# File generated from our OpenAPI spec
# frozen_string_literal: true
# typed: true
module Stripe
module V2
module Core
# A V2 Account is a representation of a company or individual that a Stripe user does business with. Accounts contain the contact details, Legal Entity information, and configuration required to enable the Account for use across Stripe products.
class Account < APIResource
class Configuration < Stripe::StripeObject
class Customer < Stripe::StripeObject
class AutomaticIndirectTax < Stripe::StripeObject
class Location < Stripe::StripeObject
# The identified tax country of the customer.
sig { returns(T.nilable(String)) }
attr_reader :country
# The identified tax state, county, province, or region of the customer.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Describes the customer's tax exemption status, which is `none`, `exempt`, or `reverse`. When set to reverse, invoice and receipt PDFs include the following text: “Reverse charge”.
sig { returns(T.nilable(String)) }
attr_reader :exempt
# A recent IP address of the customer used for tax reporting and tax location inference.
sig { returns(T.nilable(String)) }
attr_reader :ip_address
# The customer’s identified tax location - uses `location_source`. Will only be rendered if the `automatic_indirect_tax` feature is requested and `active`.
sig { returns(T.nilable(Location)) }
attr_reader :location
# The data source used to identify the customer's tax location - defaults to 'identity_address'. Will only be used for automatic tax calculation on the customer's Invoices and Subscriptions.
sig { returns(T.nilable(String)) }
attr_reader :location_source
end
class Billing < Stripe::StripeObject
class Invoice < Stripe::StripeObject
class CustomField < Stripe::StripeObject
# The name of the custom field. This may be up to 40 characters.
sig { returns(String) }
attr_reader :name
# The value of the custom field. This may be up to 140 characters. When updating, pass an empty string to remove previously-defined values.
sig { returns(String) }
attr_reader :value
end
class Rendering < Stripe::StripeObject
# How line-item prices and amounts will be displayed with respect to tax on invoice PDFs. One of exclude_tax or include_inclusive_tax. include_inclusive_tax will include inclusive tax (and exclude exclusive tax) in invoice PDF amounts. exclude_tax will exclude all tax (inclusive and exclusive alike) from invoice PDF amounts.
sig { returns(T.nilable(String)) }
attr_reader :amount_tax_display
# ID of the invoice rendering template to use for future invoices.
sig { returns(T.nilable(String)) }
attr_reader :template
end
# The list of up to 4 default custom fields to be displayed on invoices for this customer. When updating, pass an empty string to remove previously-defined fields.
sig { returns(T::Array[CustomField]) }
attr_reader :custom_fields
# Default footer to be displayed on invoices for this customer.
sig { returns(T.nilable(String)) }
attr_reader :footer
# The sequence to be used on the customer's next invoice. Defaults to 1.
sig { returns(T.nilable(Integer)) }
attr_reader :next_sequence
# The prefix for the customer used to generate unique invoice numbers. Must be 3–12 uppercase letters or numbers.
sig { returns(T.nilable(String)) }
attr_reader :prefix
# Default options for invoice PDF rendering for this customer.
sig { returns(T.nilable(Rendering)) }
attr_reader :rendering
end
# ID of a payment method that’s attached to the customer, to be used as the customer’s default payment method for invoices and subscriptions.
sig { returns(T.nilable(String)) }
attr_reader :default_payment_method
# Default settings used on invoices for this customer.
sig { returns(T.nilable(Invoice)) }
attr_reader :invoice
end
class Capabilities < Stripe::StripeObject
class AutomaticIndirectTax < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
# Generates requirements for enabling automatic indirect tax calculation on this customer's invoices or subscriptions. Recommended to request this capability if planning to enable automatic tax calculation on this customer's invoices or subscriptions. Uses the `location_source` field.
sig { returns(T.nilable(AutomaticIndirectTax)) }
attr_reader :automatic_indirect_tax
end
class Shipping < Stripe::StripeObject
class Address < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Customer shipping address.
sig { returns(T.nilable(Address)) }
attr_reader :address
# Customer name.
sig { returns(T.nilable(String)) }
attr_reader :name
# Customer phone (including extension).
sig { returns(T.nilable(String)) }
attr_reader :phone
end
# Automatic indirect tax settings to be used when automatic tax calculation is enabled on the customer's invoices, subscriptions, checkout sessions, or payment links. Surfaces if automatic tax calculation is possible given the current customer location information.
sig { returns(T.nilable(AutomaticIndirectTax)) }
attr_reader :automatic_indirect_tax
# Billing settings - default settings used for this customer in Billing flows such as Invoices and Subscriptions.
sig { returns(T.nilable(Billing)) }
attr_reader :billing
# Capabilities that have been requested on the Customer Configuration.
sig { returns(T.nilable(Capabilities)) }
attr_reader :capabilities
# The customer's shipping information. Appears on invoices emailed to this customer.
sig { returns(T.nilable(Shipping)) }
attr_reader :shipping
# ID of the test clock to attach to the customer. Can only be set on testmode Accounts, and when the Customer Configuration is first set on an Account.
sig { returns(T.nilable(String)) }
attr_reader :test_clock
end
class Merchant < Stripe::StripeObject
class BacsDebitPayments < Stripe::StripeObject
# Display name for Bacs debit payments.
sig { returns(T.nilable(String)) }
attr_reader :display_name
# Service user number for Bacs debit payments.
sig { returns(T.nilable(String)) }
attr_reader :service_user_number
end
class Branding < Stripe::StripeObject
# ID of a [file upload](https://docs.stripe.com/api/persons/update#create_file): An icon for the merchant. Must be square and at least 128px x 128px.
sig { returns(T.nilable(String)) }
attr_reader :icon
# ID of a [file upload](https://docs.stripe.com/api/persons/update#create_file): A logo for the merchant that will be used in Checkout instead of the icon and without the merchant's name next to it if provided. Must be at least 128px x 128px.
sig { returns(T.nilable(String)) }
attr_reader :logo
# A CSS hex color value representing the primary branding color for the merchant.
sig { returns(T.nilable(String)) }
attr_reader :primary_color
# A CSS hex color value representing the secondary branding color for the merchant.
sig { returns(T.nilable(String)) }
attr_reader :secondary_color
end
class Capabilities < Stripe::StripeObject
class AchDebitPayments < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class AcssDebitPayments < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class AffirmPayments < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class AfterpayClearpayPayments < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class AlmaPayments < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class AmazonPayPayments < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class AuBecsDebitPayments < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class BacsDebitPayments < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class BancontactPayments < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class BlikPayments < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class BoletoPayments < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class CardPayments < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class CartesBancairesPayments < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class CashappPayments < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class EpsPayments < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class FpxPayments < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class GbBankTransferPayments < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class GrabpayPayments < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class IdealPayments < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class JcbPayments < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class JpBankTransferPayments < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class KakaoPayPayments < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class KlarnaPayments < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class KonbiniPayments < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class KrCardPayments < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class LinkPayments < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class MobilepayPayments < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class MultibancoPayments < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class MxBankTransferPayments < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class NaverPayPayments < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class OxxoPayments < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class P24Payments < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class PayByBankPayments < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class PaycoPayments < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class PaynowPayments < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class PromptpayPayments < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class RevolutPayPayments < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class SamsungPayPayments < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class SepaBankTransferPayments < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class SepaDebitPayments < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class StripeBalance < Stripe::StripeObject
class Payouts < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
# Allows the account to do payouts using their Stripe Balance (/v1/balance).
sig { returns(T.nilable(Payouts)) }
attr_reader :payouts
end
class SwishPayments < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class TwintPayments < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class UsBankTransferPayments < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class ZipPayments < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
# Allow the merchant to process ACH debit payments.
sig { returns(T.nilable(AchDebitPayments)) }
attr_reader :ach_debit_payments
# Allow the merchant to process ACSS debit payments.
sig { returns(T.nilable(AcssDebitPayments)) }
attr_reader :acss_debit_payments
# Allow the merchant to process Affirm payments.
sig { returns(T.nilable(AffirmPayments)) }
attr_reader :affirm_payments
# Allow the merchant to process Afterpay/Clearpay payments.
sig { returns(T.nilable(AfterpayClearpayPayments)) }
attr_reader :afterpay_clearpay_payments
# Allow the merchant to process Alma payments.
sig { returns(T.nilable(AlmaPayments)) }
attr_reader :alma_payments
# Allow the merchant to process Amazon Pay payments.
sig { returns(T.nilable(AmazonPayPayments)) }
attr_reader :amazon_pay_payments
# Allow the merchant to process Australian BECS Direct Debit payments.
sig { returns(T.nilable(AuBecsDebitPayments)) }
attr_reader :au_becs_debit_payments
# Allow the merchant to process BACS Direct Debit payments.
sig { returns(T.nilable(BacsDebitPayments)) }
attr_reader :bacs_debit_payments
# Allow the merchant to process Bancontact payments.
sig { returns(T.nilable(BancontactPayments)) }
attr_reader :bancontact_payments
# Allow the merchant to process BLIK payments.
sig { returns(T.nilable(BlikPayments)) }
attr_reader :blik_payments
# Allow the merchant to process Boleto payments.
sig { returns(T.nilable(BoletoPayments)) }
attr_reader :boleto_payments
# Allow the merchant to collect card payments.
sig { returns(T.nilable(CardPayments)) }
attr_reader :card_payments
# Allow the merchant to process Cartes Bancaires payments.
sig { returns(T.nilable(CartesBancairesPayments)) }
attr_reader :cartes_bancaires_payments
# Allow the merchant to process Cash App payments.
sig { returns(T.nilable(CashappPayments)) }
attr_reader :cashapp_payments
# Allow the merchant to process EPS payments.
sig { returns(T.nilable(EpsPayments)) }
attr_reader :eps_payments
# Allow the merchant to process FPX payments.
sig { returns(T.nilable(FpxPayments)) }
attr_reader :fpx_payments
# Allow the merchant to process UK bank transfer payments.
sig { returns(T.nilable(GbBankTransferPayments)) }
attr_reader :gb_bank_transfer_payments
# Allow the merchant to process GrabPay payments.
sig { returns(T.nilable(GrabpayPayments)) }
attr_reader :grabpay_payments
# Allow the merchant to process iDEAL payments.
sig { returns(T.nilable(IdealPayments)) }
attr_reader :ideal_payments
# Allow the merchant to process JCB card payments.
sig { returns(T.nilable(JcbPayments)) }
attr_reader :jcb_payments
# Allow the merchant to process Japanese bank transfer payments.
sig { returns(T.nilable(JpBankTransferPayments)) }
attr_reader :jp_bank_transfer_payments
# Allow the merchant to process Kakao Pay payments.
sig { returns(T.nilable(KakaoPayPayments)) }
attr_reader :kakao_pay_payments
# Allow the merchant to process Klarna payments.
sig { returns(T.nilable(KlarnaPayments)) }
attr_reader :klarna_payments
# Allow the merchant to process Konbini convenience store payments.
sig { returns(T.nilable(KonbiniPayments)) }
attr_reader :konbini_payments
# Allow the merchant to process Korean card payments.
sig { returns(T.nilable(KrCardPayments)) }
attr_reader :kr_card_payments
# Allow the merchant to process Link payments.
sig { returns(T.nilable(LinkPayments)) }
attr_reader :link_payments
# Allow the merchant to process MobilePay payments.
sig { returns(T.nilable(MobilepayPayments)) }
attr_reader :mobilepay_payments
# Allow the merchant to process Multibanco payments.
sig { returns(T.nilable(MultibancoPayments)) }
attr_reader :multibanco_payments
# Allow the merchant to process Mexican bank transfer payments.
sig { returns(T.nilable(MxBankTransferPayments)) }
attr_reader :mx_bank_transfer_payments
# Allow the merchant to process Naver Pay payments.
sig { returns(T.nilable(NaverPayPayments)) }
attr_reader :naver_pay_payments
# Allow the merchant to process OXXO payments.
sig { returns(T.nilable(OxxoPayments)) }
attr_reader :oxxo_payments
# Allow the merchant to process Przelewy24 (P24) payments.
sig { returns(T.nilable(P24Payments)) }
attr_reader :p24_payments
# Allow the merchant to process Pay by Bank payments.
sig { returns(T.nilable(PayByBankPayments)) }
attr_reader :pay_by_bank_payments
# Allow the merchant to process PAYCO payments.
sig { returns(T.nilable(PaycoPayments)) }
attr_reader :payco_payments
# Allow the merchant to process PayNow payments.
sig { returns(T.nilable(PaynowPayments)) }
attr_reader :paynow_payments
# Allow the merchant to process PromptPay payments.
sig { returns(T.nilable(PromptpayPayments)) }
attr_reader :promptpay_payments
# Allow the merchant to process Revolut Pay payments.
sig { returns(T.nilable(RevolutPayPayments)) }
attr_reader :revolut_pay_payments
# Allow the merchant to process Samsung Pay payments.
sig { returns(T.nilable(SamsungPayPayments)) }
attr_reader :samsung_pay_payments
# Allow the merchant to process SEPA bank transfer payments.
sig { returns(T.nilable(SepaBankTransferPayments)) }
attr_reader :sepa_bank_transfer_payments
# Allow the merchant to process SEPA Direct Debit payments.
sig { returns(T.nilable(SepaDebitPayments)) }
attr_reader :sepa_debit_payments
# Capabilities that enable the merchant to manage their Stripe Balance (/v1/balance).
sig { returns(T.nilable(StripeBalance)) }
attr_reader :stripe_balance
# Allow the merchant to process Swish payments.
sig { returns(T.nilable(SwishPayments)) }
attr_reader :swish_payments
# Allow the merchant to process TWINT payments.
sig { returns(T.nilable(TwintPayments)) }
attr_reader :twint_payments
# Allow the merchant to process US bank transfer payments.
sig { returns(T.nilable(UsBankTransferPayments)) }
attr_reader :us_bank_transfer_payments
# Allow the merchant to process Zip payments.
sig { returns(T.nilable(ZipPayments)) }
attr_reader :zip_payments
end
class CardPayments < Stripe::StripeObject
class DeclineOn < Stripe::StripeObject
# Whether Stripe automatically declines charges with an incorrect ZIP or postal code. This setting only applies when a ZIP or postal code is provided and they fail bank verification.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :avs_failure
# Whether Stripe automatically declines charges with an incorrect CVC. This setting only applies when a CVC is provided and it fails bank verification.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :cvc_failure
end
# Automatically declines certain charge types regardless of whether the card issuer accepted or declined the charge.
sig { returns(T.nilable(DeclineOn)) }
attr_reader :decline_on
end
class SepaDebitPayments < Stripe::StripeObject
# Creditor ID for SEPA debit payments.
sig { returns(T.nilable(String)) }
attr_reader :creditor_id
end
class StatementDescriptor < Stripe::StripeObject
# The default text that appears on statements for non-card charges outside of Japan. For card charges, if you don’t set a statement_descriptor_prefix, this text is also used as the statement descriptor prefix. In that case, if concatenating the statement descriptor suffix causes the combined statement descriptor to exceed 22 characters, we truncate the statement_descriptor text to limit the full descriptor to 22 characters. For more information about statement descriptors and their requirements, see the Merchant Configuration settings documentation.
sig { returns(T.nilable(String)) }
attr_reader :descriptor
# Default text that appears on statements for card charges outside of Japan, prefixing any dynamic statement_descriptor_suffix specified on the charge. To maximize space for the dynamic part of the descriptor, keep this text short. If you don’t specify this value, statement_descriptor is used as the prefix. For more information about statement descriptors and their requirements, see the Merchant Configuration settings documentation.
sig { returns(T.nilable(String)) }
attr_reader :prefix
end
class Support < Stripe::StripeObject
class Address < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_reader :town
end
# A publicly available mailing address for sending support issues to.
sig { returns(T.nilable(Address)) }
attr_reader :address
# A publicly available email address for sending support issues to.
sig { returns(T.nilable(String)) }
attr_reader :email
# A publicly available phone number to call with support issues.
sig { returns(T.nilable(String)) }
attr_reader :phone
# A publicly available website for handling support issues.
sig { returns(T.nilable(String)) }
attr_reader :url
end
# Settings used for Bacs debit payments.
sig { returns(T.nilable(BacsDebitPayments)) }
attr_reader :bacs_debit_payments
# Settings used to apply the merchant's branding to email receipts, invoices, Checkout, and other products.
sig { returns(T.nilable(Branding)) }
attr_reader :branding
# Capabilities that have been requested on the Merchant Configuration.
sig { returns(T.nilable(Capabilities)) }
attr_reader :capabilities
# Card payments settings.
sig { returns(T.nilable(CardPayments)) }
attr_reader :card_payments
# The merchant category code for the merchant. MCCs are used to classify businesses based on the goods or services they provide.
sig { returns(T.nilable(String)) }
attr_reader :mcc
# Settings used for SEPA debit payments.
sig { returns(T.nilable(SepaDebitPayments)) }
attr_reader :sepa_debit_payments
# Statement descriptor.
sig { returns(T.nilable(StatementDescriptor)) }
attr_reader :statement_descriptor
# Publicly available contact information for sending support issues to.
sig { returns(T.nilable(Support)) }
attr_reader :support
end
class Recipient < Stripe::StripeObject
class Capabilities < Stripe::StripeObject
class BankAccounts < Stripe::StripeObject
class Local < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class Wire < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
# Enables this Account to receive OutboundPayments to linked bank accounts over local networks.
sig { returns(T.nilable(Local)) }
attr_reader :local
# Enables this Account to receive OutboundPayments to linked bank accounts over wire.
sig { returns(T.nilable(Wire)) }
attr_reader :wire
end
class Cards < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class StripeBalance < Stripe::StripeObject
class Payouts < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class StripeTransfers < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Machine-readable code explaining the reason for the Capability to be in its current status.
sig { returns(String) }
attr_reader :code
# Machine-readable code explaining how to make the Capability active.
sig { returns(String) }
attr_reader :resolution
end
# Whether the Capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# The status of the Capability.
sig { returns(String) }
attr_reader :status
# Additional details regarding the status of the Capability. `status_details` will be empty if the Capability's status is `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
# Allows the account to do payouts using their Stripe Balance (/v1/balance).
sig { returns(T.nilable(Payouts)) }
attr_reader :payouts
# Allows the account to receive /v1/transfers into their Stripe Balance (/v1/balance).
sig { returns(T.nilable(StripeTransfers)) }
attr_reader :stripe_transfers
end
# Capabilities that enable OutboundPayments to a bank account linked to this Account.
sig { returns(T.nilable(BankAccounts)) }
attr_reader :bank_accounts
# Capability that enable OutboundPayments to a debit card linked to this Account.
sig { returns(T.nilable(Cards)) }
attr_reader :cards
# Capabilities that enable the recipient to manage their Stripe Balance (/v1/balance).
sig { returns(T.nilable(StripeBalance)) }
attr_reader :stripe_balance
end
class DefaultOutboundDestination < Stripe::StripeObject
# The payout method ID of the default outbound destination.
sig { returns(String) }
attr_reader :id
# Closed Enum. The payout method type of the default outbound destination.
sig { returns(String) }
attr_reader :type
end
# Capabilities that have been requested on the Recipient Configuration.
sig { returns(T.nilable(Capabilities)) }
attr_reader :capabilities
# The payout method to be used as a default outbound destination. This will allow the PayoutMethod to be omitted on OutboundPayments made through the dashboard.
sig { returns(T.nilable(DefaultOutboundDestination)) }
attr_reader :default_outbound_destination
end
# The Customer Configuration allows the Account to be used in inbound payment flows.
sig { returns(T.nilable(Customer)) }
attr_reader :customer
# The Merchant configuration allows the Account to act as a connected account and collect payments facilitated by a Connect platform. You can add this configuration to your connected accounts only if you’ve completed onboarding as a Connect platform.
sig { returns(T.nilable(Merchant)) }
attr_reader :merchant
# The Recipient Configuration allows the Account to receive funds.
sig { returns(T.nilable(Recipient)) }
attr_reader :recipient
end
class Defaults < Stripe::StripeObject
class Responsibilities < Stripe::StripeObject
# A value indicating the responsible payer of a bundle of Stripe fees for pricing-control eligible products on this Account.
sig { returns(String) }
attr_reader :fees_collector
# A value indicating who is responsible for losses when this Account can’t pay back negative balances from payments.
sig { returns(String) }
attr_reader :losses_collector
end
# 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).
sig { returns(T.nilable(String)) }
attr_reader :currency
# The Account's preferred locales (languages), ordered by preference.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :locales
# Default responsibilities held by either Stripe or the platform.
sig { returns(T.nilable(Responsibilities)) }
attr_reader :responsibilities
end
class Identity < Stripe::StripeObject
class Attestations < Stripe::StripeObject
class DirectorshipDeclaration < Stripe::StripeObject
# The time marking when the director attestation was made. Represented as a RFC 3339 date & time UTC value in millisecond precision, for example: 2022-09-18T13:22:18.123Z.
sig { returns(T.nilable(String)) }
attr_reader :date
# The IP address from which the director attestation was made.
sig { returns(T.nilable(String)) }
attr_reader :ip
# The user agent of the browser from which the director attestation was made.
sig { returns(T.nilable(String)) }
attr_reader :user_agent
end
class OwnershipDeclaration < Stripe::StripeObject
# The time marking when the beneficial owner attestation was made. Represented as a RFC 3339 date & time UTC value in millisecond precision, for example: 2022-09-18T13:22:18.123Z.
sig { returns(T.nilable(String)) }
attr_reader :date
# The IP address from which the beneficial owner attestation was made.
sig { returns(T.nilable(String)) }
attr_reader :ip
# The user agent of the browser from which the beneficial owner attestation was made.
sig { returns(T.nilable(String)) }
attr_reader :user_agent
end
class PersonsProvided < Stripe::StripeObject
# Whether the company’s directors have been provided. Set this Boolean to true after creating all the company’s directors with the [Persons API](https://docs.stripe.com/api/v2/core/accounts/createperson).
sig { returns(T.nilable(T::Boolean)) }
attr_reader :directors
# Whether the company’s executives have been provided. Set this Boolean to true after creating all the company’s executives with the [Persons API](https://docs.stripe.com/api/v2/core/accounts/createperson).
sig { returns(T.nilable(T::Boolean)) }
attr_reader :executives
# Whether the company’s owners have been provided. Set this Boolean to true after creating all the company’s owners with the [Persons API](https://docs.stripe.com/api/v2/core/accounts/createperson).
sig { returns(T.nilable(T::Boolean)) }
attr_reader :owners
# Reason for why the company is exempt from providing ownership information.
sig { returns(T.nilable(String)) }
attr_reader :ownership_exemption_reason
end
class TermsOfService < Stripe::StripeObject
class Account < Stripe::StripeObject
# The time when the Account's representative accepted the terms of service. Represented as a RFC 3339 date & time UTC value in millisecond precision, for example: 2022-09-18T13:22:18.123Z.
sig { returns(T.nilable(String)) }
attr_reader :date
# The IP address from which the Account's representative accepted the terms of service.
sig { returns(T.nilable(String)) }
attr_reader :ip
# The user agent of the browser from which the Account's representative accepted the terms of service.
sig { returns(T.nilable(String)) }
attr_reader :user_agent
end
# Details on the Account's acceptance of the [Stripe Services Agreement](https://docs.stripe.com/connect/updating-accounts#tos-acceptance).
sig { returns(T.nilable(Account)) }
attr_reader :account
end
# This hash is used to attest that the directors information provided to Stripe is both current and correct.
sig { returns(T.nilable(DirectorshipDeclaration)) }
attr_reader :directorship_declaration
# This hash is used to attest that the beneficial owner information provided to Stripe is both current and correct.
sig { returns(T.nilable(OwnershipDeclaration)) }
attr_reader :ownership_declaration
# Attestation that all Persons with a specific Relationship value have been provided.
sig { returns(T.nilable(PersonsProvided)) }
attr_reader :persons_provided
# Attestations of accepted terms of service agreements.
sig { returns(T.nilable(TermsOfService)) }
attr_reader :terms_of_service
end
class BusinessDetails < Stripe::StripeObject
class Address < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_reader :town
end
class AnnualRevenue < Stripe::StripeObject
# A non-negative integer representing the amount in the smallest currency unit.
sig { returns(T.nilable(Stripe::V2::Amount)) }
attr_reader :amount
# The close-out date of the preceding fiscal year in ISO 8601 format. E.g. 2023-12-31 for the 31st of December, 2023.
sig { returns(T.nilable(String)) }
attr_reader :fiscal_year_end
end
class Documents < Stripe::StripeObject
class BankAccountOwnershipVerification < Stripe::StripeObject
# One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`.
sig { returns(T::Array[String]) }
attr_reader :files
# The format of the document. Currently supports `files` only.
sig { returns(String) }
attr_reader :type
end
class CompanyLicense < Stripe::StripeObject
# One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`.
sig { returns(T::Array[String]) }
attr_reader :files
# The format of the document. Currently supports `files` only.
sig { returns(String) }
attr_reader :type
end
class CompanyMemorandumOfAssociation < Stripe::StripeObject
# One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`.
sig { returns(T::Array[String]) }
attr_reader :files
# The format of the document. Currently supports `files` only.
sig { returns(String) }
attr_reader :type
end
class CompanyMinisterialDecree < Stripe::StripeObject
# One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`.
sig { returns(T::Array[String]) }
attr_reader :files
# The format of the document. Currently supports `files` only.
sig { returns(String) }
attr_reader :type
end
class CompanyRegistrationVerification < Stripe::StripeObject
# One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`.
sig { returns(T::Array[String]) }
attr_reader :files
# The format of the document. Currently supports `files` only.
sig { returns(String) }
attr_reader :type
end
class CompanyTaxIdVerification < Stripe::StripeObject
# One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`.
sig { returns(T::Array[String]) }
attr_reader :files
# The format of the document. Currently supports `files` only.
sig { returns(String) }
attr_reader :type
end
class PrimaryVerification < Stripe::StripeObject
class FrontBack < Stripe::StripeObject
# A [file upload](https://docs.stripe.com/api/persons/update#create_file) token representing the back of the verification document. The purpose of the uploaded file should be 'identity_document'. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_reader :back
# A [file upload](https://docs.stripe.com/api/persons/update#create_file) token representing the front of the verification document. The purpose of the uploaded file should be 'identity_document'. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(String) }
attr_reader :front
end
# The [file upload](https://docs.stripe.com/api/persons/update#create_file) tokens for the front and back of the verification document.
sig { returns(FrontBack) }
attr_reader :front_back
# The format of the verification document. Currently supports `front_back` only.
sig { returns(String) }
attr_reader :type
end
class ProofOfRegistration < Stripe::StripeObject
# One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`.
sig { returns(T::Array[String]) }
attr_reader :files
# The format of the document. Currently supports `files` only.
sig { returns(String) }
attr_reader :type
end
class ProofOfUltimateBeneficialOwnership < Stripe::StripeObject
# One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`.
sig { returns(T::Array[String]) }
attr_reader :files
# The format of the document. Currently supports `files` only.
sig { returns(String) }
attr_reader :type
end
# One or more documents that support the Bank account ownership verification requirement. Must be a document associated with the account’s primary active bank account that displays the last 4 digits of the account number, either a statement or a check.
sig { returns(T.nilable(BankAccountOwnershipVerification)) }
attr_reader :bank_account_ownership_verification
# One or more documents that demonstrate proof of a company’s license to operate.
sig { returns(T.nilable(CompanyLicense)) }
attr_reader :company_license
# One or more documents showing the company’s Memorandum of Association.
sig { returns(T.nilable(CompanyMemorandumOfAssociation)) }
attr_reader :company_memorandum_of_association
# Certain countries only: One or more documents showing the ministerial decree legalizing the company’s establishment.
sig { returns(T.nilable(CompanyMinisterialDecree)) }
attr_reader :company_ministerial_decree
# One or more documents that demonstrate proof of a company’s registration with the appropriate local authorities.
sig { returns(T.nilable(CompanyRegistrationVerification)) }
attr_reader :company_registration_verification
# One or more documents that demonstrate proof of a company’s tax ID.
sig { returns(T.nilable(CompanyTaxIdVerification)) }
attr_reader :company_tax_id_verification
# A document verifying the business.
sig { returns(T.nilable(PrimaryVerification)) }
attr_reader :primary_verification
# One or more documents showing the company’s proof of registration with the national business registry.
sig { returns(T.nilable(ProofOfRegistration)) }
attr_reader :proof_of_registration
# One or more documents that demonstrate proof of ultimate beneficial ownership.
sig { returns(T.nilable(ProofOfUltimateBeneficialOwnership)) }
attr_reader :proof_of_ultimate_beneficial_ownership
end
class IdNumber < Stripe::StripeObject
# The registrar of the ID number (Only valid for DE ID number types).
sig { returns(T.nilable(String)) }
attr_reader :registrar
# Open Enum. The ID number type of a business entity.
sig { returns(String) }
attr_reader :type
end
class MonthlyEstimatedRevenue < Stripe::StripeObject
# A non-negative integer representing the amount in the smallest currency unit.
sig { returns(T.nilable(Stripe::V2::Amount)) }
attr_reader :amount
end
class ScriptAddresses < Stripe::StripeObject
class Kana < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_reader :town
end
class Kanji < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_reader :town
end
# Kana Address.
sig { returns(T.nilable(Kana)) }
attr_reader :kana
# Kanji Address.
sig { returns(T.nilable(Kanji)) }
attr_reader :kanji
end
class ScriptNames < Stripe::StripeObject
class Kana < Stripe::StripeObject
# Registered name of the business.
sig { returns(T.nilable(String)) }
attr_reader :registered_name
end
class Kanji < Stripe::StripeObject
# Registered name of the business.
sig { returns(T.nilable(String)) }
attr_reader :registered_name
end
# Kana name.
sig { returns(T.nilable(Kana)) }
attr_reader :kana
# Kanji name.
sig { returns(T.nilable(Kanji)) }
attr_reader :kanji
end
# The company’s primary address.
sig { returns(T.nilable(Address)) }
attr_reader :address
# The business gross annual revenue for its preceding fiscal year.
sig { returns(T.nilable(AnnualRevenue)) }
attr_reader :annual_revenue
# Documents that may be submitted to satisfy various informational requests.
sig { returns(T.nilable(Documents)) }
attr_reader :documents
# The company’s legal name.
sig { returns(T.nilable(String)) }
attr_reader :doing_business_as
# An estimated upper bound of employees, contractors, vendors, etc. currently working for the business.
sig { returns(T.nilable(Integer)) }
attr_reader :estimated_worker_count
# The provided ID numbers of a business entity.
sig { returns(T.nilable(T::Array[IdNumber])) }
attr_reader :id_numbers
# An estimate of the monthly revenue of the business.
sig { returns(T.nilable(MonthlyEstimatedRevenue)) }
attr_reader :monthly_estimated_revenue
# The company’s phone number (used for verification).
sig { returns(T.nilable(String)) }
attr_reader :phone
# Internal-only description of the product sold or service provided by the business. It’s used by Stripe for risk and underwriting purposes.
sig { returns(T.nilable(String)) }
attr_reader :product_description
# The business legal name.
sig { returns(T.nilable(String)) }
attr_reader :registered_name
# The business registration address of the business entity in non latin script.
sig { returns(T.nilable(ScriptAddresses)) }
attr_reader :script_addresses
# The business legal name in non latin script.
sig { returns(T.nilable(ScriptNames)) }
attr_reader :script_names
# The category identifying the legal structure of the business.
sig { returns(T.nilable(String)) }
attr_reader :structure
# The business's publicly available website.
sig { returns(T.nilable(String)) }
attr_reader :url
end
class Individual < Stripe::StripeObject
class AdditionalAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# Purpose of additional address.
sig { returns(String) }
attr_reader :purpose
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_reader :town
end
class AdditionalName < Stripe::StripeObject
# The individual's full name.
sig { returns(T.nilable(String)) }
attr_reader :full_name
# The individual's first or given name.
sig { returns(T.nilable(String)) }
attr_reader :given_name
# The purpose or type of the additional name.
sig { returns(String) }
attr_reader :purpose
# The individual's last or family name.
sig { returns(T.nilable(String)) }
attr_reader :surname
end
class AdditionalTermsOfService < Stripe::StripeObject
class Account < Stripe::StripeObject
# The time when the Account's representative accepted the terms of service. Represented as a RFC 3339 date & time UTC value in millisecond precision, for example: 2022-09-18T13:22:18.123Z.
sig { returns(T.nilable(String)) }
attr_reader :date
# The IP address from which the Account's representative accepted the terms of service.
sig { returns(T.nilable(String)) }
attr_reader :ip
# The user agent of the browser from which the Account's representative accepted the terms of service.
sig { returns(T.nilable(String)) }
attr_reader :user_agent
end
# Stripe terms of service agreement.
sig { returns(T.nilable(Account)) }
attr_reader :account
end
class Address < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_reader :town
end
class DateOfBirth < Stripe::StripeObject
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_reader :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_reader :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_reader :year
end
class Documents < Stripe::StripeObject
class CompanyAuthorization < Stripe::StripeObject
# One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`.
sig { returns(T::Array[String]) }
attr_reader :files
# The format of the document. Currently supports `files` only.
sig { returns(String) }
attr_reader :type
end
class Passport < Stripe::StripeObject
# One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`.
sig { returns(T::Array[String]) }
attr_reader :files
# The format of the document. Currently supports `files` only.
sig { returns(String) }
attr_reader :type
end
class PrimaryVerification < Stripe::StripeObject
class FrontBack < Stripe::StripeObject
# A [file upload](https://docs.stripe.com/api/persons/update#create_file) token representing the back of the verification document. The purpose of the uploaded file should be 'identity_document'. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_reader :back
# A [file upload](https://docs.stripe.com/api/persons/update#create_file) token representing the front of the verification document. The purpose of the uploaded file should be 'identity_document'. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(String) }
attr_reader :front
end
# The [file upload](https://docs.stripe.com/api/persons/update#create_file) tokens for the front and back of the verification document.
sig { returns(FrontBack) }
attr_reader :front_back
# The format of the verification document. Currently supports `front_back` only.
sig { returns(String) }
attr_reader :type
end
class SecondaryVerification < Stripe::StripeObject
class FrontBack < Stripe::StripeObject
# A [file upload](https://docs.stripe.com/api/persons/update#create_file) token representing the back of the verification document. The purpose of the uploaded file should be 'identity_document'. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_reader :back
# A [file upload](https://docs.stripe.com/api/persons/update#create_file) token representing the front of the verification document. The purpose of the uploaded file should be 'identity_document'. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(String) }
attr_reader :front
end
# The [file upload](https://docs.stripe.com/api/persons/update#create_file) tokens for the front and back of the verification document.
sig { returns(FrontBack) }
attr_reader :front_back
# The format of the verification document. Currently supports `front_back` only.
sig { returns(String) }
attr_reader :type
end
class Visa < Stripe::StripeObject
# One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`.
sig { returns(T::Array[String]) }
attr_reader :files
# The format of the document. Currently supports `files` only.
sig { returns(String) }
attr_reader :type
end
# One or more documents that demonstrate proof that this person is authorized to represent the company.
sig { returns(T.nilable(CompanyAuthorization)) }
attr_reader :company_authorization
# One or more documents showing the person’s passport page with photo and personal data.
sig { returns(T.nilable(Passport)) }
attr_reader :passport
# An identifying document showing the person's name, either a passport or local ID card.
sig { returns(T.nilable(PrimaryVerification)) }
attr_reader :primary_verification
# A document showing address, either a passport, local ID card, or utility bill from a well-known utility company.
sig { returns(T.nilable(SecondaryVerification)) }
attr_reader :secondary_verification
# One or more documents showing the person’s visa required for living in the country where they are residing.
sig { returns(T.nilable(Visa)) }
attr_reader :visa
end
class IdNumber < Stripe::StripeObject
# The ID number type of an individual.
sig { returns(String) }
attr_reader :type
end
class Relationship < Stripe::StripeObject
# Whether the individual is an authorizer of the Account’s legal entity.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :authorizer
# Whether the individual is a director of the Account’s legal entity. Directors are typically members of the governing board of the company, or responsible for ensuring the company meets its regulatory obligations.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :director
# Whether the individual has significant responsibility to control, manage, or direct the organization.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :executive
# Whether the individual is the legal guardian of the Account’s representative.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :legal_guardian
# Whether the individual is an owner of the Account’s legal entity.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :owner
# The percent owned by the individual of the Account’s legal entity.
sig { returns(T.nilable(String)) }
attr_reader :percent_ownership
# Whether the individual is authorized as the primary representative of the Account. This is the person nominated by the business to provide information about themselves, and general information about the account. There can only be one representative at any given time. At the time the account is created, this person should be set to the person responsible for opening the account.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :representative
# The individual's title (e.g., CEO, Support Engineer).
sig { returns(T.nilable(String)) }
attr_reader :title
end
class ScriptAddresses < Stripe::StripeObject
class Kana < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_reader :town
end
class Kanji < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_reader :town
end
# Kana Address.
sig { returns(T.nilable(Kana)) }
attr_reader :kana
# Kanji Address.
sig { returns(T.nilable(Kanji)) }
attr_reader :kanji
end
class ScriptNames < Stripe::StripeObject
class Kana < Stripe::StripeObject
# The person's first or given name.
sig { returns(T.nilable(String)) }
attr_reader :given_name
# The person's last or family name.
sig { returns(T.nilable(String)) }
attr_reader :surname
end
class Kanji < Stripe::StripeObject
# The person's first or given name.
sig { returns(T.nilable(String)) }
attr_reader :given_name
# The person's last or family name.
sig { returns(T.nilable(String)) }
attr_reader :surname
end
# Persons name in kana script.
sig { returns(T.nilable(Kana)) }
attr_reader :kana
# Persons name in kanji script.
sig { returns(T.nilable(Kanji)) }
attr_reader :kanji
end
# The account ID which the individual belongs to.
sig { returns(String) }
attr_reader :account
# Additional addresses associated with the individual.
sig { returns(T.nilable(T::Array[AdditionalAddress])) }
attr_reader :additional_addresses
# Additional names (e.g. aliases) associated with the individual.
sig { returns(T.nilable(T::Array[AdditionalName])) }
attr_reader :additional_names
# Terms of service acceptances.
sig { returns(T.nilable(AdditionalTermsOfService)) }
attr_reader :additional_terms_of_service
# The individual's residential address.
sig { returns(T.nilable(Address)) }
attr_reader :address
# Time at which the object was created. Represented as a RFC 3339 date & time UTC value in millisecond precision, for example: 2022-09-18T13:22:18.123Z.
sig { returns(String) }
attr_reader :created
# The individual's date of birth.
sig { returns(T.nilable(DateOfBirth)) }
attr_reader :date_of_birth
# Documents that may be submitted to satisfy various informational requests.
sig { returns(T.nilable(Documents)) }
attr_reader :documents
# The individual's email address.
sig { returns(T.nilable(String)) }
attr_reader :email
# The individual's first name.
sig { returns(T.nilable(String)) }
attr_reader :given_name
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# The identification numbers (e.g., SSN) associated with the individual.
sig { returns(T.nilable(T::Array[IdNumber])) }
attr_reader :id_numbers
# The individual's gender (International regulations require either "male” or "female").
sig { returns(T.nilable(String)) }
attr_reader :legal_gender
# Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# The countries where the individual is a national. Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(T::Array[String])) }
attr_reader :nationalities
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The individual's phone number.
sig { returns(T.nilable(String)) }
attr_reader :phone
# Indicates if the individual or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction.
sig { returns(T.nilable(String)) }
attr_reader :political_exposure
# The relationship that this individual has with the Account's identity.
sig { returns(T.nilable(Relationship)) }
attr_reader :relationship
# The script addresses (e.g., non-Latin characters) associated with the individual.
sig { returns(T.nilable(ScriptAddresses)) }
attr_reader :script_addresses
# The script names (e.g. non-Latin characters) associated with the individual.
sig { returns(T.nilable(ScriptNames)) }
attr_reader :script_names
# The individual's last name.
sig { returns(T.nilable(String)) }
attr_reader :surname
# Time at which the object was last updated.
sig { returns(String) }
attr_reader :updated
end
# Attestations from the identity's key people, e.g. owners, executives, directors.
sig { returns(T.nilable(Attestations)) }
attr_reader :attestations
# Information about the company or business.
sig { returns(T.nilable(BusinessDetails)) }
attr_reader :business_details
# The country in which the account holder resides, or in which the business is legally established. This should be an [ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2) country code.
sig { returns(T.nilable(String)) }
attr_reader :country
# The entity type.
sig { returns(T.nilable(String)) }
attr_reader :entity_type
# Information about the individual represented by the Account. This property is `null` unless `entity_type` is set to `individual`.
sig { returns(T.nilable(Individual)) }
attr_reader :individual
end
class Requirements < Stripe::StripeObject
class Entry < Stripe::StripeObject
class Error < Stripe::StripeObject
# Machine-readable code describing the error.
sig { returns(String) }
attr_reader :code
# Human-readable description of the error.
sig { returns(String) }
attr_reader :description
end
class Impact < Stripe::StripeObject
class RestrictsCapability < Stripe::StripeObject
class Deadline < Stripe::StripeObject
# The current status of the requirement's impact.
sig { returns(String) }
attr_reader :status
end
# The name of the Capability which will be restricted.
sig { returns(String) }
attr_reader :capability
# The configuration which specifies the Capability which will be restricted.
sig { returns(String) }
attr_reader :configuration
# Details about when in the account lifecycle the requirement must be collected by the avoid the Capability restriction.
sig { returns(Deadline) }
attr_reader :deadline
end
# The Capabilities that will be restricted if the requirement is not collected and satisfactory to Stripe.
sig { returns(T.nilable(T::Array[RestrictsCapability])) }
attr_reader :restricts_capabilities
end
class MinimumDeadline < Stripe::StripeObject
# The current status of the requirement's impact.
sig { returns(String) }
attr_reader :status
end
class Reference < Stripe::StripeObject
# If `inquiry` is the type, the inquiry token.
sig { returns(T.nilable(String)) }
attr_reader :inquiry
# If `resource` is the type, the resource token.
sig { returns(T.nilable(String)) }
attr_reader :resource
# The type of the reference. An additional hash is included with a name matching the type. It contains additional information specific to the type.
sig { returns(String) }
attr_reader :type
end
class RequestedReason < Stripe::StripeObject
# Machine-readable description of Stripe's reason for collecting the requirement.
sig { returns(String) }
attr_reader :code
end
# Whether the responsibility is with the integrator or with Stripe (to review info, to wait for some condition, etc.) to action the requirement.
sig { returns(String) }
attr_reader :awaiting_action_from
# Machine-readable string describing the requirement.
sig { returns(String) }
attr_reader :description
# Descriptions of why the requirement must be collected, or why the collected information isn't satisfactory to Stripe.
sig { returns(T::Array[Error]) }
attr_reader :errors
# A hash describing the impact of not collecting the requirement, or Stripe not being able to verify the collected information.
sig { returns(Impact) }
attr_reader :impact
# The soonest point when the account will be impacted by not providing the requirement.
sig { returns(MinimumDeadline) }
attr_reader :minimum_deadline
# A reference to the location of the requirement.
sig { returns(T.nilable(Reference)) }
attr_reader :reference
# A list of reasons why Stripe is collecting the requirement.
sig { returns(T::Array[RequestedReason]) }
attr_reader :requested_reasons
end
class Summary < Stripe::StripeObject
class MinimumDeadline < Stripe::StripeObject
# The current strictest status of all requirements on the Account.
sig { returns(String) }
attr_reader :status
# The soonest RFC3339 date & time UTC value a requirement can impact the Account.
sig { returns(T.nilable(String)) }
attr_reader :time
end
# The soonest date and time a requirement on the Account will become `past due`. Represented as a RFC 3339 date & time UTC value in millisecond precision, for example: `2022-09-18T13:22:18.123Z`.
sig { returns(T.nilable(MinimumDeadline)) }
attr_reader :minimum_deadline
end
# A value indicating responsibility for collecting requirements on this account.
sig { returns(String) }
attr_reader :collector
# A list of requirements for the Account.
sig { returns(T.nilable(T::Array[Entry])) }
attr_reader :entries
# An object containing an overview of requirements for the Account.
sig { returns(T.nilable(Summary)) }
attr_reader :summary
end
# Filter only accounts that have all of the configurations specified. If omitted, returns all accounts regardless of which configurations they have.
sig { returns(T::Array[String]) }
attr_reader :applied_configurations
# An Account Configuration which allows the Account to take on a key persona across Stripe products.
sig { returns(T.nilable(Configuration)) }
attr_reader :configuration
# The default contact email address for the Account. Required when configuring the account as a merchant or recipient.
sig { returns(T.nilable(String)) }
attr_reader :contact_email
# Time at which the object was created. Represented as a RFC 3339 date & time UTC value in millisecond precision, for example: 2022-09-18T13:22:18.123Z.
sig { returns(String) }
attr_reader :created
# A value indicating the Stripe dashboard this Account has access to. This will depend on which configurations are enabled for this account.
sig { returns(T.nilable(String)) }
attr_reader :dashboard
# Default values to be used on Account Configurations.
sig { returns(T.nilable(Defaults)) }
attr_reader :defaults
# A descriptive name for the Account. This name will be surfaced in the Stripe Dashboard and on any invoices sent to the Account.
sig { returns(T.nilable(String)) }
attr_reader :display_name
# Unique identifier for the Account.
sig { returns(String) }
attr_reader :id
# Information about the company, individual, and business represented by the Account.
sig { returns(T.nilable(Identity)) }
attr_reader :identity
# Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# String representing the object's type. Objects of the same type share the same value of the object field.
sig { returns(String) }
attr_reader :object
# Information about the requirements for the Account, including what information needs to be collected, and by when.
sig { returns(T.nilable(Requirements)) }
attr_reader :requirements
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
end
end
end
end
# typed: true
module Stripe
module V2
module Core
# AccountLinks are the means by which a Merchant grants an Account permission to access Stripe-hosted applications, such as Recipient Onboarding. This API is only available for users enrolled in the public preview for Global Payouts.
class AccountLink < APIResource
class UseCase < Stripe::StripeObject
class AccountOnboarding < Stripe::StripeObject
# Open Enum. A v2/account can be configured to enable certain functionality. The configuration param targets the v2/account_link to collect information for the specified v2/account configuration/s.
sig { returns(T::Array[String]) }
attr_reader :configurations
# The URL the user will be redirected to if the AccountLink is expired, has been used, or is otherwise invalid. The URL you specify should attempt to generate a new AccountLink with the same parameters used to create the original AccountLink, then redirect the user to the new AccountLink’s URL so they can continue the flow. If a new AccountLink cannot be generated or the redirect fails you should display a useful error to the user. Please make sure to implement authentication before redirecting the user in case this URL is leaked to a third party.
sig { returns(String) }
attr_reader :refresh_url
# The URL that the user will be redirected to upon completing the linked flow.
sig { returns(T.nilable(String)) }
attr_reader :return_url
end
class AccountUpdate < Stripe::StripeObject
# Open Enum. A v2/account can be configured to enable certain functionality. The configuration param targets the v2/account_link to collect information for the specified v2/account configuration/s.
sig { returns(T::Array[String]) }
attr_reader :configurations
# The URL the user will be redirected to if the AccountLink is expired, has been used, or is otherwise invalid. The URL you specify should attempt to generate a new AccountLink with the same parameters used to create the original AccountLink, then redirect the user to the new AccountLink’s URL so they can continue the flow. If a new AccountLink cannot be generated or the redirect fails you should display a useful error to the user. Please make sure to implement authentication before redirecting the user in case this URL is leaked to a third party.
sig { returns(String) }
attr_reader :refresh_url
# The URL that the user will be redirected to upon completing the linked flow.
sig { returns(T.nilable(String)) }
attr_reader :return_url
end
# Open Enum. The type of AccountLink the user is requesting.
sig { returns(String) }
attr_reader :type
# Indicates that the AccountLink provided should onboard an account.
sig { returns(T.nilable(AccountOnboarding)) }
attr_reader :account_onboarding
# Indicates that the AccountLink provided should update a previously onboarded account.
sig { returns(T.nilable(AccountUpdate)) }
attr_reader :account_update
end
# The ID of the Account the link was created for.
sig { returns(String) }
attr_reader :account
# The timestamp at which this AccountLink was created.
sig { returns(String) }
attr_reader :created
# The timestamp at which this AccountLink will expire.
sig { returns(String) }
attr_reader :expires_at
# String representing the object's type. Objects of the same type share the same value of the object field.
sig { returns(String) }
attr_reader :object
# The URL for the AccountLink.
sig { returns(String) }
attr_reader :url
# The use case of AccountLink the user is requesting.
sig { returns(UseCase) }
attr_reader :use_case
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
end
end
end
end
# typed: true
module Stripe
module V2
module Core
# Person retrieval response schema.
class Person < APIResource
class AdditionalAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# Purpose of additional address.
sig { returns(String) }
attr_reader :purpose
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_reader :town
end
class AdditionalName < Stripe::StripeObject
# The individual's full name.
sig { returns(T.nilable(String)) }
attr_reader :full_name
# The individual's first or given name.
sig { returns(T.nilable(String)) }
attr_reader :given_name
# The purpose or type of the additional name.
sig { returns(String) }
attr_reader :purpose
# The individual's last or family name.
sig { returns(T.nilable(String)) }
attr_reader :surname
end
class AdditionalTermsOfService < Stripe::StripeObject
class Account < Stripe::StripeObject
# The time when the Account's representative accepted the terms of service. Represented as a RFC 3339 date & time UTC value in millisecond precision, for example: 2022-09-18T13:22:18.123Z.
sig { returns(T.nilable(String)) }
attr_reader :date
# The IP address from which the Account's representative accepted the terms of service.
sig { returns(T.nilable(String)) }
attr_reader :ip
# The user agent of the browser from which the Account's representative accepted the terms of service.
sig { returns(T.nilable(String)) }
attr_reader :user_agent
end
# Stripe terms of service agreement.
sig { returns(T.nilable(Account)) }
attr_reader :account
end
class Address < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_reader :town
end
class DateOfBirth < Stripe::StripeObject
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_reader :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_reader :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_reader :year
end
class Documents < Stripe::StripeObject
class CompanyAuthorization < Stripe::StripeObject
# One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`.
sig { returns(T::Array[String]) }
attr_reader :files
# The format of the document. Currently supports `files` only.
sig { returns(String) }
attr_reader :type
end
class Passport < Stripe::StripeObject
# One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`.
sig { returns(T::Array[String]) }
attr_reader :files
# The format of the document. Currently supports `files` only.
sig { returns(String) }
attr_reader :type
end
class PrimaryVerification < Stripe::StripeObject
class FrontBack < Stripe::StripeObject
# A [file upload](https://docs.stripe.com/api/persons/update#create_file) token representing the back of the verification document. The purpose of the uploaded file should be 'identity_document'. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_reader :back
# A [file upload](https://docs.stripe.com/api/persons/update#create_file) token representing the front of the verification document. The purpose of the uploaded file should be 'identity_document'. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(String) }
attr_reader :front
end
# The [file upload](https://docs.stripe.com/api/persons/update#create_file) tokens for the front and back of the verification document.
sig { returns(FrontBack) }
attr_reader :front_back
# The format of the verification document. Currently supports `front_back` only.
sig { returns(String) }
attr_reader :type
end
class SecondaryVerification < Stripe::StripeObject
class FrontBack < Stripe::StripeObject
# A [file upload](https://docs.stripe.com/api/persons/update#create_file) token representing the back of the verification document. The purpose of the uploaded file should be 'identity_document'. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_reader :back
# A [file upload](https://docs.stripe.com/api/persons/update#create_file) token representing the front of the verification document. The purpose of the uploaded file should be 'identity_document'. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(String) }
attr_reader :front
end
# The [file upload](https://docs.stripe.com/api/persons/update#create_file) tokens for the front and back of the verification document.
sig { returns(FrontBack) }
attr_reader :front_back
# The format of the verification document. Currently supports `front_back` only.
sig { returns(String) }
attr_reader :type
end
class Visa < Stripe::StripeObject
# One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`.
sig { returns(T::Array[String]) }
attr_reader :files
# The format of the document. Currently supports `files` only.
sig { returns(String) }
attr_reader :type
end
# One or more documents that demonstrate proof that this person is authorized to represent the company.
sig { returns(T.nilable(CompanyAuthorization)) }
attr_reader :company_authorization
# One or more documents showing the person’s passport page with photo and personal data.
sig { returns(T.nilable(Passport)) }
attr_reader :passport
# An identifying document showing the person's name, either a passport or local ID card.
sig { returns(T.nilable(PrimaryVerification)) }
attr_reader :primary_verification
# A document showing address, either a passport, local ID card, or utility bill from a well-known utility company.
sig { returns(T.nilable(SecondaryVerification)) }
attr_reader :secondary_verification
# One or more documents showing the person’s visa required for living in the country where they are residing.
sig { returns(T.nilable(Visa)) }
attr_reader :visa
end
class IdNumber < Stripe::StripeObject
# The ID number type of an individual.
sig { returns(String) }
attr_reader :type
end
class Relationship < Stripe::StripeObject
# Whether the individual is an authorizer of the Account’s legal entity.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :authorizer
# Whether the individual is a director of the Account’s legal entity. Directors are typically members of the governing board of the company, or responsible for ensuring the company meets its regulatory obligations.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :director
# Whether the individual has significant responsibility to control, manage, or direct the organization.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :executive
# Whether the individual is the legal guardian of the Account’s representative.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :legal_guardian
# Whether the individual is an owner of the Account’s legal entity.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :owner
# The percent owned by the individual of the Account’s legal entity.
sig { returns(T.nilable(String)) }
attr_reader :percent_ownership
# Whether the individual is authorized as the primary representative of the Account. This is the person nominated by the business to provide information about themselves, and general information about the account. There can only be one representative at any given time. At the time the account is created, this person should be set to the person responsible for opening the account.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :representative
# The individual's title (e.g., CEO, Support Engineer).
sig { returns(T.nilable(String)) }
attr_reader :title
end
class ScriptAddresses < Stripe::StripeObject
class Kana < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_reader :town
end
class Kanji < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_reader :town
end
# Kana Address.
sig { returns(T.nilable(Kana)) }
attr_reader :kana
# Kanji Address.
sig { returns(T.nilable(Kanji)) }
attr_reader :kanji
end
class ScriptNames < Stripe::StripeObject
class Kana < Stripe::StripeObject
# The person's first or given name.
sig { returns(T.nilable(String)) }
attr_reader :given_name
# The person's last or family name.
sig { returns(T.nilable(String)) }
attr_reader :surname
end
class Kanji < Stripe::StripeObject
# The person's first or given name.
sig { returns(T.nilable(String)) }
attr_reader :given_name
# The person's last or family name.
sig { returns(T.nilable(String)) }
attr_reader :surname
end
# Persons name in kana script.
sig { returns(T.nilable(Kana)) }
attr_reader :kana
# Persons name in kanji script.
sig { returns(T.nilable(Kanji)) }
attr_reader :kanji
end
# The account ID which the individual belongs to.
sig { returns(String) }
attr_reader :account
# Additional addresses associated with the person.
sig { returns(T.nilable(T::Array[AdditionalAddress])) }
attr_reader :additional_addresses
# Additional names (e.g. aliases) associated with the person.
sig { returns(T.nilable(T::Array[AdditionalName])) }
attr_reader :additional_names
# Attestations of accepted terms of service agreements.
sig { returns(T.nilable(AdditionalTermsOfService)) }
attr_reader :additional_terms_of_service
# The person's residential address.
sig { returns(T.nilable(Address)) }
attr_reader :address
# Time at which the object was created. Represented as a RFC 3339 date & time UTC value in millisecond precision, for example: 2022-09-18T13:22:18.123Z.
sig { returns(String) }
attr_reader :created
# The person's date of birth.
sig { returns(T.nilable(DateOfBirth)) }
attr_reader :date_of_birth
# Documents that may be submitted to satisfy various informational requests.
sig { returns(T.nilable(Documents)) }
attr_reader :documents
# The person's email address.
sig { returns(T.nilable(String)) }
attr_reader :email
# The person's first name.
sig { returns(T.nilable(String)) }
attr_reader :given_name
# Unique identifier for the Person.
sig { returns(String) }
attr_reader :id
# The identification numbers (e.g., SSN) associated with the person.
sig { returns(T.nilable(T::Array[IdNumber])) }
attr_reader :id_numbers
# The person's gender (International regulations require either "male" or "female").
sig { returns(T.nilable(String)) }
attr_reader :legal_gender
# Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# The countries where the person is a national. Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(T::Array[String])) }
attr_reader :nationalities
# String representing the object's type. Objects of the same type share the same value of the object field.
sig { returns(String) }
attr_reader :object
# The person's phone number.
sig { returns(T.nilable(String)) }
attr_reader :phone
# The person's political exposure.
sig { returns(T.nilable(String)) }
attr_reader :political_exposure
# The relationship that this person has with the Account's business or legal entity.
sig { returns(T.nilable(Relationship)) }
attr_reader :relationship
# The script addresses (e.g., non-Latin characters) associated with the person.
sig { returns(T.nilable(ScriptAddresses)) }
attr_reader :script_addresses
# The script names (e.g. non-Latin characters) associated with the person.
sig { returns(T.nilable(ScriptNames)) }
attr_reader :script_names
# The person's last name.
sig { returns(T.nilable(String)) }
attr_reader :surname
# Time at which the object was last updated. Represented as a RFC 3339 date & time UTC value in millisecond precision, for example: 2022-09-18T13:22:18.123Z.
sig { returns(String) }
attr_reader :updated
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
end
end
end
end
# typed: true
module Stripe
module V2
module MoneyManagement
# Adjustments represent Stripe-initiated credits or debits to a user balance. They might be used to amend balances due to technical or operational error.
class Adjustment < APIResource
class AdjustedFlow < Stripe::StripeObject
# Closed Enum. If applicable, the type of flow linked to this Adjustment. The field matching this value will contain the ID of the flow.
sig { returns(String) }
attr_reader :type
# If applicable, the ID of the Adjustment linked to this Adjustment.
sig { returns(T.nilable(String)) }
attr_reader :adjustment
# If applicable, the ID of the InboundTransfer linked to this Adjustment.
sig { returns(T.nilable(String)) }
attr_reader :inbound_transfer
# If applicable, the ID of the OutboundPayment linked to this Adjustment.
sig { returns(T.nilable(String)) }
attr_reader :outbound_payment
# If applicable, the ID of the OutboundTransfer linked to this Adjustment.
sig { returns(T.nilable(String)) }
attr_reader :outbound_transfer
# If applicable, the ID of the ReceivedCredit linked to this Adjustment.
sig { returns(T.nilable(String)) }
attr_reader :received_credit
# If applicable, the ID of the ReceivedDebit linked to this Adjustment.
sig { returns(T.nilable(String)) }
attr_reader :received_debit
end
# If applicable, contains information about the original flow linked to this Adjustment.
sig { returns(T.nilable(AdjustedFlow)) }
attr_reader :adjusted_flow
# The amount of the Adjustment.
sig { returns(Stripe::V2::Amount) }
attr_reader :amount
# Time at which the object was created. Represented as a RFC 3339 date & time UTC value in millisecond precision, for example: 2022-09-18T13:22:18.123Z.
sig { returns(String) }
attr_reader :created
# Description of the Adjustment and what it was used for.
sig { returns(T.nilable(String)) }
attr_reader :description
# The FinancialAccount that this adjustment is for.
sig { returns(String) }
attr_reader :financial_account
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# String representing the object's type. Objects of the same type share the same value of the object field.
sig { returns(String) }
attr_reader :object
# A link to the Stripe-hosted receipt that is provided when money movement is considered regulated under Stripe’s money transmission licenses. The receipt link remains active for 60 days from the Adjustment creation date. After this period, the link will expire and the receipt url value will be null.
sig { returns(T.nilable(String)) }
attr_reader :receipt_url
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
end
end
end
end
# typed: true
module Stripe
module V2
module Billing
class MeterEventSession < APIResource
# The authentication token for this session. Use this token when calling the
# high-throughput meter event API.
sig { returns(String) }
attr_reader :authentication_token
# The creation time of this session.
sig { returns(String) }
attr_reader :created
# The time at which this session will expire.
sig { returns(String) }
attr_reader :expires_at
# The unique id of this auth session.
sig { returns(String) }
attr_reader :id
# String representing the object's type. Objects of the same type share the same value of the object field.
sig { returns(String) }
attr_reader :object
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
end
end
end
end
# typed: true
module Stripe
module V2
module Billing
class MeterEventAdjustment < APIResource
class Cancel < Stripe::StripeObject
# Unique identifier for the event. You can only cancel events within 24 hours of Stripe receiving them.
sig { returns(String) }
attr_reader :identifier
end
# Specifies which event to cancel.
sig { returns(Cancel) }
attr_reader :cancel
# The time the adjustment was created.
sig { returns(String) }
attr_reader :created
# The name of the meter event. Corresponds with the `event_name` field on a meter.
sig { returns(String) }
attr_reader :event_name
# The unique id of this meter event adjustment.
sig { returns(String) }
attr_reader :id
# String representing the object's type. Objects of the same type share the same value of the object field.
sig { returns(String) }
attr_reader :object
# Open Enum. The meter event adjustment’s status.
sig { returns(String) }
attr_reader :status
# Open Enum. Specifies whether to cancel a single event or a range of events for a time period. Time period cancellation is not supported yet.
sig { returns(String) }
attr_reader :type
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
end
end
end
end
# typed: true
module Stripe
module V2
module Billing
# Fix me empty_doc_string.
class MeterEvent < APIResource
# The creation time of this meter event.
sig { returns(String) }
attr_reader :created
# The name of the meter event. Corresponds with the `event_name` field on a meter.
sig { returns(String) }
attr_reader :event_name
# A unique identifier for the event. If not provided, one will be generated. We recommend using a globally unique identifier for this. We’ll enforce uniqueness within a rolling 24 hour period.
sig { returns(String) }
attr_reader :identifier
# String representing the object's type. Objects of the same type share the same value of the object field.
sig { returns(String) }
attr_reader :object
# The payload of the event. This must contain the fields corresponding to a meter’s
# `customer_mapping.event_payload_key` (default is `stripe_customer_id`) and
# `value_settings.event_payload_key` (default is `value`). Read more about the payload.
sig { returns(T::Hash[String, String]) }
attr_reader :payload
# The time of the event. Must be within the past 35 calendar days or up to
# 5 minutes in the future. Defaults to current timestamp if not specified.
sig { returns(String) }
attr_reader :timestamp
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
end
end
end
end
# typed: true
module Stripe
module V2
module MoneyManagement
# The Financial Account is the container that allows for the configuration of money movement.
class FinancialAccount < APIResource
class Balance < Stripe::StripeObject
# Balance that can be used for money movement.
sig { returns(T::Hash[String, Stripe::V2::Amount]) }
attr_reader :available
# Balance of inbound funds that will later transition to the `cash` balance.
sig { returns(T::Hash[String, Stripe::V2::Amount]) }
attr_reader :inbound_pending
# Balance of funds that are being used for a pending outbound money movement.
sig { returns(T::Hash[String, Stripe::V2::Amount]) }
attr_reader :outbound_pending
end
class Other < Stripe::StripeObject
# The type of the FinancialAccount, represented as a string. Upgrade your API version to see the type reflected in `financial_account.type`.
sig { returns(String) }
attr_reader :type
end
class Storage < Stripe::StripeObject
# The currencies that this FinancialAccount can hold.
sig { returns(T::Array[String]) }
attr_reader :holds_currencies
end
# Multi-currency balance of this FinancialAccount, split by availability state. Each balance is represented as a hash where the key is the three-letter ISO currency code, in lowercase, and the value is the amount for that currency.
sig { returns(Balance) }
attr_reader :balance
# Open Enum. Two-letter country code that represents the country where the LegalEntity associated with the FinancialAccount is based in.
sig { returns(String) }
attr_reader :country
# Time at which the object was created.
sig { returns(String) }
attr_reader :created
# Attribute for field description
sig { returns(T.nilable(String)) }
attr_reader :description
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# String representing the object's type. Objects of the same type share the same value of the object field.
sig { returns(String) }
attr_reader :object
# If this is a `other` FinancialAccount, this hash indicates what the actual type is. Upgrade your API version to see it reflected in `type`.
sig { returns(T.nilable(Other)) }
attr_reader :other
# Closed Enum. An enum representing the status of the FinancialAccount. This indicates whether or not the FinancialAccount can be used for any money movement flows.
sig { returns(String) }
attr_reader :status
# If this is a `storage` FinancialAccount, this hash includes details specific to `storage` FinancialAccounts.
sig { returns(T.nilable(Storage)) }
attr_reader :storage
# Type of the FinancialAccount. An additional hash is included on the FinancialAccount with a name matching this value.
# It contains additional information specific to the FinancialAccount type.
sig { returns(String) }
attr_reader :type
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
end
end
end
end
# typed: true
module Stripe
module V2
module MoneyManagement
# A FinancialAddress contains information needed to transfer money to a Financial Account. A Financial Account can have more than one Financial Address.
class FinancialAddress < APIResource
class Credentials < Stripe::StripeObject
class GbBankAccount < Stripe::StripeObject
# The account holder name to be used during bank transference.
sig { returns(String) }
attr_reader :account_holder_name
# The account number of the UK Bank Account.
sig { returns(T.nilable(String)) }
attr_reader :account_number
# The last four digits of the UK Bank Account number. This will always be returned.
# To view the full account number when retrieving or listing FinancialAddresses, use the `include` request parameter.
sig { returns(String) }
attr_reader :last4
# The sort code of the UK Bank Account.
sig { returns(String) }
attr_reader :sort_code
end
class UsBankAccount < Stripe::StripeObject
# The account number of the US Bank Account.
sig { returns(T.nilable(String)) }
attr_reader :account_number
# The name of the Bank.
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# The last four digits of the US Bank Account number. This will always be returned.
# To view the full account number when retrieving or listing FinancialAddresses, use the `include` request parameter.
sig { returns(String) }
attr_reader :last4
# The routing number of the US Bank Account.
sig { returns(String) }
attr_reader :routing_number
# The swift code of the bank or financial institution.
sig { returns(T.nilable(String)) }
attr_reader :swift_code
end
# Open Enum. The type of Credentials that are provisioned for the FinancialAddress.
sig { returns(String) }
attr_reader :type
# The credentials of the UK Bank Account for the FinancialAddress. This contains unique banking details such as the sort code, account number, etc. of a UK bank account.
sig { returns(T.nilable(GbBankAccount)) }
attr_reader :gb_bank_account
# The credentials of the US Bank Account for the FinancialAddress. This contains unique banking details such as the routing number, account number, etc. of a US bank account.
sig { returns(T.nilable(UsBankAccount)) }
attr_reader :us_bank_account
end
# The creation timestamp of the FinancialAddress.
sig { returns(String) }
attr_reader :created
# Object indicates the type of credentials that have been allocated and attached to the FinancialAddress.
# It contains all necessary banking details with which to perform money movements with the FinancialAddress.
# This field is only available for FinancialAddresses with an active status.
sig { returns(T.nilable(Credentials)) }
attr_reader :credentials
# Open Enum. The currency the FinancialAddress supports.
sig { returns(String) }
attr_reader :currency
# A ID of the FinancialAccount this FinancialAddress corresponds to.
sig { returns(String) }
attr_reader :financial_account
# The ID of a FinancialAddress.
sig { returns(String) }
attr_reader :id
# String representing the object's type. Objects of the same type share the same value of the object field.
sig { returns(String) }
attr_reader :object
# Closed Enum. An enum representing the status of the FinancialAddress. This indicates whether or not the FinancialAddress can be used for any money movement flows.
sig { returns(String) }
attr_reader :status
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
end
end
end
end
# typed: true
module Stripe
module V2
class FinancialAddressCreditSimulation < APIResource
# String representing the object's type. Objects of the same type share the same value of the object field.
sig { returns(String) }
attr_reader :object
# The status of the request, signifying whether a simulated credit was initiated.
sig { returns(String) }
attr_reader :status
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
end
end
end
# typed: true
module Stripe
module V2
class FinancialAddressGeneratedMicrodeposits < APIResource
# The amounts of the microdeposits that were generated.
sig { returns(T::Array[Stripe::V2::Amount]) }
attr_reader :amounts
# String representing the object's type. Objects of the same type share the same value of the object field.
sig { returns(String) }
attr_reader :object
# Closed Enum. The status of the request.
sig { returns(String) }
attr_reader :status
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
end
end
end
# typed: true
module Stripe
module V2
module MoneyManagement
# An InboundTransfer object, representing a money movement from a
# user owned PaymentMethod to a FinancialAccount belonging to the same user.
class InboundTransfer < APIResource
class From < Stripe::StripeObject
class PaymentMethod < Stripe::StripeObject
# The type of object this destination represents. For a us bank account, we expect us_bank_account.
sig { returns(String) }
attr_reader :type
# The destination US bank account identifier. eg "usba_***".
sig { returns(T.nilable(String)) }
attr_reader :us_bank_account
end
# The amount in specified currency that was debited from the Payment Method.
sig { returns(Stripe::V2::Amount) }
attr_reader :debited
# The Payment Method object used to create the InboundTransfer.
sig { returns(PaymentMethod) }
attr_reader :payment_method
end
class To < Stripe::StripeObject
# The amount by which the FinancialAccount balance is credited.
sig { returns(Stripe::V2::Amount) }
attr_reader :credited
# The FinancialAccount that funds will land in.
sig { returns(String) }
attr_reader :financial_account
end
class TransferHistory < Stripe::StripeObject
class BankDebitFailed < Stripe::StripeObject
# Open Enum. The return reason for the failed InboundTransfer.
sig { returns(String) }
attr_reader :failure_reason
end
class BankDebitProcessing < Stripe::StripeObject; end
class BankDebitQueued < Stripe::StripeObject; end
class BankDebitReturned < Stripe::StripeObject
# Open Enum. The return reason for the returned InboundTransfer.
sig { returns(String) }
attr_reader :return_reason
end
class BankDebitSucceeded < Stripe::StripeObject; end
# Creation time of the HistoryEntry in RFC 3339 format and UTC.
sig { returns(String) }
attr_reader :created
# Effective at time of the HistoryEntry in RFC 3339 format and UTC.
sig { returns(String) }
attr_reader :effective_at
# A unique ID for the HistoryEntry.
sig { returns(String) }
attr_reader :id
# Open Enum. The Level of the HistoryEntry.
sig { returns(String) }
attr_reader :level
# Open Enum. The type of the HistoryEntry.
sig { returns(String) }
attr_reader :type
# The history entry for a failed InboundTransfer.
sig { returns(T.nilable(BankDebitFailed)) }
attr_reader :bank_debit_failed
# The history entry for a processing InboundTransfer.
sig { returns(T.nilable(BankDebitProcessing)) }
attr_reader :bank_debit_processing
# The history entry for a queued InboundTransfer.
sig { returns(T.nilable(BankDebitQueued)) }
attr_reader :bank_debit_queued
# The history entry for a returned InboundTransfer.
sig { returns(T.nilable(BankDebitReturned)) }
attr_reader :bank_debit_returned
# The history entry for a succeeded InboundTransfer.
sig { returns(T.nilable(BankDebitSucceeded)) }
attr_reader :bank_debit_succeeded
end
# The amount in specified currency that will land in the FinancialAccount balance.
sig { returns(Stripe::V2::Amount) }
attr_reader :amount
# Creation time of the InboundTransfer. Represented as a RFC 3339 date & time UTC value in millisecond precision, for example: 2022-09-18T13:22:18.123Z.
sig { returns(String) }
attr_reader :created
# A freeform text field provided by user, containing metadata.
sig { returns(String) }
attr_reader :description
# A nested object containing information about the origin of the InboundTransfer.
sig { returns(From) }
attr_reader :from
# Unique identifier for the InboundTransfer.
sig { returns(String) }
attr_reader :id
# String representing the object's type. Objects of the same type share the same value of the object field.
sig { returns(String) }
attr_reader :object
# A hosted transaction receipt URL that is provided when money movement is considered regulated under Stripe’s money transmission licenses.
sig { returns(T.nilable(String)) }
attr_reader :receipt_url
# A nested object containing information about the destination of the InboundTransfer.
sig { returns(To) }
attr_reader :to
# A list of history objects, representing changes in the state of the InboundTransfer.
sig { returns(T::Array[TransferHistory]) }
attr_reader :transfer_history
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
end
end
end
end
# typed: true
module Stripe
module V2
# Set up an event destination to receive events from Stripe across multiple destination types, including [webhook endpoints](https://docs.stripe.com/webhooks) and [Amazon EventBridge](https://docs.stripe.com/event-destinations/eventbridge). Event destinations support receiving [thin events](https://docs.stripe.com/api/v2/events) and [snapshot events](https://docs.stripe.com/api/events).
class EventDestination < APIResource
class StatusDetails < Stripe::StripeObject
class Disabled < Stripe::StripeObject
# Reason event destination has been disabled.
sig { returns(String) }
attr_reader :reason
end
# Details about why the event destination has been disabled.
sig { returns(T.nilable(Disabled)) }
attr_reader :disabled
end
class AmazonEventbridge < Stripe::StripeObject
# The AWS account ID.
sig { returns(String) }
attr_reader :aws_account_id
# The ARN of the AWS event source.
sig { returns(String) }
attr_reader :aws_event_source_arn
# The state of the AWS event source.
sig { returns(String) }
attr_reader :aws_event_source_status
end
class WebhookEndpoint < Stripe::StripeObject
# The signing secret of the webhook endpoint, only includable on creation.
sig { returns(T.nilable(String)) }
attr_reader :signing_secret
# The URL of the webhook endpoint, includable.
sig { returns(T.nilable(String)) }
attr_reader :url
end
# Time at which the object was created.
sig { returns(String) }
attr_reader :created
# An optional description of what the event destination is used for.
sig { returns(String) }
attr_reader :description
# The list of events to enable for this endpoint.
sig { returns(T::Array[String]) }
attr_reader :enabled_events
# Payload type of events being subscribed to.
sig { returns(String) }
attr_reader :event_payload
# Where events should be routed from.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :events_from
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Metadata.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# Event destination name.
sig { returns(String) }
attr_reader :name
# String representing the object's type. Objects of the same type share the same value of the object field.
sig { returns(String) }
attr_reader :object
# If using the snapshot event payload, the API version events are rendered as.
sig { returns(T.nilable(String)) }
attr_reader :snapshot_api_version
# Status. It can be set to either enabled or disabled.
sig { returns(String) }
attr_reader :status
# Additional information about event destination status.
sig { returns(T.nilable(StatusDetails)) }
attr_reader :status_details
# Event destination type.
sig { returns(String) }
attr_reader :type
# Time at which the object was last updated.
sig { returns(String) }
attr_reader :updated
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# Amazon EventBridge configuration.
sig { returns(T.nilable(AmazonEventbridge)) }
attr_reader :amazon_eventbridge
# Webhook endpoint configuration.
sig { returns(T.nilable(WebhookEndpoint)) }
attr_reader :webhook_endpoint
end
end
end
# typed: true
module Stripe
module V2
# Events are generated to keep you informed of activity in your business account. APIs in the /v2 namespace generate [thin events](https://docs.stripe.com/event-destinations#benefits-of-thin-events) which have small, unversioned payloads that include a reference to the ID of the object that has changed. The Events v2 API returns these new thin events. [Retrieve the event object](https://docs.stripe.com/event-destinations#fetch-data) for additional data about the event. Use the related object ID in the event payload to [fetch the API resource](https://docs.stripe.com/event-destinations#retrieve-the-object-associated-with-thin-events) of the object associated with the event. Comparatively, events generated by most API v1 include a versioned snapshot of an API object in their payload.
class Event < APIResource
class Reason < Stripe::StripeObject
class Request < Stripe::StripeObject
# ID of the API request that caused the event.
sig { returns(String) }
attr_reader :id
# The idempotency key transmitted during the request.
sig { returns(String) }
attr_reader :idempotency_key
end
# Event reason type.
sig { returns(String) }
attr_reader :type
# Information on the API request that instigated the event.
sig { returns(T.nilable(Request)) }
attr_reader :request
end
# Authentication context needed to fetch the event or related object.
sig { returns(T.nilable(String)) }
attr_reader :context
# Time at which the object was created.
sig { returns(String) }
attr_reader :created
# Unique identifier for the event.
sig { returns(String) }
attr_reader :id
# String representing the object's type. Objects of the same type share the same value of the object field.
sig { returns(String) }
attr_reader :object
# Reason for the event.
sig { returns(T.nilable(Reason)) }
attr_reader :reason
# The type of the event.
sig { returns(String) }
attr_reader :type
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
end
end
end
# typed: true
module Stripe
module V2
module Payments
# Off-session payment resource.
class OffSessionPayment < APIResource
class RetryDetails < Stripe::StripeObject
# Number of authorization attempts so far.
sig { returns(Integer) }
attr_reader :attempts
# How you want Stripe to retry the payment.
sig { returns(String) }
attr_reader :retry_strategy
end
class TransferData < Stripe::StripeObject
# Amount in minor units that you want to transfer.
sig { returns(Integer) }
attr_reader :amount
# ID of the connected account where you want money to go.
sig { returns(String) }
attr_reader :destination
end
# The amount you requested to be collected on the OSP upon creation.
sig { returns(Stripe::V2::Amount) }
attr_reader :amount_requested
# Number of authorization attempts.
sig { returns(Integer) }
attr_reader :attempts
# The frequency of the underlying payment that this OSP represents.
sig { returns(String) }
attr_reader :cadence
# ID of owning compartment.
sig { returns(String) }
attr_reader :compartment_id
# Timestamp of creation.
sig { returns(String) }
attr_reader :created
# Customer owning the supplied payment method.
sig { returns(String) }
attr_reader :customer
# Reason why the OSP failed.
sig { returns(T.nilable(String)) }
attr_reader :failure_reason
# ID of the OSP.
sig { returns(String) }
attr_reader :id
# Last error returned by the financial partner for a failed authorization.
sig { returns(T.nilable(String)) }
attr_reader :last_authorization_attempt_error
# Payment attempt record for the latest attempt, if one exists.
sig { returns(T.nilable(String)) }
attr_reader :latest_payment_attempt_record
# True if the txn is livemode, false otherwise.
sig { returns(T::Boolean) }
attr_reader :livemode
# Metadata you provided.
sig { returns(T::Hash[String, String]) }
attr_reader :metadata
# String representing the object's type. Objects of the same type share the same value of the object field.
sig { returns(String) }
attr_reader :object
# OBO, same as on the PI.
sig { returns(T.nilable(String)) }
attr_reader :on_behalf_of
# ID of payment method.
sig { returns(String) }
attr_reader :payment_method
# Payment record associated with the OSP. consistent across attempts.
sig { returns(T.nilable(String)) }
attr_reader :payment_record
# Details about the OSP retries.
sig { returns(RetryDetails) }
attr_reader :retry_details
# Statement descriptor you provided.
sig { returns(T.nilable(String)) }
attr_reader :statement_descriptor
# Statement descriptor suffix you provided, similar to that on the PI.
sig { returns(T.nilable(String)) }
attr_reader :statement_descriptor_suffix
# Status of the OSP.
sig { returns(String) }
attr_reader :status
# Test clock to be used to advance the retry attempts.
sig { returns(T.nilable(String)) }
attr_reader :test_clock
# Instructions for the transfer to be made with this OSP after successful money movement.
sig { returns(T.nilable(TransferData)) }
attr_reader :transfer_data
end
end
end
end
# typed: true
module Stripe
module V2
module MoneyManagement
# OutboundPayment represents a single money movement from one FinancialAccount you own to a payout method someone else owns.
class OutboundPayment < APIResource
class DeliveryOptions < Stripe::StripeObject
# Open Enum. Method for bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_account
end
class From < Stripe::StripeObject
# The monetary amount debited from the sender, only set on responses.
sig { returns(Stripe::V2::Amount) }
attr_reader :debited
# The FinancialAccount that funds were pulled from.
sig { returns(String) }
attr_reader :financial_account
end
class RecipientNotification < Stripe::StripeObject
# Closed Enum. Configuration option to enable or disable notifications to recipients.
# Do not send notifications when setting is NONE. Default to account setting when setting is CONFIGURED or not set.
sig { returns(String) }
attr_reader :setting
end
class StatusDetails < Stripe::StripeObject
class Failed < Stripe::StripeObject
# Open Enum. The `failed` status reason.
sig { returns(String) }
attr_reader :reason
end
class Returned < Stripe::StripeObject
# Open Enum. The `returned` status reason.
sig { returns(String) }
attr_reader :reason
end
# The `failed` status reason.
sig { returns(T.nilable(Failed)) }
attr_reader :failed
# The `returned` status reason.
sig { returns(T.nilable(Returned)) }
attr_reader :returned
end
class StatusTransitions < Stripe::StripeObject
# Timestamp describing when an OutboundPayment changed status to `canceled`.
# Represented as a RFC 3339 date & time UTC value in millisecond precision, for example: 2022-09-18T13:22:18.123Z.
sig { returns(T.nilable(String)) }
attr_reader :canceled_at
# Timestamp describing when an OutboundPayment changed status to `failed`.
# Represented as a RFC 3339 date & time UTC value in millisecond precision, for example: 2022-09-18T13:22:18.123Z.
sig { returns(T.nilable(String)) }
attr_reader :failed_at
# Timestamp describing when an OutboundPayment changed status to `posted`.
# Represented as a RFC 3339 date & time UTC value in millisecond precision, for example: 2022-09-18T13:22:18.123Z.
sig { returns(T.nilable(String)) }
attr_reader :posted_at
# Timestamp describing when an OutboundPayment changed status to `returned`.
# Represented as a RFC 3339 date & time UTC value in millisecond precision, for example: 2022-09-18T13:22:18.123Z.
sig { returns(T.nilable(String)) }
attr_reader :returned_at
end
class To < Stripe::StripeObject
# The monetary amount being credited to the destination.
sig { returns(Stripe::V2::Amount) }
attr_reader :credited
# The payout method which the OutboundPayment uses to send payout.
sig { returns(String) }
attr_reader :payout_method
# To which account the OutboundPayment is sent.
sig { returns(String) }
attr_reader :recipient
end
class TraceId < Stripe::StripeObject
# Possible values are `pending`, `supported`, and `unsupported`. Initially set to `pending`, it changes to
# `supported` when the recipient bank provides a trace ID, or `unsupported` if the recipient bank doesn't support it.
# Note that this status may not align with the OutboundPayment or OutboundTransfer status and can remain `pending`
# even after the payment or transfer is posted.
sig { returns(String) }
attr_reader :status
# The trace ID value if `trace_id.status` is `supported`, otherwise empty.
sig { returns(T.nilable(String)) }
attr_reader :value
end
# The "presentment amount" for the OutboundPayment.
sig { returns(Stripe::V2::Amount) }
attr_reader :amount
# Returns true if the OutboundPayment can be canceled, and false otherwise.
sig { returns(T::Boolean) }
attr_reader :cancelable
# Time at which the OutboundPayment was created.
# Represented as a RFC 3339 date & time UTC value in millisecond precision, for example: 2022-09-18T13:22:18.123Z.
sig { returns(String) }
attr_reader :created
# Delivery options to be used to send the OutboundPayment.
sig { returns(T.nilable(DeliveryOptions)) }
attr_reader :delivery_options
# An arbitrary string attached to the OutboundPayment. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_reader :description
# The date when funds are expected to arrive in the payout method. This field is not set if the payout method is in a `failed`, `canceled`, or `returned` state.
# Represented as a RFC 3339 date & time UTC value in millisecond precision, for example: 2022-09-18T13:22:18.123Z.
sig { returns(T.nilable(String)) }
attr_reader :expected_arrival_date
# The FinancialAccount that funds were pulled from.
sig { returns(From) }
attr_reader :from
# Unique identifier for the OutboundPayment.
sig { returns(String) }
attr_reader :id
# Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# String representing the object's type. Objects of the same type share the same value of the object field.
sig { returns(String) }
attr_reader :object
# The quote for this OutboundPayment. Only required for countries with regulatory mandates to display fee estimates before OutboundPayment creation.
sig { returns(T.nilable(String)) }
attr_reader :outbound_payment_quote
# A link to the Stripe-hosted receipt for this OutboundPayment. The receipt link remains active for 60 days from the OutboundPayment creation date. After this period, the link will expire and the receipt url value will be null.
sig { returns(T.nilable(String)) }
attr_reader :receipt_url
# Details about the OutboundPayment notification settings for recipient.
sig { returns(RecipientNotification) }
attr_reader :recipient_notification
# The description that appears on the receiving end for an OutboundPayment (for example, bank statement for external bank transfer).
sig { returns(String) }
attr_reader :statement_descriptor
# Closed Enum. Current status of the OutboundPayment: `processing`, `failed`, `posted`, `returned`, `canceled`.
# An OutboundPayment is `processing` if it has been created and is processing.
# The status changes to `posted` once the OutboundPayment has been "confirmed" and funds have left the account, or to `failed` or `canceled`.
# If an OutboundPayment fails to arrive at its payout method, its status will change to `returned`.
sig { returns(String) }
attr_reader :status
# Status details for an OutboundPayment in a `failed` or `returned` state.
sig { returns(T.nilable(StatusDetails)) }
attr_reader :status_details
# Hash containing timestamps of when the object transitioned to a particular status.
sig { returns(T.nilable(StatusTransitions)) }
attr_reader :status_transitions
# To which payout method the OutboundPayment was sent.
sig { returns(To) }
attr_reader :to
# A unique identifier that can be used to track this OutboundPayment with recipient bank. Banks might call this a “reference number” or something similar.
sig { returns(TraceId) }
attr_reader :trace_id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
end
end
end
end
# typed: true
module Stripe
module V2
module MoneyManagement
# OutboundPaymentQuote represents a quote
class OutboundPaymentQuote < APIResource
class DeliveryOptions < Stripe::StripeObject
# Open Enum. Method for bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_account
end
class EstimatedFee < Stripe::StripeObject
# The fee amount for corresponding fee type.
sig { returns(Stripe::V2::Amount) }
attr_reader :amount
# The fee type.
sig { returns(String) }
attr_reader :type
end
class From < Stripe::StripeObject
# The monetary amount debited from the sender, only set on responses.
sig { returns(Stripe::V2::Amount) }
attr_reader :debited
# The FinancialAccount that funds were pulled from.
sig { returns(String) }
attr_reader :financial_account
end
class FxQuote < Stripe::StripeObject
class Rates < Stripe::StripeObject
# The exchange rate going from_currency -> to_currency.
sig { returns(String) }
attr_reader :exchange_rate
end
# The duration the exchange rate lock remains valid from creation time. Allowed value is five_minutes.
sig { returns(String) }
attr_reader :lock_duration
# Time at which the rate lock will expire, measured in seconds since the Unix epoch.
sig { returns(String) }
attr_reader :lock_expires_at
# Lock status of the quote. Transitions from active to expired once past the lock_expires_at timestamp. Value can be active or expired.
sig { returns(String) }
attr_reader :lock_status
# Key pair: from currency Value: exchange rate going from_currency -> to_currency.
sig { returns(T::Hash[String, Rates]) }
attr_reader :rates
# The currency that the transaction is exchanging to.
sig { returns(String) }
attr_reader :to_currency
end
class To < Stripe::StripeObject
# The monetary amount being credited to the destination.
sig { returns(Stripe::V2::Amount) }
attr_reader :credited
# The payout method which the OutboundPayment uses to send payout.
sig { returns(String) }
attr_reader :payout_method
# To which account the OutboundPayment is sent.
sig { returns(String) }
attr_reader :recipient
end
# The "presentment amount" for the OutboundPaymentQuote.
sig { returns(Stripe::V2::Amount) }
attr_reader :amount
# Time at which the OutboundPaymentQuote was created.
# Represented as a RFC 3339 date & time UTC value in millisecond precision, for example: 2022-09-18T13:22:18.123Z.
sig { returns(String) }
attr_reader :created
# Delivery options to be used to send the OutboundPayment.
sig { returns(T.nilable(DeliveryOptions)) }
attr_reader :delivery_options
# The estimated fees for the OutboundPaymentQuote.
sig { returns(T::Array[EstimatedFee]) }
attr_reader :estimated_fees
# Details about the sender of an OutboundPaymentQuote.
sig { returns(From) }
attr_reader :from
# The underlying FXQuote details for the OutboundPaymentQuote.
sig { returns(FxQuote) }
attr_reader :fx_quote
# Unique identifier for the OutboundPaymentQuote.
sig { returns(String) }
attr_reader :id
# String representing the object's type. Objects of the same type share the same value of the object field.
sig { returns(String) }
attr_reader :object
# Details about the recipient of an OutboundPaymentQuote.
sig { returns(To) }
attr_reader :to
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
end
end
end
end
# typed: true
module Stripe
module V2
module MoneyManagement
# OutboundTransfer represents a single money movement from one FinancialAccount you own to a payout method you also own.
class OutboundTransfer < APIResource
class DeliveryOptions < Stripe::StripeObject
# Open Enum. Method for bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_account
end
class From < Stripe::StripeObject
# The monetary amount debited from the sender, only set on responses.
sig { returns(Stripe::V2::Amount) }
attr_reader :debited
# The FinancialAccount that funds were pulled from.
sig { returns(String) }
attr_reader :financial_account
end
class StatusDetails < Stripe::StripeObject
class Failed < Stripe::StripeObject
# Open Enum. The `failed` status reason.
sig { returns(String) }
attr_reader :reason
end
class Returned < Stripe::StripeObject
# Open Enum. The `returned` status reason.
sig { returns(String) }
attr_reader :reason
end
# The `failed` status reason.
sig { returns(T.nilable(Failed)) }
attr_reader :failed
# The `returned` status reason.
sig { returns(T.nilable(Returned)) }
attr_reader :returned
end
class StatusTransitions < Stripe::StripeObject
# Timestamp describing when an OutboundTransfer changed status to `canceled`.
# Represented as a RFC 3339 date & time UTC value in millisecond precision, for example: 2022-09-18T13:22:18.123Z.
sig { returns(T.nilable(String)) }
attr_reader :canceled_at
# Timestamp describing when an OutboundTransfer changed status to `failed`.
# Represented as a RFC 3339 date & time UTC value in millisecond precision, for example: 2022-09-18T13:22:18.123Z.
sig { returns(T.nilable(String)) }
attr_reader :failed_at
# Timestamp describing when an OutboundTransfer changed status to `posted`.
# Represented as a RFC 3339 date & time UTC value in millisecond precision, for example: 2022-09-18T13:22:18.123Z.
sig { returns(T.nilable(String)) }
attr_reader :posted_at
# Timestamp describing when an OutboundTransfer changed status to `returned`.
# Represented as a RFC 3339 date & time UTC value in millisecond precision, for example: 2022-09-18T13:22:18.123Z.
sig { returns(T.nilable(String)) }
attr_reader :returned_at
end
class To < Stripe::StripeObject
# The monetary amount being credited to the destination.
sig { returns(Stripe::V2::Amount) }
attr_reader :credited
# The payout method which the OutboundTransfer uses to send payout.
sig { returns(String) }
attr_reader :payout_method
end
class TraceId < Stripe::StripeObject
# Possible values are `pending`, `supported`, and `unsupported`. Initially set to `pending`, it changes to
# `supported` when the recipient bank provides a trace ID, or `unsupported` if the recipient bank doesn't support it.
# Note that this status may not align with the OutboundPayment or OutboundTransfer status and can remain `pending`
# even after the payment or transfer is posted.
sig { returns(String) }
attr_reader :status
# The trace ID value if `trace_id.status` is `supported`, otherwise empty.
sig { returns(T.nilable(String)) }
attr_reader :value
end
# The "presentment amount" for the OutboundTransfer.
sig { returns(Stripe::V2::Amount) }
attr_reader :amount
# Returns true if the OutboundTransfer can be canceled, and false otherwise.
sig { returns(T::Boolean) }
attr_reader :cancelable
# Time at which the OutboundTransfer was created.
# Represented as a RFC 3339 date & time UTC value in millisecond precision, for example: 2022-09-18T13:22:18.123Z.
sig { returns(String) }
attr_reader :created
# Delivery options to be used to send the OutboundTransfer.
sig { returns(T.nilable(DeliveryOptions)) }
attr_reader :delivery_options
# An arbitrary string attached to the OutboundTransfer. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_reader :description
# The date when funds are expected to arrive in the payout method. This field is not set if the payout method is in a `failed`, `canceled`, or `returned` state.
# Represented as a RFC 3339 date & time UTC value in millisecond precision, for example: 2022-09-18T13:22:18.123Z.
sig { returns(T.nilable(String)) }
attr_reader :expected_arrival_date
# The FinancialAccount that funds were pulled from.
sig { returns(From) }
attr_reader :from
# Unique identifier for the OutboundTransfer.
sig { returns(String) }
attr_reader :id
# Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# String representing the object's type. Objects of the same type share the same value of the object field.
sig { returns(String) }
attr_reader :object
# A link to the Stripe-hosted receipt for this OutboundTransfer. The receipt link remains active for 60 days from the OutboundTransfer creation date. After this period, the link will expire and the receipt url value will be null.
sig { returns(T.nilable(String)) }
attr_reader :receipt_url
# The description that appears on the receiving end for an OutboundTransfer (for example, bank statement for external bank transfer).
sig { returns(String) }
attr_reader :statement_descriptor
# Closed Enum. Current status of the OutboundTransfer: `processing`, `failed`, `posted`, `returned`, `canceled`.
# An OutboundTransfer is `processing` if it has been created and is processing.
# The status changes to `posted` once the OutboundTransfer has been "confirmed" and funds have left the account, or to `failed` or `canceled`.
# If an OutboundTransfer fails to arrive at its payout method, its status will change to `returned`.
sig { returns(String) }
attr_reader :status
# Status details for an OutboundTransfer in a `failed` or `returned` state.
sig { returns(T.nilable(StatusDetails)) }
attr_reader :status_details
# Hash containing timestamps of when the object transitioned to a particular status.
sig { returns(T.nilable(StatusTransitions)) }
attr_reader :status_transitions
# To which payout method the OutboundTransfer was sent.
sig { returns(To) }
attr_reader :to
# A unique identifier that can be used to track this OutboundTransfer with recipient bank. Banks might call this a “reference number” or something similar.
sig { returns(TraceId) }
attr_reader :trace_id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
end
end
end
end
# typed: true
module Stripe
module V2
module MoneyManagement
# Use the PayoutMethods API to list and interact with PayoutMethod objects.
class PayoutMethod < APIResource
class UsageStatus < Stripe::StripeObject
# Payments status - used when sending OutboundPayments (sending funds to recipients).
sig { returns(String) }
attr_reader :payments
# Transfers status - used when making an OutboundTransfer (sending funds to yourself).
sig { returns(String) }
attr_reader :transfers
end
class BankAccount < Stripe::StripeObject
# Whether this PayoutMethodBankAccount object was archived. PayoutMethodBankAccount objects can be archived through
# the /archive API, and they will not be automatically archived by Stripe. Archived PayoutMethodBankAccount objects
# cannot be used as payout methods and will not appear in the payout method list.
sig { returns(T::Boolean) }
attr_reader :archived
# The name of the bank this bank account is in. This field is populated automatically by Stripe.
sig { returns(String) }
attr_reader :bank_name
# The country code of the bank account.
sig { returns(String) }
attr_reader :country
# List of enabled flows for this bank account (wire or local).
sig { returns(T::Array[String]) }
attr_reader :enabled_delivery_options
# The last 4 digits of the account number.
sig { returns(String) }
attr_reader :last4
# The routing number of the bank account, if present.
sig { returns(T.nilable(String)) }
attr_reader :routing_number
# The list of currencies supported by this bank account.
sig { returns(T::Array[String]) }
attr_reader :supported_currencies
end
class Card < Stripe::StripeObject
# Whether the PayoutMethodCard object was archived. PayoutMethodCard objects can be archived through
# the /archive API, and they will not be automatically archived by Stripe. Archived PayoutMethodCard objects
# cannot be used as payout methods and will not appear in the payout method list.
sig { returns(T::Boolean) }
attr_reader :archived
# The month the card expires.
sig { returns(String) }
attr_reader :exp_month
# The year the card expires.
sig { returns(String) }
attr_reader :exp_year
# The last 4 digits of the card number.
sig { returns(String) }
attr_reader :last4
end
# A set of available payout speeds for this payout method.
sig { returns(T::Array[String]) }
attr_reader :available_payout_speeds
# Created timestamp.
sig { returns(String) }
attr_reader :created
# ID of the PayoutMethod object.
sig { returns(String) }
attr_reader :id
# ID of the underlying active OutboundSetupIntent object, if any.
sig { returns(T.nilable(String)) }
attr_reader :latest_outbound_setup_intent
# String representing the object's type. Objects of the same type share the same value of the object field.
sig { returns(String) }
attr_reader :object
# Closed Enum. The type of payout method.
sig { returns(String) }
attr_reader :type
# Indicates whether the payout method has met the necessary requirements for outbound money movement.
sig { returns(UsageStatus) }
attr_reader :usage_status
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# The PayoutMethodBankAccount object details.
sig { returns(T.nilable(BankAccount)) }
attr_reader :bank_account
# The PayoutMethodCard object details.
sig { returns(T.nilable(Card)) }
attr_reader :card
end
end
end
end
# typed: true
module Stripe
module V2
module MoneyManagement
# Use the OutboundSetupIntent API to create and setup usable payout methods.
class OutboundSetupIntent < APIResource
class NextAction < Stripe::StripeObject
class ConfirmationOfPayee < Stripe::StripeObject
# The type of the credential.
sig { returns(String) }
attr_reader :object
# The Confirmation of Payee status.
sig { returns(String) }
attr_reader :status
end
# The type of next action.
sig { returns(String) }
attr_reader :type
# Confirmation of Payee details.
sig { returns(T.nilable(ConfirmationOfPayee)) }
attr_reader :confirmation_of_payee
end
# Created timestamp.
sig { returns(String) }
attr_reader :created
# ID of the outbound setup intent.
sig { returns(String) }
attr_reader :id
# Specifies which actions needs to be taken next to continue setup of the credential.
sig { returns(T.nilable(NextAction)) }
attr_reader :next_action
# String representing the object's type. Objects of the same type share the same value of the object field.
sig { returns(String) }
attr_reader :object
# Information about the payout method that’s created and linked to this outbound setup intent.
sig { returns(Stripe::V2::MoneyManagement::PayoutMethod) }
attr_reader :payout_method
# Closed Enum. Status of the outbound setup intent.
sig { returns(String) }
attr_reader :status
# The intended money movement flow this payout method should be set up for, specified in params.
sig { returns(String) }
attr_reader :usage_intent
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
end
end
end
end
# typed: true
module Stripe
module V2
module MoneyManagement
# The PayoutMethodsBankAccountSpec object.
class PayoutMethodsBankAccountSpec < APIResource
class Countries < Stripe::StripeObject
class Field < Stripe::StripeObject
class LocalNameHuman < Stripe::StripeObject
# Attribute for field content
sig { returns(String) }
attr_reader :content
# Attribute for field localization_key
sig { returns(String) }
attr_reader :localization_key
end
# The local name of the field.
sig { returns(String) }
attr_reader :local_name
# The human readable local name of the field.
sig { returns(LocalNameHuman) }
attr_reader :local_name_human
# The maximum length of the field.
sig { returns(Integer) }
attr_reader :max_length
# THe minimum length of the field.
sig { returns(Integer) }
attr_reader :min_length
# The placeholder value of the field.
sig { returns(String) }
attr_reader :placeholder
# The stripe name of the field.
sig { returns(String) }
attr_reader :stripe_name
# The validation regex of the field.
sig { returns(String) }
attr_reader :validation_regex
end
# The list of fields for a country, along with associated information.
sig { returns(T::Array[Field]) }
attr_reader :fields
end
# The list of specs by country.
sig { returns(T::Hash[String, Countries]) }
attr_reader :countries
# String representing the object's type. Objects of the same type share the same value of the object field.
sig { returns(String) }
attr_reader :object
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
end
end
end
end
# typed: true
module Stripe
module V2
module Core
module Vault
# Use the GBBankAccounts API to create and manage GB bank account objects
class GbBankAccount < APIResource
class ConfirmationOfPayee < Stripe::StripeObject
class Result < Stripe::StripeObject
class Matched < Stripe::StripeObject
# The business type given by the bank for this account, in case of a MATCH or PARTIAL_MATCH.
# Closed enum.
sig { returns(T.nilable(String)) }
attr_reader :business_type
# The name given by the bank for this account, in case of a MATCH or PARTIAL_MATCH.
sig { returns(T.nilable(String)) }
attr_reader :name
end
class Provided < Stripe::StripeObject
# The provided or Legal Entity business type to match against the CoP service. Closed enum.
sig { returns(String) }
attr_reader :business_type
# The provided or Legal Entity name to match against the CoP service.
sig { returns(String) }
attr_reader :name
end
# When the CoP result was created.
sig { returns(String) }
attr_reader :created
# Whether or not the information of the bank account matches what you have provided. Closed enum.
sig { returns(String) }
attr_reader :match_result
# The fields that CoP service matched against. Only has value if MATCH or PARTIAL_MATCH, empty otherwise.
sig { returns(Matched) }
attr_reader :matched
# Human-readable message describing the match result.
sig { returns(String) }
attr_reader :message
# The fields that are matched against what the network has on file.
sig { returns(Provided) }
attr_reader :provided
end
# The result of the Confirmation of Payee check, once the check has been initiated. Closed enum.
sig { returns(Result) }
attr_reader :result
# The current state of Confirmation of Payee on this bank account. Closed enum.
sig { returns(String) }
attr_reader :status
end
# Whether this bank account object was archived. Bank account objects can be archived through
# the /archive API, and they will not be automatically archived by Stripe. Archived bank account objects
# cannot be used as outbound destinations and will not appear in the outbound destination list.
sig { returns(T::Boolean) }
attr_reader :archived
# Closed Enum. The type of the bank account (checking or savings).
sig { returns(String) }
attr_reader :bank_account_type
# The name of the bank.
sig { returns(String) }
attr_reader :bank_name
# Information around the status of Confirmation of Payee matching done on this bank account.
# Confirmation of Payee is a name matching service that must be done before making OutboundPayments in the UK.
sig { returns(ConfirmationOfPayee) }
attr_reader :confirmation_of_payee
# Creation time.
sig { returns(String) }
attr_reader :created
# The ID of the GBBankAccount object.
sig { returns(String) }
attr_reader :id
# The last 4 digits of the account number or IBAN.
sig { returns(String) }
attr_reader :last4
# String representing the object's type. Objects of the same type share the same value of the object field.
sig { returns(String) }
attr_reader :object
# The Sort Code of the bank account.
sig { returns(String) }
attr_reader :sort_code
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
end
end
end
end
end
# typed: true
module Stripe
module V2
module Core
module Vault
# Use the USBankAccounts API to create and manage US bank accounts objects that you can use to receive funds. Note that these are not interchangeable with v1 Tokens.
class UsBankAccount < APIResource
# Whether this USBankAccount object was archived.
sig { returns(T::Boolean) }
attr_reader :archived
# Closed Enum. The type of bank account (checking or savings).
sig { returns(String) }
attr_reader :bank_account_type
# The name of the bank this bank account belongs to. This field is populated automatically by Stripe based on the routing number.
sig { returns(String) }
attr_reader :bank_name
# Creation time of the object.
sig { returns(String) }
attr_reader :created
# The fedwire routing number of the bank account.
sig { returns(T.nilable(String)) }
attr_reader :fedwire_routing_number
# The ID of the USBankAccount object.
sig { returns(String) }
attr_reader :id
# The last 4 digits of the account number.
sig { returns(String) }
attr_reader :last4
# String representing the object's type. Objects of the same type share the same value of the object field.
sig { returns(String) }
attr_reader :object
# The ACH routing number of the bank account.
sig { returns(T.nilable(String)) }
attr_reader :routing_number
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
end
end
end
end
end
# typed: true
module Stripe
module V2
module MoneyManagement
# Use ReceivedCredits API to retrieve information on when, where, and how funds are sent into your FinancialAccount.
class ReceivedCredit < APIResource
class StatusDetails < Stripe::StripeObject
class Failed < Stripe::StripeObject
# Open Enum. The `failed` status reason.
sig { returns(String) }
attr_reader :reason
end
class Returned < Stripe::StripeObject
# Open Enum. The `returned` status reason.
sig { returns(String) }
attr_reader :reason
end
# Hash that provides additional information regarding the reason behind a `failed` ReceivedCredit status. It is only present when the ReceivedCredit status is `failed`.
sig { returns(T.nilable(Failed)) }
attr_reader :failed
# Hash that provides additional information regarding the reason behind a `returned` ReceivedCredit status. It is only present when the ReceivedCredit status is `returned`.
sig { returns(T.nilable(Returned)) }
attr_reader :returned
end
class StatusTransitions < Stripe::StripeObject
# Timestamp describing when the ReceivedCredit was marked as `failed`.
# Represented as a RFC 3339 date & time UTC value in millisecond precision, for example: 2022-09-18T13:22:18.123Z.
sig { returns(T.nilable(String)) }
attr_reader :failed_at
# Timestamp describing when the ReceivedCredit changed status to `returned`.
# Represented as a RFC 3339 date & time UTC value in millisecond precision, for example: 2022-09-18T13:22:18.123Z.
sig { returns(T.nilable(String)) }
attr_reader :returned_at
# Timestamp describing when the ReceivedCredit was marked as `succeeded`.
# Represented as a RFC 3339 date & time UTC value in millisecond precision, for example: 2022-09-18T13:22:18.123Z.
sig { returns(T.nilable(String)) }
attr_reader :succeeded_at
end
class BalanceTransfer < Stripe::StripeObject
# The ID of the Stripe Money Movement that originated the ReceivedCredit.
sig { returns(String) }
attr_reader :payout_v1
# Open Enum. The type of Stripe Money Movement that originated the ReceivedCredit.
sig { returns(String) }
attr_reader :type
end
class BankTransfer < Stripe::StripeObject
class GbBankAccount < Stripe::StripeObject
# The bank name the transfer was received from.
sig { returns(T.nilable(String)) }
attr_reader :account_holder_name
# The bank name the transfer was received from.
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# The last 4 digits of the account number that originated the transfer.
sig { returns(T.nilable(String)) }
attr_reader :last4
# Open Enum. The money transmission network used to send funds for this ReceivedCredit.
sig { returns(String) }
attr_reader :network
# The sort code of the account that originated the transfer.
sig { returns(T.nilable(String)) }
attr_reader :sort_code
end
class UsBankAccount < Stripe::StripeObject
# The bank name the transfer was received from.
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# The last 4 digits of the account number that originated the transfer.
sig { returns(T.nilable(String)) }
attr_reader :last4
# Open Enum. The money transmission network used to send funds for this ReceivedCredit.
sig { returns(String) }
attr_reader :network
# The routing number of the account that originated the transfer.
sig { returns(T.nilable(String)) }
attr_reader :routing_number
end
# Financial Address on which funds for ReceivedCredit were received.
sig { returns(String) }
attr_reader :financial_address
# Open Enum. Indicates the type of source via from which external funds originated.
sig { returns(String) }
attr_reader :payment_method_type
# Freeform string set by originator of the external ReceivedCredit.
sig { returns(T.nilable(String)) }
attr_reader :statement_descriptor
# Hash containing the transaction bank details. Present if `payment_method_type` field value is `gb_bank_account`.
sig { returns(T.nilable(GbBankAccount)) }
attr_reader :gb_bank_account
# Hash containing the transaction bank details. Present if `payment_method_type` field value is `us_bank_account`.
sig { returns(T.nilable(UsBankAccount)) }
attr_reader :us_bank_account
end
# The amount and currency of the ReceivedCredit.
sig { returns(Stripe::V2::Amount) }
attr_reader :amount
# Time at which the ReceivedCredit was created.
# Represented as a RFC 3339 date & time UTC value in millisecond precision, for example: 2022-09-18T13:22:18.123Z.
sig { returns(String) }
attr_reader :created
# Freeform string set by originator of the ReceivedCredit.
sig { returns(T.nilable(String)) }
attr_reader :description
# Financial Account ID on which funds for ReceivedCredit were received.
sig { returns(String) }
attr_reader :financial_account
# Unique identifier for the ReceivedCredit.
sig { returns(String) }
attr_reader :id
# String representing the object's type. Objects of the same type share the same value of the object field.
sig { returns(String) }
attr_reader :object
# A hosted transaction receipt URL that is provided when money movement is considered regulated under Stripe’s money transmission licenses.
sig { returns(T.nilable(String)) }
attr_reader :receipt_url
# Open Enum. The status of the ReceivedCredit.
sig { returns(String) }
attr_reader :status
# This hash contains detailed information that elaborates on the specific status of the ReceivedCredit. e.g the reason behind a failure if the status is marked as `failed`.
sig { returns(T.nilable(StatusDetails)) }
attr_reader :status_details
# Hash containing timestamps of when the object transitioned to a particular status.
sig { returns(T.nilable(StatusTransitions)) }
attr_reader :status_transitions
# Open Enum. The type of flow that caused the ReceivedCredit.
sig { returns(String) }
attr_reader :type
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# This object stores details about the originating Stripe transaction that resulted in the ReceivedCredit. Present if `type` field value is `balance_transfer`.
sig { returns(T.nilable(BalanceTransfer)) }
attr_reader :balance_transfer
# This object stores details about the originating banking transaction that resulted in the ReceivedCredit. Present if `type` field value is `external_credit`.
sig { returns(T.nilable(BankTransfer)) }
attr_reader :bank_transfer
end
end
end
end
# typed: true
module Stripe
module V2
module MoneyManagement
# ReceivedDebit resource
class ReceivedDebit < APIResource
class StatusDetails < Stripe::StripeObject
class Failed < Stripe::StripeObject
# Open Enum. The reason for the failure of the ReceivedDebit.
sig { returns(String) }
attr_reader :reason
end
# Information that elaborates on the `failed` status of a ReceivedDebit.
# It is only present when the ReceivedDebit status is `failed`.
sig { returns(Failed) }
attr_reader :failed
end
class StatusTransitions < Stripe::StripeObject
# The time when the ReceivedDebit was marked as `canceled`.
# Represented as a RFC 3339 date & time UTC value in millisecond precision, for example: `2022-09-18T13:22:18.123Z`.
sig { returns(T.nilable(String)) }
attr_reader :canceled_at
# The time when the ReceivedDebit was marked as `failed`.
# Represented as a RFC 3339 date & time UTC value in millisecond precision, for example: `2022-09-18T13:22:18.123Z`.
sig { returns(T.nilable(String)) }
attr_reader :failed_at
# The time when the ReceivedDebit was marked as `succeeded`.
# Represented as a RFC 3339 date & time UTC value in millisecond precision, for example: `2022-09-18T13:22:18.123Z`.
sig { returns(T.nilable(String)) }
attr_reader :succeeded_at
end
class BankTransfer < Stripe::StripeObject
class UsBankAccount < Stripe::StripeObject
# The name of the bank the debit originated from.
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# Open Enum. The bank network the debit was originated on.
sig { returns(String) }
attr_reader :network
# The routing number of the bank that originated the debit.
sig { returns(T.nilable(String)) }
attr_reader :routing_number
end
# The Financial Address that was debited.
sig { returns(String) }
attr_reader :financial_address
# Open Enum. The type of the payment method used to originate the debit.
sig { returns(String) }
attr_reader :payment_method_type
# The statement descriptor set by the originator of the debit.
sig { returns(T.nilable(String)) }
attr_reader :statement_descriptor
# The payment method used to originate the debit.
sig { returns(UsBankAccount) }
attr_reader :us_bank_account
end
# Amount and currency of the ReceivedDebit.
sig { returns(Stripe::V2::Amount) }
attr_reader :amount
# The time at which the ReceivedDebit was created.
# Represented as a RFC 3339 date & time UTC value in millisecond precision, for example: `2022-09-18T13:22:18.123Z`.
sig { returns(String) }
attr_reader :created
# Freeform string sent by the originator of the ReceivedDebit.
sig { returns(T.nilable(String)) }
attr_reader :description
# Financial Account on which funds for ReceivedDebit were debited.
sig { returns(String) }
attr_reader :financial_account
# Unique identifier for the ReceivedDebit.
sig { returns(String) }
attr_reader :id
# String representing the object's type. Objects of the same type share the same value of the object field.
sig { returns(String) }
attr_reader :object
# A link to the Stripe-hosted receipt for this ReceivedDebit.
sig { returns(T.nilable(String)) }
attr_reader :receipt_url
# Open Enum. The status of the ReceivedDebit.
sig { returns(String) }
attr_reader :status
# Detailed information about the status of the ReceivedDebit.
sig { returns(T.nilable(StatusDetails)) }
attr_reader :status_details
# The time at which the ReceivedDebit transitioned to a particular status.
sig { returns(T.nilable(StatusTransitions)) }
attr_reader :status_transitions
# Open Enum. The type of the ReceivedDebit.
sig { returns(String) }
attr_reader :type
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# This object stores details about the originating banking transaction that resulted in the ReceivedDebit. Present if `type` field value is `bank_transfer`.
sig { returns(T.nilable(BankTransfer)) }
attr_reader :bank_transfer
end
end
end
end
# typed: true
module Stripe
module V2
module MoneyManagement
# Use Transactions to view changes to your FinancialAccount balance over time. Every flow that moves money, such as OutboundPayments or ReceivedCredits, will have one or more Transactions that describes how the flow impacted your balance. Note that while the FinancialAccount balance will always be up to date, be aware that Transactions and TransactionEntries are created shortly after to reflect changes.
class Transaction < APIResource
class BalanceImpact < Stripe::StripeObject
# Impact to the available balance.
sig { returns(Stripe::V2::Amount) }
attr_reader :available
# Impact to the inbound_pending balance.
sig { returns(Stripe::V2::Amount) }
attr_reader :inbound_pending
# Impact to the outbound_pending balance.
sig { returns(Stripe::V2::Amount) }
attr_reader :outbound_pending
end
class Flow < Stripe::StripeObject
# Open Enum. Type of the flow that created the Transaction. The field matching this value will contain the ID of the flow.
sig { returns(String) }
attr_reader :type
# If applicable, the ID of the Adjustment that created this Transaction.
sig { returns(T.nilable(String)) }
attr_reader :adjustment
# If applicable, the ID of the FeeTransaction that created this Transaction.
sig { returns(T.nilable(String)) }
attr_reader :fee_transaction
# If applicable, the ID of the InboundTransfer that created this Transaction.
sig { returns(T.nilable(String)) }
attr_reader :inbound_transfer
# If applicable, the ID of the OutboundPayment that created this Transaction.
sig { returns(T.nilable(String)) }
attr_reader :outbound_payment
# If applicable, the ID of the OutboundTransfer that created this Transaction.
sig { returns(T.nilable(String)) }
attr_reader :outbound_transfer
# If applicable, the ID of the ReceivedCredit that created this Transaction.
sig { returns(T.nilable(String)) }
attr_reader :received_credit
# If applicable, the ID of the ReceivedDebit that created this Transaction.
sig { returns(T.nilable(String)) }
attr_reader :received_debit
end
class StatusTransitions < Stripe::StripeObject
# The time at which the Transaction became posted. Only present if status == posted.
sig { returns(T.nilable(String)) }
attr_reader :posted_at
# The time at which the Transaction became void. Only present if status == void.
sig { returns(T.nilable(String)) }
attr_reader :void_at
end
# The amount of the Transaction.
sig { returns(Stripe::V2::Amount) }
attr_reader :amount
# The delta to the FinancialAccount's balance. The balance_impact for the Transaction is equal to sum of its
# TransactionEntries that have `effective_at`s in the past.
sig { returns(BalanceImpact) }
attr_reader :balance_impact
# Open Enum. A descriptive category used to classify the Transaction.
sig { returns(String) }
attr_reader :category
# Time at which the object was created. Represented as a RFC 3339 date & time UTC value in millisecond precision, for example: 2022-09-18T13:22:18.123Z.
sig { returns(String) }
attr_reader :created
# Indicates the FinancialAccount affected by this Transaction.
sig { returns(String) }
attr_reader :financial_account
# Details about the Flow object that created the Transaction.
sig { returns(Flow) }
attr_reader :flow
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# String representing the object's type. Objects of the same type share the same value of the object field.
sig { returns(String) }
attr_reader :object
# Closed Enum. Current status of the Transaction.
# A Transaction is `pending` if either `balance_impact.inbound_pending` or `balance_impact.outbound_pending` is non-zero.
# A Transaction is `posted` if only `balance_impact.available` is non-zero.
# A Transaction is `void` if there is no balance impact.
# `posted` and `void` are terminal states, and no additional entries will be added to the Transaction.
sig { returns(String) }
attr_reader :status
# Timestamps for when the Transaction transitioned to a particular status.
sig { returns(StatusTransitions) }
attr_reader :status_transitions
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
end
end
end
end
# typed: true
module Stripe
module V2
module MoneyManagement
# TransactionEntries represent individual money movements across different states within a Transaction.
class TransactionEntry < APIResource
class BalanceImpact < Stripe::StripeObject
# Impact to the available balance.
sig { returns(Stripe::V2::Amount) }
attr_reader :available
# Impact to the inbound_pending balance.
sig { returns(Stripe::V2::Amount) }
attr_reader :inbound_pending
# Impact to the outbound_pending balance.
sig { returns(Stripe::V2::Amount) }
attr_reader :outbound_pending
end
class TransactionDetails < Stripe::StripeObject
class Flow < Stripe::StripeObject
# Open Enum. Type of the flow that created the Transaction. The field matching this value will contain the ID of the flow.
sig { returns(String) }
attr_reader :type
# If applicable, the ID of the Adjustment that created this Transaction.
sig { returns(T.nilable(String)) }
attr_reader :adjustment
# If applicable, the ID of the FeeTransaction that created this Transaction.
sig { returns(T.nilable(String)) }
attr_reader :fee_transaction
# If applicable, the ID of the InboundTransfer that created this Transaction.
sig { returns(T.nilable(String)) }
attr_reader :inbound_transfer
# If applicable, the ID of the OutboundPayment that created this Transaction.
sig { returns(T.nilable(String)) }
attr_reader :outbound_payment
# If applicable, the ID of the OutboundTransfer that created this Transaction.
sig { returns(T.nilable(String)) }
attr_reader :outbound_transfer
# If applicable, the ID of the ReceivedCredit that created this Transaction.
sig { returns(T.nilable(String)) }
attr_reader :received_credit
# If applicable, the ID of the ReceivedDebit that created this Transaction.
sig { returns(T.nilable(String)) }
attr_reader :received_debit
end
# Closed Enum for now, and will be turned into an Open Enum soon. A descriptive category used to classify the Transaction.
sig { returns(String) }
attr_reader :category
# Indicates the FinancialAccount affected by this Transaction.
sig { returns(String) }
attr_reader :financial_account
# Details about the Flow object that created the Transaction.
sig { returns(Flow) }
attr_reader :flow
end
# The delta to the FinancialAccount's balance.
sig { returns(BalanceImpact) }
attr_reader :balance_impact
# Time at which the object was created.
sig { returns(String) }
attr_reader :created
# Time at which the entry impacted (or will impact if it's in the future) the FinancialAccount balance.
sig { returns(String) }
attr_reader :effective_at
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# String representing the object's type. Objects of the same type share the same value of the object field.
sig { returns(String) }
attr_reader :object
# The Transaction that this TransactionEntry belongs to.
sig { returns(String) }
attr_reader :transaction
# Details copied from the transaction that this TransactionEntry belongs to.
sig { returns(TransactionDetails) }
attr_reader :transaction_details
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
end
end
end
end
# typed: true
module Stripe
# This is an object representing a Stripe account. You can retrieve it to see
# properties on the account like its current requirements or if the account is
# enabled to make live charges or receive payouts.
#
# For accounts where [controller.requirement_collection](https://docs.stripe.com/api/accounts/object#account_object-controller-requirement_collection)
# is `application`, which includes Custom accounts, the properties below are always
# returned.
#
# For accounts where [controller.requirement_collection](https://docs.stripe.com/api/accounts/object#account_object-controller-requirement_collection)
# is `stripe`, which includes Standard and Express accounts, some properties are only returned
# until you create an [Account Link](https://docs.stripe.com/api/account_links) or [Account Session](https://docs.stripe.com/api/account_sessions)
# to start Connect Onboarding. Learn about the [differences between accounts](https://docs.stripe.com/connect/accounts).
class Account < APIResource
class BusinessProfile < Stripe::StripeObject
class AnnualRevenue < Stripe::StripeObject
# A non-negative integer representing the amount in the [smallest currency unit](/currencies#zero-decimal).
sig { returns(T.nilable(Integer)) }
attr_reader :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).
sig { returns(T.nilable(String)) }
attr_reader :currency
# The close-out date of the preceding fiscal year in ISO 8601 format. E.g. 2023-12-31 for the 31st of December, 2023.
sig { returns(T.nilable(String)) }
attr_reader :fiscal_year_end
end
class MonthlyEstimatedRevenue < Stripe::StripeObject
# A non-negative integer representing how much to charge in the [smallest currency unit](/currencies#zero-decimal).
sig { returns(Integer) }
attr_reader :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).
sig { returns(String) }
attr_reader :currency
end
class SupportAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# The applicant's gross annual revenue for its preceding fiscal year.
sig { returns(T.nilable(AnnualRevenue)) }
attr_reader :annual_revenue
# An estimated upper bound of employees, contractors, vendors, etc. currently working for the business.
sig { returns(T.nilable(Integer)) }
attr_reader :estimated_worker_count
# [The merchant category code for the account](/connect/setting-mcc). MCCs are used to classify businesses based on the goods or services they provide.
sig { returns(T.nilable(String)) }
attr_reader :mcc
# Whether the business is a minority-owned, women-owned, and/or LGBTQI+-owned business.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :minority_owned_business_designation
# Attribute for field monthly_estimated_revenue
sig { returns(MonthlyEstimatedRevenue) }
attr_reader :monthly_estimated_revenue
# The customer-facing business name.
sig { returns(T.nilable(String)) }
attr_reader :name
# Internal-only description of the product sold or service provided by the business. It's used by Stripe for risk and underwriting purposes.
sig { returns(T.nilable(String)) }
attr_reader :product_description
# A publicly available mailing address for sending support issues to.
sig { returns(T.nilable(SupportAddress)) }
attr_reader :support_address
# A publicly available email address for sending support issues to.
sig { returns(T.nilable(String)) }
attr_reader :support_email
# A publicly available phone number to call with support issues.
sig { returns(T.nilable(String)) }
attr_reader :support_phone
# A publicly available website for handling support issues.
sig { returns(T.nilable(String)) }
attr_reader :support_url
# The business's publicly available website.
sig { returns(T.nilable(String)) }
attr_reader :url
end
class Capabilities < Stripe::StripeObject
# The status of the Canadian pre-authorized debits payments capability of the account, or whether the account can directly process Canadian pre-authorized debits charges.
sig { returns(String) }
attr_reader :acss_debit_payments
# The status of the Affirm capability of the account, or whether the account can directly process Affirm charges.
sig { returns(String) }
attr_reader :affirm_payments
# The status of the Afterpay Clearpay capability of the account, or whether the account can directly process Afterpay Clearpay charges.
sig { returns(String) }
attr_reader :afterpay_clearpay_payments
# The status of the Alma capability of the account, or whether the account can directly process Alma payments.
sig { returns(String) }
attr_reader :alma_payments
# The status of the AmazonPay capability of the account, or whether the account can directly process AmazonPay payments.
sig { returns(String) }
attr_reader :amazon_pay_payments
# The status of the BECS Direct Debit (AU) payments capability of the account, or whether the account can directly process BECS Direct Debit (AU) charges.
sig { returns(String) }
attr_reader :au_becs_debit_payments
# The status of the automatic_indirect_tax capability of the account.
sig { returns(String) }
attr_reader :automatic_indirect_tax
# The status of the Bacs Direct Debits payments capability of the account, or whether the account can directly process Bacs Direct Debits charges.
sig { returns(String) }
attr_reader :bacs_debit_payments
# The status of the Bancontact payments capability of the account, or whether the account can directly process Bancontact charges.
sig { returns(String) }
attr_reader :bancontact_payments
# The status of the customer_balance payments capability of the account, or whether the account can directly process customer_balance charges.
sig { returns(String) }
attr_reader :bank_transfer_payments
# The status of the Billie capability of the account, or whether the account can directly process Billie payments.
sig { returns(String) }
attr_reader :billie_payments
# The status of the blik payments capability of the account, or whether the account can directly process blik charges.
sig { returns(String) }
attr_reader :blik_payments
# The status of the boleto payments capability of the account, or whether the account can directly process boleto charges.
sig { returns(String) }
attr_reader :boleto_payments
# The status of the card issuing capability of the account, or whether you can use Issuing to distribute funds on cards
sig { returns(String) }
attr_reader :card_issuing
# The status of the card payments capability of the account, or whether the account can directly process credit and debit card charges.
sig { returns(String) }
attr_reader :card_payments
# The status of the Cartes Bancaires payments capability of the account, or whether the account can directly process Cartes Bancaires card charges in EUR currency.
sig { returns(String) }
attr_reader :cartes_bancaires_payments
# The status of the Cash App Pay capability of the account, or whether the account can directly process Cash App Pay payments.
sig { returns(String) }
attr_reader :cashapp_payments
# The status of the EPS payments capability of the account, or whether the account can directly process EPS charges.
sig { returns(String) }
attr_reader :eps_payments
# The status of the FPX payments capability of the account, or whether the account can directly process FPX charges.
sig { returns(String) }
attr_reader :fpx_payments
# The status of the GB customer_balance payments (GBP currency) capability of the account, or whether the account can directly process GB customer_balance charges.
sig { returns(String) }
attr_reader :gb_bank_transfer_payments
# The status of the giropay payments capability of the account, or whether the account can directly process giropay charges.
sig { returns(String) }
attr_reader :giropay_payments
# The status of the Gopay capability of the account, or whether the account can directly process Gopay payments.
sig { returns(String) }
attr_reader :gopay_payments
# The status of the GrabPay payments capability of the account, or whether the account can directly process GrabPay charges.
sig { returns(String) }
attr_reader :grabpay_payments
# The status of the Indonesia Bank Transfer payments capability of the account, or whether the account can directly process Indonesia Bank Transfer charges.
sig { returns(String) }
attr_reader :id_bank_transfer_payments
# The status of Bank BCA onboarding of the account.
sig { returns(String) }
attr_reader :id_bank_transfer_payments_bca
# The status of the iDEAL payments capability of the account, or whether the account can directly process iDEAL charges.
sig { returns(String) }
attr_reader :ideal_payments
# The status of the india_international_payments capability of the account, or whether the account can process international charges (non INR) in India.
sig { returns(String) }
attr_reader :india_international_payments
# The status of the JCB payments capability of the account, or whether the account (Japan only) can directly process JCB credit card charges in JPY currency.
sig { returns(String) }
attr_reader :jcb_payments
# The status of the Japanese customer_balance payments (JPY currency) capability of the account, or whether the account can directly process Japanese customer_balance charges.
sig { returns(String) }
attr_reader :jp_bank_transfer_payments
# The status of the KakaoPay capability of the account, or whether the account can directly process KakaoPay payments.
sig { returns(String) }
attr_reader :kakao_pay_payments
# The status of the Klarna payments capability of the account, or whether the account can directly process Klarna charges.
sig { returns(String) }
attr_reader :klarna_payments
# The status of the konbini payments capability of the account, or whether the account can directly process konbini charges.
sig { returns(String) }
attr_reader :konbini_payments
# The status of the KrCard capability of the account, or whether the account can directly process KrCard payments.
sig { returns(String) }
attr_reader :kr_card_payments
# The status of the legacy payments capability of the account.
sig { returns(String) }
attr_reader :legacy_payments
# The status of the link_payments capability of the account, or whether the account can directly process Link charges.
sig { returns(String) }
attr_reader :link_payments
# The status of the MB WAY payments capability of the account, or whether the account can directly process MB WAY charges.
sig { returns(String) }
attr_reader :mb_way_payments
# The status of the MobilePay capability of the account, or whether the account can directly process MobilePay charges.
sig { returns(String) }
attr_reader :mobilepay_payments
# The status of the Multibanco payments capability of the account, or whether the account can directly process Multibanco charges.
sig { returns(String) }
attr_reader :multibanco_payments
# The status of the Mexican customer_balance payments (MXN currency) capability of the account, or whether the account can directly process Mexican customer_balance charges.
sig { returns(String) }
attr_reader :mx_bank_transfer_payments
# The status of the NaverPay capability of the account, or whether the account can directly process NaverPay payments.
sig { returns(String) }
attr_reader :naver_pay_payments
# The status of the New Zealand BECS Direct Debit payments capability of the account, or whether the account can directly process New Zealand BECS Direct Debit charges.
sig { returns(String) }
attr_reader :nz_bank_account_becs_debit_payments
# The status of the OXXO payments capability of the account, or whether the account can directly process OXXO charges.
sig { returns(String) }
attr_reader :oxxo_payments
# The status of the P24 payments capability of the account, or whether the account can directly process P24 charges.
sig { returns(String) }
attr_reader :p24_payments
# The status of the pay_by_bank payments capability of the account, or whether the account can directly process pay_by_bank charges.
sig { returns(String) }
attr_reader :pay_by_bank_payments
# The status of the Payco capability of the account, or whether the account can directly process Payco payments.
sig { returns(String) }
attr_reader :payco_payments
# The status of the paynow payments capability of the account, or whether the account can directly process paynow charges.
sig { returns(String) }
attr_reader :paynow_payments
# The status of the PayPal payments capability of the account, or whether the account can directly process PayPal charges.
sig { returns(String) }
attr_reader :paypal_payments
# The status of the PayTo capability of the account, or whether the account can directly process PayTo charges.
sig { returns(String) }
attr_reader :payto_payments
# The status of the pix payments capability of the account, or whether the account can directly process pix charges.
sig { returns(String) }
attr_reader :pix_payments
# The status of the promptpay payments capability of the account, or whether the account can directly process promptpay charges.
sig { returns(String) }
attr_reader :promptpay_payments
# The status of the Qris capability of the account, or whether the account can directly process Qris payments.
sig { returns(String) }
attr_reader :qris_payments
# The status of the Rechnung capability of the account, or whether the account can directly process Rechnung payments.
sig { returns(String) }
attr_reader :rechnung_payments
# The status of the RevolutPay capability of the account, or whether the account can directly process RevolutPay payments.
sig { returns(String) }
attr_reader :revolut_pay_payments
# The status of the SamsungPay capability of the account, or whether the account can directly process SamsungPay payments.
sig { returns(String) }
attr_reader :samsung_pay_payments
# The status of the Satispay capability of the account, or whether the account can directly process Satispay payments.
sig { returns(String) }
attr_reader :satispay_payments
# The status of the SEPA customer_balance payments (EUR currency) capability of the account, or whether the account can directly process SEPA customer_balance charges.
sig { returns(String) }
attr_reader :sepa_bank_transfer_payments
# The status of the SEPA Direct Debits payments capability of the account, or whether the account can directly process SEPA Direct Debits charges.
sig { returns(String) }
attr_reader :sepa_debit_payments
# The status of the ShopeePay capability of the account, or whether the account can directly process ShopeePay payments.
sig { returns(String) }
attr_reader :shopeepay_payments
# The status of the Sofort payments capability of the account, or whether the account can directly process Sofort charges.
sig { returns(String) }
attr_reader :sofort_payments
# The status of the stripe_balance payments capability of the account, or whether the account can directly process stripe_balance charges.
sig { returns(String) }
attr_reader :stripe_balance_payments
# The status of the Swish capability of the account, or whether the account can directly process Swish payments.
sig { returns(String) }
attr_reader :swish_payments
# The status of the tax reporting 1099-K (US) capability of the account.
sig { returns(String) }
attr_reader :tax_reporting_us_1099_k
# The status of the tax reporting 1099-MISC (US) capability of the account.
sig { returns(String) }
attr_reader :tax_reporting_us_1099_misc
# The status of the transfers capability of the account, or whether your platform can transfer funds to the account.
sig { returns(String) }
attr_reader :transfers
# The status of the banking capability, or whether the account can have bank accounts.
sig { returns(String) }
attr_reader :treasury
# The status of the treasury_evolve capability of the account.
sig { returns(String) }
attr_reader :treasury_evolve
# The status of the treasury_fifth_third capability of the account.
sig { returns(String) }
attr_reader :treasury_fifth_third
# The status of the treasury_goldman_sachs capability of the account.
sig { returns(String) }
attr_reader :treasury_goldman_sachs
# The status of the TWINT capability of the account, or whether the account can directly process TWINT charges.
sig { returns(String) }
attr_reader :twint_payments
# The status of the US bank account ACH payments capability of the account, or whether the account can directly process US bank account charges.
sig { returns(String) }
attr_reader :us_bank_account_ach_payments
# The status of the US customer_balance payments (USD currency) capability of the account, or whether the account can directly process US customer_balance charges.
sig { returns(String) }
attr_reader :us_bank_transfer_payments
# The status of the Zip capability of the account, or whether the account can directly process Zip charges.
sig { returns(String) }
attr_reader :zip_payments
end
class Company < Stripe::StripeObject
class Address < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
class AddressKana < Stripe::StripeObject
# City/Ward.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Block/Building number.
sig { returns(T.nilable(String)) }
attr_reader :line1
# Building details.
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# Prefecture.
sig { returns(T.nilable(String)) }
attr_reader :state
# Town/cho-me.
sig { returns(T.nilable(String)) }
attr_reader :town
end
class AddressKanji < Stripe::StripeObject
# City/Ward.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Block/Building number.
sig { returns(T.nilable(String)) }
attr_reader :line1
# Building details.
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# Prefecture.
sig { returns(T.nilable(String)) }
attr_reader :state
# Town/cho-me.
sig { returns(T.nilable(String)) }
attr_reader :town
end
class DirectorshipDeclaration < Stripe::StripeObject
# The Unix timestamp marking when the directorship declaration attestation was made.
sig { returns(T.nilable(Integer)) }
attr_reader :date
# The IP address from which the directorship declaration attestation was made.
sig { returns(T.nilable(String)) }
attr_reader :ip
# The user-agent string from the browser where the directorship declaration attestation was made.
sig { returns(T.nilable(String)) }
attr_reader :user_agent
end
class OwnershipDeclaration < Stripe::StripeObject
# The Unix timestamp marking when the beneficial owner attestation was made.
sig { returns(T.nilable(Integer)) }
attr_reader :date
# The IP address from which the beneficial owner attestation was made.
sig { returns(T.nilable(String)) }
attr_reader :ip
# The user-agent string from the browser where the beneficial owner attestation was made.
sig { returns(T.nilable(String)) }
attr_reader :user_agent
end
class RegistrationDate < Stripe::StripeObject
# The day of registration, between 1 and 31.
sig { returns(T.nilable(Integer)) }
attr_reader :day
# The month of registration, between 1 and 12.
sig { returns(T.nilable(Integer)) }
attr_reader :month
# The four-digit year of registration.
sig { returns(T.nilable(Integer)) }
attr_reader :year
end
class Verification < Stripe::StripeObject
class Document < Stripe::StripeObject
# The back of a document returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `additional_verification`.
sig { returns(T.nilable(T.any(String, Stripe::File))) }
attr_reader :back
# A user-displayable string describing the verification state of this document.
sig { returns(T.nilable(String)) }
attr_reader :details
# One of `document_corrupt`, `document_expired`, `document_failed_copy`, `document_failed_greyscale`, `document_failed_other`, `document_failed_test_mode`, `document_fraudulent`, `document_incomplete`, `document_invalid`, `document_manipulated`, `document_not_readable`, `document_not_uploaded`, `document_type_not_supported`, or `document_too_large`. A machine-readable code specifying the verification state for this document.
sig { returns(T.nilable(String)) }
attr_reader :details_code
# The front of a document returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `additional_verification`.
sig { returns(T.nilable(T.any(String, Stripe::File))) }
attr_reader :front
end
# Attribute for field document
sig { returns(Document) }
attr_reader :document
end
# Attribute for field address
sig { returns(Address) }
attr_reader :address
# The Kana variation of the company's primary address (Japan only).
sig { returns(T.nilable(AddressKana)) }
attr_reader :address_kana
# The Kanji variation of the company's primary address (Japan only).
sig { returns(T.nilable(AddressKanji)) }
attr_reader :address_kanji
# Whether the company's directors have been provided. This Boolean will be `true` if you've manually indicated that all directors are provided via [the `directors_provided` parameter](https://stripe.com/docs/api/accounts/update#update_account-company-directors_provided).
sig { returns(T::Boolean) }
attr_reader :directors_provided
# This hash is used to attest that the director information provided to Stripe is both current and correct.
sig { returns(T.nilable(DirectorshipDeclaration)) }
attr_reader :directorship_declaration
# Whether the company's executives have been provided. This Boolean will be `true` if you've manually indicated that all executives are provided via [the `executives_provided` parameter](https://stripe.com/docs/api/accounts/update#update_account-company-executives_provided), or if Stripe determined that sufficient executives were provided.
sig { returns(T::Boolean) }
attr_reader :executives_provided
# The export license ID number of the company, also referred as Import Export Code (India only).
sig { returns(String) }
attr_reader :export_license_id
# The purpose code to use for export transactions (India only).
sig { returns(String) }
attr_reader :export_purpose_code
# The company's legal name. Also available for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `stripe`.
sig { returns(T.nilable(String)) }
attr_reader :name
# The Kana variation of the company's legal name (Japan only). Also available for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `stripe`.
sig { returns(T.nilable(String)) }
attr_reader :name_kana
# The Kanji variation of the company's legal name (Japan only). Also available for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `stripe`.
sig { returns(T.nilable(String)) }
attr_reader :name_kanji
# Whether the company's owners have been provided. This Boolean will be `true` if you've manually indicated that all owners are provided via [the `owners_provided` parameter](https://stripe.com/docs/api/accounts/update#update_account-company-owners_provided), or if Stripe determined that sufficient owners were provided. Stripe determines ownership requirements using both the number of owners provided and their total percent ownership (calculated by adding the `percent_ownership` of each owner together).
sig { returns(T::Boolean) }
attr_reader :owners_provided
# This hash is used to attest that the beneficial owner information provided to Stripe is both current and correct.
sig { returns(T.nilable(OwnershipDeclaration)) }
attr_reader :ownership_declaration
# This value is used to determine if a business is exempt from providing ultimate beneficial owners. See [this support article](https://support.stripe.com/questions/exemption-from-providing-ownership-details) and [changelog](https://docs.stripe.com/changelog/acacia/2025-01-27/ownership-exemption-reason-accounts-api) for more details.
sig { returns(String) }
attr_reader :ownership_exemption_reason
# The company's phone number (used for verification).
sig { returns(T.nilable(String)) }
attr_reader :phone
# Attribute for field registration_date
sig { returns(RegistrationDate) }
attr_reader :registration_date
# The category identifying the legal structure of the company or legal entity. Also available for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `stripe`. See [Business structure](https://stripe.com/docs/connect/identity-verification#business-structure) for more details.
sig { returns(String) }
attr_reader :structure
# Whether the company's business ID number was provided.
sig { returns(T::Boolean) }
attr_reader :tax_id_provided
# The jurisdiction in which the `tax_id` is registered (Germany-based companies only).
sig { returns(String) }
attr_reader :tax_id_registrar
# Whether the company's business VAT number was provided.
sig { returns(T::Boolean) }
attr_reader :vat_id_provided
# Information on the verification state of the company.
sig { returns(T.nilable(Verification)) }
attr_reader :verification
end
class Controller < Stripe::StripeObject
class Application < Stripe::StripeObject
# `true` if the Connect application is responsible for negative balances and should manage credit and fraud risk on the account.
sig { returns(T::Boolean) }
attr_reader :loss_liable
# `true` if the Connect application is responsible for onboarding the account.
sig { returns(T::Boolean) }
attr_reader :onboarding_owner
# `true` if the Connect application is responsible for paying Stripe fees on pricing-control eligible products.
sig { returns(T::Boolean) }
attr_reader :pricing_controls
end
class Dashboard < Stripe::StripeObject
# Whether this account has access to the full Stripe dashboard (`full`), to the Express dashboard (`express`), or to no dashboard (`none`).
sig { returns(String) }
attr_reader :type
end
class Fees < Stripe::StripeObject
# A value indicating the responsible payer of a bundle of Stripe fees for pricing-control eligible products on this account. Learn more about [fee behavior on connected accounts](https://docs.stripe.com/connect/direct-charges-fee-payer-behavior).
sig { returns(String) }
attr_reader :payer
end
class Losses < Stripe::StripeObject
# A value indicating who is liable when this account can't pay back negative balances from payments.
sig { returns(String) }
attr_reader :payments
end
class StripeDashboard < Stripe::StripeObject
# A value indicating the Stripe dashboard this account has access to independent of the Connect application.
sig { returns(String) }
attr_reader :type
end
# Attribute for field application
sig { returns(Application) }
attr_reader :application
# Attribute for field dashboard
sig { returns(Dashboard) }
attr_reader :dashboard
# Attribute for field fees
sig { returns(Fees) }
attr_reader :fees
# `true` if the Connect application retrieving the resource controls the account and can therefore exercise [platform controls](https://stripe.com/docs/connect/platform-controls-for-standard-accounts). Otherwise, this field is null.
sig { returns(T::Boolean) }
attr_reader :is_controller
# Attribute for field losses
sig { returns(Losses) }
attr_reader :losses
# A value indicating responsibility for collecting requirements on this account. Only returned when the Connect application retrieving the resource controls the account.
sig { returns(String) }
attr_reader :requirement_collection
# Attribute for field stripe_dashboard
sig { returns(StripeDashboard) }
attr_reader :stripe_dashboard
# The controller type. Can be `application`, if a Connect application controls the account, or `account`, if the account controls itself.
sig { returns(String) }
attr_reader :type
end
class FutureRequirements < Stripe::StripeObject
class Alternative < Stripe::StripeObject
# Fields that can be provided to satisfy all fields in `original_fields_due`.
sig { returns(T::Array[String]) }
attr_reader :alternative_fields_due
# Fields that are due and can be satisfied by providing all fields in `alternative_fields_due`.
sig { returns(T::Array[String]) }
attr_reader :original_fields_due
end
class Error < Stripe::StripeObject
# The code for the type of error.
sig { returns(String) }
attr_reader :code
# An informative message that indicates the error type and provides additional details about the error.
sig { returns(String) }
attr_reader :reason
# The specific user onboarding requirement field (in the requirements hash) that needs to be resolved.
sig { returns(String) }
attr_reader :requirement
end
# Fields that are due and can be satisfied by providing the corresponding alternative fields instead.
sig { returns(T.nilable(T::Array[Alternative])) }
attr_reader :alternatives
# Date on which `future_requirements` becomes the main `requirements` hash and `future_requirements` becomes empty. After the transition, `currently_due` requirements may immediately become `past_due`, but the account may also be given a grace period depending on its enablement state prior to transitioning.
sig { returns(T.nilable(Integer)) }
attr_reader :current_deadline
# Fields that need to be collected to keep the account enabled. If not collected by `future_requirements[current_deadline]`, these fields will transition to the main `requirements` hash.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :currently_due
# This is typed as an enum for consistency with `requirements.disabled_reason`.
sig { returns(T.nilable(String)) }
attr_reader :disabled_reason
# Fields that are `currently_due` and need to be collected again because validation or verification failed.
sig { returns(T.nilable(T::Array[Error])) }
attr_reader :errors
# Fields you must collect when all thresholds are reached. As they become required, they appear in `currently_due` as well.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :eventually_due
# Fields that weren't collected by `requirements.current_deadline`. These fields need to be collected to enable the capability on the account. New fields will never appear here; `future_requirements.past_due` will always be a subset of `requirements.past_due`.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :past_due
# Fields that might become required depending on the results of verification or review. It's an empty array unless an asynchronous verification is pending. If verification fails, these fields move to `eventually_due` or `currently_due`. Fields might appear in `eventually_due` or `currently_due` and in `pending_verification` if verification fails but another verification is still pending.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :pending_verification
end
class Groups < Stripe::StripeObject
# The group the account is in to determine their payments pricing, and null if the account is on customized pricing. [See the Platform pricing tool documentation](https://stripe.com/docs/connect/platform-pricing-tools) for details.
sig { returns(T.nilable(String)) }
attr_reader :payments_pricing
end
class Requirements < Stripe::StripeObject
class Alternative < Stripe::StripeObject
# Fields that can be provided to satisfy all fields in `original_fields_due`.
sig { returns(T::Array[String]) }
attr_reader :alternative_fields_due
# Fields that are due and can be satisfied by providing all fields in `alternative_fields_due`.
sig { returns(T::Array[String]) }
attr_reader :original_fields_due
end
class Error < Stripe::StripeObject
# The code for the type of error.
sig { returns(String) }
attr_reader :code
# An informative message that indicates the error type and provides additional details about the error.
sig { returns(String) }
attr_reader :reason
# The specific user onboarding requirement field (in the requirements hash) that needs to be resolved.
sig { returns(String) }
attr_reader :requirement
end
# Fields that are due and can be satisfied by providing the corresponding alternative fields instead.
sig { returns(T.nilable(T::Array[Alternative])) }
attr_reader :alternatives
# Date by which the fields in `currently_due` must be collected to keep the account enabled. These fields may disable the account sooner if the next threshold is reached before they are collected.
sig { returns(T.nilable(Integer)) }
attr_reader :current_deadline
# Fields that need to be collected to keep the account enabled. If not collected by `current_deadline`, these fields appear in `past_due` as well, and the account is disabled.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :currently_due
# If the account is disabled, this enum describes why. [Learn more about handling verification issues](https://stripe.com/docs/connect/handling-api-verification).
sig { returns(T.nilable(String)) }
attr_reader :disabled_reason
# Fields that are `currently_due` and need to be collected again because validation or verification failed.
sig { returns(T.nilable(T::Array[Error])) }
attr_reader :errors
# Fields you must collect when all thresholds are reached. As they become required, they appear in `currently_due` as well, and `current_deadline` becomes set.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :eventually_due
# Fields that weren't collected by `current_deadline`. These fields need to be collected to enable the account.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :past_due
# Fields that might become required depending on the results of verification or review. It's an empty array unless an asynchronous verification is pending. If verification fails, these fields move to `eventually_due`, `currently_due`, or `past_due`. Fields might appear in `eventually_due`, `currently_due`, or `past_due` and in `pending_verification` if verification fails but another verification is still pending.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :pending_verification
end
class RiskControls < Stripe::StripeObject
class Charges < Stripe::StripeObject
# Whether a pause of the risk control has been requested.
sig { returns(T::Boolean) }
attr_reader :pause_requested
end
class Payouts < Stripe::StripeObject
# Whether a pause of the risk control has been requested.
sig { returns(T::Boolean) }
attr_reader :pause_requested
end
# Attribute for field charges
sig { returns(Charges) }
attr_reader :charges
# Attribute for field payouts
sig { returns(Payouts) }
attr_reader :payouts
# Represents the rejected reason of the account. Empty if account is not rejected, or rejected by Stripe. Please see [this page for more details](https://stripe.com/docs/connect/)
sig { returns(T.nilable(String)) }
attr_reader :rejected_reason
end
class Settings < Stripe::StripeObject
class BacsDebitPayments < Stripe::StripeObject
# The Bacs Direct Debit display name for this account. For payments made with Bacs Direct Debit, this name appears on the mandate as the statement descriptor. Mobile banking apps display it as the name of the business. To use custom branding, set the Bacs Direct Debit Display Name during or right after creation. Custom branding incurs an additional monthly fee for the platform. The fee appears 5 business days after requesting Bacs. If you don't set the display name before requesting Bacs capability, it's automatically set as "Stripe" and the account is onboarded to Stripe branding, which is free.
sig { returns(T.nilable(String)) }
attr_reader :display_name
# The Bacs Direct Debit Service user number for this account. For payments made with Bacs Direct Debit, this number is a unique identifier of the account with our banking partners.
sig { returns(T.nilable(String)) }
attr_reader :service_user_number
end
class BankBcaOnboarding < Stripe::StripeObject
# Bank BCA business account holder name.
sig { returns(String) }
attr_reader :account_holder_name
# Bank BCA business account number.
sig { returns(String) }
attr_reader :business_account_number
end
class Branding < Stripe::StripeObject
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) An icon for the account. Must be square and at least 128px x 128px.
sig { returns(T.nilable(T.any(String, Stripe::File))) }
attr_reader :icon
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) A logo for the account that will be used in Checkout instead of the icon and without the account's name next to it if provided. Must be at least 128px x 128px.
sig { returns(T.nilable(T.any(String, Stripe::File))) }
attr_reader :logo
# A CSS hex color value representing the primary branding color for this account
sig { returns(T.nilable(String)) }
attr_reader :primary_color
# A CSS hex color value representing the secondary branding color for this account
sig { returns(T.nilable(String)) }
attr_reader :secondary_color
end
class Capital < Stripe::StripeObject
# Per-currency mapping of user-selected destination accounts used to pay out loans.
sig { returns(T::Hash[String, String]) }
attr_reader :payout_destination
# Per-currency mapping of all destination accounts eligible to receive loan payouts.
sig { returns(T::Hash[String, T::Array[String]]) }
attr_reader :payout_destination_selector
end
class CardIssuing < Stripe::StripeObject
class TosAcceptance < Stripe::StripeObject
# The Unix timestamp marking when the account representative accepted the service agreement.
sig { returns(T.nilable(Integer)) }
attr_reader :date
# The IP address from which the account representative accepted the service agreement.
sig { returns(T.nilable(String)) }
attr_reader :ip
# The user agent of the browser from which the account representative accepted the service agreement.
sig { returns(String) }
attr_reader :user_agent
end
# Attribute for field tos_acceptance
sig { returns(TosAcceptance) }
attr_reader :tos_acceptance
end
class CardPayments < Stripe::StripeObject
class DeclineOn < Stripe::StripeObject
# Whether Stripe automatically declines charges with an incorrect ZIP or postal code. This setting only applies when a ZIP or postal code is provided and they fail bank verification.
sig { returns(T::Boolean) }
attr_reader :avs_failure
# Whether Stripe automatically declines charges with an incorrect CVC. This setting only applies when a CVC is provided and it fails bank verification.
sig { returns(T::Boolean) }
attr_reader :cvc_failure
end
# Attribute for field decline_on
sig { returns(DeclineOn) }
attr_reader :decline_on
# The default text that appears on credit card statements when a charge is made. This field prefixes any dynamic `statement_descriptor` specified on the charge. `statement_descriptor_prefix` is useful for maximizing descriptor space for the dynamic portion.
sig { returns(T.nilable(String)) }
attr_reader :statement_descriptor_prefix
# The Kana variation of the default text that appears on credit card statements when a charge is made (Japan only). This field prefixes any dynamic `statement_descriptor_suffix_kana` specified on the charge. `statement_descriptor_prefix_kana` is useful for maximizing descriptor space for the dynamic portion.
sig { returns(T.nilable(String)) }
attr_reader :statement_descriptor_prefix_kana
# The Kanji variation of the default text that appears on credit card statements when a charge is made (Japan only). This field prefixes any dynamic `statement_descriptor_suffix_kanji` specified on the charge. `statement_descriptor_prefix_kanji` is useful for maximizing descriptor space for the dynamic portion.
sig { returns(T.nilable(String)) }
attr_reader :statement_descriptor_prefix_kanji
end
class Dashboard < Stripe::StripeObject
# The display name for this account. This is used on the Stripe Dashboard to differentiate between accounts.
sig { returns(T.nilable(String)) }
attr_reader :display_name
# The timezone used in the Stripe Dashboard for this account. A list of possible time zone values is maintained at the [IANA Time Zone Database](http://www.iana.org/time-zones).
sig { returns(T.nilable(String)) }
attr_reader :timezone
end
class Invoices < Stripe::StripeObject
# The list of default Account Tax IDs to automatically include on invoices. Account Tax IDs get added when an invoice is finalized.
sig { returns(T.nilable(T::Array[T.any(String, Stripe::TaxId)])) }
attr_reader :default_account_tax_ids
# Whether payment methods should be saved when a payment is completed for a one-time invoices on a hosted invoice page.
sig { returns(T.nilable(String)) }
attr_reader :hosted_payment_method_save
end
class Payments < Stripe::StripeObject
# The default text that appears on credit card statements when a charge is made. This field prefixes any dynamic `statement_descriptor` specified on the charge.
sig { returns(T.nilable(String)) }
attr_reader :statement_descriptor
# The Kana variation of `statement_descriptor` used for charges in Japan. Japanese statement descriptors have [special requirements](https://docs.stripe.com/get-started/account/statement-descriptors#set-japanese-statement-descriptors).
sig { returns(T.nilable(String)) }
attr_reader :statement_descriptor_kana
# The Kanji variation of `statement_descriptor` used for charges in Japan. Japanese statement descriptors have [special requirements](https://docs.stripe.com/get-started/account/statement-descriptors#set-japanese-statement-descriptors).
sig { returns(T.nilable(String)) }
attr_reader :statement_descriptor_kanji
# The Kana variation of `statement_descriptor_prefix` used for card charges in Japan. Japanese statement descriptors have [special requirements](https://docs.stripe.com/get-started/account/statement-descriptors#set-japanese-statement-descriptors).
sig { returns(T.nilable(String)) }
attr_reader :statement_descriptor_prefix_kana
# The Kanji variation of `statement_descriptor_prefix` used for card charges in Japan. Japanese statement descriptors have [special requirements](https://docs.stripe.com/get-started/account/statement-descriptors#set-japanese-statement-descriptors).
sig { returns(T.nilable(String)) }
attr_reader :statement_descriptor_prefix_kanji
end
class Payouts < Stripe::StripeObject
class Schedule < Stripe::StripeObject
# The number of days charges for the account will be held before being paid out.
sig { returns(Integer) }
attr_reader :delay_days
# How frequently funds will be paid out. One of `manual` (payouts only created via API call), `daily`, `weekly`, or `monthly`.
sig { returns(String) }
attr_reader :interval
# The day of the month funds will be paid out. Only shown if `interval` is monthly. Payouts scheduled between the 29th and 31st of the month are sent on the last day of shorter months.
sig { returns(Integer) }
attr_reader :monthly_anchor
# The day of the week funds will be paid out, of the style 'monday', 'tuesday', etc. Only shown if `interval` is weekly.
sig { returns(String) }
attr_reader :weekly_anchor
end
# A Boolean indicating if Stripe should try to reclaim negative balances from an attached bank account. See [Understanding Connect account balances](/connect/account-balances) for details. The default value is `false` when [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts, otherwise `true`.
sig { returns(T::Boolean) }
attr_reader :debit_negative_balances
# Attribute for field schedule
sig { returns(Schedule) }
attr_reader :schedule
# The text that appears on the bank account statement for payouts. If not set, this defaults to the platform's bank descriptor as set in the Dashboard.
sig { returns(T.nilable(String)) }
attr_reader :statement_descriptor
end
class SepaDebitPayments < Stripe::StripeObject
# SEPA creditor identifier that identifies the company making the payment.
sig { returns(String) }
attr_reader :creditor_id
end
class TaxForms < Stripe::StripeObject
# Whether the account opted out of receiving their tax forms by postal delivery.
sig { returns(T::Boolean) }
attr_reader :consented_to_paperless_delivery
end
class Treasury < Stripe::StripeObject
class TosAcceptance < Stripe::StripeObject
# The Unix timestamp marking when the account representative accepted the service agreement.
sig { returns(T.nilable(Integer)) }
attr_reader :date
# The IP address from which the account representative accepted the service agreement.
sig { returns(T.nilable(String)) }
attr_reader :ip
# The user agent of the browser from which the account representative accepted the service agreement.
sig { returns(String) }
attr_reader :user_agent
end
# Attribute for field tos_acceptance
sig { returns(TosAcceptance) }
attr_reader :tos_acceptance
end
# Attribute for field bacs_debit_payments
sig { returns(BacsDebitPayments) }
attr_reader :bacs_debit_payments
# Attribute for field bank_bca_onboarding
sig { returns(BankBcaOnboarding) }
attr_reader :bank_bca_onboarding
# Attribute for field branding
sig { returns(Branding) }
attr_reader :branding
# Attribute for field capital
sig { returns(Capital) }
attr_reader :capital
# Attribute for field card_issuing
sig { returns(CardIssuing) }
attr_reader :card_issuing
# Attribute for field card_payments
sig { returns(CardPayments) }
attr_reader :card_payments
# Attribute for field dashboard
sig { returns(Dashboard) }
attr_reader :dashboard
# Attribute for field invoices
sig { returns(Invoices) }
attr_reader :invoices
# Attribute for field payments
sig { returns(Payments) }
attr_reader :payments
# Attribute for field payouts
sig { returns(Payouts) }
attr_reader :payouts
# Attribute for field sepa_debit_payments
sig { returns(SepaDebitPayments) }
attr_reader :sepa_debit_payments
# Attribute for field tax_forms
sig { returns(TaxForms) }
attr_reader :tax_forms
# Attribute for field treasury
sig { returns(Treasury) }
attr_reader :treasury
end
class TosAcceptance < Stripe::StripeObject
# The Unix timestamp marking when the account representative accepted their service agreement
sig { returns(T.nilable(Integer)) }
attr_reader :date
# The IP address from which the account representative accepted their service agreement
sig { returns(T.nilable(String)) }
attr_reader :ip
# The user's service agreement type
sig { returns(String) }
attr_reader :service_agreement
# The user agent of the browser from which the account representative accepted their service agreement
sig { returns(T.nilable(String)) }
attr_reader :user_agent
end
# Business information about the account.
sig { returns(T.nilable(BusinessProfile)) }
attr_reader :business_profile
# The business type.
sig { returns(T.nilable(String)) }
attr_reader :business_type
# Attribute for field capabilities
sig { returns(Capabilities) }
attr_reader :capabilities
# Whether the account can process charges.
sig { returns(T::Boolean) }
attr_reader :charges_enabled
# Attribute for field company
sig { returns(Company) }
attr_reader :company
# Attribute for field controller
sig { returns(Controller) }
attr_reader :controller
# The account's country.
sig { returns(String) }
attr_reader :country
# Time at which the account was connected. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# Three-letter ISO currency code representing the default currency for the account. This must be a currency that [Stripe supports in the account's country](https://stripe.com/docs/payouts).
sig { returns(String) }
attr_reader :default_currency
# Whether account details have been submitted. Accounts with Stripe Dashboard access, which includes Standard accounts, cannot receive payouts before this is true. Accounts where this is false should be directed to [an onboarding flow](/connect/onboarding) to finish submitting account details.
sig { returns(T::Boolean) }
attr_reader :details_submitted
# An email address associated with the account. It's not used for authentication and Stripe doesn't market to this field without explicit approval from the platform.
sig { returns(T.nilable(String)) }
attr_reader :email
# External accounts (bank accounts and debit cards) currently attached to this account. External accounts are only returned for requests where `controller[is_controller]` is true.
sig { returns(Stripe::ListObject) }
attr_reader :external_accounts
# Attribute for field future_requirements
sig { returns(FutureRequirements) }
attr_reader :future_requirements
# The groups associated with the account.
sig { returns(T.nilable(Groups)) }
attr_reader :groups
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# This is an object representing a person associated with a Stripe account.
#
# A platform can only access a subset of data in a person for an account where [account.controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `stripe`, which includes Standard and Express accounts, after creating an Account Link or Account Session to start Connect onboarding.
#
# See the [Standard onboarding](/connect/standard-accounts) or [Express onboarding](/connect/express-accounts) documentation for information about prefilling information and account onboarding steps. Learn more about [handling identity verification with the API](/connect/handling-api-verification#person-information).
sig { returns(Stripe::Person) }
attr_reader :individual
# 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.
sig { returns(T::Hash[String, String]) }
attr_reader :metadata
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Whether the funds in this account can be paid out.
sig { returns(T::Boolean) }
attr_reader :payouts_enabled
# Attribute for field requirements
sig { returns(Requirements) }
attr_reader :requirements
# Attribute for field risk_controls
sig { returns(RiskControls) }
attr_reader :risk_controls
# Options for customizing how the account functions within Stripe.
sig { returns(T.nilable(Settings)) }
attr_reader :settings
# Attribute for field tos_acceptance
sig { returns(TosAcceptance) }
attr_reader :tos_acceptance
# The Stripe account type. Can be `standard`, `express`, `custom`, or `none`.
sig { returns(String) }
attr_reader :type
# Always true for a deleted object
sig { returns(T::Boolean) }
attr_reader :deleted
class DeleteParams < Stripe::RequestParams; end
class UpdateParams < Stripe::RequestParams
class BankAccount < Stripe::RequestParams
# Attribute for param field object
sig { returns(String) }
attr_accessor :object
# The name of the person or business that owns the bank account.This field is required when attaching the bank account to a `Customer` object.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_name
# The type of entity that holds the account. It can be `company` or `individual`. This field is required when attaching the bank account to a `Customer` object.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_type
# The account number for the bank account, in string form. Must be a checking account.
sig { returns(String) }
attr_accessor :account_number
# The country in which the bank account is located.
sig { returns(String) }
attr_accessor :country
# The currency the bank account is in. This must be a country/currency pairing that [Stripe supports.](docs/payouts)
sig { returns(T.nilable(String)) }
attr_accessor :currency
# The routing number, sort code, or other country-appropriate institution number for the bank account. For US bank accounts, this is required and should be the ACH routing number, not the wire routing number. If you are providing an IBAN for `account_number`, this field is not required.
sig { returns(T.nilable(String)) }
attr_accessor :routing_number
sig {
params(object: String, account_holder_name: T.nilable(String), account_holder_type: T.nilable(String), account_number: String, country: String, currency: T.nilable(String), routing_number: T.nilable(String)).void
}
def initialize(
object: nil,
account_holder_name: nil,
account_holder_type: nil,
account_number: nil,
country: nil,
currency: nil,
routing_number: nil
); end
end
class BusinessProfile < Stripe::RequestParams
class AnnualRevenue < Stripe::RequestParams
# A non-negative integer representing the amount in the [smallest currency unit](/currencies#zero-decimal).
sig { returns(Integer) }
attr_accessor :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).
sig { returns(String) }
attr_accessor :currency
# The close-out date of the preceding fiscal year in ISO 8601 format. E.g. 2023-12-31 for the 31st of December, 2023.
sig { returns(String) }
attr_accessor :fiscal_year_end
sig { params(amount: Integer, currency: String, fiscal_year_end: String).void }
def initialize(amount: nil, currency: nil, fiscal_year_end: nil); end
end
class MonthlyEstimatedRevenue < Stripe::RequestParams
# A non-negative integer representing how much to charge in the [smallest currency unit](/currencies#zero-decimal).
sig { returns(Integer) }
attr_accessor :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).
sig { returns(String) }
attr_accessor :currency
sig { params(amount: Integer, currency: String).void }
def initialize(amount: nil, currency: nil); end
end
class SupportAddress < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# The applicant's gross annual revenue for its preceding fiscal year.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::BusinessProfile::AnnualRevenue)) }
attr_accessor :annual_revenue
# An estimated upper bound of employees, contractors, vendors, etc. currently working for the business.
sig { returns(T.nilable(Integer)) }
attr_accessor :estimated_worker_count
# [The merchant category code for the account](/connect/setting-mcc). MCCs are used to classify businesses based on the goods or services they provide.
sig { returns(T.nilable(String)) }
attr_accessor :mcc
# Whether the business is a minority-owned, women-owned, and/or LGBTQI+-owned business.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :minority_owned_business_designation
# An estimate of the monthly revenue of the business. Only accepted for accounts in Brazil and India.
sig {
returns(T.nilable(::Stripe::Account::UpdateParams::BusinessProfile::MonthlyEstimatedRevenue))
}
attr_accessor :monthly_estimated_revenue
# The customer-facing business name.
sig { returns(T.nilable(String)) }
attr_accessor :name
# Internal-only description of the product sold by, or service provided by, the business. Used by Stripe for risk and underwriting purposes.
sig { returns(T.nilable(String)) }
attr_accessor :product_description
# A publicly available mailing address for sending support issues to.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::BusinessProfile::SupportAddress)) }
attr_accessor :support_address
# A publicly available email address for sending support issues to.
sig { returns(T.nilable(String)) }
attr_accessor :support_email
# A publicly available phone number to call with support issues.
sig { returns(T.nilable(String)) }
attr_accessor :support_phone
# A publicly available website for handling support issues.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :support_url
# The business's publicly available website.
sig { returns(T.nilable(String)) }
attr_accessor :url
sig {
params(annual_revenue: T.nilable(::Stripe::Account::UpdateParams::BusinessProfile::AnnualRevenue), estimated_worker_count: T.nilable(Integer), mcc: T.nilable(String), minority_owned_business_designation: T.nilable(T::Array[String]), monthly_estimated_revenue: T.nilable(::Stripe::Account::UpdateParams::BusinessProfile::MonthlyEstimatedRevenue), name: T.nilable(String), product_description: T.nilable(String), support_address: T.nilable(::Stripe::Account::UpdateParams::BusinessProfile::SupportAddress), support_email: T.nilable(String), support_phone: T.nilable(String), support_url: T.nilable(T.nilable(String)), url: T.nilable(String)).void
}
def initialize(
annual_revenue: nil,
estimated_worker_count: nil,
mcc: nil,
minority_owned_business_designation: nil,
monthly_estimated_revenue: nil,
name: nil,
product_description: nil,
support_address: nil,
support_email: nil,
support_phone: nil,
support_url: nil,
url: nil
); end
end
class Capabilities < Stripe::RequestParams
class AcssDebitPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class AffirmPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class AfterpayClearpayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class AlmaPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class AmazonPayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class AuBecsDebitPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class AutomaticIndirectTax < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class BacsDebitPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class BancontactPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class BankTransferPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class BilliePayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class BlikPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class BoletoPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class CardIssuing < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class CardPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class CartesBancairesPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class CashappPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class EpsPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class FpxPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class GbBankTransferPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class GiropayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class GopayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class GrabpayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class IdBankTransferPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class IdBankTransferPaymentsBca < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class IdealPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class IndiaInternationalPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class JcbPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class JpBankTransferPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class KakaoPayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class KlarnaPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class KonbiniPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class KrCardPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class LegacyPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class LinkPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class MbWayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class MobilepayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class MultibancoPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class MxBankTransferPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class NaverPayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class NzBankAccountBecsDebitPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class OxxoPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class P24Payments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class PayByBankPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class PaycoPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class PaynowPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class PaypalPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class PaytoPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class PixPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class PromptpayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class QrisPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class RechnungPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class RevolutPayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class SamsungPayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class SatispayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class SepaBankTransferPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class SepaDebitPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class ShopeepayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class SofortPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class StripeBalancePayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class SwishPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class TaxReportingUs1099K < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class TaxReportingUs1099Misc < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class Transfers < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class Treasury < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class TreasuryEvolve < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class TreasuryFifthThird < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class TreasuryGoldmanSachs < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class TwintPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class UsBankAccountAchPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class UsBankTransferPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class ZipPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
# The acss_debit_payments capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::AcssDebitPayments)) }
attr_accessor :acss_debit_payments
# The affirm_payments capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::AffirmPayments)) }
attr_accessor :affirm_payments
# The afterpay_clearpay_payments capability.
sig {
returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::AfterpayClearpayPayments))
}
attr_accessor :afterpay_clearpay_payments
# The alma_payments capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::AlmaPayments)) }
attr_accessor :alma_payments
# The amazon_pay_payments capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::AmazonPayPayments)) }
attr_accessor :amazon_pay_payments
# The au_becs_debit_payments capability.
sig {
returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::AuBecsDebitPayments))
}
attr_accessor :au_becs_debit_payments
# The automatic_indirect_tax capability.
sig {
returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::AutomaticIndirectTax))
}
attr_accessor :automatic_indirect_tax
# The bacs_debit_payments capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::BacsDebitPayments)) }
attr_accessor :bacs_debit_payments
# The bancontact_payments capability.
sig {
returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::BancontactPayments))
}
attr_accessor :bancontact_payments
# The bank_transfer_payments capability.
sig {
returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::BankTransferPayments))
}
attr_accessor :bank_transfer_payments
# The billie_payments capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::BilliePayments)) }
attr_accessor :billie_payments
# The blik_payments capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::BlikPayments)) }
attr_accessor :blik_payments
# The boleto_payments capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::BoletoPayments)) }
attr_accessor :boleto_payments
# The card_issuing capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::CardIssuing)) }
attr_accessor :card_issuing
# The card_payments capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::CardPayments)) }
attr_accessor :card_payments
# The cartes_bancaires_payments capability.
sig {
returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::CartesBancairesPayments))
}
attr_accessor :cartes_bancaires_payments
# The cashapp_payments capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::CashappPayments)) }
attr_accessor :cashapp_payments
# The eps_payments capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::EpsPayments)) }
attr_accessor :eps_payments
# The fpx_payments capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::FpxPayments)) }
attr_accessor :fpx_payments
# The gb_bank_transfer_payments capability.
sig {
returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::GbBankTransferPayments))
}
attr_accessor :gb_bank_transfer_payments
# The giropay_payments capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::GiropayPayments)) }
attr_accessor :giropay_payments
# The gopay_payments capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::GopayPayments)) }
attr_accessor :gopay_payments
# The grabpay_payments capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::GrabpayPayments)) }
attr_accessor :grabpay_payments
# The id_bank_transfer_payments capability.
sig {
returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::IdBankTransferPayments))
}
attr_accessor :id_bank_transfer_payments
# The id_bank_transfer_payments_bca capability.
sig {
returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::IdBankTransferPaymentsBca))
}
attr_accessor :id_bank_transfer_payments_bca
# The ideal_payments capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::IdealPayments)) }
attr_accessor :ideal_payments
# The india_international_payments capability.
sig {
returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::IndiaInternationalPayments))
}
attr_accessor :india_international_payments
# The jcb_payments capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::JcbPayments)) }
attr_accessor :jcb_payments
# The jp_bank_transfer_payments capability.
sig {
returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::JpBankTransferPayments))
}
attr_accessor :jp_bank_transfer_payments
# The kakao_pay_payments capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::KakaoPayPayments)) }
attr_accessor :kakao_pay_payments
# The klarna_payments capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::KlarnaPayments)) }
attr_accessor :klarna_payments
# The konbini_payments capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::KonbiniPayments)) }
attr_accessor :konbini_payments
# The kr_card_payments capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::KrCardPayments)) }
attr_accessor :kr_card_payments
# The legacy_payments capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::LegacyPayments)) }
attr_accessor :legacy_payments
# The link_payments capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::LinkPayments)) }
attr_accessor :link_payments
# The mb_way_payments capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::MbWayPayments)) }
attr_accessor :mb_way_payments
# The mobilepay_payments capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::MobilepayPayments)) }
attr_accessor :mobilepay_payments
# The multibanco_payments capability.
sig {
returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::MultibancoPayments))
}
attr_accessor :multibanco_payments
# The mx_bank_transfer_payments capability.
sig {
returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::MxBankTransferPayments))
}
attr_accessor :mx_bank_transfer_payments
# The naver_pay_payments capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::NaverPayPayments)) }
attr_accessor :naver_pay_payments
# The nz_bank_account_becs_debit_payments capability.
sig {
returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::NzBankAccountBecsDebitPayments))
}
attr_accessor :nz_bank_account_becs_debit_payments
# The oxxo_payments capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::OxxoPayments)) }
attr_accessor :oxxo_payments
# The p24_payments capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::P24Payments)) }
attr_accessor :p24_payments
# The pay_by_bank_payments capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::PayByBankPayments)) }
attr_accessor :pay_by_bank_payments
# The payco_payments capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::PaycoPayments)) }
attr_accessor :payco_payments
# The paynow_payments capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::PaynowPayments)) }
attr_accessor :paynow_payments
# The paypal_payments capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::PaypalPayments)) }
attr_accessor :paypal_payments
# The payto_payments capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::PaytoPayments)) }
attr_accessor :payto_payments
# The pix_payments capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::PixPayments)) }
attr_accessor :pix_payments
# The promptpay_payments capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::PromptpayPayments)) }
attr_accessor :promptpay_payments
# The qris_payments capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::QrisPayments)) }
attr_accessor :qris_payments
# The rechnung_payments capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::RechnungPayments)) }
attr_accessor :rechnung_payments
# The revolut_pay_payments capability.
sig {
returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::RevolutPayPayments))
}
attr_accessor :revolut_pay_payments
# The samsung_pay_payments capability.
sig {
returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::SamsungPayPayments))
}
attr_accessor :samsung_pay_payments
# The satispay_payments capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::SatispayPayments)) }
attr_accessor :satispay_payments
# The sepa_bank_transfer_payments capability.
sig {
returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::SepaBankTransferPayments))
}
attr_accessor :sepa_bank_transfer_payments
# The sepa_debit_payments capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::SepaDebitPayments)) }
attr_accessor :sepa_debit_payments
# The shopeepay_payments capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::ShopeepayPayments)) }
attr_accessor :shopeepay_payments
# The sofort_payments capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::SofortPayments)) }
attr_accessor :sofort_payments
# The stripe_balance_payments capability.
sig {
returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::StripeBalancePayments))
}
attr_accessor :stripe_balance_payments
# The swish_payments capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::SwishPayments)) }
attr_accessor :swish_payments
# The tax_reporting_us_1099_k capability.
sig {
returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::TaxReportingUs1099K))
}
attr_accessor :tax_reporting_us_1099_k
# The tax_reporting_us_1099_misc capability.
sig {
returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::TaxReportingUs1099Misc))
}
attr_accessor :tax_reporting_us_1099_misc
# The transfers capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::Transfers)) }
attr_accessor :transfers
# The treasury capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::Treasury)) }
attr_accessor :treasury
# The treasury_evolve capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::TreasuryEvolve)) }
attr_accessor :treasury_evolve
# The treasury_fifth_third capability.
sig {
returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::TreasuryFifthThird))
}
attr_accessor :treasury_fifth_third
# The treasury_goldman_sachs capability.
sig {
returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::TreasuryGoldmanSachs))
}
attr_accessor :treasury_goldman_sachs
# The twint_payments capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::TwintPayments)) }
attr_accessor :twint_payments
# The us_bank_account_ach_payments capability.
sig {
returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::UsBankAccountAchPayments))
}
attr_accessor :us_bank_account_ach_payments
# The us_bank_transfer_payments capability.
sig {
returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::UsBankTransferPayments))
}
attr_accessor :us_bank_transfer_payments
# The zip_payments capability.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities::ZipPayments)) }
attr_accessor :zip_payments
sig {
params(acss_debit_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::AcssDebitPayments), affirm_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::AffirmPayments), afterpay_clearpay_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::AfterpayClearpayPayments), alma_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::AlmaPayments), amazon_pay_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::AmazonPayPayments), au_becs_debit_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::AuBecsDebitPayments), automatic_indirect_tax: T.nilable(::Stripe::Account::UpdateParams::Capabilities::AutomaticIndirectTax), bacs_debit_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::BacsDebitPayments), bancontact_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::BancontactPayments), bank_transfer_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::BankTransferPayments), billie_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::BilliePayments), blik_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::BlikPayments), boleto_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::BoletoPayments), card_issuing: T.nilable(::Stripe::Account::UpdateParams::Capabilities::CardIssuing), card_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::CardPayments), cartes_bancaires_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::CartesBancairesPayments), cashapp_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::CashappPayments), eps_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::EpsPayments), fpx_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::FpxPayments), gb_bank_transfer_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::GbBankTransferPayments), giropay_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::GiropayPayments), gopay_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::GopayPayments), grabpay_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::GrabpayPayments), id_bank_transfer_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::IdBankTransferPayments), id_bank_transfer_payments_bca: T.nilable(::Stripe::Account::UpdateParams::Capabilities::IdBankTransferPaymentsBca), ideal_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::IdealPayments), india_international_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::IndiaInternationalPayments), jcb_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::JcbPayments), jp_bank_transfer_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::JpBankTransferPayments), kakao_pay_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::KakaoPayPayments), klarna_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::KlarnaPayments), konbini_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::KonbiniPayments), kr_card_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::KrCardPayments), legacy_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::LegacyPayments), link_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::LinkPayments), mb_way_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::MbWayPayments), mobilepay_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::MobilepayPayments), multibanco_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::MultibancoPayments), mx_bank_transfer_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::MxBankTransferPayments), naver_pay_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::NaverPayPayments), nz_bank_account_becs_debit_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::NzBankAccountBecsDebitPayments), oxxo_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::OxxoPayments), p24_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::P24Payments), pay_by_bank_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::PayByBankPayments), payco_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::PaycoPayments), paynow_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::PaynowPayments), paypal_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::PaypalPayments), payto_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::PaytoPayments), pix_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::PixPayments), promptpay_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::PromptpayPayments), qris_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::QrisPayments), rechnung_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::RechnungPayments), revolut_pay_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::RevolutPayPayments), samsung_pay_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::SamsungPayPayments), satispay_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::SatispayPayments), sepa_bank_transfer_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::SepaBankTransferPayments), sepa_debit_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::SepaDebitPayments), shopeepay_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::ShopeepayPayments), sofort_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::SofortPayments), stripe_balance_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::StripeBalancePayments), swish_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::SwishPayments), tax_reporting_us_1099_k: T.nilable(::Stripe::Account::UpdateParams::Capabilities::TaxReportingUs1099K), tax_reporting_us_1099_misc: T.nilable(::Stripe::Account::UpdateParams::Capabilities::TaxReportingUs1099Misc), transfers: T.nilable(::Stripe::Account::UpdateParams::Capabilities::Transfers), treasury: T.nilable(::Stripe::Account::UpdateParams::Capabilities::Treasury), treasury_evolve: T.nilable(::Stripe::Account::UpdateParams::Capabilities::TreasuryEvolve), treasury_fifth_third: T.nilable(::Stripe::Account::UpdateParams::Capabilities::TreasuryFifthThird), treasury_goldman_sachs: T.nilable(::Stripe::Account::UpdateParams::Capabilities::TreasuryGoldmanSachs), twint_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::TwintPayments), us_bank_account_ach_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::UsBankAccountAchPayments), us_bank_transfer_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::UsBankTransferPayments), zip_payments: T.nilable(::Stripe::Account::UpdateParams::Capabilities::ZipPayments)).void
}
def initialize(
acss_debit_payments: nil,
affirm_payments: nil,
afterpay_clearpay_payments: nil,
alma_payments: nil,
amazon_pay_payments: nil,
au_becs_debit_payments: nil,
automatic_indirect_tax: nil,
bacs_debit_payments: nil,
bancontact_payments: nil,
bank_transfer_payments: nil,
billie_payments: nil,
blik_payments: nil,
boleto_payments: nil,
card_issuing: nil,
card_payments: nil,
cartes_bancaires_payments: nil,
cashapp_payments: nil,
eps_payments: nil,
fpx_payments: nil,
gb_bank_transfer_payments: nil,
giropay_payments: nil,
gopay_payments: nil,
grabpay_payments: nil,
id_bank_transfer_payments: nil,
id_bank_transfer_payments_bca: nil,
ideal_payments: nil,
india_international_payments: nil,
jcb_payments: nil,
jp_bank_transfer_payments: nil,
kakao_pay_payments: nil,
klarna_payments: nil,
konbini_payments: nil,
kr_card_payments: nil,
legacy_payments: nil,
link_payments: nil,
mb_way_payments: nil,
mobilepay_payments: nil,
multibanco_payments: nil,
mx_bank_transfer_payments: nil,
naver_pay_payments: nil,
nz_bank_account_becs_debit_payments: nil,
oxxo_payments: nil,
p24_payments: nil,
pay_by_bank_payments: nil,
payco_payments: nil,
paynow_payments: nil,
paypal_payments: nil,
payto_payments: nil,
pix_payments: nil,
promptpay_payments: nil,
qris_payments: nil,
rechnung_payments: nil,
revolut_pay_payments: nil,
samsung_pay_payments: nil,
satispay_payments: nil,
sepa_bank_transfer_payments: nil,
sepa_debit_payments: nil,
shopeepay_payments: nil,
sofort_payments: nil,
stripe_balance_payments: nil,
swish_payments: nil,
tax_reporting_us_1099_k: nil,
tax_reporting_us_1099_misc: nil,
transfers: nil,
treasury: nil,
treasury_evolve: nil,
treasury_fifth_third: nil,
treasury_goldman_sachs: nil,
twint_payments: nil,
us_bank_account_ach_payments: nil,
us_bank_transfer_payments: nil,
zip_payments: nil
); end
end
class Card < Stripe::RequestParams
# Attribute for param field object
sig { returns(String) }
attr_accessor :object
# Attribute for param field address_city
sig { returns(T.nilable(String)) }
attr_accessor :address_city
# Attribute for param field address_country
sig { returns(T.nilable(String)) }
attr_accessor :address_country
# Attribute for param field address_line1
sig { returns(T.nilable(String)) }
attr_accessor :address_line1
# Attribute for param field address_line2
sig { returns(T.nilable(String)) }
attr_accessor :address_line2
# Attribute for param field address_state
sig { returns(T.nilable(String)) }
attr_accessor :address_state
# Attribute for param field address_zip
sig { returns(T.nilable(String)) }
attr_accessor :address_zip
# Attribute for param field currency
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Attribute for param field cvc
sig { returns(T.nilable(String)) }
attr_accessor :cvc
# Attribute for param field exp_month
sig { returns(Integer) }
attr_accessor :exp_month
# Attribute for param field exp_year
sig { returns(Integer) }
attr_accessor :exp_year
# Attribute for param field name
sig { returns(T.nilable(String)) }
attr_accessor :name
# Attribute for param field number
sig { returns(String) }
attr_accessor :number
# 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.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Attribute for param field default_for_currency
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :default_for_currency
sig {
params(object: String, address_city: T.nilable(String), address_country: T.nilable(String), address_line1: T.nilable(String), address_line2: T.nilable(String), address_state: T.nilable(String), address_zip: T.nilable(String), currency: T.nilable(String), cvc: T.nilable(String), exp_month: Integer, exp_year: Integer, name: T.nilable(String), number: String, metadata: T.nilable(T::Hash[String, String]), default_for_currency: T.nilable(T::Boolean)).void
}
def initialize(
object: nil,
address_city: nil,
address_country: nil,
address_line1: nil,
address_line2: nil,
address_state: nil,
address_zip: nil,
currency: nil,
cvc: nil,
exp_month: nil,
exp_year: nil,
name: nil,
number: nil,
metadata: nil,
default_for_currency: nil
); end
end
class CardToken < Stripe::RequestParams
# Attribute for param field object
sig { returns(String) }
attr_accessor :object
# Attribute for param field currency
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Attribute for param field token
sig { returns(String) }
attr_accessor :token
sig { params(object: String, currency: T.nilable(String), token: String).void }
def initialize(object: nil, currency: nil, token: nil); end
end
class Company < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class AddressKana < Stripe::RequestParams
# City or ward.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Block or building number.
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Building details.
sig { returns(T.nilable(String)) }
attr_accessor :line2
# Postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# Prefecture.
sig { returns(T.nilable(String)) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_accessor :town
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), town: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
class AddressKanji < Stripe::RequestParams
# City or ward.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Block or building number.
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Building details.
sig { returns(T.nilable(String)) }
attr_accessor :line2
# Postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# Prefecture.
sig { returns(T.nilable(String)) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_accessor :town
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), town: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
class DirectorshipDeclaration < Stripe::RequestParams
# The Unix timestamp marking when the directorship declaration attestation was made.
sig { returns(T.nilable(Integer)) }
attr_accessor :date
# The IP address from which the directorship declaration attestation was made.
sig { returns(T.nilable(String)) }
attr_accessor :ip
# The user agent of the browser from which the directorship declaration attestation was made.
sig { returns(T.nilable(String)) }
attr_accessor :user_agent
sig {
params(date: T.nilable(Integer), ip: T.nilable(String), user_agent: T.nilable(String)).void
}
def initialize(date: nil, ip: nil, user_agent: nil); end
end
class OwnershipDeclaration < Stripe::RequestParams
# The Unix timestamp marking when the beneficial owner attestation was made.
sig { returns(T.nilable(Integer)) }
attr_accessor :date
# The IP address from which the beneficial owner attestation was made.
sig { returns(T.nilable(String)) }
attr_accessor :ip
# The user agent of the browser from which the beneficial owner attestation was made.
sig { returns(T.nilable(String)) }
attr_accessor :user_agent
sig {
params(date: T.nilable(Integer), ip: T.nilable(String), user_agent: T.nilable(String)).void
}
def initialize(date: nil, ip: nil, user_agent: nil); end
end
class RegistrationDate < Stripe::RequestParams
# The day of registration, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of registration, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of registration.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
class Verification < Stripe::RequestParams
class Document < Stripe::RequestParams
# The back of a document returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `additional_verification`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :back
# The front of a document returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `additional_verification`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :front
sig { params(back: T.nilable(String), front: T.nilable(String)).void }
def initialize(back: nil, front: nil); end
end
# A document verifying the business.
sig {
returns(T.nilable(::Stripe::Account::UpdateParams::Company::Verification::Document))
}
attr_accessor :document
sig {
params(document: T.nilable(::Stripe::Account::UpdateParams::Company::Verification::Document)).void
}
def initialize(document: nil); end
end
# The company's primary address.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Company::Address)) }
attr_accessor :address
# The Kana variation of the company's primary address (Japan only).
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Company::AddressKana)) }
attr_accessor :address_kana
# The Kanji variation of the company's primary address (Japan only).
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Company::AddressKanji)) }
attr_accessor :address_kanji
# Whether the company's directors have been provided. Set this Boolean to `true` after creating all the company's directors with [the Persons API](/api/persons) for accounts with a `relationship.director` requirement. This value is not automatically set to `true` after creating directors, so it needs to be updated to indicate all directors have been provided.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :directors_provided
# This hash is used to attest that the directors information provided to Stripe is both current and correct.
sig {
returns(T.nilable(::Stripe::Account::UpdateParams::Company::DirectorshipDeclaration))
}
attr_accessor :directorship_declaration
# Whether the company's executives have been provided. Set this Boolean to `true` after creating all the company's executives with [the Persons API](/api/persons) for accounts with a `relationship.executive` requirement.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :executives_provided
# The export license ID number of the company, also referred as Import Export Code (India only).
sig { returns(T.nilable(String)) }
attr_accessor :export_license_id
# The purpose code to use for export transactions (India only).
sig { returns(T.nilable(String)) }
attr_accessor :export_purpose_code
# The company's legal name.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The Kana variation of the company's legal name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :name_kana
# The Kanji variation of the company's legal name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :name_kanji
# Whether the company's owners have been provided. Set this Boolean to `true` after creating all the company's owners with [the Persons API](/api/persons) for accounts with a `relationship.owner` requirement.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :owners_provided
# This hash is used to attest that the beneficial owner information provided to Stripe is both current and correct.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Company::OwnershipDeclaration)) }
attr_accessor :ownership_declaration
# This value is used to determine if a business is exempt from providing ultimate beneficial owners. See [this support article](https://support.stripe.com/questions/exemption-from-providing-ownership-details) and [changelog](https://docs.stripe.com/changelog/acacia/2025-01-27/ownership-exemption-reason-accounts-api) for more details.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :ownership_exemption_reason
# The company's phone number (used for verification).
sig { returns(T.nilable(String)) }
attr_accessor :phone
# Attribute for param field registration_date
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Account::UpdateParams::Company::RegistrationDate))))
}
attr_accessor :registration_date
# The identification number given to a company when it is registered or incorporated, if distinct from the identification number used for filing taxes. (Examples are the CIN for companies and LLP IN for partnerships in India, and the Company Registration Number in Hong Kong).
sig { returns(T.nilable(String)) }
attr_accessor :registration_number
# The category identifying the legal structure of the company or legal entity. See [Business structure](/connect/identity-verification#business-structure) for more details. Pass an empty string to unset this value.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :structure
# The business ID number of the company, as appropriate for the company’s country. (Examples are an Employer ID Number in the U.S., a Business Number in Canada, or a Company Number in the UK.)
sig { returns(T.nilable(String)) }
attr_accessor :tax_id
# The jurisdiction in which the `tax_id` is registered (Germany-based companies only).
sig { returns(T.nilable(String)) }
attr_accessor :tax_id_registrar
# The VAT number of the company.
sig { returns(T.nilable(String)) }
attr_accessor :vat_id
# Information on the verification state of the company.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Company::Verification)) }
attr_accessor :verification
sig {
params(address: T.nilable(::Stripe::Account::UpdateParams::Company::Address), address_kana: T.nilable(::Stripe::Account::UpdateParams::Company::AddressKana), address_kanji: T.nilable(::Stripe::Account::UpdateParams::Company::AddressKanji), directors_provided: T.nilable(T::Boolean), directorship_declaration: T.nilable(::Stripe::Account::UpdateParams::Company::DirectorshipDeclaration), executives_provided: T.nilable(T::Boolean), export_license_id: T.nilable(String), export_purpose_code: T.nilable(String), name: T.nilable(String), name_kana: T.nilable(String), name_kanji: T.nilable(String), owners_provided: T.nilable(T::Boolean), ownership_declaration: T.nilable(::Stripe::Account::UpdateParams::Company::OwnershipDeclaration), ownership_exemption_reason: T.nilable(T.nilable(T.any(String, String))), phone: T.nilable(String), registration_date: T.nilable(T.nilable(T.any(String, ::Stripe::Account::UpdateParams::Company::RegistrationDate))), registration_number: T.nilable(String), structure: T.nilable(T.nilable(T.any(String, String))), tax_id: T.nilable(String), tax_id_registrar: T.nilable(String), vat_id: T.nilable(String), verification: T.nilable(::Stripe::Account::UpdateParams::Company::Verification)).void
}
def initialize(
address: nil,
address_kana: nil,
address_kanji: nil,
directors_provided: nil,
directorship_declaration: nil,
executives_provided: nil,
export_license_id: nil,
export_purpose_code: nil,
name: nil,
name_kana: nil,
name_kanji: nil,
owners_provided: nil,
ownership_declaration: nil,
ownership_exemption_reason: nil,
phone: nil,
registration_date: nil,
registration_number: nil,
structure: nil,
tax_id: nil,
tax_id_registrar: nil,
vat_id: nil,
verification: nil
); end
end
class Documents < Stripe::RequestParams
class BankAccountOwnershipVerification < Stripe::RequestParams
# One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :files
sig { params(files: T.nilable(T::Array[String])).void }
def initialize(files: nil); end
end
class CompanyLicense < Stripe::RequestParams
# One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :files
sig { params(files: T.nilable(T::Array[String])).void }
def initialize(files: nil); end
end
class CompanyMemorandumOfAssociation < Stripe::RequestParams
# One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :files
sig { params(files: T.nilable(T::Array[String])).void }
def initialize(files: nil); end
end
class CompanyMinisterialDecree < Stripe::RequestParams
# One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :files
sig { params(files: T.nilable(T::Array[String])).void }
def initialize(files: nil); end
end
class CompanyRegistrationVerification < Stripe::RequestParams
# One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :files
sig { params(files: T.nilable(T::Array[String])).void }
def initialize(files: nil); end
end
class CompanyTaxIdVerification < Stripe::RequestParams
# One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :files
sig { params(files: T.nilable(T::Array[String])).void }
def initialize(files: nil); end
end
class ProofOfRegistration < Stripe::RequestParams
# One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :files
sig { params(files: T.nilable(T::Array[String])).void }
def initialize(files: nil); end
end
class ProofOfUltimateBeneficialOwnership < Stripe::RequestParams
# One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :files
sig { params(files: T.nilable(T::Array[String])).void }
def initialize(files: nil); end
end
# One or more documents that support the [Bank account ownership verification](https://support.stripe.com/questions/bank-account-ownership-verification) requirement. Must be a document associated with the account’s primary active bank account that displays the last 4 digits of the account number, either a statement or a check.
sig {
returns(T.nilable(::Stripe::Account::UpdateParams::Documents::BankAccountOwnershipVerification))
}
attr_accessor :bank_account_ownership_verification
# One or more documents that demonstrate proof of a company's license to operate.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Documents::CompanyLicense)) }
attr_accessor :company_license
# One or more documents showing the company's Memorandum of Association.
sig {
returns(T.nilable(::Stripe::Account::UpdateParams::Documents::CompanyMemorandumOfAssociation))
}
attr_accessor :company_memorandum_of_association
# (Certain countries only) One or more documents showing the ministerial decree legalizing the company's establishment.
sig {
returns(T.nilable(::Stripe::Account::UpdateParams::Documents::CompanyMinisterialDecree))
}
attr_accessor :company_ministerial_decree
# One or more documents that demonstrate proof of a company's registration with the appropriate local authorities.
sig {
returns(T.nilable(::Stripe::Account::UpdateParams::Documents::CompanyRegistrationVerification))
}
attr_accessor :company_registration_verification
# One or more documents that demonstrate proof of a company's tax ID.
sig {
returns(T.nilable(::Stripe::Account::UpdateParams::Documents::CompanyTaxIdVerification))
}
attr_accessor :company_tax_id_verification
# One or more documents showing the company’s proof of registration with the national business registry.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Documents::ProofOfRegistration)) }
attr_accessor :proof_of_registration
# One or more documents that demonstrate proof of ultimate beneficial ownership.
sig {
returns(T.nilable(::Stripe::Account::UpdateParams::Documents::ProofOfUltimateBeneficialOwnership))
}
attr_accessor :proof_of_ultimate_beneficial_ownership
sig {
params(bank_account_ownership_verification: T.nilable(::Stripe::Account::UpdateParams::Documents::BankAccountOwnershipVerification), company_license: T.nilable(::Stripe::Account::UpdateParams::Documents::CompanyLicense), company_memorandum_of_association: T.nilable(::Stripe::Account::UpdateParams::Documents::CompanyMemorandumOfAssociation), company_ministerial_decree: T.nilable(::Stripe::Account::UpdateParams::Documents::CompanyMinisterialDecree), company_registration_verification: T.nilable(::Stripe::Account::UpdateParams::Documents::CompanyRegistrationVerification), company_tax_id_verification: T.nilable(::Stripe::Account::UpdateParams::Documents::CompanyTaxIdVerification), proof_of_registration: T.nilable(::Stripe::Account::UpdateParams::Documents::ProofOfRegistration), proof_of_ultimate_beneficial_ownership: T.nilable(::Stripe::Account::UpdateParams::Documents::ProofOfUltimateBeneficialOwnership)).void
}
def initialize(
bank_account_ownership_verification: nil,
company_license: nil,
company_memorandum_of_association: nil,
company_ministerial_decree: nil,
company_registration_verification: nil,
company_tax_id_verification: nil,
proof_of_registration: nil,
proof_of_ultimate_beneficial_ownership: nil
); end
end
class Groups < Stripe::RequestParams
# The group the account is in to determine their payments pricing, and null if the account is on customized pricing. [See the Platform pricing tool documentation](https://stripe.com/docs/connect/platform-pricing-tools) for details.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :payments_pricing
sig { params(payments_pricing: T.nilable(T.nilable(String))).void }
def initialize(payments_pricing: nil); end
end
class Individual < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class AddressKana < Stripe::RequestParams
# City or ward.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Block or building number.
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Building details.
sig { returns(T.nilable(String)) }
attr_accessor :line2
# Postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# Prefecture.
sig { returns(T.nilable(String)) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_accessor :town
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), town: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
class AddressKanji < Stripe::RequestParams
# City or ward.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Block or building number.
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Building details.
sig { returns(T.nilable(String)) }
attr_accessor :line2
# Postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# Prefecture.
sig { returns(T.nilable(String)) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_accessor :town
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), town: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
class Dob < Stripe::RequestParams
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
class RegisteredAddress < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class Relationship < Stripe::RequestParams
# Whether the person is a director of the account's legal entity. Directors are typically members of the governing board of the company, or responsible for ensuring the company meets its regulatory obligations.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :director
# Whether the person has significant responsibility to control, manage, or direct the organization.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :executive
# Whether the person is an owner of the account’s legal entity.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :owner
# The percent owned by the person of the account's legal entity.
sig { returns(T.nilable(T.nilable(T.any(String, Float)))) }
attr_accessor :percent_ownership
# The person's title (e.g., CEO, Support Engineer).
sig { returns(T.nilable(String)) }
attr_accessor :title
sig {
params(director: T.nilable(T::Boolean), executive: T.nilable(T::Boolean), owner: T.nilable(T::Boolean), percent_ownership: T.nilable(T.nilable(T.any(String, Float))), title: T.nilable(String)).void
}
def initialize(
director: nil,
executive: nil,
owner: nil,
percent_ownership: nil,
title: nil
); end
end
class Verification < Stripe::RequestParams
class AdditionalDocument < Stripe::RequestParams
# The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :back
# The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :front
sig { params(back: T.nilable(String), front: T.nilable(String)).void }
def initialize(back: nil, front: nil); end
end
class Document < Stripe::RequestParams
# The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :back
# The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :front
sig { params(back: T.nilable(String), front: T.nilable(String)).void }
def initialize(back: nil, front: nil); end
end
# A document showing address, either a passport, local ID card, or utility bill from a well-known utility company.
sig {
returns(T.nilable(::Stripe::Account::UpdateParams::Individual::Verification::AdditionalDocument))
}
attr_accessor :additional_document
# An identifying document, either a passport or local ID card.
sig {
returns(T.nilable(::Stripe::Account::UpdateParams::Individual::Verification::Document))
}
attr_accessor :document
sig {
params(additional_document: T.nilable(::Stripe::Account::UpdateParams::Individual::Verification::AdditionalDocument), document: T.nilable(::Stripe::Account::UpdateParams::Individual::Verification::Document)).void
}
def initialize(additional_document: nil, document: nil); end
end
# The individual's primary address.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Individual::Address)) }
attr_accessor :address
# The Kana variation of the individual's primary address (Japan only).
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Individual::AddressKana)) }
attr_accessor :address_kana
# The Kanji variation of the individual's primary address (Japan only).
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Individual::AddressKanji)) }
attr_accessor :address_kanji
# The individual's date of birth.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Account::UpdateParams::Individual::Dob))))
}
attr_accessor :dob
# The individual's email address.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The individual's first name.
sig { returns(T.nilable(String)) }
attr_accessor :first_name
# The Kana variation of the individual's first name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :first_name_kana
# The Kanji variation of the individual's first name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :first_name_kanji
# A list of alternate names or aliases that the individual is known by.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :full_name_aliases
# The individual's gender
sig { returns(T.nilable(String)) }
attr_accessor :gender
# The government-issued ID number of the individual, as appropriate for the representative's country. (Examples are a Social Security Number in the U.S., or a Social Insurance Number in Canada). Instead of the number itself, you can also provide a [PII token created with Stripe.js](/js/tokens/create_token?type=pii).
sig { returns(T.nilable(String)) }
attr_accessor :id_number
# The government-issued secondary ID number of the individual, as appropriate for the representative's country, will be used for enhanced verification checks. In Thailand, this would be the laser code found on the back of an ID card. Instead of the number itself, you can also provide a [PII token created with Stripe.js](/js/tokens/create_token?type=pii).
sig { returns(T.nilable(String)) }
attr_accessor :id_number_secondary
# The individual's last name.
sig { returns(T.nilable(String)) }
attr_accessor :last_name
# The Kana variation of the individual's last name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :last_name_kana
# The Kanji variation of the individual's last name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :last_name_kanji
# The individual's maiden name.
sig { returns(T.nilable(String)) }
attr_accessor :maiden_name
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# The individual's phone number.
sig { returns(T.nilable(String)) }
attr_accessor :phone
# Indicates if the person or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction.
sig { returns(T.nilable(String)) }
attr_accessor :political_exposure
# The individual's registered address.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Individual::RegisteredAddress)) }
attr_accessor :registered_address
# Describes the person’s relationship to the account.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Individual::Relationship)) }
attr_accessor :relationship
# The last four digits of the individual's Social Security Number (U.S. only).
sig { returns(T.nilable(String)) }
attr_accessor :ssn_last_4
# The individual's verification document information.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Individual::Verification)) }
attr_accessor :verification
sig {
params(address: T.nilable(::Stripe::Account::UpdateParams::Individual::Address), address_kana: T.nilable(::Stripe::Account::UpdateParams::Individual::AddressKana), address_kanji: T.nilable(::Stripe::Account::UpdateParams::Individual::AddressKanji), dob: T.nilable(T.nilable(T.any(String, ::Stripe::Account::UpdateParams::Individual::Dob))), email: T.nilable(String), first_name: T.nilable(String), first_name_kana: T.nilable(String), first_name_kanji: T.nilable(String), full_name_aliases: T.nilable(T.nilable(T.any(String, T::Array[String]))), gender: T.nilable(String), id_number: T.nilable(String), id_number_secondary: T.nilable(String), last_name: T.nilable(String), last_name_kana: T.nilable(String), last_name_kanji: T.nilable(String), maiden_name: T.nilable(String), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), phone: T.nilable(String), political_exposure: T.nilable(String), registered_address: T.nilable(::Stripe::Account::UpdateParams::Individual::RegisteredAddress), relationship: T.nilable(::Stripe::Account::UpdateParams::Individual::Relationship), ssn_last_4: T.nilable(String), verification: T.nilable(::Stripe::Account::UpdateParams::Individual::Verification)).void
}
def initialize(
address: nil,
address_kana: nil,
address_kanji: nil,
dob: nil,
email: nil,
first_name: nil,
first_name_kana: nil,
first_name_kanji: nil,
full_name_aliases: nil,
gender: nil,
id_number: nil,
id_number_secondary: nil,
last_name: nil,
last_name_kana: nil,
last_name_kanji: nil,
maiden_name: nil,
metadata: nil,
phone: nil,
political_exposure: nil,
registered_address: nil,
relationship: nil,
ssn_last_4: nil,
verification: nil
); end
end
class RiskControls < Stripe::RequestParams
class Charges < Stripe::RequestParams
# To request to pause a risk control, pass `true`. To request to unpause a risk control, pass `false`.
# There can be a delay before the risk control is paused or unpaused.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :pause_requested
sig { params(pause_requested: T.nilable(T::Boolean)).void }
def initialize(pause_requested: nil); end
end
class Payouts < Stripe::RequestParams
# To request to pause a risk control, pass `true`. To request to unpause a risk control, pass `false`.
# There can be a delay before the risk control is paused or unpaused.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :pause_requested
sig { params(pause_requested: T.nilable(T::Boolean)).void }
def initialize(pause_requested: nil); end
end
# Represents the risk control status of charges. Please see [this page for more details](https://stripe.com/docs/connect/pausing-payments-or-payouts-on-connected-accounts).
sig { returns(T.nilable(::Stripe::Account::UpdateParams::RiskControls::Charges)) }
attr_accessor :charges
# Represents the risk control status of payouts. Please see [this page for more details](https://stripe.com/docs/connect/pausing-payments-or-payouts-on-connected-accounts).
sig { returns(T.nilable(::Stripe::Account::UpdateParams::RiskControls::Payouts)) }
attr_accessor :payouts
sig {
params(charges: T.nilable(::Stripe::Account::UpdateParams::RiskControls::Charges), payouts: T.nilable(::Stripe::Account::UpdateParams::RiskControls::Payouts)).void
}
def initialize(charges: nil, payouts: nil); end
end
class Settings < Stripe::RequestParams
class BacsDebitPayments < Stripe::RequestParams
# The Bacs Direct Debit Display Name for this account. For payments made with Bacs Direct Debit, this name appears on the mandate as the statement descriptor. Mobile banking apps display it as the name of the business. To use custom branding, set the Bacs Direct Debit Display Name during or right after creation. Custom branding incurs an additional monthly fee for the platform. If you don't set the display name before requesting Bacs capability, it's automatically set as "Stripe" and the account is onboarded to Stripe branding, which is free.
sig { returns(T.nilable(String)) }
attr_accessor :display_name
sig { params(display_name: T.nilable(String)).void }
def initialize(display_name: nil); end
end
class BankBcaOnboarding < Stripe::RequestParams
# Bank BCA business account holder name
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_name
# Bank BCA business account number
sig { returns(T.nilable(String)) }
attr_accessor :business_account_number
sig {
params(account_holder_name: T.nilable(String), business_account_number: T.nilable(String)).void
}
def initialize(account_holder_name: nil, business_account_number: nil); end
end
class Branding < Stripe::RequestParams
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) An icon for the account. Must be square and at least 128px x 128px.
sig { returns(T.nilable(String)) }
attr_accessor :icon
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) A logo for the account that will be used in Checkout instead of the icon and without the account's name next to it if provided. Must be at least 128px x 128px.
sig { returns(T.nilable(String)) }
attr_accessor :logo
# A CSS hex color value representing the primary branding color for this account.
sig { returns(T.nilable(String)) }
attr_accessor :primary_color
# A CSS hex color value representing the secondary branding color for this account.
sig { returns(T.nilable(String)) }
attr_accessor :secondary_color
sig {
params(icon: T.nilable(String), logo: T.nilable(String), primary_color: T.nilable(String), secondary_color: T.nilable(String)).void
}
def initialize(icon: nil, logo: nil, primary_color: nil, secondary_color: nil); end
end
class Capital < Stripe::RequestParams
# Per-currency mapping of user-selected destination accounts used to pay out loans.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :payout_destination
# Per-currency mapping of all destination accounts eligible to receive Capital financing payouts.
sig { returns(T.nilable(T::Hash[String, T::Array[String]])) }
attr_accessor :payout_destination_selector
sig {
params(payout_destination: T.nilable(T::Hash[String, String]), payout_destination_selector: T.nilable(T::Hash[String, T::Array[String]])).void
}
def initialize(payout_destination: nil, payout_destination_selector: nil); end
end
class CardIssuing < Stripe::RequestParams
class TosAcceptance < Stripe::RequestParams
# The Unix timestamp marking when the account representative accepted the service agreement.
sig { returns(T.nilable(Integer)) }
attr_accessor :date
# The IP address from which the account representative accepted the service agreement.
sig { returns(T.nilable(String)) }
attr_accessor :ip
# The user agent of the browser from which the account representative accepted the service agreement.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :user_agent
sig {
params(date: T.nilable(Integer), ip: T.nilable(String), user_agent: T.nilable(T.nilable(String))).void
}
def initialize(date: nil, ip: nil, user_agent: nil); end
end
# Details on the account's acceptance of the [Stripe Issuing Terms and Disclosures](/issuing/connect/tos_acceptance).
sig {
returns(T.nilable(::Stripe::Account::UpdateParams::Settings::CardIssuing::TosAcceptance))
}
attr_accessor :tos_acceptance
sig {
params(tos_acceptance: T.nilable(::Stripe::Account::UpdateParams::Settings::CardIssuing::TosAcceptance)).void
}
def initialize(tos_acceptance: nil); end
end
class CardPayments < Stripe::RequestParams
class DeclineOn < Stripe::RequestParams
# Whether Stripe automatically declines charges with an incorrect ZIP or postal code. This setting only applies when a ZIP or postal code is provided and they fail bank verification.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :avs_failure
# Whether Stripe automatically declines charges with an incorrect CVC. This setting only applies when a CVC is provided and it fails bank verification.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :cvc_failure
sig {
params(avs_failure: T.nilable(T::Boolean), cvc_failure: T.nilable(T::Boolean)).void
}
def initialize(avs_failure: nil, cvc_failure: nil); end
end
# Automatically declines certain charge types regardless of whether the card issuer accepted or declined the charge.
sig {
returns(T.nilable(::Stripe::Account::UpdateParams::Settings::CardPayments::DeclineOn))
}
attr_accessor :decline_on
# The default text that appears on credit card statements when a charge is made. This field prefixes any dynamic `statement_descriptor` specified on the charge. `statement_descriptor_prefix` is useful for maximizing descriptor space for the dynamic portion.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor_prefix
# The Kana variation of the default text that appears on credit card statements when a charge is made (Japan only). This field prefixes any dynamic `statement_descriptor_suffix_kana` specified on the charge. `statement_descriptor_prefix_kana` is useful for maximizing descriptor space for the dynamic portion.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :statement_descriptor_prefix_kana
# The Kanji variation of the default text that appears on credit card statements when a charge is made (Japan only). This field prefixes any dynamic `statement_descriptor_suffix_kanji` specified on the charge. `statement_descriptor_prefix_kanji` is useful for maximizing descriptor space for the dynamic portion.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :statement_descriptor_prefix_kanji
sig {
params(decline_on: T.nilable(::Stripe::Account::UpdateParams::Settings::CardPayments::DeclineOn), statement_descriptor_prefix: T.nilable(String), statement_descriptor_prefix_kana: T.nilable(T.nilable(String)), statement_descriptor_prefix_kanji: T.nilable(T.nilable(String))).void
}
def initialize(
decline_on: nil,
statement_descriptor_prefix: nil,
statement_descriptor_prefix_kana: nil,
statement_descriptor_prefix_kanji: nil
); end
end
class Invoices < Stripe::RequestParams
# The list of default Account Tax IDs to automatically include on invoices. Account Tax IDs get added when an invoice is finalized.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :default_account_tax_ids
# Whether payment methods should be saved when a payment is completed for a one-time invoices on a hosted invoice page.
sig { returns(T.nilable(String)) }
attr_accessor :hosted_payment_method_save
sig {
params(default_account_tax_ids: T.nilable(T.nilable(T.any(String, T::Array[String]))), hosted_payment_method_save: T.nilable(String)).void
}
def initialize(default_account_tax_ids: nil, hosted_payment_method_save: nil); end
end
class Payments < Stripe::RequestParams
# The default text that appears on statements for non-card charges outside of Japan. For card charges, if you don't set a `statement_descriptor_prefix`, this text is also used as the statement descriptor prefix. In that case, if concatenating the statement descriptor suffix causes the combined statement descriptor to exceed 22 characters, we truncate the `statement_descriptor` text to limit the full descriptor to 22 characters. For more information about statement descriptors and their requirements, see the [account settings documentation](https://docs.stripe.com/get-started/account/statement-descriptors).
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
# The Kana variation of `statement_descriptor` used for charges in Japan. Japanese statement descriptors have [special requirements](https://docs.stripe.com/get-started/account/statement-descriptors#set-japanese-statement-descriptors).
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor_kana
# The Kanji variation of `statement_descriptor` used for charges in Japan. Japanese statement descriptors have [special requirements](https://docs.stripe.com/get-started/account/statement-descriptors#set-japanese-statement-descriptors).
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor_kanji
sig {
params(statement_descriptor: T.nilable(String), statement_descriptor_kana: T.nilable(String), statement_descriptor_kanji: T.nilable(String)).void
}
def initialize(
statement_descriptor: nil,
statement_descriptor_kana: nil,
statement_descriptor_kanji: nil
); end
end
class Payouts < Stripe::RequestParams
class Schedule < Stripe::RequestParams
# The number of days charge funds are held before being paid out. May also be set to `minimum`, representing the lowest available value for the account country. Default is `minimum`. The `delay_days` parameter remains at the last configured value if `interval` is `manual`. [Learn more about controlling payout delay days](/connect/manage-payout-schedule).
sig { returns(T.nilable(T.any(String, Integer))) }
attr_accessor :delay_days
# How frequently available funds are paid out. One of: `daily`, `manual`, `weekly`, or `monthly`. Default is `daily`.
sig { returns(T.nilable(String)) }
attr_accessor :interval
# The day of the month when available funds are paid out, specified as a number between 1--31. Payouts nominally scheduled between the 29th and 31st of the month are instead sent on the last day of a shorter month. Required and applicable only if `interval` is `monthly`.
sig { returns(T.nilable(Integer)) }
attr_accessor :monthly_anchor
# The day of the week when available funds are paid out, specified as `monday`, `tuesday`, etc. (required and applicable only if `interval` is `weekly`.)
sig { returns(T.nilable(String)) }
attr_accessor :weekly_anchor
sig {
params(delay_days: T.nilable(T.any(String, Integer)), interval: T.nilable(String), monthly_anchor: T.nilable(Integer), weekly_anchor: T.nilable(String)).void
}
def initialize(
delay_days: nil,
interval: nil,
monthly_anchor: nil,
weekly_anchor: nil
); end
end
# A Boolean indicating whether Stripe should try to reclaim negative balances from an attached bank account. For details, see [Understanding Connect Account Balances](/connect/account-balances).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :debit_negative_balances
# Details on when funds from charges are available, and when they are paid out to an external account. For details, see our [Setting Bank and Debit Card Payouts](/connect/bank-transfers#payout-information) documentation.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Settings::Payouts::Schedule)) }
attr_accessor :schedule
# The text that appears on the bank account statement for payouts. If not set, this defaults to the platform's bank descriptor as set in the Dashboard.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
sig {
params(debit_negative_balances: T.nilable(T::Boolean), schedule: T.nilable(::Stripe::Account::UpdateParams::Settings::Payouts::Schedule), statement_descriptor: T.nilable(String)).void
}
def initialize(
debit_negative_balances: nil,
schedule: nil,
statement_descriptor: nil
); end
end
class TaxForms < Stripe::RequestParams
# Whether the account opted out of receiving their tax forms by postal delivery.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :consented_to_paperless_delivery
sig { params(consented_to_paperless_delivery: T.nilable(T::Boolean)).void }
def initialize(consented_to_paperless_delivery: nil); end
end
class Treasury < Stripe::RequestParams
class TosAcceptance < Stripe::RequestParams
# The Unix timestamp marking when the account representative accepted the service agreement.
sig { returns(T.nilable(Integer)) }
attr_accessor :date
# The IP address from which the account representative accepted the service agreement.
sig { returns(T.nilable(String)) }
attr_accessor :ip
# The user agent of the browser from which the account representative accepted the service agreement.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :user_agent
sig {
params(date: T.nilable(Integer), ip: T.nilable(String), user_agent: T.nilable(T.nilable(String))).void
}
def initialize(date: nil, ip: nil, user_agent: nil); end
end
# Details on the account's acceptance of the Stripe Treasury Services Agreement.
sig {
returns(T.nilable(::Stripe::Account::UpdateParams::Settings::Treasury::TosAcceptance))
}
attr_accessor :tos_acceptance
sig {
params(tos_acceptance: T.nilable(::Stripe::Account::UpdateParams::Settings::Treasury::TosAcceptance)).void
}
def initialize(tos_acceptance: nil); end
end
# Settings specific to Bacs Direct Debit payments.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Settings::BacsDebitPayments)) }
attr_accessor :bacs_debit_payments
# Settings specific to bank BCA onboarding for Indonesia bank transfers payments method.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Settings::BankBcaOnboarding)) }
attr_accessor :bank_bca_onboarding
# Settings used to apply the account's branding to email receipts, invoices, Checkout, and other products.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Settings::Branding)) }
attr_accessor :branding
# Settings specific to the account's use of the Capital product.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Settings::Capital)) }
attr_accessor :capital
# Settings specific to the account's use of the Card Issuing product.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Settings::CardIssuing)) }
attr_accessor :card_issuing
# Settings specific to card charging on the account.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Settings::CardPayments)) }
attr_accessor :card_payments
# Settings specific to the account's use of Invoices.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Settings::Invoices)) }
attr_accessor :invoices
# Settings that apply across payment methods for charging on the account.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Settings::Payments)) }
attr_accessor :payments
# Settings specific to the account's payouts.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Settings::Payouts)) }
attr_accessor :payouts
# Settings specific to the account's tax forms.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Settings::TaxForms)) }
attr_accessor :tax_forms
# Settings specific to the account's Treasury FinancialAccounts.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Settings::Treasury)) }
attr_accessor :treasury
sig {
params(bacs_debit_payments: T.nilable(::Stripe::Account::UpdateParams::Settings::BacsDebitPayments), bank_bca_onboarding: T.nilable(::Stripe::Account::UpdateParams::Settings::BankBcaOnboarding), branding: T.nilable(::Stripe::Account::UpdateParams::Settings::Branding), capital: T.nilable(::Stripe::Account::UpdateParams::Settings::Capital), card_issuing: T.nilable(::Stripe::Account::UpdateParams::Settings::CardIssuing), card_payments: T.nilable(::Stripe::Account::UpdateParams::Settings::CardPayments), invoices: T.nilable(::Stripe::Account::UpdateParams::Settings::Invoices), payments: T.nilable(::Stripe::Account::UpdateParams::Settings::Payments), payouts: T.nilable(::Stripe::Account::UpdateParams::Settings::Payouts), tax_forms: T.nilable(::Stripe::Account::UpdateParams::Settings::TaxForms), treasury: T.nilable(::Stripe::Account::UpdateParams::Settings::Treasury)).void
}
def initialize(
bacs_debit_payments: nil,
bank_bca_onboarding: nil,
branding: nil,
capital: nil,
card_issuing: nil,
card_payments: nil,
invoices: nil,
payments: nil,
payouts: nil,
tax_forms: nil,
treasury: nil
); end
end
class TosAcceptance < Stripe::RequestParams
# The Unix timestamp marking when the account representative accepted their service agreement.
sig { returns(T.nilable(Integer)) }
attr_accessor :date
# The IP address from which the account representative accepted their service agreement.
sig { returns(T.nilable(String)) }
attr_accessor :ip
# The user's service agreement type.
sig { returns(T.nilable(String)) }
attr_accessor :service_agreement
# The user agent of the browser from which the account representative accepted their service agreement.
sig { returns(T.nilable(String)) }
attr_accessor :user_agent
sig {
params(date: T.nilable(Integer), ip: T.nilable(String), service_agreement: T.nilable(String), user_agent: T.nilable(String)).void
}
def initialize(date: nil, ip: nil, service_agreement: nil, user_agent: nil); end
end
# An [account token](https://stripe.com/docs/api#create_account_token), used to securely provide details to the account.
sig { returns(T.nilable(String)) }
attr_accessor :account_token
# Business information about the account.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::BusinessProfile)) }
attr_accessor :business_profile
# The business type. Once you create an [Account Link](/api/account_links) or [Account Session](/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.
sig { returns(T.nilable(String)) }
attr_accessor :business_type
# Each key of the dictionary represents a capability, and each capability
# maps to its settings (for example, whether it has been requested or not). Each
# capability is inactive until you have provided its specific
# requirements and Stripe has verified them. An account might have some
# of its requested capabilities be active and some be inactive.
#
# Required when [account.controller.stripe_dashboard.type](/api/accounts/create#create_account-controller-dashboard-type)
# is `none`, which includes Custom accounts.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Capabilities)) }
attr_accessor :capabilities
# Information about the company or business. This field is available for any `business_type`. Once you create an [Account Link](/api/account_links) or [Account Session](/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Company)) }
attr_accessor :company
# Three-letter ISO currency code representing the default currency for the account. This must be a currency that [Stripe supports in the account's country](https://docs.stripe.com/payouts).
sig { returns(T.nilable(String)) }
attr_accessor :default_currency
# Documents that may be submitted to satisfy various informational requests.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Documents)) }
attr_accessor :documents
# The email address of the account holder. This is only to make the account easier to identify to you. If [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts, Stripe doesn't email the account without your consent.
sig { returns(T.nilable(String)) }
attr_accessor :email
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A card or bank account to attach to the account for receiving [payouts](/connect/bank-debit-card-payouts) (you won’t be able to use it for top-ups). You can provide either a token, like the ones returned by [Stripe.js](/js), or a dictionary, as documented in the `external_account` parameter for [bank account](/api#account_create_bank_account) creation.
By default, providing an external account sets it as the new default external account for its currency, and deletes the old default if one exists. To add additional external accounts without replacing the existing default for the currency, use the [bank account](/api#account_create_bank_account) or [card creation](/api#account_create_card) APIs. After you create an [Account Link](/api/account_links) or [Account Session](/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.
sig {
returns(T.nilable(T.nilable(T.any(String, T.any(String, ::Stripe::Account::UpdateParams::BankAccount, ::Stripe::Account::UpdateParams::Card, ::Stripe::Account::UpdateParams::CardToken)))))
}
attr_accessor :external_account
# A hash of account group type to tokens. These are account groups this account should be added to.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Groups)) }
attr_accessor :groups
# Information about the person represented by the account. This field is null unless `business_type` is set to `individual`. Once you create an [Account Link](/api/account_links) or [Account Session](/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Individual)) }
attr_accessor :individual
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# A hash to configure risk controls on the account. Please see [this page for more details](/connect/pausing-payments-or-payouts-on-connected-accounts).
sig { returns(T.nilable(::Stripe::Account::UpdateParams::RiskControls)) }
attr_accessor :risk_controls
# Options for customizing how the account functions within Stripe.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::Settings)) }
attr_accessor :settings
# Details on the account's acceptance of the [Stripe Services Agreement](/connect/updating-accounts#tos-acceptance). This property can only be updated for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts. This property defaults to a `full` service agreement when empty.
sig { returns(T.nilable(::Stripe::Account::UpdateParams::TosAcceptance)) }
attr_accessor :tos_acceptance
sig {
params(account_token: T.nilable(String), business_profile: T.nilable(::Stripe::Account::UpdateParams::BusinessProfile), business_type: T.nilable(String), capabilities: T.nilable(::Stripe::Account::UpdateParams::Capabilities), company: T.nilable(::Stripe::Account::UpdateParams::Company), default_currency: T.nilable(String), documents: T.nilable(::Stripe::Account::UpdateParams::Documents), email: T.nilable(String), expand: T.nilable(T::Array[String]), external_account: T.nilable(T.nilable(T.any(String, T.any(String, ::Stripe::Account::UpdateParams::BankAccount, ::Stripe::Account::UpdateParams::Card, ::Stripe::Account::UpdateParams::CardToken)))), groups: T.nilable(::Stripe::Account::UpdateParams::Groups), individual: T.nilable(::Stripe::Account::UpdateParams::Individual), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), risk_controls: T.nilable(::Stripe::Account::UpdateParams::RiskControls), settings: T.nilable(::Stripe::Account::UpdateParams::Settings), tos_acceptance: T.nilable(::Stripe::Account::UpdateParams::TosAcceptance)).void
}
def initialize(
account_token: nil,
business_profile: nil,
business_type: nil,
capabilities: nil,
company: nil,
default_currency: nil,
documents: nil,
email: nil,
expand: nil,
external_account: nil,
groups: nil,
individual: nil,
metadata: nil,
risk_controls: nil,
settings: nil,
tos_acceptance: nil
); end
end
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return connected accounts that were created during the given date interval.
sig { returns(T.nilable(T.any(::Stripe::Account::ListParams::Created, Integer))) }
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(created: T.nilable(T.any(::Stripe::Account::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class BankAccount < Stripe::RequestParams
# Attribute for param field object
sig { returns(String) }
attr_accessor :object
# The name of the person or business that owns the bank account.This field is required when attaching the bank account to a `Customer` object.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_name
# The type of entity that holds the account. It can be `company` or `individual`. This field is required when attaching the bank account to a `Customer` object.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_type
# The account number for the bank account, in string form. Must be a checking account.
sig { returns(String) }
attr_accessor :account_number
# The country in which the bank account is located.
sig { returns(String) }
attr_accessor :country
# The currency the bank account is in. This must be a country/currency pairing that [Stripe supports.](docs/payouts)
sig { returns(T.nilable(String)) }
attr_accessor :currency
# The routing number, sort code, or other country-appropriate institution number for the bank account. For US bank accounts, this is required and should be the ACH routing number, not the wire routing number. If you are providing an IBAN for `account_number`, this field is not required.
sig { returns(T.nilable(String)) }
attr_accessor :routing_number
sig {
params(object: String, account_holder_name: T.nilable(String), account_holder_type: T.nilable(String), account_number: String, country: String, currency: T.nilable(String), routing_number: T.nilable(String)).void
}
def initialize(
object: nil,
account_holder_name: nil,
account_holder_type: nil,
account_number: nil,
country: nil,
currency: nil,
routing_number: nil
); end
end
class BusinessProfile < Stripe::RequestParams
class AnnualRevenue < Stripe::RequestParams
# A non-negative integer representing the amount in the [smallest currency unit](/currencies#zero-decimal).
sig { returns(Integer) }
attr_accessor :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).
sig { returns(String) }
attr_accessor :currency
# The close-out date of the preceding fiscal year in ISO 8601 format. E.g. 2023-12-31 for the 31st of December, 2023.
sig { returns(String) }
attr_accessor :fiscal_year_end
sig { params(amount: Integer, currency: String, fiscal_year_end: String).void }
def initialize(amount: nil, currency: nil, fiscal_year_end: nil); end
end
class MonthlyEstimatedRevenue < Stripe::RequestParams
# A non-negative integer representing how much to charge in the [smallest currency unit](/currencies#zero-decimal).
sig { returns(Integer) }
attr_accessor :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).
sig { returns(String) }
attr_accessor :currency
sig { params(amount: Integer, currency: String).void }
def initialize(amount: nil, currency: nil); end
end
class SupportAddress < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# The applicant's gross annual revenue for its preceding fiscal year.
sig { returns(T.nilable(::Stripe::Account::CreateParams::BusinessProfile::AnnualRevenue)) }
attr_accessor :annual_revenue
# An estimated upper bound of employees, contractors, vendors, etc. currently working for the business.
sig { returns(T.nilable(Integer)) }
attr_accessor :estimated_worker_count
# [The merchant category code for the account](/connect/setting-mcc). MCCs are used to classify businesses based on the goods or services they provide.
sig { returns(T.nilable(String)) }
attr_accessor :mcc
# Whether the business is a minority-owned, women-owned, and/or LGBTQI+-owned business.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :minority_owned_business_designation
# An estimate of the monthly revenue of the business. Only accepted for accounts in Brazil and India.
sig {
returns(T.nilable(::Stripe::Account::CreateParams::BusinessProfile::MonthlyEstimatedRevenue))
}
attr_accessor :monthly_estimated_revenue
# The customer-facing business name.
sig { returns(T.nilable(String)) }
attr_accessor :name
# Internal-only description of the product sold by, or service provided by, the business. Used by Stripe for risk and underwriting purposes.
sig { returns(T.nilable(String)) }
attr_accessor :product_description
# A publicly available mailing address for sending support issues to.
sig { returns(T.nilable(::Stripe::Account::CreateParams::BusinessProfile::SupportAddress)) }
attr_accessor :support_address
# A publicly available email address for sending support issues to.
sig { returns(T.nilable(String)) }
attr_accessor :support_email
# A publicly available phone number to call with support issues.
sig { returns(T.nilable(String)) }
attr_accessor :support_phone
# A publicly available website for handling support issues.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :support_url
# The business's publicly available website.
sig { returns(T.nilable(String)) }
attr_accessor :url
sig {
params(annual_revenue: T.nilable(::Stripe::Account::CreateParams::BusinessProfile::AnnualRevenue), estimated_worker_count: T.nilable(Integer), mcc: T.nilable(String), minority_owned_business_designation: T.nilable(T::Array[String]), monthly_estimated_revenue: T.nilable(::Stripe::Account::CreateParams::BusinessProfile::MonthlyEstimatedRevenue), name: T.nilable(String), product_description: T.nilable(String), support_address: T.nilable(::Stripe::Account::CreateParams::BusinessProfile::SupportAddress), support_email: T.nilable(String), support_phone: T.nilable(String), support_url: T.nilable(T.nilable(String)), url: T.nilable(String)).void
}
def initialize(
annual_revenue: nil,
estimated_worker_count: nil,
mcc: nil,
minority_owned_business_designation: nil,
monthly_estimated_revenue: nil,
name: nil,
product_description: nil,
support_address: nil,
support_email: nil,
support_phone: nil,
support_url: nil,
url: nil
); end
end
class Capabilities < Stripe::RequestParams
class AcssDebitPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class AffirmPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class AfterpayClearpayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class AlmaPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class AmazonPayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class AuBecsDebitPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class AutomaticIndirectTax < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class BacsDebitPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class BancontactPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class BankTransferPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class BilliePayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class BlikPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class BoletoPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class CardIssuing < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class CardPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class CartesBancairesPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class CashappPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class EpsPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class FpxPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class GbBankTransferPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class GiropayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class GopayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class GrabpayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class IdBankTransferPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class IdBankTransferPaymentsBca < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class IdealPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class IndiaInternationalPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class JcbPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class JpBankTransferPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class KakaoPayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class KlarnaPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class KonbiniPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class KrCardPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class LegacyPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class LinkPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class MbWayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class MobilepayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class MultibancoPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class MxBankTransferPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class NaverPayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class NzBankAccountBecsDebitPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class OxxoPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class P24Payments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class PayByBankPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class PaycoPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class PaynowPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class PaypalPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class PaytoPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class PixPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class PromptpayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class QrisPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class RechnungPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class RevolutPayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class SamsungPayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class SatispayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class SepaBankTransferPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class SepaDebitPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class ShopeepayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class SofortPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class StripeBalancePayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class SwishPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class TaxReportingUs1099K < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class TaxReportingUs1099Misc < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class Transfers < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class Treasury < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class TreasuryEvolve < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class TreasuryFifthThird < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class TreasuryGoldmanSachs < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class TwintPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class UsBankAccountAchPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class UsBankTransferPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class ZipPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
# The acss_debit_payments capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::AcssDebitPayments)) }
attr_accessor :acss_debit_payments
# The affirm_payments capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::AffirmPayments)) }
attr_accessor :affirm_payments
# The afterpay_clearpay_payments capability.
sig {
returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::AfterpayClearpayPayments))
}
attr_accessor :afterpay_clearpay_payments
# The alma_payments capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::AlmaPayments)) }
attr_accessor :alma_payments
# The amazon_pay_payments capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::AmazonPayPayments)) }
attr_accessor :amazon_pay_payments
# The au_becs_debit_payments capability.
sig {
returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::AuBecsDebitPayments))
}
attr_accessor :au_becs_debit_payments
# The automatic_indirect_tax capability.
sig {
returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::AutomaticIndirectTax))
}
attr_accessor :automatic_indirect_tax
# The bacs_debit_payments capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::BacsDebitPayments)) }
attr_accessor :bacs_debit_payments
# The bancontact_payments capability.
sig {
returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::BancontactPayments))
}
attr_accessor :bancontact_payments
# The bank_transfer_payments capability.
sig {
returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::BankTransferPayments))
}
attr_accessor :bank_transfer_payments
# The billie_payments capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::BilliePayments)) }
attr_accessor :billie_payments
# The blik_payments capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::BlikPayments)) }
attr_accessor :blik_payments
# The boleto_payments capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::BoletoPayments)) }
attr_accessor :boleto_payments
# The card_issuing capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::CardIssuing)) }
attr_accessor :card_issuing
# The card_payments capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::CardPayments)) }
attr_accessor :card_payments
# The cartes_bancaires_payments capability.
sig {
returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::CartesBancairesPayments))
}
attr_accessor :cartes_bancaires_payments
# The cashapp_payments capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::CashappPayments)) }
attr_accessor :cashapp_payments
# The eps_payments capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::EpsPayments)) }
attr_accessor :eps_payments
# The fpx_payments capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::FpxPayments)) }
attr_accessor :fpx_payments
# The gb_bank_transfer_payments capability.
sig {
returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::GbBankTransferPayments))
}
attr_accessor :gb_bank_transfer_payments
# The giropay_payments capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::GiropayPayments)) }
attr_accessor :giropay_payments
# The gopay_payments capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::GopayPayments)) }
attr_accessor :gopay_payments
# The grabpay_payments capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::GrabpayPayments)) }
attr_accessor :grabpay_payments
# The id_bank_transfer_payments capability.
sig {
returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::IdBankTransferPayments))
}
attr_accessor :id_bank_transfer_payments
# The id_bank_transfer_payments_bca capability.
sig {
returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::IdBankTransferPaymentsBca))
}
attr_accessor :id_bank_transfer_payments_bca
# The ideal_payments capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::IdealPayments)) }
attr_accessor :ideal_payments
# The india_international_payments capability.
sig {
returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::IndiaInternationalPayments))
}
attr_accessor :india_international_payments
# The jcb_payments capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::JcbPayments)) }
attr_accessor :jcb_payments
# The jp_bank_transfer_payments capability.
sig {
returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::JpBankTransferPayments))
}
attr_accessor :jp_bank_transfer_payments
# The kakao_pay_payments capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::KakaoPayPayments)) }
attr_accessor :kakao_pay_payments
# The klarna_payments capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::KlarnaPayments)) }
attr_accessor :klarna_payments
# The konbini_payments capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::KonbiniPayments)) }
attr_accessor :konbini_payments
# The kr_card_payments capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::KrCardPayments)) }
attr_accessor :kr_card_payments
# The legacy_payments capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::LegacyPayments)) }
attr_accessor :legacy_payments
# The link_payments capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::LinkPayments)) }
attr_accessor :link_payments
# The mb_way_payments capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::MbWayPayments)) }
attr_accessor :mb_way_payments
# The mobilepay_payments capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::MobilepayPayments)) }
attr_accessor :mobilepay_payments
# The multibanco_payments capability.
sig {
returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::MultibancoPayments))
}
attr_accessor :multibanco_payments
# The mx_bank_transfer_payments capability.
sig {
returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::MxBankTransferPayments))
}
attr_accessor :mx_bank_transfer_payments
# The naver_pay_payments capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::NaverPayPayments)) }
attr_accessor :naver_pay_payments
# The nz_bank_account_becs_debit_payments capability.
sig {
returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::NzBankAccountBecsDebitPayments))
}
attr_accessor :nz_bank_account_becs_debit_payments
# The oxxo_payments capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::OxxoPayments)) }
attr_accessor :oxxo_payments
# The p24_payments capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::P24Payments)) }
attr_accessor :p24_payments
# The pay_by_bank_payments capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::PayByBankPayments)) }
attr_accessor :pay_by_bank_payments
# The payco_payments capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::PaycoPayments)) }
attr_accessor :payco_payments
# The paynow_payments capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::PaynowPayments)) }
attr_accessor :paynow_payments
# The paypal_payments capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::PaypalPayments)) }
attr_accessor :paypal_payments
# The payto_payments capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::PaytoPayments)) }
attr_accessor :payto_payments
# The pix_payments capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::PixPayments)) }
attr_accessor :pix_payments
# The promptpay_payments capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::PromptpayPayments)) }
attr_accessor :promptpay_payments
# The qris_payments capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::QrisPayments)) }
attr_accessor :qris_payments
# The rechnung_payments capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::RechnungPayments)) }
attr_accessor :rechnung_payments
# The revolut_pay_payments capability.
sig {
returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::RevolutPayPayments))
}
attr_accessor :revolut_pay_payments
# The samsung_pay_payments capability.
sig {
returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::SamsungPayPayments))
}
attr_accessor :samsung_pay_payments
# The satispay_payments capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::SatispayPayments)) }
attr_accessor :satispay_payments
# The sepa_bank_transfer_payments capability.
sig {
returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::SepaBankTransferPayments))
}
attr_accessor :sepa_bank_transfer_payments
# The sepa_debit_payments capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::SepaDebitPayments)) }
attr_accessor :sepa_debit_payments
# The shopeepay_payments capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::ShopeepayPayments)) }
attr_accessor :shopeepay_payments
# The sofort_payments capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::SofortPayments)) }
attr_accessor :sofort_payments
# The stripe_balance_payments capability.
sig {
returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::StripeBalancePayments))
}
attr_accessor :stripe_balance_payments
# The swish_payments capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::SwishPayments)) }
attr_accessor :swish_payments
# The tax_reporting_us_1099_k capability.
sig {
returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::TaxReportingUs1099K))
}
attr_accessor :tax_reporting_us_1099_k
# The tax_reporting_us_1099_misc capability.
sig {
returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::TaxReportingUs1099Misc))
}
attr_accessor :tax_reporting_us_1099_misc
# The transfers capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::Transfers)) }
attr_accessor :transfers
# The treasury capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::Treasury)) }
attr_accessor :treasury
# The treasury_evolve capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::TreasuryEvolve)) }
attr_accessor :treasury_evolve
# The treasury_fifth_third capability.
sig {
returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::TreasuryFifthThird))
}
attr_accessor :treasury_fifth_third
# The treasury_goldman_sachs capability.
sig {
returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::TreasuryGoldmanSachs))
}
attr_accessor :treasury_goldman_sachs
# The twint_payments capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::TwintPayments)) }
attr_accessor :twint_payments
# The us_bank_account_ach_payments capability.
sig {
returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::UsBankAccountAchPayments))
}
attr_accessor :us_bank_account_ach_payments
# The us_bank_transfer_payments capability.
sig {
returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::UsBankTransferPayments))
}
attr_accessor :us_bank_transfer_payments
# The zip_payments capability.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities::ZipPayments)) }
attr_accessor :zip_payments
sig {
params(acss_debit_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::AcssDebitPayments), affirm_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::AffirmPayments), afterpay_clearpay_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::AfterpayClearpayPayments), alma_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::AlmaPayments), amazon_pay_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::AmazonPayPayments), au_becs_debit_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::AuBecsDebitPayments), automatic_indirect_tax: T.nilable(::Stripe::Account::CreateParams::Capabilities::AutomaticIndirectTax), bacs_debit_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::BacsDebitPayments), bancontact_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::BancontactPayments), bank_transfer_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::BankTransferPayments), billie_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::BilliePayments), blik_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::BlikPayments), boleto_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::BoletoPayments), card_issuing: T.nilable(::Stripe::Account::CreateParams::Capabilities::CardIssuing), card_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::CardPayments), cartes_bancaires_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::CartesBancairesPayments), cashapp_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::CashappPayments), eps_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::EpsPayments), fpx_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::FpxPayments), gb_bank_transfer_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::GbBankTransferPayments), giropay_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::GiropayPayments), gopay_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::GopayPayments), grabpay_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::GrabpayPayments), id_bank_transfer_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::IdBankTransferPayments), id_bank_transfer_payments_bca: T.nilable(::Stripe::Account::CreateParams::Capabilities::IdBankTransferPaymentsBca), ideal_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::IdealPayments), india_international_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::IndiaInternationalPayments), jcb_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::JcbPayments), jp_bank_transfer_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::JpBankTransferPayments), kakao_pay_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::KakaoPayPayments), klarna_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::KlarnaPayments), konbini_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::KonbiniPayments), kr_card_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::KrCardPayments), legacy_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::LegacyPayments), link_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::LinkPayments), mb_way_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::MbWayPayments), mobilepay_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::MobilepayPayments), multibanco_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::MultibancoPayments), mx_bank_transfer_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::MxBankTransferPayments), naver_pay_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::NaverPayPayments), nz_bank_account_becs_debit_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::NzBankAccountBecsDebitPayments), oxxo_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::OxxoPayments), p24_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::P24Payments), pay_by_bank_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::PayByBankPayments), payco_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::PaycoPayments), paynow_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::PaynowPayments), paypal_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::PaypalPayments), payto_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::PaytoPayments), pix_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::PixPayments), promptpay_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::PromptpayPayments), qris_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::QrisPayments), rechnung_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::RechnungPayments), revolut_pay_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::RevolutPayPayments), samsung_pay_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::SamsungPayPayments), satispay_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::SatispayPayments), sepa_bank_transfer_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::SepaBankTransferPayments), sepa_debit_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::SepaDebitPayments), shopeepay_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::ShopeepayPayments), sofort_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::SofortPayments), stripe_balance_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::StripeBalancePayments), swish_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::SwishPayments), tax_reporting_us_1099_k: T.nilable(::Stripe::Account::CreateParams::Capabilities::TaxReportingUs1099K), tax_reporting_us_1099_misc: T.nilable(::Stripe::Account::CreateParams::Capabilities::TaxReportingUs1099Misc), transfers: T.nilable(::Stripe::Account::CreateParams::Capabilities::Transfers), treasury: T.nilable(::Stripe::Account::CreateParams::Capabilities::Treasury), treasury_evolve: T.nilable(::Stripe::Account::CreateParams::Capabilities::TreasuryEvolve), treasury_fifth_third: T.nilable(::Stripe::Account::CreateParams::Capabilities::TreasuryFifthThird), treasury_goldman_sachs: T.nilable(::Stripe::Account::CreateParams::Capabilities::TreasuryGoldmanSachs), twint_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::TwintPayments), us_bank_account_ach_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::UsBankAccountAchPayments), us_bank_transfer_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::UsBankTransferPayments), zip_payments: T.nilable(::Stripe::Account::CreateParams::Capabilities::ZipPayments)).void
}
def initialize(
acss_debit_payments: nil,
affirm_payments: nil,
afterpay_clearpay_payments: nil,
alma_payments: nil,
amazon_pay_payments: nil,
au_becs_debit_payments: nil,
automatic_indirect_tax: nil,
bacs_debit_payments: nil,
bancontact_payments: nil,
bank_transfer_payments: nil,
billie_payments: nil,
blik_payments: nil,
boleto_payments: nil,
card_issuing: nil,
card_payments: nil,
cartes_bancaires_payments: nil,
cashapp_payments: nil,
eps_payments: nil,
fpx_payments: nil,
gb_bank_transfer_payments: nil,
giropay_payments: nil,
gopay_payments: nil,
grabpay_payments: nil,
id_bank_transfer_payments: nil,
id_bank_transfer_payments_bca: nil,
ideal_payments: nil,
india_international_payments: nil,
jcb_payments: nil,
jp_bank_transfer_payments: nil,
kakao_pay_payments: nil,
klarna_payments: nil,
konbini_payments: nil,
kr_card_payments: nil,
legacy_payments: nil,
link_payments: nil,
mb_way_payments: nil,
mobilepay_payments: nil,
multibanco_payments: nil,
mx_bank_transfer_payments: nil,
naver_pay_payments: nil,
nz_bank_account_becs_debit_payments: nil,
oxxo_payments: nil,
p24_payments: nil,
pay_by_bank_payments: nil,
payco_payments: nil,
paynow_payments: nil,
paypal_payments: nil,
payto_payments: nil,
pix_payments: nil,
promptpay_payments: nil,
qris_payments: nil,
rechnung_payments: nil,
revolut_pay_payments: nil,
samsung_pay_payments: nil,
satispay_payments: nil,
sepa_bank_transfer_payments: nil,
sepa_debit_payments: nil,
shopeepay_payments: nil,
sofort_payments: nil,
stripe_balance_payments: nil,
swish_payments: nil,
tax_reporting_us_1099_k: nil,
tax_reporting_us_1099_misc: nil,
transfers: nil,
treasury: nil,
treasury_evolve: nil,
treasury_fifth_third: nil,
treasury_goldman_sachs: nil,
twint_payments: nil,
us_bank_account_ach_payments: nil,
us_bank_transfer_payments: nil,
zip_payments: nil
); end
end
class Card < Stripe::RequestParams
# Attribute for param field object
sig { returns(String) }
attr_accessor :object
# Attribute for param field address_city
sig { returns(T.nilable(String)) }
attr_accessor :address_city
# Attribute for param field address_country
sig { returns(T.nilable(String)) }
attr_accessor :address_country
# Attribute for param field address_line1
sig { returns(T.nilable(String)) }
attr_accessor :address_line1
# Attribute for param field address_line2
sig { returns(T.nilable(String)) }
attr_accessor :address_line2
# Attribute for param field address_state
sig { returns(T.nilable(String)) }
attr_accessor :address_state
# Attribute for param field address_zip
sig { returns(T.nilable(String)) }
attr_accessor :address_zip
# Attribute for param field currency
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Attribute for param field cvc
sig { returns(T.nilable(String)) }
attr_accessor :cvc
# Attribute for param field exp_month
sig { returns(Integer) }
attr_accessor :exp_month
# Attribute for param field exp_year
sig { returns(Integer) }
attr_accessor :exp_year
# Attribute for param field name
sig { returns(T.nilable(String)) }
attr_accessor :name
# Attribute for param field number
sig { returns(String) }
attr_accessor :number
# 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.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Attribute for param field default_for_currency
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :default_for_currency
sig {
params(object: String, address_city: T.nilable(String), address_country: T.nilable(String), address_line1: T.nilable(String), address_line2: T.nilable(String), address_state: T.nilable(String), address_zip: T.nilable(String), currency: T.nilable(String), cvc: T.nilable(String), exp_month: Integer, exp_year: Integer, name: T.nilable(String), number: String, metadata: T.nilable(T::Hash[String, String]), default_for_currency: T.nilable(T::Boolean)).void
}
def initialize(
object: nil,
address_city: nil,
address_country: nil,
address_line1: nil,
address_line2: nil,
address_state: nil,
address_zip: nil,
currency: nil,
cvc: nil,
exp_month: nil,
exp_year: nil,
name: nil,
number: nil,
metadata: nil,
default_for_currency: nil
); end
end
class CardToken < Stripe::RequestParams
# Attribute for param field object
sig { returns(String) }
attr_accessor :object
# Attribute for param field currency
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Attribute for param field token
sig { returns(String) }
attr_accessor :token
sig { params(object: String, currency: T.nilable(String), token: String).void }
def initialize(object: nil, currency: nil, token: nil); end
end
class Company < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class AddressKana < Stripe::RequestParams
# City or ward.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Block or building number.
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Building details.
sig { returns(T.nilable(String)) }
attr_accessor :line2
# Postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# Prefecture.
sig { returns(T.nilable(String)) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_accessor :town
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), town: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
class AddressKanji < Stripe::RequestParams
# City or ward.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Block or building number.
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Building details.
sig { returns(T.nilable(String)) }
attr_accessor :line2
# Postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# Prefecture.
sig { returns(T.nilable(String)) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_accessor :town
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), town: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
class DirectorshipDeclaration < Stripe::RequestParams
# The Unix timestamp marking when the directorship declaration attestation was made.
sig { returns(T.nilable(Integer)) }
attr_accessor :date
# The IP address from which the directorship declaration attestation was made.
sig { returns(T.nilable(String)) }
attr_accessor :ip
# The user agent of the browser from which the directorship declaration attestation was made.
sig { returns(T.nilable(String)) }
attr_accessor :user_agent
sig {
params(date: T.nilable(Integer), ip: T.nilable(String), user_agent: T.nilable(String)).void
}
def initialize(date: nil, ip: nil, user_agent: nil); end
end
class OwnershipDeclaration < Stripe::RequestParams
# The Unix timestamp marking when the beneficial owner attestation was made.
sig { returns(T.nilable(Integer)) }
attr_accessor :date
# The IP address from which the beneficial owner attestation was made.
sig { returns(T.nilable(String)) }
attr_accessor :ip
# The user agent of the browser from which the beneficial owner attestation was made.
sig { returns(T.nilable(String)) }
attr_accessor :user_agent
sig {
params(date: T.nilable(Integer), ip: T.nilable(String), user_agent: T.nilable(String)).void
}
def initialize(date: nil, ip: nil, user_agent: nil); end
end
class RegistrationDate < Stripe::RequestParams
# The day of registration, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of registration, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of registration.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
class Verification < Stripe::RequestParams
class Document < Stripe::RequestParams
# The back of a document returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `additional_verification`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :back
# The front of a document returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `additional_verification`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :front
sig { params(back: T.nilable(String), front: T.nilable(String)).void }
def initialize(back: nil, front: nil); end
end
# A document verifying the business.
sig {
returns(T.nilable(::Stripe::Account::CreateParams::Company::Verification::Document))
}
attr_accessor :document
sig {
params(document: T.nilable(::Stripe::Account::CreateParams::Company::Verification::Document)).void
}
def initialize(document: nil); end
end
# The company's primary address.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Company::Address)) }
attr_accessor :address
# The Kana variation of the company's primary address (Japan only).
sig { returns(T.nilable(::Stripe::Account::CreateParams::Company::AddressKana)) }
attr_accessor :address_kana
# The Kanji variation of the company's primary address (Japan only).
sig { returns(T.nilable(::Stripe::Account::CreateParams::Company::AddressKanji)) }
attr_accessor :address_kanji
# Whether the company's directors have been provided. Set this Boolean to `true` after creating all the company's directors with [the Persons API](/api/persons) for accounts with a `relationship.director` requirement. This value is not automatically set to `true` after creating directors, so it needs to be updated to indicate all directors have been provided.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :directors_provided
# This hash is used to attest that the directors information provided to Stripe is both current and correct.
sig {
returns(T.nilable(::Stripe::Account::CreateParams::Company::DirectorshipDeclaration))
}
attr_accessor :directorship_declaration
# Whether the company's executives have been provided. Set this Boolean to `true` after creating all the company's executives with [the Persons API](/api/persons) for accounts with a `relationship.executive` requirement.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :executives_provided
# The export license ID number of the company, also referred as Import Export Code (India only).
sig { returns(T.nilable(String)) }
attr_accessor :export_license_id
# The purpose code to use for export transactions (India only).
sig { returns(T.nilable(String)) }
attr_accessor :export_purpose_code
# The company's legal name.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The Kana variation of the company's legal name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :name_kana
# The Kanji variation of the company's legal name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :name_kanji
# Whether the company's owners have been provided. Set this Boolean to `true` after creating all the company's owners with [the Persons API](/api/persons) for accounts with a `relationship.owner` requirement.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :owners_provided
# This hash is used to attest that the beneficial owner information provided to Stripe is both current and correct.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Company::OwnershipDeclaration)) }
attr_accessor :ownership_declaration
# This value is used to determine if a business is exempt from providing ultimate beneficial owners. See [this support article](https://support.stripe.com/questions/exemption-from-providing-ownership-details) and [changelog](https://docs.stripe.com/changelog/acacia/2025-01-27/ownership-exemption-reason-accounts-api) for more details.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :ownership_exemption_reason
# The company's phone number (used for verification).
sig { returns(T.nilable(String)) }
attr_accessor :phone
# Attribute for param field registration_date
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Account::CreateParams::Company::RegistrationDate))))
}
attr_accessor :registration_date
# The identification number given to a company when it is registered or incorporated, if distinct from the identification number used for filing taxes. (Examples are the CIN for companies and LLP IN for partnerships in India, and the Company Registration Number in Hong Kong).
sig { returns(T.nilable(String)) }
attr_accessor :registration_number
# The category identifying the legal structure of the company or legal entity. See [Business structure](/connect/identity-verification#business-structure) for more details. Pass an empty string to unset this value.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :structure
# The business ID number of the company, as appropriate for the company’s country. (Examples are an Employer ID Number in the U.S., a Business Number in Canada, or a Company Number in the UK.)
sig { returns(T.nilable(String)) }
attr_accessor :tax_id
# The jurisdiction in which the `tax_id` is registered (Germany-based companies only).
sig { returns(T.nilable(String)) }
attr_accessor :tax_id_registrar
# The VAT number of the company.
sig { returns(T.nilable(String)) }
attr_accessor :vat_id
# Information on the verification state of the company.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Company::Verification)) }
attr_accessor :verification
sig {
params(address: T.nilable(::Stripe::Account::CreateParams::Company::Address), address_kana: T.nilable(::Stripe::Account::CreateParams::Company::AddressKana), address_kanji: T.nilable(::Stripe::Account::CreateParams::Company::AddressKanji), directors_provided: T.nilable(T::Boolean), directorship_declaration: T.nilable(::Stripe::Account::CreateParams::Company::DirectorshipDeclaration), executives_provided: T.nilable(T::Boolean), export_license_id: T.nilable(String), export_purpose_code: T.nilable(String), name: T.nilable(String), name_kana: T.nilable(String), name_kanji: T.nilable(String), owners_provided: T.nilable(T::Boolean), ownership_declaration: T.nilable(::Stripe::Account::CreateParams::Company::OwnershipDeclaration), ownership_exemption_reason: T.nilable(T.nilable(T.any(String, String))), phone: T.nilable(String), registration_date: T.nilable(T.nilable(T.any(String, ::Stripe::Account::CreateParams::Company::RegistrationDate))), registration_number: T.nilable(String), structure: T.nilable(T.nilable(T.any(String, String))), tax_id: T.nilable(String), tax_id_registrar: T.nilable(String), vat_id: T.nilable(String), verification: T.nilable(::Stripe::Account::CreateParams::Company::Verification)).void
}
def initialize(
address: nil,
address_kana: nil,
address_kanji: nil,
directors_provided: nil,
directorship_declaration: nil,
executives_provided: nil,
export_license_id: nil,
export_purpose_code: nil,
name: nil,
name_kana: nil,
name_kanji: nil,
owners_provided: nil,
ownership_declaration: nil,
ownership_exemption_reason: nil,
phone: nil,
registration_date: nil,
registration_number: nil,
structure: nil,
tax_id: nil,
tax_id_registrar: nil,
vat_id: nil,
verification: nil
); end
end
class Controller < Stripe::RequestParams
class Application < Stripe::RequestParams
# Whether the controller is liable for losses on this account. For details, see [Understanding Connect Account Balances](https://stripe.com/docs/connect/account-balances).
sig { returns(T::Boolean) }
attr_accessor :loss_liable
# Whether the controller owns onboarding for this account.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :onboarding_owner
# Whether the controller has pricing controls for this account.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :pricing_controls
sig {
params(loss_liable: T::Boolean, onboarding_owner: T.nilable(T::Boolean), pricing_controls: T.nilable(T::Boolean)).void
}
def initialize(loss_liable: nil, onboarding_owner: nil, pricing_controls: nil); end
end
class Dashboard < Stripe::RequestParams
# Whether this account should have access to the full Stripe Dashboard (`full`), to the Express Dashboard (`express`), or to no Stripe-hosted dashboard (`none`). Defaults to `full`.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig { params(type: T.nilable(String)).void }
def initialize(type: nil); end
end
class Fees < Stripe::RequestParams
# A value indicating the responsible payer of Stripe fees on this account. Defaults to `account`. Learn more about [fee behavior on connected accounts](https://docs.stripe.com/connect/direct-charges-fee-payer-behavior).
sig { returns(T.nilable(String)) }
attr_accessor :payer
sig { params(payer: T.nilable(String)).void }
def initialize(payer: nil); end
end
class Losses < Stripe::RequestParams
# A value indicating who is liable when this account can't pay back negative balances resulting from payments. Defaults to `stripe`.
sig { returns(T.nilable(String)) }
attr_accessor :payments
sig { params(payments: T.nilable(String)).void }
def initialize(payments: nil); end
end
class StripeDashboard < Stripe::RequestParams
# Whether this account should have access to the full Stripe Dashboard (`full`), to the Express Dashboard (`express`), or to no Stripe-hosted dashboard (`none`). Defaults to `full`.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig { params(type: T.nilable(String)).void }
def initialize(type: nil); end
end
# A hash of configuration describing the Connect application that controls the account.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Controller::Application)) }
attr_accessor :application
# Properties of the account's dashboard.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Controller::Dashboard)) }
attr_accessor :dashboard
# A hash of configuration for who pays Stripe fees for product usage on this account.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Controller::Fees)) }
attr_accessor :fees
# A hash of configuration for products that have negative balance liability, and whether Stripe or a Connect application is responsible for them.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Controller::Losses)) }
attr_accessor :losses
# A value indicating responsibility for collecting updated information when requirements on the account are due or change. Defaults to `stripe`.
sig { returns(T.nilable(String)) }
attr_accessor :requirement_collection
# A hash of configuration for Stripe-hosted dashboards.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Controller::StripeDashboard)) }
attr_accessor :stripe_dashboard
sig {
params(application: T.nilable(::Stripe::Account::CreateParams::Controller::Application), dashboard: T.nilable(::Stripe::Account::CreateParams::Controller::Dashboard), fees: T.nilable(::Stripe::Account::CreateParams::Controller::Fees), losses: T.nilable(::Stripe::Account::CreateParams::Controller::Losses), requirement_collection: T.nilable(String), stripe_dashboard: T.nilable(::Stripe::Account::CreateParams::Controller::StripeDashboard)).void
}
def initialize(
application: nil,
dashboard: nil,
fees: nil,
losses: nil,
requirement_collection: nil,
stripe_dashboard: nil
); end
end
class Documents < Stripe::RequestParams
class BankAccountOwnershipVerification < Stripe::RequestParams
# One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :files
sig { params(files: T.nilable(T::Array[String])).void }
def initialize(files: nil); end
end
class CompanyLicense < Stripe::RequestParams
# One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :files
sig { params(files: T.nilable(T::Array[String])).void }
def initialize(files: nil); end
end
class CompanyMemorandumOfAssociation < Stripe::RequestParams
# One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :files
sig { params(files: T.nilable(T::Array[String])).void }
def initialize(files: nil); end
end
class CompanyMinisterialDecree < Stripe::RequestParams
# One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :files
sig { params(files: T.nilable(T::Array[String])).void }
def initialize(files: nil); end
end
class CompanyRegistrationVerification < Stripe::RequestParams
# One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :files
sig { params(files: T.nilable(T::Array[String])).void }
def initialize(files: nil); end
end
class CompanyTaxIdVerification < Stripe::RequestParams
# One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :files
sig { params(files: T.nilable(T::Array[String])).void }
def initialize(files: nil); end
end
class ProofOfRegistration < Stripe::RequestParams
# One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :files
sig { params(files: T.nilable(T::Array[String])).void }
def initialize(files: nil); end
end
class ProofOfUltimateBeneficialOwnership < Stripe::RequestParams
# One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :files
sig { params(files: T.nilable(T::Array[String])).void }
def initialize(files: nil); end
end
# One or more documents that support the [Bank account ownership verification](https://support.stripe.com/questions/bank-account-ownership-verification) requirement. Must be a document associated with the account’s primary active bank account that displays the last 4 digits of the account number, either a statement or a check.
sig {
returns(T.nilable(::Stripe::Account::CreateParams::Documents::BankAccountOwnershipVerification))
}
attr_accessor :bank_account_ownership_verification
# One or more documents that demonstrate proof of a company's license to operate.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Documents::CompanyLicense)) }
attr_accessor :company_license
# One or more documents showing the company's Memorandum of Association.
sig {
returns(T.nilable(::Stripe::Account::CreateParams::Documents::CompanyMemorandumOfAssociation))
}
attr_accessor :company_memorandum_of_association
# (Certain countries only) One or more documents showing the ministerial decree legalizing the company's establishment.
sig {
returns(T.nilable(::Stripe::Account::CreateParams::Documents::CompanyMinisterialDecree))
}
attr_accessor :company_ministerial_decree
# One or more documents that demonstrate proof of a company's registration with the appropriate local authorities.
sig {
returns(T.nilable(::Stripe::Account::CreateParams::Documents::CompanyRegistrationVerification))
}
attr_accessor :company_registration_verification
# One or more documents that demonstrate proof of a company's tax ID.
sig {
returns(T.nilable(::Stripe::Account::CreateParams::Documents::CompanyTaxIdVerification))
}
attr_accessor :company_tax_id_verification
# One or more documents showing the company’s proof of registration with the national business registry.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Documents::ProofOfRegistration)) }
attr_accessor :proof_of_registration
# One or more documents that demonstrate proof of ultimate beneficial ownership.
sig {
returns(T.nilable(::Stripe::Account::CreateParams::Documents::ProofOfUltimateBeneficialOwnership))
}
attr_accessor :proof_of_ultimate_beneficial_ownership
sig {
params(bank_account_ownership_verification: T.nilable(::Stripe::Account::CreateParams::Documents::BankAccountOwnershipVerification), company_license: T.nilable(::Stripe::Account::CreateParams::Documents::CompanyLicense), company_memorandum_of_association: T.nilable(::Stripe::Account::CreateParams::Documents::CompanyMemorandumOfAssociation), company_ministerial_decree: T.nilable(::Stripe::Account::CreateParams::Documents::CompanyMinisterialDecree), company_registration_verification: T.nilable(::Stripe::Account::CreateParams::Documents::CompanyRegistrationVerification), company_tax_id_verification: T.nilable(::Stripe::Account::CreateParams::Documents::CompanyTaxIdVerification), proof_of_registration: T.nilable(::Stripe::Account::CreateParams::Documents::ProofOfRegistration), proof_of_ultimate_beneficial_ownership: T.nilable(::Stripe::Account::CreateParams::Documents::ProofOfUltimateBeneficialOwnership)).void
}
def initialize(
bank_account_ownership_verification: nil,
company_license: nil,
company_memorandum_of_association: nil,
company_ministerial_decree: nil,
company_registration_verification: nil,
company_tax_id_verification: nil,
proof_of_registration: nil,
proof_of_ultimate_beneficial_ownership: nil
); end
end
class Groups < Stripe::RequestParams
# The group the account is in to determine their payments pricing, and null if the account is on customized pricing. [See the Platform pricing tool documentation](https://stripe.com/docs/connect/platform-pricing-tools) for details.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :payments_pricing
sig { params(payments_pricing: T.nilable(T.nilable(String))).void }
def initialize(payments_pricing: nil); end
end
class Individual < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class AddressKana < Stripe::RequestParams
# City or ward.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Block or building number.
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Building details.
sig { returns(T.nilable(String)) }
attr_accessor :line2
# Postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# Prefecture.
sig { returns(T.nilable(String)) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_accessor :town
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), town: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
class AddressKanji < Stripe::RequestParams
# City or ward.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Block or building number.
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Building details.
sig { returns(T.nilable(String)) }
attr_accessor :line2
# Postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# Prefecture.
sig { returns(T.nilable(String)) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_accessor :town
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), town: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
class Dob < Stripe::RequestParams
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
class RegisteredAddress < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class Relationship < Stripe::RequestParams
# Whether the person is a director of the account's legal entity. Directors are typically members of the governing board of the company, or responsible for ensuring the company meets its regulatory obligations.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :director
# Whether the person has significant responsibility to control, manage, or direct the organization.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :executive
# Whether the person is an owner of the account’s legal entity.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :owner
# The percent owned by the person of the account's legal entity.
sig { returns(T.nilable(T.nilable(T.any(String, Float)))) }
attr_accessor :percent_ownership
# The person's title (e.g., CEO, Support Engineer).
sig { returns(T.nilable(String)) }
attr_accessor :title
sig {
params(director: T.nilable(T::Boolean), executive: T.nilable(T::Boolean), owner: T.nilable(T::Boolean), percent_ownership: T.nilable(T.nilable(T.any(String, Float))), title: T.nilable(String)).void
}
def initialize(
director: nil,
executive: nil,
owner: nil,
percent_ownership: nil,
title: nil
); end
end
class Verification < Stripe::RequestParams
class AdditionalDocument < Stripe::RequestParams
# The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :back
# The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :front
sig { params(back: T.nilable(String), front: T.nilable(String)).void }
def initialize(back: nil, front: nil); end
end
class Document < Stripe::RequestParams
# The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :back
# The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :front
sig { params(back: T.nilable(String), front: T.nilable(String)).void }
def initialize(back: nil, front: nil); end
end
# A document showing address, either a passport, local ID card, or utility bill from a well-known utility company.
sig {
returns(T.nilable(::Stripe::Account::CreateParams::Individual::Verification::AdditionalDocument))
}
attr_accessor :additional_document
# An identifying document, either a passport or local ID card.
sig {
returns(T.nilable(::Stripe::Account::CreateParams::Individual::Verification::Document))
}
attr_accessor :document
sig {
params(additional_document: T.nilable(::Stripe::Account::CreateParams::Individual::Verification::AdditionalDocument), document: T.nilable(::Stripe::Account::CreateParams::Individual::Verification::Document)).void
}
def initialize(additional_document: nil, document: nil); end
end
# The individual's primary address.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Individual::Address)) }
attr_accessor :address
# The Kana variation of the individual's primary address (Japan only).
sig { returns(T.nilable(::Stripe::Account::CreateParams::Individual::AddressKana)) }
attr_accessor :address_kana
# The Kanji variation of the individual's primary address (Japan only).
sig { returns(T.nilable(::Stripe::Account::CreateParams::Individual::AddressKanji)) }
attr_accessor :address_kanji
# The individual's date of birth.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Account::CreateParams::Individual::Dob))))
}
attr_accessor :dob
# The individual's email address.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The individual's first name.
sig { returns(T.nilable(String)) }
attr_accessor :first_name
# The Kana variation of the individual's first name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :first_name_kana
# The Kanji variation of the individual's first name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :first_name_kanji
# A list of alternate names or aliases that the individual is known by.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :full_name_aliases
# The individual's gender
sig { returns(T.nilable(String)) }
attr_accessor :gender
# The government-issued ID number of the individual, as appropriate for the representative's country. (Examples are a Social Security Number in the U.S., or a Social Insurance Number in Canada). Instead of the number itself, you can also provide a [PII token created with Stripe.js](/js/tokens/create_token?type=pii).
sig { returns(T.nilable(String)) }
attr_accessor :id_number
# The government-issued secondary ID number of the individual, as appropriate for the representative's country, will be used for enhanced verification checks. In Thailand, this would be the laser code found on the back of an ID card. Instead of the number itself, you can also provide a [PII token created with Stripe.js](/js/tokens/create_token?type=pii).
sig { returns(T.nilable(String)) }
attr_accessor :id_number_secondary
# The individual's last name.
sig { returns(T.nilable(String)) }
attr_accessor :last_name
# The Kana variation of the individual's last name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :last_name_kana
# The Kanji variation of the individual's last name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :last_name_kanji
# The individual's maiden name.
sig { returns(T.nilable(String)) }
attr_accessor :maiden_name
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# The individual's phone number.
sig { returns(T.nilable(String)) }
attr_accessor :phone
# Indicates if the person or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction.
sig { returns(T.nilable(String)) }
attr_accessor :political_exposure
# The individual's registered address.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Individual::RegisteredAddress)) }
attr_accessor :registered_address
# Describes the person’s relationship to the account.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Individual::Relationship)) }
attr_accessor :relationship
# The last four digits of the individual's Social Security Number (U.S. only).
sig { returns(T.nilable(String)) }
attr_accessor :ssn_last_4
# The individual's verification document information.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Individual::Verification)) }
attr_accessor :verification
sig {
params(address: T.nilable(::Stripe::Account::CreateParams::Individual::Address), address_kana: T.nilable(::Stripe::Account::CreateParams::Individual::AddressKana), address_kanji: T.nilable(::Stripe::Account::CreateParams::Individual::AddressKanji), dob: T.nilable(T.nilable(T.any(String, ::Stripe::Account::CreateParams::Individual::Dob))), email: T.nilable(String), first_name: T.nilable(String), first_name_kana: T.nilable(String), first_name_kanji: T.nilable(String), full_name_aliases: T.nilable(T.nilable(T.any(String, T::Array[String]))), gender: T.nilable(String), id_number: T.nilable(String), id_number_secondary: T.nilable(String), last_name: T.nilable(String), last_name_kana: T.nilable(String), last_name_kanji: T.nilable(String), maiden_name: T.nilable(String), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), phone: T.nilable(String), political_exposure: T.nilable(String), registered_address: T.nilable(::Stripe::Account::CreateParams::Individual::RegisteredAddress), relationship: T.nilable(::Stripe::Account::CreateParams::Individual::Relationship), ssn_last_4: T.nilable(String), verification: T.nilable(::Stripe::Account::CreateParams::Individual::Verification)).void
}
def initialize(
address: nil,
address_kana: nil,
address_kanji: nil,
dob: nil,
email: nil,
first_name: nil,
first_name_kana: nil,
first_name_kanji: nil,
full_name_aliases: nil,
gender: nil,
id_number: nil,
id_number_secondary: nil,
last_name: nil,
last_name_kana: nil,
last_name_kanji: nil,
maiden_name: nil,
metadata: nil,
phone: nil,
political_exposure: nil,
registered_address: nil,
relationship: nil,
ssn_last_4: nil,
verification: nil
); end
end
class RiskControls < Stripe::RequestParams
class Charges < Stripe::RequestParams
# To request to pause a risk control, pass `true`. To request to unpause a risk control, pass `false`.
# There can be a delay before the risk control is paused or unpaused.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :pause_requested
sig { params(pause_requested: T.nilable(T::Boolean)).void }
def initialize(pause_requested: nil); end
end
class Payouts < Stripe::RequestParams
# To request to pause a risk control, pass `true`. To request to unpause a risk control, pass `false`.
# There can be a delay before the risk control is paused or unpaused.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :pause_requested
sig { params(pause_requested: T.nilable(T::Boolean)).void }
def initialize(pause_requested: nil); end
end
# Represents the risk control status of charges. Please see [this page for more details](https://stripe.com/docs/connect/pausing-payments-or-payouts-on-connected-accounts).
sig { returns(T.nilable(::Stripe::Account::CreateParams::RiskControls::Charges)) }
attr_accessor :charges
# Represents the risk control status of payouts. Please see [this page for more details](https://stripe.com/docs/connect/pausing-payments-or-payouts-on-connected-accounts).
sig { returns(T.nilable(::Stripe::Account::CreateParams::RiskControls::Payouts)) }
attr_accessor :payouts
sig {
params(charges: T.nilable(::Stripe::Account::CreateParams::RiskControls::Charges), payouts: T.nilable(::Stripe::Account::CreateParams::RiskControls::Payouts)).void
}
def initialize(charges: nil, payouts: nil); end
end
class Settings < Stripe::RequestParams
class BacsDebitPayments < Stripe::RequestParams
# The Bacs Direct Debit Display Name for this account. For payments made with Bacs Direct Debit, this name appears on the mandate as the statement descriptor. Mobile banking apps display it as the name of the business. To use custom branding, set the Bacs Direct Debit Display Name during or right after creation. Custom branding incurs an additional monthly fee for the platform. If you don't set the display name before requesting Bacs capability, it's automatically set as "Stripe" and the account is onboarded to Stripe branding, which is free.
sig { returns(T.nilable(String)) }
attr_accessor :display_name
sig { params(display_name: T.nilable(String)).void }
def initialize(display_name: nil); end
end
class BankBcaOnboarding < Stripe::RequestParams
# Bank BCA business account holder name
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_name
# Bank BCA business account number
sig { returns(T.nilable(String)) }
attr_accessor :business_account_number
sig {
params(account_holder_name: T.nilable(String), business_account_number: T.nilable(String)).void
}
def initialize(account_holder_name: nil, business_account_number: nil); end
end
class Branding < Stripe::RequestParams
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) An icon for the account. Must be square and at least 128px x 128px.
sig { returns(T.nilable(String)) }
attr_accessor :icon
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) A logo for the account that will be used in Checkout instead of the icon and without the account's name next to it if provided. Must be at least 128px x 128px.
sig { returns(T.nilable(String)) }
attr_accessor :logo
# A CSS hex color value representing the primary branding color for this account.
sig { returns(T.nilable(String)) }
attr_accessor :primary_color
# A CSS hex color value representing the secondary branding color for this account.
sig { returns(T.nilable(String)) }
attr_accessor :secondary_color
sig {
params(icon: T.nilable(String), logo: T.nilable(String), primary_color: T.nilable(String), secondary_color: T.nilable(String)).void
}
def initialize(icon: nil, logo: nil, primary_color: nil, secondary_color: nil); end
end
class Capital < Stripe::RequestParams
# Per-currency mapping of user-selected destination accounts used to pay out loans.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :payout_destination
# Per-currency mapping of all destination accounts eligible to receive Capital financing payouts.
sig { returns(T.nilable(T::Hash[String, T::Array[String]])) }
attr_accessor :payout_destination_selector
sig {
params(payout_destination: T.nilable(T::Hash[String, String]), payout_destination_selector: T.nilable(T::Hash[String, T::Array[String]])).void
}
def initialize(payout_destination: nil, payout_destination_selector: nil); end
end
class CardIssuing < Stripe::RequestParams
class TosAcceptance < Stripe::RequestParams
# The Unix timestamp marking when the account representative accepted the service agreement.
sig { returns(T.nilable(Integer)) }
attr_accessor :date
# The IP address from which the account representative accepted the service agreement.
sig { returns(T.nilable(String)) }
attr_accessor :ip
# The user agent of the browser from which the account representative accepted the service agreement.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :user_agent
sig {
params(date: T.nilable(Integer), ip: T.nilable(String), user_agent: T.nilable(T.nilable(String))).void
}
def initialize(date: nil, ip: nil, user_agent: nil); end
end
# Details on the account's acceptance of the [Stripe Issuing Terms and Disclosures](/issuing/connect/tos_acceptance).
sig {
returns(T.nilable(::Stripe::Account::CreateParams::Settings::CardIssuing::TosAcceptance))
}
attr_accessor :tos_acceptance
sig {
params(tos_acceptance: T.nilable(::Stripe::Account::CreateParams::Settings::CardIssuing::TosAcceptance)).void
}
def initialize(tos_acceptance: nil); end
end
class CardPayments < Stripe::RequestParams
class DeclineOn < Stripe::RequestParams
# Whether Stripe automatically declines charges with an incorrect ZIP or postal code. This setting only applies when a ZIP or postal code is provided and they fail bank verification.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :avs_failure
# Whether Stripe automatically declines charges with an incorrect CVC. This setting only applies when a CVC is provided and it fails bank verification.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :cvc_failure
sig {
params(avs_failure: T.nilable(T::Boolean), cvc_failure: T.nilable(T::Boolean)).void
}
def initialize(avs_failure: nil, cvc_failure: nil); end
end
# Automatically declines certain charge types regardless of whether the card issuer accepted or declined the charge.
sig {
returns(T.nilable(::Stripe::Account::CreateParams::Settings::CardPayments::DeclineOn))
}
attr_accessor :decline_on
# The default text that appears on credit card statements when a charge is made. This field prefixes any dynamic `statement_descriptor` specified on the charge. `statement_descriptor_prefix` is useful for maximizing descriptor space for the dynamic portion.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor_prefix
# The Kana variation of the default text that appears on credit card statements when a charge is made (Japan only). This field prefixes any dynamic `statement_descriptor_suffix_kana` specified on the charge. `statement_descriptor_prefix_kana` is useful for maximizing descriptor space for the dynamic portion.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :statement_descriptor_prefix_kana
# The Kanji variation of the default text that appears on credit card statements when a charge is made (Japan only). This field prefixes any dynamic `statement_descriptor_suffix_kanji` specified on the charge. `statement_descriptor_prefix_kanji` is useful for maximizing descriptor space for the dynamic portion.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :statement_descriptor_prefix_kanji
sig {
params(decline_on: T.nilable(::Stripe::Account::CreateParams::Settings::CardPayments::DeclineOn), statement_descriptor_prefix: T.nilable(String), statement_descriptor_prefix_kana: T.nilable(T.nilable(String)), statement_descriptor_prefix_kanji: T.nilable(T.nilable(String))).void
}
def initialize(
decline_on: nil,
statement_descriptor_prefix: nil,
statement_descriptor_prefix_kana: nil,
statement_descriptor_prefix_kanji: nil
); end
end
class Invoices < Stripe::RequestParams
# Whether payment methods should be saved when a payment is completed for a one-time invoices on a hosted invoice page.
sig { returns(T.nilable(String)) }
attr_accessor :hosted_payment_method_save
sig { params(hosted_payment_method_save: T.nilable(String)).void }
def initialize(hosted_payment_method_save: nil); end
end
class Payments < Stripe::RequestParams
# The default text that appears on statements for non-card charges outside of Japan. For card charges, if you don't set a `statement_descriptor_prefix`, this text is also used as the statement descriptor prefix. In that case, if concatenating the statement descriptor suffix causes the combined statement descriptor to exceed 22 characters, we truncate the `statement_descriptor` text to limit the full descriptor to 22 characters. For more information about statement descriptors and their requirements, see the [account settings documentation](https://docs.stripe.com/get-started/account/statement-descriptors).
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
# The Kana variation of `statement_descriptor` used for charges in Japan. Japanese statement descriptors have [special requirements](https://docs.stripe.com/get-started/account/statement-descriptors#set-japanese-statement-descriptors).
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor_kana
# The Kanji variation of `statement_descriptor` used for charges in Japan. Japanese statement descriptors have [special requirements](https://docs.stripe.com/get-started/account/statement-descriptors#set-japanese-statement-descriptors).
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor_kanji
sig {
params(statement_descriptor: T.nilable(String), statement_descriptor_kana: T.nilable(String), statement_descriptor_kanji: T.nilable(String)).void
}
def initialize(
statement_descriptor: nil,
statement_descriptor_kana: nil,
statement_descriptor_kanji: nil
); end
end
class Payouts < Stripe::RequestParams
class Schedule < Stripe::RequestParams
# The number of days charge funds are held before being paid out. May also be set to `minimum`, representing the lowest available value for the account country. Default is `minimum`. The `delay_days` parameter remains at the last configured value if `interval` is `manual`. [Learn more about controlling payout delay days](/connect/manage-payout-schedule).
sig { returns(T.nilable(T.any(String, Integer))) }
attr_accessor :delay_days
# How frequently available funds are paid out. One of: `daily`, `manual`, `weekly`, or `monthly`. Default is `daily`.
sig { returns(T.nilable(String)) }
attr_accessor :interval
# The day of the month when available funds are paid out, specified as a number between 1--31. Payouts nominally scheduled between the 29th and 31st of the month are instead sent on the last day of a shorter month. Required and applicable only if `interval` is `monthly`.
sig { returns(T.nilable(Integer)) }
attr_accessor :monthly_anchor
# The day of the week when available funds are paid out, specified as `monday`, `tuesday`, etc. (required and applicable only if `interval` is `weekly`.)
sig { returns(T.nilable(String)) }
attr_accessor :weekly_anchor
sig {
params(delay_days: T.nilable(T.any(String, Integer)), interval: T.nilable(String), monthly_anchor: T.nilable(Integer), weekly_anchor: T.nilable(String)).void
}
def initialize(
delay_days: nil,
interval: nil,
monthly_anchor: nil,
weekly_anchor: nil
); end
end
# A Boolean indicating whether Stripe should try to reclaim negative balances from an attached bank account. For details, see [Understanding Connect Account Balances](/connect/account-balances).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :debit_negative_balances
# Details on when funds from charges are available, and when they are paid out to an external account. For details, see our [Setting Bank and Debit Card Payouts](/connect/bank-transfers#payout-information) documentation.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Settings::Payouts::Schedule)) }
attr_accessor :schedule
# The text that appears on the bank account statement for payouts. If not set, this defaults to the platform's bank descriptor as set in the Dashboard.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
sig {
params(debit_negative_balances: T.nilable(T::Boolean), schedule: T.nilable(::Stripe::Account::CreateParams::Settings::Payouts::Schedule), statement_descriptor: T.nilable(String)).void
}
def initialize(
debit_negative_balances: nil,
schedule: nil,
statement_descriptor: nil
); end
end
class TaxForms < Stripe::RequestParams
# Whether the account opted out of receiving their tax forms by postal delivery.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :consented_to_paperless_delivery
sig { params(consented_to_paperless_delivery: T.nilable(T::Boolean)).void }
def initialize(consented_to_paperless_delivery: nil); end
end
class Treasury < Stripe::RequestParams
class TosAcceptance < Stripe::RequestParams
# The Unix timestamp marking when the account representative accepted the service agreement.
sig { returns(T.nilable(Integer)) }
attr_accessor :date
# The IP address from which the account representative accepted the service agreement.
sig { returns(T.nilable(String)) }
attr_accessor :ip
# The user agent of the browser from which the account representative accepted the service agreement.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :user_agent
sig {
params(date: T.nilable(Integer), ip: T.nilable(String), user_agent: T.nilable(T.nilable(String))).void
}
def initialize(date: nil, ip: nil, user_agent: nil); end
end
# Details on the account's acceptance of the Stripe Treasury Services Agreement.
sig {
returns(T.nilable(::Stripe::Account::CreateParams::Settings::Treasury::TosAcceptance))
}
attr_accessor :tos_acceptance
sig {
params(tos_acceptance: T.nilable(::Stripe::Account::CreateParams::Settings::Treasury::TosAcceptance)).void
}
def initialize(tos_acceptance: nil); end
end
# Settings specific to Bacs Direct Debit.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Settings::BacsDebitPayments)) }
attr_accessor :bacs_debit_payments
# Settings specific to bank BCA onboarding for Indonesia bank transfers payments method.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Settings::BankBcaOnboarding)) }
attr_accessor :bank_bca_onboarding
# Settings used to apply the account's branding to email receipts, invoices, Checkout, and other products.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Settings::Branding)) }
attr_accessor :branding
# Settings specific to the account's use of the Capital product.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Settings::Capital)) }
attr_accessor :capital
# Settings specific to the account's use of the Card Issuing product.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Settings::CardIssuing)) }
attr_accessor :card_issuing
# Settings specific to card charging on the account.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Settings::CardPayments)) }
attr_accessor :card_payments
# Settings specific to the account’s use of Invoices.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Settings::Invoices)) }
attr_accessor :invoices
# Settings that apply across payment methods for charging on the account.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Settings::Payments)) }
attr_accessor :payments
# Settings specific to the account's payouts.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Settings::Payouts)) }
attr_accessor :payouts
# Settings specific to the account's tax forms.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Settings::TaxForms)) }
attr_accessor :tax_forms
# Settings specific to the account's Treasury FinancialAccounts.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Settings::Treasury)) }
attr_accessor :treasury
sig {
params(bacs_debit_payments: T.nilable(::Stripe::Account::CreateParams::Settings::BacsDebitPayments), bank_bca_onboarding: T.nilable(::Stripe::Account::CreateParams::Settings::BankBcaOnboarding), branding: T.nilable(::Stripe::Account::CreateParams::Settings::Branding), capital: T.nilable(::Stripe::Account::CreateParams::Settings::Capital), card_issuing: T.nilable(::Stripe::Account::CreateParams::Settings::CardIssuing), card_payments: T.nilable(::Stripe::Account::CreateParams::Settings::CardPayments), invoices: T.nilable(::Stripe::Account::CreateParams::Settings::Invoices), payments: T.nilable(::Stripe::Account::CreateParams::Settings::Payments), payouts: T.nilable(::Stripe::Account::CreateParams::Settings::Payouts), tax_forms: T.nilable(::Stripe::Account::CreateParams::Settings::TaxForms), treasury: T.nilable(::Stripe::Account::CreateParams::Settings::Treasury)).void
}
def initialize(
bacs_debit_payments: nil,
bank_bca_onboarding: nil,
branding: nil,
capital: nil,
card_issuing: nil,
card_payments: nil,
invoices: nil,
payments: nil,
payouts: nil,
tax_forms: nil,
treasury: nil
); end
end
class TosAcceptance < Stripe::RequestParams
# The Unix timestamp marking when the account representative accepted their service agreement.
sig { returns(T.nilable(Integer)) }
attr_accessor :date
# The IP address from which the account representative accepted their service agreement.
sig { returns(T.nilable(String)) }
attr_accessor :ip
# The user's service agreement type.
sig { returns(T.nilable(String)) }
attr_accessor :service_agreement
# The user agent of the browser from which the account representative accepted their service agreement.
sig { returns(T.nilable(String)) }
attr_accessor :user_agent
sig {
params(date: T.nilable(Integer), ip: T.nilable(String), service_agreement: T.nilable(String), user_agent: T.nilable(String)).void
}
def initialize(date: nil, ip: nil, service_agreement: nil, user_agent: nil); end
end
# An [account token](https://stripe.com/docs/api#create_account_token), used to securely provide details to the account.
sig { returns(T.nilable(String)) }
attr_accessor :account_token
# Business information about the account.
sig { returns(T.nilable(::Stripe::Account::CreateParams::BusinessProfile)) }
attr_accessor :business_profile
# The business type. Once you create an [Account Link](/api/account_links) or [Account Session](/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.
sig { returns(T.nilable(String)) }
attr_accessor :business_type
# Each key of the dictionary represents a capability, and each capability
# maps to its settings (for example, whether it has been requested or not). Each
# capability is inactive until you have provided its specific
# requirements and Stripe has verified them. An account might have some
# of its requested capabilities be active and some be inactive.
#
# Required when [account.controller.stripe_dashboard.type](/api/accounts/create#create_account-controller-dashboard-type)
# is `none`, which includes Custom accounts.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Capabilities)) }
attr_accessor :capabilities
# Information about the company or business. This field is available for any `business_type`. Once you create an [Account Link](/api/account_links) or [Account Session](/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Company)) }
attr_accessor :company
# A hash of configuration describing the account controller's attributes.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Controller)) }
attr_accessor :controller
# The country in which the account holder resides, or in which the business is legally established. This should be an ISO 3166-1 alpha-2 country code. For example, if you are in the United States and the business for which you're creating an account is legally represented in Canada, you would use `CA` as the country for the account being created. Available countries include [Stripe's global markets](https://stripe.com/global) as well as countries where [cross-border payouts](https://stripe.com/docs/connect/cross-border-payouts) are supported.
sig { returns(T.nilable(String)) }
attr_accessor :country
# Three-letter ISO currency code representing the default currency for the account. This must be a currency that [Stripe supports in the account's country](https://docs.stripe.com/payouts).
sig { returns(T.nilable(String)) }
attr_accessor :default_currency
# Documents that may be submitted to satisfy various informational requests.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Documents)) }
attr_accessor :documents
# The email address of the account holder. This is only to make the account easier to identify to you. If [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts, Stripe doesn't email the account without your consent.
sig { returns(T.nilable(String)) }
attr_accessor :email
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A card or bank account to attach to the account for receiving [payouts](/connect/bank-debit-card-payouts) (you won’t be able to use it for top-ups). You can provide either a token, like the ones returned by [Stripe.js](/js), or a dictionary, as documented in the `external_account` parameter for [bank account](/api#account_create_bank_account) creation.
By default, providing an external account sets it as the new default external account for its currency, and deletes the old default if one exists. To add additional external accounts without replacing the existing default for the currency, use the [bank account](/api#account_create_bank_account) or [card creation](/api#account_create_card) APIs. After you create an [Account Link](/api/account_links) or [Account Session](/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.
sig {
returns(T.nilable(T.any(String, ::Stripe::Account::CreateParams::BankAccount, ::Stripe::Account::CreateParams::Card, ::Stripe::Account::CreateParams::CardToken)))
}
attr_accessor :external_account
# A hash of account group type to tokens. These are account groups this account should be added to.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Groups)) }
attr_accessor :groups
# Information about the person represented by the account. This field is null unless `business_type` is set to `individual`. Once you create an [Account Link](/api/account_links) or [Account Session](/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Individual)) }
attr_accessor :individual
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# A hash to configure risk controls on the account. Please see [this page for more details](/connect/pausing-payments-or-payouts-on-connected-accounts).
sig { returns(T.nilable(::Stripe::Account::CreateParams::RiskControls)) }
attr_accessor :risk_controls
# Options for customizing how the account functions within Stripe.
sig { returns(T.nilable(::Stripe::Account::CreateParams::Settings)) }
attr_accessor :settings
# Details on the account's acceptance of the [Stripe Services Agreement](/connect/updating-accounts#tos-acceptance). This property can only be updated for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts. This property defaults to a `full` service agreement when empty.
sig { returns(T.nilable(::Stripe::Account::CreateParams::TosAcceptance)) }
attr_accessor :tos_acceptance
# The type of Stripe account to create. May be one of `custom`, `express` or `standard`.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(account_token: T.nilable(String), business_profile: T.nilable(::Stripe::Account::CreateParams::BusinessProfile), business_type: T.nilable(String), capabilities: T.nilable(::Stripe::Account::CreateParams::Capabilities), company: T.nilable(::Stripe::Account::CreateParams::Company), controller: T.nilable(::Stripe::Account::CreateParams::Controller), country: T.nilable(String), default_currency: T.nilable(String), documents: T.nilable(::Stripe::Account::CreateParams::Documents), email: T.nilable(String), expand: T.nilable(T::Array[String]), external_account: T.nilable(T.any(String, ::Stripe::Account::CreateParams::BankAccount, ::Stripe::Account::CreateParams::Card, ::Stripe::Account::CreateParams::CardToken)), groups: T.nilable(::Stripe::Account::CreateParams::Groups), individual: T.nilable(::Stripe::Account::CreateParams::Individual), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), risk_controls: T.nilable(::Stripe::Account::CreateParams::RiskControls), settings: T.nilable(::Stripe::Account::CreateParams::Settings), tos_acceptance: T.nilable(::Stripe::Account::CreateParams::TosAcceptance), type: T.nilable(String)).void
}
def initialize(
account_token: nil,
business_profile: nil,
business_type: nil,
capabilities: nil,
company: nil,
controller: nil,
country: nil,
default_currency: nil,
documents: nil,
email: nil,
expand: nil,
external_account: nil,
groups: nil,
individual: nil,
metadata: nil,
risk_controls: nil,
settings: nil,
tos_acceptance: nil,
type: nil
); end
end
class PersonsParams < Stripe::RequestParams
class Relationship < Stripe::RequestParams
# A filter on the list of people returned based on whether these people are authorizers of the account's representative.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :authorizer
# A filter on the list of people returned based on whether these people are directors of the account's company.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :director
# A filter on the list of people returned based on whether these people are executives of the account's company.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :executive
# A filter on the list of people returned based on whether these people are legal guardians of the account's representative.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :legal_guardian
# A filter on the list of people returned based on whether these people are owners of the account's company.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :owner
# A filter on the list of people returned based on whether these people are the representative of the account's company.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :representative
sig {
params(authorizer: T.nilable(T::Boolean), director: T.nilable(T::Boolean), executive: T.nilable(T::Boolean), legal_guardian: T.nilable(T::Boolean), owner: T.nilable(T::Boolean), representative: T.nilable(T::Boolean)).void
}
def initialize(
authorizer: nil,
director: nil,
executive: nil,
legal_guardian: nil,
owner: nil,
representative: nil
); end
end
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Filters on the list of people returned based on the person's relationship to the account's company.
sig { returns(T.nilable(::Stripe::Account::PersonsParams::Relationship)) }
attr_accessor :relationship
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), relationship: T.nilable(::Stripe::Account::PersonsParams::Relationship), starting_after: T.nilable(String)).void
}
def initialize(
ending_before: nil,
expand: nil,
limit: nil,
relationship: nil,
starting_after: nil
); end
end
class RejectParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The reason for rejecting the account. Can be `fraud`, `terms_of_service`, or `other`.
sig { returns(String) }
attr_accessor :reason
sig { params(expand: T.nilable(T::Array[String]), reason: String).void }
def initialize(expand: nil, reason: nil); end
end
# With [Connect](https://docs.stripe.com/docs/connect), you can create Stripe accounts for your users.
# To do this, you'll first need to [register your platform](https://dashboard.stripe.com/account/applications/settings).
#
# If you've already collected information for your connected accounts, you [can prefill that information](https://docs.stripe.com/docs/connect/best-practices#onboarding) when
# creating the account. Connect Onboarding won't ask for the prefilled information during account onboarding.
# You can prefill any information on the account.
sig {
params(params: T.any(::Stripe::Account::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Account)
}
def self.create(params = {}, opts = {}); end
# With [Connect](https://docs.stripe.com/connect), you can delete accounts you manage.
#
# Test-mode accounts can be deleted at any time.
#
# Live-mode accounts where Stripe is responsible for negative account balances cannot be deleted, which includes Standard accounts. Live-mode accounts where your platform is liable for negative account balances, which includes Custom and Express accounts, can be deleted when all [balances](https://docs.stripe.com/api/balance/balance_object) are zero.
#
# If you want to delete your own account, use the [account information tab in your account settings](https://dashboard.stripe.com/settings/account) instead.
sig {
params(account: String, params: T.any(::Stripe::Account::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Account)
}
def self.delete(account, params = {}, opts = {}); end
# With [Connect](https://docs.stripe.com/connect), you can delete accounts you manage.
#
# Test-mode accounts can be deleted at any time.
#
# Live-mode accounts where Stripe is responsible for negative account balances cannot be deleted, which includes Standard accounts. Live-mode accounts where your platform is liable for negative account balances, which includes Custom and Express accounts, can be deleted when all [balances](https://docs.stripe.com/api/balance/balance_object) are zero.
#
# If you want to delete your own account, use the [account information tab in your account settings](https://dashboard.stripe.com/settings/account) instead.
sig {
params(params: T.any(::Stripe::Account::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Account)
}
def delete(params = {}, opts = {}); end
# Returns a list of accounts connected to your platform via [Connect](https://docs.stripe.com/docs/connect). If you're not a platform, the list is empty.
sig {
params(params: T.any(::Stripe::Account::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Returns a list of people associated with the account's legal entity. The people are returned sorted by creation date, with the most recent people appearing first.
sig {
params(params: T.any(::Stripe::Account::PersonsParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def persons(params = {}, opts = {}); end
# Returns a list of people associated with the account's legal entity. The people are returned sorted by creation date, with the most recent people appearing first.
sig {
params(account: String, params: T.any(::Stripe::Account::PersonsParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.persons(account, params = {}, opts = {}); end
# With [Connect](https://docs.stripe.com/connect), you can reject accounts that you have flagged as suspicious.
#
# Only accounts where your platform is liable for negative account balances, which includes Custom and Express accounts, can be rejected. Test-mode accounts can be rejected at any time. Live-mode accounts can only be rejected after all balances are zero.
sig {
params(params: T.any(::Stripe::Account::RejectParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Account)
}
def reject(params = {}, opts = {}); end
# With [Connect](https://docs.stripe.com/connect), you can reject accounts that you have flagged as suspicious.
#
# Only accounts where your platform is liable for negative account balances, which includes Custom and Express accounts, can be rejected. Test-mode accounts can be rejected at any time. Live-mode accounts can only be rejected after all balances are zero.
sig {
params(account: String, params: T.any(::Stripe::Account::RejectParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Account)
}
def self.reject(account, params = {}, opts = {}); end
# Updates a [connected account](https://docs.stripe.com/connect/accounts) by setting the values of the parameters passed. Any parameters not provided are
# left unchanged.
#
# For accounts where [controller.requirement_collection](https://docs.stripe.com/api/accounts/object#account_object-controller-requirement_collection)
# is application, which includes Custom accounts, you can update any information on the account.
#
# For accounts where [controller.requirement_collection](https://docs.stripe.com/api/accounts/object#account_object-controller-requirement_collection)
# is stripe, which includes Standard and Express accounts, you can update all information until you create
# an [Account Link or Account Session](https://docs.stripe.com/api/account_links) to start Connect onboarding,
# after which some properties can no longer be updated.
#
# To update your own account, use the [Dashboard](https://dashboard.stripe.com/settings/account). Refer to our
# [Connect](https://docs.stripe.com/docs/connect/updating-accounts) documentation to learn more about updating accounts.
sig {
params(account: String, params: T.any(::Stripe::Account::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Account)
}
def self.update(account, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
# Account Links are the means by which a Connect platform grants a connected account permission to access
# Stripe-hosted applications, such as Connect Onboarding.
#
# Related guide: [Connect Onboarding](https://stripe.com/docs/connect/custom/hosted-onboarding)
class AccountLink < APIResource
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# The timestamp at which this account link will expire.
sig { returns(Integer) }
attr_reader :expires_at
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The URL for the account link.
sig { returns(String) }
attr_reader :url
class CreateParams < Stripe::RequestParams
class CollectionOptions < Stripe::RequestParams
# Specifies whether the platform collects only currently_due requirements (`currently_due`) or both currently_due and eventually_due requirements (`eventually_due`). If you don't specify `collection_options`, the default value is `currently_due`.
sig { returns(T.nilable(String)) }
attr_accessor :fields
# Specifies whether the platform collects future_requirements in addition to requirements in Connect Onboarding. The default value is `omit`.
sig { returns(T.nilable(String)) }
attr_accessor :future_requirements
sig { params(fields: T.nilable(String), future_requirements: T.nilable(String)).void }
def initialize(fields: nil, future_requirements: nil); end
end
# The identifier of the account to create an account link for.
sig { returns(String) }
attr_accessor :account
# The collect parameter is deprecated. Use `collection_options` instead.
sig { returns(T.nilable(String)) }
attr_accessor :collect
# Specifies the requirements that Stripe collects from connected accounts in the Connect Onboarding flow.
sig { returns(T.nilable(::Stripe::AccountLink::CreateParams::CollectionOptions)) }
attr_accessor :collection_options
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The URL the user will be redirected to if the account link is expired, has been previously-visited, or is otherwise invalid. The URL you specify should attempt to generate a new account link with the same parameters used to create the original account link, then redirect the user to the new account link's URL so they can continue with Connect Onboarding. If a new account link cannot be generated or the redirect fails you should display a useful error to the user.
sig { returns(T.nilable(String)) }
attr_accessor :refresh_url
# The URL that the user will be redirected to upon leaving or completing the linked flow.
sig { returns(T.nilable(String)) }
attr_accessor :return_url
# The type of account link the user is requesting. Possible values are `account_onboarding` or `account_update`.
sig { returns(String) }
attr_accessor :type
sig {
params(account: String, collect: T.nilable(String), collection_options: T.nilable(::Stripe::AccountLink::CreateParams::CollectionOptions), expand: T.nilable(T::Array[String]), refresh_url: T.nilable(String), return_url: T.nilable(String), type: String).void
}
def initialize(
account: nil,
collect: nil,
collection_options: nil,
expand: nil,
refresh_url: nil,
return_url: nil,
type: nil
); end
end
# Creates an AccountLink object that includes a single-use Stripe URL that the platform can redirect their user to in order to take them through the Connect Onboarding flow.
sig {
params(params: T.any(::Stripe::AccountLink::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::AccountLink)
}
def self.create(params = {}, opts = {}); end
end
end
# typed: true
module Stripe
# A notice to a Connected account. Notice can be sent by Stripe on your behalf or you can opt to send the notices yourself.
#
# See the [guide to send notices](https://stripe.com/docs/issuing/compliance-us/issuing-regulated-customer-notices) to your connected accounts.
class AccountNotice < APIResource
class Email < Stripe::StripeObject
# Content of the email in plain text. The copy must match exactly the language that Stripe Compliance has approved for use.
sig { returns(String) }
attr_reader :plain_text
# Email address of the recipient.
sig { returns(String) }
attr_reader :recipient
# Subject of the email.
sig { returns(String) }
attr_reader :subject
end
class LinkedObjects < Stripe::StripeObject
# Associated [Capability](https://stripe.com/docs/api/capabilities)
sig { returns(T.nilable(String)) }
attr_reader :capability
# Associated [Credit Underwriting Record](https://stripe.com/docs/api/issuing/credit_underwriting_record)
sig { returns(T.nilable(String)) }
attr_reader :issuing_credit_underwriting_record
# Associated [Issuing Dispute](https://stripe.com/docs/api/issuing/disputes)
sig { returns(T.nilable(String)) }
attr_reader :issuing_dispute
end
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# When present, the deadline for sending the notice to meet the relevant regulations.
sig { returns(T.nilable(Integer)) }
attr_reader :deadline
# Information about the email when sent.
sig { returns(T.nilable(Email)) }
attr_reader :email
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Information about objects related to the notice.
sig { returns(T.nilable(LinkedObjects)) }
attr_reader :linked_objects
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# 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.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Reason the notice is being sent. The reason determines what copy the notice must contain. See the [regulated customer notices](https://stripe.com/docs/issuing/compliance-us/issuing-regulated-customer-notices) guide. All reasons might not apply to your integration, and Stripe might add new reasons in the future, so we recommend an internal warning when you receive an unknown reason.
sig { returns(String) }
attr_reader :reason
# Date when the notice was sent. When absent, you must send the notice, update the content of the email and date when it was sent.
sig { returns(T.nilable(Integer)) }
attr_reader :sent_at
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Set to false to only return unsent AccountNotices.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :sent
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), sent: T.nilable(T::Boolean), starting_after: T.nilable(String)).void
}
def initialize(
ending_before: nil,
expand: nil,
limit: nil,
sent: nil,
starting_after: nil
); end
end
class UpdateParams < Stripe::RequestParams
class Email < Stripe::RequestParams
# Content of the email in plain text. The copy must match exactly the language that Stripe Compliance has approved for use.
sig { returns(String) }
attr_accessor :plain_text
# Email address of the recipient.
sig { returns(String) }
attr_accessor :recipient
# Subject of the email.
sig { returns(String) }
attr_accessor :subject
sig { params(plain_text: String, recipient: String, subject: String).void }
def initialize(plain_text: nil, recipient: nil, subject: nil); end
end
# Information about the email you sent.
sig { returns(::Stripe::AccountNotice::UpdateParams::Email) }
attr_accessor :email
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Date when you sent the notice.
sig { returns(Integer) }
attr_accessor :sent_at
sig {
params(email: ::Stripe::AccountNotice::UpdateParams::Email, expand: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), sent_at: Integer).void
}
def initialize(email: nil, expand: nil, metadata: nil, sent_at: nil); end
end
# Retrieves a list of AccountNotice objects. The objects are sorted in descending order by creation date, with the most-recently-created object appearing first.
sig {
params(params: T.any(::Stripe::AccountNotice::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Updates an AccountNotice object.
sig {
params(account_notice: String, params: T.any(::Stripe::AccountNotice::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::AccountNotice)
}
def self.update(account_notice, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
# An AccountSession allows a Connect platform to grant access to a connected account in Connect embedded components.
#
# We recommend that you create an AccountSession each time you need to display an embedded component
# to your user. Do not save AccountSessions to your database as they expire relatively
# quickly, and cannot be used more than once.
#
# Related guide: [Connect embedded components](https://stripe.com/docs/connect/get-started-connect-embedded-components)
class AccountSession < APIResource
class Components < Stripe::StripeObject
class AccountManagement < Stripe::StripeObject
class Features < Stripe::StripeObject
# Disables Stripe user authentication for this embedded component. This value can only be true for accounts where `controller.requirement_collection` is `application`. The default value is the opposite of the `external_account_collection` value. For example, if you don’t set `external_account_collection`, it defaults to true and `disable_stripe_user_authentication` defaults to false.
sig { returns(T::Boolean) }
attr_reader :disable_stripe_user_authentication
# Whether to allow platforms to control bank account collection for their connected accounts. This feature can only be false for accounts where you’re responsible for collecting updated information when requirements are due or change, like custom accounts. Otherwise, bank account collection is determined by compliance requirements. The default value for this feature is `true`.
sig { returns(T::Boolean) }
attr_reader :external_account_collection
end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_reader :enabled
# Attribute for field features
sig { returns(Features) }
attr_reader :features
end
class AccountOnboarding < Stripe::StripeObject
class Features < Stripe::StripeObject
# Disables Stripe user authentication for this embedded component. This value can only be true for accounts where `controller.requirement_collection` is `application`. The default value is the opposite of the `external_account_collection` value. For example, if you don’t set `external_account_collection`, it defaults to true and `disable_stripe_user_authentication` defaults to false.
sig { returns(T::Boolean) }
attr_reader :disable_stripe_user_authentication
# Whether to allow platforms to control bank account collection for their connected accounts. This feature can only be false for accounts where you’re responsible for collecting updated information when requirements are due or change, like custom accounts. Otherwise, bank account collection is determined by compliance requirements. The default value for this feature is `true`.
sig { returns(T::Boolean) }
attr_reader :external_account_collection
end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_reader :enabled
# Attribute for field features
sig { returns(Features) }
attr_reader :features
end
class Balances < Stripe::StripeObject
class Features < Stripe::StripeObject
# Disables Stripe user authentication for this embedded component. This value can only be true for accounts where `controller.requirement_collection` is `application`. The default value is the opposite of the `external_account_collection` value. For example, if you don’t set `external_account_collection`, it defaults to true and `disable_stripe_user_authentication` defaults to false.
sig { returns(T::Boolean) }
attr_reader :disable_stripe_user_authentication
# Whether to allow payout schedule to be changed. Default `true` when Stripe owns Loss Liability, default `false` otherwise.
sig { returns(T::Boolean) }
attr_reader :edit_payout_schedule
# Whether to allow platforms to control bank account collection for their connected accounts. This feature can only be false for accounts where you’re responsible for collecting updated information when requirements are due or change, like custom accounts. Otherwise, bank account collection is determined by compliance requirements. The default value for this feature is `true`.
sig { returns(T::Boolean) }
attr_reader :external_account_collection
# Whether to allow creation of instant payouts. Default `true` when Stripe owns Loss Liability, default `false` otherwise.
sig { returns(T::Boolean) }
attr_reader :instant_payouts
# Whether to allow creation of standard payouts. Default `true` when Stripe owns Loss Liability, default `false` otherwise.
sig { returns(T::Boolean) }
attr_reader :standard_payouts
end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_reader :enabled
# Attribute for field features
sig { returns(Features) }
attr_reader :features
end
class CapitalFinancing < Stripe::StripeObject
class Features < Stripe::StripeObject; end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_reader :enabled
# Attribute for field features
sig { returns(Features) }
attr_reader :features
end
class CapitalFinancingApplication < Stripe::StripeObject
class Features < Stripe::StripeObject; end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_reader :enabled
# Attribute for field features
sig { returns(Features) }
attr_reader :features
end
class CapitalFinancingPromotion < Stripe::StripeObject
class Features < Stripe::StripeObject; end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_reader :enabled
# Attribute for field features
sig { returns(Features) }
attr_reader :features
end
class DisputesList < Stripe::StripeObject
class Features < Stripe::StripeObject
# Whether to allow capturing and cancelling payment intents. This is `true` by default.
sig { returns(T::Boolean) }
attr_reader :capture_payments
# Whether to allow connected accounts to manage destination charges that are created on behalf of them. This is `false` by default.
sig { returns(T::Boolean) }
attr_reader :destination_on_behalf_of_charge_management
# Whether to allow responding to disputes, including submitting evidence and accepting disputes. This is `true` by default.
sig { returns(T::Boolean) }
attr_reader :dispute_management
# Whether to allow sending refunds. This is `true` by default.
sig { returns(T::Boolean) }
attr_reader :refund_management
end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_reader :enabled
# Attribute for field features
sig { returns(Features) }
attr_reader :features
end
class Documents < Stripe::StripeObject
class Features < Stripe::StripeObject; end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_reader :enabled
# Attribute for field features
sig { returns(Features) }
attr_reader :features
end
class FinancialAccount < Stripe::StripeObject
class Features < Stripe::StripeObject
# Disables Stripe user authentication for this embedded component. This value can only be true for accounts where `controller.requirement_collection` is `application`. The default value is the opposite of the `external_account_collection` value. For example, if you don’t set `external_account_collection`, it defaults to true and `disable_stripe_user_authentication` defaults to false.
sig { returns(T::Boolean) }
attr_reader :disable_stripe_user_authentication
# Whether to allow external accounts to be linked for money transfer.
sig { returns(T::Boolean) }
attr_reader :external_account_collection
# Whether to allow sending money.
sig { returns(T::Boolean) }
attr_reader :send_money
# Whether to allow transferring balance.
sig { returns(T::Boolean) }
attr_reader :transfer_balance
end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_reader :enabled
# Attribute for field features
sig { returns(Features) }
attr_reader :features
end
class FinancialAccountTransactions < Stripe::StripeObject
class Features < Stripe::StripeObject
# Whether to allow card spend dispute management features.
sig { returns(T::Boolean) }
attr_reader :card_spend_dispute_management
end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_reader :enabled
# Attribute for field features
sig { returns(Features) }
attr_reader :features
end
class IssuingCard < Stripe::StripeObject
class Features < Stripe::StripeObject
# Whether to allow card management features.
sig { returns(T::Boolean) }
attr_reader :card_management
# Whether to allow card spend dispute management features.
sig { returns(T::Boolean) }
attr_reader :card_spend_dispute_management
# Whether to allow cardholder management features.
sig { returns(T::Boolean) }
attr_reader :cardholder_management
# Whether to allow spend control management features.
sig { returns(T::Boolean) }
attr_reader :spend_control_management
end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_reader :enabled
# Attribute for field features
sig { returns(Features) }
attr_reader :features
end
class IssuingCardsList < Stripe::StripeObject
class Features < Stripe::StripeObject
# Whether to allow card management features.
sig { returns(T::Boolean) }
attr_reader :card_management
# Whether to allow card spend dispute management features.
sig { returns(T::Boolean) }
attr_reader :card_spend_dispute_management
# Whether to allow cardholder management features.
sig { returns(T::Boolean) }
attr_reader :cardholder_management
# Disables Stripe user authentication for this embedded component. This feature can only be false for accounts where you’re responsible for collecting updated information when requirements are due or change, like custom accounts.
sig { returns(T::Boolean) }
attr_reader :disable_stripe_user_authentication
# Whether to allow spend control management features.
sig { returns(T::Boolean) }
attr_reader :spend_control_management
end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_reader :enabled
# Attribute for field features
sig { returns(Features) }
attr_reader :features
end
class NotificationBanner < Stripe::StripeObject
class Features < Stripe::StripeObject
# Disables Stripe user authentication for this embedded component. This value can only be true for accounts where `controller.requirement_collection` is `application`. The default value is the opposite of the `external_account_collection` value. For example, if you don’t set `external_account_collection`, it defaults to true and `disable_stripe_user_authentication` defaults to false.
sig { returns(T::Boolean) }
attr_reader :disable_stripe_user_authentication
# Whether to allow platforms to control bank account collection for their connected accounts. This feature can only be false for accounts where you’re responsible for collecting updated information when requirements are due or change, like custom accounts. Otherwise, bank account collection is determined by compliance requirements. The default value for this feature is `true`.
sig { returns(T::Boolean) }
attr_reader :external_account_collection
end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_reader :enabled
# Attribute for field features
sig { returns(Features) }
attr_reader :features
end
class PaymentDetails < Stripe::StripeObject
class Features < Stripe::StripeObject
# Whether to allow capturing and cancelling payment intents. This is `true` by default.
sig { returns(T::Boolean) }
attr_reader :capture_payments
# Whether to allow connected accounts to manage destination charges that are created on behalf of them. This is `false` by default.
sig { returns(T::Boolean) }
attr_reader :destination_on_behalf_of_charge_management
# Whether to allow responding to disputes, including submitting evidence and accepting disputes. This is `true` by default.
sig { returns(T::Boolean) }
attr_reader :dispute_management
# Whether to allow sending refunds. This is `true` by default.
sig { returns(T::Boolean) }
attr_reader :refund_management
end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_reader :enabled
# Attribute for field features
sig { returns(Features) }
attr_reader :features
end
class PaymentDisputes < Stripe::StripeObject
class Features < Stripe::StripeObject
# Whether to allow connected accounts to manage destination charges that are created on behalf of them. This is `false` by default.
sig { returns(T::Boolean) }
attr_reader :destination_on_behalf_of_charge_management
# Whether to allow responding to disputes, including submitting evidence and accepting disputes. This is `true` by default.
sig { returns(T::Boolean) }
attr_reader :dispute_management
# Whether to allow sending refunds. This is `true` by default.
sig { returns(T::Boolean) }
attr_reader :refund_management
end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_reader :enabled
# Attribute for field features
sig { returns(Features) }
attr_reader :features
end
class Payments < Stripe::StripeObject
class Features < Stripe::StripeObject
# Whether to allow capturing and cancelling payment intents. This is `true` by default.
sig { returns(T::Boolean) }
attr_reader :capture_payments
# Whether to allow connected accounts to manage destination charges that are created on behalf of them. This is `false` by default.
sig { returns(T::Boolean) }
attr_reader :destination_on_behalf_of_charge_management
# Whether to allow responding to disputes, including submitting evidence and accepting disputes. This is `true` by default.
sig { returns(T::Boolean) }
attr_reader :dispute_management
# Whether to allow sending refunds. This is `true` by default.
sig { returns(T::Boolean) }
attr_reader :refund_management
end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_reader :enabled
# Attribute for field features
sig { returns(Features) }
attr_reader :features
end
class Payouts < Stripe::StripeObject
class Features < Stripe::StripeObject
# Disables Stripe user authentication for this embedded component. This value can only be true for accounts where `controller.requirement_collection` is `application`. The default value is the opposite of the `external_account_collection` value. For example, if you don’t set `external_account_collection`, it defaults to true and `disable_stripe_user_authentication` defaults to false.
sig { returns(T::Boolean) }
attr_reader :disable_stripe_user_authentication
# Whether to allow payout schedule to be changed. Default `true` when Stripe owns Loss Liability, default `false` otherwise.
sig { returns(T::Boolean) }
attr_reader :edit_payout_schedule
# Whether to allow platforms to control bank account collection for their connected accounts. This feature can only be false for accounts where you’re responsible for collecting updated information when requirements are due or change, like custom accounts. Otherwise, bank account collection is determined by compliance requirements. The default value for this feature is `true`.
sig { returns(T::Boolean) }
attr_reader :external_account_collection
# Whether to allow creation of instant payouts. Default `true` when Stripe owns Loss Liability, default `false` otherwise.
sig { returns(T::Boolean) }
attr_reader :instant_payouts
# Whether to allow creation of standard payouts. Default `true` when Stripe owns Loss Liability, default `false` otherwise.
sig { returns(T::Boolean) }
attr_reader :standard_payouts
end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_reader :enabled
# Attribute for field features
sig { returns(Features) }
attr_reader :features
end
class PayoutsList < Stripe::StripeObject
class Features < Stripe::StripeObject; end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_reader :enabled
# Attribute for field features
sig { returns(Features) }
attr_reader :features
end
class TaxRegistrations < Stripe::StripeObject
class Features < Stripe::StripeObject; end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_reader :enabled
# Attribute for field features
sig { returns(Features) }
attr_reader :features
end
class TaxSettings < Stripe::StripeObject
class Features < Stripe::StripeObject; end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_reader :enabled
# Attribute for field features
sig { returns(Features) }
attr_reader :features
end
# Attribute for field account_management
sig { returns(AccountManagement) }
attr_reader :account_management
# Attribute for field account_onboarding
sig { returns(AccountOnboarding) }
attr_reader :account_onboarding
# Attribute for field balances
sig { returns(Balances) }
attr_reader :balances
# Attribute for field capital_financing
sig { returns(T.nilable(CapitalFinancing)) }
attr_reader :capital_financing
# Attribute for field capital_financing_application
sig { returns(T.nilable(CapitalFinancingApplication)) }
attr_reader :capital_financing_application
# Attribute for field capital_financing_promotion
sig { returns(T.nilable(CapitalFinancingPromotion)) }
attr_reader :capital_financing_promotion
# Attribute for field disputes_list
sig { returns(DisputesList) }
attr_reader :disputes_list
# Attribute for field documents
sig { returns(Documents) }
attr_reader :documents
# Attribute for field financial_account
sig { returns(FinancialAccount) }
attr_reader :financial_account
# Attribute for field financial_account_transactions
sig { returns(FinancialAccountTransactions) }
attr_reader :financial_account_transactions
# Attribute for field issuing_card
sig { returns(IssuingCard) }
attr_reader :issuing_card
# Attribute for field issuing_cards_list
sig { returns(IssuingCardsList) }
attr_reader :issuing_cards_list
# Attribute for field notification_banner
sig { returns(NotificationBanner) }
attr_reader :notification_banner
# Attribute for field payment_details
sig { returns(PaymentDetails) }
attr_reader :payment_details
# Attribute for field payment_disputes
sig { returns(PaymentDisputes) }
attr_reader :payment_disputes
# Attribute for field payments
sig { returns(Payments) }
attr_reader :payments
# Attribute for field payouts
sig { returns(Payouts) }
attr_reader :payouts
# Attribute for field payouts_list
sig { returns(PayoutsList) }
attr_reader :payouts_list
# Attribute for field tax_registrations
sig { returns(TaxRegistrations) }
attr_reader :tax_registrations
# Attribute for field tax_settings
sig { returns(TaxSettings) }
attr_reader :tax_settings
end
# The ID of the account the AccountSession was created for
sig { returns(String) }
attr_reader :account
# The client secret of this AccountSession. Used on the client to set up secure access to the given `account`.
#
# The client secret can be used to provide access to `account` from your frontend. It should not be stored, logged, or exposed to anyone other than the connected account. Make sure that you have TLS enabled on any page that includes the client secret.
#
# Refer to our docs to [setup Connect embedded components](https://stripe.com/docs/connect/get-started-connect-embedded-components) and learn about how `client_secret` should be handled.
sig { returns(String) }
attr_reader :client_secret
# Attribute for field components
sig { returns(Components) }
attr_reader :components
# The timestamp at which this AccountSession will expire.
sig { returns(Integer) }
attr_reader :expires_at
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
class CreateParams < Stripe::RequestParams
class Components < Stripe::RequestParams
class AccountManagement < Stripe::RequestParams
class Features < Stripe::RequestParams
# Disables Stripe user authentication for this embedded component. This value can only be true for accounts where `controller.requirement_collection` is `application`. The default value is the opposite of the `external_account_collection` value. For example, if you don’t set `external_account_collection`, it defaults to true and `disable_stripe_user_authentication` defaults to false.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :disable_stripe_user_authentication
# Whether to allow platforms to control bank account collection for their connected accounts. This feature can only be false for accounts where you’re responsible for collecting updated information when requirements are due or change, like custom accounts. Otherwise, bank account collection is determined by compliance requirements. The default value for this feature is `true`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :external_account_collection
sig {
params(disable_stripe_user_authentication: T.nilable(T::Boolean), external_account_collection: T.nilable(T::Boolean)).void
}
def initialize(
disable_stripe_user_authentication: nil,
external_account_collection: nil
); end
end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::AccountManagement::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSession::CreateParams::Components::AccountManagement::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class AccountOnboarding < Stripe::RequestParams
class Features < Stripe::RequestParams
# Disables Stripe user authentication for this embedded component. This value can only be true for accounts where `controller.requirement_collection` is `application`. The default value is the opposite of the `external_account_collection` value. For example, if you don’t set `external_account_collection`, it defaults to true and `disable_stripe_user_authentication` defaults to false.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :disable_stripe_user_authentication
# Whether to allow platforms to control bank account collection for their connected accounts. This feature can only be false for accounts where you’re responsible for collecting updated information when requirements are due or change, like custom accounts. Otherwise, bank account collection is determined by compliance requirements. The default value for this feature is `true`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :external_account_collection
sig {
params(disable_stripe_user_authentication: T.nilable(T::Boolean), external_account_collection: T.nilable(T::Boolean)).void
}
def initialize(
disable_stripe_user_authentication: nil,
external_account_collection: nil
); end
end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::AccountOnboarding::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSession::CreateParams::Components::AccountOnboarding::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class AppInstall < Stripe::RequestParams
class Features < Stripe::RequestParams
# List of apps allowed to be enabled for this account session.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :allowed_apps
sig { params(allowed_apps: T.nilable(T.nilable(T.any(String, T::Array[String])))).void }
def initialize(allowed_apps: nil); end
end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::AppInstall::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSession::CreateParams::Components::AppInstall::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class AppViewport < Stripe::RequestParams
class Features < Stripe::RequestParams
# List of apps allowed to be enabled for this account session.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :allowed_apps
sig { params(allowed_apps: T.nilable(T.nilable(T.any(String, T::Array[String])))).void }
def initialize(allowed_apps: nil); end
end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::AppViewport::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSession::CreateParams::Components::AppViewport::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class Balances < Stripe::RequestParams
class Features < Stripe::RequestParams
# Disables Stripe user authentication for this embedded component. This value can only be true for accounts where `controller.requirement_collection` is `application`. The default value is the opposite of the `external_account_collection` value. For example, if you don’t set `external_account_collection`, it defaults to true and `disable_stripe_user_authentication` defaults to false.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :disable_stripe_user_authentication
# Whether to allow payout schedule to be changed. Default `true` when Stripe owns Loss Liability, default `false` otherwise.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :edit_payout_schedule
# Whether to allow platforms to control bank account collection for their connected accounts. This feature can only be false for accounts where you’re responsible for collecting updated information when requirements are due or change, like custom accounts. Otherwise, bank account collection is determined by compliance requirements. The default value for this feature is `true`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :external_account_collection
# Whether to allow creation of instant payouts. Default `true` when Stripe owns Loss Liability, default `false` otherwise.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :instant_payouts
# Whether to allow creation of standard payouts. Default `true` when Stripe owns Loss Liability, default `false` otherwise.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :standard_payouts
sig {
params(disable_stripe_user_authentication: T.nilable(T::Boolean), edit_payout_schedule: T.nilable(T::Boolean), external_account_collection: T.nilable(T::Boolean), instant_payouts: T.nilable(T::Boolean), standard_payouts: T.nilable(T::Boolean)).void
}
def initialize(
disable_stripe_user_authentication: nil,
edit_payout_schedule: nil,
external_account_collection: nil,
instant_payouts: nil,
standard_payouts: nil
); end
end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::Balances::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSession::CreateParams::Components::Balances::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class CapitalFinancing < Stripe::RequestParams
class Features < Stripe::RequestParams; end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::CapitalFinancing::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSession::CreateParams::Components::CapitalFinancing::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class CapitalFinancingApplication < Stripe::RequestParams
class Features < Stripe::RequestParams; end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::CapitalFinancingApplication::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSession::CreateParams::Components::CapitalFinancingApplication::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class CapitalFinancingPromotion < Stripe::RequestParams
class Features < Stripe::RequestParams; end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::CapitalFinancingPromotion::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSession::CreateParams::Components::CapitalFinancingPromotion::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class CapitalOverview < Stripe::RequestParams
class Features < Stripe::RequestParams; end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::CapitalOverview::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSession::CreateParams::Components::CapitalOverview::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class DisputesList < Stripe::RequestParams
class Features < Stripe::RequestParams
# Whether to allow capturing and cancelling payment intents. This is `true` by default.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :capture_payments
# Whether to allow connected accounts to manage destination charges that are created on behalf of them. This is `false` by default.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :destination_on_behalf_of_charge_management
# Whether to allow responding to disputes, including submitting evidence and accepting disputes. This is `true` by default.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :dispute_management
# Whether to allow sending refunds. This is `true` by default.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :refund_management
sig {
params(capture_payments: T.nilable(T::Boolean), destination_on_behalf_of_charge_management: T.nilable(T::Boolean), dispute_management: T.nilable(T::Boolean), refund_management: T.nilable(T::Boolean)).void
}
def initialize(
capture_payments: nil,
destination_on_behalf_of_charge_management: nil,
dispute_management: nil,
refund_management: nil
); end
end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::DisputesList::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSession::CreateParams::Components::DisputesList::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class Documents < Stripe::RequestParams
class Features < Stripe::RequestParams; end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::Documents::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSession::CreateParams::Components::Documents::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class ExportTaxTransactions < Stripe::RequestParams
class Features < Stripe::RequestParams; end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::ExportTaxTransactions::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSession::CreateParams::Components::ExportTaxTransactions::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class FinancialAccount < Stripe::RequestParams
class Features < Stripe::RequestParams
# Disables Stripe user authentication for this embedded component. This value can only be true for accounts where `controller.requirement_collection` is `application`. The default value is the opposite of the `external_account_collection` value. For example, if you don’t set `external_account_collection`, it defaults to true and `disable_stripe_user_authentication` defaults to false.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :disable_stripe_user_authentication
# Whether to allow external accounts to be linked for money transfer.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :external_account_collection
# Whether to allow sending money.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :send_money
# Whether to allow transferring balance.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :transfer_balance
sig {
params(disable_stripe_user_authentication: T.nilable(T::Boolean), external_account_collection: T.nilable(T::Boolean), send_money: T.nilable(T::Boolean), transfer_balance: T.nilable(T::Boolean)).void
}
def initialize(
disable_stripe_user_authentication: nil,
external_account_collection: nil,
send_money: nil,
transfer_balance: nil
); end
end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::FinancialAccount::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSession::CreateParams::Components::FinancialAccount::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class FinancialAccountTransactions < Stripe::RequestParams
class Features < Stripe::RequestParams
# Whether to allow card spend dispute management features.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :card_spend_dispute_management
sig { params(card_spend_dispute_management: T.nilable(T::Boolean)).void }
def initialize(card_spend_dispute_management: nil); end
end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::FinancialAccountTransactions::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSession::CreateParams::Components::FinancialAccountTransactions::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class IssuingCard < Stripe::RequestParams
class Features < Stripe::RequestParams
# Whether to allow card management features.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :card_management
# Whether to allow card spend dispute management features.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :card_spend_dispute_management
# Whether to allow cardholder management features.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :cardholder_management
# Whether to allow spend control management features.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :spend_control_management
sig {
params(card_management: T.nilable(T::Boolean), card_spend_dispute_management: T.nilable(T::Boolean), cardholder_management: T.nilable(T::Boolean), spend_control_management: T.nilable(T::Boolean)).void
}
def initialize(
card_management: nil,
card_spend_dispute_management: nil,
cardholder_management: nil,
spend_control_management: nil
); end
end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::IssuingCard::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSession::CreateParams::Components::IssuingCard::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class IssuingCardsList < Stripe::RequestParams
class Features < Stripe::RequestParams
# Whether to allow card management features.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :card_management
# Whether to allow card spend dispute management features.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :card_spend_dispute_management
# Whether to allow cardholder management features.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :cardholder_management
# Disables Stripe user authentication for this embedded component. This feature can only be false for accounts where you’re responsible for collecting updated information when requirements are due or change, like custom accounts.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :disable_stripe_user_authentication
# Whether to allow spend control management features.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :spend_control_management
sig {
params(card_management: T.nilable(T::Boolean), card_spend_dispute_management: T.nilable(T::Boolean), cardholder_management: T.nilable(T::Boolean), disable_stripe_user_authentication: T.nilable(T::Boolean), spend_control_management: T.nilable(T::Boolean)).void
}
def initialize(
card_management: nil,
card_spend_dispute_management: nil,
cardholder_management: nil,
disable_stripe_user_authentication: nil,
spend_control_management: nil
); end
end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::IssuingCardsList::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSession::CreateParams::Components::IssuingCardsList::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class NotificationBanner < Stripe::RequestParams
class Features < Stripe::RequestParams
# Disables Stripe user authentication for this embedded component. This value can only be true for accounts where `controller.requirement_collection` is `application`. The default value is the opposite of the `external_account_collection` value. For example, if you don’t set `external_account_collection`, it defaults to true and `disable_stripe_user_authentication` defaults to false.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :disable_stripe_user_authentication
# Whether to allow platforms to control bank account collection for their connected accounts. This feature can only be false for accounts where you’re responsible for collecting updated information when requirements are due or change, like custom accounts. Otherwise, bank account collection is determined by compliance requirements. The default value for this feature is `true`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :external_account_collection
sig {
params(disable_stripe_user_authentication: T.nilable(T::Boolean), external_account_collection: T.nilable(T::Boolean)).void
}
def initialize(
disable_stripe_user_authentication: nil,
external_account_collection: nil
); end
end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::NotificationBanner::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSession::CreateParams::Components::NotificationBanner::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class PaymentDetails < Stripe::RequestParams
class Features < Stripe::RequestParams
# Whether to allow capturing and cancelling payment intents. This is `true` by default.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :capture_payments
# Whether to allow connected accounts to manage destination charges that are created on behalf of them. This is `false` by default.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :destination_on_behalf_of_charge_management
# Whether to allow responding to disputes, including submitting evidence and accepting disputes. This is `true` by default.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :dispute_management
# Whether to allow sending refunds. This is `true` by default.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :refund_management
sig {
params(capture_payments: T.nilable(T::Boolean), destination_on_behalf_of_charge_management: T.nilable(T::Boolean), dispute_management: T.nilable(T::Boolean), refund_management: T.nilable(T::Boolean)).void
}
def initialize(
capture_payments: nil,
destination_on_behalf_of_charge_management: nil,
dispute_management: nil,
refund_management: nil
); end
end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::PaymentDetails::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSession::CreateParams::Components::PaymentDetails::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class PaymentDisputes < Stripe::RequestParams
class Features < Stripe::RequestParams
# Whether to allow connected accounts to manage destination charges that are created on behalf of them. This is `false` by default.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :destination_on_behalf_of_charge_management
# Whether to allow responding to disputes, including submitting evidence and accepting disputes. This is `true` by default.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :dispute_management
# Whether to allow sending refunds. This is `true` by default.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :refund_management
sig {
params(destination_on_behalf_of_charge_management: T.nilable(T::Boolean), dispute_management: T.nilable(T::Boolean), refund_management: T.nilable(T::Boolean)).void
}
def initialize(
destination_on_behalf_of_charge_management: nil,
dispute_management: nil,
refund_management: nil
); end
end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::PaymentDisputes::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSession::CreateParams::Components::PaymentDisputes::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class PaymentMethodSettings < Stripe::RequestParams
class Features < Stripe::RequestParams; end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::PaymentMethodSettings::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSession::CreateParams::Components::PaymentMethodSettings::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class Payments < Stripe::RequestParams
class Features < Stripe::RequestParams
# Whether to allow capturing and cancelling payment intents. This is `true` by default.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :capture_payments
# Whether to allow connected accounts to manage destination charges that are created on behalf of them. This is `false` by default.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :destination_on_behalf_of_charge_management
# Whether to allow responding to disputes, including submitting evidence and accepting disputes. This is `true` by default.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :dispute_management
# Whether to allow sending refunds. This is `true` by default.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :refund_management
sig {
params(capture_payments: T.nilable(T::Boolean), destination_on_behalf_of_charge_management: T.nilable(T::Boolean), dispute_management: T.nilable(T::Boolean), refund_management: T.nilable(T::Boolean)).void
}
def initialize(
capture_payments: nil,
destination_on_behalf_of_charge_management: nil,
dispute_management: nil,
refund_management: nil
); end
end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::Payments::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSession::CreateParams::Components::Payments::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class Payouts < Stripe::RequestParams
class Features < Stripe::RequestParams
# Disables Stripe user authentication for this embedded component. This value can only be true for accounts where `controller.requirement_collection` is `application`. The default value is the opposite of the `external_account_collection` value. For example, if you don’t set `external_account_collection`, it defaults to true and `disable_stripe_user_authentication` defaults to false.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :disable_stripe_user_authentication
# Whether to allow payout schedule to be changed. Default `true` when Stripe owns Loss Liability, default `false` otherwise.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :edit_payout_schedule
# Whether to allow platforms to control bank account collection for their connected accounts. This feature can only be false for accounts where you’re responsible for collecting updated information when requirements are due or change, like custom accounts. Otherwise, bank account collection is determined by compliance requirements. The default value for this feature is `true`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :external_account_collection
# Whether to allow creation of instant payouts. Default `true` when Stripe owns Loss Liability, default `false` otherwise.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :instant_payouts
# Whether to allow creation of standard payouts. Default `true` when Stripe owns Loss Liability, default `false` otherwise.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :standard_payouts
sig {
params(disable_stripe_user_authentication: T.nilable(T::Boolean), edit_payout_schedule: T.nilable(T::Boolean), external_account_collection: T.nilable(T::Boolean), instant_payouts: T.nilable(T::Boolean), standard_payouts: T.nilable(T::Boolean)).void
}
def initialize(
disable_stripe_user_authentication: nil,
edit_payout_schedule: nil,
external_account_collection: nil,
instant_payouts: nil,
standard_payouts: nil
); end
end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::Payouts::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSession::CreateParams::Components::Payouts::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class PayoutsList < Stripe::RequestParams
class Features < Stripe::RequestParams; end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::PayoutsList::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSession::CreateParams::Components::PayoutsList::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class ProductTaxCodeSelector < Stripe::RequestParams
class Features < Stripe::RequestParams; end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::ProductTaxCodeSelector::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSession::CreateParams::Components::ProductTaxCodeSelector::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class Recipients < Stripe::RequestParams
class Features < Stripe::RequestParams
# Whether to allow sending money.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :send_money
sig { params(send_money: T.nilable(T::Boolean)).void }
def initialize(send_money: nil); end
end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# Attribute for param field features
sig {
returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::Recipients::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSession::CreateParams::Components::Recipients::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class ReportingChart < Stripe::RequestParams
class Features < Stripe::RequestParams; end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::ReportingChart::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSession::CreateParams::Components::ReportingChart::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class TaxRegistrations < Stripe::RequestParams
class Features < Stripe::RequestParams; end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::TaxRegistrations::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSession::CreateParams::Components::TaxRegistrations::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class TaxSettings < Stripe::RequestParams
class Features < Stripe::RequestParams; end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::TaxSettings::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSession::CreateParams::Components::TaxSettings::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class TaxThresholdMonitoring < Stripe::RequestParams
class Features < Stripe::RequestParams; end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::TaxThresholdMonitoring::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSession::CreateParams::Components::TaxThresholdMonitoring::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
# Configuration for the account management embedded component.
sig {
returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::AccountManagement))
}
attr_accessor :account_management
# Configuration for the account onboarding embedded component.
sig {
returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::AccountOnboarding))
}
attr_accessor :account_onboarding
# Configuration for the app install component.
sig { returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::AppInstall)) }
attr_accessor :app_install
# Configuration for the app viewport component.
sig { returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::AppViewport)) }
attr_accessor :app_viewport
# Configuration for the balances embedded component.
sig { returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::Balances)) }
attr_accessor :balances
# Configuration for the capital financing embedded component.
sig {
returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::CapitalFinancing))
}
attr_accessor :capital_financing
# Configuration for the capital financing application embedded component.
sig {
returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::CapitalFinancingApplication))
}
attr_accessor :capital_financing_application
# Configuration for the capital financing promotion embedded component.
sig {
returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::CapitalFinancingPromotion))
}
attr_accessor :capital_financing_promotion
# Configuration for the capital overview embedded component.
sig {
returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::CapitalOverview))
}
attr_accessor :capital_overview
# Configuration for the disputes list embedded component.
sig { returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::DisputesList)) }
attr_accessor :disputes_list
# Configuration for the documents embedded component.
sig { returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::Documents)) }
attr_accessor :documents
# Configuration for the export tax transactions embedded component.
sig {
returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::ExportTaxTransactions))
}
attr_accessor :export_tax_transactions
# Configuration for the financial account embedded component.
sig {
returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::FinancialAccount))
}
attr_accessor :financial_account
# Configuration for the financial account transactions embedded component.
sig {
returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::FinancialAccountTransactions))
}
attr_accessor :financial_account_transactions
# Configuration for the issuing card embedded component.
sig { returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::IssuingCard)) }
attr_accessor :issuing_card
# Configuration for the issuing cards list embedded component.
sig {
returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::IssuingCardsList))
}
attr_accessor :issuing_cards_list
# Configuration for the notification banner embedded component.
sig {
returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::NotificationBanner))
}
attr_accessor :notification_banner
# Configuration for the payment details embedded component.
sig {
returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::PaymentDetails))
}
attr_accessor :payment_details
# Configuration for the payment disputes embedded component.
sig {
returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::PaymentDisputes))
}
attr_accessor :payment_disputes
# Configuration for the payment method settings embedded component.
sig {
returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::PaymentMethodSettings))
}
attr_accessor :payment_method_settings
# Configuration for the payments embedded component.
sig { returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::Payments)) }
attr_accessor :payments
# Configuration for the payouts embedded component.
sig { returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::Payouts)) }
attr_accessor :payouts
# Configuration for the payouts list embedded component.
sig { returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::PayoutsList)) }
attr_accessor :payouts_list
# Configuration for the product tax code selector embedded component.
sig {
returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::ProductTaxCodeSelector))
}
attr_accessor :product_tax_code_selector
# Configuration for the recipients component.
sig { returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::Recipients)) }
attr_accessor :recipients
# Configuration for the reporting chart embedded component.
sig {
returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::ReportingChart))
}
attr_accessor :reporting_chart
# Configuration for the tax registrations embedded component.
sig {
returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::TaxRegistrations))
}
attr_accessor :tax_registrations
# Configuration for the tax settings embedded component.
sig { returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::TaxSettings)) }
attr_accessor :tax_settings
# Configuration for the tax threshold monitoring embedded component.
sig {
returns(T.nilable(::Stripe::AccountSession::CreateParams::Components::TaxThresholdMonitoring))
}
attr_accessor :tax_threshold_monitoring
sig {
params(account_management: T.nilable(::Stripe::AccountSession::CreateParams::Components::AccountManagement), account_onboarding: T.nilable(::Stripe::AccountSession::CreateParams::Components::AccountOnboarding), app_install: T.nilable(::Stripe::AccountSession::CreateParams::Components::AppInstall), app_viewport: T.nilable(::Stripe::AccountSession::CreateParams::Components::AppViewport), balances: T.nilable(::Stripe::AccountSession::CreateParams::Components::Balances), capital_financing: T.nilable(::Stripe::AccountSession::CreateParams::Components::CapitalFinancing), capital_financing_application: T.nilable(::Stripe::AccountSession::CreateParams::Components::CapitalFinancingApplication), capital_financing_promotion: T.nilable(::Stripe::AccountSession::CreateParams::Components::CapitalFinancingPromotion), capital_overview: T.nilable(::Stripe::AccountSession::CreateParams::Components::CapitalOverview), disputes_list: T.nilable(::Stripe::AccountSession::CreateParams::Components::DisputesList), documents: T.nilable(::Stripe::AccountSession::CreateParams::Components::Documents), export_tax_transactions: T.nilable(::Stripe::AccountSession::CreateParams::Components::ExportTaxTransactions), financial_account: T.nilable(::Stripe::AccountSession::CreateParams::Components::FinancialAccount), financial_account_transactions: T.nilable(::Stripe::AccountSession::CreateParams::Components::FinancialAccountTransactions), issuing_card: T.nilable(::Stripe::AccountSession::CreateParams::Components::IssuingCard), issuing_cards_list: T.nilable(::Stripe::AccountSession::CreateParams::Components::IssuingCardsList), notification_banner: T.nilable(::Stripe::AccountSession::CreateParams::Components::NotificationBanner), payment_details: T.nilable(::Stripe::AccountSession::CreateParams::Components::PaymentDetails), payment_disputes: T.nilable(::Stripe::AccountSession::CreateParams::Components::PaymentDisputes), payment_method_settings: T.nilable(::Stripe::AccountSession::CreateParams::Components::PaymentMethodSettings), payments: T.nilable(::Stripe::AccountSession::CreateParams::Components::Payments), payouts: T.nilable(::Stripe::AccountSession::CreateParams::Components::Payouts), payouts_list: T.nilable(::Stripe::AccountSession::CreateParams::Components::PayoutsList), product_tax_code_selector: T.nilable(::Stripe::AccountSession::CreateParams::Components::ProductTaxCodeSelector), recipients: T.nilable(::Stripe::AccountSession::CreateParams::Components::Recipients), reporting_chart: T.nilable(::Stripe::AccountSession::CreateParams::Components::ReportingChart), tax_registrations: T.nilable(::Stripe::AccountSession::CreateParams::Components::TaxRegistrations), tax_settings: T.nilable(::Stripe::AccountSession::CreateParams::Components::TaxSettings), tax_threshold_monitoring: T.nilable(::Stripe::AccountSession::CreateParams::Components::TaxThresholdMonitoring)).void
}
def initialize(
account_management: nil,
account_onboarding: nil,
app_install: nil,
app_viewport: nil,
balances: nil,
capital_financing: nil,
capital_financing_application: nil,
capital_financing_promotion: nil,
capital_overview: nil,
disputes_list: nil,
documents: nil,
export_tax_transactions: nil,
financial_account: nil,
financial_account_transactions: nil,
issuing_card: nil,
issuing_cards_list: nil,
notification_banner: nil,
payment_details: nil,
payment_disputes: nil,
payment_method_settings: nil,
payments: nil,
payouts: nil,
payouts_list: nil,
product_tax_code_selector: nil,
recipients: nil,
reporting_chart: nil,
tax_registrations: nil,
tax_settings: nil,
tax_threshold_monitoring: nil
); end
end
# The identifier of the account to create an Account Session for.
sig { returns(String) }
attr_accessor :account
# Each key of the dictionary represents an embedded component, and each embedded component maps to its configuration (e.g. whether it has been enabled or not).
sig { returns(::Stripe::AccountSession::CreateParams::Components) }
attr_accessor :components
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig {
params(account: String, components: ::Stripe::AccountSession::CreateParams::Components, expand: T.nilable(T::Array[String])).void
}
def initialize(account: nil, components: nil, expand: nil); end
end
# Creates a AccountSession object that includes a single-use token that the platform can use on their front-end to grant client-side API access.
sig {
params(params: T.any(::Stripe::AccountSession::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::AccountSession)
}
def self.create(params = {}, opts = {}); end
end
end
# typed: true
module Stripe
# Domains registered for Apple Pay on the Web
class ApplePayDomain < APIResource
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# Attribute for field domain_name
sig { returns(String) }
attr_reader :domain_name
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Always true for a deleted object
sig { returns(T::Boolean) }
attr_reader :deleted
class DeleteParams < Stripe::RequestParams; end
class ListParams < Stripe::RequestParams
# Attribute for param field domain_name
sig { returns(T.nilable(String)) }
attr_accessor :domain_name
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(domain_name: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
domain_name: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
# Attribute for param field domain_name
sig { returns(String) }
attr_accessor :domain_name
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(domain_name: String, expand: T.nilable(T::Array[String])).void }
def initialize(domain_name: nil, expand: nil); end
end
# Create an apple pay domain.
sig {
params(params: T.any(::Stripe::ApplePayDomain::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ApplePayDomain)
}
def self.create(params = {}, opts = {}); end
# Delete an apple pay domain.
sig {
params(domain: String, params: T.any(::Stripe::ApplePayDomain::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ApplePayDomain)
}
def self.delete(domain, params = {}, opts = {}); end
# Delete an apple pay domain.
sig {
params(params: T.any(::Stripe::ApplePayDomain::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ApplePayDomain)
}
def delete(params = {}, opts = {}); end
# List apple pay domains.
sig {
params(params: T.any(::Stripe::ApplePayDomain::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class Application < APIResource
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# The name of the application.
sig { returns(T.nilable(String)) }
attr_reader :name
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Always true for a deleted object
sig { returns(T::Boolean) }
attr_reader :deleted
end
end
# typed: true
module Stripe
class ApplicationFee < APIResource
class FeeSource < Stripe::StripeObject
# Charge ID that created this application fee.
sig { returns(String) }
attr_reader :charge
# Payout ID that created this application fee.
sig { returns(String) }
attr_reader :payout
# Type of object that created the application fee.
sig { returns(String) }
attr_reader :type
end
# ID of the Stripe account this fee was taken from.
sig { returns(T.any(String, Stripe::Account)) }
attr_reader :account
# Amount earned, in cents (or local equivalent).
sig { returns(Integer) }
attr_reader :amount
# Amount in cents (or local equivalent) refunded (can be less than the amount attribute on the fee if a partial refund was issued)
sig { returns(Integer) }
attr_reader :amount_refunded
# ID of the Connect application that earned the fee.
sig { returns(T.any(String, Stripe::Application)) }
attr_reader :application
# Balance transaction that describes the impact of this collected application fee on your account balance (not including refunds).
sig { returns(T.nilable(T.any(String, Stripe::BalanceTransaction))) }
attr_reader :balance_transaction
# ID of the charge that the application fee was taken from.
sig { returns(T.any(String, Stripe::Charge)) }
attr_reader :charge
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# 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).
sig { returns(String) }
attr_reader :currency
# Polymorphic source of the application fee. Includes the ID of the object the application fee was created from.
sig { returns(T.nilable(FeeSource)) }
attr_reader :fee_source
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# ID of the corresponding charge on the platform account, if this fee was the result of a charge using the `destination` parameter.
sig { returns(T.nilable(T.any(String, Stripe::Charge))) }
attr_reader :originating_transaction
# Whether the fee has been fully refunded. If the fee is only partially refunded, this attribute will still be false.
sig { returns(T::Boolean) }
attr_reader :refunded
# A list of refunds that have been applied to the fee.
sig { returns(Stripe::ListObject) }
attr_reader :refunds
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return application fees for the charge specified by this charge ID.
sig { returns(T.nilable(String)) }
attr_accessor :charge
# Only return applications fees that were created during the given date interval.
sig { returns(T.nilable(T.any(::Stripe::ApplicationFee::ListParams::Created, Integer))) }
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(charge: T.nilable(String), created: T.nilable(T.any(::Stripe::ApplicationFee::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
charge: nil,
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil
); end
end
# Returns a list of application fees you've previously collected. The application fees are returned in sorted order, with the most recent fees appearing first.
sig {
params(params: T.any(::Stripe::ApplicationFee::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
end
end
# typed: true
module Stripe
module Apps
# Secret Store is an API that allows Stripe Apps developers to securely persist secrets for use by UI Extensions and app backends.
#
# The primary resource in Secret Store is a `secret`. Other apps can't view secrets created by an app. Additionally, secrets are scoped to provide further permission control.
#
# All Dashboard users and the app backend share `account` scoped secrets. Use the `account` scope for secrets that don't change per-user, like a third-party API key.
#
# A `user` scoped secret is accessible by the app backend and one specific Dashboard user. Use the `user` scope for per-user secrets like per-user OAuth tokens, where different users might have different permissions.
#
# Related guide: [Store data between page reloads](https://stripe.com/docs/stripe-apps/store-auth-data-custom-objects)
class Secret < APIResource
class Scope < Stripe::StripeObject
# The secret scope type.
sig { returns(String) }
attr_reader :type
# The user ID, if type is set to "user"
sig { returns(String) }
attr_reader :user
end
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# If true, indicates that this secret has been deleted
sig { returns(T::Boolean) }
attr_reader :deleted
# The Unix timestamp for the expiry time of the secret, after which the secret deletes.
sig { returns(T.nilable(Integer)) }
attr_reader :expires_at
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# A name for the secret that's unique within the scope.
sig { returns(String) }
attr_reader :name
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The plaintext secret value to be stored.
sig { returns(T.nilable(String)) }
attr_reader :payload
# Attribute for field scope
sig { returns(Scope) }
attr_reader :scope
class ListParams < Stripe::RequestParams
class Scope < Stripe::RequestParams
# The secret scope type.
sig { returns(String) }
attr_accessor :type
# The user ID. This field is required if `type` is set to `user`, and should not be provided if `type` is set to `account`.
sig { returns(T.nilable(String)) }
attr_accessor :user
sig { params(type: String, user: T.nilable(String)).void }
def initialize(type: nil, user: nil); end
end
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Specifies the scoping of the secret. Requests originating from UI extensions can only access account-scoped secrets or secrets scoped to their own user.
sig { returns(::Stripe::Apps::Secret::ListParams::Scope) }
attr_accessor :scope
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), scope: ::Stripe::Apps::Secret::ListParams::Scope, starting_after: T.nilable(String)).void
}
def initialize(
ending_before: nil,
expand: nil,
limit: nil,
scope: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class Scope < Stripe::RequestParams
# The secret scope type.
sig { returns(String) }
attr_accessor :type
# The user ID. This field is required if `type` is set to `user`, and should not be provided if `type` is set to `account`.
sig { returns(T.nilable(String)) }
attr_accessor :user
sig { params(type: String, user: T.nilable(String)).void }
def initialize(type: nil, user: nil); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The Unix timestamp for the expiry time of the secret, after which the secret deletes.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_at
# A name for the secret that's unique within the scope.
sig { returns(String) }
attr_accessor :name
# The plaintext secret value to be stored.
sig { returns(String) }
attr_accessor :payload
# Specifies the scoping of the secret. Requests originating from UI extensions can only access account-scoped secrets or secrets scoped to their own user.
sig { returns(::Stripe::Apps::Secret::CreateParams::Scope) }
attr_accessor :scope
sig {
params(expand: T.nilable(T::Array[String]), expires_at: T.nilable(Integer), name: String, payload: String, scope: ::Stripe::Apps::Secret::CreateParams::Scope).void
}
def initialize(expand: nil, expires_at: nil, name: nil, payload: nil, scope: nil); end
end
class FindParams < Stripe::RequestParams
class Scope < Stripe::RequestParams
# The secret scope type.
sig { returns(String) }
attr_accessor :type
# The user ID. This field is required if `type` is set to `user`, and should not be provided if `type` is set to `account`.
sig { returns(T.nilable(String)) }
attr_accessor :user
sig { params(type: String, user: T.nilable(String)).void }
def initialize(type: nil, user: nil); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A name for the secret that's unique within the scope.
sig { returns(String) }
attr_accessor :name
# Specifies the scoping of the secret. Requests originating from UI extensions can only access account-scoped secrets or secrets scoped to their own user.
sig { returns(::Stripe::Apps::Secret::FindParams::Scope) }
attr_accessor :scope
sig {
params(expand: T.nilable(T::Array[String]), name: String, scope: ::Stripe::Apps::Secret::FindParams::Scope).void
}
def initialize(expand: nil, name: nil, scope: nil); end
end
class DeleteWhereParams < Stripe::RequestParams
class Scope < Stripe::RequestParams
# The secret scope type.
sig { returns(String) }
attr_accessor :type
# The user ID. This field is required if `type` is set to `user`, and should not be provided if `type` is set to `account`.
sig { returns(T.nilable(String)) }
attr_accessor :user
sig { params(type: String, user: T.nilable(String)).void }
def initialize(type: nil, user: nil); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A name for the secret that's unique within the scope.
sig { returns(String) }
attr_accessor :name
# Specifies the scoping of the secret. Requests originating from UI extensions can only access account-scoped secrets or secrets scoped to their own user.
sig { returns(::Stripe::Apps::Secret::DeleteWhereParams::Scope) }
attr_accessor :scope
sig {
params(expand: T.nilable(T::Array[String]), name: String, scope: ::Stripe::Apps::Secret::DeleteWhereParams::Scope).void
}
def initialize(expand: nil, name: nil, scope: nil); end
end
# Create or replace a secret in the secret store.
sig {
params(params: T.any(::Stripe::Apps::Secret::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Apps::Secret)
}
def self.create(params = {}, opts = {}); end
# Deletes a secret from the secret store by name and scope.
sig {
params(params: T.any(::Stripe::Apps::Secret::DeleteWhereParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Apps::Secret)
}
def self.delete_where(params = {}, opts = {}); end
# Finds a secret in the secret store by name and scope.
sig {
params(params: T.any(::Stripe::Apps::Secret::FindParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Apps::Secret)
}
def self.find(params = {}, opts = {}); end
# List all secrets stored on the given scope.
sig {
params(params: T.any(::Stripe::Apps::Secret::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
# This is an object representing your Stripe balance. You can retrieve it to see
# the balance currently on your Stripe account.
#
# You can also retrieve the balance history, which contains a list of
# [transactions](https://stripe.com/docs/reporting/balance-transaction-types) that contributed to the balance
# (charges, payouts, and so forth).
#
# The available and pending amounts for each currency are broken down further by
# payment source types.
#
# Related guide: [Understanding Connect account balances](https://stripe.com/docs/connect/account-balances)
class Balance < SingletonAPIResource
class Available < Stripe::StripeObject
class SourceTypes < Stripe::StripeObject
# Amount coming from [legacy US ACH payments](https://docs.stripe.com/ach-deprecated).
sig { returns(Integer) }
attr_reader :bank_account
# Amount coming from most payment methods, including cards as well as [non-legacy bank debits](https://docs.stripe.com/payments/bank-debits).
sig { returns(Integer) }
attr_reader :card
# Amount coming from [FPX](https://docs.stripe.com/payments/fpx), a Malaysian payment method.
sig { returns(Integer) }
attr_reader :fpx
end
# Balance amount.
sig { returns(Integer) }
attr_reader :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).
sig { returns(String) }
attr_reader :currency
# Attribute for field source_types
sig { returns(SourceTypes) }
attr_reader :source_types
end
class ConnectReserved < Stripe::StripeObject
class SourceTypes < Stripe::StripeObject
# Amount coming from [legacy US ACH payments](https://docs.stripe.com/ach-deprecated).
sig { returns(Integer) }
attr_reader :bank_account
# Amount coming from most payment methods, including cards as well as [non-legacy bank debits](https://docs.stripe.com/payments/bank-debits).
sig { returns(Integer) }
attr_reader :card
# Amount coming from [FPX](https://docs.stripe.com/payments/fpx), a Malaysian payment method.
sig { returns(Integer) }
attr_reader :fpx
end
# Balance amount.
sig { returns(Integer) }
attr_reader :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).
sig { returns(String) }
attr_reader :currency
# Attribute for field source_types
sig { returns(SourceTypes) }
attr_reader :source_types
end
class InstantAvailable < Stripe::StripeObject
class NetAvailable < Stripe::StripeObject
class SourceTypes < Stripe::StripeObject
# Amount coming from [legacy US ACH payments](https://docs.stripe.com/ach-deprecated).
sig { returns(Integer) }
attr_reader :bank_account
# Amount coming from most payment methods, including cards as well as [non-legacy bank debits](https://docs.stripe.com/payments/bank-debits).
sig { returns(Integer) }
attr_reader :card
# Amount coming from [FPX](https://docs.stripe.com/payments/fpx), a Malaysian payment method.
sig { returns(Integer) }
attr_reader :fpx
end
# Net balance amount, subtracting fees from platform-set pricing.
sig { returns(Integer) }
attr_reader :amount
# ID of the external account for this net balance (not expandable).
sig { returns(String) }
attr_reader :destination
# Attribute for field source_types
sig { returns(SourceTypes) }
attr_reader :source_types
end
class SourceTypes < Stripe::StripeObject
# Amount coming from [legacy US ACH payments](https://docs.stripe.com/ach-deprecated).
sig { returns(Integer) }
attr_reader :bank_account
# Amount coming from most payment methods, including cards as well as [non-legacy bank debits](https://docs.stripe.com/payments/bank-debits).
sig { returns(Integer) }
attr_reader :card
# Amount coming from [FPX](https://docs.stripe.com/payments/fpx), a Malaysian payment method.
sig { returns(Integer) }
attr_reader :fpx
end
# Balance amount.
sig { returns(Integer) }
attr_reader :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).
sig { returns(String) }
attr_reader :currency
# Breakdown of balance by destination.
sig { returns(T::Array[NetAvailable]) }
attr_reader :net_available
# Attribute for field source_types
sig { returns(SourceTypes) }
attr_reader :source_types
end
class Issuing < Stripe::StripeObject
class Available < Stripe::StripeObject
class SourceTypes < Stripe::StripeObject
# Amount coming from [legacy US ACH payments](https://docs.stripe.com/ach-deprecated).
sig { returns(Integer) }
attr_reader :bank_account
# Amount coming from most payment methods, including cards as well as [non-legacy bank debits](https://docs.stripe.com/payments/bank-debits).
sig { returns(Integer) }
attr_reader :card
# Amount coming from [FPX](https://docs.stripe.com/payments/fpx), a Malaysian payment method.
sig { returns(Integer) }
attr_reader :fpx
end
# Balance amount.
sig { returns(Integer) }
attr_reader :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).
sig { returns(String) }
attr_reader :currency
# Attribute for field source_types
sig { returns(SourceTypes) }
attr_reader :source_types
end
# Funds that are available for use.
sig { returns(T::Array[Available]) }
attr_reader :available
end
class Pending < Stripe::StripeObject
class SourceTypes < Stripe::StripeObject
# Amount coming from [legacy US ACH payments](https://docs.stripe.com/ach-deprecated).
sig { returns(Integer) }
attr_reader :bank_account
# Amount coming from most payment methods, including cards as well as [non-legacy bank debits](https://docs.stripe.com/payments/bank-debits).
sig { returns(Integer) }
attr_reader :card
# Amount coming from [FPX](https://docs.stripe.com/payments/fpx), a Malaysian payment method.
sig { returns(Integer) }
attr_reader :fpx
end
# Balance amount.
sig { returns(Integer) }
attr_reader :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).
sig { returns(String) }
attr_reader :currency
# Attribute for field source_types
sig { returns(SourceTypes) }
attr_reader :source_types
end
class RefundAndDisputePrefunding < Stripe::StripeObject
class Available < Stripe::StripeObject
class SourceTypes < Stripe::StripeObject
# Amount coming from [legacy US ACH payments](https://docs.stripe.com/ach-deprecated).
sig { returns(Integer) }
attr_reader :bank_account
# Amount coming from most payment methods, including cards as well as [non-legacy bank debits](https://docs.stripe.com/payments/bank-debits).
sig { returns(Integer) }
attr_reader :card
# Amount coming from [FPX](https://docs.stripe.com/payments/fpx), a Malaysian payment method.
sig { returns(Integer) }
attr_reader :fpx
end
# Balance amount.
sig { returns(Integer) }
attr_reader :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).
sig { returns(String) }
attr_reader :currency
# Attribute for field source_types
sig { returns(SourceTypes) }
attr_reader :source_types
end
class Pending < Stripe::StripeObject
class SourceTypes < Stripe::StripeObject
# Amount coming from [legacy US ACH payments](https://docs.stripe.com/ach-deprecated).
sig { returns(Integer) }
attr_reader :bank_account
# Amount coming from most payment methods, including cards as well as [non-legacy bank debits](https://docs.stripe.com/payments/bank-debits).
sig { returns(Integer) }
attr_reader :card
# Amount coming from [FPX](https://docs.stripe.com/payments/fpx), a Malaysian payment method.
sig { returns(Integer) }
attr_reader :fpx
end
# Balance amount.
sig { returns(Integer) }
attr_reader :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).
sig { returns(String) }
attr_reader :currency
# Attribute for field source_types
sig { returns(SourceTypes) }
attr_reader :source_types
end
# Funds that are available for use.
sig { returns(T::Array[Available]) }
attr_reader :available
# Funds that are pending
sig { returns(T::Array[Pending]) }
attr_reader :pending
end
# Available funds that you can transfer or pay out automatically by Stripe or explicitly through the [Transfers API](https://stripe.com/docs/api#transfers) or [Payouts API](https://stripe.com/docs/api#payouts). You can find the available balance for each currency and payment type in the `source_types` property.
sig { returns(T::Array[Available]) }
attr_reader :available
# Funds held due to negative balances on connected accounts where [account.controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts. You can find the connect reserve balance for each currency and payment type in the `source_types` property.
sig { returns(T::Array[ConnectReserved]) }
attr_reader :connect_reserved
# Funds that you can pay out using Instant Payouts.
sig { returns(T::Array[InstantAvailable]) }
attr_reader :instant_available
# Attribute for field issuing
sig { returns(Issuing) }
attr_reader :issuing
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Funds that aren't available in the balance yet. You can find the pending balance for each currency and each payment type in the `source_types` property.
sig { returns(T::Array[Pending]) }
attr_reader :pending
# Attribute for field refund_and_dispute_prefunding
sig { returns(RefundAndDisputePrefunding) }
attr_reader :refund_and_dispute_prefunding
end
end
# typed: true
module Stripe
# Options for customizing account balances and payout settings for a Stripe platform's connected accounts.
#
# This API is only available for users enrolled in the public preview for Accounts v2 on Stripe Connect.
# If you are not in this preview, please use the [Accounts v1 API](https://docs.stripe.com/api/accounts?api-version=2025-03-31.basil)
# to manage your connected accounts' balance settings instead.
class BalanceSettings < SingletonAPIResource
class Payouts < Stripe::StripeObject
class Schedule < Stripe::StripeObject
# How frequently funds will be paid out. One of `manual` (payouts only created via API call), `daily`, `weekly`, or `monthly`.
sig { returns(T.nilable(String)) }
attr_reader :interval
# The day of the month funds will be paid out. Only shown if `interval` is monthly. Payouts scheduled between the 29th and 31st of the month are sent on the last day of shorter months.
sig { returns(Integer) }
attr_reader :monthly_anchor
# The day of the week funds will be paid out, of the style 'monday', 'tuesday', etc. Only shown if `interval` is weekly.
sig { returns(String) }
attr_reader :weekly_anchor
end
# Details on when funds from charges are available, and when they are paid out to an external account. See our [Setting Bank and Debit Card Payouts](https://stripe.com/docs/connect/bank-transfers#payout-information) documentation for details.
sig { returns(T.nilable(Schedule)) }
attr_reader :schedule
# The text that appears on the bank account statement for payouts. If not set, this defaults to the platform's bank descriptor as set in the Dashboard.
sig { returns(T.nilable(String)) }
attr_reader :statement_descriptor
# Whether the funds in this account can be paid out.
sig { returns(String) }
attr_reader :status
end
class SettlementTiming < Stripe::StripeObject
# The number of days charge funds are held before becoming available.
sig { returns(Integer) }
attr_reader :delay_days
end
# A Boolean indicating if Stripe should try to reclaim negative balances from an attached bank account. See [Understanding Connect account balances](/connect/account-balances) for details. The default value is `false` when [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts, otherwise `true`.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :debit_negative_balances
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Settings specific to the account's payouts.
sig { returns(T.nilable(Payouts)) }
attr_reader :payouts
# Attribute for field settlement_timing
sig { returns(SettlementTiming) }
attr_reader :settlement_timing
class UpdateParams < Stripe::RequestParams
class Payouts < Stripe::RequestParams
class Schedule < Stripe::RequestParams
# How frequently available funds are paid out. One of: `daily`, `manual`, `weekly`, or `monthly`. Default is `daily`.
sig { returns(T.nilable(String)) }
attr_accessor :interval
# The day of the month when available funds are paid out, specified as a number between 1--31. Payouts nominally scheduled between the 29th and 31st of the month are instead sent on the last day of a shorter month. Required and applicable only if `interval` is `monthly`.
sig { returns(T.nilable(Integer)) }
attr_accessor :monthly_anchor
# The day of the week when available funds are paid out (required and applicable only if `interval` is `weekly`.)
sig { returns(T.nilable(String)) }
attr_accessor :weekly_anchor
sig {
params(interval: T.nilable(String), monthly_anchor: T.nilable(Integer), weekly_anchor: T.nilable(String)).void
}
def initialize(interval: nil, monthly_anchor: nil, weekly_anchor: nil); end
end
# Details on when funds from charges are available, and when they are paid out to an external account. For details, see our [Setting Bank and Debit Card Payouts](/connect/bank-transfers#payout-information) documentation.
sig { returns(T.nilable(::Stripe::BalanceSettings::UpdateParams::Payouts::Schedule)) }
attr_accessor :schedule
# The text that appears on the bank account statement for payouts. If not set, this defaults to the platform's bank descriptor as set in the Dashboard.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
sig {
params(schedule: T.nilable(::Stripe::BalanceSettings::UpdateParams::Payouts::Schedule), statement_descriptor: T.nilable(String)).void
}
def initialize(schedule: nil, statement_descriptor: nil); end
end
class SettlementTiming < Stripe::RequestParams
# The number of days charge funds are held before becoming available. May also be set to `minimum`, representing the lowest available value for the account country. Default is `minimum`. The `delay_days` parameter remains at the last configured value if `payouts.schedule.interval` is `manual`. [Learn more about controlling payout delay days](/connect/manage-payout-schedule).
sig { returns(T.nilable(Integer)) }
attr_accessor :delay_days
sig { params(delay_days: T.nilable(Integer)).void }
def initialize(delay_days: nil); end
end
# A Boolean indicating whether Stripe should try to reclaim negative balances from an attached bank account. For details, see [Understanding Connect Account Balances](/connect/account-balances).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :debit_negative_balances
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Settings specific to the account's payouts.
sig { returns(T.nilable(::Stripe::BalanceSettings::UpdateParams::Payouts)) }
attr_accessor :payouts
# Settings related to the account's balance settlement timing.
sig { returns(T.nilable(::Stripe::BalanceSettings::UpdateParams::SettlementTiming)) }
attr_accessor :settlement_timing
sig {
params(debit_negative_balances: T.nilable(T::Boolean), expand: T.nilable(T::Array[String]), payouts: T.nilable(::Stripe::BalanceSettings::UpdateParams::Payouts), settlement_timing: T.nilable(::Stripe::BalanceSettings::UpdateParams::SettlementTiming)).void
}
def initialize(
debit_negative_balances: nil,
expand: nil,
payouts: nil,
settlement_timing: nil
); end
end
end
end
# typed: true
module Stripe
# Balance transactions represent funds moving through your Stripe account.
# Stripe creates them for every type of transaction that enters or leaves your Stripe account balance.
#
# Related guide: [Balance transaction types](https://stripe.com/docs/reports/balance-transaction-types)
class BalanceTransaction < APIResource
class FeeDetail < Stripe::StripeObject
# Amount of the fee, in cents.
sig { returns(Integer) }
attr_reader :amount
# ID of the Connect application that earned the fee.
sig { returns(T.nilable(String)) }
attr_reader :application
# 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).
sig { returns(String) }
attr_reader :currency
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_reader :description
# Type of the fee, one of: `application_fee`, `payment_method_passthrough_fee`, `stripe_fee` or `tax`.
sig { returns(String) }
attr_reader :type
end
# Gross amount of this transaction (in cents (or local equivalent)). A positive value represents funds charged to another party, and a negative value represents funds sent to another party.
sig { returns(Integer) }
attr_reader :amount
# The date that the transaction's net funds become available in the Stripe balance.
sig { returns(Integer) }
attr_reader :available_on
# The balance that this transaction impacts.
sig { returns(String) }
attr_reader :balance_type
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# 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).
sig { returns(String) }
attr_reader :currency
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_reader :description
# If applicable, this transaction uses an exchange rate. If money converts from currency A to currency B, then the `amount` in currency A, multipled by the `exchange_rate`, equals the `amount` in currency B. For example, if you charge a customer 10.00 EUR, the PaymentIntent's `amount` is `1000` and `currency` is `eur`. If this converts to 12.34 USD in your Stripe account, the BalanceTransaction's `amount` is `1234`, its `currency` is `usd`, and the `exchange_rate` is `1.234`.
sig { returns(T.nilable(Float)) }
attr_reader :exchange_rate
# Fees (in cents (or local equivalent)) paid for this transaction. Represented as a positive integer when assessed.
sig { returns(Integer) }
attr_reader :fee
# Detailed breakdown of fees (in cents (or local equivalent)) paid for this transaction.
sig { returns(T::Array[FeeDetail]) }
attr_reader :fee_details
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Net impact to a Stripe balance (in cents (or local equivalent)). A positive value represents incrementing a Stripe balance, and a negative value decrementing a Stripe balance. You can calculate the net impact of a transaction on a balance by `amount` - `fee`
sig { returns(Integer) }
attr_reader :net
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Learn more about how [reporting categories](https://stripe.com/docs/reports/reporting-categories) can help you understand balance transactions from an accounting perspective.
sig { returns(String) }
attr_reader :reporting_category
# This transaction relates to the Stripe object.
sig {
returns(T.nilable(T.any(String, T.any(Stripe::ApplicationFee, Stripe::Charge, Stripe::ConnectCollectionTransfer, Stripe::CustomerCashBalanceTransaction, Stripe::Dispute, Stripe::ApplicationFeeRefund, Stripe::Issuing::Authorization, Stripe::Issuing::Dispute, Stripe::Issuing::Transaction, Stripe::Payout, Stripe::Refund, Stripe::ReserveTransaction, Stripe::TaxDeductedAtSource, Stripe::Topup, Stripe::Transfer, Stripe::Reversal))))
}
attr_reader :source
# The transaction's net funds status in the Stripe balance, which are either `available` or `pending`.
sig { returns(String) }
attr_reader :status
# Transaction type: `adjustment`, `advance`, `advance_funding`, `anticipation_repayment`, `application_fee`, `application_fee_refund`, `charge`, `climate_order_purchase`, `climate_order_refund`, `connect_collection_transfer`, `contribution`, `issuing_authorization_hold`, `issuing_authorization_release`, `issuing_dispute`, `issuing_transaction`, `obligation_outbound`, `obligation_reversal_inbound`, `payment`, `payment_failure_refund`, `payment_network_reserve_hold`, `payment_network_reserve_release`, `payment_refund`, `payment_reversal`, `payment_unreconciled`, `payout`, `payout_cancel`, `payout_failure`, `payout_minimum_balance_hold`, `payout_minimum_balance_release`, `refund`, `refund_failure`, `reserve_transaction`, `reserved_funds`, `stripe_fee`, `stripe_fx_fee`, `stripe_balance_payment_debit`, `stripe_balance_payment_debit_reversal`, `tax_fee`, `topup`, `topup_reversal`, `transfer`, `transfer_cancel`, `transfer_failure`, or `transfer_refund`. Learn more about [balance transaction types and what they represent](https://stripe.com/docs/reports/balance-transaction-types). To classify transactions for accounting purposes, consider `reporting_category` instead.
sig { returns(String) }
attr_reader :type
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return transactions that were created during the given date interval.
sig { returns(T.nilable(T.any(::Stripe::BalanceTransaction::ListParams::Created, Integer))) }
attr_accessor :created
# Only return transactions in a certain currency. 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).
sig { returns(T.nilable(String)) }
attr_accessor :currency
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# For automatic Stripe payouts only, only returns transactions that were paid out on the specified payout ID.
sig { returns(T.nilable(String)) }
attr_accessor :payout
# Only returns the original transaction.
sig { returns(T.nilable(String)) }
attr_accessor :source
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only returns transactions of the given type. One of: `adjustment`, `advance`, `advance_funding`, `anticipation_repayment`, `application_fee`, `application_fee_refund`, `charge`, `climate_order_purchase`, `climate_order_refund`, `connect_collection_transfer`, `contribution`, `issuing_authorization_hold`, `issuing_authorization_release`, `issuing_dispute`, `issuing_transaction`, `obligation_outbound`, `obligation_reversal_inbound`, `payment`, `payment_failure_refund`, `payment_network_reserve_hold`, `payment_network_reserve_release`, `payment_refund`, `payment_reversal`, `payment_unreconciled`, `payout`, `payout_cancel`, `payout_failure`, `payout_minimum_balance_hold`, `payout_minimum_balance_release`, `refund`, `refund_failure`, `reserve_transaction`, `reserved_funds`, `stripe_fee`, `stripe_fx_fee`, `stripe_balance_payment_debit`, `stripe_balance_payment_debit_reversal`, `tax_fee`, `topup`, `topup_reversal`, `transfer`, `transfer_cancel`, `transfer_failure`, or `transfer_refund`.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(created: T.nilable(T.any(::Stripe::BalanceTransaction::ListParams::Created, Integer)), currency: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), payout: T.nilable(String), source: T.nilable(String), starting_after: T.nilable(String), type: T.nilable(String)).void
}
def initialize(
created: nil,
currency: nil,
ending_before: nil,
expand: nil,
limit: nil,
payout: nil,
source: nil,
starting_after: nil,
type: nil
); end
end
# Returns a list of transactions that have contributed to the Stripe account balance (e.g., charges, transfers, and so forth). The transactions are returned in sorted order, with the most recent transactions appearing first.
#
# Note that this endpoint was previously called “Balance history” and used the path /v1/balance/history.
sig {
params(params: T.any(::Stripe::BalanceTransaction::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
end
end
# typed: true
module Stripe
# These bank accounts are payment methods on `Customer` objects.
#
# On the other hand [External Accounts](https://docs.stripe.com/api#external_accounts) are transfer
# destinations on `Account` objects for connected accounts.
# They can be bank accounts or debit cards as well, and are documented in the links above.
#
# Related guide: [Bank debits and transfers](https://docs.stripe.com/payments/bank-debits-transfers)
class BankAccount < APIResource
class FutureRequirements < Stripe::StripeObject
class Error < Stripe::StripeObject
# The code for the type of error.
sig { returns(String) }
attr_reader :code
# An informative message that indicates the error type and provides additional details about the error.
sig { returns(String) }
attr_reader :reason
# The specific user onboarding requirement field (in the requirements hash) that needs to be resolved.
sig { returns(String) }
attr_reader :requirement
end
# Fields that need to be collected to keep the external account enabled. If not collected by `current_deadline`, these fields appear in `past_due` as well, and the account is disabled.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :currently_due
# Fields that are `currently_due` and need to be collected again because validation or verification failed.
sig { returns(T.nilable(T::Array[Error])) }
attr_reader :errors
# Fields that weren't collected by `current_deadline`. These fields need to be collected to enable the external account.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :past_due
# Fields that might become required depending on the results of verification or review. It's an empty array unless an asynchronous verification is pending. If verification fails, these fields move to `eventually_due`, `currently_due`, or `past_due`. Fields might appear in `eventually_due`, `currently_due`, or `past_due` and in `pending_verification` if verification fails but another verification is still pending.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :pending_verification
end
class Requirements < Stripe::StripeObject
class Error < Stripe::StripeObject
# The code for the type of error.
sig { returns(String) }
attr_reader :code
# An informative message that indicates the error type and provides additional details about the error.
sig { returns(String) }
attr_reader :reason
# The specific user onboarding requirement field (in the requirements hash) that needs to be resolved.
sig { returns(String) }
attr_reader :requirement
end
# Fields that need to be collected to keep the external account enabled. If not collected by `current_deadline`, these fields appear in `past_due` as well, and the account is disabled.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :currently_due
# Fields that are `currently_due` and need to be collected again because validation or verification failed.
sig { returns(T.nilable(T::Array[Error])) }
attr_reader :errors
# Fields that weren't collected by `current_deadline`. These fields need to be collected to enable the external account.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :past_due
# Fields that might become required depending on the results of verification or review. It's an empty array unless an asynchronous verification is pending. If verification fails, these fields move to `eventually_due`, `currently_due`, or `past_due`. Fields might appear in `eventually_due`, `currently_due`, or `past_due` and in `pending_verification` if verification fails but another verification is still pending.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :pending_verification
end
# The account this bank account belongs to. Only applicable on Accounts (not customers or recipients) This property is only available when returned as an [External Account](/api/external_account_bank_accounts/object) where [controller.is_controller](/api/accounts/object#account_object-controller-is_controller) is `true`.
sig { returns(T.nilable(T.any(String, Stripe::Account))) }
attr_reader :account
# The name of the person or business that owns the bank account.
sig { returns(T.nilable(String)) }
attr_reader :account_holder_name
# The type of entity that holds the account. This can be either `individual` or `company`.
sig { returns(T.nilable(String)) }
attr_reader :account_holder_type
# The bank account type. This can only be `checking` or `savings` in most countries. In Japan, this can only be `futsu` or `toza`.
sig { returns(T.nilable(String)) }
attr_reader :account_type
# A set of available payout methods for this bank account. Only values from this set should be passed as the `method` when creating a payout.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :available_payout_methods
# Name of the bank associated with the routing number (e.g., `WELLS FARGO`).
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# Two-letter ISO code representing the country the bank account is located in.
sig { returns(String) }
attr_reader :country
# Three-letter [ISO code for the currency](https://stripe.com/docs/payouts) paid out to the bank account.
sig { returns(String) }
attr_reader :currency
# The ID of the customer that the bank account is associated with.
sig { returns(T.nilable(T.any(String, Stripe::Customer))) }
attr_reader :customer
# Whether this bank account is the default external account for its currency.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :default_for_currency
# Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Information about the [upcoming new requirements for the bank account](https://stripe.com/docs/connect/custom-accounts/future-requirements), including what information needs to be collected, and by when.
sig { returns(T.nilable(FutureRequirements)) }
attr_reader :future_requirements
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# The last four digits of the bank account number.
sig { returns(String) }
attr_reader :last4
# 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.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Information about the requirements for the bank account, including what information needs to be collected.
sig { returns(T.nilable(Requirements)) }
attr_reader :requirements
# The routing transit number for the bank account.
sig { returns(T.nilable(String)) }
attr_reader :routing_number
# For bank accounts, possible values are `new`, `validated`, `verified`, `verification_failed`, or `errored`. A bank account that hasn't had any activity or validation performed is `new`. If Stripe can determine that the bank account exists, its status will be `validated`. Note that there often isn’t enough information to know (e.g., for smaller credit unions), and the validation is not always run. If customer bank account verification has succeeded, the bank account status will be `verified`. If the verification failed for any reason, such as microdeposit failure, the status will be `verification_failed`. If a payout sent to this bank account fails, we'll set the status to `errored` and will not continue to send [scheduled payouts](https://stripe.com/docs/payouts#payout-schedule) until the bank details are updated.
#
# For external accounts, possible values are `new`, `errored` and `verification_failed`. If a payout fails, the status is set to `errored` and scheduled payouts are stopped until account details are updated. In the US and India, if we can't [verify the owner of the bank account](https://support.stripe.com/questions/bank-account-ownership-verification), we'll set the status to `verification_failed`. Other validations aren't run against external accounts because they're only used for payouts. This means the other statuses don't apply.
sig { returns(String) }
attr_reader :status
# Always true for a deleted object
sig { returns(T::Boolean) }
attr_reader :deleted
end
end
# typed: true
module Stripe
module Billing
# A billing alert is a resource that notifies you when a certain usage threshold on a meter is crossed. For example, you might create a billing alert to notify you when a certain user made 100 API requests.
class Alert < APIResource
class UsageThreshold < Stripe::StripeObject
class Filter < Stripe::StripeObject
# Limit the scope of the alert to this customer ID
sig { returns(T.nilable(T.any(String, Stripe::Customer))) }
attr_reader :customer
# Attribute for field type
sig { returns(String) }
attr_reader :type
end
# The filters allow limiting the scope of this usage alert. You can only specify up to one filter at this time.
sig { returns(T.nilable(T::Array[Filter])) }
attr_reader :filters
# The value at which this alert will trigger.
sig { returns(Integer) }
attr_reader :gte
# The [Billing Meter](/api/billing/meter) ID whose usage is monitored.
sig { returns(T.any(String, Stripe::Billing::Meter)) }
attr_reader :meter
# Defines how the alert will behave.
sig { returns(String) }
attr_reader :recurrence
end
# Defines the type of the alert.
sig { returns(String) }
attr_reader :alert_type
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Status of the alert. This can be active, inactive or archived.
sig { returns(T.nilable(String)) }
attr_reader :status
# Title of the alert.
sig { returns(String) }
attr_reader :title
# Encapsulates configuration of the alert to monitor usage on a specific [Billing Meter](https://stripe.com/docs/api/billing/meter).
sig { returns(T.nilable(UsageThreshold)) }
attr_reader :usage_threshold
class ListParams < Stripe::RequestParams
# Filter results to only include this type of alert.
sig { returns(T.nilable(String)) }
attr_accessor :alert_type
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Filter results to only include alerts with the given meter.
sig { returns(T.nilable(String)) }
attr_accessor :meter
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(alert_type: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), meter: T.nilable(String), starting_after: T.nilable(String)).void
}
def initialize(
alert_type: nil,
ending_before: nil,
expand: nil,
limit: nil,
meter: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class UsageThreshold < Stripe::RequestParams
class Filter < Stripe::RequestParams
# Limit the scope to this usage alert only to this customer.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# What type of filter is being applied to this usage alert.
sig { returns(String) }
attr_accessor :type
sig { params(customer: T.nilable(String), type: String).void }
def initialize(customer: nil, type: nil); end
end
# The filters allows limiting the scope of this usage alert. You can only specify up to one filter at this time.
sig {
returns(T.nilable(T::Array[::Stripe::Billing::Alert::CreateParams::UsageThreshold::Filter]))
}
attr_accessor :filters
# Defines at which value the alert will fire.
sig { returns(Integer) }
attr_accessor :gte
# The [Billing Meter](/api/billing/meter) ID whose usage is monitored.
sig { returns(String) }
attr_accessor :meter
# Whether the alert should only fire only once, or once per billing cycle.
sig { returns(String) }
attr_accessor :recurrence
sig {
params(filters: T.nilable(T::Array[::Stripe::Billing::Alert::CreateParams::UsageThreshold::Filter]), gte: Integer, meter: String, recurrence: String).void
}
def initialize(filters: nil, gte: nil, meter: nil, recurrence: nil); end
end
# The type of alert to create.
sig { returns(String) }
attr_accessor :alert_type
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The title of the alert.
sig { returns(String) }
attr_accessor :title
# The configuration of the usage threshold.
sig { returns(T.nilable(::Stripe::Billing::Alert::CreateParams::UsageThreshold)) }
attr_accessor :usage_threshold
sig {
params(alert_type: String, expand: T.nilable(T::Array[String]), title: String, usage_threshold: T.nilable(::Stripe::Billing::Alert::CreateParams::UsageThreshold)).void
}
def initialize(alert_type: nil, expand: nil, title: nil, usage_threshold: nil); end
end
class ActivateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class ArchiveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class DeactivateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Reactivates this alert, allowing it to trigger again.
sig {
params(params: T.any(::Stripe::Billing::Alert::ActivateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Billing::Alert)
}
def activate(params = {}, opts = {}); end
# Reactivates this alert, allowing it to trigger again.
sig {
params(id: String, params: T.any(::Stripe::Billing::Alert::ActivateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Billing::Alert)
}
def self.activate(id, params = {}, opts = {}); end
# Archives this alert, removing it from the list view and APIs. This is non-reversible.
sig {
params(params: T.any(::Stripe::Billing::Alert::ArchiveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Billing::Alert)
}
def archive(params = {}, opts = {}); end
# Archives this alert, removing it from the list view and APIs. This is non-reversible.
sig {
params(id: String, params: T.any(::Stripe::Billing::Alert::ArchiveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Billing::Alert)
}
def self.archive(id, params = {}, opts = {}); end
# Creates a billing alert
sig {
params(params: T.any(::Stripe::Billing::Alert::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Billing::Alert)
}
def self.create(params = {}, opts = {}); end
# Deactivates this alert, preventing it from triggering.
sig {
params(params: T.any(::Stripe::Billing::Alert::DeactivateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Billing::Alert)
}
def deactivate(params = {}, opts = {}); end
# Deactivates this alert, preventing it from triggering.
sig {
params(id: String, params: T.any(::Stripe::Billing::Alert::DeactivateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Billing::Alert)
}
def self.deactivate(id, params = {}, opts = {}); end
# Lists billing active and inactive alerts
sig {
params(params: T.any(::Stripe::Billing::Alert::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Billing
class AlertTriggered < APIResource
# A billing alert is a resource that notifies you when a certain usage threshold on a meter is crossed. For example, you might create a billing alert to notify you when a certain user made 100 API requests.
sig { returns(Stripe::Billing::Alert) }
attr_reader :alert
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# ID of customer for which the alert triggered
sig { returns(String) }
attr_reader :customer
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The value triggering the alert
sig { returns(Integer) }
attr_reader :value
end
end
end
# typed: true
module Stripe
module Billing
# Indicates the billing credit balance for billing credits granted to a customer.
class CreditBalanceSummary < SingletonAPIResource
class Balance < Stripe::StripeObject
class AvailableBalance < Stripe::StripeObject
class Monetary < Stripe::StripeObject
# 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).
sig { returns(String) }
attr_reader :currency
# A positive integer representing the amount.
sig { returns(Integer) }
attr_reader :value
end
# The monetary amount.
sig { returns(T.nilable(Monetary)) }
attr_reader :monetary
# The type of this amount. We currently only support `monetary` billing credits.
sig { returns(String) }
attr_reader :type
end
class LedgerBalance < Stripe::StripeObject
class Monetary < Stripe::StripeObject
# 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).
sig { returns(String) }
attr_reader :currency
# A positive integer representing the amount.
sig { returns(Integer) }
attr_reader :value
end
# The monetary amount.
sig { returns(T.nilable(Monetary)) }
attr_reader :monetary
# The type of this amount. We currently only support `monetary` billing credits.
sig { returns(String) }
attr_reader :type
end
# Attribute for field available_balance
sig { returns(AvailableBalance) }
attr_reader :available_balance
# Attribute for field ledger_balance
sig { returns(LedgerBalance) }
attr_reader :ledger_balance
end
# The billing credit balances. One entry per credit grant currency. If a customer only has credit grants in a single currency, then this will have a single balance entry.
sig { returns(T::Array[Balance]) }
attr_reader :balances
# The customer the balance is for.
sig { returns(T.any(String, Stripe::Customer)) }
attr_reader :customer
# The account the balance is for.
sig { returns(T.nilable(String)) }
attr_reader :customer_account
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
end
end
end
# typed: true
module Stripe
module Billing
# A credit balance transaction is a resource representing a transaction (either a credit or a debit) against an existing credit grant.
class CreditBalanceTransaction < APIResource
class Credit < Stripe::StripeObject
class Amount < Stripe::StripeObject
class Monetary < Stripe::StripeObject
# 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).
sig { returns(String) }
attr_reader :currency
# A positive integer representing the amount.
sig { returns(Integer) }
attr_reader :value
end
# The monetary amount.
sig { returns(T.nilable(Monetary)) }
attr_reader :monetary
# The type of this amount. We currently only support `monetary` billing credits.
sig { returns(String) }
attr_reader :type
end
class CreditsApplicationInvoiceVoided < Stripe::StripeObject
# The invoice to which the reinstated billing credits were originally applied.
sig { returns(T.any(String, Stripe::Invoice)) }
attr_reader :invoice
# The invoice line item to which the reinstated billing credits were originally applied.
sig { returns(String) }
attr_reader :invoice_line_item
end
# Attribute for field amount
sig { returns(Amount) }
attr_reader :amount
# Details of the invoice to which the reinstated credits were originally applied. Only present if `type` is `credits_application_invoice_voided`.
sig { returns(T.nilable(CreditsApplicationInvoiceVoided)) }
attr_reader :credits_application_invoice_voided
# The type of credit transaction.
sig { returns(String) }
attr_reader :type
end
class Debit < Stripe::StripeObject
class Amount < Stripe::StripeObject
class Monetary < Stripe::StripeObject
# 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).
sig { returns(String) }
attr_reader :currency
# A positive integer representing the amount.
sig { returns(Integer) }
attr_reader :value
end
# The monetary amount.
sig { returns(T.nilable(Monetary)) }
attr_reader :monetary
# The type of this amount. We currently only support `monetary` billing credits.
sig { returns(String) }
attr_reader :type
end
class CreditsApplied < Stripe::StripeObject
# The invoice to which the billing credits were applied.
sig { returns(T.any(String, Stripe::Invoice)) }
attr_reader :invoice
# The invoice line item to which the billing credits were applied.
sig { returns(String) }
attr_reader :invoice_line_item
end
# Attribute for field amount
sig { returns(Amount) }
attr_reader :amount
# Details of how the billing credits were applied to an invoice. Only present if `type` is `credits_applied`.
sig { returns(T.nilable(CreditsApplied)) }
attr_reader :credits_applied
# The type of debit transaction.
sig { returns(String) }
attr_reader :type
end
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# Credit details for this credit balance transaction. Only present if type is `credit`.
sig { returns(T.nilable(Credit)) }
attr_reader :credit
# The credit grant associated with this credit balance transaction.
sig { returns(T.any(String, Stripe::Billing::CreditGrant)) }
attr_reader :credit_grant
# Debit details for this credit balance transaction. Only present if type is `debit`.
sig { returns(T.nilable(Debit)) }
attr_reader :debit
# The effective time of this credit balance transaction.
sig { returns(Integer) }
attr_reader :effective_at
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# ID of the test clock this credit balance transaction belongs to.
sig { returns(T.nilable(T.any(String, Stripe::TestHelpers::TestClock))) }
attr_reader :test_clock
# The type of credit balance transaction (credit or debit).
sig { returns(T.nilable(String)) }
attr_reader :type
class ListParams < Stripe::RequestParams
# The credit grant for which to fetch credit balance transactions.
sig { returns(T.nilable(String)) }
attr_accessor :credit_grant
# The customer for which to fetch credit balance transactions.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# The account for which to fetch credit balance transactions.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(credit_grant: T.nilable(String), customer: T.nilable(String), customer_account: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
credit_grant: nil,
customer: nil,
customer_account: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil
); end
end
# Retrieve a list of credit balance transactions.
sig {
params(params: T.any(::Stripe::Billing::CreditBalanceTransaction::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Billing
# A credit grant is an API resource that documents the allocation of some billing credits to a customer.
#
# Related guide: [Billing credits](https://docs.stripe.com/billing/subscriptions/usage-based/billing-credits)
class CreditGrant < APIResource
class Amount < Stripe::StripeObject
class Monetary < Stripe::StripeObject
# 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).
sig { returns(String) }
attr_reader :currency
# A positive integer representing the amount.
sig { returns(Integer) }
attr_reader :value
end
# The monetary amount.
sig { returns(T.nilable(Monetary)) }
attr_reader :monetary
# The type of this amount. We currently only support `monetary` billing credits.
sig { returns(String) }
attr_reader :type
end
class ApplicabilityConfig < Stripe::StripeObject
class Scope < Stripe::StripeObject
class Price < Stripe::StripeObject
# Unique identifier for the object.
sig { returns(T.nilable(String)) }
attr_reader :id
end
# The price type that credit grants can apply to. We currently only support the `metered` price type. This refers to prices that have a [Billing Meter](https://docs.stripe.com/api/billing/meter) attached to them. Cannot be used in combination with `prices`.
sig { returns(String) }
attr_reader :price_type
# The prices that credit grants can apply to. We currently only support `metered` prices. This refers to prices that have a [Billing Meter](https://docs.stripe.com/api/billing/meter) attached to them. Cannot be used in combination with `price_type`.
sig { returns(T::Array[Price]) }
attr_reader :prices
end
# Attribute for field scope
sig { returns(Scope) }
attr_reader :scope
end
# Attribute for field amount
sig { returns(Amount) }
attr_reader :amount
# Attribute for field applicability_config
sig { returns(ApplicabilityConfig) }
attr_reader :applicability_config
# The category of this credit grant. This is for tracking purposes and isn't displayed to the customer.
sig { returns(String) }
attr_reader :category
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# ID of the customer receiving the billing credits.
sig { returns(T.any(String, Stripe::Customer)) }
attr_reader :customer
# ID of the account receiving the billing credits
sig { returns(T.nilable(String)) }
attr_reader :customer_account
# The time when the billing credits become effective-when they're eligible for use.
sig { returns(T.nilable(Integer)) }
attr_reader :effective_at
# The time when the billing credits expire. If not present, the billing credits don't expire.
sig { returns(T.nilable(Integer)) }
attr_reader :expires_at
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# 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.
sig { returns(T::Hash[String, String]) }
attr_reader :metadata
# A descriptive name shown in dashboard.
sig { returns(T.nilable(String)) }
attr_reader :name
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The priority for applying this credit grant. The highest priority is 0 and the lowest is 100.
sig { returns(T.nilable(Integer)) }
attr_reader :priority
# ID of the test clock this credit grant belongs to.
sig { returns(T.nilable(T.any(String, Stripe::TestHelpers::TestClock))) }
attr_reader :test_clock
# Time at which the object was last updated. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :updated
# The time when this credit grant was voided. If not present, the credit grant hasn't been voided.
sig { returns(T.nilable(Integer)) }
attr_reader :voided_at
class ListParams < Stripe::RequestParams
# Only return credit grants for this customer.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# Only return credit grants for this account.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(customer: T.nilable(String), customer_account: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
customer: nil,
customer_account: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class Amount < Stripe::RequestParams
class Monetary < Stripe::RequestParams
# Three-letter [ISO code for the currency](https://stripe.com/docs/currencies) of the `value` parameter.
sig { returns(String) }
attr_accessor :currency
# A positive integer representing the amount of the credit grant.
sig { returns(Integer) }
attr_accessor :value
sig { params(currency: String, value: Integer).void }
def initialize(currency: nil, value: nil); end
end
# The monetary amount.
sig { returns(T.nilable(::Stripe::Billing::CreditGrant::CreateParams::Amount::Monetary)) }
attr_accessor :monetary
# Specify the type of this amount. We currently only support `monetary` billing credits.
sig { returns(String) }
attr_accessor :type
sig {
params(monetary: T.nilable(::Stripe::Billing::CreditGrant::CreateParams::Amount::Monetary), type: String).void
}
def initialize(monetary: nil, type: nil); end
end
class ApplicabilityConfig < Stripe::RequestParams
class Scope < Stripe::RequestParams
class Price < Stripe::RequestParams
# The price ID this credit grant should apply to.
sig { returns(String) }
attr_accessor :id
sig { params(id: String).void }
def initialize(id: nil); end
end
# The price type that credit grants can apply to. We currently only support the `metered` price type. Cannot be used in combination with `prices`.
sig { returns(T.nilable(String)) }
attr_accessor :price_type
# A list of prices that the credit grant can apply to. We currently only support the `metered` prices. Cannot be used in combination with `price_type`.
sig {
returns(T.nilable(T::Array[::Stripe::Billing::CreditGrant::CreateParams::ApplicabilityConfig::Scope::Price]))
}
attr_accessor :prices
sig {
params(price_type: T.nilable(String), prices: T.nilable(T::Array[::Stripe::Billing::CreditGrant::CreateParams::ApplicabilityConfig::Scope::Price])).void
}
def initialize(price_type: nil, prices: nil); end
end
# Specify the scope of this applicability config.
sig { returns(::Stripe::Billing::CreditGrant::CreateParams::ApplicabilityConfig::Scope) }
attr_accessor :scope
sig {
params(scope: ::Stripe::Billing::CreditGrant::CreateParams::ApplicabilityConfig::Scope).void
}
def initialize(scope: nil); end
end
# Amount of this credit grant.
sig { returns(::Stripe::Billing::CreditGrant::CreateParams::Amount) }
attr_accessor :amount
# Configuration specifying what this credit grant applies to. We currently only support `metered` prices that have a [Billing Meter](https://docs.stripe.com/api/billing/meter) attached to them.
sig { returns(::Stripe::Billing::CreditGrant::CreateParams::ApplicabilityConfig) }
attr_accessor :applicability_config
# The category of this credit grant.
sig { returns(String) }
attr_accessor :category
# ID of the customer to receive the billing credits.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# ID of the account to receive the billing credits.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# The time when the billing credits become effective-when they're eligible for use. It defaults to the current timestamp if not specified.
sig { returns(T.nilable(Integer)) }
attr_accessor :effective_at
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The time when the billing credits expire. If not specified, the billing credits don't expire.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_at
# Set of key-value pairs that you can attach to an object. You can use this to store additional information about the object (for example, cost basis) in a structured format.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# A descriptive name shown in the Dashboard.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The desired priority for applying this credit grant. If not specified, it will be set to the default value of 50. The highest priority is 0 and the lowest is 100.
sig { returns(T.nilable(Integer)) }
attr_accessor :priority
sig {
params(amount: ::Stripe::Billing::CreditGrant::CreateParams::Amount, applicability_config: ::Stripe::Billing::CreditGrant::CreateParams::ApplicabilityConfig, category: String, customer: T.nilable(String), customer_account: T.nilable(String), effective_at: T.nilable(Integer), expand: T.nilable(T::Array[String]), expires_at: T.nilable(Integer), metadata: T.nilable(T::Hash[String, String]), name: T.nilable(String), priority: T.nilable(Integer)).void
}
def initialize(
amount: nil,
applicability_config: nil,
category: nil,
customer: nil,
customer_account: nil,
effective_at: nil,
expand: nil,
expires_at: nil,
metadata: nil,
name: nil,
priority: nil
); end
end
class UpdateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The time when the billing credits created by this credit grant expire. If set to empty, the billing credits never expire.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :expires_at
# Set of key-value pairs you can attach to an object. You can use this to store additional information about the object (for example, cost basis) in a structured format.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
sig {
params(expand: T.nilable(T::Array[String]), expires_at: T.nilable(T.nilable(T.any(String, Integer))), metadata: T.nilable(T::Hash[String, String])).void
}
def initialize(expand: nil, expires_at: nil, metadata: nil); end
end
class ExpireParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class VoidGrantParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Creates a credit grant.
sig {
params(params: T.any(::Stripe::Billing::CreditGrant::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Billing::CreditGrant)
}
def self.create(params = {}, opts = {}); end
# Expires a credit grant.
sig {
params(params: T.any(::Stripe::Billing::CreditGrant::ExpireParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Billing::CreditGrant)
}
def expire(params = {}, opts = {}); end
# Expires a credit grant.
sig {
params(id: String, params: T.any(::Stripe::Billing::CreditGrant::ExpireParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Billing::CreditGrant)
}
def self.expire(id, params = {}, opts = {}); end
# Retrieve a list of credit grants.
sig {
params(params: T.any(::Stripe::Billing::CreditGrant::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Updates a credit grant.
sig {
params(id: String, params: T.any(::Stripe::Billing::CreditGrant::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Billing::CreditGrant)
}
def self.update(id, params = {}, opts = {}); end
# Voids a credit grant.
sig {
params(params: T.any(::Stripe::Billing::CreditGrant::VoidGrantParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Billing::CreditGrant)
}
def void_grant(params = {}, opts = {}); end
# Voids a credit grant.
sig {
params(id: String, params: T.any(::Stripe::Billing::CreditGrant::VoidGrantParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Billing::CreditGrant)
}
def self.void_grant(id, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Billing
# Meters specify how to aggregate meter events over a billing period. Meter events represent the actions that customers take in your system. Meters attach to prices and form the basis of the bill.
#
# Related guide: [Usage based billing](https://docs.stripe.com/billing/subscriptions/usage-based)
class Meter < APIResource
class CustomerMapping < Stripe::StripeObject
# The key in the meter event payload to use for mapping the event to a customer.
sig { returns(String) }
attr_reader :event_payload_key
# The method for mapping a meter event to a customer.
sig { returns(String) }
attr_reader :type
end
class DefaultAggregation < Stripe::StripeObject
# Specifies how events are aggregated.
sig { returns(String) }
attr_reader :formula
end
class StatusTransitions < Stripe::StripeObject
# The time the meter was deactivated, if any. Measured in seconds since Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_reader :deactivated_at
end
class ValueSettings < Stripe::StripeObject
# The key in the meter event payload to use as the value for this meter.
sig { returns(String) }
attr_reader :event_payload_key
end
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# Attribute for field customer_mapping
sig { returns(CustomerMapping) }
attr_reader :customer_mapping
# Attribute for field default_aggregation
sig { returns(DefaultAggregation) }
attr_reader :default_aggregation
# The meter's name.
sig { returns(String) }
attr_reader :display_name
# The name of the meter event to record usage for. Corresponds with the `event_name` field on meter events.
sig { returns(String) }
attr_reader :event_name
# The time window to pre-aggregate meter events for, if any.
sig { returns(T.nilable(String)) }
attr_reader :event_time_window
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The meter's status.
sig { returns(String) }
attr_reader :status
# Attribute for field status_transitions
sig { returns(StatusTransitions) }
attr_reader :status_transitions
# Time at which the object was last updated. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :updated
# Attribute for field value_settings
sig { returns(ValueSettings) }
attr_reader :value_settings
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Filter results to only include meters with the given status.
sig { returns(T.nilable(String)) }
attr_accessor :status
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String), status: T.nilable(String)).void
}
def initialize(
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil,
status: nil
); end
end
class CreateParams < Stripe::RequestParams
class CustomerMapping < Stripe::RequestParams
# The key in the meter event payload to use for mapping the event to a customer.
sig { returns(String) }
attr_accessor :event_payload_key
# The method for mapping a meter event to a customer. Must be `by_id`.
sig { returns(String) }
attr_accessor :type
sig { params(event_payload_key: String, type: String).void }
def initialize(event_payload_key: nil, type: nil); end
end
class DefaultAggregation < Stripe::RequestParams
# Specifies how events are aggregated. Allowed values are `count` to count the number of events, `sum` to sum each event's value and `last` to take the last event's value in the window.
sig { returns(String) }
attr_accessor :formula
sig { params(formula: String).void }
def initialize(formula: nil); end
end
class ValueSettings < Stripe::RequestParams
# The key in the usage event payload to use as the value for this meter. For example, if the event payload contains usage on a `bytes_used` field, then set the event_payload_key to "bytes_used".
sig { returns(String) }
attr_accessor :event_payload_key
sig { params(event_payload_key: String).void }
def initialize(event_payload_key: nil); end
end
# Fields that specify how to map a meter event to a customer.
sig { returns(T.nilable(::Stripe::Billing::Meter::CreateParams::CustomerMapping)) }
attr_accessor :customer_mapping
# The default settings to aggregate a meter's events with.
sig { returns(::Stripe::Billing::Meter::CreateParams::DefaultAggregation) }
attr_accessor :default_aggregation
# The meter’s name. Not visible to the customer.
sig { returns(String) }
attr_accessor :display_name
# The name of the meter event to record usage for. Corresponds with the `event_name` field on meter events.
sig { returns(String) }
attr_accessor :event_name
# The time window to pre-aggregate meter events for, if any.
sig { returns(T.nilable(String)) }
attr_accessor :event_time_window
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Fields that specify how to calculate a meter event's value.
sig { returns(T.nilable(::Stripe::Billing::Meter::CreateParams::ValueSettings)) }
attr_accessor :value_settings
sig {
params(customer_mapping: T.nilable(::Stripe::Billing::Meter::CreateParams::CustomerMapping), default_aggregation: ::Stripe::Billing::Meter::CreateParams::DefaultAggregation, display_name: String, event_name: String, event_time_window: T.nilable(String), expand: T.nilable(T::Array[String]), value_settings: T.nilable(::Stripe::Billing::Meter::CreateParams::ValueSettings)).void
}
def initialize(
customer_mapping: nil,
default_aggregation: nil,
display_name: nil,
event_name: nil,
event_time_window: nil,
expand: nil,
value_settings: nil
); end
end
class UpdateParams < Stripe::RequestParams
# The meter’s name. Not visible to the customer.
sig { returns(T.nilable(String)) }
attr_accessor :display_name
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(display_name: T.nilable(String), expand: T.nilable(T::Array[String])).void }
def initialize(display_name: nil, expand: nil); end
end
class DeactivateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class ReactivateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Creates a billing meter.
sig {
params(params: T.any(::Stripe::Billing::Meter::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Billing::Meter)
}
def self.create(params = {}, opts = {}); end
# When a meter is deactivated, no more meter events will be accepted for this meter. You can't attach a deactivated meter to a price.
sig {
params(params: T.any(::Stripe::Billing::Meter::DeactivateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Billing::Meter)
}
def deactivate(params = {}, opts = {}); end
# When a meter is deactivated, no more meter events will be accepted for this meter. You can't attach a deactivated meter to a price.
sig {
params(id: String, params: T.any(::Stripe::Billing::Meter::DeactivateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Billing::Meter)
}
def self.deactivate(id, params = {}, opts = {}); end
# Retrieve a list of billing meters.
sig {
params(params: T.any(::Stripe::Billing::Meter::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# When a meter is reactivated, events for this meter can be accepted and you can attach the meter to a price.
sig {
params(params: T.any(::Stripe::Billing::Meter::ReactivateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Billing::Meter)
}
def reactivate(params = {}, opts = {}); end
# When a meter is reactivated, events for this meter can be accepted and you can attach the meter to a price.
sig {
params(id: String, params: T.any(::Stripe::Billing::Meter::ReactivateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Billing::Meter)
}
def self.reactivate(id, params = {}, opts = {}); end
# Updates a billing meter.
sig {
params(id: String, params: T.any(::Stripe::Billing::Meter::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Billing::Meter)
}
def self.update(id, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Billing
# Meter events represent actions that customers take in your system. You can use meter events to bill a customer based on their usage. Meter events are associated with billing meters, which define both the contents of the event's payload and how to aggregate those events.
class MeterEvent < APIResource
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# The name of the meter event. Corresponds with the `event_name` field on a meter.
sig { returns(String) }
attr_reader :event_name
# A unique identifier for the event.
sig { returns(String) }
attr_reader :identifier
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The payload of the event. This contains the fields corresponding to a meter's `customer_mapping.event_payload_key` (default is `stripe_customer_id`) and `value_settings.event_payload_key` (default is `value`). Read more about the [payload](https://stripe.com/docs/billing/subscriptions/usage-based/recording-usage#payload-key-overrides).
sig { returns(T::Hash[String, String]) }
attr_reader :payload
# The timestamp passed in when creating the event. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :timestamp
class CreateParams < Stripe::RequestParams
# The name of the meter event. Corresponds with the `event_name` field on a meter.
sig { returns(String) }
attr_accessor :event_name
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A unique identifier for the event. If not provided, one is generated. We recommend using UUID-like identifiers. We will enforce uniqueness within a rolling period of at least 24 hours. The enforcement of uniqueness primarily addresses issues arising from accidental retries or other problems occurring within extremely brief time intervals. This approach helps prevent duplicate entries and ensures data integrity in high-frequency operations.
sig { returns(T.nilable(String)) }
attr_accessor :identifier
# The payload of the event. This must contain the fields corresponding to a meter's `customer_mapping.event_payload_key` (default is `stripe_customer_id`) and `value_settings.event_payload_key` (default is `value`). Read more about the [payload](https://docs.stripe.com/billing/subscriptions/usage-based/recording-usage#payload-key-overrides).
sig { returns(T::Hash[String, String]) }
attr_accessor :payload
# The time of the event. Measured in seconds since the Unix epoch. Must be within the past 35 calendar days or up to 5 minutes in the future. Defaults to current timestamp if not specified.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
sig {
params(event_name: String, expand: T.nilable(T::Array[String]), identifier: T.nilable(String), payload: T::Hash[String, String], timestamp: T.nilable(Integer)).void
}
def initialize(
event_name: nil,
expand: nil,
identifier: nil,
payload: nil,
timestamp: nil
); end
end
# Creates a billing meter event.
sig {
params(params: T.any(::Stripe::Billing::MeterEvent::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Billing::MeterEvent)
}
def self.create(params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Billing
# A billing meter event adjustment is a resource that allows you to cancel a meter event. For example, you might create a billing meter event adjustment to cancel a meter event that was created in error or attached to the wrong customer.
class MeterEventAdjustment < APIResource
class Cancel < Stripe::StripeObject
# Unique identifier for the event.
sig { returns(T.nilable(String)) }
attr_reader :identifier
end
# Specifies which event to cancel.
sig { returns(T.nilable(Cancel)) }
attr_reader :cancel
# The name of the meter event. Corresponds with the `event_name` field on a meter.
sig { returns(String) }
attr_reader :event_name
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The meter event adjustment's status.
sig { returns(String) }
attr_reader :status
# Specifies whether to cancel a single event or a range of events for a time period. Time period cancellation is not supported yet.
sig { returns(String) }
attr_reader :type
class CreateParams < Stripe::RequestParams
class Cancel < Stripe::RequestParams
# Unique identifier for the event. You can only cancel events within 24 hours of Stripe receiving them.
sig { returns(T.nilable(String)) }
attr_accessor :identifier
sig { params(identifier: T.nilable(String)).void }
def initialize(identifier: nil); end
end
# Specifies which event to cancel.
sig { returns(T.nilable(::Stripe::Billing::MeterEventAdjustment::CreateParams::Cancel)) }
attr_accessor :cancel
# The name of the meter event. Corresponds with the `event_name` field on a meter.
sig { returns(String) }
attr_accessor :event_name
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Specifies whether to cancel a single event or a range of events for a time period. Time period cancellation is not supported yet.
sig { returns(String) }
attr_accessor :type
sig {
params(cancel: T.nilable(::Stripe::Billing::MeterEventAdjustment::CreateParams::Cancel), event_name: String, expand: T.nilable(T::Array[String]), type: String).void
}
def initialize(cancel: nil, event_name: nil, expand: nil, type: nil); end
end
# Creates a billing meter event adjustment.
sig {
params(params: T.any(::Stripe::Billing::MeterEventAdjustment::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Billing::MeterEventAdjustment)
}
def self.create(params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Billing
# A billing meter event summary represents an aggregated view of a customer's billing meter events within a specified timeframe. It indicates how much
# usage was accrued by a customer for that period.
#
# Note: Meters events are aggregated asynchronously so the meter event summaries provide an eventually consistent view of the reported usage.
class MeterEventSummary < APIResource
# Aggregated value of all the events within `start_time` (inclusive) and `end_time` (inclusive). The aggregation strategy is defined on meter via `default_aggregation`.
sig { returns(Float) }
attr_reader :aggregated_value
# End timestamp for this event summary (exclusive). Must be aligned with minute boundaries.
sig { returns(Integer) }
attr_reader :end_time
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# The meter associated with this event summary.
sig { returns(String) }
attr_reader :meter
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Start timestamp for this event summary (inclusive). Must be aligned with minute boundaries.
sig { returns(Integer) }
attr_reader :start_time
end
end
end
# typed: true
module Stripe
module BillingPortal
# A portal configuration describes the functionality and behavior of a portal session.
class Configuration < APIResource
class BusinessProfile < Stripe::StripeObject
# The messaging shown to customers in the portal.
sig { returns(T.nilable(String)) }
attr_reader :headline
# A link to the business’s publicly available privacy policy.
sig { returns(T.nilable(String)) }
attr_reader :privacy_policy_url
# A link to the business’s publicly available terms of service.
sig { returns(T.nilable(String)) }
attr_reader :terms_of_service_url
end
class Features < Stripe::StripeObject
class CustomerUpdate < Stripe::StripeObject
# The types of customer updates that are supported. When empty, customers are not updateable.
sig { returns(T::Array[String]) }
attr_reader :allowed_updates
# Whether the feature is enabled.
sig { returns(T::Boolean) }
attr_reader :enabled
end
class InvoiceHistory < Stripe::StripeObject
# Whether the feature is enabled.
sig { returns(T::Boolean) }
attr_reader :enabled
end
class PaymentMethodUpdate < Stripe::StripeObject
# Whether the feature is enabled.
sig { returns(T::Boolean) }
attr_reader :enabled
end
class SubscriptionCancel < Stripe::StripeObject
class CancellationReason < Stripe::StripeObject
# Whether the feature is enabled.
sig { returns(T::Boolean) }
attr_reader :enabled
# Which cancellation reasons will be given as options to the customer.
sig { returns(T::Array[String]) }
attr_reader :options
end
# Attribute for field cancellation_reason
sig { returns(CancellationReason) }
attr_reader :cancellation_reason
# Whether the feature is enabled.
sig { returns(T::Boolean) }
attr_reader :enabled
# Whether to cancel subscriptions immediately or at the end of the billing period.
sig { returns(String) }
attr_reader :mode
# Whether to create prorations when canceling subscriptions. Possible values are `none` and `create_prorations`.
sig { returns(String) }
attr_reader :proration_behavior
end
class SubscriptionUpdate < Stripe::StripeObject
class Product < Stripe::StripeObject
# The list of price IDs which, when subscribed to, a subscription can be updated.
sig { returns(T::Array[String]) }
attr_reader :prices
# The product ID.
sig { returns(String) }
attr_reader :product
end
class ScheduleAtPeriodEnd < Stripe::StripeObject
class Condition < Stripe::StripeObject
# The type of condition.
sig { returns(String) }
attr_reader :type
end
# List of conditions. When any condition is true, an update will be scheduled at the end of the current period.
sig { returns(T::Array[Condition]) }
attr_reader :conditions
end
# The types of subscription updates that are supported for items listed in the `products` attribute. When empty, subscriptions are not updateable.
sig { returns(T::Array[String]) }
attr_reader :default_allowed_updates
# Whether the feature is enabled.
sig { returns(T::Boolean) }
attr_reader :enabled
# The list of up to 10 products that support subscription updates.
sig { returns(T.nilable(T::Array[Product])) }
attr_reader :products
# Determines how to handle prorations resulting from subscription updates. Valid values are `none`, `create_prorations`, and `always_invoice`. Defaults to a value of `none` if you don't set it during creation.
sig { returns(String) }
attr_reader :proration_behavior
# Attribute for field schedule_at_period_end
sig { returns(ScheduleAtPeriodEnd) }
attr_reader :schedule_at_period_end
end
# Attribute for field customer_update
sig { returns(CustomerUpdate) }
attr_reader :customer_update
# Attribute for field invoice_history
sig { returns(InvoiceHistory) }
attr_reader :invoice_history
# Attribute for field payment_method_update
sig { returns(PaymentMethodUpdate) }
attr_reader :payment_method_update
# Attribute for field subscription_cancel
sig { returns(SubscriptionCancel) }
attr_reader :subscription_cancel
# Attribute for field subscription_update
sig { returns(SubscriptionUpdate) }
attr_reader :subscription_update
end
class LoginPage < Stripe::StripeObject
# If `true`, a shareable `url` will be generated that will take your customers to a hosted login page for the customer portal.
#
# If `false`, the previously generated `url`, if any, will be deactivated.
sig { returns(T::Boolean) }
attr_reader :enabled
# A shareable URL to the hosted portal login page. Your customers will be able to log in with their [email](https://stripe.com/docs/api/customers/object#customer_object-email) and receive a link to their customer portal.
sig { returns(T.nilable(String)) }
attr_reader :url
end
# Whether the configuration is active and can be used to create portal sessions.
sig { returns(T::Boolean) }
attr_reader :active
# ID of the Connect Application that created the configuration.
sig { returns(T.nilable(T.any(String, Stripe::Application))) }
attr_reader :application
# Attribute for field business_profile
sig { returns(BusinessProfile) }
attr_reader :business_profile
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# The default URL to redirect customers to when they click on the portal's link to return to your website. This can be [overriden](https://stripe.com/docs/api/customer_portal/sessions/create#create_portal_session-return_url) when creating the session.
sig { returns(T.nilable(String)) }
attr_reader :default_return_url
# Attribute for field features
sig { returns(Features) }
attr_reader :features
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Whether the configuration is the default. If `true`, this configuration can be managed in the Dashboard and portal sessions will use this configuration unless it is overriden when creating the session.
sig { returns(T::Boolean) }
attr_reader :is_default
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# Attribute for field login_page
sig { returns(LoginPage) }
attr_reader :login_page
# 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.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Time at which the object was last updated. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :updated
class ListParams < Stripe::RequestParams
# Only return configurations that are active or inactive (e.g., pass `true` to only list active configurations).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Only return the default or non-default configurations (e.g., pass `true` to only list the default configuration).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :is_default
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(active: T.nilable(T::Boolean), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), is_default: T.nilable(T::Boolean), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
active: nil,
ending_before: nil,
expand: nil,
is_default: nil,
limit: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class BusinessProfile < Stripe::RequestParams
# The messaging shown to customers in the portal.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :headline
# A link to the business’s publicly available privacy policy.
sig { returns(T.nilable(String)) }
attr_accessor :privacy_policy_url
# A link to the business’s publicly available terms of service.
sig { returns(T.nilable(String)) }
attr_accessor :terms_of_service_url
sig {
params(headline: T.nilable(T.nilable(String)), privacy_policy_url: T.nilable(String), terms_of_service_url: T.nilable(String)).void
}
def initialize(headline: nil, privacy_policy_url: nil, terms_of_service_url: nil); end
end
class Features < Stripe::RequestParams
class CustomerUpdate < Stripe::RequestParams
# The types of customer updates that are supported. When empty, customers are not updateable.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :allowed_updates
# Whether the feature is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
sig {
params(allowed_updates: T.nilable(T.nilable(T.any(String, T::Array[String]))), enabled: T::Boolean).void
}
def initialize(allowed_updates: nil, enabled: nil); end
end
class InvoiceHistory < Stripe::RequestParams
# Whether the feature is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
sig { params(enabled: T::Boolean).void }
def initialize(enabled: nil); end
end
class PaymentMethodUpdate < Stripe::RequestParams
# Whether the feature is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
sig { params(enabled: T::Boolean).void }
def initialize(enabled: nil); end
end
class SubscriptionCancel < Stripe::RequestParams
class CancellationReason < Stripe::RequestParams
# Whether the feature is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# Which cancellation reasons will be given as options to the customer.
sig { returns(T.nilable(T.any(String, T::Array[String]))) }
attr_accessor :options
sig {
params(enabled: T::Boolean, options: T.nilable(T.any(String, T::Array[String]))).void
}
def initialize(enabled: nil, options: nil); end
end
# Whether the cancellation reasons will be collected in the portal and which options are exposed to the customer
sig {
returns(T.nilable(::Stripe::BillingPortal::Configuration::CreateParams::Features::SubscriptionCancel::CancellationReason))
}
attr_accessor :cancellation_reason
# Whether the feature is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# Whether to cancel subscriptions immediately or at the end of the billing period.
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Whether to create prorations when canceling subscriptions. Possible values are `none` and `create_prorations`, which is only compatible with `mode=immediately`. Passing `always_invoice` will result in an error. No prorations are generated when canceling a subscription at the end of its natural billing period.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
sig {
params(cancellation_reason: T.nilable(::Stripe::BillingPortal::Configuration::CreateParams::Features::SubscriptionCancel::CancellationReason), enabled: T::Boolean, mode: T.nilable(String), proration_behavior: T.nilable(String)).void
}
def initialize(
cancellation_reason: nil,
enabled: nil,
mode: nil,
proration_behavior: nil
); end
end
class SubscriptionUpdate < Stripe::RequestParams
class Product < Stripe::RequestParams
# The list of price IDs for the product that a subscription can be updated to.
sig { returns(T::Array[String]) }
attr_accessor :prices
# The product id.
sig { returns(String) }
attr_accessor :product
sig { params(prices: T::Array[String], product: String).void }
def initialize(prices: nil, product: nil); end
end
class ScheduleAtPeriodEnd < Stripe::RequestParams
class Condition < Stripe::RequestParams
# The type of condition.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
# List of conditions. When any condition is true, the update will be scheduled at the end of the current period.
sig {
returns(T.nilable(T::Array[::Stripe::BillingPortal::Configuration::CreateParams::Features::SubscriptionUpdate::ScheduleAtPeriodEnd::Condition]))
}
attr_accessor :conditions
sig {
params(conditions: T.nilable(T::Array[::Stripe::BillingPortal::Configuration::CreateParams::Features::SubscriptionUpdate::ScheduleAtPeriodEnd::Condition])).void
}
def initialize(conditions: nil); end
end
# The types of subscription updates that are supported. When empty, subscriptions are not updateable.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :default_allowed_updates
# Whether the feature is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of up to 10 products that support subscription updates.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::BillingPortal::Configuration::CreateParams::Features::SubscriptionUpdate::Product]))))
}
attr_accessor :products
# Determines how to handle prorations resulting from subscription updates. Valid values are `none`, `create_prorations`, and `always_invoice`.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
# Setting to control when an update should be scheduled at the end of the period instead of applying immediately.
sig {
returns(T.nilable(::Stripe::BillingPortal::Configuration::CreateParams::Features::SubscriptionUpdate::ScheduleAtPeriodEnd))
}
attr_accessor :schedule_at_period_end
sig {
params(default_allowed_updates: T.nilable(T.nilable(T.any(String, T::Array[String]))), enabled: T::Boolean, products: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::BillingPortal::Configuration::CreateParams::Features::SubscriptionUpdate::Product]))), proration_behavior: T.nilable(String), schedule_at_period_end: T.nilable(::Stripe::BillingPortal::Configuration::CreateParams::Features::SubscriptionUpdate::ScheduleAtPeriodEnd)).void
}
def initialize(
default_allowed_updates: nil,
enabled: nil,
products: nil,
proration_behavior: nil,
schedule_at_period_end: nil
); end
end
# Information about updating the customer details in the portal.
sig {
returns(T.nilable(::Stripe::BillingPortal::Configuration::CreateParams::Features::CustomerUpdate))
}
attr_accessor :customer_update
# Information about showing the billing history in the portal.
sig {
returns(T.nilable(::Stripe::BillingPortal::Configuration::CreateParams::Features::InvoiceHistory))
}
attr_accessor :invoice_history
# Information about updating payment methods in the portal.
sig {
returns(T.nilable(::Stripe::BillingPortal::Configuration::CreateParams::Features::PaymentMethodUpdate))
}
attr_accessor :payment_method_update
# Information about canceling subscriptions in the portal.
sig {
returns(T.nilable(::Stripe::BillingPortal::Configuration::CreateParams::Features::SubscriptionCancel))
}
attr_accessor :subscription_cancel
# Information about updating subscriptions in the portal.
sig {
returns(T.nilable(::Stripe::BillingPortal::Configuration::CreateParams::Features::SubscriptionUpdate))
}
attr_accessor :subscription_update
sig {
params(customer_update: T.nilable(::Stripe::BillingPortal::Configuration::CreateParams::Features::CustomerUpdate), invoice_history: T.nilable(::Stripe::BillingPortal::Configuration::CreateParams::Features::InvoiceHistory), payment_method_update: T.nilable(::Stripe::BillingPortal::Configuration::CreateParams::Features::PaymentMethodUpdate), subscription_cancel: T.nilable(::Stripe::BillingPortal::Configuration::CreateParams::Features::SubscriptionCancel), subscription_update: T.nilable(::Stripe::BillingPortal::Configuration::CreateParams::Features::SubscriptionUpdate)).void
}
def initialize(
customer_update: nil,
invoice_history: nil,
payment_method_update: nil,
subscription_cancel: nil,
subscription_update: nil
); end
end
class LoginPage < Stripe::RequestParams
# Set to `true` to generate a shareable URL [`login_page.url`](https://stripe.com/docs/api/customer_portal/configuration#portal_configuration_object-login_page-url) that will take your customers to a hosted login page for the customer portal.
sig { returns(T::Boolean) }
attr_accessor :enabled
sig { params(enabled: T::Boolean).void }
def initialize(enabled: nil); end
end
# The business information shown to customers in the portal.
sig {
returns(T.nilable(::Stripe::BillingPortal::Configuration::CreateParams::BusinessProfile))
}
attr_accessor :business_profile
# The default URL to redirect customers to when they click on the portal's link to return to your website. This can be [overriden](https://stripe.com/docs/api/customer_portal/sessions/create#create_portal_session-return_url) when creating the session.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :default_return_url
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Information about the features available in the portal.
sig { returns(::Stripe::BillingPortal::Configuration::CreateParams::Features) }
attr_accessor :features
# The hosted login page for this configuration. Learn more about the portal login page in our [integration docs](https://stripe.com/docs/billing/subscriptions/integrating-customer-portal#share).
sig { returns(T.nilable(::Stripe::BillingPortal::Configuration::CreateParams::LoginPage)) }
attr_accessor :login_page
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
sig {
params(business_profile: T.nilable(::Stripe::BillingPortal::Configuration::CreateParams::BusinessProfile), default_return_url: T.nilable(T.nilable(String)), expand: T.nilable(T::Array[String]), features: ::Stripe::BillingPortal::Configuration::CreateParams::Features, login_page: T.nilable(::Stripe::BillingPortal::Configuration::CreateParams::LoginPage), metadata: T.nilable(T::Hash[String, String])).void
}
def initialize(
business_profile: nil,
default_return_url: nil,
expand: nil,
features: nil,
login_page: nil,
metadata: nil
); end
end
class UpdateParams < Stripe::RequestParams
class BusinessProfile < Stripe::RequestParams
# The messaging shown to customers in the portal.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :headline
# A link to the business’s publicly available privacy policy.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :privacy_policy_url
# A link to the business’s publicly available terms of service.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :terms_of_service_url
sig {
params(headline: T.nilable(T.nilable(String)), privacy_policy_url: T.nilable(T.nilable(String)), terms_of_service_url: T.nilable(T.nilable(String))).void
}
def initialize(headline: nil, privacy_policy_url: nil, terms_of_service_url: nil); end
end
class Features < Stripe::RequestParams
class CustomerUpdate < Stripe::RequestParams
# The types of customer updates that are supported. When empty, customers are not updateable.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :allowed_updates
# Whether the feature is enabled.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :enabled
sig {
params(allowed_updates: T.nilable(T.nilable(T.any(String, T::Array[String]))), enabled: T.nilable(T::Boolean)).void
}
def initialize(allowed_updates: nil, enabled: nil); end
end
class InvoiceHistory < Stripe::RequestParams
# Whether the feature is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
sig { params(enabled: T::Boolean).void }
def initialize(enabled: nil); end
end
class PaymentMethodUpdate < Stripe::RequestParams
# Whether the feature is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
sig { params(enabled: T::Boolean).void }
def initialize(enabled: nil); end
end
class SubscriptionCancel < Stripe::RequestParams
class CancellationReason < Stripe::RequestParams
# Whether the feature is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# Which cancellation reasons will be given as options to the customer.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :options
sig {
params(enabled: T::Boolean, options: T.nilable(T.nilable(T.any(String, T::Array[String])))).void
}
def initialize(enabled: nil, options: nil); end
end
# Whether the cancellation reasons will be collected in the portal and which options are exposed to the customer
sig {
returns(T.nilable(::Stripe::BillingPortal::Configuration::UpdateParams::Features::SubscriptionCancel::CancellationReason))
}
attr_accessor :cancellation_reason
# Whether the feature is enabled.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :enabled
# Whether to cancel subscriptions immediately or at the end of the billing period.
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Whether to create prorations when canceling subscriptions. Possible values are `none` and `create_prorations`, which is only compatible with `mode=immediately`. Passing `always_invoice` will result in an error. No prorations are generated when canceling a subscription at the end of its natural billing period.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
sig {
params(cancellation_reason: T.nilable(::Stripe::BillingPortal::Configuration::UpdateParams::Features::SubscriptionCancel::CancellationReason), enabled: T.nilable(T::Boolean), mode: T.nilable(String), proration_behavior: T.nilable(String)).void
}
def initialize(
cancellation_reason: nil,
enabled: nil,
mode: nil,
proration_behavior: nil
); end
end
class SubscriptionUpdate < Stripe::RequestParams
class Product < Stripe::RequestParams
# The list of price IDs for the product that a subscription can be updated to.
sig { returns(T::Array[String]) }
attr_accessor :prices
# The product id.
sig { returns(String) }
attr_accessor :product
sig { params(prices: T::Array[String], product: String).void }
def initialize(prices: nil, product: nil); end
end
class ScheduleAtPeriodEnd < Stripe::RequestParams
class Condition < Stripe::RequestParams
# The type of condition.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
# List of conditions. When any condition is true, the update will be scheduled at the end of the current period.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::BillingPortal::Configuration::UpdateParams::Features::SubscriptionUpdate::ScheduleAtPeriodEnd::Condition]))))
}
attr_accessor :conditions
sig {
params(conditions: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::BillingPortal::Configuration::UpdateParams::Features::SubscriptionUpdate::ScheduleAtPeriodEnd::Condition])))).void
}
def initialize(conditions: nil); end
end
# The types of subscription updates that are supported. When empty, subscriptions are not updateable.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :default_allowed_updates
# Whether the feature is enabled.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :enabled
# The list of up to 10 products that support subscription updates.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::BillingPortal::Configuration::UpdateParams::Features::SubscriptionUpdate::Product]))))
}
attr_accessor :products
# Determines how to handle prorations resulting from subscription updates. Valid values are `none`, `create_prorations`, and `always_invoice`.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
# Setting to control when an update should be scheduled at the end of the period instead of applying immediately.
sig {
returns(T.nilable(::Stripe::BillingPortal::Configuration::UpdateParams::Features::SubscriptionUpdate::ScheduleAtPeriodEnd))
}
attr_accessor :schedule_at_period_end
sig {
params(default_allowed_updates: T.nilable(T.nilable(T.any(String, T::Array[String]))), enabled: T.nilable(T::Boolean), products: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::BillingPortal::Configuration::UpdateParams::Features::SubscriptionUpdate::Product]))), proration_behavior: T.nilable(String), schedule_at_period_end: T.nilable(::Stripe::BillingPortal::Configuration::UpdateParams::Features::SubscriptionUpdate::ScheduleAtPeriodEnd)).void
}
def initialize(
default_allowed_updates: nil,
enabled: nil,
products: nil,
proration_behavior: nil,
schedule_at_period_end: nil
); end
end
# Information about updating the customer details in the portal.
sig {
returns(T.nilable(::Stripe::BillingPortal::Configuration::UpdateParams::Features::CustomerUpdate))
}
attr_accessor :customer_update
# Information about showing the billing history in the portal.
sig {
returns(T.nilable(::Stripe::BillingPortal::Configuration::UpdateParams::Features::InvoiceHistory))
}
attr_accessor :invoice_history
# Information about updating payment methods in the portal.
sig {
returns(T.nilable(::Stripe::BillingPortal::Configuration::UpdateParams::Features::PaymentMethodUpdate))
}
attr_accessor :payment_method_update
# Information about canceling subscriptions in the portal.
sig {
returns(T.nilable(::Stripe::BillingPortal::Configuration::UpdateParams::Features::SubscriptionCancel))
}
attr_accessor :subscription_cancel
# Information about updating subscriptions in the portal.
sig {
returns(T.nilable(::Stripe::BillingPortal::Configuration::UpdateParams::Features::SubscriptionUpdate))
}
attr_accessor :subscription_update
sig {
params(customer_update: T.nilable(::Stripe::BillingPortal::Configuration::UpdateParams::Features::CustomerUpdate), invoice_history: T.nilable(::Stripe::BillingPortal::Configuration::UpdateParams::Features::InvoiceHistory), payment_method_update: T.nilable(::Stripe::BillingPortal::Configuration::UpdateParams::Features::PaymentMethodUpdate), subscription_cancel: T.nilable(::Stripe::BillingPortal::Configuration::UpdateParams::Features::SubscriptionCancel), subscription_update: T.nilable(::Stripe::BillingPortal::Configuration::UpdateParams::Features::SubscriptionUpdate)).void
}
def initialize(
customer_update: nil,
invoice_history: nil,
payment_method_update: nil,
subscription_cancel: nil,
subscription_update: nil
); end
end
class LoginPage < Stripe::RequestParams
# Set to `true` to generate a shareable URL [`login_page.url`](https://stripe.com/docs/api/customer_portal/configuration#portal_configuration_object-login_page-url) that will take your customers to a hosted login page for the customer portal.
#
# Set to `false` to deactivate the `login_page.url`.
sig { returns(T::Boolean) }
attr_accessor :enabled
sig { params(enabled: T::Boolean).void }
def initialize(enabled: nil); end
end
# Whether the configuration is active and can be used to create portal sessions.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# The business information shown to customers in the portal.
sig {
returns(T.nilable(::Stripe::BillingPortal::Configuration::UpdateParams::BusinessProfile))
}
attr_accessor :business_profile
# The default URL to redirect customers to when they click on the portal's link to return to your website. This can be [overriden](https://stripe.com/docs/api/customer_portal/sessions/create#create_portal_session-return_url) when creating the session.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :default_return_url
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Information about the features available in the portal.
sig { returns(T.nilable(::Stripe::BillingPortal::Configuration::UpdateParams::Features)) }
attr_accessor :features
# The hosted login page for this configuration. Learn more about the portal login page in our [integration docs](https://stripe.com/docs/billing/subscriptions/integrating-customer-portal#share).
sig { returns(T.nilable(::Stripe::BillingPortal::Configuration::UpdateParams::LoginPage)) }
attr_accessor :login_page
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
sig {
params(active: T.nilable(T::Boolean), business_profile: T.nilable(::Stripe::BillingPortal::Configuration::UpdateParams::BusinessProfile), default_return_url: T.nilable(T.nilable(String)), expand: T.nilable(T::Array[String]), features: T.nilable(::Stripe::BillingPortal::Configuration::UpdateParams::Features), login_page: T.nilable(::Stripe::BillingPortal::Configuration::UpdateParams::LoginPage), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String])))).void
}
def initialize(
active: nil,
business_profile: nil,
default_return_url: nil,
expand: nil,
features: nil,
login_page: nil,
metadata: nil
); end
end
# Creates a configuration that describes the functionality and behavior of a PortalSession
sig {
params(params: T.any(::Stripe::BillingPortal::Configuration::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::BillingPortal::Configuration)
}
def self.create(params = {}, opts = {}); end
# Returns a list of configurations that describe the functionality of the customer portal.
sig {
params(params: T.any(::Stripe::BillingPortal::Configuration::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Updates a configuration that describes the functionality of the customer portal.
sig {
params(configuration: String, params: T.any(::Stripe::BillingPortal::Configuration::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::BillingPortal::Configuration)
}
def self.update(configuration, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module BillingPortal
# The Billing customer portal is a Stripe-hosted UI for subscription and
# billing management.
#
# A portal configuration describes the functionality and features that you
# want to provide to your customers through the portal.
#
# A portal session describes the instantiation of the customer portal for
# a particular customer. By visiting the session's URL, the customer
# can manage their subscriptions and billing details. For security reasons,
# sessions are short-lived and will expire if the customer does not visit the URL.
# Create sessions on-demand when customers intend to manage their subscriptions
# and billing details.
#
# Related guide: [Customer management](https://docs.stripe.com/customer-management)
class Session < APIResource
class Flow < Stripe::StripeObject
class AfterCompletion < Stripe::StripeObject
class HostedConfirmation < Stripe::StripeObject
# A custom message to display to the customer after the flow is completed.
sig { returns(T.nilable(String)) }
attr_reader :custom_message
end
class Redirect < Stripe::StripeObject
# The URL the customer will be redirected to after the flow is completed.
sig { returns(String) }
attr_reader :return_url
end
# Configuration when `after_completion.type=hosted_confirmation`.
sig { returns(T.nilable(HostedConfirmation)) }
attr_reader :hosted_confirmation
# Configuration when `after_completion.type=redirect`.
sig { returns(T.nilable(Redirect)) }
attr_reader :redirect
# The specified type of behavior after the flow is completed.
sig { returns(String) }
attr_reader :type
end
class SubscriptionCancel < Stripe::StripeObject
class Retention < Stripe::StripeObject
class CouponOffer < Stripe::StripeObject
# The ID of the coupon to be offered.
sig { returns(String) }
attr_reader :coupon
end
# Configuration when `retention.type=coupon_offer`.
sig { returns(T.nilable(CouponOffer)) }
attr_reader :coupon_offer
# Type of retention strategy that will be used.
sig { returns(String) }
attr_reader :type
end
# Specify a retention strategy to be used in the cancellation flow.
sig { returns(T.nilable(Retention)) }
attr_reader :retention
# The ID of the subscription to be canceled.
sig { returns(String) }
attr_reader :subscription
end
class SubscriptionUpdate < Stripe::StripeObject
# The ID of the subscription to be updated.
sig { returns(String) }
attr_reader :subscription
end
class SubscriptionUpdateConfirm < Stripe::StripeObject
class Discount < Stripe::StripeObject
# The ID of the coupon to apply to this subscription update.
sig { returns(T.nilable(String)) }
attr_reader :coupon
# The ID of a promotion code to apply to this subscription update.
sig { returns(T.nilable(String)) }
attr_reader :promotion_code
end
class Item < Stripe::StripeObject
# The ID of the [subscription item](https://stripe.com/docs/api/subscriptions/object#subscription_object-items-data-id) to be updated.
sig { returns(T.nilable(String)) }
attr_reader :id
# The price the customer should subscribe to through this flow. The price must also be included in the configuration's [`features.subscription_update.products`](https://stripe.com/docs/api/customer_portal/configuration#portal_configuration_object-features-subscription_update-products).
sig { returns(T.nilable(String)) }
attr_reader :price
# [Quantity](https://stripe.com/docs/subscriptions/quantities) for this item that the customer should subscribe to through this flow.
sig { returns(Integer) }
attr_reader :quantity
end
# The coupon or promotion code to apply to this subscription update. Currently, only up to one may be specified.
sig { returns(T.nilable(T::Array[Discount])) }
attr_reader :discounts
# The [subscription item](https://stripe.com/docs/api/subscription_items) to be updated through this flow. Currently, only up to one may be specified and subscriptions with multiple items are not updatable.
sig { returns(T::Array[Item]) }
attr_reader :items
# The ID of the subscription to be updated.
sig { returns(String) }
attr_reader :subscription
end
# Attribute for field after_completion
sig { returns(AfterCompletion) }
attr_reader :after_completion
# Configuration when `flow.type=subscription_cancel`.
sig { returns(T.nilable(SubscriptionCancel)) }
attr_reader :subscription_cancel
# Configuration when `flow.type=subscription_update`.
sig { returns(T.nilable(SubscriptionUpdate)) }
attr_reader :subscription_update
# Configuration when `flow.type=subscription_update_confirm`.
sig { returns(T.nilable(SubscriptionUpdateConfirm)) }
attr_reader :subscription_update_confirm
# Type of flow that the customer will go through.
sig { returns(String) }
attr_reader :type
end
# The configuration used by this session, describing the features available.
sig { returns(T.any(String, Stripe::BillingPortal::Configuration)) }
attr_reader :configuration
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# The ID of the customer for this session.
sig { returns(String) }
attr_reader :customer
# The ID of the account for this session.
sig { returns(T.nilable(String)) }
attr_reader :customer_account
# Information about a specific flow for the customer to go through. See the [docs](https://stripe.com/docs/customer-management/portal-deep-links) to learn more about using customer portal deep links and flows.
sig { returns(T.nilable(Flow)) }
attr_reader :flow
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# The IETF language tag of the locale Customer Portal is displayed in. If blank or auto, the customer’s `preferred_locales` or browser’s locale is used.
sig { returns(T.nilable(String)) }
attr_reader :locale
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The account for which the session was created on behalf of. When specified, only subscriptions and invoices with this `on_behalf_of` account appear in the portal. For more information, see the [docs](https://stripe.com/docs/connect/separate-charges-and-transfers#settlement-merchant). Use the [Accounts API](https://stripe.com/docs/api/accounts/object#account_object-settings-branding) to modify the `on_behalf_of` account's branding settings, which the portal displays.
sig { returns(T.nilable(String)) }
attr_reader :on_behalf_of
# The URL to redirect customers to when they click on the portal's link to return to your website.
sig { returns(T.nilable(String)) }
attr_reader :return_url
# The short-lived URL of the session that gives customers access to the customer portal.
sig { returns(String) }
attr_reader :url
class CreateParams < Stripe::RequestParams
class FlowData < Stripe::RequestParams
class AfterCompletion < Stripe::RequestParams
class HostedConfirmation < Stripe::RequestParams
# A custom message to display to the customer after the flow is completed.
sig { returns(T.nilable(String)) }
attr_accessor :custom_message
sig { params(custom_message: T.nilable(String)).void }
def initialize(custom_message: nil); end
end
class Redirect < Stripe::RequestParams
# The URL the customer will be redirected to after the flow is completed.
sig { returns(String) }
attr_accessor :return_url
sig { params(return_url: String).void }
def initialize(return_url: nil); end
end
# Configuration when `after_completion.type=hosted_confirmation`.
sig {
returns(T.nilable(::Stripe::BillingPortal::Session::CreateParams::FlowData::AfterCompletion::HostedConfirmation))
}
attr_accessor :hosted_confirmation
# Configuration when `after_completion.type=redirect`.
sig {
returns(T.nilable(::Stripe::BillingPortal::Session::CreateParams::FlowData::AfterCompletion::Redirect))
}
attr_accessor :redirect
# The specified behavior after the flow is completed.
sig { returns(String) }
attr_accessor :type
sig {
params(hosted_confirmation: T.nilable(::Stripe::BillingPortal::Session::CreateParams::FlowData::AfterCompletion::HostedConfirmation), redirect: T.nilable(::Stripe::BillingPortal::Session::CreateParams::FlowData::AfterCompletion::Redirect), type: String).void
}
def initialize(hosted_confirmation: nil, redirect: nil, type: nil); end
end
class SubscriptionCancel < Stripe::RequestParams
class Retention < Stripe::RequestParams
class CouponOffer < Stripe::RequestParams
# The ID of the coupon to be offered.
sig { returns(String) }
attr_accessor :coupon
sig { params(coupon: String).void }
def initialize(coupon: nil); end
end
# Configuration when `retention.type=coupon_offer`.
sig {
returns(::Stripe::BillingPortal::Session::CreateParams::FlowData::SubscriptionCancel::Retention::CouponOffer)
}
attr_accessor :coupon_offer
# Type of retention strategy to use with the customer.
sig { returns(String) }
attr_accessor :type
sig {
params(coupon_offer: ::Stripe::BillingPortal::Session::CreateParams::FlowData::SubscriptionCancel::Retention::CouponOffer, type: String).void
}
def initialize(coupon_offer: nil, type: nil); end
end
# Specify a retention strategy to be used in the cancellation flow.
sig {
returns(T.nilable(::Stripe::BillingPortal::Session::CreateParams::FlowData::SubscriptionCancel::Retention))
}
attr_accessor :retention
# The ID of the subscription to be canceled.
sig { returns(String) }
attr_accessor :subscription
sig {
params(retention: T.nilable(::Stripe::BillingPortal::Session::CreateParams::FlowData::SubscriptionCancel::Retention), subscription: String).void
}
def initialize(retention: nil, subscription: nil); end
end
class SubscriptionUpdate < Stripe::RequestParams
# The ID of the subscription to be updated.
sig { returns(String) }
attr_accessor :subscription
sig { params(subscription: String).void }
def initialize(subscription: nil); end
end
class SubscriptionUpdateConfirm < Stripe::RequestParams
class Discount < Stripe::RequestParams
# The ID of the coupon to apply to this subscription update.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# The ID of a promotion code to apply to this subscription update.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig { params(coupon: T.nilable(String), promotion_code: T.nilable(String)).void }
def initialize(coupon: nil, promotion_code: nil); end
end
class Item < Stripe::RequestParams
# The ID of the [subscription item](https://stripe.com/docs/api/subscriptions/object#subscription_object-items-data-id) to be updated.
sig { returns(String) }
attr_accessor :id
# The price the customer should subscribe to through this flow. The price must also be included in the configuration's [`features.subscription_update.products`](https://stripe.com/docs/api/customer_portal/configuration#portal_configuration_object-features-subscription_update-products).
sig { returns(T.nilable(String)) }
attr_accessor :price
# [Quantity](https://stripe.com/docs/subscriptions/quantities) for this item that the customer should subscribe to through this flow.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
sig {
params(id: String, price: T.nilable(String), quantity: T.nilable(Integer)).void
}
def initialize(id: nil, price: nil, quantity: nil); end
end
# The coupon or promotion code to apply to this subscription update. Currently, only up to one may be specified.
sig {
returns(T.nilable(T::Array[::Stripe::BillingPortal::Session::CreateParams::FlowData::SubscriptionUpdateConfirm::Discount]))
}
attr_accessor :discounts
# The [subscription item](https://stripe.com/docs/api/subscription_items) to be updated through this flow. Currently, only up to one may be specified and subscriptions with multiple items are not updatable.
sig {
returns(T::Array[::Stripe::BillingPortal::Session::CreateParams::FlowData::SubscriptionUpdateConfirm::Item])
}
attr_accessor :items
# The ID of the subscription to be updated.
sig { returns(String) }
attr_accessor :subscription
sig {
params(discounts: T.nilable(T::Array[::Stripe::BillingPortal::Session::CreateParams::FlowData::SubscriptionUpdateConfirm::Discount]), items: T::Array[::Stripe::BillingPortal::Session::CreateParams::FlowData::SubscriptionUpdateConfirm::Item], subscription: String).void
}
def initialize(discounts: nil, items: nil, subscription: nil); end
end
# Behavior after the flow is completed.
sig {
returns(T.nilable(::Stripe::BillingPortal::Session::CreateParams::FlowData::AfterCompletion))
}
attr_accessor :after_completion
# Configuration when `flow_data.type=subscription_cancel`.
sig {
returns(T.nilable(::Stripe::BillingPortal::Session::CreateParams::FlowData::SubscriptionCancel))
}
attr_accessor :subscription_cancel
# Configuration when `flow_data.type=subscription_update`.
sig {
returns(T.nilable(::Stripe::BillingPortal::Session::CreateParams::FlowData::SubscriptionUpdate))
}
attr_accessor :subscription_update
# Configuration when `flow_data.type=subscription_update_confirm`.
sig {
returns(T.nilable(::Stripe::BillingPortal::Session::CreateParams::FlowData::SubscriptionUpdateConfirm))
}
attr_accessor :subscription_update_confirm
# Type of flow that the customer will go through.
sig { returns(String) }
attr_accessor :type
sig {
params(after_completion: T.nilable(::Stripe::BillingPortal::Session::CreateParams::FlowData::AfterCompletion), subscription_cancel: T.nilable(::Stripe::BillingPortal::Session::CreateParams::FlowData::SubscriptionCancel), subscription_update: T.nilable(::Stripe::BillingPortal::Session::CreateParams::FlowData::SubscriptionUpdate), subscription_update_confirm: T.nilable(::Stripe::BillingPortal::Session::CreateParams::FlowData::SubscriptionUpdateConfirm), type: String).void
}
def initialize(
after_completion: nil,
subscription_cancel: nil,
subscription_update: nil,
subscription_update_confirm: nil,
type: nil
); end
end
# The ID of an existing [configuration](https://stripe.com/docs/api/customer_portal/configuration) to use for this session, describing its functionality and features. If not specified, the session uses the default configuration.
sig { returns(T.nilable(String)) }
attr_accessor :configuration
# The ID of an existing customer.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# The ID of an existing account.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Information about a specific flow for the customer to go through. See the [docs](https://stripe.com/docs/customer-management/portal-deep-links) to learn more about using customer portal deep links and flows.
sig { returns(T.nilable(::Stripe::BillingPortal::Session::CreateParams::FlowData)) }
attr_accessor :flow_data
# The IETF language tag of the locale customer portal is displayed in. If blank or auto, the customer’s `preferred_locales` or browser’s locale is used.
sig { returns(T.nilable(String)) }
attr_accessor :locale
# The `on_behalf_of` account to use for this session. When specified, only subscriptions and invoices with this `on_behalf_of` account appear in the portal. For more information, see the [docs](https://stripe.com/docs/connect/separate-charges-and-transfers#settlement-merchant). Use the [Accounts API](https://stripe.com/docs/api/accounts/object#account_object-settings-branding) to modify the `on_behalf_of` account's branding settings, which the portal displays.
sig { returns(T.nilable(String)) }
attr_accessor :on_behalf_of
# The default URL to redirect customers to when they click on the portal's link to return to your website.
sig { returns(T.nilable(String)) }
attr_accessor :return_url
sig {
params(configuration: T.nilable(String), customer: T.nilable(String), customer_account: T.nilable(String), expand: T.nilable(T::Array[String]), flow_data: T.nilable(::Stripe::BillingPortal::Session::CreateParams::FlowData), locale: T.nilable(String), on_behalf_of: T.nilable(String), return_url: T.nilable(String)).void
}
def initialize(
configuration: nil,
customer: nil,
customer_account: nil,
expand: nil,
flow_data: nil,
locale: nil,
on_behalf_of: nil,
return_url: nil
); end
end
# Creates a session of the customer portal.
sig {
params(params: T.any(::Stripe::BillingPortal::Session::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::BillingPortal::Session)
}
def self.create(params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
# This is an object representing a capability for a Stripe account.
#
# Related guide: [Account capabilities](https://stripe.com/docs/connect/account-capabilities)
class Capability < APIResource
class FutureRequirements < Stripe::StripeObject
class Alternative < Stripe::StripeObject
# Fields that can be provided to satisfy all fields in `original_fields_due`.
sig { returns(T::Array[String]) }
attr_reader :alternative_fields_due
# Fields that are due and can be satisfied by providing all fields in `alternative_fields_due`.
sig { returns(T::Array[String]) }
attr_reader :original_fields_due
end
class Error < Stripe::StripeObject
# The code for the type of error.
sig { returns(String) }
attr_reader :code
# An informative message that indicates the error type and provides additional details about the error.
sig { returns(String) }
attr_reader :reason
# The specific user onboarding requirement field (in the requirements hash) that needs to be resolved.
sig { returns(String) }
attr_reader :requirement
end
# Fields that are due and can be satisfied by providing the corresponding alternative fields instead.
sig { returns(T.nilable(T::Array[Alternative])) }
attr_reader :alternatives
# Date on which `future_requirements` becomes the main `requirements` hash and `future_requirements` becomes empty. After the transition, `currently_due` requirements may immediately become `past_due`, but the account may also be given a grace period depending on the capability's enablement state prior to transitioning.
sig { returns(T.nilable(Integer)) }
attr_reader :current_deadline
# Fields that need to be collected to keep the capability enabled. If not collected by `future_requirements[current_deadline]`, these fields will transition to the main `requirements` hash.
sig { returns(T::Array[String]) }
attr_reader :currently_due
# This is typed as an enum for consistency with `requirements.disabled_reason`, but it safe to assume `future_requirements.disabled_reason` is null because fields in `future_requirements` will never disable the account.
sig { returns(T.nilable(String)) }
attr_reader :disabled_reason
# Fields that are `currently_due` and need to be collected again because validation or verification failed.
sig { returns(T::Array[Error]) }
attr_reader :errors
# Fields you must collect when all thresholds are reached. As they become required, they appear in `currently_due` as well.
sig { returns(T::Array[String]) }
attr_reader :eventually_due
# Fields that weren't collected by `requirements.current_deadline`. These fields need to be collected to enable the capability on the account. New fields will never appear here; `future_requirements.past_due` will always be a subset of `requirements.past_due`.
sig { returns(T::Array[String]) }
attr_reader :past_due
# Fields that might become required depending on the results of verification or review. It's an empty array unless an asynchronous verification is pending. If verification fails, these fields move to `eventually_due` or `currently_due`. Fields might appear in `eventually_due` or `currently_due` and in `pending_verification` if verification fails but another verification is still pending.
sig { returns(T::Array[String]) }
attr_reader :pending_verification
end
class Requirements < Stripe::StripeObject
class Alternative < Stripe::StripeObject
# Fields that can be provided to satisfy all fields in `original_fields_due`.
sig { returns(T::Array[String]) }
attr_reader :alternative_fields_due
# Fields that are due and can be satisfied by providing all fields in `alternative_fields_due`.
sig { returns(T::Array[String]) }
attr_reader :original_fields_due
end
class Error < Stripe::StripeObject
# The code for the type of error.
sig { returns(String) }
attr_reader :code
# An informative message that indicates the error type and provides additional details about the error.
sig { returns(String) }
attr_reader :reason
# The specific user onboarding requirement field (in the requirements hash) that needs to be resolved.
sig { returns(String) }
attr_reader :requirement
end
# Fields that are due and can be satisfied by providing the corresponding alternative fields instead.
sig { returns(T.nilable(T::Array[Alternative])) }
attr_reader :alternatives
# The date by which all required account information must be both submitted and verified. This includes fields listed in `currently_due` as well as those in `pending_verification`. If any required information is missing or unverified by this date, the account may be disabled. Note that `current_deadline` may change if additional `currently_due` requirements are requested.
sig { returns(T.nilable(Integer)) }
attr_reader :current_deadline
# Fields that need to be collected to keep the capability enabled. If not collected by `current_deadline`, these fields appear in `past_due` as well, and the capability is disabled.
sig { returns(T::Array[String]) }
attr_reader :currently_due
# Description of why the capability is disabled. [Learn more about handling verification issues](https://stripe.com/docs/connect/handling-api-verification).
sig { returns(T.nilable(String)) }
attr_reader :disabled_reason
# Fields that are `currently_due` and need to be collected again because validation or verification failed.
sig { returns(T::Array[Error]) }
attr_reader :errors
# Fields you must collect when all thresholds are reached. As they become required, they appear in `currently_due` as well, and `current_deadline` becomes set.
sig { returns(T::Array[String]) }
attr_reader :eventually_due
# Fields that weren't collected by `current_deadline`. These fields need to be collected to enable the capability on the account.
sig { returns(T::Array[String]) }
attr_reader :past_due
# Fields that might become required depending on the results of verification or review. It's an empty array unless an asynchronous verification is pending. If verification fails, these fields move to `eventually_due`, `currently_due`, or `past_due`. Fields might appear in `eventually_due`, `currently_due`, or `past_due` and in `pending_verification` if verification fails but another verification is still pending.
sig { returns(T::Array[String]) }
attr_reader :pending_verification
end
# The account for which the capability enables functionality.
sig { returns(T.any(String, Stripe::Account)) }
attr_reader :account
# Attribute for field future_requirements
sig { returns(FutureRequirements) }
attr_reader :future_requirements
# The identifier for the capability.
sig { returns(String) }
attr_reader :id
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Whether the capability has been requested.
sig { returns(T::Boolean) }
attr_reader :requested
# Time at which the capability was requested. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_reader :requested_at
# Attribute for field requirements
sig { returns(Requirements) }
attr_reader :requirements
# The status of the capability.
sig { returns(String) }
attr_reader :status
end
end
# typed: true
module Stripe
module Capital
# This is an object representing an offer of financing from
# Stripe Capital to a Connect subaccount.
class FinancingOffer < APIResource
class AcceptedTerms < Stripe::StripeObject
# Amount of financing offered, in minor units. For example, $1,000 USD will be represented as 100000.
sig { returns(Integer) }
attr_reader :advance_amount
# Currency that the financing offer is transacted in. For example, `usd`.
sig { returns(String) }
attr_reader :currency
# Fixed fee amount, in minor units. For example, $100 USD will be represented as 10000.
sig { returns(Integer) }
attr_reader :fee_amount
# Populated when the `product_type` of the `financingoffer` is `refill`.
# Represents the discount amount on remaining premium for the existing loan at payout time.
sig { returns(T.nilable(Integer)) }
attr_reader :previous_financing_fee_discount_amount
# Per-transaction rate at which Stripe will withhold funds to repay the financing.
sig { returns(Float) }
attr_reader :withhold_rate
end
class OfferedTerms < Stripe::StripeObject
# Amount of financing offered, in minor units. For example, $1,000 USD will be represented as 100000.
sig { returns(Integer) }
attr_reader :advance_amount
# Describes the type of user the offer is being extended to.
sig { returns(String) }
attr_reader :campaign_type
# Currency that the financing offer is transacted in. For example, `usd`.
sig { returns(String) }
attr_reader :currency
# Fixed fee amount, in minor units. For example, $100 USD will be represented as 10000.
sig { returns(Integer) }
attr_reader :fee_amount
# Populated when the `product_type` of the `financingoffer` is `refill`.
# Represents the discount rate percentage on remaining fee on the existing loan. When the `financing_offer`
# is paid out, the `previous_financing_fee_discount_amount` will be computed as the multiple of this rate
# and the remaining fee.
sig { returns(T.nilable(Float)) }
attr_reader :previous_financing_fee_discount_rate
# Per-transaction rate at which Stripe will withhold funds to repay the financing.
sig { returns(Float) }
attr_reader :withhold_rate
end
# This is an object representing the terms of an offer of financing from
# Stripe Capital to a Connected account. This resource represents
# the terms accepted by the Connected account, which may differ from those
# offered.
sig { returns(AcceptedTerms) }
attr_reader :accepted_terms
# The ID of the merchant associated with this financing object.
sig { returns(String) }
attr_reader :account
# The time at which this financing offer was charged off, if applicable. Given in seconds since unix epoch.
sig { returns(Integer) }
attr_reader :charged_off_at
# Time at which the offer was created. Given in seconds since unix epoch.
sig { returns(Integer) }
attr_reader :created
# Time at which the offer expires. Given in seconds since unix epoch.
sig { returns(Float) }
attr_reader :expires_after
# The type of financing being offered.
sig { returns(String) }
attr_reader :financing_type
# A unique identifier for the financing object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# 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.
sig { returns(T::Hash[String, String]) }
attr_reader :metadata
# The object type: financing_offer.
sig { returns(String) }
attr_reader :object
# This is an object representing the terms of an offer of financing from
# Stripe Capital to a Connected account. This resource represents
# both the terms offered to the Connected account.
sig { returns(OfferedTerms) }
attr_reader :offered_terms
# Financing product identifier.
sig { returns(String) }
attr_reader :product_type
# The ID of the financing offer that replaced this offer.
sig { returns(String) }
attr_reader :replacement
# The ID of the financing offer that this offer is a replacement for.
sig { returns(String) }
attr_reader :replacement_for
# The current status of the offer.
sig { returns(String) }
attr_reader :status
# See [financing_type](https://stripe.com/docs/api/capital/connect_financing_object#financing_offer_object-financing_type).
sig { returns(String) }
attr_reader :type
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# limit list to offers belonging to given connected account
sig { returns(T.nilable(String)) }
attr_accessor :connected_account
# Only return offers that were created during the given date interval.
sig {
returns(T.nilable(T.any(::Stripe::Capital::FinancingOffer::ListParams::Created, Integer)))
}
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# limit list to offers with given status
sig { returns(T.nilable(String)) }
attr_accessor :status
sig {
params(connected_account: T.nilable(String), created: T.nilable(T.any(::Stripe::Capital::FinancingOffer::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String), status: T.nilable(String)).void
}
def initialize(
connected_account: nil,
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil,
status: nil
); end
end
class MarkDeliveredParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Retrieves the financing offers available for Connected accounts that belong to your platform.
sig {
params(params: T.any(::Stripe::Capital::FinancingOffer::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Acknowledges that platform has received and delivered the financing_offer to
# the intended merchant recipient.
sig {
params(params: T.any(::Stripe::Capital::FinancingOffer::MarkDeliveredParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Capital::FinancingOffer)
}
def mark_delivered(params = {}, opts = {}); end
# Acknowledges that platform has received and delivered the financing_offer to
# the intended merchant recipient.
sig {
params(financing_offer: String, params: T.any(::Stripe::Capital::FinancingOffer::MarkDeliveredParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Capital::FinancingOffer)
}
def self.mark_delivered(financing_offer, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Capital
# A financing object describes an account's current financing state. Used by Connect
# platforms to read the state of Capital offered to their connected accounts.
class FinancingSummary < SingletonAPIResource
class Details < Stripe::StripeObject
class CurrentRepaymentInterval < Stripe::StripeObject
# The time at which the minimum payment amount will be due. If not met through withholding, the Connected account's linked bank account or account balance will be debited.
# Given in seconds since unix epoch.
sig { returns(Float) }
attr_reader :due_at
# The amount that has already been paid in the current repayment interval, in minor units. For example, $100 USD will be represented as 10000.
sig { returns(T.nilable(Integer)) }
attr_reader :paid_amount
# The amount that is yet to be paid in the current repayment interval, in minor units. For example, $100 USD will be represented as 10000.
sig { returns(Integer) }
attr_reader :remaining_amount
end
# Amount of financing offered, in minor units. For example, $1,000 USD will be represented as 100000.
sig { returns(Integer) }
attr_reader :advance_amount
# The time at which the funds were paid out to the connected account's Stripe balance. Given in milliseconds since unix epoch.
sig { returns(T.nilable(Float)) }
attr_reader :advance_paid_out_at
# Currency that the financing offer is transacted in. For example, `usd`.
sig { returns(String) }
attr_reader :currency
# The chronologically current repayment interval for the financing offer.
sig { returns(T.nilable(CurrentRepaymentInterval)) }
attr_reader :current_repayment_interval
# Fixed fee amount, in minor units. For example, $100 USD will be represented as 10000.
sig { returns(Integer) }
attr_reader :fee_amount
# The amount the Connected account has paid toward the financing debt so far, in minor units. For example, $1,000 USD will be represented as 100000.
sig { returns(Integer) }
attr_reader :paid_amount
# The balance remaining to be paid on the financing, in minor units. For example, $1,000 USD will be represented as 100000.
sig { returns(Integer) }
attr_reader :remaining_amount
# The time at which Capital will begin withholding from payments. Given in seconds since unix epoch.
sig { returns(T.nilable(Float)) }
attr_reader :repayments_begin_at
# Per-transaction rate at which Stripe will withhold funds to repay the financing.
sig { returns(Float) }
attr_reader :withhold_rate
end
# Additional information about the financing summary. Describes currency, advance amount,
# fee amount, withhold rate, remaining amount, paid amount, current repayment interval,
# repayment start date, and advance payout date.
sig { returns(T.nilable(Details)) }
attr_reader :details
# The Financing Offer ID this Financing Summary corresponds to
sig { returns(T.nilable(String)) }
attr_reader :financing_offer
# The object type: financing_summary
sig { returns(String) }
attr_reader :object
# Status of the Connected Account's financing. [/v1/capital/financing_summary](https://stripe.com/docs/api/capital/financing_summary) will only return `details` for `paid_out` financing.
sig { returns(T.nilable(String)) }
attr_reader :status
end
end
end
# typed: true
module Stripe
module Capital
# This is an object representing the details of a transaction on a Capital financing object.
class FinancingTransaction < APIResource
class Details < Stripe::StripeObject
class Transaction < Stripe::StripeObject
# The linked payment ID.
sig { returns(String) }
attr_reader :charge
# The linked Treasury Financing Transaction ID.
sig { returns(String) }
attr_reader :treasury_transaction
end
# The advance amount being repaid, paid out, or reversed in minor units.
sig { returns(Integer) }
attr_reader :advance_amount
# The currency of the financing transaction.
sig { returns(String) }
attr_reader :currency
# The fee amount being repaid, paid out, or reversed in minor units.
sig { returns(Integer) }
attr_reader :fee_amount
# The linked payment for the transaction. This field only applies to financing transactions of type `paydown` and reason `automatic_withholding`.
sig { returns(String) }
attr_reader :linked_payment
# The reason for the financing transaction (if applicable).
sig { returns(String) }
attr_reader :reason
# The reversed transaction. This field only applies to financing
# transactions of type `reversal`.
sig { returns(String) }
attr_reader :reversed_transaction
# The advance and fee amount being repaid, paid out, or reversed in minor units.
sig { returns(Integer) }
attr_reader :total_amount
# This is an object representing a linked transaction on a Capital Financing Transaction.
sig { returns(Transaction) }
attr_reader :transaction
end
# The ID of the merchant associated with this financing transaction.
sig { returns(String) }
attr_reader :account
# Time at which the financing transaction was created. Given in seconds since unix epoch.
sig { returns(Integer) }
attr_reader :created_at
# This is an object representing a transaction on a Capital financing offer.
sig { returns(Details) }
attr_reader :details
# The Capital financing offer for this financing transaction.
sig { returns(T.nilable(String)) }
attr_reader :financing_offer
# A unique identifier for the financing transaction object.
sig { returns(String) }
attr_reader :id
# The Capital transaction object that predates the Financing Transactions API and
# corresponds with the balance transaction that was created as a result of this
# financing transaction.
sig { returns(String) }
attr_reader :legacy_balance_transaction_source
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# The object type: financing_transaction
sig { returns(String) }
attr_reader :object
# The type of the financing transaction.
sig { returns(String) }
attr_reader :type
# A human-friendly description of the financing transaction.
sig { returns(T.nilable(String)) }
attr_reader :user_facing_description
class ListParams < Stripe::RequestParams
# For transactions of type `paydown` and reason `automatic_withholding` only, only returns transactions that were created as a result of this charge.
sig { returns(T.nilable(String)) }
attr_accessor :charge
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Returns transactions that were created that apply to this financing offer ID.
sig { returns(T.nilable(String)) }
attr_accessor :financing_offer
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Only returns transactions that are responsible for reversing this financing transaction ID.
sig { returns(T.nilable(String)) }
attr_accessor :reversed_transaction
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# For transactions of type `paydown` and reason `automatic_withholding` only, only returns transactions that were created as a result of this Treasury Transaction.
sig { returns(T.nilable(String)) }
attr_accessor :treasury_transaction
sig {
params(charge: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), financing_offer: T.nilable(String), limit: T.nilable(Integer), reversed_transaction: T.nilable(String), starting_after: T.nilable(String), treasury_transaction: T.nilable(String)).void
}
def initialize(
charge: nil,
ending_before: nil,
expand: nil,
financing_offer: nil,
limit: nil,
reversed_transaction: nil,
starting_after: nil,
treasury_transaction: nil
); end
end
# Returns a list of financing transactions. The transactions are returned in sorted order,
# with the most recent transactions appearing first.
sig {
params(params: T.any(::Stripe::Capital::FinancingTransaction::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
# You can store multiple cards on a customer in order to charge the customer
# later. You can also store multiple debit cards on a recipient in order to
# transfer to those cards later.
#
# Related guide: [Card payments with Sources](https://stripe.com/docs/sources/cards)
class Card < APIResource
class Networks < Stripe::StripeObject
# The preferred network for co-branded cards. Can be `cartes_bancaires`, `mastercard`, `visa` or `invalid_preference` if requested network is not valid for the card.
sig { returns(T.nilable(String)) }
attr_reader :preferred
end
# Attribute for field account
sig { returns(T.nilable(T.any(String, Stripe::Account))) }
attr_reader :account
# City/District/Suburb/Town/Village.
sig { returns(T.nilable(String)) }
attr_reader :address_city
# Billing address country, if provided when creating card.
sig { returns(T.nilable(String)) }
attr_reader :address_country
# Address line 1 (Street address/PO Box/Company name).
sig { returns(T.nilable(String)) }
attr_reader :address_line1
# If `address_line1` was provided, results of the check: `pass`, `fail`, `unavailable`, or `unchecked`.
sig { returns(T.nilable(String)) }
attr_reader :address_line1_check
# Address line 2 (Apartment/Suite/Unit/Building).
sig { returns(T.nilable(String)) }
attr_reader :address_line2
# State/County/Province/Region.
sig { returns(T.nilable(String)) }
attr_reader :address_state
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :address_zip
# If `address_zip` was provided, results of the check: `pass`, `fail`, `unavailable`, or `unchecked`.
sig { returns(T.nilable(String)) }
attr_reader :address_zip_check
# This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to “unspecified”.
sig { returns(T.nilable(String)) }
attr_reader :allow_redisplay
# A set of available payout methods for this card. Only values from this set should be passed as the `method` when creating a payout.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :available_payout_methods
# Card brand. Can be `American Express`, `Diners Club`, `Discover`, `Eftpos Australia`, `Girocard`, `JCB`, `MasterCard`, `UnionPay`, `Visa`, or `Unknown`.
sig { returns(String) }
attr_reader :brand
# The [product code](https://stripe.com/docs/card-product-codes) that identifies the specific program or product associated with a card. (For internal use only and not typically available in standard API requests.)
sig { returns(T.nilable(String)) }
attr_reader :brand_product
# 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.
sig { returns(T.nilable(String)) }
attr_reader :country
# Three-letter [ISO code for currency](https://www.iso.org/iso-4217-currency-codes.html) in lowercase. Must be a [supported currency](https://docs.stripe.com/currencies). Only applicable on accounts (not customers or recipients). The card can be used as a transfer destination for funds in this currency. This property is only available when returned as an [External Account](/api/external_account_cards/object) where [controller.is_controller](/api/accounts/object#account_object-controller-is_controller) is `true`.
sig { returns(T.nilable(String)) }
attr_reader :currency
# The customer that this card belongs to. This attribute will not be in the card object if the card belongs to an account or recipient instead.
sig { returns(T.nilable(T.any(String, Stripe::Customer))) }
attr_reader :customer
# If a CVC was provided, results of the check: `pass`, `fail`, `unavailable`, or `unchecked`. A result of unchecked indicates that CVC was provided but hasn't been checked yet. Checks are typically performed when attaching a card to a Customer object, or when creating a charge. For more details, see [Check if a card is valid without a charge](https://support.stripe.com/questions/check-if-a-card-is-valid-without-a-charge).
sig { returns(T.nilable(String)) }
attr_reader :cvc_check
# Whether this card is the default external account for its currency. This property is only available for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :default_for_currency
# 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.)
sig { returns(String) }
attr_reader :description
# (For tokenized numbers only.) The last four digits of the device account number.
sig { returns(T.nilable(String)) }
attr_reader :dynamic_last4
# Two-digit number representing the card's expiration month.
sig { returns(Integer) }
attr_reader :exp_month
# Four-digit number representing the card's expiration year.
sig { returns(Integer) }
attr_reader :exp_year
# Uniquely identifies this particular card number. You can use this attribute to check whether two customers who’ve signed up with you are using the same card number, for example. For payment methods that tokenize card information (Apple Pay, Google Pay), the tokenized number might be provided instead of the underlying card number.
#
# *As of May 1, 2021, card fingerprint in India for Connect changed to allow two fingerprints for the same card---one for India and one for the rest of the world.*
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Card funding type. Can be `credit`, `debit`, `prepaid`, or `unknown`.
sig { returns(String) }
attr_reader :funding
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Issuer identification number of the card. (For internal use only and not typically available in standard API requests.)
sig { returns(String) }
attr_reader :iin
# The name of the card's issuing bank. (For internal use only and not typically available in standard API requests.)
sig { returns(String) }
attr_reader :issuer
# The last four digits of the card.
sig { returns(String) }
attr_reader :last4
# 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.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# Cardholder name.
sig { returns(T.nilable(String)) }
attr_reader :name
# Attribute for field networks
sig { returns(Networks) }
attr_reader :networks
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Status of a card based on the card issuer.
sig { returns(T.nilable(String)) }
attr_reader :regulated_status
# For external accounts that are cards, possible values are `new` and `errored`. If a payout fails, the status is set to `errored` and [scheduled payouts](https://stripe.com/docs/payouts#payout-schedule) are stopped until account details are updated.
sig { returns(T.nilable(String)) }
attr_reader :status
# If the card number is tokenized, this is the method that was used. Can be `android_pay` (includes Google Pay), `apple_pay`, `masterpass`, `visa_checkout`, or null.
sig { returns(T.nilable(String)) }
attr_reader :tokenization_method
# Always true for a deleted object
sig { returns(T::Boolean) }
attr_reader :deleted
end
end
# typed: true
module Stripe
# A customer's `Cash balance` represents real funds. Customers can add funds to their cash balance by sending a bank transfer. These funds can be used for payment and can eventually be paid out to your bank account.
class CashBalance < APIResource
class Settings < Stripe::StripeObject
# The configuration for how funds that land in the customer cash balance are reconciled.
sig { returns(String) }
attr_reader :reconciliation_mode
# A flag to indicate if reconciliation mode returned is the user's default or is specific to this customer cash balance
sig { returns(T::Boolean) }
attr_reader :using_merchant_default
end
# A hash of all cash balances available to this customer. You cannot delete a customer with any cash balances, even if the balance is 0. Amounts are represented in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(T.nilable(T::Hash[String, Integer])) }
attr_reader :available
# The ID of the customer whose cash balance this object represents.
sig { returns(String) }
attr_reader :customer
# The ID of the account whose cash balance this object represents.
sig { returns(T.nilable(String)) }
attr_reader :customer_account
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Attribute for field settings
sig { returns(Settings) }
attr_reader :settings
end
end
# typed: true
module Stripe
# The `Charge` object represents a single attempt to move money into your Stripe account.
# PaymentIntent confirmation is the most common way to create Charges, but transferring
# money to a different Stripe account through Connect also creates Charges.
# Some legacy payment flows create Charges directly, which is not recommended for new integrations.
class Charge < APIResource
class BillingDetails < Stripe::StripeObject
class Address < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Billing address.
sig { returns(T.nilable(Address)) }
attr_reader :address
# Email address.
sig { returns(T.nilable(String)) }
attr_reader :email
# Full name.
sig { returns(T.nilable(String)) }
attr_reader :name
# Billing phone number (including extension).
sig { returns(T.nilable(String)) }
attr_reader :phone
# Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
sig { returns(T.nilable(String)) }
attr_reader :tax_id
end
class FraudDetails < Stripe::StripeObject
# Assessments from Stripe. If set, the value is `fraudulent`.
sig { returns(String) }
attr_reader :stripe_report
# Assessments reported by you. If set, possible values of are `safe` and `fraudulent`.
sig { returns(String) }
attr_reader :user_report
end
class Level3 < Stripe::StripeObject
class LineItem < Stripe::StripeObject
# Attribute for field discount_amount
sig { returns(T.nilable(Integer)) }
attr_reader :discount_amount
# Attribute for field product_code
sig { returns(String) }
attr_reader :product_code
# Attribute for field product_description
sig { returns(String) }
attr_reader :product_description
# Attribute for field quantity
sig { returns(T.nilable(Integer)) }
attr_reader :quantity
# Attribute for field tax_amount
sig { returns(T.nilable(Integer)) }
attr_reader :tax_amount
# Attribute for field unit_cost
sig { returns(T.nilable(Integer)) }
attr_reader :unit_cost
end
# Attribute for field customer_reference
sig { returns(String) }
attr_reader :customer_reference
# Attribute for field line_items
sig { returns(T::Array[LineItem]) }
attr_reader :line_items
# Attribute for field merchant_reference
sig { returns(String) }
attr_reader :merchant_reference
# Attribute for field shipping_address_zip
sig { returns(String) }
attr_reader :shipping_address_zip
# Attribute for field shipping_amount
sig { returns(Integer) }
attr_reader :shipping_amount
# Attribute for field shipping_from_zip
sig { returns(String) }
attr_reader :shipping_from_zip
end
class Outcome < Stripe::StripeObject
class Rule < Stripe::StripeObject
# The action taken on the payment.
sig { returns(String) }
attr_reader :action
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# The predicate to evaluate the payment against.
sig { returns(String) }
attr_reader :predicate
end
# An enumerated value providing a more detailed explanation on [how to proceed with an error](https://stripe.com/docs/declines#retrying-issuer-declines).
sig { returns(T.nilable(String)) }
attr_reader :advice_code
# For charges declined by the network, a 2 digit code which indicates the advice returned by the network on how to proceed with an error.
sig { returns(T.nilable(String)) }
attr_reader :network_advice_code
# For charges declined by the network, a brand specific 2, 3, or 4 digit code which indicates the reason the authorization failed.
sig { returns(T.nilable(String)) }
attr_reader :network_decline_code
# Possible values are `approved_by_network`, `declined_by_network`, `not_sent_to_network`, and `reversed_after_approval`. The value `reversed_after_approval` indicates the payment was [blocked by Stripe](https://stripe.com/docs/declines#blocked-payments) after bank authorization, and may temporarily appear as "pending" on a cardholder's statement.
sig { returns(T.nilable(String)) }
attr_reader :network_status
# An enumerated value providing a more detailed explanation of the outcome's `type`. Charges blocked by Radar's default block rule have the value `highest_risk_level`. Charges placed in review by Radar's default review rule have the value `elevated_risk_level`. Charges authorized, blocked, or placed in review by custom rules have the value `rule`. See [understanding declines](https://stripe.com/docs/declines) for more details.
sig { returns(T.nilable(String)) }
attr_reader :reason
# Stripe Radar's evaluation of the riskiness of the payment. Possible values for evaluated payments are `normal`, `elevated`, `highest`. For non-card payments, and card-based payments predating the public assignment of risk levels, this field will have the value `not_assessed`. In the event of an error in the evaluation, this field will have the value `unknown`. This field is only available with Radar.
sig { returns(String) }
attr_reader :risk_level
# Stripe Radar's evaluation of the riskiness of the payment. Possible values for evaluated payments are between 0 and 100. For non-card payments, card-based payments predating the public assignment of risk scores, or in the event of an error during evaluation, this field will not be present. This field is only available with Radar for Fraud Teams.
sig { returns(Integer) }
attr_reader :risk_score
# The ID of the Radar rule that matched the payment, if applicable.
sig { returns(T.any(String, Rule)) }
attr_reader :rule
# A human-readable description of the outcome type and reason, designed for you (the recipient of the payment), not your customer.
sig { returns(T.nilable(String)) }
attr_reader :seller_message
# Possible values are `authorized`, `manual_review`, `issuer_declined`, `blocked`, and `invalid`. See [understanding declines](https://stripe.com/docs/declines) and [Radar reviews](https://stripe.com/docs/radar/reviews) for details.
sig { returns(String) }
attr_reader :type
end
class PaymentMethodDetails < Stripe::StripeObject
class AchCreditTransfer < Stripe::StripeObject
# Account number to transfer funds to.
sig { returns(T.nilable(String)) }
attr_reader :account_number
# Name of the bank associated with the routing number.
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# Routing transit number for the bank account to transfer funds to.
sig { returns(T.nilable(String)) }
attr_reader :routing_number
# SWIFT code of the bank associated with the routing number.
sig { returns(T.nilable(String)) }
attr_reader :swift_code
end
class AchDebit < Stripe::StripeObject
# Type of entity that holds the account. This can be either `individual` or `company`.
sig { returns(T.nilable(String)) }
attr_reader :account_holder_type
# Name of the bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# Two-letter ISO code representing the country the bank account is located in.
sig { returns(T.nilable(String)) }
attr_reader :country
# Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Last four digits of the bank account number.
sig { returns(T.nilable(String)) }
attr_reader :last4
# Routing transit number of the bank account.
sig { returns(T.nilable(String)) }
attr_reader :routing_number
end
class AcssDebit < Stripe::StripeObject
# Name of the bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Institution number of the bank account
sig { returns(T.nilable(String)) }
attr_reader :institution_number
# Last four digits of the bank account number.
sig { returns(T.nilable(String)) }
attr_reader :last4
# ID of the mandate used to make this payment.
sig { returns(String) }
attr_reader :mandate
# Transit number of the bank account.
sig { returns(T.nilable(String)) }
attr_reader :transit_number
end
class Affirm < Stripe::StripeObject
# ID of the [location](https://stripe.com/docs/api/terminal/locations) that this transaction's reader is assigned to.
sig { returns(String) }
attr_reader :location
# ID of the [reader](https://stripe.com/docs/api/terminal/readers) this transaction was made on.
sig { returns(String) }
attr_reader :reader
# The Affirm transaction ID associated with this payment.
sig { returns(T.nilable(String)) }
attr_reader :transaction_id
end
class AfterpayClearpay < Stripe::StripeObject
# The Afterpay order ID associated with this payment intent.
sig { returns(T.nilable(String)) }
attr_reader :order_id
# Order identifier shown to the merchant in Afterpay’s online portal.
sig { returns(T.nilable(String)) }
attr_reader :reference
end
class Alipay < Stripe::StripeObject
# Uniquely identifies this particular Alipay account. You can use this attribute to check whether two Alipay accounts are the same.
sig { returns(String) }
attr_reader :buyer_id
# Uniquely identifies this particular Alipay account. You can use this attribute to check whether two Alipay accounts are the same.
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Transaction ID of this particular Alipay transaction.
sig { returns(T.nilable(String)) }
attr_reader :transaction_id
end
class Alma < Stripe::StripeObject; end
class AmazonPay < Stripe::StripeObject
class Funding < Stripe::StripeObject
class Card < Stripe::StripeObject
# Card brand. Can be `amex`, `diners`, `discover`, `eftpos_au`, `jcb`, `link`, `mastercard`, `unionpay`, `visa`, or `unknown`.
sig { returns(T.nilable(String)) }
attr_reader :brand
# The [product code](https://stripe.com/docs/card-product-codes) that identifies the specific program or product associated with a card. (For internal use only and not typically available in standard API requests.)
sig { returns(T.nilable(String)) }
attr_reader :brand_product
# 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.
sig { returns(T.nilable(String)) }
attr_reader :country
# Two-digit number representing the card's expiration month.
sig { returns(T.nilable(Integer)) }
attr_reader :exp_month
# Four-digit number representing the card's expiration year.
sig { returns(T.nilable(Integer)) }
attr_reader :exp_year
# Card funding type. Can be `credit`, `debit`, `prepaid`, or `unknown`.
sig { returns(T.nilable(String)) }
attr_reader :funding
# The last four digits of the card.
sig { returns(T.nilable(String)) }
attr_reader :last4
end
# Attribute for field card
sig { returns(Card) }
attr_reader :card
# funding type of the underlying payment method.
sig { returns(T.nilable(String)) }
attr_reader :type
end
# Attribute for field funding
sig { returns(Funding) }
attr_reader :funding
end
class AuBecsDebit < Stripe::StripeObject
# Bank-State-Branch number of the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bsb_number
# Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Last four digits of the bank account number.
sig { returns(T.nilable(String)) }
attr_reader :last4
# ID of the mandate used to make this payment.
sig { returns(String) }
attr_reader :mandate
end
class BacsDebit < Stripe::StripeObject
# Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Last four digits of the bank account number.
sig { returns(T.nilable(String)) }
attr_reader :last4
# ID of the mandate used to make this payment.
sig { returns(T.nilable(String)) }
attr_reader :mandate
# Sort code of the bank account. (e.g., `10-20-30`)
sig { returns(T.nilable(String)) }
attr_reader :sort_code
end
class Bancontact < Stripe::StripeObject
# Bank code of bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_code
# Name of the bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# Bank Identifier Code of the bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bic
# The ID of the SEPA Direct Debit PaymentMethod which was generated by this Charge.
sig { returns(T.nilable(T.any(String, Stripe::PaymentMethod))) }
attr_reader :generated_sepa_debit
# The mandate for the SEPA Direct Debit PaymentMethod which was generated by this Charge.
sig { returns(T.nilable(T.any(String, Stripe::Mandate))) }
attr_reader :generated_sepa_debit_mandate
# Last four characters of the IBAN.
sig { returns(T.nilable(String)) }
attr_reader :iban_last4
# Preferred language of the Bancontact authorization page that the customer is redirected to.
# Can be one of `en`, `de`, `fr`, or `nl`
sig { returns(T.nilable(String)) }
attr_reader :preferred_language
# Owner's verified full name. Values are verified or provided by Bancontact directly
# (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(String)) }
attr_reader :verified_name
end
class Billie < Stripe::StripeObject; end
class Blik < Stripe::StripeObject
# A unique and immutable identifier assigned by BLIK to every buyer.
sig { returns(T.nilable(String)) }
attr_reader :buyer_id
end
class Boleto < Stripe::StripeObject
# The tax ID of the customer (CPF for individuals consumers or CNPJ for businesses consumers)
sig { returns(String) }
attr_reader :tax_id
end
class Card < Stripe::StripeObject
class Checks < Stripe::StripeObject
# If a address line1 was provided, results of the check, one of `pass`, `fail`, `unavailable`, or `unchecked`.
sig { returns(T.nilable(String)) }
attr_reader :address_line1_check
# If a address postal code was provided, results of the check, one of `pass`, `fail`, `unavailable`, or `unchecked`.
sig { returns(T.nilable(String)) }
attr_reader :address_postal_code_check
# If a CVC was provided, results of the check, one of `pass`, `fail`, `unavailable`, or `unchecked`.
sig { returns(T.nilable(String)) }
attr_reader :cvc_check
end
class DecrementalAuthorization < Stripe::StripeObject
# Indicates whether or not the decremental authorization feature is supported.
sig { returns(String) }
attr_reader :status
end
class ExtendedAuthorization < Stripe::StripeObject
# Indicates whether or not the capture window is extended beyond the standard authorization.
sig { returns(String) }
attr_reader :status
end
class IncrementalAuthorization < Stripe::StripeObject
# Indicates whether or not the incremental authorization feature is supported.
sig { returns(String) }
attr_reader :status
end
class Installments < Stripe::StripeObject
class Plan < Stripe::StripeObject
# For `fixed_count` installment plans, this is the number of installment payments your customer will make to their credit card.
sig { returns(T.nilable(Integer)) }
attr_reader :count
# For `fixed_count` installment plans, this is the interval between installment payments your customer will make to their credit card.
# One of `month`.
sig { returns(T.nilable(String)) }
attr_reader :interval
# Type of installment plan, one of `fixed_count`.
sig { returns(String) }
attr_reader :type
end
# Installment plan selected for the payment.
sig { returns(T.nilable(Plan)) }
attr_reader :plan
end
class Multicapture < Stripe::StripeObject
# Indicates whether or not multiple captures are supported.
sig { returns(String) }
attr_reader :status
end
class NetworkToken < Stripe::StripeObject
# Indicates if Stripe used a network token, either user provided or Stripe managed when processing the transaction.
sig { returns(T::Boolean) }
attr_reader :used
end
class Overcapture < Stripe::StripeObject
# The maximum amount that can be captured.
sig { returns(Integer) }
attr_reader :maximum_amount_capturable
# Indicates whether or not the authorized amount can be over-captured.
sig { returns(String) }
attr_reader :status
end
class PartialAuthorization < Stripe::StripeObject
# Indicates whether the transaction requested for partial authorization feature and the authorization outcome.
sig { returns(String) }
attr_reader :status
end
class ThreeDSecure < Stripe::StripeObject
# For authenticated transactions: how the customer was authenticated by
# the issuing bank.
sig { returns(T.nilable(String)) }
attr_reader :authentication_flow
# The Electronic Commerce Indicator (ECI). A protocol-level field
# indicating what degree of authentication was performed.
sig { returns(T.nilable(String)) }
attr_reader :electronic_commerce_indicator
# The exemption requested via 3DS and accepted by the issuer at authentication time.
sig { returns(T.nilable(String)) }
attr_reader :exemption_indicator
# Whether Stripe requested the value of `exemption_indicator` in the transaction. This will depend on
# the outcome of Stripe's internal risk assessment.
sig { returns(T::Boolean) }
attr_reader :exemption_indicator_applied
# Indicates the outcome of 3D Secure authentication.
sig { returns(T.nilable(String)) }
attr_reader :result
# Additional information about why 3D Secure succeeded or failed based
# on the `result`.
sig { returns(T.nilable(String)) }
attr_reader :result_reason
# The 3D Secure 1 XID or 3D Secure 2 Directory Server Transaction ID
# (dsTransId) for this payment.
sig { returns(T.nilable(String)) }
attr_reader :transaction_id
# The version of 3D Secure that was used.
sig { returns(T.nilable(String)) }
attr_reader :version
end
class Wallet < Stripe::StripeObject
class AmexExpressCheckout < Stripe::StripeObject; end
class ApplePay < Stripe::StripeObject; end
class GooglePay < Stripe::StripeObject; end
class Link < Stripe::StripeObject; end
class Masterpass < Stripe::StripeObject
class BillingAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
class ShippingAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Owner's verified billing address. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(BillingAddress)) }
attr_reader :billing_address
# Owner's verified email. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(String)) }
attr_reader :email
# Owner's verified full name. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(String)) }
attr_reader :name
# Owner's verified shipping address. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(ShippingAddress)) }
attr_reader :shipping_address
end
class SamsungPay < Stripe::StripeObject; end
class VisaCheckout < Stripe::StripeObject
class BillingAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
class ShippingAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Owner's verified billing address. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(BillingAddress)) }
attr_reader :billing_address
# Owner's verified email. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(String)) }
attr_reader :email
# Owner's verified full name. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(String)) }
attr_reader :name
# Owner's verified shipping address. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(ShippingAddress)) }
attr_reader :shipping_address
end
# Attribute for field amex_express_checkout
sig { returns(AmexExpressCheckout) }
attr_reader :amex_express_checkout
# Attribute for field apple_pay
sig { returns(ApplePay) }
attr_reader :apple_pay
# (For tokenized numbers only.) The last four digits of the device account number.
sig { returns(T.nilable(String)) }
attr_reader :dynamic_last4
# Attribute for field google_pay
sig { returns(GooglePay) }
attr_reader :google_pay
# Attribute for field link
sig { returns(Link) }
attr_reader :link
# Attribute for field masterpass
sig { returns(Masterpass) }
attr_reader :masterpass
# Attribute for field samsung_pay
sig { returns(SamsungPay) }
attr_reader :samsung_pay
# The type of the card wallet, one of `amex_express_checkout`, `apple_pay`, `google_pay`, `masterpass`, `samsung_pay`, `visa_checkout`, or `link`. An additional hash is included on the Wallet subhash with a name matching this value. It contains additional information specific to the card wallet type.
sig { returns(String) }
attr_reader :type
# Attribute for field visa_checkout
sig { returns(VisaCheckout) }
attr_reader :visa_checkout
end
# The authorized amount.
sig { returns(T.nilable(Integer)) }
attr_reader :amount_authorized
# The latest amount intended to be authorized by this charge.
sig { returns(T.nilable(Integer)) }
attr_reader :amount_requested
# Authorization code on the charge.
sig { returns(T.nilable(String)) }
attr_reader :authorization_code
# Card brand. Can be `amex`, `diners`, `discover`, `eftpos_au`, `jcb`, `link`, `mastercard`, `unionpay`, `visa`, or `unknown`.
sig { returns(T.nilable(String)) }
attr_reader :brand
# When using manual capture, a future timestamp at which the charge will be automatically refunded if uncaptured.
sig { returns(Integer) }
attr_reader :capture_before
# Check results by Card networks on Card address and CVC at time of payment.
sig { returns(T.nilable(Checks)) }
attr_reader :checks
# 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.
sig { returns(T.nilable(String)) }
attr_reader :country
# Attribute for field decremental_authorization
sig { returns(DecrementalAuthorization) }
attr_reader :decremental_authorization
# 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.)
sig { returns(T.nilable(String)) }
attr_reader :description
# Two-digit number representing the card's expiration month.
sig { returns(Integer) }
attr_reader :exp_month
# Four-digit number representing the card's expiration year.
sig { returns(Integer) }
attr_reader :exp_year
# Attribute for field extended_authorization
sig { returns(ExtendedAuthorization) }
attr_reader :extended_authorization
# Uniquely identifies this particular card number. You can use this attribute to check whether two customers who’ve signed up with you are using the same card number, for example. For payment methods that tokenize card information (Apple Pay, Google Pay), the tokenized number might be provided instead of the underlying card number.
#
# *As of May 1, 2021, card fingerprint in India for Connect changed to allow two fingerprints for the same card---one for India and one for the rest of the world.*
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Card funding type. Can be `credit`, `debit`, `prepaid`, or `unknown`.
sig { returns(T.nilable(String)) }
attr_reader :funding
# Issuer identification number of the card. (For internal use only and not typically available in standard API requests.)
sig { returns(T.nilable(String)) }
attr_reader :iin
# Attribute for field incremental_authorization
sig { returns(IncrementalAuthorization) }
attr_reader :incremental_authorization
# Installment details for this payment (Mexico only).
#
# For more information, see the [installments integration guide](https://stripe.com/docs/payments/installments).
sig { returns(T.nilable(Installments)) }
attr_reader :installments
# The name of the card's issuing bank. (For internal use only and not typically available in standard API requests.)
sig { returns(T.nilable(String)) }
attr_reader :issuer
# The last four digits of the card.
sig { returns(T.nilable(String)) }
attr_reader :last4
# ID of the mandate used to make this payment or created by it.
sig { returns(T.nilable(String)) }
attr_reader :mandate
# True if this payment was marked as MOTO and out of scope for SCA.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :moto
# Attribute for field multicapture
sig { returns(Multicapture) }
attr_reader :multicapture
# Identifies which network this charge was processed on. Can be `amex`, `cartes_bancaires`, `diners`, `discover`, `eftpos_au`, `interac`, `jcb`, `link`, `mastercard`, `unionpay`, `visa`, or `unknown`.
sig { returns(T.nilable(String)) }
attr_reader :network
# If this card has network token credentials, this contains the details of the network token credentials.
sig { returns(T.nilable(NetworkToken)) }
attr_reader :network_token
# This is used by the financial networks to identify a transaction. Visa calls this the Transaction ID, Mastercard calls this the Trace ID, and American Express calls this the Acquirer Reference Data. This value will be present if it is returned by the financial network in the authorization response, and null otherwise.
sig { returns(T.nilable(String)) }
attr_reader :network_transaction_id
# Attribute for field overcapture
sig { returns(Overcapture) }
attr_reader :overcapture
# Attribute for field partial_authorization
sig { returns(PartialAuthorization) }
attr_reader :partial_authorization
# Status of a card based on the card issuer.
sig { returns(T.nilable(String)) }
attr_reader :regulated_status
# Populated if this transaction used 3D Secure authentication.
sig { returns(T.nilable(ThreeDSecure)) }
attr_reader :three_d_secure
# If this Card is part of a card wallet, this contains the details of the card wallet.
sig { returns(T.nilable(Wallet)) }
attr_reader :wallet
end
class CardPresent < Stripe::StripeObject
class Offline < Stripe::StripeObject
# Time at which the payment was collected while offline
sig { returns(T.nilable(Integer)) }
attr_reader :stored_at
# The method used to process this payment method offline. Only deferred is allowed.
sig { returns(T.nilable(String)) }
attr_reader :type
end
class Receipt < Stripe::StripeObject
# The type of account being debited or credited
sig { returns(String) }
attr_reader :account_type
# EMV tag 9F26, cryptogram generated by the integrated circuit chip.
sig { returns(T.nilable(String)) }
attr_reader :application_cryptogram
# Mnenomic of the Application Identifier.
sig { returns(T.nilable(String)) }
attr_reader :application_preferred_name
# Identifier for this transaction.
sig { returns(T.nilable(String)) }
attr_reader :authorization_code
# EMV tag 8A. A code returned by the card issuer.
sig { returns(T.nilable(String)) }
attr_reader :authorization_response_code
# Describes the method used by the cardholder to verify ownership of the card. One of the following: `approval`, `failure`, `none`, `offline_pin`, `offline_pin_and_signature`, `online_pin`, or `signature`.
sig { returns(T.nilable(String)) }
attr_reader :cardholder_verification_method
# EMV tag 84. Similar to the application identifier stored on the integrated circuit chip.
sig { returns(T.nilable(String)) }
attr_reader :dedicated_file_name
# The outcome of a series of EMV functions performed by the card reader.
sig { returns(T.nilable(String)) }
attr_reader :terminal_verification_results
# An indication of various EMV functions performed during the transaction.
sig { returns(T.nilable(String)) }
attr_reader :transaction_status_information
end
class Wallet < Stripe::StripeObject
# The type of mobile wallet, one of `apple_pay`, `google_pay`, `samsung_pay`, or `unknown`.
sig { returns(String) }
attr_reader :type
end
# The authorized amount
sig { returns(T.nilable(Integer)) }
attr_reader :amount_authorized
# Card brand. Can be `amex`, `diners`, `discover`, `eftpos_au`, `jcb`, `link`, `mastercard`, `unionpay`, `visa`, or `unknown`.
sig { returns(T.nilable(String)) }
attr_reader :brand
# The [product code](https://stripe.com/docs/card-product-codes) that identifies the specific program or product associated with a card.
sig { returns(T.nilable(String)) }
attr_reader :brand_product
# When using manual capture, a future timestamp after which the charge will be automatically refunded if uncaptured.
sig { returns(Integer) }
attr_reader :capture_before
# The cardholder name as read from the card, in [ISO 7813](https://en.wikipedia.org/wiki/ISO/IEC_7813) format. May include alphanumeric characters, special characters and first/last name separator (`/`). In some cases, the cardholder name may not be available depending on how the issuer has configured the card. Cardholder name is typically not available on swipe or contactless payments, such as those made with Apple Pay and Google Pay.
sig { returns(T.nilable(String)) }
attr_reader :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.
sig { returns(T.nilable(String)) }
attr_reader :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.)
sig { returns(T.nilable(String)) }
attr_reader :description
# Authorization response cryptogram.
sig { returns(T.nilable(String)) }
attr_reader :emv_auth_data
# Two-digit number representing the card's expiration month.
sig { returns(Integer) }
attr_reader :exp_month
# Four-digit number representing the card's expiration year.
sig { returns(Integer) }
attr_reader :exp_year
# Uniquely identifies this particular card number. You can use this attribute to check whether two customers who’ve signed up with you are using the same card number, for example. For payment methods that tokenize card information (Apple Pay, Google Pay), the tokenized number might be provided instead of the underlying card number.
#
# *As of May 1, 2021, card fingerprint in India for Connect changed to allow two fingerprints for the same card---one for India and one for the rest of the world.*
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Card funding type. Can be `credit`, `debit`, `prepaid`, or `unknown`.
sig { returns(T.nilable(String)) }
attr_reader :funding
# ID of a card PaymentMethod generated from the card_present PaymentMethod that may be attached to a Customer for future transactions. Only present if it was possible to generate a card PaymentMethod.
sig { returns(T.nilable(String)) }
attr_reader :generated_card
# Issuer identification number of the card. (For internal use only and not typically available in standard API requests.)
sig { returns(T.nilable(String)) }
attr_reader :iin
# Whether this [PaymentIntent](https://stripe.com/docs/api/payment_intents) is eligible for incremental authorizations. Request support using [request_incremental_authorization_support](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-payment_method_options-card_present-request_incremental_authorization_support).
sig { returns(T::Boolean) }
attr_reader :incremental_authorization_supported
# The name of the card's issuing bank. (For internal use only and not typically available in standard API requests.)
sig { returns(T.nilable(String)) }
attr_reader :issuer
# The last four digits of the card.
sig { returns(T.nilable(String)) }
attr_reader :last4
# Identifies which network this charge was processed on. Can be `amex`, `cartes_bancaires`, `diners`, `discover`, `eftpos_au`, `interac`, `jcb`, `link`, `mastercard`, `unionpay`, `visa`, or `unknown`.
sig { returns(T.nilable(String)) }
attr_reader :network
# This is used by the financial networks to identify a transaction. Visa calls this the Transaction ID, Mastercard calls this the Trace ID, and American Express calls this the Acquirer Reference Data. This value will be present if it is returned by the financial network in the authorization response, and null otherwise.
sig { returns(T.nilable(String)) }
attr_reader :network_transaction_id
# Details about payments collected offline.
sig { returns(T.nilable(Offline)) }
attr_reader :offline
# Defines whether the authorized amount can be over-captured or not
sig { returns(T::Boolean) }
attr_reader :overcapture_supported
# EMV tag 5F2D. Preferred languages specified by the integrated circuit chip.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :preferred_locales
# How card details were read in this transaction.
sig { returns(T.nilable(String)) }
attr_reader :read_method
# A collection of fields required to be displayed on receipts. Only required for EMV transactions.
sig { returns(T.nilable(Receipt)) }
attr_reader :receipt
# Attribute for field wallet
sig { returns(Wallet) }
attr_reader :wallet
end
class Cashapp < Stripe::StripeObject
# A unique and immutable identifier assigned by Cash App to every buyer.
sig { returns(T.nilable(String)) }
attr_reader :buyer_id
# A public identifier for buyers using Cash App.
sig { returns(T.nilable(String)) }
attr_reader :cashtag
end
class CustomerBalance < Stripe::StripeObject; end
class Eps < Stripe::StripeObject
# The customer's bank. Should be one of `arzte_und_apotheker_bank`, `austrian_anadi_bank_ag`, `bank_austria`, `bankhaus_carl_spangler`, `bankhaus_schelhammer_und_schattera_ag`, `bawag_psk_ag`, `bks_bank_ag`, `brull_kallmus_bank_ag`, `btv_vier_lander_bank`, `capital_bank_grawe_gruppe_ag`, `deutsche_bank_ag`, `dolomitenbank`, `easybank_ag`, `erste_bank_und_sparkassen`, `hypo_alpeadriabank_international_ag`, `hypo_noe_lb_fur_niederosterreich_u_wien`, `hypo_oberosterreich_salzburg_steiermark`, `hypo_tirol_bank_ag`, `hypo_vorarlberg_bank_ag`, `hypo_bank_burgenland_aktiengesellschaft`, `marchfelder_bank`, `oberbank_ag`, `raiffeisen_bankengruppe_osterreich`, `schoellerbank_ag`, `sparda_bank_wien`, `volksbank_gruppe`, `volkskreditbank_ag`, or `vr_bank_braunau`.
sig { returns(T.nilable(String)) }
attr_reader :bank
# Owner's verified full name. Values are verified or provided by EPS directly
# (if supported) at the time of authorization or settlement. They cannot be set or mutated.
# EPS rarely provides this information so the attribute is usually empty.
sig { returns(T.nilable(String)) }
attr_reader :verified_name
end
class Fpx < Stripe::StripeObject
# Account holder type, if provided. Can be one of `individual` or `company`.
sig { returns(T.nilable(String)) }
attr_reader :account_holder_type
# The customer's bank. Can be one of `affin_bank`, `agrobank`, `alliance_bank`, `ambank`, `bank_islam`, `bank_muamalat`, `bank_rakyat`, `bsn`, `cimb`, `hong_leong_bank`, `hsbc`, `kfh`, `maybank2u`, `ocbc`, `public_bank`, `rhb`, `standard_chartered`, `uob`, `deutsche_bank`, `maybank2e`, `pb_enterprise`, or `bank_of_china`.
sig { returns(String) }
attr_reader :bank
# Unique transaction id generated by FPX for every request from the merchant
sig { returns(T.nilable(String)) }
attr_reader :transaction_id
end
class Giropay < Stripe::StripeObject
# Bank code of bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_code
# Name of the bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# Bank Identifier Code of the bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bic
# Owner's verified full name. Values are verified or provided by Giropay directly
# (if supported) at the time of authorization or settlement. They cannot be set or mutated.
# Giropay rarely provides this information so the attribute is usually empty.
sig { returns(T.nilable(String)) }
attr_reader :verified_name
end
class Gopay < Stripe::StripeObject; end
class Grabpay < Stripe::StripeObject
# Unique transaction id generated by GrabPay
sig { returns(T.nilable(String)) }
attr_reader :transaction_id
end
class IdBankTransfer < Stripe::StripeObject
# Account number of the bank account to transfer funds to.
sig { returns(String) }
attr_reader :account_number
# Bank where the account is located.
sig { returns(String) }
attr_reader :bank
# Local bank code of the bank.
sig { returns(String) }
attr_reader :bank_code
# Name of the bank associated with the bank account.
sig { returns(String) }
attr_reader :bank_name
# Merchant name and billing details name, for the customer to check for the correct merchant when performing the bank transfer.
sig { returns(String) }
attr_reader :display_name
end
class Ideal < Stripe::StripeObject
# The customer's bank. Can be one of `abn_amro`, `asn_bank`, `bunq`, `handelsbanken`, `ing`, `knab`, `moneyou`, `n26`, `nn`, `rabobank`, `regiobank`, `revolut`, `sns_bank`, `triodos_bank`, `van_lanschot`, or `yoursafe`.
sig { returns(T.nilable(String)) }
attr_reader :bank
# The Bank Identifier Code of the customer's bank.
sig { returns(T.nilable(String)) }
attr_reader :bic
# The ID of the SEPA Direct Debit PaymentMethod which was generated by this Charge.
sig { returns(T.nilable(T.any(String, Stripe::PaymentMethod))) }
attr_reader :generated_sepa_debit
# The mandate for the SEPA Direct Debit PaymentMethod which was generated by this Charge.
sig { returns(T.nilable(T.any(String, Stripe::Mandate))) }
attr_reader :generated_sepa_debit_mandate
# Last four characters of the IBAN.
sig { returns(T.nilable(String)) }
attr_reader :iban_last4
# Owner's verified full name. Values are verified or provided by iDEAL directly
# (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(String)) }
attr_reader :verified_name
end
class InteracPresent < Stripe::StripeObject
class Receipt < Stripe::StripeObject
# The type of account being debited or credited
sig { returns(String) }
attr_reader :account_type
# EMV tag 9F26, cryptogram generated by the integrated circuit chip.
sig { returns(T.nilable(String)) }
attr_reader :application_cryptogram
# Mnenomic of the Application Identifier.
sig { returns(T.nilable(String)) }
attr_reader :application_preferred_name
# Identifier for this transaction.
sig { returns(T.nilable(String)) }
attr_reader :authorization_code
# EMV tag 8A. A code returned by the card issuer.
sig { returns(T.nilable(String)) }
attr_reader :authorization_response_code
# Describes the method used by the cardholder to verify ownership of the card. One of the following: `approval`, `failure`, `none`, `offline_pin`, `offline_pin_and_signature`, `online_pin`, or `signature`.
sig { returns(T.nilable(String)) }
attr_reader :cardholder_verification_method
# EMV tag 84. Similar to the application identifier stored on the integrated circuit chip.
sig { returns(T.nilable(String)) }
attr_reader :dedicated_file_name
# The outcome of a series of EMV functions performed by the card reader.
sig { returns(T.nilable(String)) }
attr_reader :terminal_verification_results
# An indication of various EMV functions performed during the transaction.
sig { returns(T.nilable(String)) }
attr_reader :transaction_status_information
end
# Card brand. Can be `interac`, `mastercard` or `visa`.
sig { returns(T.nilable(String)) }
attr_reader :brand
# The cardholder name as read from the card, in [ISO 7813](https://en.wikipedia.org/wiki/ISO/IEC_7813) format. May include alphanumeric characters, special characters and first/last name separator (`/`). In some cases, the cardholder name may not be available depending on how the issuer has configured the card. Cardholder name is typically not available on swipe or contactless payments, such as those made with Apple Pay and Google Pay.
sig { returns(T.nilable(String)) }
attr_reader :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.
sig { returns(T.nilable(String)) }
attr_reader :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.)
sig { returns(T.nilable(String)) }
attr_reader :description
# Authorization response cryptogram.
sig { returns(T.nilable(String)) }
attr_reader :emv_auth_data
# Two-digit number representing the card's expiration month.
sig { returns(Integer) }
attr_reader :exp_month
# Four-digit number representing the card's expiration year.
sig { returns(Integer) }
attr_reader :exp_year
# Uniquely identifies this particular card number. You can use this attribute to check whether two customers who’ve signed up with you are using the same card number, for example. For payment methods that tokenize card information (Apple Pay, Google Pay), the tokenized number might be provided instead of the underlying card number.
#
# *As of May 1, 2021, card fingerprint in India for Connect changed to allow two fingerprints for the same card---one for India and one for the rest of the world.*
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Card funding type. Can be `credit`, `debit`, `prepaid`, or `unknown`.
sig { returns(T.nilable(String)) }
attr_reader :funding
# ID of a card PaymentMethod generated from the card_present PaymentMethod that may be attached to a Customer for future transactions. Only present if it was possible to generate a card PaymentMethod.
sig { returns(T.nilable(String)) }
attr_reader :generated_card
# Issuer identification number of the card. (For internal use only and not typically available in standard API requests.)
sig { returns(T.nilable(String)) }
attr_reader :iin
# The name of the card's issuing bank. (For internal use only and not typically available in standard API requests.)
sig { returns(T.nilable(String)) }
attr_reader :issuer
# The last four digits of the card.
sig { returns(T.nilable(String)) }
attr_reader :last4
# Identifies which network this charge was processed on. Can be `amex`, `cartes_bancaires`, `diners`, `discover`, `eftpos_au`, `interac`, `jcb`, `link`, `mastercard`, `unionpay`, `visa`, or `unknown`.
sig { returns(T.nilable(String)) }
attr_reader :network
# This is used by the financial networks to identify a transaction. Visa calls this the Transaction ID, Mastercard calls this the Trace ID, and American Express calls this the Acquirer Reference Data. This value will be present if it is returned by the financial network in the authorization response, and null otherwise.
sig { returns(T.nilable(String)) }
attr_reader :network_transaction_id
# EMV tag 5F2D. Preferred languages specified by the integrated circuit chip.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :preferred_locales
# How card details were read in this transaction.
sig { returns(T.nilable(String)) }
attr_reader :read_method
# A collection of fields required to be displayed on receipts. Only required for EMV transactions.
sig { returns(T.nilable(Receipt)) }
attr_reader :receipt
end
class KakaoPay < Stripe::StripeObject
# A unique identifier for the buyer as determined by the local payment processor.
sig { returns(T.nilable(String)) }
attr_reader :buyer_id
end
class Klarna < Stripe::StripeObject
class PayerDetails < Stripe::StripeObject
class Address < Stripe::StripeObject
# The payer address country
sig { returns(T.nilable(String)) }
attr_reader :country
end
# The payer's address
sig { returns(T.nilable(Address)) }
attr_reader :address
end
# The payer details for this transaction.
sig { returns(T.nilable(PayerDetails)) }
attr_reader :payer_details
# The Klarna payment method used for this transaction.
# Can be one of `pay_later`, `pay_now`, `pay_with_financing`, or `pay_in_installments`
sig { returns(T.nilable(String)) }
attr_reader :payment_method_category
# Preferred language of the Klarna authorization page that the customer is redirected to.
# Can be one of `de-AT`, `en-AT`, `nl-BE`, `fr-BE`, `en-BE`, `de-DE`, `en-DE`, `da-DK`, `en-DK`, `es-ES`, `en-ES`, `fi-FI`, `sv-FI`, `en-FI`, `en-GB`, `en-IE`, `it-IT`, `en-IT`, `nl-NL`, `en-NL`, `nb-NO`, `en-NO`, `sv-SE`, `en-SE`, `en-US`, `es-US`, `fr-FR`, `en-FR`, `cs-CZ`, `en-CZ`, `ro-RO`, `en-RO`, `el-GR`, `en-GR`, `en-AU`, `en-NZ`, `en-CA`, `fr-CA`, `pl-PL`, `en-PL`, `pt-PT`, `en-PT`, `de-CH`, `fr-CH`, `it-CH`, or `en-CH`
sig { returns(T.nilable(String)) }
attr_reader :preferred_locale
end
class Konbini < Stripe::StripeObject
class Store < Stripe::StripeObject
# The name of the convenience store chain where the payment was completed.
sig { returns(T.nilable(String)) }
attr_reader :chain
end
# If the payment succeeded, this contains the details of the convenience store where the payment was completed.
sig { returns(T.nilable(Store)) }
attr_reader :store
end
class KrCard < Stripe::StripeObject
# The local credit or debit card brand.
sig { returns(T.nilable(String)) }
attr_reader :brand
# A unique identifier for the buyer as determined by the local payment processor.
sig { returns(T.nilable(String)) }
attr_reader :buyer_id
# The last four digits of the card. This may not be present for American Express cards.
sig { returns(T.nilable(String)) }
attr_reader :last4
end
class Link < Stripe::StripeObject
# Two-letter ISO code representing the funding source country beneath the Link payment.
# You could use this attribute to get a sense of international fees.
sig { returns(T.nilable(String)) }
attr_reader :country
end
class MbWay < Stripe::StripeObject; end
class Mobilepay < Stripe::StripeObject
class Card < Stripe::StripeObject
# Brand of the card used in the transaction
sig { returns(T.nilable(String)) }
attr_reader :brand
# Two-letter ISO code representing the country of the card
sig { returns(T.nilable(String)) }
attr_reader :country
# Two digit number representing the card's expiration month
sig { returns(T.nilable(Integer)) }
attr_reader :exp_month
# Two digit number representing the card's expiration year
sig { returns(T.nilable(Integer)) }
attr_reader :exp_year
# The last 4 digits of the card
sig { returns(T.nilable(String)) }
attr_reader :last4
end
# Internal card details
sig { returns(T.nilable(Card)) }
attr_reader :card
end
class Multibanco < Stripe::StripeObject
# Entity number associated with this Multibanco payment.
sig { returns(T.nilable(String)) }
attr_reader :entity
# Reference number associated with this Multibanco payment.
sig { returns(T.nilable(String)) }
attr_reader :reference
end
class NaverPay < Stripe::StripeObject
# A unique identifier for the buyer as determined by the local payment processor.
sig { returns(T.nilable(String)) }
attr_reader :buyer_id
end
class NzBankAccount < Stripe::StripeObject
# The name on the bank account. Only present if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod’s billing details.
sig { returns(T.nilable(String)) }
attr_reader :account_holder_name
# The numeric code for the bank account's bank.
sig { returns(String) }
attr_reader :bank_code
# The name of the bank.
sig { returns(String) }
attr_reader :bank_name
# The numeric code for the bank account's bank branch.
sig { returns(String) }
attr_reader :branch_code
# Last four digits of the bank account number.
sig { returns(String) }
attr_reader :last4
# The suffix of the bank account number.
sig { returns(T.nilable(String)) }
attr_reader :suffix
end
class Oxxo < Stripe::StripeObject
# OXXO reference number
sig { returns(T.nilable(String)) }
attr_reader :number
end
class P24 < Stripe::StripeObject
# The customer's bank. Can be one of `ing`, `citi_handlowy`, `tmobile_usbugi_bankowe`, `plus_bank`, `etransfer_pocztowy24`, `banki_spbdzielcze`, `bank_nowy_bfg_sa`, `getin_bank`, `velobank`, `blik`, `noble_pay`, `ideabank`, `envelobank`, `santander_przelew24`, `nest_przelew`, `mbank_mtransfer`, `inteligo`, `pbac_z_ipko`, `bnp_paribas`, `credit_agricole`, `toyota_bank`, `bank_pekao_sa`, `volkswagen_bank`, `bank_millennium`, `alior_bank`, or `boz`.
sig { returns(T.nilable(String)) }
attr_reader :bank
# Unique reference for this Przelewy24 payment.
sig { returns(T.nilable(String)) }
attr_reader :reference
# Owner's verified full name. Values are verified or provided by Przelewy24 directly
# (if supported) at the time of authorization or settlement. They cannot be set or mutated.
# Przelewy24 rarely provides this information so the attribute is usually empty.
sig { returns(T.nilable(String)) }
attr_reader :verified_name
end
class PayByBank < Stripe::StripeObject; end
class Payco < Stripe::StripeObject
# A unique identifier for the buyer as determined by the local payment processor.
sig { returns(T.nilable(String)) }
attr_reader :buyer_id
end
class Paynow < Stripe::StripeObject
# Reference number associated with this PayNow payment
sig { returns(T.nilable(String)) }
attr_reader :reference
end
class Paypal < Stripe::StripeObject
class SellerProtection < Stripe::StripeObject
# An array of conditions that are covered for the transaction, if applicable.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :dispute_categories
# Indicates whether the transaction is eligible for PayPal's seller protection.
sig { returns(String) }
attr_reader :status
end
class Shipping < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
class VerifiedAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Two-letter ISO code representing the buyer's country. Values are provided by PayPal directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(String)) }
attr_reader :country
# Owner's email. Values are provided by PayPal directly
# (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(String)) }
attr_reader :payer_email
# PayPal account PayerID. This identifier uniquely identifies the PayPal customer.
sig { returns(T.nilable(String)) }
attr_reader :payer_id
# Owner's full name. Values provided by PayPal directly
# (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(String)) }
attr_reader :payer_name
# The level of protection offered as defined by PayPal Seller Protection for Merchants, for this transaction.
sig { returns(T.nilable(SellerProtection)) }
attr_reader :seller_protection
# The shipping address for the customer, as supplied by the merchant at the point of payment
# execution. This shipping address will not be updated if the merchant updates the shipping
# address on the PaymentIntent after the PaymentIntent was successfully confirmed.
sig { returns(T.nilable(Shipping)) }
attr_reader :shipping
# A unique ID generated by PayPal for this transaction.
sig { returns(T.nilable(String)) }
attr_reader :transaction_id
# The shipping address for the customer, as supplied by the merchant at the point of payment
# execution. This shipping address will not be updated if the merchant updates the shipping
# address on the PaymentIntent after the PaymentIntent was successfully confirmed.
sig { returns(T.nilable(VerifiedAddress)) }
attr_reader :verified_address
# Owner's verified email. Values are verified or provided by PayPal directly
# (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(String)) }
attr_reader :verified_email
# Owner's verified full name. Values are verified or provided by PayPal directly
# (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(String)) }
attr_reader :verified_name
end
class Payto < Stripe::StripeObject
# Bank-State-Branch number of the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bsb_number
# Last four digits of the bank account number.
sig { returns(T.nilable(String)) }
attr_reader :last4
# ID of the mandate used to make this payment.
sig { returns(String) }
attr_reader :mandate
# The PayID alias for the bank account.
sig { returns(T.nilable(String)) }
attr_reader :pay_id
end
class Pix < Stripe::StripeObject
# Unique transaction id generated by BCB
sig { returns(T.nilable(String)) }
attr_reader :bank_transaction_id
end
class Promptpay < Stripe::StripeObject
# Bill reference generated by PromptPay
sig { returns(T.nilable(String)) }
attr_reader :reference
end
class Qris < Stripe::StripeObject; end
class Rechnung < Stripe::StripeObject; end
class RevolutPay < Stripe::StripeObject
class Funding < Stripe::StripeObject
class Card < Stripe::StripeObject
# Card brand. Can be `amex`, `diners`, `discover`, `eftpos_au`, `jcb`, `link`, `mastercard`, `unionpay`, `visa`, or `unknown`.
sig { returns(T.nilable(String)) }
attr_reader :brand
# The [product code](https://stripe.com/docs/card-product-codes) that identifies the specific program or product associated with a card. (For internal use only and not typically available in standard API requests.)
sig { returns(T.nilable(String)) }
attr_reader :brand_product
# 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.
sig { returns(T.nilable(String)) }
attr_reader :country
# Two-digit number representing the card's expiration month.
sig { returns(T.nilable(Integer)) }
attr_reader :exp_month
# Four-digit number representing the card's expiration year.
sig { returns(T.nilable(Integer)) }
attr_reader :exp_year
# Card funding type. Can be `credit`, `debit`, `prepaid`, or `unknown`.
sig { returns(T.nilable(String)) }
attr_reader :funding
# The last four digits of the card.
sig { returns(T.nilable(String)) }
attr_reader :last4
end
# Attribute for field card
sig { returns(Card) }
attr_reader :card
# funding type of the underlying payment method.
sig { returns(T.nilable(String)) }
attr_reader :type
end
# Attribute for field funding
sig { returns(Funding) }
attr_reader :funding
end
class SamsungPay < Stripe::StripeObject
# A unique identifier for the buyer as determined by the local payment processor.
sig { returns(T.nilable(String)) }
attr_reader :buyer_id
end
class Satispay < Stripe::StripeObject; end
class SepaCreditTransfer < Stripe::StripeObject
# Name of the bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# Bank Identifier Code of the bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bic
# IBAN of the bank account to transfer funds to.
sig { returns(T.nilable(String)) }
attr_reader :iban
end
class SepaDebit < Stripe::StripeObject
# Bank code of bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_code
# Branch code of bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :branch_code
# Two-letter ISO code representing the country the bank account is located in.
sig { returns(T.nilable(String)) }
attr_reader :country
# Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Last four characters of the IBAN.
sig { returns(T.nilable(String)) }
attr_reader :last4
# Find the ID of the mandate used for this payment under the [payment_method_details.sepa_debit.mandate](https://stripe.com/docs/api/charges/object#charge_object-payment_method_details-sepa_debit-mandate) property on the Charge. Use this mandate ID to [retrieve the Mandate](https://stripe.com/docs/api/mandates/retrieve).
sig { returns(T.nilable(String)) }
attr_reader :mandate
end
class Shopeepay < Stripe::StripeObject; end
class Sofort < Stripe::StripeObject
# Bank code of bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_code
# Name of the bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# Bank Identifier Code of the bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bic
# Two-letter ISO code representing the country the bank account is located in.
sig { returns(T.nilable(String)) }
attr_reader :country
# The ID of the SEPA Direct Debit PaymentMethod which was generated by this Charge.
sig { returns(T.nilable(T.any(String, Stripe::PaymentMethod))) }
attr_reader :generated_sepa_debit
# The mandate for the SEPA Direct Debit PaymentMethod which was generated by this Charge.
sig { returns(T.nilable(T.any(String, Stripe::Mandate))) }
attr_reader :generated_sepa_debit_mandate
# Last four characters of the IBAN.
sig { returns(T.nilable(String)) }
attr_reader :iban_last4
# Preferred language of the SOFORT authorization page that the customer is redirected to.
# Can be one of `de`, `en`, `es`, `fr`, `it`, `nl`, or `pl`
sig { returns(T.nilable(String)) }
attr_reader :preferred_language
# Owner's verified full name. Values are verified or provided by SOFORT directly
# (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(String)) }
attr_reader :verified_name
end
class StripeAccount < Stripe::StripeObject; end
class StripeBalance < Stripe::StripeObject
# The connected account ID whose Stripe balance to use as the source of payment
sig { returns(T.nilable(String)) }
attr_reader :account
# The [source_type](https://docs.stripe.com/api/balance/balance_object#balance_object-available-source_types) of the balance
sig { returns(String) }
attr_reader :source_type
end
class Swish < Stripe::StripeObject
# Uniquely identifies the payer's Swish account. You can use this attribute to check whether two Swish transactions were paid for by the same payer
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Payer bank reference number for the payment
sig { returns(T.nilable(String)) }
attr_reader :payment_reference
# The last four digits of the Swish account phone number
sig { returns(T.nilable(String)) }
attr_reader :verified_phone_last4
end
class Twint < Stripe::StripeObject; end
class UsBankAccount < Stripe::StripeObject
# Account holder type: individual or company.
sig { returns(T.nilable(String)) }
attr_reader :account_holder_type
# Account type: checkings or savings. Defaults to checking if omitted.
sig { returns(T.nilable(String)) }
attr_reader :account_type
# Name of the bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Last four digits of the bank account number.
sig { returns(T.nilable(String)) }
attr_reader :last4
# ID of the mandate used to make this payment.
sig { returns(T.any(String, Stripe::Mandate)) }
attr_reader :mandate
# Reference number to locate ACH payments with customer's bank.
sig { returns(T.nilable(String)) }
attr_reader :payment_reference
# Routing number of the bank account.
sig { returns(T.nilable(String)) }
attr_reader :routing_number
end
class Wechat < Stripe::StripeObject; end
class WechatPay < Stripe::StripeObject
# Uniquely identifies this particular WeChat Pay account. You can use this attribute to check whether two WeChat accounts are the same.
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# ID of the [location](https://stripe.com/docs/api/terminal/locations) that this transaction's reader is assigned to.
sig { returns(String) }
attr_reader :location
# ID of the [reader](https://stripe.com/docs/api/terminal/readers) this transaction was made on.
sig { returns(String) }
attr_reader :reader
# Transaction ID of this particular WeChat Pay transaction.
sig { returns(T.nilable(String)) }
attr_reader :transaction_id
end
class Zip < Stripe::StripeObject; end
# Attribute for field ach_credit_transfer
sig { returns(AchCreditTransfer) }
attr_reader :ach_credit_transfer
# Attribute for field ach_debit
sig { returns(AchDebit) }
attr_reader :ach_debit
# Attribute for field acss_debit
sig { returns(AcssDebit) }
attr_reader :acss_debit
# Attribute for field affirm
sig { returns(Affirm) }
attr_reader :affirm
# Attribute for field afterpay_clearpay
sig { returns(AfterpayClearpay) }
attr_reader :afterpay_clearpay
# Attribute for field alipay
sig { returns(Alipay) }
attr_reader :alipay
# Attribute for field alma
sig { returns(Alma) }
attr_reader :alma
# Attribute for field amazon_pay
sig { returns(AmazonPay) }
attr_reader :amazon_pay
# Attribute for field au_becs_debit
sig { returns(AuBecsDebit) }
attr_reader :au_becs_debit
# Attribute for field bacs_debit
sig { returns(BacsDebit) }
attr_reader :bacs_debit
# Attribute for field bancontact
sig { returns(Bancontact) }
attr_reader :bancontact
# Attribute for field billie
sig { returns(Billie) }
attr_reader :billie
# Attribute for field blik
sig { returns(Blik) }
attr_reader :blik
# Attribute for field boleto
sig { returns(Boleto) }
attr_reader :boleto
# Attribute for field card
sig { returns(Card) }
attr_reader :card
# Attribute for field card_present
sig { returns(CardPresent) }
attr_reader :card_present
# Attribute for field cashapp
sig { returns(Cashapp) }
attr_reader :cashapp
# Attribute for field customer_balance
sig { returns(CustomerBalance) }
attr_reader :customer_balance
# Attribute for field eps
sig { returns(Eps) }
attr_reader :eps
# Attribute for field fpx
sig { returns(Fpx) }
attr_reader :fpx
# Attribute for field giropay
sig { returns(Giropay) }
attr_reader :giropay
# Attribute for field gopay
sig { returns(Gopay) }
attr_reader :gopay
# Attribute for field grabpay
sig { returns(Grabpay) }
attr_reader :grabpay
# Attribute for field id_bank_transfer
sig { returns(IdBankTransfer) }
attr_reader :id_bank_transfer
# Attribute for field ideal
sig { returns(Ideal) }
attr_reader :ideal
# Attribute for field interac_present
sig { returns(InteracPresent) }
attr_reader :interac_present
# Attribute for field kakao_pay
sig { returns(KakaoPay) }
attr_reader :kakao_pay
# Attribute for field klarna
sig { returns(Klarna) }
attr_reader :klarna
# Attribute for field konbini
sig { returns(Konbini) }
attr_reader :konbini
# Attribute for field kr_card
sig { returns(KrCard) }
attr_reader :kr_card
# Attribute for field link
sig { returns(Link) }
attr_reader :link
# Attribute for field mb_way
sig { returns(MbWay) }
attr_reader :mb_way
# Attribute for field mobilepay
sig { returns(Mobilepay) }
attr_reader :mobilepay
# Attribute for field multibanco
sig { returns(Multibanco) }
attr_reader :multibanco
# Attribute for field naver_pay
sig { returns(NaverPay) }
attr_reader :naver_pay
# Attribute for field nz_bank_account
sig { returns(NzBankAccount) }
attr_reader :nz_bank_account
# Attribute for field oxxo
sig { returns(Oxxo) }
attr_reader :oxxo
# Attribute for field p24
sig { returns(P24) }
attr_reader :p24
# Attribute for field pay_by_bank
sig { returns(PayByBank) }
attr_reader :pay_by_bank
# Attribute for field payco
sig { returns(Payco) }
attr_reader :payco
# Attribute for field paynow
sig { returns(Paynow) }
attr_reader :paynow
# Attribute for field paypal
sig { returns(Paypal) }
attr_reader :paypal
# Attribute for field payto
sig { returns(Payto) }
attr_reader :payto
# Attribute for field pix
sig { returns(Pix) }
attr_reader :pix
# Attribute for field promptpay
sig { returns(Promptpay) }
attr_reader :promptpay
# Attribute for field qris
sig { returns(Qris) }
attr_reader :qris
# Attribute for field rechnung
sig { returns(Rechnung) }
attr_reader :rechnung
# Attribute for field revolut_pay
sig { returns(RevolutPay) }
attr_reader :revolut_pay
# Attribute for field samsung_pay
sig { returns(SamsungPay) }
attr_reader :samsung_pay
# Attribute for field satispay
sig { returns(Satispay) }
attr_reader :satispay
# Attribute for field sepa_credit_transfer
sig { returns(SepaCreditTransfer) }
attr_reader :sepa_credit_transfer
# Attribute for field sepa_debit
sig { returns(SepaDebit) }
attr_reader :sepa_debit
# Attribute for field shopeepay
sig { returns(Shopeepay) }
attr_reader :shopeepay
# Attribute for field sofort
sig { returns(Sofort) }
attr_reader :sofort
# Attribute for field stripe_account
sig { returns(StripeAccount) }
attr_reader :stripe_account
# Attribute for field stripe_balance
sig { returns(StripeBalance) }
attr_reader :stripe_balance
# Attribute for field swish
sig { returns(Swish) }
attr_reader :swish
# Attribute for field twint
sig { returns(Twint) }
attr_reader :twint
# The type of transaction-specific details of the payment method used in the payment. See [PaymentMethod.type](https://stripe.com/docs/api/payment_methods/object#payment_method_object-type) for the full list of possible types.
# An additional hash is included on `payment_method_details` with a name matching this value.
# It contains information specific to the payment method.
sig { returns(String) }
attr_reader :type
# Attribute for field us_bank_account
sig { returns(UsBankAccount) }
attr_reader :us_bank_account
# Attribute for field wechat
sig { returns(Wechat) }
attr_reader :wechat
# Attribute for field wechat_pay
sig { returns(WechatPay) }
attr_reader :wechat_pay
# Attribute for field zip
sig { returns(Zip) }
attr_reader :zip
end
class PresentmentDetails < Stripe::StripeObject
# Amount intended to be collected by this payment, denominated in presentment_currency.
sig { returns(Integer) }
attr_reader :presentment_amount
# Currency presented to the customer during payment.
sig { returns(String) }
attr_reader :presentment_currency
end
class RadarOptions < Stripe::StripeObject
# A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
sig { returns(String) }
attr_reader :session
end
class Shipping < Stripe::StripeObject
class Address < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Attribute for field address
sig { returns(Address) }
attr_reader :address
# The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
sig { returns(T.nilable(String)) }
attr_reader :carrier
# Recipient name.
sig { returns(String) }
attr_reader :name
# Recipient phone (including extension).
sig { returns(T.nilable(String)) }
attr_reader :phone
# The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
sig { returns(T.nilable(String)) }
attr_reader :tracking_number
end
class TransferData < Stripe::StripeObject
# The amount transferred to the destination account, if specified. By default, the entire charge amount is transferred to the destination account.
sig { returns(T.nilable(Integer)) }
attr_reader :amount
# ID of an existing, connected Stripe account to transfer funds to if `transfer_data` was specified in the charge request.
sig { returns(T.any(String, Stripe::Account)) }
attr_reader :destination
end
# Amount intended to be collected by this payment. A positive integer representing how much to charge in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is $0.50 US or [equivalent in charge currency](https://stripe.com/docs/currencies#minimum-and-maximum-charge-amounts). The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99).
sig { returns(Integer) }
attr_reader :amount
# Amount in cents (or local equivalent) captured (can be less than the amount attribute on the charge if a partial capture was made).
sig { returns(Integer) }
attr_reader :amount_captured
# Amount in cents (or local equivalent) refunded (can be less than the amount attribute on the charge if a partial refund was issued).
sig { returns(Integer) }
attr_reader :amount_refunded
# ID of the Connect application that created the charge.
sig { returns(T.nilable(T.any(String, Stripe::Application))) }
attr_reader :application
# The application fee (if any) for the charge. [See the Connect documentation](https://stripe.com/docs/connect/direct-charges#collect-fees) for details.
sig { returns(T.nilable(T.any(String, Stripe::ApplicationFee))) }
attr_reader :application_fee
# The amount of the application fee (if any) requested for the charge. [See the Connect documentation](https://stripe.com/docs/connect/direct-charges#collect-fees) for details.
sig { returns(T.nilable(Integer)) }
attr_reader :application_fee_amount
# Authorization code on the charge.
sig { returns(String) }
attr_reader :authorization_code
# ID of the balance transaction that describes the impact of this charge on your account balance (not including refunds or disputes).
sig { returns(T.nilable(T.any(String, Stripe::BalanceTransaction))) }
attr_reader :balance_transaction
# Attribute for field billing_details
sig { returns(BillingDetails) }
attr_reader :billing_details
# The full statement descriptor that is passed to card networks, and that is displayed on your customers' credit card and bank statements. Allows you to see what the statement descriptor looks like after the static and dynamic portions are combined. This value only exists for card payments.
sig { returns(T.nilable(String)) }
attr_reader :calculated_statement_descriptor
# If the charge was created without capturing, this Boolean represents whether it is still uncaptured or has since been captured.
sig { returns(T::Boolean) }
attr_reader :captured
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# 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).
sig { returns(String) }
attr_reader :currency
# ID of the customer this charge is for if one exists.
sig { returns(T.nilable(T.any(String, Stripe::Customer))) }
attr_reader :customer
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_reader :description
# Whether the charge has been disputed.
sig { returns(T::Boolean) }
attr_reader :disputed
# ID of the balance transaction that describes the reversal of the balance on your account due to payment failure.
sig { returns(T.nilable(T.any(String, Stripe::BalanceTransaction))) }
attr_reader :failure_balance_transaction
# Error code explaining reason for charge failure if available (see [the errors section](https://stripe.com/docs/error-codes) for a list of codes).
sig { returns(T.nilable(String)) }
attr_reader :failure_code
# Message to user further explaining reason for charge failure if available.
sig { returns(T.nilable(String)) }
attr_reader :failure_message
# Information on fraud assessments for the charge.
sig { returns(T.nilable(FraudDetails)) }
attr_reader :fraud_details
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Attribute for field level3
sig { returns(Level3) }
attr_reader :level3
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# 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.
sig { returns(T::Hash[String, String]) }
attr_reader :metadata
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The account (if any) the charge was made on behalf of without triggering an automatic transfer. See the [Connect documentation](https://stripe.com/docs/connect/separate-charges-and-transfers) for details.
sig { returns(T.nilable(T.any(String, Stripe::Account))) }
attr_reader :on_behalf_of
# Details about whether the payment was accepted, and why. See [understanding declines](https://stripe.com/docs/declines) for details.
sig { returns(T.nilable(Outcome)) }
attr_reader :outcome
# `true` if the charge succeeded, or was successfully authorized for later capture.
sig { returns(T::Boolean) }
attr_reader :paid
# ID of the PaymentIntent associated with this charge, if one exists.
sig { returns(T.nilable(T.any(String, Stripe::PaymentIntent))) }
attr_reader :payment_intent
# ID of the payment method used in this charge.
sig { returns(T.nilable(String)) }
attr_reader :payment_method
# Details about the payment method at the time of the transaction.
sig { returns(T.nilable(PaymentMethodDetails)) }
attr_reader :payment_method_details
# Attribute for field presentment_details
sig { returns(PresentmentDetails) }
attr_reader :presentment_details
# Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
sig { returns(RadarOptions) }
attr_reader :radar_options
# This is the email address that the receipt for this charge was sent to.
sig { returns(T.nilable(String)) }
attr_reader :receipt_email
# This is the transaction number that appears on email receipts sent for this charge. This attribute will be `null` until a receipt has been sent.
sig { returns(T.nilable(String)) }
attr_reader :receipt_number
# This is the URL to view the receipt for this charge. The receipt is kept up-to-date to the latest state of the charge, including any refunds. If the charge is for an Invoice, the receipt will be stylized as an Invoice receipt.
sig { returns(T.nilable(String)) }
attr_reader :receipt_url
# Whether the charge has been fully refunded. If the charge is only partially refunded, this attribute will still be false.
sig { returns(T::Boolean) }
attr_reader :refunded
# A list of refunds that have been applied to the charge.
sig { returns(T.nilable(Stripe::ListObject)) }
attr_reader :refunds
# ID of the review associated with this charge if one exists.
sig { returns(T.nilable(T.any(String, Stripe::Review))) }
attr_reader :review
# Shipping information for the charge.
sig { returns(T.nilable(Shipping)) }
attr_reader :shipping
# This is a legacy field that will be removed in the future. It contains the Source, Card, or BankAccount object used for the charge. For details about the payment method used for this charge, refer to `payment_method` or `payment_method_details` instead.
sig {
returns(T.nilable(T.any(Stripe::Account, Stripe::BankAccount, Stripe::Card, Stripe::Source)))
}
attr_reader :source
# The transfer ID which created this charge. Only present if the charge came from another Stripe account. [See the Connect documentation](https://docs.stripe.com/connect/destination-charges) for details.
sig { returns(T.nilable(T.any(String, Stripe::Transfer))) }
attr_reader :source_transfer
# For a non-card charge, text that appears on the customer's statement as the statement descriptor. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
#
# For a card charge, this value is ignored unless you don't specify a `statement_descriptor_suffix`, in which case this value is used as the suffix.
sig { returns(T.nilable(String)) }
attr_reader :statement_descriptor
# Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement. If the account has no prefix value, the suffix is concatenated to the account's statement descriptor.
sig { returns(T.nilable(String)) }
attr_reader :statement_descriptor_suffix
# The status of the payment is either `succeeded`, `pending`, or `failed`.
sig { returns(String) }
attr_reader :status
# ID of the transfer to the `destination` account (only applicable if the charge was created using the `destination` parameter).
sig { returns(T.any(String, Stripe::Transfer)) }
attr_reader :transfer
# An optional dictionary including the account to automatically transfer to as part of a destination charge. [See the Connect documentation](https://stripe.com/docs/connect/destination-charges) for details.
sig { returns(T.nilable(TransferData)) }
attr_reader :transfer_data
# A string that identifies this transaction as part of a group. See the [Connect documentation](https://stripe.com/docs/connect/separate-charges-and-transfers#transfer-options) for details.
sig { returns(T.nilable(String)) }
attr_reader :transfer_group
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return charges that were created during the given date interval.
sig { returns(T.nilable(T.any(::Stripe::Charge::ListParams::Created, Integer))) }
attr_accessor :created
# Only return charges for the customer specified by this customer ID.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Only return charges that were created by the PaymentIntent specified by this PaymentIntent ID.
sig { returns(T.nilable(String)) }
attr_accessor :payment_intent
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return charges for this transfer group, limited to 100.
sig { returns(T.nilable(String)) }
attr_accessor :transfer_group
sig {
params(created: T.nilable(T.any(::Stripe::Charge::ListParams::Created, Integer)), customer: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), payment_intent: T.nilable(String), starting_after: T.nilable(String), transfer_group: T.nilable(String)).void
}
def initialize(
created: nil,
customer: nil,
ending_before: nil,
expand: nil,
limit: nil,
payment_intent: nil,
starting_after: nil,
transfer_group: nil
); end
end
class CreateParams < Stripe::RequestParams
class Destination < Stripe::RequestParams
# ID of an existing, connected Stripe account.
sig { returns(String) }
attr_accessor :account
# The amount to transfer to the destination account without creating an `Application Fee` object. Cannot be combined with the `application_fee` parameter. Must be less than or equal to the charge amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
sig { params(account: String, amount: T.nilable(Integer)).void }
def initialize(account: nil, amount: nil); end
end
class RadarOptions < Stripe::RequestParams
# A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
sig { returns(T.nilable(String)) }
attr_accessor :session
sig { params(session: T.nilable(String)).void }
def initialize(session: nil); end
end
class Shipping < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Shipping address.
sig { returns(::Stripe::Charge::CreateParams::Shipping::Address) }
attr_accessor :address
# The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
sig { returns(T.nilable(String)) }
attr_accessor :carrier
# Recipient name.
sig { returns(String) }
attr_accessor :name
# Recipient phone (including extension).
sig { returns(T.nilable(String)) }
attr_accessor :phone
# The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
sig { returns(T.nilable(String)) }
attr_accessor :tracking_number
sig {
params(address: ::Stripe::Charge::CreateParams::Shipping::Address, carrier: T.nilable(String), name: String, phone: T.nilable(String), tracking_number: T.nilable(String)).void
}
def initialize(address: nil, carrier: nil, name: nil, phone: nil, tracking_number: nil); end
end
class TransferData < Stripe::RequestParams
# The amount transferred to the destination account, if specified. By default, the entire charge amount is transferred to the destination account.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# ID of an existing, connected Stripe account.
sig { returns(String) }
attr_accessor :destination
sig { params(amount: T.nilable(Integer), destination: String).void }
def initialize(amount: nil, destination: nil); end
end
# Amount intended to be collected by this payment. A positive integer representing how much to charge in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is $0.50 US or [equivalent in charge currency](https://stripe.com/docs/currencies#minimum-and-maximum-charge-amounts). The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99).
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# Attribute for param field application_fee
sig { returns(T.nilable(Integer)) }
attr_accessor :application_fee
# A fee in cents (or local equivalent) that will be applied to the charge 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/connect/direct-charges#collect-fees).
sig { returns(T.nilable(Integer)) }
attr_accessor :application_fee_amount
# Whether to immediately capture the charge. Defaults to `true`. When `false`, the charge issues an authorization (or pre-authorization), and will need to be [captured](https://stripe.com/docs/api#capture_charge) later. Uncaptured charges expire after a set number of days (7 by default). For more information, see the [authorizing charges and settling later](https://stripe.com/docs/charges/placing-a-hold) documentation.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :capture
# 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).
sig { returns(T.nilable(String)) }
attr_accessor :currency
# The ID of an existing customer that will be charged in this request.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# An arbitrary string which you can attach to a `Charge` object. It is displayed when in the web interface alongside the charge. Note that if you use Stripe to send automatic email receipts to your customers, your receipt emails will include the `description` of the charge(s) that they are describing.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Attribute for param field destination
sig { returns(T.nilable(::Stripe::Charge::CreateParams::Destination)) }
attr_accessor :destination
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# The Stripe account ID for which these funds are intended. Automatically set if you use the `destination` parameter. For details, see [Creating Separate Charges and Transfers](https://stripe.com/docs/connect/separate-charges-and-transfers#settlement-merchant).
sig { returns(T.nilable(String)) }
attr_accessor :on_behalf_of
# Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
sig { returns(T.nilable(::Stripe::Charge::CreateParams::RadarOptions)) }
attr_accessor :radar_options
# The email address to which this charge's [receipt](https://stripe.com/docs/dashboard/receipts) will be sent. The receipt will not be sent until the charge is paid, and no receipts will be sent for test mode charges. If this charge is for a [Customer](https://stripe.com/docs/api/customers/object), the email address specified here will override the customer's email address. If `receipt_email` is specified for a charge in live mode, a receipt will be sent regardless of your [email settings](https://dashboard.stripe.com/account/emails).
sig { returns(T.nilable(String)) }
attr_accessor :receipt_email
# Shipping information for the charge. Helps prevent fraud on charges for physical goods.
sig { returns(T.nilable(::Stripe::Charge::CreateParams::Shipping)) }
attr_accessor :shipping
# A payment source to be charged. This can be the ID of a [card](https://stripe.com/docs/api#cards) (i.e., credit or debit card), a [bank account](https://stripe.com/docs/api#bank_accounts), a [source](https://stripe.com/docs/api#sources), a [token](https://stripe.com/docs/api#tokens), or a [connected account](https://stripe.com/docs/connect/account-debits#charging-a-connected-account). For certain sources---namely, [cards](https://stripe.com/docs/api#cards), [bank accounts](https://stripe.com/docs/api#bank_accounts), and attached [sources](https://stripe.com/docs/api#sources)---you must also pass the ID of the associated customer.
sig { returns(T.nilable(String)) }
attr_accessor :source
# For a non-card charge, text that appears on the customer's statement as the statement descriptor. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
#
# For a card charge, this value is ignored unless you don't specify a `statement_descriptor_suffix`, in which case this value is used as the suffix.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
# Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement. If the account has no prefix value, the suffix is concatenated to the account's statement descriptor.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor_suffix
# An optional dictionary including the account to automatically transfer to as part of a destination charge. [See the Connect documentation](https://stripe.com/docs/connect/destination-charges) for details.
sig { returns(T.nilable(::Stripe::Charge::CreateParams::TransferData)) }
attr_accessor :transfer_data
# A string that identifies this transaction as part of a group. For details, see [Grouping transactions](https://stripe.com/docs/connect/separate-charges-and-transfers#transfer-options).
sig { returns(T.nilable(String)) }
attr_accessor :transfer_group
sig {
params(amount: T.nilable(Integer), application_fee: T.nilable(Integer), application_fee_amount: T.nilable(Integer), capture: T.nilable(T::Boolean), currency: T.nilable(String), customer: T.nilable(String), description: T.nilable(String), destination: T.nilable(::Stripe::Charge::CreateParams::Destination), expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), on_behalf_of: T.nilable(String), radar_options: T.nilable(::Stripe::Charge::CreateParams::RadarOptions), receipt_email: T.nilable(String), shipping: T.nilable(::Stripe::Charge::CreateParams::Shipping), source: T.nilable(String), statement_descriptor: T.nilable(String), statement_descriptor_suffix: T.nilable(String), transfer_data: T.nilable(::Stripe::Charge::CreateParams::TransferData), transfer_group: T.nilable(String)).void
}
def initialize(
amount: nil,
application_fee: nil,
application_fee_amount: nil,
capture: nil,
currency: nil,
customer: nil,
description: nil,
destination: nil,
expand: nil,
metadata: nil,
on_behalf_of: nil,
radar_options: nil,
receipt_email: nil,
shipping: nil,
source: nil,
statement_descriptor: nil,
statement_descriptor_suffix: nil,
transfer_data: nil,
transfer_group: nil
); end
end
class UpdateParams < Stripe::RequestParams
class FraudDetails < Stripe::RequestParams
# Either `safe` or `fraudulent`.
sig { returns(T.nilable(T.any(String, String))) }
attr_accessor :user_report
sig { params(user_report: T.nilable(T.any(String, String))).void }
def initialize(user_report: nil); end
end
class PaymentDetails < Stripe::RequestParams
class CarRental < Stripe::RequestParams
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::CarRental::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::CarRental::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
class Distance < Stripe::RequestParams
# Distance traveled.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# Unit of measurement for the distance traveled. One of `miles` or `kilometers`.
sig { returns(T.nilable(String)) }
attr_accessor :unit
sig { params(amount: T.nilable(Integer), unit: T.nilable(String)).void }
def initialize(amount: nil, unit: nil); end
end
class Driver < Stripe::RequestParams
# Driver's identification number.
sig { returns(T.nilable(String)) }
attr_accessor :driver_identification_number
# Driver's tax number.
sig { returns(T.nilable(String)) }
attr_accessor :driver_tax_number
# Full name of the person or entity on the car reservation.
sig { returns(String) }
attr_accessor :name
sig {
params(driver_identification_number: T.nilable(String), driver_tax_number: T.nilable(String), name: String).void
}
def initialize(
driver_identification_number: nil,
driver_tax_number: nil,
name: nil
); end
end
class PickupAddress < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class ReturnAddress < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::CarRental::Affiliate))
}
attr_accessor :affiliate
# The booking number associated with the car rental.
sig { returns(String) }
attr_accessor :booking_number
# Class code of the car.
sig { returns(T.nilable(String)) }
attr_accessor :car_class_code
# Make of the car.
sig { returns(T.nilable(String)) }
attr_accessor :car_make
# Model of the car.
sig { returns(T.nilable(String)) }
attr_accessor :car_model
# The name of the rental car company.
sig { returns(T.nilable(String)) }
attr_accessor :company
# The customer service phone number of the car rental company.
sig { returns(T.nilable(String)) }
attr_accessor :customer_service_phone_number
# Number of days the car is being rented.
sig { returns(Integer) }
attr_accessor :days_rented
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::CarRental::Delivery))
}
attr_accessor :delivery
# The details of the distance traveled during the rental period.
sig {
returns(T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::CarRental::Distance))
}
attr_accessor :distance
# The details of the passengers in the travel reservation
sig {
returns(T.nilable(T::Array[::Stripe::Charge::UpdateParams::PaymentDetails::CarRental::Driver]))
}
attr_accessor :drivers
# List of additional charges being billed.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :extra_charges
# Indicates if the customer did not keep nor cancel their booking.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :no_show
# Car pick-up address.
sig {
returns(T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::CarRental::PickupAddress))
}
attr_accessor :pickup_address
# Car pick-up time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :pickup_at
# Name of the pickup location.
sig { returns(T.nilable(String)) }
attr_accessor :pickup_location_name
# Rental rate.
sig { returns(T.nilable(Integer)) }
attr_accessor :rate_amount
# The frequency at which the rate amount is applied. One of `day`, `week` or `month`
sig { returns(T.nilable(String)) }
attr_accessor :rate_interval
# The name of the person or entity renting the car.
sig { returns(T.nilable(String)) }
attr_accessor :renter_name
# Car return address.
sig {
returns(T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::CarRental::ReturnAddress))
}
attr_accessor :return_address
# Car return time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :return_at
# Name of the return location.
sig { returns(T.nilable(String)) }
attr_accessor :return_location_name
# Indicates whether the goods or services are tax-exempt or tax is not collected.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :tax_exempt
# The vehicle identification number.
sig { returns(T.nilable(String)) }
attr_accessor :vehicle_identification_number
sig {
params(affiliate: T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::CarRental::Affiliate), booking_number: String, car_class_code: T.nilable(String), car_make: T.nilable(String), car_model: T.nilable(String), company: T.nilable(String), customer_service_phone_number: T.nilable(String), days_rented: Integer, delivery: T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::CarRental::Delivery), distance: T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::CarRental::Distance), drivers: T.nilable(T::Array[::Stripe::Charge::UpdateParams::PaymentDetails::CarRental::Driver]), extra_charges: T.nilable(T::Array[String]), no_show: T.nilable(T::Boolean), pickup_address: T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::CarRental::PickupAddress), pickup_at: Integer, pickup_location_name: T.nilable(String), rate_amount: T.nilable(Integer), rate_interval: T.nilable(String), renter_name: T.nilable(String), return_address: T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::CarRental::ReturnAddress), return_at: Integer, return_location_name: T.nilable(String), tax_exempt: T.nilable(T::Boolean), vehicle_identification_number: T.nilable(String)).void
}
def initialize(
affiliate: nil,
booking_number: nil,
car_class_code: nil,
car_make: nil,
car_model: nil,
company: nil,
customer_service_phone_number: nil,
days_rented: nil,
delivery: nil,
distance: nil,
drivers: nil,
extra_charges: nil,
no_show: nil,
pickup_address: nil,
pickup_at: nil,
pickup_location_name: nil,
rate_amount: nil,
rate_interval: nil,
renter_name: nil,
return_address: nil,
return_at: nil,
return_location_name: nil,
tax_exempt: nil,
vehicle_identification_number: nil
); end
end
class EventDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::EventDetails::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::EventDetails::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
# Indicates if the tickets are digitally checked when entering the venue.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :access_controlled_venue
# The event location's address.
sig {
returns(T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::EventDetails::Address))
}
attr_accessor :address
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::EventDetails::Affiliate))
}
attr_accessor :affiliate
# The name of the company
sig { returns(T.nilable(String)) }
attr_accessor :company
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::EventDetails::Delivery))
}
attr_accessor :delivery
# Event end time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :ends_at
# Type of the event entertainment (concert, sports event etc)
sig { returns(T.nilable(String)) }
attr_accessor :genre
# The name of the event.
sig { returns(String) }
attr_accessor :name
# Event start time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :starts_at
sig {
params(access_controlled_venue: T.nilable(T::Boolean), address: T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::EventDetails::Address), affiliate: T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::EventDetails::Affiliate), company: T.nilable(String), delivery: T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::EventDetails::Delivery), ends_at: T.nilable(Integer), genre: T.nilable(String), name: String, starts_at: T.nilable(Integer)).void
}
def initialize(
access_controlled_venue: nil,
address: nil,
affiliate: nil,
company: nil,
delivery: nil,
ends_at: nil,
genre: nil,
name: nil,
starts_at: nil
); end
end
class Flight < Stripe::RequestParams
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::Flight::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::Flight::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
class Passenger < Stripe::RequestParams
# Full name of the person or entity on the flight reservation.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Segment < Stripe::RequestParams
# The flight segment amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# The International Air Transport Association (IATA) airport code for the arrival airport.
sig { returns(T.nilable(String)) }
attr_accessor :arrival_airport
# The arrival time for the flight segment. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :arrives_at
# The International Air Transport Association (IATA) carrier code of the carrier operating the flight segment.
sig { returns(T.nilable(String)) }
attr_accessor :carrier
# The departure time for the flight segment. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :departs_at
# The International Air Transport Association (IATA) airport code for the departure airport.
sig { returns(T.nilable(String)) }
attr_accessor :departure_airport
# The flight number associated with the segment
sig { returns(T.nilable(String)) }
attr_accessor :flight_number
# The fare class for the segment.
sig { returns(T.nilable(String)) }
attr_accessor :service_class
sig {
params(amount: T.nilable(Integer), arrival_airport: T.nilable(String), arrives_at: T.nilable(Integer), carrier: T.nilable(String), departs_at: Integer, departure_airport: T.nilable(String), flight_number: T.nilable(String), service_class: T.nilable(String)).void
}
def initialize(
amount: nil,
arrival_airport: nil,
arrives_at: nil,
carrier: nil,
departs_at: nil,
departure_airport: nil,
flight_number: nil,
service_class: nil
); end
end
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::Flight::Affiliate))
}
attr_accessor :affiliate
# The agency number (i.e. International Air Transport Association (IATA) agency number) of the travel agency that made the booking.
sig { returns(T.nilable(String)) }
attr_accessor :agency_number
# The International Air Transport Association (IATA) carrier code of the carrier that issued the ticket.
sig { returns(T.nilable(String)) }
attr_accessor :carrier
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::Flight::Delivery))
}
attr_accessor :delivery
# The name of the person or entity on the reservation.
sig { returns(T.nilable(String)) }
attr_accessor :passenger_name
# The details of the passengers in the travel reservation.
sig {
returns(T.nilable(T::Array[::Stripe::Charge::UpdateParams::PaymentDetails::Flight::Passenger]))
}
attr_accessor :passengers
# The individual flight segments associated with the trip.
sig { returns(T::Array[::Stripe::Charge::UpdateParams::PaymentDetails::Flight::Segment]) }
attr_accessor :segments
# The ticket number associated with the travel reservation.
sig { returns(T.nilable(String)) }
attr_accessor :ticket_number
sig {
params(affiliate: T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::Flight::Affiliate), agency_number: T.nilable(String), carrier: T.nilable(String), delivery: T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::Flight::Delivery), passenger_name: T.nilable(String), passengers: T.nilable(T::Array[::Stripe::Charge::UpdateParams::PaymentDetails::Flight::Passenger]), segments: T::Array[::Stripe::Charge::UpdateParams::PaymentDetails::Flight::Segment], ticket_number: T.nilable(String)).void
}
def initialize(
affiliate: nil,
agency_number: nil,
carrier: nil,
delivery: nil,
passenger_name: nil,
passengers: nil,
segments: nil,
ticket_number: nil
); end
end
class Lodging < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::Lodging::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::Lodging::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
class Passenger < Stripe::RequestParams
# Full name of the person or entity on the lodging reservation.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
# The lodging location's address.
sig {
returns(T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::Lodging::Address))
}
attr_accessor :address
# The number of adults on the booking
sig { returns(T.nilable(Integer)) }
attr_accessor :adults
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::Lodging::Affiliate))
}
attr_accessor :affiliate
# The booking number associated with the lodging reservation.
sig { returns(T.nilable(String)) }
attr_accessor :booking_number
# The lodging category
sig { returns(T.nilable(String)) }
attr_accessor :category
# Lodging check-in time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :checkin_at
# Lodging check-out time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :checkout_at
# The customer service phone number of the lodging company.
sig { returns(T.nilable(String)) }
attr_accessor :customer_service_phone_number
# The daily lodging room rate.
sig { returns(T.nilable(Integer)) }
attr_accessor :daily_room_rate_amount
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::Lodging::Delivery))
}
attr_accessor :delivery
# List of additional charges being billed.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :extra_charges
# Indicates whether the lodging location is compliant with the Fire Safety Act.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :fire_safety_act_compliance
# The name of the lodging location.
sig { returns(T.nilable(String)) }
attr_accessor :name
# Indicates if the customer did not keep their booking while failing to cancel the reservation.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :no_show
# The number of rooms on the booking
sig { returns(T.nilable(Integer)) }
attr_accessor :number_of_rooms
# The details of the passengers in the travel reservation
sig {
returns(T.nilable(T::Array[::Stripe::Charge::UpdateParams::PaymentDetails::Lodging::Passenger]))
}
attr_accessor :passengers
# The phone number of the lodging location.
sig { returns(T.nilable(String)) }
attr_accessor :property_phone_number
# The room class for this purchase.
sig { returns(T.nilable(String)) }
attr_accessor :room_class
# The number of room nights
sig { returns(T.nilable(Integer)) }
attr_accessor :room_nights
# The total tax amount associating with the room reservation.
sig { returns(T.nilable(Integer)) }
attr_accessor :total_room_tax_amount
# The total tax amount
sig { returns(T.nilable(Integer)) }
attr_accessor :total_tax_amount
sig {
params(address: T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::Lodging::Address), adults: T.nilable(Integer), affiliate: T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::Lodging::Affiliate), booking_number: T.nilable(String), category: T.nilable(String), checkin_at: Integer, checkout_at: Integer, customer_service_phone_number: T.nilable(String), daily_room_rate_amount: T.nilable(Integer), delivery: T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::Lodging::Delivery), extra_charges: T.nilable(T::Array[String]), fire_safety_act_compliance: T.nilable(T::Boolean), name: T.nilable(String), no_show: T.nilable(T::Boolean), number_of_rooms: T.nilable(Integer), passengers: T.nilable(T::Array[::Stripe::Charge::UpdateParams::PaymentDetails::Lodging::Passenger]), property_phone_number: T.nilable(String), room_class: T.nilable(String), room_nights: T.nilable(Integer), total_room_tax_amount: T.nilable(Integer), total_tax_amount: T.nilable(Integer)).void
}
def initialize(
address: nil,
adults: nil,
affiliate: nil,
booking_number: nil,
category: nil,
checkin_at: nil,
checkout_at: nil,
customer_service_phone_number: nil,
daily_room_rate_amount: nil,
delivery: nil,
extra_charges: nil,
fire_safety_act_compliance: nil,
name: nil,
no_show: nil,
number_of_rooms: nil,
passengers: nil,
property_phone_number: nil,
room_class: nil,
room_nights: nil,
total_room_tax_amount: nil,
total_tax_amount: nil
); end
end
class Subscription < Stripe::RequestParams
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class BillingInterval < Stripe::RequestParams
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :count
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
sig { params(count: Integer, interval: String).void }
def initialize(count: nil, interval: nil); end
end
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::Subscription::Affiliate))
}
attr_accessor :affiliate
# Info whether the subscription will be auto renewed upon expiry.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :auto_renewal
# Subscription billing details for this purchase.
sig {
returns(T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::Subscription::BillingInterval))
}
attr_accessor :billing_interval
# Subscription end time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :ends_at
# Name of the product on subscription. e.g. Apple Music Subscription
sig { returns(String) }
attr_accessor :name
# Subscription start time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :starts_at
sig {
params(affiliate: T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::Subscription::Affiliate), auto_renewal: T.nilable(T::Boolean), billing_interval: T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::Subscription::BillingInterval), ends_at: T.nilable(Integer), name: String, starts_at: T.nilable(Integer)).void
}
def initialize(
affiliate: nil,
auto_renewal: nil,
billing_interval: nil,
ends_at: nil,
name: nil,
starts_at: nil
); end
end
# Car rental details for this PaymentIntent.
sig { returns(T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::CarRental)) }
attr_accessor :car_rental
# Some customers might be required by their company or organization to provide this information. If so, provide this value. Otherwise you can ignore this field.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :customer_reference
# Event details for this PaymentIntent
sig { returns(T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::EventDetails)) }
attr_accessor :event_details
# Flight reservation details for this PaymentIntent
sig { returns(T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::Flight)) }
attr_accessor :flight
# Lodging reservation details for this PaymentIntent
sig { returns(T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::Lodging)) }
attr_accessor :lodging
# A unique value assigned by the business to identify the transaction.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :order_reference
# Subscription details for this PaymentIntent
sig { returns(T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::Subscription)) }
attr_accessor :subscription
sig {
params(car_rental: T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::CarRental), customer_reference: T.nilable(T.nilable(String)), event_details: T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::EventDetails), flight: T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::Flight), lodging: T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::Lodging), order_reference: T.nilable(T.nilable(String)), subscription: T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails::Subscription)).void
}
def initialize(
car_rental: nil,
customer_reference: nil,
event_details: nil,
flight: nil,
lodging: nil,
order_reference: nil,
subscription: nil
); end
end
class Shipping < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Shipping address.
sig { returns(::Stripe::Charge::UpdateParams::Shipping::Address) }
attr_accessor :address
# The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
sig { returns(T.nilable(String)) }
attr_accessor :carrier
# Recipient name.
sig { returns(String) }
attr_accessor :name
# Recipient phone (including extension).
sig { returns(T.nilable(String)) }
attr_accessor :phone
# The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
sig { returns(T.nilable(String)) }
attr_accessor :tracking_number
sig {
params(address: ::Stripe::Charge::UpdateParams::Shipping::Address, carrier: T.nilable(String), name: String, phone: T.nilable(String), tracking_number: T.nilable(String)).void
}
def initialize(address: nil, carrier: nil, name: nil, phone: nil, tracking_number: nil); end
end
# The ID of an existing customer that will be associated with this request. This field may only be updated if there is no existing associated customer with this charge.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# An arbitrary string which you can attach to a charge object. It is displayed when in the web interface alongside the charge. Note that if you use Stripe to send automatic email receipts to your customers, your receipt emails will include the `description` of the charge(s) that they are describing.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A set of key-value pairs you can attach to a charge giving information about its riskiness. If you believe a charge is fraudulent, include a `user_report` key with a value of `fraudulent`. If you believe a charge is safe, include a `user_report` key with a value of `safe`. Stripe will use the information you send to improve our fraud detection algorithms.
sig { returns(T.nilable(::Stripe::Charge::UpdateParams::FraudDetails)) }
attr_accessor :fraud_details
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Provides industry-specific information about the charge.
sig { returns(T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails)) }
attr_accessor :payment_details
# This is the email address that the receipt for this charge will be sent to. If this field is updated, then a new email receipt will be sent to the updated address.
sig { returns(T.nilable(String)) }
attr_accessor :receipt_email
# Shipping information for the charge. Helps prevent fraud on charges for physical goods.
sig { returns(T.nilable(::Stripe::Charge::UpdateParams::Shipping)) }
attr_accessor :shipping
# A string that identifies this transaction as part of a group. `transfer_group` may only be provided if it has not been set. See the [Connect documentation](https://stripe.com/docs/connect/separate-charges-and-transfers#transfer-options) for details.
sig { returns(T.nilable(String)) }
attr_accessor :transfer_group
sig {
params(customer: T.nilable(String), description: T.nilable(String), expand: T.nilable(T::Array[String]), fraud_details: T.nilable(::Stripe::Charge::UpdateParams::FraudDetails), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), payment_details: T.nilable(::Stripe::Charge::UpdateParams::PaymentDetails), receipt_email: T.nilable(String), shipping: T.nilable(::Stripe::Charge::UpdateParams::Shipping), transfer_group: T.nilable(String)).void
}
def initialize(
customer: nil,
description: nil,
expand: nil,
fraud_details: nil,
metadata: nil,
payment_details: nil,
receipt_email: nil,
shipping: nil,
transfer_group: nil
); end
end
class SearchParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for pagination across multiple pages of results. Don't include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.
sig { returns(T.nilable(String)) }
attr_accessor :page
# The search query string. See [search query language](https://stripe.com/docs/search#search-query-language) and the list of supported [query fields for charges](https://stripe.com/docs/search#query-fields-for-charges).
sig { returns(String) }
attr_accessor :query
sig {
params(expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), page: T.nilable(String), query: String).void
}
def initialize(expand: nil, limit: nil, page: nil, query: nil); end
end
class CaptureParams < Stripe::RequestParams
class PaymentDetails < Stripe::RequestParams
class CarRental < Stripe::RequestParams
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::CarRental::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::CarRental::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
class Distance < Stripe::RequestParams
# Distance traveled.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# Unit of measurement for the distance traveled. One of `miles` or `kilometers`.
sig { returns(T.nilable(String)) }
attr_accessor :unit
sig { params(amount: T.nilable(Integer), unit: T.nilable(String)).void }
def initialize(amount: nil, unit: nil); end
end
class Driver < Stripe::RequestParams
# Driver's identification number.
sig { returns(T.nilable(String)) }
attr_accessor :driver_identification_number
# Driver's tax number.
sig { returns(T.nilable(String)) }
attr_accessor :driver_tax_number
# Full name of the person or entity on the car reservation.
sig { returns(String) }
attr_accessor :name
sig {
params(driver_identification_number: T.nilable(String), driver_tax_number: T.nilable(String), name: String).void
}
def initialize(
driver_identification_number: nil,
driver_tax_number: nil,
name: nil
); end
end
class PickupAddress < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class ReturnAddress < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::CarRental::Affiliate))
}
attr_accessor :affiliate
# The booking number associated with the car rental.
sig { returns(String) }
attr_accessor :booking_number
# Class code of the car.
sig { returns(T.nilable(String)) }
attr_accessor :car_class_code
# Make of the car.
sig { returns(T.nilable(String)) }
attr_accessor :car_make
# Model of the car.
sig { returns(T.nilable(String)) }
attr_accessor :car_model
# The name of the rental car company.
sig { returns(T.nilable(String)) }
attr_accessor :company
# The customer service phone number of the car rental company.
sig { returns(T.nilable(String)) }
attr_accessor :customer_service_phone_number
# Number of days the car is being rented.
sig { returns(Integer) }
attr_accessor :days_rented
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::CarRental::Delivery))
}
attr_accessor :delivery
# The details of the distance traveled during the rental period.
sig {
returns(T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::CarRental::Distance))
}
attr_accessor :distance
# The details of the passengers in the travel reservation
sig {
returns(T.nilable(T::Array[::Stripe::Charge::CaptureParams::PaymentDetails::CarRental::Driver]))
}
attr_accessor :drivers
# List of additional charges being billed.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :extra_charges
# Indicates if the customer did not keep nor cancel their booking.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :no_show
# Car pick-up address.
sig {
returns(T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::CarRental::PickupAddress))
}
attr_accessor :pickup_address
# Car pick-up time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :pickup_at
# Name of the pickup location.
sig { returns(T.nilable(String)) }
attr_accessor :pickup_location_name
# Rental rate.
sig { returns(T.nilable(Integer)) }
attr_accessor :rate_amount
# The frequency at which the rate amount is applied. One of `day`, `week` or `month`
sig { returns(T.nilable(String)) }
attr_accessor :rate_interval
# The name of the person or entity renting the car.
sig { returns(T.nilable(String)) }
attr_accessor :renter_name
# Car return address.
sig {
returns(T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::CarRental::ReturnAddress))
}
attr_accessor :return_address
# Car return time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :return_at
# Name of the return location.
sig { returns(T.nilable(String)) }
attr_accessor :return_location_name
# Indicates whether the goods or services are tax-exempt or tax is not collected.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :tax_exempt
# The vehicle identification number.
sig { returns(T.nilable(String)) }
attr_accessor :vehicle_identification_number
sig {
params(affiliate: T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::CarRental::Affiliate), booking_number: String, car_class_code: T.nilable(String), car_make: T.nilable(String), car_model: T.nilable(String), company: T.nilable(String), customer_service_phone_number: T.nilable(String), days_rented: Integer, delivery: T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::CarRental::Delivery), distance: T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::CarRental::Distance), drivers: T.nilable(T::Array[::Stripe::Charge::CaptureParams::PaymentDetails::CarRental::Driver]), extra_charges: T.nilable(T::Array[String]), no_show: T.nilable(T::Boolean), pickup_address: T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::CarRental::PickupAddress), pickup_at: Integer, pickup_location_name: T.nilable(String), rate_amount: T.nilable(Integer), rate_interval: T.nilable(String), renter_name: T.nilable(String), return_address: T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::CarRental::ReturnAddress), return_at: Integer, return_location_name: T.nilable(String), tax_exempt: T.nilable(T::Boolean), vehicle_identification_number: T.nilable(String)).void
}
def initialize(
affiliate: nil,
booking_number: nil,
car_class_code: nil,
car_make: nil,
car_model: nil,
company: nil,
customer_service_phone_number: nil,
days_rented: nil,
delivery: nil,
distance: nil,
drivers: nil,
extra_charges: nil,
no_show: nil,
pickup_address: nil,
pickup_at: nil,
pickup_location_name: nil,
rate_amount: nil,
rate_interval: nil,
renter_name: nil,
return_address: nil,
return_at: nil,
return_location_name: nil,
tax_exempt: nil,
vehicle_identification_number: nil
); end
end
class EventDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::EventDetails::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::EventDetails::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
# Indicates if the tickets are digitally checked when entering the venue.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :access_controlled_venue
# The event location's address.
sig {
returns(T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::EventDetails::Address))
}
attr_accessor :address
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::EventDetails::Affiliate))
}
attr_accessor :affiliate
# The name of the company
sig { returns(T.nilable(String)) }
attr_accessor :company
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::EventDetails::Delivery))
}
attr_accessor :delivery
# Event end time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :ends_at
# Type of the event entertainment (concert, sports event etc)
sig { returns(T.nilable(String)) }
attr_accessor :genre
# The name of the event.
sig { returns(String) }
attr_accessor :name
# Event start time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :starts_at
sig {
params(access_controlled_venue: T.nilable(T::Boolean), address: T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::EventDetails::Address), affiliate: T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::EventDetails::Affiliate), company: T.nilable(String), delivery: T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::EventDetails::Delivery), ends_at: T.nilable(Integer), genre: T.nilable(String), name: String, starts_at: T.nilable(Integer)).void
}
def initialize(
access_controlled_venue: nil,
address: nil,
affiliate: nil,
company: nil,
delivery: nil,
ends_at: nil,
genre: nil,
name: nil,
starts_at: nil
); end
end
class Flight < Stripe::RequestParams
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::Flight::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::Flight::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
class Passenger < Stripe::RequestParams
# Full name of the person or entity on the flight reservation.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Segment < Stripe::RequestParams
# The flight segment amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# The International Air Transport Association (IATA) airport code for the arrival airport.
sig { returns(T.nilable(String)) }
attr_accessor :arrival_airport
# The arrival time for the flight segment. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :arrives_at
# The International Air Transport Association (IATA) carrier code of the carrier operating the flight segment.
sig { returns(T.nilable(String)) }
attr_accessor :carrier
# The departure time for the flight segment. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :departs_at
# The International Air Transport Association (IATA) airport code for the departure airport.
sig { returns(T.nilable(String)) }
attr_accessor :departure_airport
# The flight number associated with the segment
sig { returns(T.nilable(String)) }
attr_accessor :flight_number
# The fare class for the segment.
sig { returns(T.nilable(String)) }
attr_accessor :service_class
sig {
params(amount: T.nilable(Integer), arrival_airport: T.nilable(String), arrives_at: T.nilable(Integer), carrier: T.nilable(String), departs_at: Integer, departure_airport: T.nilable(String), flight_number: T.nilable(String), service_class: T.nilable(String)).void
}
def initialize(
amount: nil,
arrival_airport: nil,
arrives_at: nil,
carrier: nil,
departs_at: nil,
departure_airport: nil,
flight_number: nil,
service_class: nil
); end
end
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::Flight::Affiliate))
}
attr_accessor :affiliate
# The agency number (i.e. International Air Transport Association (IATA) agency number) of the travel agency that made the booking.
sig { returns(T.nilable(String)) }
attr_accessor :agency_number
# The International Air Transport Association (IATA) carrier code of the carrier that issued the ticket.
sig { returns(T.nilable(String)) }
attr_accessor :carrier
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::Flight::Delivery))
}
attr_accessor :delivery
# The name of the person or entity on the reservation.
sig { returns(T.nilable(String)) }
attr_accessor :passenger_name
# The details of the passengers in the travel reservation.
sig {
returns(T.nilable(T::Array[::Stripe::Charge::CaptureParams::PaymentDetails::Flight::Passenger]))
}
attr_accessor :passengers
# The individual flight segments associated with the trip.
sig {
returns(T::Array[::Stripe::Charge::CaptureParams::PaymentDetails::Flight::Segment])
}
attr_accessor :segments
# The ticket number associated with the travel reservation.
sig { returns(T.nilable(String)) }
attr_accessor :ticket_number
sig {
params(affiliate: T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::Flight::Affiliate), agency_number: T.nilable(String), carrier: T.nilable(String), delivery: T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::Flight::Delivery), passenger_name: T.nilable(String), passengers: T.nilable(T::Array[::Stripe::Charge::CaptureParams::PaymentDetails::Flight::Passenger]), segments: T::Array[::Stripe::Charge::CaptureParams::PaymentDetails::Flight::Segment], ticket_number: T.nilable(String)).void
}
def initialize(
affiliate: nil,
agency_number: nil,
carrier: nil,
delivery: nil,
passenger_name: nil,
passengers: nil,
segments: nil,
ticket_number: nil
); end
end
class Lodging < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::Lodging::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::Lodging::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
class Passenger < Stripe::RequestParams
# Full name of the person or entity on the lodging reservation.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
# The lodging location's address.
sig {
returns(T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::Lodging::Address))
}
attr_accessor :address
# The number of adults on the booking
sig { returns(T.nilable(Integer)) }
attr_accessor :adults
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::Lodging::Affiliate))
}
attr_accessor :affiliate
# The booking number associated with the lodging reservation.
sig { returns(T.nilable(String)) }
attr_accessor :booking_number
# The lodging category
sig { returns(T.nilable(String)) }
attr_accessor :category
# Lodging check-in time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :checkin_at
# Lodging check-out time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :checkout_at
# The customer service phone number of the lodging company.
sig { returns(T.nilable(String)) }
attr_accessor :customer_service_phone_number
# The daily lodging room rate.
sig { returns(T.nilable(Integer)) }
attr_accessor :daily_room_rate_amount
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::Lodging::Delivery))
}
attr_accessor :delivery
# List of additional charges being billed.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :extra_charges
# Indicates whether the lodging location is compliant with the Fire Safety Act.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :fire_safety_act_compliance
# The name of the lodging location.
sig { returns(T.nilable(String)) }
attr_accessor :name
# Indicates if the customer did not keep their booking while failing to cancel the reservation.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :no_show
# The number of rooms on the booking
sig { returns(T.nilable(Integer)) }
attr_accessor :number_of_rooms
# The details of the passengers in the travel reservation
sig {
returns(T.nilable(T::Array[::Stripe::Charge::CaptureParams::PaymentDetails::Lodging::Passenger]))
}
attr_accessor :passengers
# The phone number of the lodging location.
sig { returns(T.nilable(String)) }
attr_accessor :property_phone_number
# The room class for this purchase.
sig { returns(T.nilable(String)) }
attr_accessor :room_class
# The number of room nights
sig { returns(T.nilable(Integer)) }
attr_accessor :room_nights
# The total tax amount associating with the room reservation.
sig { returns(T.nilable(Integer)) }
attr_accessor :total_room_tax_amount
# The total tax amount
sig { returns(T.nilable(Integer)) }
attr_accessor :total_tax_amount
sig {
params(address: T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::Lodging::Address), adults: T.nilable(Integer), affiliate: T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::Lodging::Affiliate), booking_number: T.nilable(String), category: T.nilable(String), checkin_at: Integer, checkout_at: Integer, customer_service_phone_number: T.nilable(String), daily_room_rate_amount: T.nilable(Integer), delivery: T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::Lodging::Delivery), extra_charges: T.nilable(T::Array[String]), fire_safety_act_compliance: T.nilable(T::Boolean), name: T.nilable(String), no_show: T.nilable(T::Boolean), number_of_rooms: T.nilable(Integer), passengers: T.nilable(T::Array[::Stripe::Charge::CaptureParams::PaymentDetails::Lodging::Passenger]), property_phone_number: T.nilable(String), room_class: T.nilable(String), room_nights: T.nilable(Integer), total_room_tax_amount: T.nilable(Integer), total_tax_amount: T.nilable(Integer)).void
}
def initialize(
address: nil,
adults: nil,
affiliate: nil,
booking_number: nil,
category: nil,
checkin_at: nil,
checkout_at: nil,
customer_service_phone_number: nil,
daily_room_rate_amount: nil,
delivery: nil,
extra_charges: nil,
fire_safety_act_compliance: nil,
name: nil,
no_show: nil,
number_of_rooms: nil,
passengers: nil,
property_phone_number: nil,
room_class: nil,
room_nights: nil,
total_room_tax_amount: nil,
total_tax_amount: nil
); end
end
class Subscription < Stripe::RequestParams
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class BillingInterval < Stripe::RequestParams
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :count
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
sig { params(count: Integer, interval: String).void }
def initialize(count: nil, interval: nil); end
end
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::Subscription::Affiliate))
}
attr_accessor :affiliate
# Info whether the subscription will be auto renewed upon expiry.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :auto_renewal
# Subscription billing details for this purchase.
sig {
returns(T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::Subscription::BillingInterval))
}
attr_accessor :billing_interval
# Subscription end time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :ends_at
# Name of the product on subscription. e.g. Apple Music Subscription
sig { returns(String) }
attr_accessor :name
# Subscription start time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :starts_at
sig {
params(affiliate: T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::Subscription::Affiliate), auto_renewal: T.nilable(T::Boolean), billing_interval: T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::Subscription::BillingInterval), ends_at: T.nilable(Integer), name: String, starts_at: T.nilable(Integer)).void
}
def initialize(
affiliate: nil,
auto_renewal: nil,
billing_interval: nil,
ends_at: nil,
name: nil,
starts_at: nil
); end
end
# Car rental details for this PaymentIntent.
sig { returns(T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::CarRental)) }
attr_accessor :car_rental
# Some customers might be required by their company or organization to provide this information. If so, provide this value. Otherwise you can ignore this field.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :customer_reference
# Event details for this PaymentIntent
sig { returns(T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::EventDetails)) }
attr_accessor :event_details
# Flight reservation details for this PaymentIntent
sig { returns(T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::Flight)) }
attr_accessor :flight
# Lodging reservation details for this PaymentIntent
sig { returns(T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::Lodging)) }
attr_accessor :lodging
# A unique value assigned by the business to identify the transaction.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :order_reference
# Subscription details for this PaymentIntent
sig { returns(T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::Subscription)) }
attr_accessor :subscription
sig {
params(car_rental: T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::CarRental), customer_reference: T.nilable(T.nilable(String)), event_details: T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::EventDetails), flight: T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::Flight), lodging: T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::Lodging), order_reference: T.nilable(T.nilable(String)), subscription: T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails::Subscription)).void
}
def initialize(
car_rental: nil,
customer_reference: nil,
event_details: nil,
flight: nil,
lodging: nil,
order_reference: nil,
subscription: nil
); end
end
class TransferData < Stripe::RequestParams
# The amount transferred to the destination account, if specified. By default, the entire charge amount is transferred to the destination account.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
sig { params(amount: T.nilable(Integer)).void }
def initialize(amount: nil); end
end
# The amount to capture, which must be less than or equal to the original amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# An application fee to add on to this charge.
sig { returns(T.nilable(Integer)) }
attr_accessor :application_fee
# An application fee amount to add on to this charge, which must be less than or equal to the original amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :application_fee_amount
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Provides industry-specific information about the charge.
sig { returns(T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails)) }
attr_accessor :payment_details
# The email address to send this charge's receipt to. This will override the previously-specified email address for this charge, if one was set. Receipts will not be sent in test mode.
sig { returns(T.nilable(String)) }
attr_accessor :receipt_email
# For a non-card charge, text that appears on the customer's statement as the statement descriptor. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
#
# For a card charge, this value is ignored unless you don't specify a `statement_descriptor_suffix`, in which case this value is used as the suffix.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
# Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement. If the account has no prefix value, the suffix is concatenated to the account's statement descriptor.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor_suffix
# An optional dictionary including the account to automatically transfer to as part of a destination charge. [See the Connect documentation](https://stripe.com/docs/connect/destination-charges) for details.
sig { returns(T.nilable(::Stripe::Charge::CaptureParams::TransferData)) }
attr_accessor :transfer_data
# A string that identifies this transaction as part of a group. `transfer_group` may only be provided if it has not been set. See the [Connect documentation](https://stripe.com/docs/connect/separate-charges-and-transfers#transfer-options) for details.
sig { returns(T.nilable(String)) }
attr_accessor :transfer_group
sig {
params(amount: T.nilable(Integer), application_fee: T.nilable(Integer), application_fee_amount: T.nilable(Integer), expand: T.nilable(T::Array[String]), payment_details: T.nilable(::Stripe::Charge::CaptureParams::PaymentDetails), receipt_email: T.nilable(String), statement_descriptor: T.nilable(String), statement_descriptor_suffix: T.nilable(String), transfer_data: T.nilable(::Stripe::Charge::CaptureParams::TransferData), transfer_group: T.nilable(String)).void
}
def initialize(
amount: nil,
application_fee: nil,
application_fee_amount: nil,
expand: nil,
payment_details: nil,
receipt_email: nil,
statement_descriptor: nil,
statement_descriptor_suffix: nil,
transfer_data: nil,
transfer_group: nil
); end
end
# Capture the payment of an existing, uncaptured charge that was created with the capture option set to false.
#
# Uncaptured payments expire a set number of days after they are created ([7 by default](https://docs.stripe.com/docs/charges/placing-a-hold)), after which they are marked as refunded and capture attempts will fail.
#
# Don't use this method to capture a PaymentIntent-initiated charge. Use [Capture a PaymentIntent](https://docs.stripe.com/docs/api/payment_intents/capture).
sig {
params(params: T.any(::Stripe::Charge::CaptureParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Charge)
}
def capture(params = {}, opts = {}); end
# Capture the payment of an existing, uncaptured charge that was created with the capture option set to false.
#
# Uncaptured payments expire a set number of days after they are created ([7 by default](https://docs.stripe.com/docs/charges/placing-a-hold)), after which they are marked as refunded and capture attempts will fail.
#
# Don't use this method to capture a PaymentIntent-initiated charge. Use [Capture a PaymentIntent](https://docs.stripe.com/docs/api/payment_intents/capture).
sig {
params(charge: String, params: T.any(::Stripe::Charge::CaptureParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Charge)
}
def self.capture(charge, params = {}, opts = {}); end
# This method is no longer recommended—use the [Payment Intents API](https://docs.stripe.com/docs/api/payment_intents)
# to initiate a new payment instead. Confirmation of the PaymentIntent creates the Charge
# object used to request payment.
sig {
params(params: T.any(::Stripe::Charge::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Charge)
}
def self.create(params = {}, opts = {}); end
# Returns a list of charges you've previously created. The charges are returned in sorted order, with the most recent charges appearing first.
sig {
params(params: T.any(::Stripe::Charge::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
sig {
params(params: T.any(::Stripe::Charge::SearchParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SearchResultObject)
}
def self.search(params = {}, opts = {}); end
sig {
params(params: T.any(::Stripe::Charge::SearchParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped, blk: T.untyped).returns(Stripe::SearchResultObject)
}
def self.search_auto_paging_each(params = {}, opts = {}, &blk); end
# Updates the specified charge by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
sig {
params(charge: String, params: T.any(::Stripe::Charge::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Charge)
}
def self.update(charge, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
module Checkout
# A Checkout Session represents your customer's session as they pay for
# one-time purchases or subscriptions through [Checkout](https://stripe.com/docs/payments/checkout)
# or [Payment Links](https://stripe.com/docs/payments/payment-links). We recommend creating a
# new Session each time your customer attempts to pay.
#
# Once payment is successful, the Checkout Session will contain a reference
# to the [Customer](https://stripe.com/docs/api/customers), and either the successful
# [PaymentIntent](https://stripe.com/docs/api/payment_intents) or an active
# [Subscription](https://stripe.com/docs/api/subscriptions).
#
# You can create a Checkout Session on your server and redirect to its URL
# to begin Checkout.
#
# Related guide: [Checkout quickstart](https://stripe.com/docs/checkout/quickstart)
class Session < APIResource
class AdaptivePricing < Stripe::StripeObject
# Whether Adaptive Pricing is enabled.
sig { returns(T::Boolean) }
attr_reader :enabled
end
class AfterExpiration < Stripe::StripeObject
class Recovery < Stripe::StripeObject
# Enables user redeemable promotion codes on the recovered Checkout Sessions. Defaults to `false`
sig { returns(T::Boolean) }
attr_reader :allow_promotion_codes
# If `true`, a recovery url will be generated to recover this Checkout Session if it
# expires before a transaction is completed. It will be attached to the
# Checkout Session object upon expiration.
sig { returns(T::Boolean) }
attr_reader :enabled
# The timestamp at which the recovery URL will expire.
sig { returns(T.nilable(Integer)) }
attr_reader :expires_at
# URL that creates a new Checkout Session when clicked that is a copy of this expired Checkout Session
sig { returns(T.nilable(String)) }
attr_reader :url
end
# When set, configuration used to recover the Checkout Session on expiry.
sig { returns(T.nilable(Recovery)) }
attr_reader :recovery
end
class AutomaticTax < Stripe::StripeObject
class Liability < Stripe::StripeObject
# The connected account being referenced when `type` is `account`.
sig { returns(T.any(String, Stripe::Account)) }
attr_reader :account
# Type of the account referenced.
sig { returns(String) }
attr_reader :type
end
# Indicates whether automatic tax is enabled for the session
sig { returns(T::Boolean) }
attr_reader :enabled
# The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
sig { returns(T.nilable(Liability)) }
attr_reader :liability
# The tax provider powering automatic tax.
sig { returns(T.nilable(String)) }
attr_reader :provider
# The status of the most recent automated tax calculation for this session.
sig { returns(T.nilable(String)) }
attr_reader :status
end
class CollectedInformation < Stripe::StripeObject
class ShippingDetails < Stripe::StripeObject
class Address < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Attribute for field address
sig { returns(Address) }
attr_reader :address
# Customer name.
sig { returns(String) }
attr_reader :name
end
class TaxId < Stripe::StripeObject
# The type of the tax ID, one of `ad_nrt`, `ar_cuit`, `eu_vat`, `bo_tin`, `br_cnpj`, `br_cpf`, `cn_tin`, `co_nit`, `cr_tin`, `do_rcn`, `ec_ruc`, `eu_oss_vat`, `hr_oib`, `pe_ruc`, `ro_tin`, `rs_pib`, `sv_nit`, `uy_ruc`, `ve_rif`, `vn_tin`, `gb_vat`, `nz_gst`, `au_abn`, `au_arn`, `in_gst`, `no_vat`, `no_voec`, `za_vat`, `ch_vat`, `mx_rfc`, `sg_uen`, `ru_inn`, `ru_kpp`, `ca_bn`, `hk_br`, `es_cif`, `tw_vat`, `th_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `li_uid`, `li_vat`, `my_itn`, `us_ein`, `kr_brn`, `ca_qst`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `my_sst`, `sg_gst`, `ae_trn`, `cl_tin`, `sa_vat`, `id_npwp`, `my_frp`, `il_vat`, `ge_vat`, `ua_vat`, `is_vat`, `bg_uic`, `hu_tin`, `si_tin`, `ke_pin`, `tr_tin`, `eg_tin`, `ph_tin`, `al_tin`, `bh_vat`, `kz_bin`, `ng_tin`, `om_vat`, `de_stn`, `ch_uid`, `tz_vat`, `uz_vat`, `uz_tin`, `md_vat`, `ma_vat`, `by_tin`, `ao_tin`, `bs_tin`, `bb_tin`, `cd_nif`, `mr_nif`, `me_pib`, `zw_tin`, `ba_tin`, `gn_nif`, `mk_vat`, `sr_fin`, `sn_ninea`, `am_tin`, `np_pan`, `tj_tin`, `ug_tin`, `zm_tin`, `kh_tin`, `aw_tin`, `az_tin`, `bd_bin`, `bj_ifu`, `et_tin`, `kg_tin`, `la_tin`, `cm_niu`, `cv_nif`, `bf_ifu`, or `unknown`
sig { returns(String) }
attr_reader :type
# The value of the tax ID.
sig { returns(T.nilable(String)) }
attr_reader :value
end
# Customer’s business name for this Checkout Session
sig { returns(T.nilable(String)) }
attr_reader :business_name
# Customer’s email for this Checkout Session
sig { returns(T.nilable(String)) }
attr_reader :email
# Customer’s phone number for this Checkout Session
sig { returns(T.nilable(String)) }
attr_reader :phone
# Shipping information for this Checkout Session.
sig { returns(T.nilable(ShippingDetails)) }
attr_reader :shipping_details
# Customer’s tax ids for this Checkout Session.
sig { returns(T.nilable(T::Array[TaxId])) }
attr_reader :tax_ids
end
class Consent < Stripe::StripeObject
# If `opt_in`, the customer consents to receiving promotional communications
# from the merchant about this Checkout Session.
sig { returns(T.nilable(String)) }
attr_reader :promotions
# If `accepted`, the customer in this Checkout Session has agreed to the merchant's terms of service.
sig { returns(T.nilable(String)) }
attr_reader :terms_of_service
end
class ConsentCollection < Stripe::StripeObject
class PaymentMethodReuseAgreement < Stripe::StripeObject
# Determines the position and visibility of the payment method reuse agreement in the UI. When set to `auto`, Stripe's defaults will be used.
#
# When set to `hidden`, the payment method reuse agreement text will always be hidden in the UI.
sig { returns(String) }
attr_reader :position
end
# If set to `hidden`, it will hide legal text related to the reuse of a payment method.
sig { returns(T.nilable(PaymentMethodReuseAgreement)) }
attr_reader :payment_method_reuse_agreement
# If set to `auto`, enables the collection of customer consent for promotional communications. The Checkout
# Session will determine whether to display an option to opt into promotional communication
# from the merchant depending on the customer's locale. Only available to US merchants.
sig { returns(T.nilable(String)) }
attr_reader :promotions
# If set to `required`, it requires customers to accept the terms of service before being able to pay.
sig { returns(T.nilable(String)) }
attr_reader :terms_of_service
end
class CurrencyConversion < Stripe::StripeObject
# Total of all items in source currency before discounts or taxes are applied.
sig { returns(Integer) }
attr_reader :amount_subtotal
# Total of all items in source currency after discounts and taxes are applied.
sig { returns(Integer) }
attr_reader :amount_total
# Exchange rate used to convert source currency amounts to customer currency amounts
sig { returns(String) }
attr_reader :fx_rate
# Creation currency of the CheckoutSession before localization
sig { returns(String) }
attr_reader :source_currency
end
class CustomField < Stripe::StripeObject
class Dropdown < Stripe::StripeObject
class Option < Stripe::StripeObject
# The label for the option, displayed to the customer. Up to 100 characters.
sig { returns(String) }
attr_reader :label
# The value for this option, not displayed to the customer, used by your integration to reconcile the option selected by the customer. Must be unique to this option, alphanumeric, and up to 100 characters.
sig { returns(String) }
attr_reader :value
end
# The value that will pre-fill on the payment page.
sig { returns(T.nilable(String)) }
attr_reader :default_value
# The options available for the customer to select. Up to 200 options allowed.
sig { returns(T::Array[Option]) }
attr_reader :options
# The option selected by the customer. This will be the `value` for the option.
sig { returns(T.nilable(String)) }
attr_reader :value
end
class Label < Stripe::StripeObject
# Custom text for the label, displayed to the customer. Up to 50 characters.
sig { returns(T.nilable(String)) }
attr_reader :custom
# The type of the label.
sig { returns(String) }
attr_reader :type
end
class Numeric < Stripe::StripeObject
# The value that will pre-fill the field on the payment page.
sig { returns(T.nilable(String)) }
attr_reader :default_value
# The maximum character length constraint for the customer's input.
sig { returns(T.nilable(Integer)) }
attr_reader :maximum_length
# The minimum character length requirement for the customer's input.
sig { returns(T.nilable(Integer)) }
attr_reader :minimum_length
# The value entered by the customer, containing only digits.
sig { returns(T.nilable(String)) }
attr_reader :value
end
class Text < Stripe::StripeObject
# The value that will pre-fill the field on the payment page.
sig { returns(T.nilable(String)) }
attr_reader :default_value
# The maximum character length constraint for the customer's input.
sig { returns(T.nilable(Integer)) }
attr_reader :maximum_length
# The minimum character length requirement for the customer's input.
sig { returns(T.nilable(Integer)) }
attr_reader :minimum_length
# The value entered by the customer.
sig { returns(T.nilable(String)) }
attr_reader :value
end
# Attribute for field dropdown
sig { returns(Dropdown) }
attr_reader :dropdown
# String of your choice that your integration can use to reconcile this field. Must be unique to this field, alphanumeric, and up to 200 characters.
sig { returns(String) }
attr_reader :key
# Attribute for field label
sig { returns(Label) }
attr_reader :label
# Attribute for field numeric
sig { returns(Numeric) }
attr_reader :numeric
# Whether the customer is required to complete the field before completing the Checkout Session. Defaults to `false`.
sig { returns(T::Boolean) }
attr_reader :optional
# Attribute for field text
sig { returns(Text) }
attr_reader :text
# The type of the field.
sig { returns(String) }
attr_reader :type
end
class CustomText < Stripe::StripeObject
class AfterSubmit < Stripe::StripeObject
# Text may be up to 1200 characters in length.
sig { returns(String) }
attr_reader :message
end
class ShippingAddress < Stripe::StripeObject
# Text may be up to 1200 characters in length.
sig { returns(String) }
attr_reader :message
end
class Submit < Stripe::StripeObject
# Text may be up to 1200 characters in length.
sig { returns(String) }
attr_reader :message
end
class TermsOfServiceAcceptance < Stripe::StripeObject
# Text may be up to 1200 characters in length.
sig { returns(String) }
attr_reader :message
end
# Custom text that should be displayed after the payment confirmation button.
sig { returns(T.nilable(AfterSubmit)) }
attr_reader :after_submit
# Custom text that should be displayed alongside shipping address collection.
sig { returns(T.nilable(ShippingAddress)) }
attr_reader :shipping_address
# Custom text that should be displayed alongside the payment confirmation button.
sig { returns(T.nilable(Submit)) }
attr_reader :submit
# Custom text that should be displayed in place of the default terms of service agreement text.
sig { returns(T.nilable(TermsOfServiceAcceptance)) }
attr_reader :terms_of_service_acceptance
end
class CustomerDetails < Stripe::StripeObject
class Address < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
class TaxId < Stripe::StripeObject
# The type of the tax ID, one of `ad_nrt`, `ar_cuit`, `eu_vat`, `bo_tin`, `br_cnpj`, `br_cpf`, `cn_tin`, `co_nit`, `cr_tin`, `do_rcn`, `ec_ruc`, `eu_oss_vat`, `hr_oib`, `pe_ruc`, `ro_tin`, `rs_pib`, `sv_nit`, `uy_ruc`, `ve_rif`, `vn_tin`, `gb_vat`, `nz_gst`, `au_abn`, `au_arn`, `in_gst`, `no_vat`, `no_voec`, `za_vat`, `ch_vat`, `mx_rfc`, `sg_uen`, `ru_inn`, `ru_kpp`, `ca_bn`, `hk_br`, `es_cif`, `tw_vat`, `th_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `li_uid`, `li_vat`, `my_itn`, `us_ein`, `kr_brn`, `ca_qst`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `my_sst`, `sg_gst`, `ae_trn`, `cl_tin`, `sa_vat`, `id_npwp`, `my_frp`, `il_vat`, `ge_vat`, `ua_vat`, `is_vat`, `bg_uic`, `hu_tin`, `si_tin`, `ke_pin`, `tr_tin`, `eg_tin`, `ph_tin`, `al_tin`, `bh_vat`, `kz_bin`, `ng_tin`, `om_vat`, `de_stn`, `ch_uid`, `tz_vat`, `uz_vat`, `uz_tin`, `md_vat`, `ma_vat`, `by_tin`, `ao_tin`, `bs_tin`, `bb_tin`, `cd_nif`, `mr_nif`, `me_pib`, `zw_tin`, `ba_tin`, `gn_nif`, `mk_vat`, `sr_fin`, `sn_ninea`, `am_tin`, `np_pan`, `tj_tin`, `ug_tin`, `zm_tin`, `kh_tin`, `aw_tin`, `az_tin`, `bd_bin`, `bj_ifu`, `et_tin`, `kg_tin`, `la_tin`, `cm_niu`, `cv_nif`, `bf_ifu`, or `unknown`
sig { returns(String) }
attr_reader :type
# The value of the tax ID.
sig { returns(T.nilable(String)) }
attr_reader :value
end
# The customer's address after a completed Checkout Session. Note: This property is populated only for sessions on or after March 30, 2022.
sig { returns(T.nilable(Address)) }
attr_reader :address
# The email associated with the Customer, if one exists, on the Checkout Session after a completed Checkout Session or at time of session expiry.
# Otherwise, if the customer has consented to promotional content, this value is the most recent valid email provided by the customer on the Checkout form.
sig { returns(T.nilable(String)) }
attr_reader :email
# The customer's name after a completed Checkout Session. Note: This property is populated only for sessions on or after March 30, 2022.
sig { returns(T.nilable(String)) }
attr_reader :name
# The customer's phone number after a completed Checkout Session.
sig { returns(T.nilable(String)) }
attr_reader :phone
# The customer’s tax exempt status after a completed Checkout Session.
sig { returns(T.nilable(String)) }
attr_reader :tax_exempt
# The customer’s tax IDs after a completed Checkout Session.
sig { returns(T.nilable(T::Array[TaxId])) }
attr_reader :tax_ids
end
class Discount < Stripe::StripeObject
# Coupon attached to the Checkout Session.
sig { returns(T.nilable(T.any(String, Stripe::Coupon))) }
attr_reader :coupon
# Promotion code attached to the Checkout Session.
sig { returns(T.nilable(T.any(String, Stripe::PromotionCode))) }
attr_reader :promotion_code
end
class InvoiceCreation < Stripe::StripeObject
class InvoiceData < Stripe::StripeObject
class CustomField < Stripe::StripeObject
# The name of the custom field.
sig { returns(String) }
attr_reader :name
# The value of the custom field.
sig { returns(String) }
attr_reader :value
end
class Issuer < Stripe::StripeObject
# The connected account being referenced when `type` is `account`.
sig { returns(T.any(String, Stripe::Account)) }
attr_reader :account
# Type of the account referenced.
sig { returns(String) }
attr_reader :type
end
class RenderingOptions < Stripe::StripeObject
# How line-item prices and amounts will be displayed with respect to tax on invoice PDFs.
sig { returns(T.nilable(String)) }
attr_reader :amount_tax_display
end
# The account tax IDs associated with the invoice.
sig { returns(T.nilable(T::Array[T.any(String, Stripe::TaxId)])) }
attr_reader :account_tax_ids
# Custom fields displayed on the invoice.
sig { returns(T.nilable(T::Array[CustomField])) }
attr_reader :custom_fields
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_reader :description
# Footer displayed on the invoice.
sig { returns(T.nilable(String)) }
attr_reader :footer
# The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
sig { returns(T.nilable(Issuer)) }
attr_reader :issuer
# 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.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# Options for invoice PDF rendering.
sig { returns(T.nilable(RenderingOptions)) }
attr_reader :rendering_options
end
# Indicates whether invoice creation is enabled for the Checkout Session.
sig { returns(T::Boolean) }
attr_reader :enabled
# Attribute for field invoice_data
sig { returns(InvoiceData) }
attr_reader :invoice_data
end
class OptionalItem < Stripe::StripeObject
class AdjustableQuantity < Stripe::StripeObject
# Set to true if the quantity can be adjusted to any non-negative integer.
sig { returns(T::Boolean) }
attr_reader :enabled
# The maximum quantity of this item the customer can purchase. By default this value is 99. You can specify a value up to 999999.
sig { returns(T.nilable(Integer)) }
attr_reader :maximum
# The minimum quantity of this item the customer must purchase, if they choose to purchase it. Because this item is optional, the customer will always be able to remove it from their order, even if the `minimum` configured here is greater than 0. By default this value is 0.
sig { returns(T.nilable(Integer)) }
attr_reader :minimum
end
# Attribute for field adjustable_quantity
sig { returns(T.nilable(AdjustableQuantity)) }
attr_reader :adjustable_quantity
# Attribute for field price
sig { returns(String) }
attr_reader :price
# Attribute for field quantity
sig { returns(Integer) }
attr_reader :quantity
end
class PaymentMethodConfigurationDetails < Stripe::StripeObject
# ID of the payment method configuration used.
sig { returns(String) }
attr_reader :id
# ID of the parent payment method configuration used.
sig { returns(T.nilable(String)) }
attr_reader :parent
end
class PaymentMethodOptions < Stripe::StripeObject
class AcssDebit < Stripe::StripeObject
class MandateOptions < Stripe::StripeObject
# A URL for custom mandate text
sig { returns(String) }
attr_reader :custom_mandate_url
# List of Stripe products where this mandate can be selected automatically. Returned when the Session is in `setup` mode.
sig { returns(T::Array[String]) }
attr_reader :default_for
# Description of the interval. Only required if the 'payment_schedule' parameter is 'interval' or 'combined'.
sig { returns(T.nilable(String)) }
attr_reader :interval_description
# Payment schedule for the mandate.
sig { returns(T.nilable(String)) }
attr_reader :payment_schedule
# Transaction type of the mandate.
sig { returns(T.nilable(String)) }
attr_reader :transaction_type
end
# Currency supported by the bank account. Returned when the Session is in `setup` mode.
sig { returns(String) }
attr_reader :currency
# Attribute for field mandate_options
sig { returns(MandateOptions) }
attr_reader :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(String) }
attr_reader :target_date
# Bank account verification method.
sig { returns(String) }
attr_reader :verification_method
end
class Affirm < Stripe::StripeObject
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class AfterpayClearpay < Stripe::StripeObject
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Alipay < Stripe::StripeObject
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class AmazonPay < Stripe::StripeObject
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class AuBecsDebit < Stripe::StripeObject
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(String) }
attr_reader :target_date
end
class BacsDebit < Stripe::StripeObject
class MandateOptions < Stripe::StripeObject
# Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'DDIC' or 'STRIPE'.
sig { returns(String) }
attr_reader :reference_prefix
end
# Attribute for field mandate_options
sig { returns(MandateOptions) }
attr_reader :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(String) }
attr_reader :target_date
end
class Bancontact < Stripe::StripeObject
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Boleto < Stripe::StripeObject
# The number of calendar days before a Boleto voucher expires. For example, if you create a Boleto voucher on Monday and you set expires_after_days to 2, the Boleto voucher will expire on Wednesday at 23:59 America/Sao_Paulo time.
sig { returns(Integer) }
attr_reader :expires_after_days
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Card < Stripe::StripeObject
class Installments < Stripe::StripeObject
# Indicates if installments are enabled
sig { returns(T::Boolean) }
attr_reader :enabled
end
class Restrictions < Stripe::StripeObject
# Specify the card brands to block in the Checkout Session. If a customer enters or selects a card belonging to a blocked brand, they can't complete the Session.
sig { returns(T::Array[String]) }
attr_reader :brands_blocked
end
# Attribute for field installments
sig { returns(Installments) }
attr_reader :installments
# Request ability to [capture beyond the standard authorization validity window](/payments/extended-authorization) for this CheckoutSession.
sig { returns(String) }
attr_reader :request_decremental_authorization
# Request ability to [capture beyond the standard authorization validity window](/payments/extended-authorization) for this CheckoutSession.
sig { returns(String) }
attr_reader :request_extended_authorization
# Request ability to [increment the authorization](/payments/incremental-authorization) for this CheckoutSession.
sig { returns(String) }
attr_reader :request_incremental_authorization
# Request ability to make [multiple captures](/payments/multicapture) for this CheckoutSession.
sig { returns(String) }
attr_reader :request_multicapture
# Request ability to [overcapture](/payments/overcapture) for this CheckoutSession.
sig { returns(String) }
attr_reader :request_overcapture
# We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. If not provided, this value defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
sig { returns(String) }
attr_reader :request_three_d_secure
# Attribute for field restrictions
sig { returns(Restrictions) }
attr_reader :restrictions
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
# Provides information about a card payment that customers see on their statements. Concatenated with the Kana prefix (shortened Kana descriptor) or Kana statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 22 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 22 characters.
sig { returns(String) }
attr_reader :statement_descriptor_suffix_kana
# Provides information about a card payment that customers see on their statements. Concatenated with the Kanji prefix (shortened Kanji descriptor) or Kanji statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 17 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 17 characters.
sig { returns(String) }
attr_reader :statement_descriptor_suffix_kanji
end
class Cashapp < Stripe::StripeObject
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class CustomerBalance < Stripe::StripeObject
class BankTransfer < Stripe::StripeObject
class EuBankTransfer < Stripe::StripeObject
# The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
sig { returns(String) }
attr_reader :country
end
# Attribute for field eu_bank_transfer
sig { returns(EuBankTransfer) }
attr_reader :eu_bank_transfer
# List of address types that should be returned in the financial_addresses response. If not specified, all valid types will be returned.
#
# Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`.
sig { returns(T::Array[String]) }
attr_reader :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`, `mx_bank_transfer`, or `us_bank_transfer`.
sig { returns(T.nilable(String)) }
attr_reader :type
end
# Attribute for field bank_transfer
sig { returns(BankTransfer) }
attr_reader :bank_transfer
# The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
sig { returns(T.nilable(String)) }
attr_reader :funding_type
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Eps < Stripe::StripeObject
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Fpx < Stripe::StripeObject
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Giropay < Stripe::StripeObject
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Grabpay < Stripe::StripeObject
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Ideal < Stripe::StripeObject
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class KakaoPay < Stripe::StripeObject
# Controls when the funds will be captured from the customer's account.
sig { returns(String) }
attr_reader :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Klarna < Stripe::StripeObject
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Konbini < Stripe::StripeObject
# The number of calendar days (between 1 and 60) after which Konbini payment instructions will expire. For example, if a PaymentIntent is confirmed with Konbini and `expires_after_days` set to 2 on Monday JST, the instructions will expire on Wednesday 23:59:59 JST.
sig { returns(T.nilable(Integer)) }
attr_reader :expires_after_days
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class KrCard < Stripe::StripeObject
# Controls when the funds will be captured from the customer's account.
sig { returns(String) }
attr_reader :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Link < Stripe::StripeObject
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Mobilepay < Stripe::StripeObject
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Multibanco < Stripe::StripeObject
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class NaverPay < Stripe::StripeObject
# Controls when the funds will be captured from the customer's account.
sig { returns(String) }
attr_reader :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Oxxo < Stripe::StripeObject
# The number of calendar days before an OXXO invoice expires. For example, if you create an OXXO invoice on Monday and you set expires_after_days to 2, the OXXO invoice will expire on Wednesday at 23:59 America/Mexico_City time.
sig { returns(Integer) }
attr_reader :expires_after_days
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class P24 < Stripe::StripeObject
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Payco < Stripe::StripeObject
# Controls when the funds will be captured from the customer's account.
sig { returns(String) }
attr_reader :capture_method
end
class Paynow < Stripe::StripeObject
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Paypal < Stripe::StripeObject
# Controls when the funds will be captured from the customer's account.
sig { returns(String) }
attr_reader :capture_method
# Preferred locale of the PayPal checkout page that the customer is redirected to.
sig { returns(T.nilable(String)) }
attr_reader :preferred_locale
# A reference of the PayPal transaction visible to customer which is mapped to PayPal's invoice ID. This must be a globally unique ID if you have configured in your PayPal settings to block multiple payments per invoice ID.
sig { returns(T.nilable(String)) }
attr_reader :reference
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
# The Stripe connected account IDs of the sellers on the platform for this transaction (optional). Only allowed when [separate charges and transfers](https://stripe.com/docs/connect/separate-charges-and-transfers) are used.
sig { returns(T::Array[String]) }
attr_reader :subsellers
end
class Payto < Stripe::StripeObject
class MandateOptions < Stripe::StripeObject
# Amount that will be collected. It is required when `amount_type` is `fixed`.
sig { returns(T.nilable(Integer)) }
attr_reader :amount
# The type of amount that will be collected. The amount charged must be exact or up to the value of `amount` param for `fixed` or `maximum` type respectively.
sig { returns(T.nilable(String)) }
attr_reader :amount_type
# Date, in YYYY-MM-DD format, after which payments will not be collected. Defaults to no end date.
sig { returns(T.nilable(String)) }
attr_reader :end_date
# The periodicity at which payments will be collected.
sig { returns(T.nilable(String)) }
attr_reader :payment_schedule
# The number of payments that will be made during a payment period. Defaults to 1 except for when `payment_schedule` is `adhoc`. In that case, it defaults to no limit.
sig { returns(T.nilable(Integer)) }
attr_reader :payments_per_period
# The purpose for which payments are made. Defaults to retail.
sig { returns(T.nilable(String)) }
attr_reader :purpose
# Date, in YYYY-MM-DD format, from which payments will be collected. Defaults to confirmation time.
sig { returns(T.nilable(String)) }
attr_reader :start_date
end
# Attribute for field mandate_options
sig { returns(MandateOptions) }
attr_reader :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Pix < Stripe::StripeObject
# The number of seconds after which Pix payment will expire.
sig { returns(T.nilable(Integer)) }
attr_reader :expires_after_seconds
end
class RevolutPay < Stripe::StripeObject
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class SamsungPay < Stripe::StripeObject
# Controls when the funds will be captured from the customer's account.
sig { returns(String) }
attr_reader :capture_method
end
class SepaDebit < Stripe::StripeObject
class MandateOptions < Stripe::StripeObject
# Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'STRIPE'.
sig { returns(String) }
attr_reader :reference_prefix
end
# Attribute for field mandate_options
sig { returns(MandateOptions) }
attr_reader :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(String) }
attr_reader :target_date
end
class Sofort < Stripe::StripeObject
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Swish < Stripe::StripeObject
# The order reference that will be displayed to customers in the Swish application. Defaults to the `id` of the Payment Intent.
sig { returns(T.nilable(String)) }
attr_reader :reference
end
class UsBankAccount < Stripe::StripeObject
class FinancialConnections < Stripe::StripeObject
class Filters < Stripe::StripeObject
# The account subcategories to use to filter for possible accounts to link. Valid subcategories are `checking` and `savings`.
sig { returns(T::Array[String]) }
attr_reader :account_subcategories
# The institution to use to filter for possible accounts to link.
sig { returns(String) }
attr_reader :institution
end
class ManualEntry < Stripe::StripeObject
# Settings for configuring manual entry of account details.
sig { returns(String) }
attr_reader :mode
end
# Attribute for field filters
sig { returns(Filters) }
attr_reader :filters
# Attribute for field manual_entry
sig { returns(ManualEntry) }
attr_reader :manual_entry
# The list of permissions to request. The `payment_method` permission must be included.
sig { returns(T::Array[String]) }
attr_reader :permissions
# Data features requested to be retrieved upon account creation.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :prefetch
# For webview integrations only. Upon completing OAuth login in the native browser, the user will be redirected to this URL to return to your app.
sig { returns(String) }
attr_reader :return_url
end
# Attribute for field financial_connections
sig { returns(FinancialConnections) }
attr_reader :financial_connections
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(String) }
attr_reader :target_date
# Bank account verification method.
sig { returns(String) }
attr_reader :verification_method
end
# Attribute for field acss_debit
sig { returns(AcssDebit) }
attr_reader :acss_debit
# Attribute for field affirm
sig { returns(Affirm) }
attr_reader :affirm
# Attribute for field afterpay_clearpay
sig { returns(AfterpayClearpay) }
attr_reader :afterpay_clearpay
# Attribute for field alipay
sig { returns(Alipay) }
attr_reader :alipay
# Attribute for field amazon_pay
sig { returns(AmazonPay) }
attr_reader :amazon_pay
# Attribute for field au_becs_debit
sig { returns(AuBecsDebit) }
attr_reader :au_becs_debit
# Attribute for field bacs_debit
sig { returns(BacsDebit) }
attr_reader :bacs_debit
# Attribute for field bancontact
sig { returns(Bancontact) }
attr_reader :bancontact
# Attribute for field boleto
sig { returns(Boleto) }
attr_reader :boleto
# Attribute for field card
sig { returns(Card) }
attr_reader :card
# Attribute for field cashapp
sig { returns(Cashapp) }
attr_reader :cashapp
# Attribute for field customer_balance
sig { returns(CustomerBalance) }
attr_reader :customer_balance
# Attribute for field eps
sig { returns(Eps) }
attr_reader :eps
# Attribute for field fpx
sig { returns(Fpx) }
attr_reader :fpx
# Attribute for field giropay
sig { returns(Giropay) }
attr_reader :giropay
# Attribute for field grabpay
sig { returns(Grabpay) }
attr_reader :grabpay
# Attribute for field ideal
sig { returns(Ideal) }
attr_reader :ideal
# Attribute for field kakao_pay
sig { returns(KakaoPay) }
attr_reader :kakao_pay
# Attribute for field klarna
sig { returns(Klarna) }
attr_reader :klarna
# Attribute for field konbini
sig { returns(Konbini) }
attr_reader :konbini
# Attribute for field kr_card
sig { returns(KrCard) }
attr_reader :kr_card
# Attribute for field link
sig { returns(Link) }
attr_reader :link
# Attribute for field mobilepay
sig { returns(Mobilepay) }
attr_reader :mobilepay
# Attribute for field multibanco
sig { returns(Multibanco) }
attr_reader :multibanco
# Attribute for field naver_pay
sig { returns(NaverPay) }
attr_reader :naver_pay
# Attribute for field oxxo
sig { returns(Oxxo) }
attr_reader :oxxo
# Attribute for field p24
sig { returns(P24) }
attr_reader :p24
# Attribute for field payco
sig { returns(Payco) }
attr_reader :payco
# Attribute for field paynow
sig { returns(Paynow) }
attr_reader :paynow
# Attribute for field paypal
sig { returns(Paypal) }
attr_reader :paypal
# Attribute for field payto
sig { returns(Payto) }
attr_reader :payto
# Attribute for field pix
sig { returns(Pix) }
attr_reader :pix
# Attribute for field revolut_pay
sig { returns(RevolutPay) }
attr_reader :revolut_pay
# Attribute for field samsung_pay
sig { returns(SamsungPay) }
attr_reader :samsung_pay
# Attribute for field sepa_debit
sig { returns(SepaDebit) }
attr_reader :sepa_debit
# Attribute for field sofort
sig { returns(Sofort) }
attr_reader :sofort
# Attribute for field swish
sig { returns(Swish) }
attr_reader :swish
# Attribute for field us_bank_account
sig { returns(UsBankAccount) }
attr_reader :us_bank_account
end
class Permissions < Stripe::StripeObject
class Update < Stripe::StripeObject
# Determines which entity is allowed to update the line items.
#
# Default is `client_only`. Stripe Checkout client will automatically update the line items. If set to `server_only`, only your server is allowed to update the line items.
#
# When set to `server_only`, you must add the onLineItemsChange event handler when initializing the Stripe Checkout client and manually update the line items from your server using the Stripe API.
sig { returns(T.nilable(String)) }
attr_reader :line_items
# Determines which entity is allowed to update the shipping details.
#
# Default is `client_only`. Stripe Checkout client will automatically update the shipping details. If set to `server_only`, only your server is allowed to update the shipping details.
#
# When set to `server_only`, you must add the onShippingDetailsChange event handler when initializing the Stripe Checkout client and manually update the shipping details from your server using the Stripe API.
sig { returns(T.nilable(String)) }
attr_reader :shipping_details
end
# Permissions for updating the Checkout Session.
sig { returns(T.nilable(Update)) }
attr_reader :update
# Determines which entity is allowed to update the line items.
#
# Default is `client_only`. Stripe Checkout client will automatically update the line items. If set to `server_only`, only your server is allowed to update the line items.
#
# When set to `server_only`, you must add the onLineItemsChange event handler when initializing the Stripe Checkout client and manually update the line items from your server using the Stripe API.
sig { returns(T.nilable(String)) }
attr_reader :update_line_items
# Determines which entity is allowed to update the shipping details.
#
# Default is `client_only`. Stripe Checkout client will automatically update the shipping details. If set to `server_only`, only your server is allowed to update the shipping details.
#
# When set to `server_only`, you must add the onShippingDetailsChange event handler when initializing the Stripe Checkout client and manually update the shipping details from your server using the Stripe API.
sig { returns(T.nilable(String)) }
attr_reader :update_shipping_details
end
class PhoneNumberCollection < Stripe::StripeObject
# Indicates whether phone number collection is enabled for the session
sig { returns(T::Boolean) }
attr_reader :enabled
end
class PresentmentDetails < Stripe::StripeObject
# Amount intended to be collected by this payment, denominated in presentment_currency.
sig { returns(Integer) }
attr_reader :presentment_amount
# Currency presented to the customer during payment.
sig { returns(String) }
attr_reader :presentment_currency
end
class SavedPaymentMethodOptions < Stripe::StripeObject
# Uses the `allow_redisplay` value of each saved payment method to filter the set presented to a returning customer. By default, only saved payment methods with ’allow_redisplay: ‘always’ are shown in Checkout.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :allow_redisplay_filters
# Enable customers to choose if they wish to remove their saved payment methods. Disabled by default.
sig { returns(T.nilable(String)) }
attr_reader :payment_method_remove
# Enable customers to choose if they wish to save their payment method for future use. Disabled by default.
sig { returns(T.nilable(String)) }
attr_reader :payment_method_save
end
class ShippingAddressCollection < Stripe::StripeObject
# An array of two-letter ISO country codes representing which countries Checkout should provide as options for
# shipping locations. Unsupported country codes: `AS, CX, CC, CU, HM, IR, KP, MH, FM, NF, MP, PW, SY, UM, VI`.
sig { returns(T::Array[String]) }
attr_reader :allowed_countries
end
class ShippingCost < Stripe::StripeObject
class Tax < Stripe::StripeObject
# Amount of tax applied for this rate.
sig { returns(Integer) }
attr_reader :amount
# Tax rates can be applied to [invoices](/invoicing/taxes/tax-rates), [subscriptions](/billing/taxes/tax-rates) and [Checkout Sessions](/payments/checkout/use-manual-tax-rates) to collect tax.
#
# Related guide: [Tax rates](/billing/taxes/tax-rates)
sig { returns(Stripe::TaxRate) }
attr_reader :rate
# 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.
sig { returns(T.nilable(String)) }
attr_reader :taxability_reason
# The amount on which tax is calculated, in cents (or local equivalent).
sig { returns(T.nilable(Integer)) }
attr_reader :taxable_amount
end
# Total shipping cost before any discounts or taxes are applied.
sig { returns(Integer) }
attr_reader :amount_subtotal
# Total tax amount applied due to shipping costs. If no tax was applied, defaults to 0.
sig { returns(Integer) }
attr_reader :amount_tax
# Total shipping cost after discounts and taxes are applied.
sig { returns(Integer) }
attr_reader :amount_total
# The ID of the ShippingRate for this order.
sig { returns(T.nilable(T.any(String, Stripe::ShippingRate))) }
attr_reader :shipping_rate
# The taxes applied to the shipping rate.
sig { returns(T::Array[Tax]) }
attr_reader :taxes
end
class ShippingOption < Stripe::StripeObject
# A non-negative integer in cents representing how much to charge.
sig { returns(Integer) }
attr_reader :shipping_amount
# The shipping rate.
sig { returns(T.any(String, Stripe::ShippingRate)) }
attr_reader :shipping_rate
end
class TaxIdCollection < Stripe::StripeObject
# Indicates whether tax ID collection is enabled for the session
sig { returns(T::Boolean) }
attr_reader :enabled
# Indicates whether a tax ID is required on the payment page
sig { returns(String) }
attr_reader :required
end
class TotalDetails < Stripe::StripeObject
class Breakdown < Stripe::StripeObject
class Discount < Stripe::StripeObject
# The amount discounted.
sig { returns(Integer) }
attr_reader :amount
# A discount represents the actual application of a [coupon](https://stripe.com/docs/api#coupons) or [promotion code](https://stripe.com/docs/api#promotion_codes).
# It contains information about when the discount began, when it will end, and what it is applied to.
#
# Related guide: [Applying discounts to subscriptions](https://stripe.com/docs/billing/subscriptions/discounts)
sig { returns(Stripe::Discount) }
attr_reader :discount
end
class Tax < Stripe::StripeObject
# Amount of tax applied for this rate.
sig { returns(Integer) }
attr_reader :amount
# Tax rates can be applied to [invoices](/invoicing/taxes/tax-rates), [subscriptions](/billing/taxes/tax-rates) and [Checkout Sessions](/payments/checkout/use-manual-tax-rates) to collect tax.
#
# Related guide: [Tax rates](/billing/taxes/tax-rates)
sig { returns(Stripe::TaxRate) }
attr_reader :rate
# 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.
sig { returns(T.nilable(String)) }
attr_reader :taxability_reason
# The amount on which tax is calculated, in cents (or local equivalent).
sig { returns(T.nilable(Integer)) }
attr_reader :taxable_amount
end
# The aggregated discounts.
sig { returns(T::Array[Discount]) }
attr_reader :discounts
# The aggregated tax amounts by rate.
sig { returns(T::Array[Tax]) }
attr_reader :taxes
end
# This is the sum of all the discounts.
sig { returns(Integer) }
attr_reader :amount_discount
# This is the sum of all the shipping amounts.
sig { returns(T.nilable(Integer)) }
attr_reader :amount_shipping
# This is the sum of all the tax amounts.
sig { returns(Integer) }
attr_reader :amount_tax
# Attribute for field breakdown
sig { returns(Breakdown) }
attr_reader :breakdown
end
class WalletOptions < Stripe::StripeObject
class Link < Stripe::StripeObject
# Describes whether Checkout should display Link. Defaults to `auto`.
sig { returns(String) }
attr_reader :display
end
# Attribute for field link
sig { returns(Link) }
attr_reader :link
end
# Settings for price localization with [Adaptive Pricing](https://docs.stripe.com/payments/checkout/adaptive-pricing).
sig { returns(T.nilable(AdaptivePricing)) }
attr_reader :adaptive_pricing
# When set, provides configuration for actions to take if this Checkout Session expires.
sig { returns(T.nilable(AfterExpiration)) }
attr_reader :after_expiration
# Enables user redeemable promotion codes.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :allow_promotion_codes
# Total of all items before discounts or taxes are applied.
sig { returns(T.nilable(Integer)) }
attr_reader :amount_subtotal
# Total of all items after discounts and taxes are applied.
sig { returns(T.nilable(Integer)) }
attr_reader :amount_total
# Attribute for field automatic_tax
sig { returns(AutomaticTax) }
attr_reader :automatic_tax
# Describes whether Checkout should collect the customer's billing address. Defaults to `auto`.
sig { returns(T.nilable(String)) }
attr_reader :billing_address_collection
# If set, Checkout displays a back button and customers will be directed to this URL if they decide to cancel payment and return to your website.
sig { returns(T.nilable(String)) }
attr_reader :cancel_url
# A unique string to reference the Checkout Session. This can be a
# customer ID, a cart ID, or similar, and can be used to reconcile the
# Session with your internal systems.
sig { returns(T.nilable(String)) }
attr_reader :client_reference_id
# The client secret of your Checkout Session. Applies to Checkout Sessions with `ui_mode: embedded` or `ui_mode: custom`. For `ui_mode: embedded`, the client secret is to be used when initializing Stripe.js embedded checkout.
# For `ui_mode: custom`, use the client secret with [initCheckout](https://stripe.com/docs/js/custom_checkout/init) on your front end.
sig { returns(T.nilable(String)) }
attr_reader :client_secret
# Information about the customer collected within the Checkout Session.
sig { returns(T.nilable(CollectedInformation)) }
attr_reader :collected_information
# Results of `consent_collection` for this session.
sig { returns(T.nilable(Consent)) }
attr_reader :consent
# When set, provides configuration for the Checkout Session to gather active consent from customers.
sig { returns(T.nilable(ConsentCollection)) }
attr_reader :consent_collection
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# 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).
sig { returns(T.nilable(String)) }
attr_reader :currency
# Currency conversion details for [Adaptive Pricing](https://docs.stripe.com/payments/checkout/adaptive-pricing) sessions created before 2025-03-31.
sig { returns(T.nilable(CurrencyConversion)) }
attr_reader :currency_conversion
# Collect additional information from your customer using custom fields. Up to 3 fields are supported.
sig { returns(T::Array[CustomField]) }
attr_reader :custom_fields
# Attribute for field custom_text
sig { returns(CustomText) }
attr_reader :custom_text
# The ID of the customer for this Session.
# For Checkout Sessions in `subscription` mode or Checkout Sessions with `customer_creation` set as `always` in `payment` mode, Checkout
# will create a new customer object based on information provided
# during the payment flow unless an existing customer was provided when
# the Session was created.
sig { returns(T.nilable(T.any(String, Stripe::Customer))) }
attr_reader :customer
# The ID of the account for this Session.
sig { returns(T.nilable(String)) }
attr_reader :customer_account
# Configure whether a Checkout Session creates a Customer when the Checkout Session completes.
sig { returns(T.nilable(String)) }
attr_reader :customer_creation
# The customer details including the customer's tax exempt status and the customer's tax IDs. Customer's address details are not present on Sessions in `setup` mode.
sig { returns(T.nilable(CustomerDetails)) }
attr_reader :customer_details
# If provided, this value will be used when the Customer object is created.
# If not provided, customers will be asked to enter their email address.
# Use this parameter to prefill customer data if you already have an email
# on file. To access information about the customer once the payment flow is
# complete, use the `customer` attribute.
sig { returns(T.nilable(String)) }
attr_reader :customer_email
# List of coupons and promotion codes attached to the Checkout Session.
sig { returns(T.nilable(T::Array[Discount])) }
attr_reader :discounts
# The timestamp at which the Checkout Session will expire.
sig { returns(Integer) }
attr_reader :expires_at
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# ID of the invoice created by the Checkout Session, if it exists.
sig { returns(T.nilable(T.any(String, Stripe::Invoice))) }
attr_reader :invoice
# Details on the state of invoice creation for the Checkout Session.
sig { returns(T.nilable(InvoiceCreation)) }
attr_reader :invoice_creation
# The line items purchased by the customer.
sig { returns(Stripe::ListObject) }
attr_reader :line_items
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# The IETF language tag of the locale Checkout is displayed in. If blank or `auto`, the browser's locale is used.
sig { returns(T.nilable(String)) }
attr_reader :locale
# 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.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# The mode of the Checkout Session.
sig { returns(String) }
attr_reader :mode
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The optional items presented to the customer at checkout.
sig { returns(T.nilable(T::Array[OptionalItem])) }
attr_reader :optional_items
# The ID of the PaymentIntent for Checkout Sessions in `payment` mode. You can't confirm or cancel the PaymentIntent for a Checkout Session. To cancel, [expire the Checkout Session](https://stripe.com/docs/api/checkout/sessions/expire) instead.
sig { returns(T.nilable(T.any(String, Stripe::PaymentIntent))) }
attr_reader :payment_intent
# The ID of the Payment Link that created this Session.
sig { returns(T.nilable(T.any(String, Stripe::PaymentLink))) }
attr_reader :payment_link
# Configure whether a Checkout Session should collect a payment method. Defaults to `always`.
sig { returns(T.nilable(String)) }
attr_reader :payment_method_collection
# Information about the payment method configuration used for this Checkout session if using dynamic payment methods.
sig { returns(T.nilable(PaymentMethodConfigurationDetails)) }
attr_reader :payment_method_configuration_details
# Payment-method-specific configuration for the PaymentIntent or SetupIntent of this CheckoutSession.
sig { returns(T.nilable(PaymentMethodOptions)) }
attr_reader :payment_method_options
# A list of the types of payment methods (e.g. card) this Checkout
# Session is allowed to accept.
sig { returns(T::Array[String]) }
attr_reader :payment_method_types
# The payment status of the Checkout Session, one of `paid`, `unpaid`, or `no_payment_required`.
# You can use this value to decide when to fulfill your customer's order.
sig { returns(String) }
attr_reader :payment_status
# This property is used to set up permissions for various actions (e.g., update) on the CheckoutSession object.
#
# For specific permissions, please refer to their dedicated subsections, such as `permissions.update_shipping_details`.
sig { returns(T.nilable(Permissions)) }
attr_reader :permissions
# Attribute for field phone_number_collection
sig { returns(PhoneNumberCollection) }
attr_reader :phone_number_collection
# Attribute for field presentment_details
sig { returns(PresentmentDetails) }
attr_reader :presentment_details
# The ID of the original expired Checkout Session that triggered the recovery flow.
sig { returns(T.nilable(String)) }
attr_reader :recovered_from
# This parameter applies to `ui_mode: embedded`. Learn more about the [redirect behavior](https://stripe.com/docs/payments/checkout/custom-success-page?payment-ui=embedded-form) of embedded sessions. Defaults to `always`.
sig { returns(String) }
attr_reader :redirect_on_completion
# Applies to Checkout Sessions with `ui_mode: embedded` or `ui_mode: custom`. The URL to redirect your customer back to after they authenticate or cancel their payment on the payment method's app or site.
sig { returns(String) }
attr_reader :return_url
# Controls saved payment method settings for the session. Only available in `payment` and `subscription` mode.
sig { returns(T.nilable(SavedPaymentMethodOptions)) }
attr_reader :saved_payment_method_options
# The ID of the SetupIntent for Checkout Sessions in `setup` mode. You can't confirm or cancel the SetupIntent for a Checkout Session. To cancel, [expire the Checkout Session](https://stripe.com/docs/api/checkout/sessions/expire) instead.
sig { returns(T.nilable(T.any(String, Stripe::SetupIntent))) }
attr_reader :setup_intent
# When set, provides configuration for Checkout to collect a shipping address from a customer.
sig { returns(T.nilable(ShippingAddressCollection)) }
attr_reader :shipping_address_collection
# The details of the customer cost of shipping, including the customer chosen ShippingRate.
sig { returns(T.nilable(ShippingCost)) }
attr_reader :shipping_cost
# The shipping rate options applied to this Session.
sig { returns(T::Array[ShippingOption]) }
attr_reader :shipping_options
# The status of the Checkout Session, one of `open`, `complete`, or `expired`.
sig { returns(T.nilable(String)) }
attr_reader :status
# Describes the type of transaction being performed by Checkout in order to customize
# relevant text on the page, such as the submit button. `submit_type` can only be
# specified on Checkout Sessions in `payment` mode. If blank or `auto`, `pay` is used.
sig { returns(T.nilable(String)) }
attr_reader :submit_type
# The ID of the [Subscription](https://stripe.com/docs/api/subscriptions) for Checkout Sessions in `subscription` mode.
sig { returns(T.nilable(T.any(String, Stripe::Subscription))) }
attr_reader :subscription
# The URL the customer will be directed to after the payment or
# subscription creation is successful.
sig { returns(T.nilable(String)) }
attr_reader :success_url
# Attribute for field tax_id_collection
sig { returns(TaxIdCollection) }
attr_reader :tax_id_collection
# Tax and discount details for the computed total amount.
sig { returns(T.nilable(TotalDetails)) }
attr_reader :total_details
# The UI mode of the Session. Defaults to `hosted`.
sig { returns(T.nilable(String)) }
attr_reader :ui_mode
# The URL to the Checkout Session. Applies to Checkout Sessions with `ui_mode: hosted`. Redirect customers to this URL to take them to Checkout. If you’re using [Custom Domains](https://stripe.com/docs/payments/checkout/custom-domains), the URL will use your subdomain. Otherwise, it’ll use `checkout.stripe.com.`
# This value is only present when the session is active.
sig { returns(T.nilable(String)) }
attr_reader :url
# Wallet-specific configuration for this Checkout Session.
sig { returns(T.nilable(WalletOptions)) }
attr_reader :wallet_options
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
class CustomerDetails < Stripe::RequestParams
# Customer's email address.
sig { returns(String) }
attr_accessor :email
sig { params(email: String).void }
def initialize(email: nil); end
end
# Only return Checkout Sessions that were created during the given date interval.
sig { returns(T.nilable(T.any(::Stripe::Checkout::Session::ListParams::Created, Integer))) }
attr_accessor :created
# Only return the Checkout Sessions for the Customer specified.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# Only return the Checkout Sessions for the Account specified.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# Only return the Checkout Sessions for the Customer details specified.
sig { returns(T.nilable(::Stripe::Checkout::Session::ListParams::CustomerDetails)) }
attr_accessor :customer_details
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Only return the Checkout Session for the PaymentIntent specified.
sig { returns(T.nilable(String)) }
attr_accessor :payment_intent
# Only return the Checkout Sessions for the Payment Link specified.
sig { returns(T.nilable(String)) }
attr_accessor :payment_link
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return the Checkout Sessions matching the given status.
sig { returns(T.nilable(String)) }
attr_accessor :status
# Only return the Checkout Session for the subscription specified.
sig { returns(T.nilable(String)) }
attr_accessor :subscription
sig {
params(created: T.nilable(T.any(::Stripe::Checkout::Session::ListParams::Created, Integer)), customer: T.nilable(String), customer_account: T.nilable(String), customer_details: T.nilable(::Stripe::Checkout::Session::ListParams::CustomerDetails), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), payment_intent: T.nilable(String), payment_link: T.nilable(String), starting_after: T.nilable(String), status: T.nilable(String), subscription: T.nilable(String)).void
}
def initialize(
created: nil,
customer: nil,
customer_account: nil,
customer_details: nil,
ending_before: nil,
expand: nil,
limit: nil,
payment_intent: nil,
payment_link: nil,
starting_after: nil,
status: nil,
subscription: nil
); end
end
class CreateParams < Stripe::RequestParams
class AdaptivePricing < Stripe::RequestParams
# Set to `true` to enable [Adaptive Pricing](https://docs.stripe.com/payments/checkout/adaptive-pricing). Defaults to your [dashboard setting](https://dashboard.stripe.com/settings/adaptive-pricing).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :enabled
sig { params(enabled: T.nilable(T::Boolean)).void }
def initialize(enabled: nil); end
end
class AfterExpiration < Stripe::RequestParams
class Recovery < Stripe::RequestParams
# Enables user redeemable promotion codes on the recovered Checkout Sessions. Defaults to `false`
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :allow_promotion_codes
# If `true`, a recovery URL will be generated to recover this Checkout Session if it
# expires before a successful transaction is completed. It will be attached to the
# Checkout Session object upon expiration.
sig { returns(T::Boolean) }
attr_accessor :enabled
sig { params(allow_promotion_codes: T.nilable(T::Boolean), enabled: T::Boolean).void }
def initialize(allow_promotion_codes: nil, enabled: nil); end
end
# Configure a Checkout Session that can be used to recover an expired session.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::AfterExpiration::Recovery))
}
attr_accessor :recovery
sig {
params(recovery: T.nilable(::Stripe::Checkout::Session::CreateParams::AfterExpiration::Recovery)).void
}
def initialize(recovery: nil); end
end
class AutomaticTax < Stripe::RequestParams
class Liability < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# Set to `true` to [calculate tax automatically](https://docs.stripe.com/tax) using the customer's location.
#
# Enabling this parameter causes Checkout to collect any billing address information necessary for tax calculation.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::AutomaticTax::Liability))
}
attr_accessor :liability
sig {
params(enabled: T::Boolean, liability: T.nilable(::Stripe::Checkout::Session::CreateParams::AutomaticTax::Liability)).void
}
def initialize(enabled: nil, liability: nil); end
end
class ConsentCollection < Stripe::RequestParams
class PaymentMethodReuseAgreement < Stripe::RequestParams
# Determines the position and visibility of the payment method reuse agreement in the UI. When set to `auto`, Stripe's
# defaults will be used. When set to `hidden`, the payment method reuse agreement text will always be hidden in the UI.
sig { returns(String) }
attr_accessor :position
sig { params(position: String).void }
def initialize(position: nil); end
end
# Determines the display of payment method reuse agreement text in the UI. If set to `hidden`, it will hide legal text related to the reuse of a payment method.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::ConsentCollection::PaymentMethodReuseAgreement))
}
attr_accessor :payment_method_reuse_agreement
# If set to `auto`, enables the collection of customer consent for promotional communications. The Checkout
# Session will determine whether to display an option to opt into promotional communication
# from the merchant depending on the customer's locale. Only available to US merchants.
sig { returns(T.nilable(String)) }
attr_accessor :promotions
# If set to `required`, it requires customers to check a terms of service checkbox before being able to pay.
# There must be a valid terms of service URL set in your [Dashboard settings](https://dashboard.stripe.com/settings/public).
sig { returns(T.nilable(String)) }
attr_accessor :terms_of_service
sig {
params(payment_method_reuse_agreement: T.nilable(::Stripe::Checkout::Session::CreateParams::ConsentCollection::PaymentMethodReuseAgreement), promotions: T.nilable(String), terms_of_service: T.nilable(String)).void
}
def initialize(
payment_method_reuse_agreement: nil,
promotions: nil,
terms_of_service: nil
); end
end
class CustomField < Stripe::RequestParams
class Dropdown < Stripe::RequestParams
class Option < Stripe::RequestParams
# The label for the option, displayed to the customer. Up to 100 characters.
sig { returns(String) }
attr_accessor :label
# The value for this option, not displayed to the customer, used by your integration to reconcile the option selected by the customer. Must be unique to this option, alphanumeric, and up to 100 characters.
sig { returns(String) }
attr_accessor :value
sig { params(label: String, value: String).void }
def initialize(label: nil, value: nil); end
end
# The value that will pre-fill the field on the payment page.Must match a `value` in the `options` array.
sig { returns(T.nilable(String)) }
attr_accessor :default_value
# The options available for the customer to select. Up to 200 options allowed.
sig {
returns(T::Array[::Stripe::Checkout::Session::CreateParams::CustomField::Dropdown::Option])
}
attr_accessor :options
sig {
params(default_value: T.nilable(String), options: T::Array[::Stripe::Checkout::Session::CreateParams::CustomField::Dropdown::Option]).void
}
def initialize(default_value: nil, options: nil); end
end
class Label < Stripe::RequestParams
# Custom text for the label, displayed to the customer. Up to 50 characters.
sig { returns(String) }
attr_accessor :custom
# The type of the label.
sig { returns(String) }
attr_accessor :type
sig { params(custom: String, type: String).void }
def initialize(custom: nil, type: nil); end
end
class Numeric < Stripe::RequestParams
# The value that will pre-fill the field on the payment page.
sig { returns(T.nilable(String)) }
attr_accessor :default_value
# The maximum character length constraint for the customer's input.
sig { returns(T.nilable(Integer)) }
attr_accessor :maximum_length
# The minimum character length requirement for the customer's input.
sig { returns(T.nilable(Integer)) }
attr_accessor :minimum_length
sig {
params(default_value: T.nilable(String), maximum_length: T.nilable(Integer), minimum_length: T.nilable(Integer)).void
}
def initialize(default_value: nil, maximum_length: nil, minimum_length: nil); end
end
class Text < Stripe::RequestParams
# The value that will pre-fill the field on the payment page.
sig { returns(T.nilable(String)) }
attr_accessor :default_value
# The maximum character length constraint for the customer's input.
sig { returns(T.nilable(Integer)) }
attr_accessor :maximum_length
# The minimum character length requirement for the customer's input.
sig { returns(T.nilable(Integer)) }
attr_accessor :minimum_length
sig {
params(default_value: T.nilable(String), maximum_length: T.nilable(Integer), minimum_length: T.nilable(Integer)).void
}
def initialize(default_value: nil, maximum_length: nil, minimum_length: nil); end
end
# Configuration for `type=dropdown` fields.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::CustomField::Dropdown))
}
attr_accessor :dropdown
# String of your choice that your integration can use to reconcile this field. Must be unique to this field, alphanumeric, and up to 200 characters.
sig { returns(String) }
attr_accessor :key
# The label for the field, displayed to the customer.
sig { returns(::Stripe::Checkout::Session::CreateParams::CustomField::Label) }
attr_accessor :label
# Configuration for `type=numeric` fields.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::CustomField::Numeric))
}
attr_accessor :numeric
# Whether the customer is required to complete the field before completing the Checkout Session. Defaults to `false`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :optional
# Configuration for `type=text` fields.
sig { returns(T.nilable(::Stripe::Checkout::Session::CreateParams::CustomField::Text)) }
attr_accessor :text
# The type of the field.
sig { returns(String) }
attr_accessor :type
sig {
params(dropdown: T.nilable(::Stripe::Checkout::Session::CreateParams::CustomField::Dropdown), key: String, label: ::Stripe::Checkout::Session::CreateParams::CustomField::Label, numeric: T.nilable(::Stripe::Checkout::Session::CreateParams::CustomField::Numeric), optional: T.nilable(T::Boolean), text: T.nilable(::Stripe::Checkout::Session::CreateParams::CustomField::Text), type: String).void
}
def initialize(
dropdown: nil,
key: nil,
label: nil,
numeric: nil,
optional: nil,
text: nil,
type: nil
); end
end
class CustomText < Stripe::RequestParams
class AfterSubmit < Stripe::RequestParams
# Text may be up to 1200 characters in length.
sig { returns(String) }
attr_accessor :message
sig { params(message: String).void }
def initialize(message: nil); end
end
class ShippingAddress < Stripe::RequestParams
# Text may be up to 1200 characters in length.
sig { returns(String) }
attr_accessor :message
sig { params(message: String).void }
def initialize(message: nil); end
end
class Submit < Stripe::RequestParams
# Text may be up to 1200 characters in length.
sig { returns(String) }
attr_accessor :message
sig { params(message: String).void }
def initialize(message: nil); end
end
class TermsOfServiceAcceptance < Stripe::RequestParams
# Text may be up to 1200 characters in length.
sig { returns(String) }
attr_accessor :message
sig { params(message: String).void }
def initialize(message: nil); end
end
# Custom text that should be displayed after the payment confirmation button.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Checkout::Session::CreateParams::CustomText::AfterSubmit))))
}
attr_accessor :after_submit
# Custom text that should be displayed alongside shipping address collection.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Checkout::Session::CreateParams::CustomText::ShippingAddress))))
}
attr_accessor :shipping_address
# Custom text that should be displayed alongside the payment confirmation button.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Checkout::Session::CreateParams::CustomText::Submit))))
}
attr_accessor :submit
# Custom text that should be displayed in place of the default terms of service agreement text.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Checkout::Session::CreateParams::CustomText::TermsOfServiceAcceptance))))
}
attr_accessor :terms_of_service_acceptance
sig {
params(after_submit: T.nilable(T.nilable(T.any(String, ::Stripe::Checkout::Session::CreateParams::CustomText::AfterSubmit))), shipping_address: T.nilable(T.nilable(T.any(String, ::Stripe::Checkout::Session::CreateParams::CustomText::ShippingAddress))), submit: T.nilable(T.nilable(T.any(String, ::Stripe::Checkout::Session::CreateParams::CustomText::Submit))), terms_of_service_acceptance: T.nilable(T.nilable(T.any(String, ::Stripe::Checkout::Session::CreateParams::CustomText::TermsOfServiceAcceptance)))).void
}
def initialize(
after_submit: nil,
shipping_address: nil,
submit: nil,
terms_of_service_acceptance: nil
); end
end
class CustomerUpdate < Stripe::RequestParams
# Describes whether Checkout saves the billing address onto `customer.address`.
# To always collect a full billing address, use `billing_address_collection`. Defaults to `never`.
sig { returns(T.nilable(String)) }
attr_accessor :address
# Describes whether Checkout saves the name onto `customer.name`. Defaults to `never`.
sig { returns(T.nilable(String)) }
attr_accessor :name
# Describes whether Checkout saves shipping information onto `customer.shipping`.
# To collect shipping information, use `shipping_address_collection`. Defaults to `never`.
sig { returns(T.nilable(String)) }
attr_accessor :shipping
sig {
params(address: T.nilable(String), name: T.nilable(String), shipping: T.nilable(String)).void
}
def initialize(address: nil, name: nil, shipping: nil); end
end
class Discount < Stripe::RequestParams
# The ID of the coupon to apply to this Session.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# The ID of a promotion code to apply to this Session.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig { params(coupon: T.nilable(String), promotion_code: T.nilable(String)).void }
def initialize(coupon: nil, promotion_code: nil); end
end
class InvoiceCreation < Stripe::RequestParams
class InvoiceData < Stripe::RequestParams
class CustomField < Stripe::RequestParams
# The name of the custom field. This may be up to 40 characters.
sig { returns(String) }
attr_accessor :name
# The value of the custom field. This may be up to 140 characters.
sig { returns(String) }
attr_accessor :value
sig { params(name: String, value: String).void }
def initialize(name: nil, value: nil); end
end
class Issuer < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
class RenderingOptions < Stripe::RequestParams
# How line-item prices and amounts will be displayed with respect to tax on invoice PDFs. One of `exclude_tax` or `include_inclusive_tax`. `include_inclusive_tax` will include inclusive tax (and exclude exclusive tax) in invoice PDF amounts. `exclude_tax` will exclude all tax (inclusive and exclusive alike) from invoice PDF amounts.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :amount_tax_display
sig { params(amount_tax_display: T.nilable(T.nilable(T.any(String, String)))).void }
def initialize(amount_tax_display: nil); end
end
# The account tax IDs associated with the invoice.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :account_tax_ids
# Default custom fields to be displayed on invoices for this customer.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Checkout::Session::CreateParams::InvoiceCreation::InvoiceData::CustomField]))))
}
attr_accessor :custom_fields
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Default footer to be displayed on invoices for this customer.
sig { returns(T.nilable(String)) }
attr_accessor :footer
# The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::InvoiceCreation::InvoiceData::Issuer))
}
attr_accessor :issuer
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Default options for invoice PDF rendering for this customer.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Checkout::Session::CreateParams::InvoiceCreation::InvoiceData::RenderingOptions))))
}
attr_accessor :rendering_options
sig {
params(account_tax_ids: T.nilable(T.nilable(T.any(String, T::Array[String]))), custom_fields: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Checkout::Session::CreateParams::InvoiceCreation::InvoiceData::CustomField]))), description: T.nilable(String), footer: T.nilable(String), issuer: T.nilable(::Stripe::Checkout::Session::CreateParams::InvoiceCreation::InvoiceData::Issuer), metadata: T.nilable(T::Hash[String, String]), rendering_options: T.nilable(T.nilable(T.any(String, ::Stripe::Checkout::Session::CreateParams::InvoiceCreation::InvoiceData::RenderingOptions)))).void
}
def initialize(
account_tax_ids: nil,
custom_fields: nil,
description: nil,
footer: nil,
issuer: nil,
metadata: nil,
rendering_options: nil
); end
end
# Set to `true` to enable invoice creation.
sig { returns(T::Boolean) }
attr_accessor :enabled
# Parameters passed when creating invoices for payment-mode Checkout Sessions.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::InvoiceCreation::InvoiceData))
}
attr_accessor :invoice_data
sig {
params(enabled: T::Boolean, invoice_data: T.nilable(::Stripe::Checkout::Session::CreateParams::InvoiceCreation::InvoiceData)).void
}
def initialize(enabled: nil, invoice_data: nil); end
end
class LineItem < Stripe::RequestParams
class AdjustableQuantity < Stripe::RequestParams
# Set to true if the quantity can be adjusted to any non-negative integer.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The maximum quantity the customer can purchase for the Checkout Session. By default this value is 99. You can specify a value up to 999999.
sig { returns(T.nilable(Integer)) }
attr_accessor :maximum
# The minimum quantity the customer must purchase for the Checkout Session. By default this value is 0.
sig { returns(T.nilable(Integer)) }
attr_accessor :minimum
sig {
params(enabled: T::Boolean, maximum: T.nilable(Integer), minimum: T.nilable(Integer)).void
}
def initialize(enabled: nil, maximum: nil, minimum: nil); end
end
class PriceData < Stripe::RequestParams
class ProductData < Stripe::RequestParams
# The product's description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes.
sig { returns(T.nilable(String)) }
attr_accessor :description
# A list of up to 8 URLs of images for this product, meant to be displayable to the customer.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :images
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The product's name, meant to be displayable to the customer.
sig { returns(String) }
attr_accessor :name
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
sig { returns(T.nilable(String)) }
attr_accessor :tax_code
sig {
params(description: T.nilable(String), images: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), name: String, tax_code: T.nilable(String)).void
}
def initialize(
description: nil,
images: nil,
metadata: nil,
name: nil,
tax_code: nil
); end
end
class Recurring < Stripe::RequestParams
# Specifies billing frequency. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: T.nilable(Integer)).void }
def initialize(interval: nil, interval_count: nil); end
end
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to. One of `product` or `product_data` is required.
sig { returns(T.nilable(String)) }
attr_accessor :product
# Data used to generate a new [Product](https://docs.stripe.com/api/products) object inline. One of `product` or `product_data` is required.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::LineItem::PriceData::ProductData))
}
attr_accessor :product_data
# The recurring components of a price such as `interval` and `interval_count`.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::LineItem::PriceData::Recurring))
}
attr_accessor :recurring
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A non-negative integer in cents (or local equivalent) representing how much to charge. One of `unit_amount` or `unit_amount_decimal` is required.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, product: T.nilable(String), product_data: T.nilable(::Stripe::Checkout::Session::CreateParams::LineItem::PriceData::ProductData), recurring: T.nilable(::Stripe::Checkout::Session::CreateParams::LineItem::PriceData::Recurring), tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
product_data: nil,
recurring: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
# When set, provides configuration for this item’s quantity to be adjusted by the customer during Checkout.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::LineItem::AdjustableQuantity))
}
attr_accessor :adjustable_quantity
# The [tax rates](https://stripe.com/docs/api/tax_rates) that will be applied to this line item depending on the customer's billing/shipping address. We currently support the following countries: US, GB, AU, and all countries in the EU.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :dynamic_tax_rates
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The ID of the [Price](https://stripe.com/docs/api/prices) or [Plan](https://stripe.com/docs/api/plans) object. One of `price` or `price_data` is required.
sig { returns(T.nilable(String)) }
attr_accessor :price
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
sig { returns(T.nilable(::Stripe::Checkout::Session::CreateParams::LineItem::PriceData)) }
attr_accessor :price_data
# The quantity of the line item being purchased. Quantity should not be defined when `recurring.usage_type=metered`.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# The [tax rates](https://stripe.com/docs/api/tax_rates) which apply to this line item.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :tax_rates
sig {
params(adjustable_quantity: T.nilable(::Stripe::Checkout::Session::CreateParams::LineItem::AdjustableQuantity), dynamic_tax_rates: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), price: T.nilable(String), price_data: T.nilable(::Stripe::Checkout::Session::CreateParams::LineItem::PriceData), quantity: T.nilable(Integer), tax_rates: T.nilable(T::Array[String])).void
}
def initialize(
adjustable_quantity: nil,
dynamic_tax_rates: nil,
metadata: nil,
price: nil,
price_data: nil,
quantity: nil,
tax_rates: nil
); end
end
class OptionalItem < Stripe::RequestParams
class AdjustableQuantity < Stripe::RequestParams
# Set to true if the quantity can be adjusted to any non-negative integer.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The maximum quantity of this item the customer can purchase. By default this value is 99. You can specify a value up to 999999.
sig { returns(T.nilable(Integer)) }
attr_accessor :maximum
# The minimum quantity of this item the customer must purchase, if they choose to purchase it. Because this item is optional, the customer will always be able to remove it from their order, even if the `minimum` configured here is greater than 0. By default this value is 0.
sig { returns(T.nilable(Integer)) }
attr_accessor :minimum
sig {
params(enabled: T::Boolean, maximum: T.nilable(Integer), minimum: T.nilable(Integer)).void
}
def initialize(enabled: nil, maximum: nil, minimum: nil); end
end
# When set, provides configuration for the customer to adjust the quantity of the line item created when a customer chooses to add this optional item to their order.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::OptionalItem::AdjustableQuantity))
}
attr_accessor :adjustable_quantity
# The ID of the [Price](https://stripe.com/docs/api/prices) or [Plan](https://stripe.com/docs/api/plans) object.
sig { returns(String) }
attr_accessor :price
# The initial quantity of the line item created when a customer chooses to add this optional item to their order.
sig { returns(Integer) }
attr_accessor :quantity
sig {
params(adjustable_quantity: T.nilable(::Stripe::Checkout::Session::CreateParams::OptionalItem::AdjustableQuantity), price: String, quantity: Integer).void
}
def initialize(adjustable_quantity: nil, price: nil, quantity: nil); end
end
class PaymentIntentData < Stripe::RequestParams
class Shipping < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(String) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: String, line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Shipping address.
sig {
returns(::Stripe::Checkout::Session::CreateParams::PaymentIntentData::Shipping::Address)
}
attr_accessor :address
# The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
sig { returns(T.nilable(String)) }
attr_accessor :carrier
# Recipient name.
sig { returns(String) }
attr_accessor :name
# Recipient phone (including extension).
sig { returns(T.nilable(String)) }
attr_accessor :phone
# The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
sig { returns(T.nilable(String)) }
attr_accessor :tracking_number
sig {
params(address: ::Stripe::Checkout::Session::CreateParams::PaymentIntentData::Shipping::Address, carrier: T.nilable(String), name: String, phone: T.nilable(String), tracking_number: T.nilable(String)).void
}
def initialize(
address: nil,
carrier: nil,
name: nil,
phone: nil,
tracking_number: nil
); end
end
class TransferData < Stripe::RequestParams
# The amount that will be transferred automatically when a charge succeeds.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# If specified, successful charges will be attributed to the destination
# account for tax reporting, and the funds from charges will be transferred
# to the destination account. The ID of the resulting transfer will be
# returned on the successful charge's `transfer` field.
sig { returns(String) }
attr_accessor :destination
sig { params(amount: T.nilable(Integer), destination: String).void }
def initialize(amount: nil, destination: nil); end
end
# The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. The amount of the application fee collected will be capped at the total amount captured. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
sig { returns(T.nilable(Integer)) }
attr_accessor :application_fee_amount
# Controls when the funds will be captured from the customer's account.
sig { returns(T.nilable(String)) }
attr_accessor :capture_method
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The Stripe account ID for which these funds are intended. For details,
# see the PaymentIntents [use case for connected
# accounts](/docs/payments/connected-accounts).
sig { returns(T.nilable(String)) }
attr_accessor :on_behalf_of
# Email address that the receipt for the resulting payment will be sent to. If `receipt_email` is specified for a payment in live mode, a receipt will be sent regardless of your [email settings](https://dashboard.stripe.com/account/emails).
sig { returns(T.nilable(String)) }
attr_accessor :receipt_email
# Indicates that you intend to [make future payments](https://stripe.com/docs/payments/payment-intents#future-usage) with the payment
# method collected by this Checkout Session.
#
# When setting this to `on_session`, Checkout will show a notice to the
# customer that their payment details will be saved.
#
# When setting this to `off_session`, Checkout will show a notice to the
# customer that their payment details will be saved and used for future
# payments.
#
# If a Customer has been provided or Checkout creates a new Customer,
# Checkout will attach the payment method to the Customer.
#
# If Checkout does not create a Customer, the payment method is not attached
# to a Customer. To reuse the payment method, you can retrieve it from the
# Checkout Session's PaymentIntent.
#
# When processing card payments, Checkout also uses `setup_future_usage`
# to dynamically optimize your payment flow and comply with regional
# legislation and network rules, such as SCA.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
# Shipping information for this payment.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentIntentData::Shipping))
}
attr_accessor :shipping
# Text that appears on the customer's statement as the statement descriptor for a non-card charge. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
#
# Setting this value for a card charge returns an error. For card charges, set the [statement_descriptor_suffix](https://docs.stripe.com/get-started/account/statement-descriptors#dynamic) instead.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
# Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor_suffix
# The parameters used to automatically create a Transfer when the payment succeeds.
# For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentIntentData::TransferData))
}
attr_accessor :transfer_data
# A string that identifies the resulting payment as part of a group. See the PaymentIntents [use case for connected accounts](https://stripe.com/docs/connect/separate-charges-and-transfers) for details.
sig { returns(T.nilable(String)) }
attr_accessor :transfer_group
sig {
params(application_fee_amount: T.nilable(Integer), capture_method: T.nilable(String), description: T.nilable(String), metadata: T.nilable(T::Hash[String, String]), on_behalf_of: T.nilable(String), receipt_email: T.nilable(String), setup_future_usage: T.nilable(String), shipping: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentIntentData::Shipping), statement_descriptor: T.nilable(String), statement_descriptor_suffix: T.nilable(String), transfer_data: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentIntentData::TransferData), transfer_group: T.nilable(String)).void
}
def initialize(
application_fee_amount: nil,
capture_method: nil,
description: nil,
metadata: nil,
on_behalf_of: nil,
receipt_email: nil,
setup_future_usage: nil,
shipping: nil,
statement_descriptor: nil,
statement_descriptor_suffix: nil,
transfer_data: nil,
transfer_group: nil
); end
end
class PaymentMethodData < Stripe::RequestParams
# Allow redisplay will be set on the payment method on confirmation and indicates whether this payment method can be shown again to the customer in a checkout flow. Only set this field if you wish to override the allow_redisplay value determined by Checkout.
sig { returns(T.nilable(String)) }
attr_accessor :allow_redisplay
sig { params(allow_redisplay: T.nilable(String)).void }
def initialize(allow_redisplay: nil); end
end
class PaymentMethodOptions < Stripe::RequestParams
class AcssDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# A URL for custom mandate text to render during confirmation step.
# The URL will be rendered with additional GET parameters `payment_intent` and `payment_intent_client_secret` when confirming a Payment Intent,
# or `setup_intent` and `setup_intent_client_secret` when confirming a Setup Intent.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :custom_mandate_url
# List of Stripe products where this mandate can be selected automatically. Only usable in `setup` mode.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :default_for
# Description of the mandate interval. Only required if 'payment_schedule' parameter is 'interval' or 'combined'.
sig { returns(T.nilable(String)) }
attr_accessor :interval_description
# Payment schedule for the mandate.
sig { returns(T.nilable(String)) }
attr_accessor :payment_schedule
# Transaction type of the mandate.
sig { returns(T.nilable(String)) }
attr_accessor :transaction_type
sig {
params(custom_mandate_url: T.nilable(T.nilable(String)), default_for: T.nilable(T::Array[String]), interval_description: T.nilable(String), payment_schedule: T.nilable(String), transaction_type: T.nilable(String)).void
}
def initialize(
custom_mandate_url: nil,
default_for: nil,
interval_description: nil,
payment_schedule: nil,
transaction_type: nil
); end
end
# 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). This is only accepted for Checkout Sessions in `setup` mode.
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::AcssDebit::MandateOptions))
}
attr_accessor :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
# Verification method for the intent
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(currency: T.nilable(String), mandate_options: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::AcssDebit::MandateOptions), setup_future_usage: T.nilable(String), target_date: T.nilable(String), verification_method: T.nilable(String)).void
}
def initialize(
currency: nil,
mandate_options: nil,
setup_future_usage: nil,
target_date: nil,
verification_method: nil
); end
end
class Affirm < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class AfterpayClearpay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Alipay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class AmazonPay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class AuBecsDebit < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
sig {
params(setup_future_usage: T.nilable(String), target_date: T.nilable(String)).void
}
def initialize(setup_future_usage: nil, target_date: nil); end
end
class BacsDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'DDIC' or 'STRIPE'.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :reference_prefix
sig { params(reference_prefix: T.nilable(T.nilable(String))).void }
def initialize(reference_prefix: nil); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::BacsDebit::MandateOptions))
}
attr_accessor :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
sig {
params(mandate_options: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::BacsDebit::MandateOptions), setup_future_usage: T.nilable(String), target_date: T.nilable(String)).void
}
def initialize(mandate_options: nil, setup_future_usage: nil, target_date: nil); end
end
class Bancontact < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Boleto < Stripe::RequestParams
# The number of calendar days before a Boleto voucher expires. For example, if you create a Boleto voucher on Monday and you set expires_after_days to 2, the Boleto invoice will expire on Wednesday at 23:59 America/Sao_Paulo time.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_after_days
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(expires_after_days: T.nilable(Integer), setup_future_usage: T.nilable(String)).void
}
def initialize(expires_after_days: nil, setup_future_usage: nil); end
end
class Card < Stripe::RequestParams
class Installments < Stripe::RequestParams
# Setting to true enables installments for this Checkout Session.
# Setting to false will prevent any installment plan from applying to a payment.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :enabled
sig { params(enabled: T.nilable(T::Boolean)).void }
def initialize(enabled: nil); end
end
class Restrictions < Stripe::RequestParams
# Specify the card brands to block in the Checkout Session. If a customer enters or selects a card belonging to a blocked brand, they can't complete the Session.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :brands_blocked
sig { params(brands_blocked: T.nilable(T::Array[String])).void }
def initialize(brands_blocked: nil); end
end
# Installment options for card payments
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Card::Installments))
}
attr_accessor :installments
# Request ability to [capture beyond the standard authorization validity window](/payments/extended-authorization) for this CheckoutSession.
sig { returns(T.nilable(String)) }
attr_accessor :request_decremental_authorization
# Request ability to [capture beyond the standard authorization validity window](/payments/extended-authorization) for this CheckoutSession.
sig { returns(T.nilable(String)) }
attr_accessor :request_extended_authorization
# Request ability to [increment the authorization](/payments/incremental-authorization) for this CheckoutSession.
sig { returns(T.nilable(String)) }
attr_accessor :request_incremental_authorization
# Request ability to make [multiple captures](/payments/multicapture) for this CheckoutSession.
sig { returns(T.nilable(String)) }
attr_accessor :request_multicapture
# Request ability to [overcapture](/payments/overcapture) for this CheckoutSession.
sig { returns(T.nilable(String)) }
attr_accessor :request_overcapture
# We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. If not provided, this value defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
sig { returns(T.nilable(String)) }
attr_accessor :request_three_d_secure
# Restrictions to apply to the card payment method. For example, you can block specific card brands.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Card::Restrictions))
}
attr_accessor :restrictions
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
# Provides information about a card payment that customers see on their statements. Concatenated with the Kana prefix (shortened Kana descriptor) or Kana statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 22 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 22 characters.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor_suffix_kana
# Provides information about a card payment that customers see on their statements. Concatenated with the Kanji prefix (shortened Kanji descriptor) or Kanji statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 17 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 17 characters.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor_suffix_kanji
sig {
params(installments: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Card::Installments), request_decremental_authorization: T.nilable(String), request_extended_authorization: T.nilable(String), request_incremental_authorization: T.nilable(String), request_multicapture: T.nilable(String), request_overcapture: T.nilable(String), request_three_d_secure: T.nilable(String), restrictions: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Card::Restrictions), setup_future_usage: T.nilable(String), statement_descriptor_suffix_kana: T.nilable(String), statement_descriptor_suffix_kanji: T.nilable(String)).void
}
def initialize(
installments: nil,
request_decremental_authorization: nil,
request_extended_authorization: nil,
request_incremental_authorization: nil,
request_multicapture: nil,
request_overcapture: nil,
request_three_d_secure: nil,
restrictions: nil,
setup_future_usage: nil,
statement_descriptor_suffix_kana: nil,
statement_descriptor_suffix_kanji: nil
); end
end
class Cashapp < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class CustomerBalance < Stripe::RequestParams
class BankTransfer < Stripe::RequestParams
class EuBankTransfer < Stripe::RequestParams
# The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
sig { returns(String) }
attr_accessor :country
sig { params(country: String).void }
def initialize(country: nil); end
end
# Configuration for eu_bank_transfer funding type.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::CustomerBalance::BankTransfer::EuBankTransfer))
}
attr_accessor :eu_bank_transfer
# List of address types that should be returned in the financial_addresses response. If not specified, all valid types will be returned.
#
# Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :requested_address_types
# The list of bank transfer types that this PaymentIntent is allowed to use for funding.
sig { returns(String) }
attr_accessor :type
sig {
params(eu_bank_transfer: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::CustomerBalance::BankTransfer::EuBankTransfer), requested_address_types: T.nilable(T::Array[String]), type: String).void
}
def initialize(eu_bank_transfer: nil, requested_address_types: nil, type: nil); end
end
# Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::CustomerBalance::BankTransfer))
}
attr_accessor :bank_transfer
# The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
sig { returns(T.nilable(String)) }
attr_accessor :funding_type
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(bank_transfer: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::CustomerBalance::BankTransfer), funding_type: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(bank_transfer: nil, funding_type: nil, setup_future_usage: nil); end
end
class Eps < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Fpx < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Giropay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Grabpay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Ideal < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class KakaoPay < Stripe::RequestParams
# Controls when the funds will be captured from the customer's account.
sig { returns(T.nilable(String)) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class Klarna < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Konbini < Stripe::RequestParams
# The number of calendar days (between 1 and 60) after which Konbini payment instructions will expire. For example, if a PaymentIntent is confirmed with Konbini and `expires_after_days` set to 2 on Monday JST, the instructions will expire on Wednesday 23:59:59 JST. Defaults to 3 days.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_after_days
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(expires_after_days: T.nilable(Integer), setup_future_usage: T.nilable(String)).void
}
def initialize(expires_after_days: nil, setup_future_usage: nil); end
end
class KrCard < Stripe::RequestParams
# Controls when the funds will be captured from the customer's account.
sig { returns(T.nilable(String)) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class Link < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Mobilepay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Multibanco < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class NaverPay < Stripe::RequestParams
# Controls when the funds will be captured from the customer's account.
sig { returns(T.nilable(String)) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class Oxxo < Stripe::RequestParams
# The number of calendar days before an OXXO voucher expires. For example, if you create an OXXO voucher on Monday and you set expires_after_days to 2, the OXXO invoice will expire on Wednesday at 23:59 America/Mexico_City time.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_after_days
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(expires_after_days: T.nilable(Integer), setup_future_usage: T.nilable(String)).void
}
def initialize(expires_after_days: nil, setup_future_usage: nil); end
end
class P24 < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
# Confirm that the payer has accepted the P24 terms and conditions.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :tos_shown_and_accepted
sig {
params(setup_future_usage: T.nilable(String), tos_shown_and_accepted: T.nilable(T::Boolean)).void
}
def initialize(setup_future_usage: nil, tos_shown_and_accepted: nil); end
end
class PayByBank < Stripe::RequestParams; end
class Payco < Stripe::RequestParams
# Controls when the funds will be captured from the customer's account.
sig { returns(T.nilable(String)) }
attr_accessor :capture_method
sig { params(capture_method: T.nilable(String)).void }
def initialize(capture_method: nil); end
end
class Paynow < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Paypal < Stripe::RequestParams
# Controls when the funds will be captured from the customer's account.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# [Preferred locale](https://stripe.com/docs/payments/paypal/supported-locales) of the PayPal checkout page that the customer is redirected to.
sig { returns(T.nilable(String)) }
attr_accessor :preferred_locale
# A reference of the PayPal transaction visible to customer which is mapped to PayPal's invoice ID. This must be a globally unique ID if you have configured in your PayPal settings to block multiple payments per invoice ID.
sig { returns(T.nilable(String)) }
attr_accessor :reference
# A reference of the PayPal transaction visible to customer which is mapped to PayPal's invoice ID. This must be a globally unique ID if you have configured in your PayPal settings to block multiple payments per invoice ID.
sig { returns(T.nilable(String)) }
attr_accessor :reference_id
# The risk correlation ID for an on-session payment using a saved PayPal payment method.
sig { returns(T.nilable(String)) }
attr_accessor :risk_correlation_id
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# The Stripe connected account IDs of the sellers on the platform for this transaction (optional). Only allowed when [separate charges and transfers](https://stripe.com/docs/connect/separate-charges-and-transfers) are used.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :subsellers
sig {
params(capture_method: T.nilable(T.nilable(String)), preferred_locale: T.nilable(String), reference: T.nilable(String), reference_id: T.nilable(String), risk_correlation_id: T.nilable(String), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), subsellers: T.nilable(T::Array[String])).void
}
def initialize(
capture_method: nil,
preferred_locale: nil,
reference: nil,
reference_id: nil,
risk_correlation_id: nil,
setup_future_usage: nil,
subsellers: nil
); end
end
class Payto < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Amount that will be collected. It is required when `amount_type` is `fixed`.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# The type of amount that will be collected. The amount charged must be exact or up to the value of `amount` param for `fixed` or `maximum` type respectively.
sig { returns(T.nilable(String)) }
attr_accessor :amount_type
# Date, in YYYY-MM-DD format, after which payments will not be collected. Defaults to no end date.
sig { returns(T.nilable(String)) }
attr_accessor :end_date
# The periodicity at which payments will be collected.
sig { returns(T.nilable(String)) }
attr_accessor :payment_schedule
# The number of payments that will be made during a payment period. Defaults to 1 except for when `payment_schedule` is `adhoc`. In that case, it defaults to no limit.
sig { returns(T.nilable(Integer)) }
attr_accessor :payments_per_period
# The purpose for which payments are made. Defaults to retail.
sig { returns(T.nilable(String)) }
attr_accessor :purpose
# Date, in YYYY-MM-DD format, from which payments will be collected. Defaults to confirmation time.
sig { returns(T.nilable(String)) }
attr_accessor :start_date
sig {
params(amount: T.nilable(Integer), amount_type: T.nilable(String), end_date: T.nilable(String), payment_schedule: T.nilable(String), payments_per_period: T.nilable(Integer), purpose: T.nilable(String), start_date: T.nilable(String)).void
}
def initialize(
amount: nil,
amount_type: nil,
end_date: nil,
payment_schedule: nil,
payments_per_period: nil,
purpose: nil,
start_date: nil
); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Payto::MandateOptions))
}
attr_accessor :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(mandate_options: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Payto::MandateOptions), setup_future_usage: T.nilable(String)).void
}
def initialize(mandate_options: nil, setup_future_usage: nil); end
end
class Pix < Stripe::RequestParams
# The number of seconds (between 10 and 1209600) after which Pix payment will expire. Defaults to 86400 seconds.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_after_seconds
sig { params(expires_after_seconds: T.nilable(Integer)).void }
def initialize(expires_after_seconds: nil); end
end
class RevolutPay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class SamsungPay < Stripe::RequestParams
# Controls when the funds will be captured from the customer's account.
sig { returns(T.nilable(String)) }
attr_accessor :capture_method
sig { params(capture_method: T.nilable(String)).void }
def initialize(capture_method: nil); end
end
class SepaDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'STRIPE'.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :reference_prefix
sig { params(reference_prefix: T.nilable(T.nilable(String))).void }
def initialize(reference_prefix: nil); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::SepaDebit::MandateOptions))
}
attr_accessor :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
sig {
params(mandate_options: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::SepaDebit::MandateOptions), setup_future_usage: T.nilable(String), target_date: T.nilable(String)).void
}
def initialize(mandate_options: nil, setup_future_usage: nil, target_date: nil); end
end
class Sofort < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Swish < Stripe::RequestParams
# The order reference that will be displayed to customers in the Swish application. Defaults to the `id` of the Payment Intent.
sig { returns(T.nilable(String)) }
attr_accessor :reference
sig { params(reference: T.nilable(String)).void }
def initialize(reference: nil); end
end
class UsBankAccount < Stripe::RequestParams
class FinancialConnections < Stripe::RequestParams
# The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :permissions
# List of data features that you would like to retrieve upon account creation.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :prefetch
sig {
params(permissions: T.nilable(T::Array[String]), prefetch: T.nilable(T::Array[String])).void
}
def initialize(permissions: nil, prefetch: nil); end
end
# Additional fields for Financial Connections Session creation
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections))
}
attr_accessor :financial_connections
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
# Verification method for the intent
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(financial_connections: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections), setup_future_usage: T.nilable(String), target_date: T.nilable(String), verification_method: T.nilable(String)).void
}
def initialize(
financial_connections: nil,
setup_future_usage: nil,
target_date: nil,
verification_method: nil
); end
end
class WechatPay < Stripe::RequestParams
# The app ID registered with WeChat Pay. Only required when client is ios or android.
sig { returns(T.nilable(String)) }
attr_accessor :app_id
# The client type that the end customer will pay from
sig { returns(String) }
attr_accessor :client
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(app_id: T.nilable(String), client: String, setup_future_usage: T.nilable(String)).void
}
def initialize(app_id: nil, client: nil, setup_future_usage: nil); end
end
# contains details about the ACSS Debit payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::AcssDebit))
}
attr_accessor :acss_debit
# contains details about the Affirm payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Affirm))
}
attr_accessor :affirm
# contains details about the Afterpay Clearpay payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::AfterpayClearpay))
}
attr_accessor :afterpay_clearpay
# contains details about the Alipay payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Alipay))
}
attr_accessor :alipay
# contains details about the AmazonPay payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::AmazonPay))
}
attr_accessor :amazon_pay
# contains details about the AU Becs Debit payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::AuBecsDebit))
}
attr_accessor :au_becs_debit
# contains details about the Bacs Debit payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::BacsDebit))
}
attr_accessor :bacs_debit
# contains details about the Bancontact payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Bancontact))
}
attr_accessor :bancontact
# contains details about the Boleto payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Boleto))
}
attr_accessor :boleto
# contains details about the Card payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Card))
}
attr_accessor :card
# contains details about the Cashapp Pay payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Cashapp))
}
attr_accessor :cashapp
# contains details about the Customer Balance payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::CustomerBalance))
}
attr_accessor :customer_balance
# contains details about the EPS payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Eps))
}
attr_accessor :eps
# contains details about the FPX payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Fpx))
}
attr_accessor :fpx
# contains details about the Giropay payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Giropay))
}
attr_accessor :giropay
# contains details about the Grabpay payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Grabpay))
}
attr_accessor :grabpay
# contains details about the Ideal payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Ideal))
}
attr_accessor :ideal
# contains details about the Kakao Pay payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::KakaoPay))
}
attr_accessor :kakao_pay
# contains details about the Klarna payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Klarna))
}
attr_accessor :klarna
# contains details about the Konbini payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Konbini))
}
attr_accessor :konbini
# contains details about the Korean card payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::KrCard))
}
attr_accessor :kr_card
# contains details about the Link payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Link))
}
attr_accessor :link
# contains details about the Mobilepay payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Mobilepay))
}
attr_accessor :mobilepay
# contains details about the Multibanco payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Multibanco))
}
attr_accessor :multibanco
# contains details about the Naver Pay payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::NaverPay))
}
attr_accessor :naver_pay
# contains details about the OXXO payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Oxxo))
}
attr_accessor :oxxo
# contains details about the P24 payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::P24))
}
attr_accessor :p24
# contains details about the Pay By Bank payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::PayByBank))
}
attr_accessor :pay_by_bank
# contains details about the PAYCO payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Payco))
}
attr_accessor :payco
# contains details about the PayNow payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Paynow))
}
attr_accessor :paynow
# contains details about the PayPal payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Paypal))
}
attr_accessor :paypal
# contains details about the PayTo payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Payto))
}
attr_accessor :payto
# contains details about the Pix payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Pix))
}
attr_accessor :pix
# contains details about the RevolutPay payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::RevolutPay))
}
attr_accessor :revolut_pay
# contains details about the Samsung Pay payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::SamsungPay))
}
attr_accessor :samsung_pay
# contains details about the Sepa Debit payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::SepaDebit))
}
attr_accessor :sepa_debit
# contains details about the Sofort payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Sofort))
}
attr_accessor :sofort
# contains details about the Swish payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Swish))
}
attr_accessor :swish
# contains details about the Us Bank Account payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::UsBankAccount))
}
attr_accessor :us_bank_account
# contains details about the WeChat Pay payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::WechatPay))
}
attr_accessor :wechat_pay
sig {
params(acss_debit: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::AcssDebit), affirm: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Affirm), afterpay_clearpay: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::AfterpayClearpay), alipay: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Alipay), amazon_pay: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::AmazonPay), au_becs_debit: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::AuBecsDebit), bacs_debit: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::BacsDebit), bancontact: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Bancontact), boleto: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Boleto), card: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Card), cashapp: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Cashapp), customer_balance: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::CustomerBalance), eps: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Eps), fpx: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Fpx), giropay: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Giropay), grabpay: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Grabpay), ideal: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Ideal), kakao_pay: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::KakaoPay), klarna: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Klarna), konbini: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Konbini), kr_card: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::KrCard), link: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Link), mobilepay: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Mobilepay), multibanco: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Multibanco), naver_pay: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::NaverPay), oxxo: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Oxxo), p24: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::P24), pay_by_bank: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::PayByBank), payco: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Payco), paynow: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Paynow), paypal: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Paypal), payto: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Payto), pix: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Pix), revolut_pay: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::RevolutPay), samsung_pay: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::SamsungPay), sepa_debit: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::SepaDebit), sofort: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Sofort), swish: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::Swish), us_bank_account: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::UsBankAccount), wechat_pay: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions::WechatPay)).void
}
def initialize(
acss_debit: nil,
affirm: nil,
afterpay_clearpay: nil,
alipay: nil,
amazon_pay: nil,
au_becs_debit: nil,
bacs_debit: nil,
bancontact: nil,
boleto: nil,
card: nil,
cashapp: nil,
customer_balance: nil,
eps: nil,
fpx: nil,
giropay: nil,
grabpay: nil,
ideal: nil,
kakao_pay: nil,
klarna: nil,
konbini: nil,
kr_card: nil,
link: nil,
mobilepay: nil,
multibanco: nil,
naver_pay: nil,
oxxo: nil,
p24: nil,
pay_by_bank: nil,
payco: nil,
paynow: nil,
paypal: nil,
payto: nil,
pix: nil,
revolut_pay: nil,
samsung_pay: nil,
sepa_debit: nil,
sofort: nil,
swish: nil,
us_bank_account: nil,
wechat_pay: nil
); end
end
class Permissions < Stripe::RequestParams
class Update < Stripe::RequestParams
# Determines which entity is allowed to update the line items.
#
# Default is `client_only`. Stripe Checkout client will automatically update the line items. If set to `server_only`, only your server is allowed to update the line items.
#
# When set to `server_only`, you must add the onLineItemsChange event handler when initializing the Stripe Checkout client and manually update the line items from your server using the Stripe API.
sig { returns(T.nilable(String)) }
attr_accessor :line_items
# Determines which entity is allowed to update the shipping details.
#
# Default is `client_only`. Stripe Checkout client will automatically update the shipping details. If set to `server_only`, only your server is allowed to update the shipping details.
#
# When set to `server_only`, you must add the onShippingDetailsChange event handler when initializing the Stripe Checkout client and manually update the shipping details from your server using the Stripe API.
sig { returns(T.nilable(String)) }
attr_accessor :shipping_details
sig { params(line_items: T.nilable(String), shipping_details: T.nilable(String)).void }
def initialize(line_items: nil, shipping_details: nil); end
end
# Permissions for updating the Checkout Session.
sig { returns(T.nilable(::Stripe::Checkout::Session::CreateParams::Permissions::Update)) }
attr_accessor :update
# Determines which entity is allowed to update the line items.
#
# Default is `client_only`. Stripe Checkout client will automatically update the line items. If set to `server_only`, only your server is allowed to update the line items.
#
# When set to `server_only`, you must add the onLineItemsChange event handler when initializing the Stripe Checkout client and manually update the line items from your server using the Stripe API.
sig { returns(T.nilable(String)) }
attr_accessor :update_line_items
# Determines which entity is allowed to update the shipping details.
#
# Default is `client_only`. Stripe Checkout client will automatically update the shipping details. If set to `server_only`, only your server is allowed to update the shipping details.
#
# When set to `server_only`, you must add the onShippingDetailsChange event handler when initializing the Stripe Checkout client and manually update the shipping details from your server using the Stripe API.
sig { returns(T.nilable(String)) }
attr_accessor :update_shipping_details
sig {
params(update: T.nilable(::Stripe::Checkout::Session::CreateParams::Permissions::Update), update_line_items: T.nilable(String), update_shipping_details: T.nilable(String)).void
}
def initialize(update: nil, update_line_items: nil, update_shipping_details: nil); end
end
class PhoneNumberCollection < Stripe::RequestParams
# Set to `true` to enable phone number collection.
#
# Can only be set in `payment` and `subscription` mode.
sig { returns(T::Boolean) }
attr_accessor :enabled
sig { params(enabled: T::Boolean).void }
def initialize(enabled: nil); end
end
class SavedPaymentMethodOptions < Stripe::RequestParams
# Uses the `allow_redisplay` value of each saved payment method to filter the set presented to a returning customer. By default, only saved payment methods with ’allow_redisplay: ‘always’ are shown in Checkout.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :allow_redisplay_filters
# Enable customers to choose if they wish to remove their saved payment methods. Disabled by default.
sig { returns(T.nilable(String)) }
attr_accessor :payment_method_remove
# Enable customers to choose if they wish to save their payment method for future use. Disabled by default.
sig { returns(T.nilable(String)) }
attr_accessor :payment_method_save
sig {
params(allow_redisplay_filters: T.nilable(T::Array[String]), payment_method_remove: T.nilable(String), payment_method_save: T.nilable(String)).void
}
def initialize(
allow_redisplay_filters: nil,
payment_method_remove: nil,
payment_method_save: nil
); end
end
class SetupIntentData < Stripe::RequestParams
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The Stripe account for which the setup is intended.
sig { returns(T.nilable(String)) }
attr_accessor :on_behalf_of
sig {
params(description: T.nilable(String), metadata: T.nilable(T::Hash[String, String]), on_behalf_of: T.nilable(String)).void
}
def initialize(description: nil, metadata: nil, on_behalf_of: nil); end
end
class ShippingAddressCollection < Stripe::RequestParams
# An array of two-letter ISO country codes representing which countries Checkout should provide as options for
# shipping locations.
sig { returns(T::Array[String]) }
attr_accessor :allowed_countries
sig { params(allowed_countries: T::Array[String]).void }
def initialize(allowed_countries: nil); end
end
class ShippingOption < Stripe::RequestParams
class ShippingRateData < Stripe::RequestParams
class DeliveryEstimate < Stripe::RequestParams
class Maximum < Stripe::RequestParams
# A unit of time.
sig { returns(String) }
attr_accessor :unit
# Must be greater than 0.
sig { returns(Integer) }
attr_accessor :value
sig { params(unit: String, value: Integer).void }
def initialize(unit: nil, value: nil); end
end
class Minimum < Stripe::RequestParams
# A unit of time.
sig { returns(String) }
attr_accessor :unit
# Must be greater than 0.
sig { returns(Integer) }
attr_accessor :value
sig { params(unit: String, value: Integer).void }
def initialize(unit: nil, value: nil); end
end
# The upper bound of the estimated range. If empty, represents no upper bound i.e., infinite.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::ShippingOption::ShippingRateData::DeliveryEstimate::Maximum))
}
attr_accessor :maximum
# The lower bound of the estimated range. If empty, represents no lower bound.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::ShippingOption::ShippingRateData::DeliveryEstimate::Minimum))
}
attr_accessor :minimum
sig {
params(maximum: T.nilable(::Stripe::Checkout::Session::CreateParams::ShippingOption::ShippingRateData::DeliveryEstimate::Maximum), minimum: T.nilable(::Stripe::Checkout::Session::CreateParams::ShippingOption::ShippingRateData::DeliveryEstimate::Minimum)).void
}
def initialize(maximum: nil, minimum: nil); end
end
class FixedAmount < Stripe::RequestParams
class CurrencyOptions < Stripe::RequestParams
# A non-negative integer in cents representing how much to charge.
sig { returns(Integer) }
attr_accessor :amount
# Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
sig { params(amount: Integer, tax_behavior: T.nilable(String)).void }
def initialize(amount: nil, tax_behavior: nil); end
end
# A non-negative integer in cents representing how much to charge.
sig { returns(Integer) }
attr_accessor :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).
sig { returns(String) }
attr_accessor :currency
# Shipping rates defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
sig {
returns(T.nilable(T::Hash[String, ::Stripe::Checkout::Session::CreateParams::ShippingOption::ShippingRateData::FixedAmount::CurrencyOptions]))
}
attr_accessor :currency_options
sig {
params(amount: Integer, currency: String, currency_options: T.nilable(T::Hash[String, ::Stripe::Checkout::Session::CreateParams::ShippingOption::ShippingRateData::FixedAmount::CurrencyOptions])).void
}
def initialize(amount: nil, currency: nil, currency_options: nil); end
end
# The estimated range for how long shipping will take, meant to be displayable to the customer. This will appear on CheckoutSessions.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::ShippingOption::ShippingRateData::DeliveryEstimate))
}
attr_accessor :delivery_estimate
# The name of the shipping rate, meant to be displayable to the customer. This will appear on CheckoutSessions.
sig { returns(String) }
attr_accessor :display_name
# Describes a fixed amount to charge for shipping. Must be present if type is `fixed_amount`.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::ShippingOption::ShippingRateData::FixedAmount))
}
attr_accessor :fixed_amount
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID. The Shipping tax code is `txcd_92010001`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_code
# The type of calculation to use on the shipping rate.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(delivery_estimate: T.nilable(::Stripe::Checkout::Session::CreateParams::ShippingOption::ShippingRateData::DeliveryEstimate), display_name: String, fixed_amount: T.nilable(::Stripe::Checkout::Session::CreateParams::ShippingOption::ShippingRateData::FixedAmount), metadata: T.nilable(T::Hash[String, String]), tax_behavior: T.nilable(String), tax_code: T.nilable(String), type: T.nilable(String)).void
}
def initialize(
delivery_estimate: nil,
display_name: nil,
fixed_amount: nil,
metadata: nil,
tax_behavior: nil,
tax_code: nil,
type: nil
); end
end
# The ID of the Shipping Rate to use for this shipping option.
sig { returns(T.nilable(String)) }
attr_accessor :shipping_rate
# Parameters to be passed to Shipping Rate creation for this shipping option.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::ShippingOption::ShippingRateData))
}
attr_accessor :shipping_rate_data
sig {
params(shipping_rate: T.nilable(String), shipping_rate_data: T.nilable(::Stripe::Checkout::Session::CreateParams::ShippingOption::ShippingRateData)).void
}
def initialize(shipping_rate: nil, shipping_rate_data: nil); end
end
class SubscriptionData < Stripe::RequestParams
class InvoiceSettings < Stripe::RequestParams
class Issuer < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::SubscriptionData::InvoiceSettings::Issuer))
}
attr_accessor :issuer
sig {
params(issuer: T.nilable(::Stripe::Checkout::Session::CreateParams::SubscriptionData::InvoiceSettings::Issuer)).void
}
def initialize(issuer: nil); end
end
class TransferData < Stripe::RequestParams
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
sig { returns(T.nilable(Float)) }
attr_accessor :amount_percent
# ID of an existing, connected Stripe account.
sig { returns(String) }
attr_accessor :destination
sig { params(amount_percent: T.nilable(Float), destination: String).void }
def initialize(amount_percent: nil, destination: nil); end
end
class TrialSettings < Stripe::RequestParams
class EndBehavior < Stripe::RequestParams
# Indicates how the subscription should change when the trial ends if the user did not provide a payment method.
sig { returns(String) }
attr_accessor :missing_payment_method
sig { params(missing_payment_method: String).void }
def initialize(missing_payment_method: nil); end
end
# Defines how the subscription should behave when the user's free trial ends.
sig {
returns(::Stripe::Checkout::Session::CreateParams::SubscriptionData::TrialSettings::EndBehavior)
}
attr_accessor :end_behavior
sig {
params(end_behavior: ::Stripe::Checkout::Session::CreateParams::SubscriptionData::TrialSettings::EndBehavior).void
}
def initialize(end_behavior: nil); end
end
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. To use an application fee percent, the request must be made on behalf of another account, using the `Stripe-Account` header or an OAuth key. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).
sig { returns(T.nilable(Float)) }
attr_accessor :application_fee_percent
# A future timestamp to anchor the subscription's billing cycle for new subscriptions.
sig { returns(T.nilable(Integer)) }
attr_accessor :billing_cycle_anchor
# Controls how prorations and invoices for subscriptions are calculated and orchestrated.
sig { returns(T.nilable(String)) }
attr_accessor :billing_mode
# The tax rates that will apply to any subscription item that does not have
# `tax_rates` set. Invoices created will have their `default_tax_rates` populated
# from the subscription.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :default_tax_rates
# The subscription's description, meant to be displayable to the customer.
# Use this field to optionally store an explanation of the subscription
# for rendering in the [customer portal](https://stripe.com/docs/customer-management).
sig { returns(T.nilable(String)) }
attr_accessor :description
# All invoices will be billed using the specified settings.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::SubscriptionData::InvoiceSettings))
}
attr_accessor :invoice_settings
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The account on behalf of which to charge, for each of the subscription's invoices.
sig { returns(T.nilable(String)) }
attr_accessor :on_behalf_of
# Determines how to handle prorations resulting from the `billing_cycle_anchor`. If no value is passed, the default is `create_prorations`.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
# If specified, the funds from the subscription's invoices will be transferred to the destination and the ID of the resulting transfers will be found on the resulting charges.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::SubscriptionData::TransferData))
}
attr_accessor :transfer_data
# Unix timestamp representing the end of the trial period the customer
# will get before being charged for the first time. Has to be at least
# 48 hours in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :trial_end
# Integer representing the number of trial period days before the
# customer is charged for the first time. Has to be at least 1.
sig { returns(T.nilable(Integer)) }
attr_accessor :trial_period_days
# Settings related to subscription trials.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::SubscriptionData::TrialSettings))
}
attr_accessor :trial_settings
sig {
params(application_fee_percent: T.nilable(Float), billing_cycle_anchor: T.nilable(Integer), billing_mode: T.nilable(String), default_tax_rates: T.nilable(T::Array[String]), description: T.nilable(String), invoice_settings: T.nilable(::Stripe::Checkout::Session::CreateParams::SubscriptionData::InvoiceSettings), metadata: T.nilable(T::Hash[String, String]), on_behalf_of: T.nilable(String), proration_behavior: T.nilable(String), transfer_data: T.nilable(::Stripe::Checkout::Session::CreateParams::SubscriptionData::TransferData), trial_end: T.nilable(Integer), trial_period_days: T.nilable(Integer), trial_settings: T.nilable(::Stripe::Checkout::Session::CreateParams::SubscriptionData::TrialSettings)).void
}
def initialize(
application_fee_percent: nil,
billing_cycle_anchor: nil,
billing_mode: nil,
default_tax_rates: nil,
description: nil,
invoice_settings: nil,
metadata: nil,
on_behalf_of: nil,
proration_behavior: nil,
transfer_data: nil,
trial_end: nil,
trial_period_days: nil,
trial_settings: nil
); end
end
class TaxIdCollection < Stripe::RequestParams
# Enable tax ID collection during checkout. Defaults to `false`.
sig { returns(T::Boolean) }
attr_accessor :enabled
# Describes whether a tax ID is required during checkout. Defaults to `never`.
sig { returns(T.nilable(String)) }
attr_accessor :required
sig { params(enabled: T::Boolean, required: T.nilable(String)).void }
def initialize(enabled: nil, required: nil); end
end
class WalletOptions < Stripe::RequestParams
class Link < Stripe::RequestParams
# Specifies whether Checkout should display Link as a payment option. By default, Checkout will display all the supported wallets that the Checkout Session was created with. This is the `auto` behavior, and it is the default choice.
sig { returns(T.nilable(String)) }
attr_accessor :display
sig { params(display: T.nilable(String)).void }
def initialize(display: nil); end
end
# contains details about the Link wallet options.
sig { returns(T.nilable(::Stripe::Checkout::Session::CreateParams::WalletOptions::Link)) }
attr_accessor :link
sig {
params(link: T.nilable(::Stripe::Checkout::Session::CreateParams::WalletOptions::Link)).void
}
def initialize(link: nil); end
end
# Settings for price localization with [Adaptive Pricing](https://docs.stripe.com/payments/checkout/adaptive-pricing).
sig { returns(T.nilable(::Stripe::Checkout::Session::CreateParams::AdaptivePricing)) }
attr_accessor :adaptive_pricing
# Configure actions after a Checkout Session has expired.
sig { returns(T.nilable(::Stripe::Checkout::Session::CreateParams::AfterExpiration)) }
attr_accessor :after_expiration
# Enables user redeemable promotion codes.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :allow_promotion_codes
# Settings for automatic tax lookup for this session and resulting payments, invoices, and subscriptions.
sig { returns(T.nilable(::Stripe::Checkout::Session::CreateParams::AutomaticTax)) }
attr_accessor :automatic_tax
# Specify whether Checkout should collect the customer's billing address. Defaults to `auto`.
sig { returns(T.nilable(String)) }
attr_accessor :billing_address_collection
# If set, Checkout displays a back button and customers will be directed to this URL if they decide to cancel payment and return to your website. This parameter is not allowed if ui_mode is `embedded` or `custom`.
sig { returns(T.nilable(String)) }
attr_accessor :cancel_url
# A unique string to reference the Checkout Session. This can be a
# customer ID, a cart ID, or similar, and can be used to reconcile the
# session with your internal systems.
sig { returns(T.nilable(String)) }
attr_accessor :client_reference_id
# Configure fields for the Checkout Session to gather active consent from customers.
sig { returns(T.nilable(::Stripe::Checkout::Session::CreateParams::ConsentCollection)) }
attr_accessor :consent_collection
# 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). Required in `setup` mode when `payment_method_types` is not set.
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Collect additional information from your customer using custom fields. Up to 3 fields are supported.
sig { returns(T.nilable(T::Array[::Stripe::Checkout::Session::CreateParams::CustomField])) }
attr_accessor :custom_fields
# Display additional text for your customers using custom text.
sig { returns(T.nilable(::Stripe::Checkout::Session::CreateParams::CustomText)) }
attr_accessor :custom_text
# ID of an existing Customer, if one exists. In `payment` mode, the customer’s most recently saved card
# payment method will be used to prefill the email, name, card details, and billing address
# on the Checkout page. In `subscription` mode, the customer’s [default payment method](https://stripe.com/docs/api/customers/update#update_customer-invoice_settings-default_payment_method)
# will be used if it’s a card, otherwise the most recently saved card will be used. A valid billing address, billing name and billing email are required on the payment method for Checkout to prefill the customer's card details.
#
# If the Customer already has a valid [email](https://stripe.com/docs/api/customers/object#customer_object-email) set, the email will be prefilled and not editable in Checkout.
# If the Customer does not have a valid `email`, Checkout will set the email entered during the session on the Customer.
#
# If blank for Checkout Sessions in `subscription` mode or with `customer_creation` set as `always` in `payment` mode, Checkout will create a new Customer object based on information provided during the payment flow.
#
# You can set [`payment_intent_data.setup_future_usage`](https://stripe.com/docs/api/checkout/sessions/create#create_checkout_session-payment_intent_data-setup_future_usage) to have Checkout automatically attach the payment method to the Customer you pass in for future reuse.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# ID of an existing Account, if one exists. Has the same behavior as `customer`.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# Configure whether a Checkout Session creates a [Customer](https://stripe.com/docs/api/customers) during Session confirmation.
#
# When a Customer is not created, you can still retrieve email, address, and other customer data entered in Checkout
# with [customer_details](https://stripe.com/docs/api/checkout/sessions/object#checkout_session_object-customer_details).
#
# Sessions that don't create Customers instead are grouped by [guest customers](https://stripe.com/docs/payments/checkout/guest-customers)
# in the Dashboard. Promotion codes limited to first time customers will return invalid for these Sessions.
#
# Can only be set in `payment` and `setup` mode.
sig { returns(T.nilable(String)) }
attr_accessor :customer_creation
# If provided, this value will be used when the Customer object is created.
# If not provided, customers will be asked to enter their email address.
# Use this parameter to prefill customer data if you already have an email
# on file. To access information about the customer once a session is
# complete, use the `customer` field.
sig { returns(T.nilable(String)) }
attr_accessor :customer_email
# Controls what fields on Customer can be updated by the Checkout Session. Can only be provided when `customer` is provided.
sig { returns(T.nilable(::Stripe::Checkout::Session::CreateParams::CustomerUpdate)) }
attr_accessor :customer_update
# The coupon or promotion code to apply to this Session. Currently, only up to one may be specified.
sig { returns(T.nilable(T::Array[::Stripe::Checkout::Session::CreateParams::Discount])) }
attr_accessor :discounts
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The Epoch time in seconds at which the Checkout Session will expire. It can be anywhere from 30 minutes to 24 hours after Checkout Session creation. By default, this value is 24 hours from creation.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_at
# Generate a post-purchase Invoice for one-time payments.
sig { returns(T.nilable(::Stripe::Checkout::Session::CreateParams::InvoiceCreation)) }
attr_accessor :invoice_creation
# A list of items the customer is purchasing. Use this parameter to pass one-time or recurring [Prices](https://stripe.com/docs/api/prices).
#
# For `payment` mode, there is a maximum of 100 line items, however it is recommended to consolidate line items if there are more than a few dozen.
#
# For `subscription` mode, there is a maximum of 20 line items with recurring Prices and 20 line items with one-time Prices. Line items with one-time Prices will be on the initial invoice only.
sig { returns(T.nilable(T::Array[::Stripe::Checkout::Session::CreateParams::LineItem])) }
attr_accessor :line_items
# The IETF language tag of the locale Checkout is displayed in. If blank or `auto`, the browser's locale is used.
sig { returns(T.nilable(String)) }
attr_accessor :locale
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The mode of the Checkout Session. Pass `subscription` if the Checkout Session includes at least one recurring item.
sig { returns(T.nilable(String)) }
attr_accessor :mode
# A list of optional items the customer can add to their order at checkout. Use this parameter to pass one-time or recurring [Prices](https://stripe.com/docs/api/prices).
#
# There is a maximum of 10 optional items allowed on a Checkout Session, and the existing limits on the number of line items allowed on a Checkout Session apply to the combined number of line items and optional items.
#
# For `payment` mode, there is a maximum of 100 combined line items and optional items, however it is recommended to consolidate items if there are more than a few dozen.
#
# For `subscription` mode, there is a maximum of 20 line items and optional items with recurring Prices and 20 line items and optional items with one-time Prices.
sig {
returns(T.nilable(T::Array[::Stripe::Checkout::Session::CreateParams::OptionalItem]))
}
attr_accessor :optional_items
# A subset of parameters to be passed to PaymentIntent creation for Checkout Sessions in `payment` mode.
sig { returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentIntentData)) }
attr_accessor :payment_intent_data
# Specify whether Checkout should collect a payment method. When set to `if_required`, Checkout will not collect a payment method when the total due for the session is 0.
# This may occur if the Checkout Session includes a free trial or a discount.
#
# Can only be set in `subscription` mode. Defaults to `always`.
#
# If you'd like information on how to collect a payment method outside of Checkout, read the guide on configuring [subscriptions with a free trial](https://stripe.com/docs/payments/checkout/free-trials).
sig { returns(T.nilable(String)) }
attr_accessor :payment_method_collection
# The ID of the payment method configuration to use with this Checkout session.
sig { returns(T.nilable(String)) }
attr_accessor :payment_method_configuration
# This parameter allows you to set some attributes on the payment method created during a Checkout session.
sig { returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodData)) }
attr_accessor :payment_method_data
# Payment-method-specific configuration.
sig { returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions)) }
attr_accessor :payment_method_options
# A list of the types of payment methods (e.g., `card`) this Checkout Session can accept.
#
# You can omit this attribute to manage your payment methods from the [Stripe Dashboard](https://dashboard.stripe.com/settings/payment_methods).
# See [Dynamic Payment Methods](https://stripe.com/docs/payments/payment-methods/integration-options#using-dynamic-payment-methods) for more details.
#
# Read more about the supported payment methods and their requirements in our [payment
# method details guide](/docs/payments/checkout/payment-methods).
#
# If multiple payment methods are passed, Checkout will dynamically reorder them to
# prioritize the most relevant payment methods based on the customer's location and
# other characteristics.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :payment_method_types
# This property is used to set up permissions for various actions (e.g., update) on the CheckoutSession object. Can only be set when creating `embedded` or `custom` sessions.
#
# For specific permissions, please refer to their dedicated subsections, such as `permissions.update_shipping_details`.
sig { returns(T.nilable(::Stripe::Checkout::Session::CreateParams::Permissions)) }
attr_accessor :permissions
# Controls phone number collection settings for the session.
#
# We recommend that you review your privacy policy and check with your legal contacts
# before using this feature. Learn more about [collecting phone numbers with Checkout](https://stripe.com/docs/payments/checkout/phone-numbers).
sig { returns(T.nilable(::Stripe::Checkout::Session::CreateParams::PhoneNumberCollection)) }
attr_accessor :phone_number_collection
# This parameter applies to `ui_mode: embedded`. Learn more about the [redirect behavior](https://stripe.com/docs/payments/checkout/custom-success-page?payment-ui=embedded-form) of embedded sessions. Defaults to `always`.
sig { returns(T.nilable(String)) }
attr_accessor :redirect_on_completion
# The URL to redirect your customer back to after they authenticate or cancel their payment on the
# payment method's app or site. This parameter is required if `ui_mode` is `embedded` or `custom`
# and redirect-based payment methods are enabled on the session.
sig { returns(T.nilable(String)) }
attr_accessor :return_url
# Controls saved payment method settings for the session. Only available in `payment` and `subscription` mode.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::SavedPaymentMethodOptions))
}
attr_accessor :saved_payment_method_options
# A subset of parameters to be passed to SetupIntent creation for Checkout Sessions in `setup` mode.
sig { returns(T.nilable(::Stripe::Checkout::Session::CreateParams::SetupIntentData)) }
attr_accessor :setup_intent_data
# When set, provides configuration for Checkout to collect a shipping address from a customer.
sig {
returns(T.nilable(::Stripe::Checkout::Session::CreateParams::ShippingAddressCollection))
}
attr_accessor :shipping_address_collection
# The shipping rate options to apply to this Session. Up to a maximum of 5.
sig {
returns(T.nilable(T::Array[::Stripe::Checkout::Session::CreateParams::ShippingOption]))
}
attr_accessor :shipping_options
# Describes the type of transaction being performed by Checkout in order
# to customize relevant text on the page, such as the submit button.
# `submit_type` can only be specified on Checkout Sessions in
# `payment` or `subscription` mode. If blank or `auto`, `pay` is used.
sig { returns(T.nilable(String)) }
attr_accessor :submit_type
# A subset of parameters to be passed to subscription creation for Checkout Sessions in `subscription` mode.
sig { returns(T.nilable(::Stripe::Checkout::Session::CreateParams::SubscriptionData)) }
attr_accessor :subscription_data
# The URL to which Stripe should send customers when payment or setup
# is complete.
# This parameter is not allowed if ui_mode is `embedded` or `custom`. If you'd like to use
# information from the successful Checkout Session on your page, read the
# guide on [customizing your success page](https://stripe.com/docs/payments/checkout/custom-success-page).
sig { returns(T.nilable(String)) }
attr_accessor :success_url
# Controls tax ID collection during checkout.
sig { returns(T.nilable(::Stripe::Checkout::Session::CreateParams::TaxIdCollection)) }
attr_accessor :tax_id_collection
# The UI mode of the Session. Defaults to `hosted`.
sig { returns(T.nilable(String)) }
attr_accessor :ui_mode
# Wallet-specific configuration.
sig { returns(T.nilable(::Stripe::Checkout::Session::CreateParams::WalletOptions)) }
attr_accessor :wallet_options
sig {
params(adaptive_pricing: T.nilable(::Stripe::Checkout::Session::CreateParams::AdaptivePricing), after_expiration: T.nilable(::Stripe::Checkout::Session::CreateParams::AfterExpiration), allow_promotion_codes: T.nilable(T::Boolean), automatic_tax: T.nilable(::Stripe::Checkout::Session::CreateParams::AutomaticTax), billing_address_collection: T.nilable(String), cancel_url: T.nilable(String), client_reference_id: T.nilable(String), consent_collection: T.nilable(::Stripe::Checkout::Session::CreateParams::ConsentCollection), currency: T.nilable(String), custom_fields: T.nilable(T::Array[::Stripe::Checkout::Session::CreateParams::CustomField]), custom_text: T.nilable(::Stripe::Checkout::Session::CreateParams::CustomText), customer: T.nilable(String), customer_account: T.nilable(String), customer_creation: T.nilable(String), customer_email: T.nilable(String), customer_update: T.nilable(::Stripe::Checkout::Session::CreateParams::CustomerUpdate), discounts: T.nilable(T::Array[::Stripe::Checkout::Session::CreateParams::Discount]), expand: T.nilable(T::Array[String]), expires_at: T.nilable(Integer), invoice_creation: T.nilable(::Stripe::Checkout::Session::CreateParams::InvoiceCreation), line_items: T.nilable(T::Array[::Stripe::Checkout::Session::CreateParams::LineItem]), locale: T.nilable(String), metadata: T.nilable(T::Hash[String, String]), mode: T.nilable(String), optional_items: T.nilable(T::Array[::Stripe::Checkout::Session::CreateParams::OptionalItem]), payment_intent_data: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentIntentData), payment_method_collection: T.nilable(String), payment_method_configuration: T.nilable(String), payment_method_data: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodData), payment_method_options: T.nilable(::Stripe::Checkout::Session::CreateParams::PaymentMethodOptions), payment_method_types: T.nilable(T::Array[String]), permissions: T.nilable(::Stripe::Checkout::Session::CreateParams::Permissions), phone_number_collection: T.nilable(::Stripe::Checkout::Session::CreateParams::PhoneNumberCollection), redirect_on_completion: T.nilable(String), return_url: T.nilable(String), saved_payment_method_options: T.nilable(::Stripe::Checkout::Session::CreateParams::SavedPaymentMethodOptions), setup_intent_data: T.nilable(::Stripe::Checkout::Session::CreateParams::SetupIntentData), shipping_address_collection: T.nilable(::Stripe::Checkout::Session::CreateParams::ShippingAddressCollection), shipping_options: T.nilable(T::Array[::Stripe::Checkout::Session::CreateParams::ShippingOption]), submit_type: T.nilable(String), subscription_data: T.nilable(::Stripe::Checkout::Session::CreateParams::SubscriptionData), success_url: T.nilable(String), tax_id_collection: T.nilable(::Stripe::Checkout::Session::CreateParams::TaxIdCollection), ui_mode: T.nilable(String), wallet_options: T.nilable(::Stripe::Checkout::Session::CreateParams::WalletOptions)).void
}
def initialize(
adaptive_pricing: nil,
after_expiration: nil,
allow_promotion_codes: nil,
automatic_tax: nil,
billing_address_collection: nil,
cancel_url: nil,
client_reference_id: nil,
consent_collection: nil,
currency: nil,
custom_fields: nil,
custom_text: nil,
customer: nil,
customer_account: nil,
customer_creation: nil,
customer_email: nil,
customer_update: nil,
discounts: nil,
expand: nil,
expires_at: nil,
invoice_creation: nil,
line_items: nil,
locale: nil,
metadata: nil,
mode: nil,
optional_items: nil,
payment_intent_data: nil,
payment_method_collection: nil,
payment_method_configuration: nil,
payment_method_data: nil,
payment_method_options: nil,
payment_method_types: nil,
permissions: nil,
phone_number_collection: nil,
redirect_on_completion: nil,
return_url: nil,
saved_payment_method_options: nil,
setup_intent_data: nil,
shipping_address_collection: nil,
shipping_options: nil,
submit_type: nil,
subscription_data: nil,
success_url: nil,
tax_id_collection: nil,
ui_mode: nil,
wallet_options: nil
); end
end
class UpdateParams < Stripe::RequestParams
class CollectedInformation < Stripe::RequestParams
class ShippingDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(String) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(String) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: String, line1: String, line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# The address of the customer
sig {
returns(::Stripe::Checkout::Session::UpdateParams::CollectedInformation::ShippingDetails::Address)
}
attr_accessor :address
# The name of customer
sig { returns(String) }
attr_accessor :name
sig {
params(address: ::Stripe::Checkout::Session::UpdateParams::CollectedInformation::ShippingDetails::Address, name: String).void
}
def initialize(address: nil, name: nil); end
end
# The shipping details to apply to this Session.
sig {
returns(T.nilable(::Stripe::Checkout::Session::UpdateParams::CollectedInformation::ShippingDetails))
}
attr_accessor :shipping_details
sig {
params(shipping_details: T.nilable(::Stripe::Checkout::Session::UpdateParams::CollectedInformation::ShippingDetails)).void
}
def initialize(shipping_details: nil); end
end
class LineItem < Stripe::RequestParams
class AdjustableQuantity < Stripe::RequestParams
# Set to true if the quantity can be adjusted to any positive integer. Setting to false will remove any previously specified constraints on quantity.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The maximum quantity the customer can purchase for the Checkout Session. By default this value is 99. You can specify a value up to 999999.
sig { returns(T.nilable(Integer)) }
attr_accessor :maximum
# The minimum quantity the customer must purchase for the Checkout Session. By default this value is 0.
sig { returns(T.nilable(Integer)) }
attr_accessor :minimum
sig {
params(enabled: T::Boolean, maximum: T.nilable(Integer), minimum: T.nilable(Integer)).void
}
def initialize(enabled: nil, maximum: nil, minimum: nil); end
end
class PriceData < Stripe::RequestParams
class ProductData < Stripe::RequestParams
# The product's description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes.
sig { returns(T.nilable(String)) }
attr_accessor :description
# A list of up to 8 URLs of images for this product, meant to be displayable to the customer.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :images
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The product's name, meant to be displayable to the customer.
sig { returns(String) }
attr_accessor :name
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
sig { returns(T.nilable(String)) }
attr_accessor :tax_code
sig {
params(description: T.nilable(String), images: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), name: String, tax_code: T.nilable(String)).void
}
def initialize(
description: nil,
images: nil,
metadata: nil,
name: nil,
tax_code: nil
); end
end
class Recurring < Stripe::RequestParams
# Specifies billing frequency. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: T.nilable(Integer)).void }
def initialize(interval: nil, interval_count: nil); end
end
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to. One of `product` or `product_data` is required.
sig { returns(T.nilable(String)) }
attr_accessor :product
# Data used to generate a new [Product](https://docs.stripe.com/api/products) object inline. One of `product` or `product_data` is required.
sig {
returns(T.nilable(::Stripe::Checkout::Session::UpdateParams::LineItem::PriceData::ProductData))
}
attr_accessor :product_data
# The recurring components of a price such as `interval` and `interval_count`.
sig {
returns(T.nilable(::Stripe::Checkout::Session::UpdateParams::LineItem::PriceData::Recurring))
}
attr_accessor :recurring
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A non-negative integer in cents (or local equivalent) representing how much to charge. One of `unit_amount` or `unit_amount_decimal` is required.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, product: T.nilable(String), product_data: T.nilable(::Stripe::Checkout::Session::UpdateParams::LineItem::PriceData::ProductData), recurring: T.nilable(::Stripe::Checkout::Session::UpdateParams::LineItem::PriceData::Recurring), tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
product_data: nil,
recurring: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
# When set, provides configuration for this item’s quantity to be adjusted by the customer during Checkout.
sig {
returns(T.nilable(::Stripe::Checkout::Session::UpdateParams::LineItem::AdjustableQuantity))
}
attr_accessor :adjustable_quantity
# ID of an existing line item.
sig { returns(T.nilable(String)) }
attr_accessor :id
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# The ID of the [Price](https://stripe.com/docs/api/prices). One of `price` or `price_data` is required when creating a new line item.
sig { returns(T.nilable(String)) }
attr_accessor :price
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required when creating a new line item.
sig { returns(T.nilable(::Stripe::Checkout::Session::UpdateParams::LineItem::PriceData)) }
attr_accessor :price_data
# The quantity of the line item being purchased. Quantity should not be defined when `recurring.usage_type=metered`.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# The [tax rates](https://stripe.com/docs/api/tax_rates) which apply to this line item.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
sig {
params(adjustable_quantity: T.nilable(::Stripe::Checkout::Session::UpdateParams::LineItem::AdjustableQuantity), id: T.nilable(String), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), price: T.nilable(String), price_data: T.nilable(::Stripe::Checkout::Session::UpdateParams::LineItem::PriceData), quantity: T.nilable(Integer), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String])))).void
}
def initialize(
adjustable_quantity: nil,
id: nil,
metadata: nil,
price: nil,
price_data: nil,
quantity: nil,
tax_rates: nil
); end
end
class ShippingOption < Stripe::RequestParams
class ShippingRateData < Stripe::RequestParams
class DeliveryEstimate < Stripe::RequestParams
class Maximum < Stripe::RequestParams
# A unit of time.
sig { returns(String) }
attr_accessor :unit
# Must be greater than 0.
sig { returns(Integer) }
attr_accessor :value
sig { params(unit: String, value: Integer).void }
def initialize(unit: nil, value: nil); end
end
class Minimum < Stripe::RequestParams
# A unit of time.
sig { returns(String) }
attr_accessor :unit
# Must be greater than 0.
sig { returns(Integer) }
attr_accessor :value
sig { params(unit: String, value: Integer).void }
def initialize(unit: nil, value: nil); end
end
# The upper bound of the estimated range. If empty, represents no upper bound i.e., infinite.
sig {
returns(T.nilable(::Stripe::Checkout::Session::UpdateParams::ShippingOption::ShippingRateData::DeliveryEstimate::Maximum))
}
attr_accessor :maximum
# The lower bound of the estimated range. If empty, represents no lower bound.
sig {
returns(T.nilable(::Stripe::Checkout::Session::UpdateParams::ShippingOption::ShippingRateData::DeliveryEstimate::Minimum))
}
attr_accessor :minimum
sig {
params(maximum: T.nilable(::Stripe::Checkout::Session::UpdateParams::ShippingOption::ShippingRateData::DeliveryEstimate::Maximum), minimum: T.nilable(::Stripe::Checkout::Session::UpdateParams::ShippingOption::ShippingRateData::DeliveryEstimate::Minimum)).void
}
def initialize(maximum: nil, minimum: nil); end
end
class FixedAmount < Stripe::RequestParams
class CurrencyOptions < Stripe::RequestParams
# A non-negative integer in cents representing how much to charge.
sig { returns(Integer) }
attr_accessor :amount
# Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
sig { params(amount: Integer, tax_behavior: T.nilable(String)).void }
def initialize(amount: nil, tax_behavior: nil); end
end
# A non-negative integer in cents representing how much to charge.
sig { returns(Integer) }
attr_accessor :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).
sig { returns(String) }
attr_accessor :currency
# Shipping rates defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
sig {
returns(T.nilable(T::Hash[String, ::Stripe::Checkout::Session::UpdateParams::ShippingOption::ShippingRateData::FixedAmount::CurrencyOptions]))
}
attr_accessor :currency_options
sig {
params(amount: Integer, currency: String, currency_options: T.nilable(T::Hash[String, ::Stripe::Checkout::Session::UpdateParams::ShippingOption::ShippingRateData::FixedAmount::CurrencyOptions])).void
}
def initialize(amount: nil, currency: nil, currency_options: nil); end
end
# The estimated range for how long shipping will take, meant to be displayable to the customer. This will appear on CheckoutSessions.
sig {
returns(T.nilable(::Stripe::Checkout::Session::UpdateParams::ShippingOption::ShippingRateData::DeliveryEstimate))
}
attr_accessor :delivery_estimate
# The name of the shipping rate, meant to be displayable to the customer. This will appear on CheckoutSessions.
sig { returns(String) }
attr_accessor :display_name
# Describes a fixed amount to charge for shipping. Must be present if type is `fixed_amount`.
sig {
returns(T.nilable(::Stripe::Checkout::Session::UpdateParams::ShippingOption::ShippingRateData::FixedAmount))
}
attr_accessor :fixed_amount
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID. The Shipping tax code is `txcd_92010001`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_code
# The type of calculation to use on the shipping rate.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(delivery_estimate: T.nilable(::Stripe::Checkout::Session::UpdateParams::ShippingOption::ShippingRateData::DeliveryEstimate), display_name: String, fixed_amount: T.nilable(::Stripe::Checkout::Session::UpdateParams::ShippingOption::ShippingRateData::FixedAmount), metadata: T.nilable(T::Hash[String, String]), tax_behavior: T.nilable(String), tax_code: T.nilable(String), type: T.nilable(String)).void
}
def initialize(
delivery_estimate: nil,
display_name: nil,
fixed_amount: nil,
metadata: nil,
tax_behavior: nil,
tax_code: nil,
type: nil
); end
end
# The ID of the Shipping Rate to use for this shipping option.
sig { returns(T.nilable(String)) }
attr_accessor :shipping_rate
# Parameters to be passed to Shipping Rate creation for this shipping option.
sig {
returns(T.nilable(::Stripe::Checkout::Session::UpdateParams::ShippingOption::ShippingRateData))
}
attr_accessor :shipping_rate_data
sig {
params(shipping_rate: T.nilable(String), shipping_rate_data: T.nilable(::Stripe::Checkout::Session::UpdateParams::ShippingOption::ShippingRateData)).void
}
def initialize(shipping_rate: nil, shipping_rate_data: nil); end
end
# Information about the customer collected within the Checkout Session. Can only be set when updating `embedded` or `custom` sessions.
sig { returns(T.nilable(::Stripe::Checkout::Session::UpdateParams::CollectedInformation)) }
attr_accessor :collected_information
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A list of items the customer is purchasing.
#
# When updating line items, you must retransmit the entire array of line items.
#
# To retain an existing line item, specify its `id`.
#
# To update an existing line item, specify its `id` along with the new values of the fields to update.
#
# To add a new line item, specify one of `price` or `price_data` and `quantity`.
#
# To remove an existing line item, omit the line item's ID from the retransmitted array.
#
# To reorder a line item, specify it at the desired position in the retransmitted array.
sig { returns(T.nilable(T::Array[::Stripe::Checkout::Session::UpdateParams::LineItem])) }
attr_accessor :line_items
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# The shipping rate options to apply to this Session. Up to a maximum of 5.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Checkout::Session::UpdateParams::ShippingOption]))))
}
attr_accessor :shipping_options
sig {
params(collected_information: T.nilable(::Stripe::Checkout::Session::UpdateParams::CollectedInformation), expand: T.nilable(T::Array[String]), line_items: T.nilable(T::Array[::Stripe::Checkout::Session::UpdateParams::LineItem]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), shipping_options: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Checkout::Session::UpdateParams::ShippingOption])))).void
}
def initialize(
collected_information: nil,
expand: nil,
line_items: nil,
metadata: nil,
shipping_options: nil
); end
end
class ListLineItemsParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
class ExpireParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Creates a Checkout Session object.
sig {
params(params: T.any(::Stripe::Checkout::Session::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Checkout::Session)
}
def self.create(params = {}, opts = {}); end
# A Checkout Session can be expired when it is in one of these statuses: open
#
# After it expires, a customer can't complete a Checkout Session and customers loading the Checkout Session see a message saying the Checkout Session is expired.
sig {
params(params: T.any(::Stripe::Checkout::Session::ExpireParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Checkout::Session)
}
def expire(params = {}, opts = {}); end
# A Checkout Session can be expired when it is in one of these statuses: open
#
# After it expires, a customer can't complete a Checkout Session and customers loading the Checkout Session see a message saying the Checkout Session is expired.
sig {
params(session: String, params: T.any(::Stripe::Checkout::Session::ExpireParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Checkout::Session)
}
def self.expire(session, params = {}, opts = {}); end
# Returns a list of Checkout Sessions.
sig {
params(params: T.any(::Stripe::Checkout::Session::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# When retrieving a Checkout Session, there is an includable line_items property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items.
sig {
params(params: T.any(::Stripe::Checkout::Session::ListLineItemsParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list_line_items(params = {}, opts = {}); end
# When retrieving a Checkout Session, there is an includable line_items property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items.
sig {
params(session: String, params: T.any(::Stripe::Checkout::Session::ListLineItemsParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list_line_items(session, params = {}, opts = {}); end
# Updates a Checkout Session object.
#
# Related guide: [Dynamically update Checkout](https://docs.stripe.com/payments/checkout/dynamic-updates)
sig {
params(session: String, params: T.any(::Stripe::Checkout::Session::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Checkout::Session)
}
def self.update(session, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Climate
# Orders represent your intent to purchase a particular Climate product. When you create an order, the
# payment is deducted from your merchant balance.
class Order < APIResource
class Beneficiary < Stripe::StripeObject
# Publicly displayable name for the end beneficiary of carbon removal.
sig { returns(String) }
attr_reader :public_name
end
class DeliveryDetail < Stripe::StripeObject
class Location < Stripe::StripeObject
# The city where the supplier is located.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter ISO code representing the country where the supplier is located.
sig { returns(String) }
attr_reader :country
# The geographic latitude where the supplier is located.
sig { returns(T.nilable(Float)) }
attr_reader :latitude
# The geographic longitude where the supplier is located.
sig { returns(T.nilable(Float)) }
attr_reader :longitude
# The state/county/province/region where the supplier is located.
sig { returns(T.nilable(String)) }
attr_reader :region
end
# Time at which the delivery occurred. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :delivered_at
# Specific location of this delivery.
sig { returns(T.nilable(Location)) }
attr_reader :location
# Quantity of carbon removal supplied by this delivery.
sig { returns(String) }
attr_reader :metric_tons
# Once retired, a URL to the registry entry for the tons from this delivery.
sig { returns(T.nilable(String)) }
attr_reader :registry_url
# A supplier of carbon removal.
sig { returns(Stripe::Climate::Supplier) }
attr_reader :supplier
end
# Total amount of [Frontier](https://frontierclimate.com/)'s service fees in the currency's smallest unit.
sig { returns(Integer) }
attr_reader :amount_fees
# Total amount of the carbon removal in the currency's smallest unit.
sig { returns(Integer) }
attr_reader :amount_subtotal
# Total amount of the order including fees in the currency's smallest unit.
sig { returns(Integer) }
attr_reader :amount_total
# Attribute for field beneficiary
sig { returns(Beneficiary) }
attr_reader :beneficiary
# Time at which the order was canceled. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_reader :canceled_at
# Reason for the cancellation of this order.
sig { returns(T.nilable(String)) }
attr_reader :cancellation_reason
# For delivered orders, a URL to a delivery certificate for the order.
sig { returns(T.nilable(String)) }
attr_reader :certificate
# Time at which the order was confirmed. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_reader :confirmed_at
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase, representing the currency for this order.
sig { returns(String) }
attr_reader :currency
# Time at which the order's expected_delivery_year was delayed. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_reader :delayed_at
# Time at which the order was delivered. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_reader :delivered_at
# Details about the delivery of carbon removal for this order.
sig { returns(T::Array[DeliveryDetail]) }
attr_reader :delivery_details
# The year this order is expected to be delivered.
sig { returns(Integer) }
attr_reader :expected_delivery_year
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# 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.
sig { returns(T::Hash[String, String]) }
attr_reader :metadata
# Quantity of carbon removal that is included in this order.
sig { returns(String) }
attr_reader :metric_tons
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Unique ID for the Climate `Product` this order is purchasing.
sig { returns(T.any(String, Stripe::Climate::Product)) }
attr_reader :product
# Time at which the order's product was substituted for a different product. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_reader :product_substituted_at
# The current status of this order.
sig { returns(String) }
attr_reader :status
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
class CreateParams < Stripe::RequestParams
class Beneficiary < Stripe::RequestParams
# Publicly displayable name for the end beneficiary of carbon removal.
sig { returns(String) }
attr_accessor :public_name
sig { params(public_name: String).void }
def initialize(public_name: nil); end
end
# Requested amount of carbon removal units. Either this or `metric_tons` must be specified.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# Publicly sharable reference for the end beneficiary of carbon removal. Assumed to be the Stripe account if not set.
sig { returns(T.nilable(::Stripe::Climate::Order::CreateParams::Beneficiary)) }
attr_accessor :beneficiary
# Request currency for the order as a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a supported [settlement currency for your account](https://stripe.com/docs/currencies). If omitted, the account's default currency will be used.
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Requested number of tons for the order. Either this or `amount` must be specified.
sig { returns(T.nilable(String)) }
attr_accessor :metric_tons
# Unique identifier of the Climate product.
sig { returns(String) }
attr_accessor :product
sig {
params(amount: T.nilable(Integer), beneficiary: T.nilable(::Stripe::Climate::Order::CreateParams::Beneficiary), currency: T.nilable(String), expand: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), metric_tons: T.nilable(String), product: String).void
}
def initialize(
amount: nil,
beneficiary: nil,
currency: nil,
expand: nil,
metadata: nil,
metric_tons: nil,
product: nil
); end
end
class UpdateParams < Stripe::RequestParams
class Beneficiary < Stripe::RequestParams
# Publicly displayable name for the end beneficiary of carbon removal.
sig { returns(T.nilable(String)) }
attr_accessor :public_name
sig { params(public_name: T.nilable(String)).void }
def initialize(public_name: nil); end
end
# Publicly sharable reference for the end beneficiary of carbon removal. Assumed to be the Stripe account if not set.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Climate::Order::UpdateParams::Beneficiary))))
}
attr_accessor :beneficiary
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
sig {
params(beneficiary: T.nilable(T.nilable(T.any(String, ::Stripe::Climate::Order::UpdateParams::Beneficiary))), expand: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String])).void
}
def initialize(beneficiary: nil, expand: nil, metadata: nil); end
end
class CancelParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Cancels a Climate order. You can cancel an order within 24 hours of creation. Stripe refunds the
# reservation amount_subtotal, but not the amount_fees for user-triggered cancellations. Frontier
# might cancel reservations if suppliers fail to deliver. If Frontier cancels the reservation, Stripe
# provides 90 days advance notice and refunds the amount_total.
sig {
params(params: T.any(::Stripe::Climate::Order::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Climate::Order)
}
def cancel(params = {}, opts = {}); end
# Cancels a Climate order. You can cancel an order within 24 hours of creation. Stripe refunds the
# reservation amount_subtotal, but not the amount_fees for user-triggered cancellations. Frontier
# might cancel reservations if suppliers fail to deliver. If Frontier cancels the reservation, Stripe
# provides 90 days advance notice and refunds the amount_total.
sig {
params(order: String, params: T.any(::Stripe::Climate::Order::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Climate::Order)
}
def self.cancel(order, params = {}, opts = {}); end
# Creates a Climate order object for a given Climate product. The order will be processed immediately
# after creation and payment will be deducted your Stripe balance.
sig {
params(params: T.any(::Stripe::Climate::Order::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Climate::Order)
}
def self.create(params = {}, opts = {}); end
# Lists all Climate order objects. The orders are returned sorted by creation date, with the
# most recently created orders appearing first.
sig {
params(params: T.any(::Stripe::Climate::Order::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Updates the specified order by setting the values of the parameters passed.
sig {
params(order: String, params: T.any(::Stripe::Climate::Order::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Climate::Order)
}
def self.update(order, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Climate
# A Climate product represents a type of carbon removal unit available for reservation.
# You can retrieve it to see the current price and availability.
class Product < APIResource
class CurrentPricesPerMetricTon < Stripe::StripeObject
# Fees for one metric ton of carbon removal in the currency's smallest unit.
sig { returns(Integer) }
attr_reader :amount_fees
# Subtotal for one metric ton of carbon removal (excluding fees) in the currency's smallest unit.
sig { returns(Integer) }
attr_reader :amount_subtotal
# Total for one metric ton of carbon removal (including fees) in the currency's smallest unit.
sig { returns(Integer) }
attr_reader :amount_total
end
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# Current prices for a metric ton of carbon removal in a currency's smallest unit.
sig { returns(T::Hash[String, CurrentPricesPerMetricTon]) }
attr_reader :current_prices_per_metric_ton
# The year in which the carbon removal is expected to be delivered.
sig { returns(T.nilable(Integer)) }
attr_reader :delivery_year
# Unique identifier for the object. For convenience, Climate product IDs are human-readable strings
# that start with `climsku_`. See [carbon removal inventory](https://stripe.com/docs/climate/orders/carbon-removal-inventory)
# for a list of available carbon removal products.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# The quantity of metric tons available for reservation.
sig { returns(String) }
attr_reader :metric_tons_available
# The Climate product's name.
sig { returns(String) }
attr_reader :name
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The carbon removal suppliers that fulfill orders for this Climate product.
sig { returns(T::Array[Stripe::Climate::Supplier]) }
attr_reader :suppliers
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
# Lists all available Climate product objects.
sig {
params(params: T.any(::Stripe::Climate::Product::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Climate
# A supplier of carbon removal.
class Supplier < APIResource
class Location < Stripe::StripeObject
# The city where the supplier is located.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter ISO code representing the country where the supplier is located.
sig { returns(String) }
attr_reader :country
# The geographic latitude where the supplier is located.
sig { returns(T.nilable(Float)) }
attr_reader :latitude
# The geographic longitude where the supplier is located.
sig { returns(T.nilable(Float)) }
attr_reader :longitude
# The state/county/province/region where the supplier is located.
sig { returns(T.nilable(String)) }
attr_reader :region
end
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Link to a webpage to learn more about the supplier.
sig { returns(String) }
attr_reader :info_url
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# The locations in which this supplier operates.
sig { returns(T::Array[Location]) }
attr_reader :locations
# Name of this carbon removal supplier.
sig { returns(String) }
attr_reader :name
# String representing the object’s type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The scientific pathway used for carbon removal.
sig { returns(String) }
attr_reader :removal_pathway
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
# Lists all available Climate supplier objects.
sig {
params(params: T.any(::Stripe::Climate::Supplier::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
# ConfirmationTokens help transport client side data collected by Stripe JS over
# to your server for confirming a PaymentIntent or SetupIntent. If the confirmation
# is successful, values present on the ConfirmationToken are written onto the Intent.
#
# To learn more about how to use ConfirmationToken, visit the related guides:
# - [Finalize payments on the server](https://stripe.com/docs/payments/finalize-payments-on-the-server)
# - [Build two-step confirmation](https://stripe.com/docs/payments/build-a-two-step-confirmation).
class ConfirmationToken < APIResource
class MandateData < Stripe::StripeObject
class CustomerAcceptance < Stripe::StripeObject
class Online < Stripe::StripeObject
# The IP address from which the Mandate was accepted by the customer.
sig { returns(T.nilable(String)) }
attr_reader :ip_address
# The user agent of the browser from which the Mandate was accepted by the customer.
sig { returns(T.nilable(String)) }
attr_reader :user_agent
end
# If this is a Mandate accepted online, this hash contains details about the online acceptance.
sig { returns(T.nilable(Online)) }
attr_reader :online
# The type of customer acceptance information included with the Mandate.
sig { returns(String) }
attr_reader :type
end
# This hash contains details about the customer acceptance of the Mandate.
sig { returns(CustomerAcceptance) }
attr_reader :customer_acceptance
end
class PaymentMethodOptions < Stripe::StripeObject
class Card < Stripe::StripeObject
class Installments < Stripe::StripeObject
class Plan < Stripe::StripeObject
# For `fixed_count` installment plans, this is the number of installment payments your customer will make to their credit card.
sig { returns(T.nilable(Integer)) }
attr_reader :count
# For `fixed_count` installment plans, this is the interval between installment payments your customer will make to their credit card.
# One of `month`.
sig { returns(T.nilable(String)) }
attr_reader :interval
# Type of installment plan, one of `fixed_count`.
sig { returns(String) }
attr_reader :type
end
# Attribute for field plan
sig { returns(Plan) }
attr_reader :plan
end
# The `cvc_update` Token collected from the Payment Element.
sig { returns(T.nilable(String)) }
attr_reader :cvc_token
# Installment configuration for payments.
sig { returns(Installments) }
attr_reader :installments
end
# This hash contains the card payment method options.
sig { returns(T.nilable(Card)) }
attr_reader :card
end
class PaymentMethodPreview < Stripe::StripeObject
class AcssDebit < Stripe::StripeObject
# Account number of the bank account.
sig { returns(T.nilable(String)) }
attr_reader :account_number
# Name of the bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Institution number of the bank account.
sig { returns(T.nilable(String)) }
attr_reader :institution_number
# Last four digits of the bank account number.
sig { returns(T.nilable(String)) }
attr_reader :last4
# Transit number of the bank account.
sig { returns(T.nilable(String)) }
attr_reader :transit_number
end
class Affirm < Stripe::StripeObject; end
class AfterpayClearpay < Stripe::StripeObject; end
class Alipay < Stripe::StripeObject; end
class Alma < Stripe::StripeObject; end
class AmazonPay < Stripe::StripeObject; end
class AuBecsDebit < Stripe::StripeObject
# Six-digit number identifying bank and branch associated with this bank account.
sig { returns(T.nilable(String)) }
attr_reader :bsb_number
# Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Last four digits of the bank account number.
sig { returns(T.nilable(String)) }
attr_reader :last4
end
class BacsDebit < Stripe::StripeObject
# Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Last four digits of the bank account number.
sig { returns(T.nilable(String)) }
attr_reader :last4
# Sort code of the bank account. (e.g., `10-20-30`)
sig { returns(T.nilable(String)) }
attr_reader :sort_code
end
class Bancontact < Stripe::StripeObject; end
class Billie < Stripe::StripeObject; end
class BillingDetails < Stripe::StripeObject
class Address < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Billing address.
sig { returns(T.nilable(Address)) }
attr_reader :address
# Email address.
sig { returns(T.nilable(String)) }
attr_reader :email
# Full name.
sig { returns(T.nilable(String)) }
attr_reader :name
# Billing phone number (including extension).
sig { returns(T.nilable(String)) }
attr_reader :phone
# Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
sig { returns(T.nilable(String)) }
attr_reader :tax_id
end
class Blik < Stripe::StripeObject; end
class Boleto < Stripe::StripeObject
# Uniquely identifies the customer tax id (CNPJ or CPF)
sig { returns(String) }
attr_reader :tax_id
end
class Card < Stripe::StripeObject
class Checks < Stripe::StripeObject
# If a address line1 was provided, results of the check, one of `pass`, `fail`, `unavailable`, or `unchecked`.
sig { returns(T.nilable(String)) }
attr_reader :address_line1_check
# If a address postal code was provided, results of the check, one of `pass`, `fail`, `unavailable`, or `unchecked`.
sig { returns(T.nilable(String)) }
attr_reader :address_postal_code_check
# If a CVC was provided, results of the check, one of `pass`, `fail`, `unavailable`, or `unchecked`.
sig { returns(T.nilable(String)) }
attr_reader :cvc_check
end
class GeneratedFrom < Stripe::StripeObject
class PaymentMethodDetails < Stripe::StripeObject
class CardPresent < Stripe::StripeObject
class Offline < Stripe::StripeObject
# Time at which the payment was collected while offline
sig { returns(T.nilable(Integer)) }
attr_reader :stored_at
# The method used to process this payment method offline. Only deferred is allowed.
sig { returns(T.nilable(String)) }
attr_reader :type
end
class Receipt < Stripe::StripeObject
# The type of account being debited or credited
sig { returns(String) }
attr_reader :account_type
# EMV tag 9F26, cryptogram generated by the integrated circuit chip.
sig { returns(T.nilable(String)) }
attr_reader :application_cryptogram
# Mnenomic of the Application Identifier.
sig { returns(T.nilable(String)) }
attr_reader :application_preferred_name
# Identifier for this transaction.
sig { returns(T.nilable(String)) }
attr_reader :authorization_code
# EMV tag 8A. A code returned by the card issuer.
sig { returns(T.nilable(String)) }
attr_reader :authorization_response_code
# Describes the method used by the cardholder to verify ownership of the card. One of the following: `approval`, `failure`, `none`, `offline_pin`, `offline_pin_and_signature`, `online_pin`, or `signature`.
sig { returns(T.nilable(String)) }
attr_reader :cardholder_verification_method
# EMV tag 84. Similar to the application identifier stored on the integrated circuit chip.
sig { returns(T.nilable(String)) }
attr_reader :dedicated_file_name
# The outcome of a series of EMV functions performed by the card reader.
sig { returns(T.nilable(String)) }
attr_reader :terminal_verification_results
# An indication of various EMV functions performed during the transaction.
sig { returns(T.nilable(String)) }
attr_reader :transaction_status_information
end
class Wallet < Stripe::StripeObject
# The type of mobile wallet, one of `apple_pay`, `google_pay`, `samsung_pay`, or `unknown`.
sig { returns(String) }
attr_reader :type
end
# The authorized amount
sig { returns(T.nilable(Integer)) }
attr_reader :amount_authorized
# Card brand. Can be `amex`, `diners`, `discover`, `eftpos_au`, `jcb`, `link`, `mastercard`, `unionpay`, `visa`, or `unknown`.
sig { returns(T.nilable(String)) }
attr_reader :brand
# The [product code](https://stripe.com/docs/card-product-codes) that identifies the specific program or product associated with a card.
sig { returns(T.nilable(String)) }
attr_reader :brand_product
# When using manual capture, a future timestamp after which the charge will be automatically refunded if uncaptured.
sig { returns(Integer) }
attr_reader :capture_before
# The cardholder name as read from the card, in [ISO 7813](https://en.wikipedia.org/wiki/ISO/IEC_7813) format. May include alphanumeric characters, special characters and first/last name separator (`/`). In some cases, the cardholder name may not be available depending on how the issuer has configured the card. Cardholder name is typically not available on swipe or contactless payments, such as those made with Apple Pay and Google Pay.
sig { returns(T.nilable(String)) }
attr_reader :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.
sig { returns(T.nilable(String)) }
attr_reader :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.)
sig { returns(T.nilable(String)) }
attr_reader :description
# Authorization response cryptogram.
sig { returns(T.nilable(String)) }
attr_reader :emv_auth_data
# Two-digit number representing the card's expiration month.
sig { returns(Integer) }
attr_reader :exp_month
# Four-digit number representing the card's expiration year.
sig { returns(Integer) }
attr_reader :exp_year
# Uniquely identifies this particular card number. You can use this attribute to check whether two customers who’ve signed up with you are using the same card number, for example. For payment methods that tokenize card information (Apple Pay, Google Pay), the tokenized number might be provided instead of the underlying card number.
#
# *As of May 1, 2021, card fingerprint in India for Connect changed to allow two fingerprints for the same card---one for India and one for the rest of the world.*
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Card funding type. Can be `credit`, `debit`, `prepaid`, or `unknown`.
sig { returns(T.nilable(String)) }
attr_reader :funding
# ID of a card PaymentMethod generated from the card_present PaymentMethod that may be attached to a Customer for future transactions. Only present if it was possible to generate a card PaymentMethod.
sig { returns(T.nilable(String)) }
attr_reader :generated_card
# Issuer identification number of the card. (For internal use only and not typically available in standard API requests.)
sig { returns(T.nilable(String)) }
attr_reader :iin
# Whether this [PaymentIntent](https://stripe.com/docs/api/payment_intents) is eligible for incremental authorizations. Request support using [request_incremental_authorization_support](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-payment_method_options-card_present-request_incremental_authorization_support).
sig { returns(T::Boolean) }
attr_reader :incremental_authorization_supported
# The name of the card's issuing bank. (For internal use only and not typically available in standard API requests.)
sig { returns(T.nilable(String)) }
attr_reader :issuer
# The last four digits of the card.
sig { returns(T.nilable(String)) }
attr_reader :last4
# Identifies which network this charge was processed on. Can be `amex`, `cartes_bancaires`, `diners`, `discover`, `eftpos_au`, `interac`, `jcb`, `link`, `mastercard`, `unionpay`, `visa`, or `unknown`.
sig { returns(T.nilable(String)) }
attr_reader :network
# This is used by the financial networks to identify a transaction. Visa calls this the Transaction ID, Mastercard calls this the Trace ID, and American Express calls this the Acquirer Reference Data. This value will be present if it is returned by the financial network in the authorization response, and null otherwise.
sig { returns(T.nilable(String)) }
attr_reader :network_transaction_id
# Details about payments collected offline.
sig { returns(T.nilable(Offline)) }
attr_reader :offline
# Defines whether the authorized amount can be over-captured or not
sig { returns(T::Boolean) }
attr_reader :overcapture_supported
# EMV tag 5F2D. Preferred languages specified by the integrated circuit chip.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :preferred_locales
# How card details were read in this transaction.
sig { returns(T.nilable(String)) }
attr_reader :read_method
# A collection of fields required to be displayed on receipts. Only required for EMV transactions.
sig { returns(T.nilable(Receipt)) }
attr_reader :receipt
# Attribute for field wallet
sig { returns(Wallet) }
attr_reader :wallet
end
# Attribute for field card_present
sig { returns(CardPresent) }
attr_reader :card_present
# The type of payment method transaction-specific details from the transaction that generated this `card` payment method. Always `card_present`.
sig { returns(String) }
attr_reader :type
end
# The charge that created this object.
sig { returns(T.nilable(String)) }
attr_reader :charge
# Transaction-specific details of the payment method used in the payment.
sig { returns(T.nilable(PaymentMethodDetails)) }
attr_reader :payment_method_details
# The ID of the SetupAttempt that generated this PaymentMethod, if any.
sig { returns(T.nilable(T.any(String, Stripe::SetupAttempt))) }
attr_reader :setup_attempt
end
class Networks < Stripe::StripeObject
# All networks available for selection via [payment_method_options.card.network](/api/payment_intents/confirm#confirm_payment_intent-payment_method_options-card-network).
sig { returns(T::Array[String]) }
attr_reader :available
# The preferred network for co-branded cards. Can be `cartes_bancaires`, `mastercard`, `visa` or `invalid_preference` if requested network is not valid for the card.
sig { returns(T.nilable(String)) }
attr_reader :preferred
end
class ThreeDSecureUsage < Stripe::StripeObject
# Whether 3D Secure is supported on this card.
sig { returns(T::Boolean) }
attr_reader :supported
end
class Wallet < Stripe::StripeObject
class AmexExpressCheckout < Stripe::StripeObject; end
class ApplePay < Stripe::StripeObject; end
class GooglePay < Stripe::StripeObject; end
class Link < Stripe::StripeObject; end
class Masterpass < Stripe::StripeObject
class BillingAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
class ShippingAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Owner's verified billing address. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(BillingAddress)) }
attr_reader :billing_address
# Owner's verified email. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(String)) }
attr_reader :email
# Owner's verified full name. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(String)) }
attr_reader :name
# Owner's verified shipping address. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(ShippingAddress)) }
attr_reader :shipping_address
end
class SamsungPay < Stripe::StripeObject; end
class VisaCheckout < Stripe::StripeObject
class BillingAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
class ShippingAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Owner's verified billing address. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(BillingAddress)) }
attr_reader :billing_address
# Owner's verified email. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(String)) }
attr_reader :email
# Owner's verified full name. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(String)) }
attr_reader :name
# Owner's verified shipping address. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(ShippingAddress)) }
attr_reader :shipping_address
end
# Attribute for field amex_express_checkout
sig { returns(AmexExpressCheckout) }
attr_reader :amex_express_checkout
# Attribute for field apple_pay
sig { returns(ApplePay) }
attr_reader :apple_pay
# (For tokenized numbers only.) The last four digits of the device account number.
sig { returns(T.nilable(String)) }
attr_reader :dynamic_last4
# Attribute for field google_pay
sig { returns(GooglePay) }
attr_reader :google_pay
# Attribute for field link
sig { returns(Link) }
attr_reader :link
# Attribute for field masterpass
sig { returns(Masterpass) }
attr_reader :masterpass
# Attribute for field samsung_pay
sig { returns(SamsungPay) }
attr_reader :samsung_pay
# The type of the card wallet, one of `amex_express_checkout`, `apple_pay`, `google_pay`, `masterpass`, `samsung_pay`, `visa_checkout`, or `link`. An additional hash is included on the Wallet subhash with a name matching this value. It contains additional information specific to the card wallet type.
sig { returns(String) }
attr_reader :type
# Attribute for field visa_checkout
sig { returns(VisaCheckout) }
attr_reader :visa_checkout
end
# Card brand. Can be `amex`, `diners`, `discover`, `eftpos_au`, `jcb`, `link`, `mastercard`, `unionpay`, `visa`, or `unknown`.
sig { returns(String) }
attr_reader :brand
# Checks on Card address and CVC if provided.
sig { returns(T.nilable(Checks)) }
attr_reader :checks
# 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.
sig { returns(T.nilable(String)) }
attr_reader :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.)
sig { returns(T.nilable(String)) }
attr_reader :description
# The brand to use when displaying the card, this accounts for customer's brand choice on dual-branded cards. Can be `american_express`, `cartes_bancaires`, `diners_club`, `discover`, `eftpos_australia`, `interac`, `jcb`, `mastercard`, `union_pay`, `visa`, or `other` and may contain more values in the future.
sig { returns(T.nilable(String)) }
attr_reader :display_brand
# Two-digit number representing the card's expiration month.
sig { returns(Integer) }
attr_reader :exp_month
# Four-digit number representing the card's expiration year.
sig { returns(Integer) }
attr_reader :exp_year
# Uniquely identifies this particular card number. You can use this attribute to check whether two customers who’ve signed up with you are using the same card number, for example. For payment methods that tokenize card information (Apple Pay, Google Pay), the tokenized number might be provided instead of the underlying card number.
#
# *As of May 1, 2021, card fingerprint in India for Connect changed to allow two fingerprints for the same card---one for India and one for the rest of the world.*
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Card funding type. Can be `credit`, `debit`, `prepaid`, or `unknown`.
sig { returns(String) }
attr_reader :funding
# Details of the original PaymentMethod that created this object.
sig { returns(T.nilable(GeneratedFrom)) }
attr_reader :generated_from
# Issuer identification number of the card. (For internal use only and not typically available in standard API requests.)
sig { returns(T.nilable(String)) }
attr_reader :iin
# The name of the card's issuing bank. (For internal use only and not typically available in standard API requests.)
sig { returns(T.nilable(String)) }
attr_reader :issuer
# The last four digits of the card.
sig { returns(String) }
attr_reader :last4
# Contains information about card networks that can be used to process the payment.
sig { returns(T.nilable(Networks)) }
attr_reader :networks
# Status of a card based on the card issuer.
sig { returns(T.nilable(String)) }
attr_reader :regulated_status
# Contains details on how this Card may be used for 3D Secure authentication.
sig { returns(T.nilable(ThreeDSecureUsage)) }
attr_reader :three_d_secure_usage
# If this Card is part of a card wallet, this contains the details of the card wallet.
sig { returns(T.nilable(Wallet)) }
attr_reader :wallet
end
class CardPresent < Stripe::StripeObject
class Networks < Stripe::StripeObject
# All networks available for selection via [payment_method_options.card.network](/api/payment_intents/confirm#confirm_payment_intent-payment_method_options-card-network).
sig { returns(T::Array[String]) }
attr_reader :available
# The preferred network for the card.
sig { returns(T.nilable(String)) }
attr_reader :preferred
end
class Offline < Stripe::StripeObject
# Time at which the payment was collected while offline
sig { returns(T.nilable(Integer)) }
attr_reader :stored_at
# The method used to process this payment method offline. Only deferred is allowed.
sig { returns(T.nilable(String)) }
attr_reader :type
end
class Wallet < Stripe::StripeObject
# The type of mobile wallet, one of `apple_pay`, `google_pay`, `samsung_pay`, or `unknown`.
sig { returns(String) }
attr_reader :type
end
# Card brand. Can be `amex`, `diners`, `discover`, `eftpos_au`, `jcb`, `link`, `mastercard`, `unionpay`, `visa`, or `unknown`.
sig { returns(T.nilable(String)) }
attr_reader :brand
# The [product code](https://stripe.com/docs/card-product-codes) that identifies the specific program or product associated with a card.
sig { returns(T.nilable(String)) }
attr_reader :brand_product
# The cardholder name as read from the card, in [ISO 7813](https://en.wikipedia.org/wiki/ISO/IEC_7813) format. May include alphanumeric characters, special characters and first/last name separator (`/`). In some cases, the cardholder name may not be available depending on how the issuer has configured the card. Cardholder name is typically not available on swipe or contactless payments, such as those made with Apple Pay and Google Pay.
sig { returns(T.nilable(String)) }
attr_reader :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.
sig { returns(T.nilable(String)) }
attr_reader :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.)
sig { returns(T.nilable(String)) }
attr_reader :description
# Two-digit number representing the card's expiration month.
sig { returns(Integer) }
attr_reader :exp_month
# Four-digit number representing the card's expiration year.
sig { returns(Integer) }
attr_reader :exp_year
# Uniquely identifies this particular card number. You can use this attribute to check whether two customers who’ve signed up with you are using the same card number, for example. For payment methods that tokenize card information (Apple Pay, Google Pay), the tokenized number might be provided instead of the underlying card number.
#
# *As of May 1, 2021, card fingerprint in India for Connect changed to allow two fingerprints for the same card---one for India and one for the rest of the world.*
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Card funding type. Can be `credit`, `debit`, `prepaid`, or `unknown`.
sig { returns(T.nilable(String)) }
attr_reader :funding
# Issuer identification number of the card. (For internal use only and not typically available in standard API requests.)
sig { returns(T.nilable(String)) }
attr_reader :iin
# The name of the card's issuing bank. (For internal use only and not typically available in standard API requests.)
sig { returns(T.nilable(String)) }
attr_reader :issuer
# The last four digits of the card.
sig { returns(T.nilable(String)) }
attr_reader :last4
# Contains information about card networks that can be used to process the payment.
sig { returns(T.nilable(Networks)) }
attr_reader :networks
# Details about payment methods collected offline.
sig { returns(T.nilable(Offline)) }
attr_reader :offline
# EMV tag 5F2D. Preferred languages specified by the integrated circuit chip.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :preferred_locales
# How card details were read in this transaction.
sig { returns(T.nilable(String)) }
attr_reader :read_method
# Attribute for field wallet
sig { returns(Wallet) }
attr_reader :wallet
end
class Cashapp < Stripe::StripeObject
# A unique and immutable identifier assigned by Cash App to every buyer.
sig { returns(T.nilable(String)) }
attr_reader :buyer_id
# A public identifier for buyers using Cash App.
sig { returns(T.nilable(String)) }
attr_reader :cashtag
end
class CustomerBalance < Stripe::StripeObject; end
class Eps < Stripe::StripeObject
# The customer's bank. Should be one of `arzte_und_apotheker_bank`, `austrian_anadi_bank_ag`, `bank_austria`, `bankhaus_carl_spangler`, `bankhaus_schelhammer_und_schattera_ag`, `bawag_psk_ag`, `bks_bank_ag`, `brull_kallmus_bank_ag`, `btv_vier_lander_bank`, `capital_bank_grawe_gruppe_ag`, `deutsche_bank_ag`, `dolomitenbank`, `easybank_ag`, `erste_bank_und_sparkassen`, `hypo_alpeadriabank_international_ag`, `hypo_noe_lb_fur_niederosterreich_u_wien`, `hypo_oberosterreich_salzburg_steiermark`, `hypo_tirol_bank_ag`, `hypo_vorarlberg_bank_ag`, `hypo_bank_burgenland_aktiengesellschaft`, `marchfelder_bank`, `oberbank_ag`, `raiffeisen_bankengruppe_osterreich`, `schoellerbank_ag`, `sparda_bank_wien`, `volksbank_gruppe`, `volkskreditbank_ag`, or `vr_bank_braunau`.
sig { returns(T.nilable(String)) }
attr_reader :bank
end
class Fpx < Stripe::StripeObject
# Account holder type, if provided. Can be one of `individual` or `company`.
sig { returns(T.nilable(String)) }
attr_reader :account_holder_type
# The customer's bank, if provided. Can be one of `affin_bank`, `agrobank`, `alliance_bank`, `ambank`, `bank_islam`, `bank_muamalat`, `bank_rakyat`, `bsn`, `cimb`, `hong_leong_bank`, `hsbc`, `kfh`, `maybank2u`, `ocbc`, `public_bank`, `rhb`, `standard_chartered`, `uob`, `deutsche_bank`, `maybank2e`, `pb_enterprise`, or `bank_of_china`.
sig { returns(String) }
attr_reader :bank
end
class Giropay < Stripe::StripeObject; end
class Gopay < Stripe::StripeObject; end
class Grabpay < Stripe::StripeObject; end
class IdBankTransfer < Stripe::StripeObject
# Attribute for field bank
sig { returns(T.nilable(String)) }
attr_reader :bank
# Attribute for field bank_code
sig { returns(T.nilable(String)) }
attr_reader :bank_code
# Attribute for field bank_name
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# Attribute for field display_name
sig { returns(T.nilable(String)) }
attr_reader :display_name
end
class Ideal < Stripe::StripeObject
# The customer's bank, if provided. Can be one of `abn_amro`, `asn_bank`, `bunq`, `handelsbanken`, `ing`, `knab`, `moneyou`, `n26`, `nn`, `rabobank`, `regiobank`, `revolut`, `sns_bank`, `triodos_bank`, `van_lanschot`, or `yoursafe`.
sig { returns(T.nilable(String)) }
attr_reader :bank
# The Bank Identifier Code of the customer's bank, if the bank was provided.
sig { returns(T.nilable(String)) }
attr_reader :bic
end
class InteracPresent < Stripe::StripeObject
class Networks < Stripe::StripeObject
# All networks available for selection via [payment_method_options.card.network](/api/payment_intents/confirm#confirm_payment_intent-payment_method_options-card-network).
sig { returns(T::Array[String]) }
attr_reader :available
# The preferred network for the card.
sig { returns(T.nilable(String)) }
attr_reader :preferred
end
# Card brand. Can be `interac`, `mastercard` or `visa`.
sig { returns(T.nilable(String)) }
attr_reader :brand
# The cardholder name as read from the card, in [ISO 7813](https://en.wikipedia.org/wiki/ISO/IEC_7813) format. May include alphanumeric characters, special characters and first/last name separator (`/`). In some cases, the cardholder name may not be available depending on how the issuer has configured the card. Cardholder name is typically not available on swipe or contactless payments, such as those made with Apple Pay and Google Pay.
sig { returns(T.nilable(String)) }
attr_reader :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.
sig { returns(T.nilable(String)) }
attr_reader :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.)
sig { returns(T.nilable(String)) }
attr_reader :description
# Two-digit number representing the card's expiration month.
sig { returns(Integer) }
attr_reader :exp_month
# Four-digit number representing the card's expiration year.
sig { returns(Integer) }
attr_reader :exp_year
# Uniquely identifies this particular card number. You can use this attribute to check whether two customers who’ve signed up with you are using the same card number, for example. For payment methods that tokenize card information (Apple Pay, Google Pay), the tokenized number might be provided instead of the underlying card number.
#
# *As of May 1, 2021, card fingerprint in India for Connect changed to allow two fingerprints for the same card---one for India and one for the rest of the world.*
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Card funding type. Can be `credit`, `debit`, `prepaid`, or `unknown`.
sig { returns(T.nilable(String)) }
attr_reader :funding
# Issuer identification number of the card. (For internal use only and not typically available in standard API requests.)
sig { returns(T.nilable(String)) }
attr_reader :iin
# The name of the card's issuing bank. (For internal use only and not typically available in standard API requests.)
sig { returns(T.nilable(String)) }
attr_reader :issuer
# The last four digits of the card.
sig { returns(T.nilable(String)) }
attr_reader :last4
# Contains information about card networks that can be used to process the payment.
sig { returns(T.nilable(Networks)) }
attr_reader :networks
# EMV tag 5F2D. Preferred languages specified by the integrated circuit chip.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :preferred_locales
# How card details were read in this transaction.
sig { returns(T.nilable(String)) }
attr_reader :read_method
end
class KakaoPay < Stripe::StripeObject; end
class Klarna < Stripe::StripeObject
class Dob < Stripe::StripeObject
# The day of birth, between 1 and 31.
sig { returns(T.nilable(Integer)) }
attr_reader :day
# The month of birth, between 1 and 12.
sig { returns(T.nilable(Integer)) }
attr_reader :month
# The four-digit year of birth.
sig { returns(T.nilable(Integer)) }
attr_reader :year
end
# The customer's date of birth, if provided.
sig { returns(T.nilable(Dob)) }
attr_reader :dob
end
class Konbini < Stripe::StripeObject; end
class KrCard < Stripe::StripeObject
# The local credit or debit card brand.
sig { returns(T.nilable(String)) }
attr_reader :brand
# The last four digits of the card. This may not be present for American Express cards.
sig { returns(T.nilable(String)) }
attr_reader :last4
end
class Link < Stripe::StripeObject
# Account owner's email address.
sig { returns(T.nilable(String)) }
attr_reader :email
# [Deprecated] This is a legacy parameter that no longer has any function.
sig { returns(String) }
attr_reader :persistent_token
end
class MbWay < Stripe::StripeObject; end
class Mobilepay < Stripe::StripeObject; end
class Multibanco < Stripe::StripeObject; end
class NaverPay < Stripe::StripeObject
# Uniquely identifies this particular Naver Pay account. You can use this attribute to check whether two Naver Pay accounts are the same.
sig { returns(T.nilable(String)) }
attr_reader :buyer_id
# Whether to fund this transaction with Naver Pay points or a card.
sig { returns(String) }
attr_reader :funding
end
class NzBankAccount < Stripe::StripeObject
# The name on the bank account. Only present if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod’s billing details.
sig { returns(T.nilable(String)) }
attr_reader :account_holder_name
# The numeric code for the bank account's bank.
sig { returns(String) }
attr_reader :bank_code
# The name of the bank.
sig { returns(String) }
attr_reader :bank_name
# The numeric code for the bank account's bank branch.
sig { returns(String) }
attr_reader :branch_code
# Last four digits of the bank account number.
sig { returns(String) }
attr_reader :last4
# The suffix of the bank account number.
sig { returns(T.nilable(String)) }
attr_reader :suffix
end
class Oxxo < Stripe::StripeObject; end
class P24 < Stripe::StripeObject
# The customer's bank, if provided.
sig { returns(T.nilable(String)) }
attr_reader :bank
end
class PayByBank < Stripe::StripeObject; end
class Payco < Stripe::StripeObject; end
class Paynow < Stripe::StripeObject; end
class Paypal < Stripe::StripeObject
# Two-letter ISO code representing the buyer's country. Values are provided by PayPal directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(String)) }
attr_reader :country
# Uniquely identifies this particular PayPal account. You can use this attribute to check whether two PayPal accounts are the same.
sig { returns(T.nilable(String)) }
attr_reader :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.
sig { returns(T.nilable(String)) }
attr_reader :payer_email
# PayPal account PayerID. This identifier uniquely identifies the PayPal customer.
sig { returns(T.nilable(String)) }
attr_reader :payer_id
# Owner's verified email. Values are verified or provided by PayPal directly
# (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(String)) }
attr_reader :verified_email
end
class Payto < Stripe::StripeObject
# Bank-State-Branch number of the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bsb_number
# Last four digits of the bank account number.
sig { returns(T.nilable(String)) }
attr_reader :last4
# The PayID alias for the bank account.
sig { returns(T.nilable(String)) }
attr_reader :pay_id
end
class Pix < Stripe::StripeObject; end
class Promptpay < Stripe::StripeObject; end
class Qris < Stripe::StripeObject; end
class Rechnung < Stripe::StripeObject
class Dob < Stripe::StripeObject
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_reader :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_reader :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_reader :year
end
# Attribute for field dob
sig { returns(Dob) }
attr_reader :dob
end
class RevolutPay < Stripe::StripeObject; end
class SamsungPay < Stripe::StripeObject; end
class Satispay < Stripe::StripeObject; end
class SepaDebit < Stripe::StripeObject
class GeneratedFrom < Stripe::StripeObject
# The ID of the Charge that generated this PaymentMethod, if any.
sig { returns(T.nilable(T.any(String, Stripe::Charge))) }
attr_reader :charge
# The ID of the SetupAttempt that generated this PaymentMethod, if any.
sig { returns(T.nilable(T.any(String, Stripe::SetupAttempt))) }
attr_reader :setup_attempt
end
# Bank code of bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_code
# Branch code of bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :branch_code
# Two-letter ISO code representing the country the bank account is located in.
sig { returns(T.nilable(String)) }
attr_reader :country
# Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Information about the object that generated this PaymentMethod.
sig { returns(T.nilable(GeneratedFrom)) }
attr_reader :generated_from
# Last four characters of the IBAN.
sig { returns(T.nilable(String)) }
attr_reader :last4
end
class Shopeepay < Stripe::StripeObject; end
class Sofort < Stripe::StripeObject
# Two-letter ISO code representing the country the bank account is located in.
sig { returns(T.nilable(String)) }
attr_reader :country
end
class StripeBalance < Stripe::StripeObject
# The connected account ID whose Stripe balance to use as the source of payment
sig { returns(T.nilable(String)) }
attr_reader :account
# The [source_type](https://docs.stripe.com/api/balance/balance_object#balance_object-available-source_types) of the balance
sig { returns(String) }
attr_reader :source_type
end
class Swish < Stripe::StripeObject; end
class Twint < Stripe::StripeObject; end
class UsBankAccount < Stripe::StripeObject
class Networks < Stripe::StripeObject
# The preferred network.
sig { returns(T.nilable(String)) }
attr_reader :preferred
# All supported networks.
sig { returns(T::Array[String]) }
attr_reader :supported
end
class StatusDetails < Stripe::StripeObject
class Blocked < Stripe::StripeObject
# The ACH network code that resulted in this block.
sig { returns(T.nilable(String)) }
attr_reader :network_code
# The reason why this PaymentMethod's fingerprint has been blocked
sig { returns(T.nilable(String)) }
attr_reader :reason
end
# Attribute for field blocked
sig { returns(Blocked) }
attr_reader :blocked
end
# Account holder type: individual or company.
sig { returns(T.nilable(String)) }
attr_reader :account_holder_type
# Account number of the bank account.
sig { returns(T.nilable(String)) }
attr_reader :account_number
# Account type: checkings or savings. Defaults to checking if omitted.
sig { returns(T.nilable(String)) }
attr_reader :account_type
# The name of the bank.
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# The ID of the Financial Connections Account used to create the payment method.
sig { returns(T.nilable(String)) }
attr_reader :financial_connections_account
# Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Last four digits of the bank account number.
sig { returns(T.nilable(String)) }
attr_reader :last4
# Contains information about US bank account networks that can be used.
sig { returns(T.nilable(Networks)) }
attr_reader :networks
# Routing number of the bank account.
sig { returns(T.nilable(String)) }
attr_reader :routing_number
# Contains information about the future reusability of this PaymentMethod.
sig { returns(T.nilable(StatusDetails)) }
attr_reader :status_details
end
class WechatPay < Stripe::StripeObject; end
class Zip < Stripe::StripeObject; end
# Attribute for field acss_debit
sig { returns(AcssDebit) }
attr_reader :acss_debit
# Attribute for field affirm
sig { returns(Affirm) }
attr_reader :affirm
# Attribute for field afterpay_clearpay
sig { returns(AfterpayClearpay) }
attr_reader :afterpay_clearpay
# Attribute for field alipay
sig { returns(Alipay) }
attr_reader :alipay
# This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to “unspecified”.
sig { returns(String) }
attr_reader :allow_redisplay
# Attribute for field alma
sig { returns(Alma) }
attr_reader :alma
# Attribute for field amazon_pay
sig { returns(AmazonPay) }
attr_reader :amazon_pay
# Attribute for field au_becs_debit
sig { returns(AuBecsDebit) }
attr_reader :au_becs_debit
# Attribute for field bacs_debit
sig { returns(BacsDebit) }
attr_reader :bacs_debit
# Attribute for field bancontact
sig { returns(Bancontact) }
attr_reader :bancontact
# Attribute for field billie
sig { returns(Billie) }
attr_reader :billie
# Attribute for field billing_details
sig { returns(BillingDetails) }
attr_reader :billing_details
# Attribute for field blik
sig { returns(Blik) }
attr_reader :blik
# Attribute for field boleto
sig { returns(Boleto) }
attr_reader :boleto
# Attribute for field card
sig { returns(Card) }
attr_reader :card
# Attribute for field card_present
sig { returns(CardPresent) }
attr_reader :card_present
# Attribute for field cashapp
sig { returns(Cashapp) }
attr_reader :cashapp
# The ID of the Customer to which this PaymentMethod is saved. This will not be set when the PaymentMethod has not been saved to a Customer.
sig { returns(T.nilable(T.any(String, Stripe::Customer))) }
attr_reader :customer
# Attribute for field customer_account
sig { returns(T.nilable(String)) }
attr_reader :customer_account
# Attribute for field customer_balance
sig { returns(CustomerBalance) }
attr_reader :customer_balance
# Attribute for field eps
sig { returns(Eps) }
attr_reader :eps
# Attribute for field fpx
sig { returns(Fpx) }
attr_reader :fpx
# Attribute for field giropay
sig { returns(Giropay) }
attr_reader :giropay
# Attribute for field gopay
sig { returns(Gopay) }
attr_reader :gopay
# Attribute for field grabpay
sig { returns(Grabpay) }
attr_reader :grabpay
# Attribute for field id_bank_transfer
sig { returns(IdBankTransfer) }
attr_reader :id_bank_transfer
# Attribute for field ideal
sig { returns(Ideal) }
attr_reader :ideal
# Attribute for field interac_present
sig { returns(InteracPresent) }
attr_reader :interac_present
# Attribute for field kakao_pay
sig { returns(KakaoPay) }
attr_reader :kakao_pay
# Attribute for field klarna
sig { returns(Klarna) }
attr_reader :klarna
# Attribute for field konbini
sig { returns(Konbini) }
attr_reader :konbini
# Attribute for field kr_card
sig { returns(KrCard) }
attr_reader :kr_card
# Attribute for field link
sig { returns(Link) }
attr_reader :link
# Attribute for field mb_way
sig { returns(MbWay) }
attr_reader :mb_way
# Attribute for field mobilepay
sig { returns(Mobilepay) }
attr_reader :mobilepay
# Attribute for field multibanco
sig { returns(Multibanco) }
attr_reader :multibanco
# Attribute for field naver_pay
sig { returns(NaverPay) }
attr_reader :naver_pay
# Attribute for field nz_bank_account
sig { returns(NzBankAccount) }
attr_reader :nz_bank_account
# Attribute for field oxxo
sig { returns(Oxxo) }
attr_reader :oxxo
# Attribute for field p24
sig { returns(P24) }
attr_reader :p24
# Attribute for field pay_by_bank
sig { returns(PayByBank) }
attr_reader :pay_by_bank
# Attribute for field payco
sig { returns(Payco) }
attr_reader :payco
# Attribute for field paynow
sig { returns(Paynow) }
attr_reader :paynow
# Attribute for field paypal
sig { returns(Paypal) }
attr_reader :paypal
# Attribute for field payto
sig { returns(Payto) }
attr_reader :payto
# Attribute for field pix
sig { returns(Pix) }
attr_reader :pix
# Attribute for field promptpay
sig { returns(Promptpay) }
attr_reader :promptpay
# Attribute for field qris
sig { returns(Qris) }
attr_reader :qris
# Attribute for field rechnung
sig { returns(Rechnung) }
attr_reader :rechnung
# Attribute for field revolut_pay
sig { returns(RevolutPay) }
attr_reader :revolut_pay
# Attribute for field samsung_pay
sig { returns(SamsungPay) }
attr_reader :samsung_pay
# Attribute for field satispay
sig { returns(Satispay) }
attr_reader :satispay
# Attribute for field sepa_debit
sig { returns(SepaDebit) }
attr_reader :sepa_debit
# Attribute for field shopeepay
sig { returns(Shopeepay) }
attr_reader :shopeepay
# Attribute for field sofort
sig { returns(Sofort) }
attr_reader :sofort
# Attribute for field stripe_balance
sig { returns(StripeBalance) }
attr_reader :stripe_balance
# Attribute for field swish
sig { returns(Swish) }
attr_reader :swish
# Attribute for field twint
sig { returns(Twint) }
attr_reader :twint
# The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
sig { returns(String) }
attr_reader :type
# Attribute for field us_bank_account
sig { returns(UsBankAccount) }
attr_reader :us_bank_account
# Attribute for field wechat_pay
sig { returns(WechatPay) }
attr_reader :wechat_pay
# Attribute for field zip
sig { returns(Zip) }
attr_reader :zip
end
class Shipping < Stripe::StripeObject
class Address < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Attribute for field address
sig { returns(Address) }
attr_reader :address
# Recipient name.
sig { returns(String) }
attr_reader :name
# Recipient phone (including extension).
sig { returns(T.nilable(String)) }
attr_reader :phone
end
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# Time at which this ConfirmationToken expires and can no longer be used to confirm a PaymentIntent or SetupIntent.
sig { returns(T.nilable(Integer)) }
attr_reader :expires_at
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# Data used for generating a Mandate.
sig { returns(T.nilable(MandateData)) }
attr_reader :mandate_data
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# ID of the PaymentIntent that this ConfirmationToken was used to confirm, or null if this ConfirmationToken has not yet been used.
sig { returns(T.nilable(String)) }
attr_reader :payment_intent
# Payment-method-specific configuration for this ConfirmationToken.
sig { returns(T.nilable(PaymentMethodOptions)) }
attr_reader :payment_method_options
# Payment details collected by the Payment Element, used to create a PaymentMethod when a PaymentIntent or SetupIntent is confirmed with this ConfirmationToken.
sig { returns(T.nilable(PaymentMethodPreview)) }
attr_reader :payment_method_preview
# Return URL used to confirm the Intent.
sig { returns(T.nilable(String)) }
attr_reader :return_url
# Indicates that you intend to make future payments with this ConfirmationToken's payment method.
#
# The presence of this property will [attach the payment method](https://stripe.com/docs/payments/save-during-payment) to the PaymentIntent's Customer, if present, after the PaymentIntent is confirmed and any required actions from the user are complete.
sig { returns(T.nilable(String)) }
attr_reader :setup_future_usage
# ID of the SetupIntent that this ConfirmationToken was used to confirm, or null if this ConfirmationToken has not yet been used.
sig { returns(T.nilable(String)) }
attr_reader :setup_intent
# Shipping information collected on this ConfirmationToken.
sig { returns(T.nilable(Shipping)) }
attr_reader :shipping
# Indicates whether the Stripe SDK is used to handle confirmation flow. Defaults to `true` on ConfirmationToken.
sig { returns(T::Boolean) }
attr_reader :use_stripe_sdk
class CreateParams < Stripe::RequestParams
class PaymentMethodData < Stripe::RequestParams
class AcssDebit < Stripe::RequestParams
# Customer's bank account number.
sig { returns(String) }
attr_accessor :account_number
# Institution number of the customer's bank.
sig { returns(String) }
attr_accessor :institution_number
# Transit number of the customer's bank.
sig { returns(String) }
attr_accessor :transit_number
sig {
params(account_number: String, institution_number: String, transit_number: String).void
}
def initialize(account_number: nil, institution_number: nil, transit_number: nil); end
end
class Affirm < Stripe::RequestParams; end
class AfterpayClearpay < Stripe::RequestParams; end
class Alipay < Stripe::RequestParams; end
class Alma < Stripe::RequestParams; end
class AmazonPay < Stripe::RequestParams; end
class AuBecsDebit < Stripe::RequestParams
# The account number for the bank account.
sig { returns(String) }
attr_accessor :account_number
# Bank-State-Branch number of the bank account.
sig { returns(String) }
attr_accessor :bsb_number
sig { params(account_number: String, bsb_number: String).void }
def initialize(account_number: nil, bsb_number: nil); end
end
class BacsDebit < Stripe::RequestParams
# Account number of the bank account that the funds will be debited from.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Sort code of the bank account. (e.g., `10-20-30`)
sig { returns(T.nilable(String)) }
attr_accessor :sort_code
sig { params(account_number: T.nilable(String), sort_code: T.nilable(String)).void }
def initialize(account_number: nil, sort_code: nil); end
end
class Bancontact < Stripe::RequestParams; end
class Billie < Stripe::RequestParams; end
class BillingDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Billing address.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::BillingDetails::Address))))
}
attr_accessor :address
# Email address.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :email
# Full name.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :name
# Billing phone number (including extension).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :phone
# Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
sig { returns(T.nilable(String)) }
attr_accessor :tax_id
sig {
params(address: T.nilable(T.nilable(T.any(String, ::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::BillingDetails::Address))), email: T.nilable(T.nilable(String)), name: T.nilable(T.nilable(String)), phone: T.nilable(T.nilable(String)), tax_id: T.nilable(String)).void
}
def initialize(address: nil, email: nil, name: nil, phone: nil, tax_id: nil); end
end
class Blik < Stripe::RequestParams; end
class Boleto < Stripe::RequestParams
# The tax ID of the customer (CPF for individual consumers or CNPJ for businesses consumers)
sig { returns(String) }
attr_accessor :tax_id
sig { params(tax_id: String).void }
def initialize(tax_id: nil); end
end
class Cashapp < Stripe::RequestParams; end
class CustomerBalance < Stripe::RequestParams; end
class Eps < Stripe::RequestParams
# The customer's bank.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class Fpx < Stripe::RequestParams
# Account holder type for FPX transaction
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_type
# The customer's bank.
sig { returns(String) }
attr_accessor :bank
sig { params(account_holder_type: T.nilable(String), bank: String).void }
def initialize(account_holder_type: nil, bank: nil); end
end
class Giropay < Stripe::RequestParams; end
class Gopay < Stripe::RequestParams; end
class Grabpay < Stripe::RequestParams; end
class IdBankTransfer < Stripe::RequestParams
# Bank where the account is held.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class Ideal < Stripe::RequestParams
# The customer's bank. Only use this parameter for existing customers. Don't use it for new customers.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class InteracPresent < Stripe::RequestParams; end
class KakaoPay < Stripe::RequestParams; end
class Klarna < Stripe::RequestParams
class Dob < Stripe::RequestParams
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
# Customer's date of birth
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Klarna::Dob))
}
attr_accessor :dob
sig {
params(dob: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Klarna::Dob)).void
}
def initialize(dob: nil); end
end
class Konbini < Stripe::RequestParams; end
class KrCard < Stripe::RequestParams; end
class Link < Stripe::RequestParams; end
class MbWay < Stripe::RequestParams; end
class Mobilepay < Stripe::RequestParams; end
class Multibanco < Stripe::RequestParams; end
class NaverPay < Stripe::RequestParams
# Whether to use Naver Pay points or a card to fund this transaction. If not provided, this defaults to `card`.
sig { returns(T.nilable(String)) }
attr_accessor :funding
sig { params(funding: T.nilable(String)).void }
def initialize(funding: nil); end
end
class NzBankAccount < Stripe::RequestParams
# The name on the bank account. Only required if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod’s billing details.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_name
# The account number for the bank account.
sig { returns(String) }
attr_accessor :account_number
# The numeric code for the bank account's bank.
sig { returns(String) }
attr_accessor :bank_code
# The numeric code for the bank account's bank branch.
sig { returns(String) }
attr_accessor :branch_code
# Attribute for param field reference
sig { returns(T.nilable(String)) }
attr_accessor :reference
# The suffix of the bank account number.
sig { returns(String) }
attr_accessor :suffix
sig {
params(account_holder_name: T.nilable(String), account_number: String, bank_code: String, branch_code: String, reference: T.nilable(String), suffix: String).void
}
def initialize(
account_holder_name: nil,
account_number: nil,
bank_code: nil,
branch_code: nil,
reference: nil,
suffix: nil
); end
end
class Oxxo < Stripe::RequestParams; end
class P24 < Stripe::RequestParams
# The customer's bank.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class PayByBank < Stripe::RequestParams; end
class Payco < Stripe::RequestParams; end
class Paynow < Stripe::RequestParams; end
class Paypal < Stripe::RequestParams; end
class Payto < Stripe::RequestParams
# The account number for the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Bank-State-Branch number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :bsb_number
# The PayID alias for the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :pay_id
sig {
params(account_number: T.nilable(String), bsb_number: T.nilable(String), pay_id: T.nilable(String)).void
}
def initialize(account_number: nil, bsb_number: nil, pay_id: nil); end
end
class Pix < Stripe::RequestParams; end
class Promptpay < Stripe::RequestParams; end
class Qris < Stripe::RequestParams; end
class RadarOptions < Stripe::RequestParams
# A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
sig { returns(T.nilable(String)) }
attr_accessor :session
sig { params(session: T.nilable(String)).void }
def initialize(session: nil); end
end
class Rechnung < Stripe::RequestParams
class Dob < Stripe::RequestParams
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
# Customer's date of birth
sig {
returns(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Rechnung::Dob)
}
attr_accessor :dob
sig {
params(dob: ::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Rechnung::Dob).void
}
def initialize(dob: nil); end
end
class RevolutPay < Stripe::RequestParams; end
class SamsungPay < Stripe::RequestParams; end
class Satispay < Stripe::RequestParams; end
class SepaDebit < Stripe::RequestParams
# IBAN of the bank account.
sig { returns(String) }
attr_accessor :iban
sig { params(iban: String).void }
def initialize(iban: nil); end
end
class Shopeepay < Stripe::RequestParams; end
class Sofort < Stripe::RequestParams
# Two-letter ISO code representing the country the bank account is located in.
sig { returns(String) }
attr_accessor :country
sig { params(country: String).void }
def initialize(country: nil); end
end
class StripeBalance < Stripe::RequestParams
# The connected account ID whose Stripe balance to use as the source of payment
sig { returns(T.nilable(String)) }
attr_accessor :account
# The [source_type](https://docs.stripe.com/api/balance/balance_object#balance_object-available-source_types) of the balance
sig { returns(T.nilable(String)) }
attr_accessor :source_type
sig { params(account: T.nilable(String), source_type: T.nilable(String)).void }
def initialize(account: nil, source_type: nil); end
end
class Swish < Stripe::RequestParams; end
class Twint < Stripe::RequestParams; end
class UsBankAccount < Stripe::RequestParams
# Account holder type: individual or company.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_type
# Account number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Account type: checkings or savings. Defaults to checking if omitted.
sig { returns(T.nilable(String)) }
attr_accessor :account_type
# The ID of a Financial Connections Account to use as a payment method.
sig { returns(T.nilable(String)) }
attr_accessor :financial_connections_account
# Routing number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :routing_number
sig {
params(account_holder_type: T.nilable(String), account_number: T.nilable(String), account_type: T.nilable(String), financial_connections_account: T.nilable(String), routing_number: T.nilable(String)).void
}
def initialize(
account_holder_type: nil,
account_number: nil,
account_type: nil,
financial_connections_account: nil,
routing_number: nil
); end
end
class WechatPay < Stripe::RequestParams; end
class Zip < Stripe::RequestParams; end
# If this is an `acss_debit` PaymentMethod, this hash contains details about the ACSS Debit payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::AcssDebit))
}
attr_accessor :acss_debit
# If this is an `affirm` PaymentMethod, this hash contains details about the Affirm payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Affirm))
}
attr_accessor :affirm
# If this is an `AfterpayClearpay` PaymentMethod, this hash contains details about the AfterpayClearpay payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::AfterpayClearpay))
}
attr_accessor :afterpay_clearpay
# If this is an `Alipay` PaymentMethod, this hash contains details about the Alipay payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Alipay))
}
attr_accessor :alipay
# This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :allow_redisplay
# If this is a Alma PaymentMethod, this hash contains details about the Alma payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Alma))
}
attr_accessor :alma
# If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::AmazonPay))
}
attr_accessor :amazon_pay
# If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::AuBecsDebit))
}
attr_accessor :au_becs_debit
# If this is a `bacs_debit` PaymentMethod, this hash contains details about the Bacs Direct Debit bank account.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::BacsDebit))
}
attr_accessor :bacs_debit
# If this is a `bancontact` PaymentMethod, this hash contains details about the Bancontact payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Bancontact))
}
attr_accessor :bancontact
# If this is a `billie` PaymentMethod, this hash contains details about the Billie payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Billie))
}
attr_accessor :billie
# Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::BillingDetails))
}
attr_accessor :billing_details
# If this is a `blik` PaymentMethod, this hash contains details about the BLIK payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Blik))
}
attr_accessor :blik
# If this is a `boleto` PaymentMethod, this hash contains details about the Boleto payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Boleto))
}
attr_accessor :boleto
# If this is a `cashapp` PaymentMethod, this hash contains details about the Cash App Pay payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Cashapp))
}
attr_accessor :cashapp
# If this is a `customer_balance` PaymentMethod, this hash contains details about the CustomerBalance payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::CustomerBalance))
}
attr_accessor :customer_balance
# If this is an `eps` PaymentMethod, this hash contains details about the EPS payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Eps))
}
attr_accessor :eps
# If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Fpx))
}
attr_accessor :fpx
# If this is a `giropay` PaymentMethod, this hash contains details about the Giropay payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Giropay))
}
attr_accessor :giropay
# If this is a Gopay PaymentMethod, this hash contains details about the Gopay payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Gopay))
}
attr_accessor :gopay
# If this is a `grabpay` PaymentMethod, this hash contains details about the GrabPay payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Grabpay))
}
attr_accessor :grabpay
# If this is an `IdBankTransfer` PaymentMethod, this hash contains details about the IdBankTransfer payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::IdBankTransfer))
}
attr_accessor :id_bank_transfer
# If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Ideal))
}
attr_accessor :ideal
# If this is an `interac_present` PaymentMethod, this hash contains details about the Interac Present payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::InteracPresent))
}
attr_accessor :interac_present
# If this is a `kakao_pay` PaymentMethod, this hash contains details about the Kakao Pay payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::KakaoPay))
}
attr_accessor :kakao_pay
# If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Klarna))
}
attr_accessor :klarna
# If this is a `konbini` PaymentMethod, this hash contains details about the Konbini payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Konbini))
}
attr_accessor :konbini
# If this is a `kr_card` PaymentMethod, this hash contains details about the Korean Card payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::KrCard))
}
attr_accessor :kr_card
# If this is an `Link` PaymentMethod, this hash contains details about the Link payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Link))
}
attr_accessor :link
# If this is a MB WAY PaymentMethod, this hash contains details about the MB WAY payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::MbWay))
}
attr_accessor :mb_way
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# If this is a `mobilepay` PaymentMethod, this hash contains details about the MobilePay payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Mobilepay))
}
attr_accessor :mobilepay
# If this is a `multibanco` PaymentMethod, this hash contains details about the Multibanco payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Multibanco))
}
attr_accessor :multibanco
# If this is a `naver_pay` PaymentMethod, this hash contains details about the Naver Pay payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::NaverPay))
}
attr_accessor :naver_pay
# If this is an nz_bank_account PaymentMethod, this hash contains details about the nz_bank_account payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::NzBankAccount))
}
attr_accessor :nz_bank_account
# If this is an `oxxo` PaymentMethod, this hash contains details about the OXXO payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Oxxo))
}
attr_accessor :oxxo
# If this is a `p24` PaymentMethod, this hash contains details about the P24 payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::P24))
}
attr_accessor :p24
# If this is a `pay_by_bank` PaymentMethod, this hash contains details about the PayByBank payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::PayByBank))
}
attr_accessor :pay_by_bank
# If this is a `payco` PaymentMethod, this hash contains details about the PAYCO payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Payco))
}
attr_accessor :payco
# If this is a `paynow` PaymentMethod, this hash contains details about the PayNow payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Paynow))
}
attr_accessor :paynow
# If this is a `paypal` PaymentMethod, this hash contains details about the PayPal payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Paypal))
}
attr_accessor :paypal
# If this is a `payto` PaymentMethod, this hash contains details about the PayTo payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Payto))
}
attr_accessor :payto
# If this is a `pix` PaymentMethod, this hash contains details about the Pix payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Pix))
}
attr_accessor :pix
# If this is a `promptpay` PaymentMethod, this hash contains details about the PromptPay payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Promptpay))
}
attr_accessor :promptpay
# If this is a `qris` PaymentMethod, this hash contains details about the QRIS payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Qris))
}
attr_accessor :qris
# Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::RadarOptions))
}
attr_accessor :radar_options
# If this is a `rechnung` PaymentMethod, this hash contains details about the Rechnung payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Rechnung))
}
attr_accessor :rechnung
# If this is a `revolut_pay` PaymentMethod, this hash contains details about the Revolut Pay payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::RevolutPay))
}
attr_accessor :revolut_pay
# If this is a `samsung_pay` PaymentMethod, this hash contains details about the SamsungPay payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::SamsungPay))
}
attr_accessor :samsung_pay
# If this is a `satispay` PaymentMethod, this hash contains details about the Satispay payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Satispay))
}
attr_accessor :satispay
# If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::SepaDebit))
}
attr_accessor :sepa_debit
# If this is a Shopeepay PaymentMethod, this hash contains details about the Shopeepay payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Shopeepay))
}
attr_accessor :shopeepay
# If this is a `sofort` PaymentMethod, this hash contains details about the SOFORT payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Sofort))
}
attr_accessor :sofort
# This hash contains details about the Stripe balance payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::StripeBalance))
}
attr_accessor :stripe_balance
# If this is a `swish` PaymentMethod, this hash contains details about the Swish payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Swish))
}
attr_accessor :swish
# If this is a TWINT PaymentMethod, this hash contains details about the TWINT payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Twint))
}
attr_accessor :twint
# The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
sig { returns(String) }
attr_accessor :type
# If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::UsBankAccount))
}
attr_accessor :us_bank_account
# If this is an `wechat_pay` PaymentMethod, this hash contains details about the wechat_pay payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::WechatPay))
}
attr_accessor :wechat_pay
# If this is a `zip` PaymentMethod, this hash contains details about the Zip payment method.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Zip))
}
attr_accessor :zip
sig {
params(acss_debit: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::AcssDebit), affirm: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Affirm), afterpay_clearpay: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::AfterpayClearpay), alipay: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Alipay), allow_redisplay: T.nilable(String), alma: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Alma), amazon_pay: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::AmazonPay), au_becs_debit: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::AuBecsDebit), bacs_debit: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::BacsDebit), bancontact: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Bancontact), billie: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Billie), billing_details: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::BillingDetails), blik: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Blik), boleto: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Boleto), cashapp: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Cashapp), customer_balance: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::CustomerBalance), eps: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Eps), fpx: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Fpx), giropay: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Giropay), gopay: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Gopay), grabpay: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Grabpay), id_bank_transfer: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::IdBankTransfer), ideal: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Ideal), interac_present: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::InteracPresent), kakao_pay: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::KakaoPay), klarna: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Klarna), konbini: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Konbini), kr_card: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::KrCard), link: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Link), mb_way: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::MbWay), metadata: T.nilable(T::Hash[String, String]), mobilepay: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Mobilepay), multibanco: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Multibanco), naver_pay: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::NaverPay), nz_bank_account: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::NzBankAccount), oxxo: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Oxxo), p24: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::P24), pay_by_bank: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::PayByBank), payco: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Payco), paynow: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Paynow), paypal: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Paypal), payto: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Payto), pix: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Pix), promptpay: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Promptpay), qris: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Qris), radar_options: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::RadarOptions), rechnung: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Rechnung), revolut_pay: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::RevolutPay), samsung_pay: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::SamsungPay), satispay: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Satispay), sepa_debit: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::SepaDebit), shopeepay: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Shopeepay), sofort: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Sofort), stripe_balance: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::StripeBalance), swish: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Swish), twint: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Twint), type: String, us_bank_account: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::UsBankAccount), wechat_pay: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::WechatPay), zip: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData::Zip)).void
}
def initialize(
acss_debit: nil,
affirm: nil,
afterpay_clearpay: nil,
alipay: nil,
allow_redisplay: nil,
alma: nil,
amazon_pay: nil,
au_becs_debit: nil,
bacs_debit: nil,
bancontact: nil,
billie: nil,
billing_details: nil,
blik: nil,
boleto: nil,
cashapp: nil,
customer_balance: nil,
eps: nil,
fpx: nil,
giropay: nil,
gopay: nil,
grabpay: nil,
id_bank_transfer: nil,
ideal: nil,
interac_present: nil,
kakao_pay: nil,
klarna: nil,
konbini: nil,
kr_card: nil,
link: nil,
mb_way: nil,
metadata: nil,
mobilepay: nil,
multibanco: nil,
naver_pay: nil,
nz_bank_account: nil,
oxxo: nil,
p24: nil,
pay_by_bank: nil,
payco: nil,
paynow: nil,
paypal: nil,
payto: nil,
pix: nil,
promptpay: nil,
qris: nil,
radar_options: nil,
rechnung: nil,
revolut_pay: nil,
samsung_pay: nil,
satispay: nil,
sepa_debit: nil,
shopeepay: nil,
sofort: nil,
stripe_balance: nil,
swish: nil,
twint: nil,
type: nil,
us_bank_account: nil,
wechat_pay: nil,
zip: nil
); end
end
class PaymentMethodOptions < Stripe::RequestParams
class Card < Stripe::RequestParams
class Installments < Stripe::RequestParams
class Plan < Stripe::RequestParams
# For `fixed_count` installment plans, this is required. It represents the number of installment payments your customer will make to their credit card.
sig { returns(T.nilable(Integer)) }
attr_accessor :count
# For `fixed_count` installment plans, this is required. It represents the interval between installment payments your customer will make to their credit card.
# One of `month`.
sig { returns(T.nilable(String)) }
attr_accessor :interval
# Type of installment plan, one of `fixed_count`.
sig { returns(String) }
attr_accessor :type
sig {
params(count: T.nilable(Integer), interval: T.nilable(String), type: String).void
}
def initialize(count: nil, interval: nil, type: nil); end
end
# The selected installment plan to use for this payment attempt.
# This parameter can only be provided during confirmation.
sig {
returns(::Stripe::ConfirmationToken::CreateParams::PaymentMethodOptions::Card::Installments::Plan)
}
attr_accessor :plan
sig {
params(plan: ::Stripe::ConfirmationToken::CreateParams::PaymentMethodOptions::Card::Installments::Plan).void
}
def initialize(plan: nil); end
end
# Installment configuration for payments confirmed using this ConfirmationToken.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodOptions::Card::Installments))
}
attr_accessor :installments
sig {
params(installments: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodOptions::Card::Installments)).void
}
def initialize(installments: nil); end
end
# Configuration for any card payments confirmed using this ConfirmationToken.
sig {
returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodOptions::Card))
}
attr_accessor :card
sig {
params(card: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodOptions::Card)).void
}
def initialize(card: nil); end
end
class Shipping < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Shipping address
sig { returns(::Stripe::ConfirmationToken::CreateParams::Shipping::Address) }
attr_accessor :address
# Recipient name.
sig { returns(String) }
attr_accessor :name
# Recipient phone (including extension)
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :phone
sig {
params(address: ::Stripe::ConfirmationToken::CreateParams::Shipping::Address, name: String, phone: T.nilable(T.nilable(String))).void
}
def initialize(address: nil, name: nil, phone: nil); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# ID of an existing PaymentMethod.
sig { returns(T.nilable(String)) }
attr_accessor :payment_method
# If provided, this hash will be used to create a PaymentMethod.
sig { returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData)) }
attr_accessor :payment_method_data
# Payment-method-specific configuration for this ConfirmationToken.
sig { returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodOptions)) }
attr_accessor :payment_method_options
# Return URL used to confirm the Intent.
sig { returns(T.nilable(String)) }
attr_accessor :return_url
# Indicates that you intend to make future payments with this ConfirmationToken's payment method.
#
# The presence of this property will [attach the payment method](https://stripe.com/docs/payments/save-during-payment) to the PaymentIntent's Customer, if present, after the PaymentIntent is confirmed and any required actions from the user are complete.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
# Shipping information for this ConfirmationToken.
sig { returns(T.nilable(::Stripe::ConfirmationToken::CreateParams::Shipping)) }
attr_accessor :shipping
sig {
params(expand: T.nilable(T::Array[String]), payment_method: T.nilable(String), payment_method_data: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodData), payment_method_options: T.nilable(::Stripe::ConfirmationToken::CreateParams::PaymentMethodOptions), return_url: T.nilable(String), setup_future_usage: T.nilable(String), shipping: T.nilable(::Stripe::ConfirmationToken::CreateParams::Shipping)).void
}
def initialize(
expand: nil,
payment_method: nil,
payment_method_data: nil,
payment_method_options: nil,
return_url: nil,
setup_future_usage: nil,
shipping: nil
); end
end
end
end
# typed: true
module Stripe
class ConnectCollectionTransfer < APIResource
# Amount transferred, in cents (or local equivalent).
sig { returns(Integer) }
attr_reader :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).
sig { returns(String) }
attr_reader :currency
# ID of the account that funds are being collected for.
sig { returns(T.any(String, Stripe::Account)) }
attr_reader :destination
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
end
end
# typed: true
module Stripe
# Stripe needs to collect certain pieces of information about each account
# created. These requirements can differ depending on the account's country. The
# Country Specs API makes these rules available to your integration.
#
# You can also view the information from this API call as [an online
# guide](https://docs.stripe.com/docs/connect/required-verification-information).
class CountrySpec < APIResource
class VerificationFields < Stripe::StripeObject
class Company < Stripe::StripeObject
# Additional fields which are only required for some users.
sig { returns(T::Array[String]) }
attr_reader :additional
# Fields which every account must eventually provide.
sig { returns(T::Array[String]) }
attr_reader :minimum
end
class Individual < Stripe::StripeObject
# Additional fields which are only required for some users.
sig { returns(T::Array[String]) }
attr_reader :additional
# Fields which every account must eventually provide.
sig { returns(T::Array[String]) }
attr_reader :minimum
end
# Attribute for field company
sig { returns(Company) }
attr_reader :company
# Attribute for field individual
sig { returns(Individual) }
attr_reader :individual
end
# The default currency for this country. This applies to both payment methods and bank accounts.
sig { returns(String) }
attr_reader :default_currency
# Unique identifier for the object. Represented as the ISO country code for this country.
sig { returns(String) }
attr_reader :id
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Currencies that can be accepted in the specific country (for transfers).
sig { returns(T::Hash[String, T::Array[String]]) }
attr_reader :supported_bank_account_currencies
# Currencies that can be accepted in the specified country (for payments).
sig { returns(T::Array[String]) }
attr_reader :supported_payment_currencies
# Payment methods available in the specified country. You may need to enable some payment methods (e.g., [ACH](https://stripe.com/docs/ach)) on your account before they appear in this list. The `stripe` payment method refers to [charging through your platform](https://stripe.com/docs/connect/destination-charges).
sig { returns(T::Array[String]) }
attr_reader :supported_payment_methods
# Countries that can accept transfers from the specified country.
sig { returns(T::Array[String]) }
attr_reader :supported_transfer_countries
# Attribute for field verification_fields
sig { returns(VerificationFields) }
attr_reader :verification_fields
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
# Lists all Country Spec objects available in the API.
sig {
params(params: T.any(::Stripe::CountrySpec::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
end
end
# typed: true
module Stripe
# A coupon contains information about a percent-off or amount-off discount you
# might want to apply to a customer. Coupons may be applied to [subscriptions](https://stripe.com/docs/api#subscriptions), [invoices](https://stripe.com/docs/api#invoices),
# [checkout sessions](https://stripe.com/docs/api/checkout/sessions), [quotes](https://stripe.com/docs/api#quotes), and more. Coupons do not work with conventional one-off [charges](https://stripe.com/docs/api#create_charge) or [payment intents](https://stripe.com/docs/api/payment_intents).
class Coupon < APIResource
class AppliesTo < Stripe::StripeObject
# A list of product IDs this coupon applies to
sig { returns(T::Array[String]) }
attr_reader :products
end
class CurrencyOptions < Stripe::StripeObject
# Amount (in the `currency` specified) that will be taken off the subtotal of any invoices for this customer.
sig { returns(Integer) }
attr_reader :amount_off
end
class Script < Stripe::StripeObject
# The configuration values of the script. The keys and values are specific to the script implementation.
sig { returns(T::Hash[String, T.untyped]) }
attr_reader :configuration
# The name of the script used to calculate the discount.
sig { returns(String) }
attr_reader :display_name
# The script implementation ID for this coupon.
sig { returns(String) }
attr_reader :id
end
# Amount (in the `currency` specified) that will be taken off the subtotal of any invoices for this customer.
sig { returns(T.nilable(Integer)) }
attr_reader :amount_off
# Attribute for field applies_to
sig { returns(AppliesTo) }
attr_reader :applies_to
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# If `amount_off` has been set, the three-letter [ISO code for the currency](https://stripe.com/docs/currencies) of the amount to take off.
sig { returns(T.nilable(String)) }
attr_reader :currency
# Coupons defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
sig { returns(T::Hash[String, CurrencyOptions]) }
attr_reader :currency_options
# One of `forever`, `once`, or `repeating`. Describes how long a customer who applies this coupon will get the discount.
sig { returns(String) }
attr_reader :duration
# If `duration` is `repeating`, the number of months the coupon applies. Null if coupon `duration` is `forever` or `once`.
sig { returns(T.nilable(Integer)) }
attr_reader :duration_in_months
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# Maximum number of times this coupon can be redeemed, in total, across all customers, before it is no longer valid.
sig { returns(T.nilable(Integer)) }
attr_reader :max_redemptions
# 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.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# Name of the coupon displayed to customers on for instance invoices or receipts.
sig { returns(T.nilable(String)) }
attr_reader :name
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Percent that will be taken off the subtotal of any invoices for this customer for the duration of the coupon. For example, a coupon with percent_off of 50 will make a $ (or local equivalent)100 invoice $ (or local equivalent)50 instead.
sig { returns(T.nilable(Float)) }
attr_reader :percent_off
# Date after which the coupon can no longer be redeemed.
sig { returns(T.nilable(Integer)) }
attr_reader :redeem_by
# Configuration of the [script](https://docs.stripe.com/billing/subscriptions/script-coupons) used to calculate the discount.
sig { returns(T.nilable(Script)) }
attr_reader :script
# Number of times this coupon has been applied to a customer.
sig { returns(Integer) }
attr_reader :times_redeemed
# One of `amount_off`, `percent_off`, or `script`. Describes the type of coupon logic used to calculate the discount.
sig { returns(T.nilable(String)) }
attr_reader :type
# Taking account of the above properties, whether this coupon can still be applied to a customer.
sig { returns(T::Boolean) }
attr_reader :valid
# Always true for a deleted object
sig { returns(T::Boolean) }
attr_reader :deleted
class DeleteParams < Stripe::RequestParams; end
class UpdateParams < Stripe::RequestParams
class CurrencyOptions < Stripe::RequestParams
# A positive integer representing the amount to subtract from an invoice total.
sig { returns(Integer) }
attr_accessor :amount_off
sig { params(amount_off: Integer).void }
def initialize(amount_off: nil); end
end
# Coupons defined in each available currency option (only supported if the coupon is amount-based). Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
sig { returns(T.nilable(T::Hash[String, ::Stripe::Coupon::UpdateParams::CurrencyOptions])) }
attr_accessor :currency_options
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Name of the coupon displayed to customers on, for instance invoices, or receipts. By default the `id` is shown if `name` is not set.
sig { returns(T.nilable(String)) }
attr_accessor :name
sig {
params(currency_options: T.nilable(T::Hash[String, ::Stripe::Coupon::UpdateParams::CurrencyOptions]), expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), name: T.nilable(String)).void
}
def initialize(currency_options: nil, expand: nil, metadata: nil, name: nil); end
end
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.
sig { returns(T.nilable(T.any(::Stripe::Coupon::ListParams::Created, Integer))) }
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(created: T.nilable(T.any(::Stripe::Coupon::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class AppliesTo < Stripe::RequestParams
# An array of Product IDs that this Coupon will apply to.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :products
sig { params(products: T.nilable(T::Array[String])).void }
def initialize(products: nil); end
end
class CurrencyOptions < Stripe::RequestParams
# A positive integer representing the amount to subtract from an invoice total.
sig { returns(Integer) }
attr_accessor :amount_off
sig { params(amount_off: Integer).void }
def initialize(amount_off: nil); end
end
class Script < Stripe::RequestParams
# The configuration values of the script. The keys and values are specific to the script implementation.
sig { returns(T::Hash[String, T.untyped]) }
attr_accessor :configuration
# The script implementation ID for this coupon.
sig { returns(String) }
attr_accessor :id
sig { params(configuration: T::Hash[String, T.untyped], id: String).void }
def initialize(configuration: nil, id: nil); end
end
# A positive integer representing the amount to subtract from an invoice total (required if `percent_off` is not passed).
sig { returns(T.nilable(Integer)) }
attr_accessor :amount_off
# A hash containing directions for what this Coupon will apply discounts to.
sig { returns(T.nilable(::Stripe::Coupon::CreateParams::AppliesTo)) }
attr_accessor :applies_to
# Three-letter [ISO code for the currency](https://stripe.com/docs/currencies) of the `amount_off` parameter (required if `amount_off` is passed).
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Coupons defined in each available currency option (only supported if `amount_off` is passed). Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
sig { returns(T.nilable(T::Hash[String, ::Stripe::Coupon::CreateParams::CurrencyOptions])) }
attr_accessor :currency_options
# Specifies how long the discount will be in effect if used on a subscription. Defaults to `once`.
sig { returns(T.nilable(String)) }
attr_accessor :duration
# Required only if `duration` is `repeating`, in which case it must be a positive integer that specifies the number of months the discount will be in effect.
sig { returns(T.nilable(Integer)) }
attr_accessor :duration_in_months
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Unique string of your choice that will be used to identify this coupon when applying it to a customer. If you don't want to specify a particular code, you can leave the ID blank and we'll generate a random code for you.
sig { returns(T.nilable(String)) }
attr_accessor :id
# A positive integer specifying the number of times the coupon can be redeemed before it's no longer valid. For example, you might have a 50% off coupon that the first 20 readers of your blog can use.
sig { returns(T.nilable(Integer)) }
attr_accessor :max_redemptions
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Name of the coupon displayed to customers on, for instance invoices, or receipts. By default the `id` is shown if `name` is not set.
sig { returns(T.nilable(String)) }
attr_accessor :name
# A positive float larger than 0, and smaller or equal to 100, that represents the discount the coupon will apply (required if `amount_off` is not passed).
sig { returns(T.nilable(Float)) }
attr_accessor :percent_off
# Unix timestamp specifying the last time at which the coupon can be redeemed. After the redeem_by date, the coupon can no longer be applied to new customers.
sig { returns(T.nilable(Integer)) }
attr_accessor :redeem_by
# Configuration of the [script](https://docs.stripe.com/billing/subscriptions/script-coupons) used to calculate the discount.
sig { returns(T.nilable(::Stripe::Coupon::CreateParams::Script)) }
attr_accessor :script
sig {
params(amount_off: T.nilable(Integer), applies_to: T.nilable(::Stripe::Coupon::CreateParams::AppliesTo), currency: T.nilable(String), currency_options: T.nilable(T::Hash[String, ::Stripe::Coupon::CreateParams::CurrencyOptions]), duration: T.nilable(String), duration_in_months: T.nilable(Integer), expand: T.nilable(T::Array[String]), id: T.nilable(String), max_redemptions: T.nilable(Integer), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), name: T.nilable(String), percent_off: T.nilable(Float), redeem_by: T.nilable(Integer), script: T.nilable(::Stripe::Coupon::CreateParams::Script)).void
}
def initialize(
amount_off: nil,
applies_to: nil,
currency: nil,
currency_options: nil,
duration: nil,
duration_in_months: nil,
expand: nil,
id: nil,
max_redemptions: nil,
metadata: nil,
name: nil,
percent_off: nil,
redeem_by: nil,
script: nil
); end
end
# You can create coupons easily via the [coupon management](https://dashboard.stripe.com/coupons) page of the Stripe dashboard. Coupon creation is also accessible via the API if you need to create coupons on the fly.
#
# A coupon has either a percent_off or an amount_off and currency. If you set an amount_off, that amount will be subtracted from any invoice's subtotal. For example, an invoice with a subtotal of 100 will have a final total of 0 if a coupon with an amount_off of 200 is applied to it and an invoice with a subtotal of 300 will have a final total of 100 if a coupon with an amount_off of 200 is applied to it.
sig {
params(params: T.any(::Stripe::Coupon::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Coupon)
}
def self.create(params = {}, opts = {}); end
# You can delete coupons via the [coupon management](https://dashboard.stripe.com/coupons) page of the Stripe dashboard. However, deleting a coupon does not affect any customers who have already applied the coupon; it means that new customers can't redeem the coupon. You can also delete coupons via the API.
sig {
params(coupon: String, params: T.any(::Stripe::Coupon::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Coupon)
}
def self.delete(coupon, params = {}, opts = {}); end
# You can delete coupons via the [coupon management](https://dashboard.stripe.com/coupons) page of the Stripe dashboard. However, deleting a coupon does not affect any customers who have already applied the coupon; it means that new customers can't redeem the coupon. You can also delete coupons via the API.
sig {
params(params: T.any(::Stripe::Coupon::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Coupon)
}
def delete(params = {}, opts = {}); end
# Returns a list of your coupons.
sig {
params(params: T.any(::Stripe::Coupon::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Updates the metadata of a coupon. Other coupon details (currency, duration, amount_off) are, by design, not editable.
sig {
params(coupon: String, params: T.any(::Stripe::Coupon::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Coupon)
}
def self.update(coupon, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
# Issue a credit note to adjust an invoice's amount after the invoice is finalized.
#
# Related guide: [Credit notes](https://stripe.com/docs/billing/invoices/credit-notes)
class CreditNote < APIResource
class DiscountAmount < Stripe::StripeObject
# The amount, in cents (or local equivalent), of the discount.
sig { returns(Integer) }
attr_reader :amount
# The discount that was applied to get this discount amount.
sig { returns(T.any(String, Stripe::Discount)) }
attr_reader :discount
end
class PretaxCreditAmount < Stripe::StripeObject
# The amount, in cents (or local equivalent), of the pretax credit amount.
sig { returns(Integer) }
attr_reader :amount
# The credit balance transaction that was applied to get this pretax credit amount.
sig { returns(T.any(String, Stripe::Billing::CreditBalanceTransaction)) }
attr_reader :credit_balance_transaction
# The discount that was applied to get this pretax credit amount.
sig { returns(T.any(String, Stripe::Discount)) }
attr_reader :discount
# Type of the pretax credit amount referenced.
sig { returns(String) }
attr_reader :type
end
class Refund < Stripe::StripeObject
# Amount of the refund that applies to this credit note, in cents (or local equivalent).
sig { returns(Integer) }
attr_reader :amount_refunded
# ID of the refund.
sig { returns(T.any(String, Stripe::Refund)) }
attr_reader :refund
end
class ShippingCost < Stripe::StripeObject
class Tax < Stripe::StripeObject
# Amount of tax applied for this rate.
sig { returns(Integer) }
attr_reader :amount
# Tax rates can be applied to [invoices](/invoicing/taxes/tax-rates), [subscriptions](/billing/taxes/tax-rates) and [Checkout Sessions](/payments/checkout/use-manual-tax-rates) to collect tax.
#
# Related guide: [Tax rates](/billing/taxes/tax-rates)
sig { returns(Stripe::TaxRate) }
attr_reader :rate
# 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.
sig { returns(T.nilable(String)) }
attr_reader :taxability_reason
# The amount on which tax is calculated, in cents (or local equivalent).
sig { returns(T.nilable(Integer)) }
attr_reader :taxable_amount
end
# Total shipping cost before any taxes are applied.
sig { returns(Integer) }
attr_reader :amount_subtotal
# Total tax amount applied due to shipping costs. If no tax was applied, defaults to 0.
sig { returns(Integer) }
attr_reader :amount_tax
# Total shipping cost after taxes are applied.
sig { returns(Integer) }
attr_reader :amount_total
# The ID of the ShippingRate for this invoice.
sig { returns(T.nilable(T.any(String, Stripe::ShippingRate))) }
attr_reader :shipping_rate
# The taxes applied to the shipping rate.
sig { returns(T::Array[Tax]) }
attr_reader :taxes
end
class TotalTax < Stripe::StripeObject
class TaxRateDetails < Stripe::StripeObject
# Attribute for field tax_rate
sig { returns(String) }
attr_reader :tax_rate
end
# The amount of the tax, in cents (or local equivalent).
sig { returns(Integer) }
attr_reader :amount
# Whether this tax is inclusive or exclusive.
sig { returns(String) }
attr_reader :tax_behavior
# Additional details about the tax rate. Only present when `type` is `tax_rate_details`.
sig { returns(T.nilable(TaxRateDetails)) }
attr_reader :tax_rate_details
# 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.
sig { returns(String) }
attr_reader :taxability_reason
# The amount on which tax is calculated, in cents (or local equivalent).
sig { returns(T.nilable(Integer)) }
attr_reader :taxable_amount
# The type of tax information.
sig { returns(String) }
attr_reader :type
end
# The integer amount in cents (or local equivalent) representing the total amount of the credit note, including tax.
sig { returns(Integer) }
attr_reader :amount
# This is the sum of all the shipping amounts.
sig { returns(Integer) }
attr_reader :amount_shipping
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# 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).
sig { returns(String) }
attr_reader :currency
# ID of the customer.
sig { returns(T.any(String, Stripe::Customer)) }
attr_reader :customer
# ID of the account.
sig { returns(T.nilable(String)) }
attr_reader :customer_account
# Customer balance transaction related to this credit note.
sig { returns(T.nilable(T.any(String, Stripe::CustomerBalanceTransaction))) }
attr_reader :customer_balance_transaction
# The integer amount in cents (or local equivalent) representing the total amount of discount that was credited.
sig { returns(Integer) }
attr_reader :discount_amount
# The aggregate amounts calculated per discount for all line items.
sig { returns(T::Array[DiscountAmount]) }
attr_reader :discount_amounts
# The date when this credit note is in effect. Same as `created` unless overwritten. When defined, this value replaces the system-generated 'Date of issue' printed on the credit note PDF.
sig { returns(T.nilable(Integer)) }
attr_reader :effective_at
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# ID of the invoice.
sig { returns(T.any(String, Stripe::Invoice)) }
attr_reader :invoice
# Line items that make up the credit note
sig { returns(Stripe::ListObject) }
attr_reader :lines
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# Customer-facing text that appears on the credit note PDF.
sig { returns(T.nilable(String)) }
attr_reader :memo
# 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.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# A unique number that identifies this particular credit note and appears on the PDF of the credit note and its associated invoice.
sig { returns(String) }
attr_reader :number
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Amount that was credited outside of Stripe.
sig { returns(T.nilable(Integer)) }
attr_reader :out_of_band_amount
# The link to download the PDF of the credit note.
sig { returns(String) }
attr_reader :pdf
# The amount of the credit note that was refunded to the customer, credited to the customer's balance, credited outside of Stripe, or any combination thereof.
sig { returns(Integer) }
attr_reader :post_payment_amount
# The amount of the credit note by which the invoice's `amount_remaining` and `amount_due` were reduced.
sig { returns(Integer) }
attr_reader :pre_payment_amount
# The pretax credit amounts (ex: discount, credit grants, etc) for all line items.
sig { returns(T::Array[PretaxCreditAmount]) }
attr_reader :pretax_credit_amounts
# Reason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory`
sig { returns(T.nilable(String)) }
attr_reader :reason
# Refunds related to this credit note.
sig { returns(T::Array[Refund]) }
attr_reader :refunds
# The details of the cost of shipping, including the ShippingRate applied to the invoice.
sig { returns(T.nilable(ShippingCost)) }
attr_reader :shipping_cost
# Status of this credit note, one of `issued` or `void`. Learn more about [voiding credit notes](https://stripe.com/docs/billing/invoices/credit-notes#voiding).
sig { returns(String) }
attr_reader :status
# The integer amount in cents (or local equivalent) representing the amount of the credit note, excluding exclusive tax and invoice level discounts.
sig { returns(Integer) }
attr_reader :subtotal
# The integer amount in cents (or local equivalent) representing the amount of the credit note, excluding all tax and invoice level discounts.
sig { returns(T.nilable(Integer)) }
attr_reader :subtotal_excluding_tax
# The integer amount in cents (or local equivalent) representing the total amount of the credit note, including tax and all discount.
sig { returns(Integer) }
attr_reader :total
# The integer amount in cents (or local equivalent) representing the total amount of the credit note, excluding tax, but including discounts.
sig { returns(T.nilable(Integer)) }
attr_reader :total_excluding_tax
# The aggregate tax information for all line items.
sig { returns(T.nilable(T::Array[TotalTax])) }
attr_reader :total_taxes
# Type of this credit note, one of `pre_payment` or `post_payment`. A `pre_payment` credit note means it was issued when the invoice was open. A `post_payment` credit note means it was issued when the invoice was paid.
sig { returns(String) }
attr_reader :type
# The time that the credit note was voided.
sig { returns(T.nilable(Integer)) }
attr_reader :voided_at
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return credit notes that were created during the given date interval.
sig { returns(T.nilable(T.any(::Stripe::CreditNote::ListParams::Created, Integer))) }
attr_accessor :created
# Only return credit notes for the customer specified by this customer ID.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# Only return credit notes for the account specified by this account ID.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Only return credit notes for the invoice specified by this invoice ID.
sig { returns(T.nilable(String)) }
attr_accessor :invoice
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(created: T.nilable(T.any(::Stripe::CreditNote::ListParams::Created, Integer)), customer: T.nilable(String), customer_account: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), invoice: T.nilable(String), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
created: nil,
customer: nil,
customer_account: nil,
ending_before: nil,
expand: nil,
invoice: nil,
limit: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class Line < Stripe::RequestParams
class TaxAmount < Stripe::RequestParams
# The amount, in cents (or local equivalent), of the tax.
sig { returns(Integer) }
attr_accessor :amount
# The id of the tax rate for this tax amount. The tax rate must have been automatically created by Stripe.
sig { returns(String) }
attr_accessor :tax_rate
# The amount on which tax is calculated, in cents (or local equivalent).
sig { returns(Integer) }
attr_accessor :taxable_amount
sig { params(amount: Integer, tax_rate: String, taxable_amount: Integer).void }
def initialize(amount: nil, tax_rate: nil, taxable_amount: nil); end
end
# The line item amount to credit. Only valid when `type` is `invoice_line_item`. If invoice is set up with `automatic_tax[enabled]=true`, this amount is tax exclusive
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# The description of the credit note line item. Only valid when the `type` is `custom_line_item`.
sig { returns(T.nilable(String)) }
attr_accessor :description
# The invoice line item to credit. Only valid when the `type` is `invoice_line_item`.
sig { returns(T.nilable(String)) }
attr_accessor :invoice_line_item
# The line item quantity to credit.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# A list of up to 10 tax amounts for the credit note line item. Cannot be mixed with `tax_rates`.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::CreditNote::CreateParams::Line::TaxAmount]))))
}
attr_accessor :tax_amounts
# The tax rates which apply to the credit note line item. Only valid when the `type` is `custom_line_item` and cannot be mixed with `tax_amounts`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
# Type of the credit note line item, one of `invoice_line_item` or `custom_line_item`
sig { returns(String) }
attr_accessor :type
# The integer unit amount in cents (or local equivalent) of the credit note line item. This `unit_amount` will be multiplied by the quantity to get the full amount to credit for this line item. Only valid when `type` is `custom_line_item`.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(amount: T.nilable(Integer), description: T.nilable(String), invoice_line_item: T.nilable(String), quantity: T.nilable(Integer), tax_amounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::CreditNote::CreateParams::Line::TaxAmount]))), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String]))), type: String, unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
amount: nil,
description: nil,
invoice_line_item: nil,
quantity: nil,
tax_amounts: nil,
tax_rates: nil,
type: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
class Refund < Stripe::RequestParams
# Amount of the refund that applies to this credit note, in cents (or local equivalent). Defaults to the entire refund amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount_refunded
# ID of an existing refund to link this credit note to.
sig { returns(T.nilable(String)) }
attr_accessor :refund
sig { params(amount_refunded: T.nilable(Integer), refund: T.nilable(String)).void }
def initialize(amount_refunded: nil, refund: nil); end
end
class ShippingCost < Stripe::RequestParams
# The ID of the shipping rate to use for this order.
sig { returns(T.nilable(String)) }
attr_accessor :shipping_rate
sig { params(shipping_rate: T.nilable(String)).void }
def initialize(shipping_rate: nil); end
end
# The integer amount in cents (or local equivalent) representing the total amount of the credit note.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# The integer amount in cents (or local equivalent) representing the amount to credit the customer's balance, which will be automatically applied to their next invoice.
sig { returns(T.nilable(Integer)) }
attr_accessor :credit_amount
# The date when this credit note is in effect. Same as `created` unless overwritten. When defined, this value replaces the system-generated 'Date of issue' printed on the credit note PDF.
sig { returns(T.nilable(Integer)) }
attr_accessor :effective_at
# Type of email to send to the customer, one of `credit_note` or `none` and the default is `credit_note`.
sig { returns(T.nilable(String)) }
attr_accessor :email_type
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# ID of the invoice.
sig { returns(String) }
attr_accessor :invoice
# Line items that make up the credit note.
sig { returns(T.nilable(T::Array[::Stripe::CreditNote::CreateParams::Line])) }
attr_accessor :lines
# The credit note's memo appears on the credit note PDF.
sig { returns(T.nilable(String)) }
attr_accessor :memo
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The integer amount in cents (or local equivalent) representing the amount that is credited outside of Stripe.
sig { returns(T.nilable(Integer)) }
attr_accessor :out_of_band_amount
# Reason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory`
sig { returns(T.nilable(String)) }
attr_accessor :reason
# The integer amount in cents (or local equivalent) representing the amount to refund. If set, a refund will be created for the charge associated with the invoice.
sig { returns(T.nilable(Integer)) }
attr_accessor :refund_amount
# Refunds to link to this credit note.
sig { returns(T.nilable(T::Array[::Stripe::CreditNote::CreateParams::Refund])) }
attr_accessor :refunds
# When shipping_cost contains the shipping_rate from the invoice, the shipping_cost is included in the credit note.
sig { returns(T.nilable(::Stripe::CreditNote::CreateParams::ShippingCost)) }
attr_accessor :shipping_cost
sig {
params(amount: T.nilable(Integer), credit_amount: T.nilable(Integer), effective_at: T.nilable(Integer), email_type: T.nilable(String), expand: T.nilable(T::Array[String]), invoice: String, lines: T.nilable(T::Array[::Stripe::CreditNote::CreateParams::Line]), memo: T.nilable(String), metadata: T.nilable(T::Hash[String, String]), out_of_band_amount: T.nilable(Integer), reason: T.nilable(String), refund_amount: T.nilable(Integer), refunds: T.nilable(T::Array[::Stripe::CreditNote::CreateParams::Refund]), shipping_cost: T.nilable(::Stripe::CreditNote::CreateParams::ShippingCost)).void
}
def initialize(
amount: nil,
credit_amount: nil,
effective_at: nil,
email_type: nil,
expand: nil,
invoice: nil,
lines: nil,
memo: nil,
metadata: nil,
out_of_band_amount: nil,
reason: nil,
refund_amount: nil,
refunds: nil,
shipping_cost: nil
); end
end
class UpdateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Credit note memo.
sig { returns(T.nilable(String)) }
attr_accessor :memo
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
sig {
params(expand: T.nilable(T::Array[String]), memo: T.nilable(String), metadata: T.nilable(T::Hash[String, String])).void
}
def initialize(expand: nil, memo: nil, metadata: nil); end
end
class PreviewParams < Stripe::RequestParams
class Line < Stripe::RequestParams
class TaxAmount < Stripe::RequestParams
# The amount, in cents (or local equivalent), of the tax.
sig { returns(Integer) }
attr_accessor :amount
# The id of the tax rate for this tax amount. The tax rate must have been automatically created by Stripe.
sig { returns(String) }
attr_accessor :tax_rate
# The amount on which tax is calculated, in cents (or local equivalent).
sig { returns(Integer) }
attr_accessor :taxable_amount
sig { params(amount: Integer, tax_rate: String, taxable_amount: Integer).void }
def initialize(amount: nil, tax_rate: nil, taxable_amount: nil); end
end
# The line item amount to credit. Only valid when `type` is `invoice_line_item`. If invoice is set up with `automatic_tax[enabled]=true`, this amount is tax exclusive
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# The description of the credit note line item. Only valid when the `type` is `custom_line_item`.
sig { returns(T.nilable(String)) }
attr_accessor :description
# The invoice line item to credit. Only valid when the `type` is `invoice_line_item`.
sig { returns(T.nilable(String)) }
attr_accessor :invoice_line_item
# The line item quantity to credit.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# A list of up to 10 tax amounts for the credit note line item. Cannot be mixed with `tax_rates`.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::CreditNote::PreviewParams::Line::TaxAmount]))))
}
attr_accessor :tax_amounts
# The tax rates which apply to the credit note line item. Only valid when the `type` is `custom_line_item` and cannot be mixed with `tax_amounts`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
# Type of the credit note line item, one of `invoice_line_item` or `custom_line_item`
sig { returns(String) }
attr_accessor :type
# The integer unit amount in cents (or local equivalent) of the credit note line item. This `unit_amount` will be multiplied by the quantity to get the full amount to credit for this line item. Only valid when `type` is `custom_line_item`.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(amount: T.nilable(Integer), description: T.nilable(String), invoice_line_item: T.nilable(String), quantity: T.nilable(Integer), tax_amounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::CreditNote::PreviewParams::Line::TaxAmount]))), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String]))), type: String, unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
amount: nil,
description: nil,
invoice_line_item: nil,
quantity: nil,
tax_amounts: nil,
tax_rates: nil,
type: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
class Refund < Stripe::RequestParams
# Amount of the refund that applies to this credit note, in cents (or local equivalent). Defaults to the entire refund amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount_refunded
# ID of an existing refund to link this credit note to.
sig { returns(T.nilable(String)) }
attr_accessor :refund
sig { params(amount_refunded: T.nilable(Integer), refund: T.nilable(String)).void }
def initialize(amount_refunded: nil, refund: nil); end
end
class ShippingCost < Stripe::RequestParams
# The ID of the shipping rate to use for this order.
sig { returns(T.nilable(String)) }
attr_accessor :shipping_rate
sig { params(shipping_rate: T.nilable(String)).void }
def initialize(shipping_rate: nil); end
end
# The integer amount in cents (or local equivalent) representing the total amount of the credit note.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# The integer amount in cents (or local equivalent) representing the amount to credit the customer's balance, which will be automatically applied to their next invoice.
sig { returns(T.nilable(Integer)) }
attr_accessor :credit_amount
# The date when this credit note is in effect. Same as `created` unless overwritten. When defined, this value replaces the system-generated 'Date of issue' printed on the credit note PDF.
sig { returns(T.nilable(Integer)) }
attr_accessor :effective_at
# Type of email to send to the customer, one of `credit_note` or `none` and the default is `credit_note`.
sig { returns(T.nilable(String)) }
attr_accessor :email_type
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# ID of the invoice.
sig { returns(String) }
attr_accessor :invoice
# Line items that make up the credit note.
sig { returns(T.nilable(T::Array[::Stripe::CreditNote::PreviewParams::Line])) }
attr_accessor :lines
# The credit note's memo appears on the credit note PDF.
sig { returns(T.nilable(String)) }
attr_accessor :memo
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The integer amount in cents (or local equivalent) representing the amount that is credited outside of Stripe.
sig { returns(T.nilable(Integer)) }
attr_accessor :out_of_band_amount
# Reason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory`
sig { returns(T.nilable(String)) }
attr_accessor :reason
# The integer amount in cents (or local equivalent) representing the amount to refund. If set, a refund will be created for the charge associated with the invoice.
sig { returns(T.nilable(Integer)) }
attr_accessor :refund_amount
# Refunds to link to this credit note.
sig { returns(T.nilable(T::Array[::Stripe::CreditNote::PreviewParams::Refund])) }
attr_accessor :refunds
# When shipping_cost contains the shipping_rate from the invoice, the shipping_cost is included in the credit note.
sig { returns(T.nilable(::Stripe::CreditNote::PreviewParams::ShippingCost)) }
attr_accessor :shipping_cost
sig {
params(amount: T.nilable(Integer), credit_amount: T.nilable(Integer), effective_at: T.nilable(Integer), email_type: T.nilable(String), expand: T.nilable(T::Array[String]), invoice: String, lines: T.nilable(T::Array[::Stripe::CreditNote::PreviewParams::Line]), memo: T.nilable(String), metadata: T.nilable(T::Hash[String, String]), out_of_band_amount: T.nilable(Integer), reason: T.nilable(String), refund_amount: T.nilable(Integer), refunds: T.nilable(T::Array[::Stripe::CreditNote::PreviewParams::Refund]), shipping_cost: T.nilable(::Stripe::CreditNote::PreviewParams::ShippingCost)).void
}
def initialize(
amount: nil,
credit_amount: nil,
effective_at: nil,
email_type: nil,
expand: nil,
invoice: nil,
lines: nil,
memo: nil,
metadata: nil,
out_of_band_amount: nil,
reason: nil,
refund_amount: nil,
refunds: nil,
shipping_cost: nil
); end
end
class ListPreviewLineItemsParams < Stripe::RequestParams
class Line < Stripe::RequestParams
class TaxAmount < Stripe::RequestParams
# The amount, in cents (or local equivalent), of the tax.
sig { returns(Integer) }
attr_accessor :amount
# The id of the tax rate for this tax amount. The tax rate must have been automatically created by Stripe.
sig { returns(String) }
attr_accessor :tax_rate
# The amount on which tax is calculated, in cents (or local equivalent).
sig { returns(Integer) }
attr_accessor :taxable_amount
sig { params(amount: Integer, tax_rate: String, taxable_amount: Integer).void }
def initialize(amount: nil, tax_rate: nil, taxable_amount: nil); end
end
# The line item amount to credit. Only valid when `type` is `invoice_line_item`. If invoice is set up with `automatic_tax[enabled]=true`, this amount is tax exclusive
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# The description of the credit note line item. Only valid when the `type` is `custom_line_item`.
sig { returns(T.nilable(String)) }
attr_accessor :description
# The invoice line item to credit. Only valid when the `type` is `invoice_line_item`.
sig { returns(T.nilable(String)) }
attr_accessor :invoice_line_item
# The line item quantity to credit.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# A list of up to 10 tax amounts for the credit note line item. Cannot be mixed with `tax_rates`.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::CreditNote::ListPreviewLineItemsParams::Line::TaxAmount]))))
}
attr_accessor :tax_amounts
# The tax rates which apply to the credit note line item. Only valid when the `type` is `custom_line_item` and cannot be mixed with `tax_amounts`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
# Type of the credit note line item, one of `invoice_line_item` or `custom_line_item`
sig { returns(String) }
attr_accessor :type
# The integer unit amount in cents (or local equivalent) of the credit note line item. This `unit_amount` will be multiplied by the quantity to get the full amount to credit for this line item. Only valid when `type` is `custom_line_item`.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(amount: T.nilable(Integer), description: T.nilable(String), invoice_line_item: T.nilable(String), quantity: T.nilable(Integer), tax_amounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::CreditNote::ListPreviewLineItemsParams::Line::TaxAmount]))), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String]))), type: String, unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
amount: nil,
description: nil,
invoice_line_item: nil,
quantity: nil,
tax_amounts: nil,
tax_rates: nil,
type: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
class Refund < Stripe::RequestParams
# Amount of the refund that applies to this credit note, in cents (or local equivalent). Defaults to the entire refund amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount_refunded
# ID of an existing refund to link this credit note to.
sig { returns(T.nilable(String)) }
attr_accessor :refund
sig { params(amount_refunded: T.nilable(Integer), refund: T.nilable(String)).void }
def initialize(amount_refunded: nil, refund: nil); end
end
class ShippingCost < Stripe::RequestParams
# The ID of the shipping rate to use for this order.
sig { returns(T.nilable(String)) }
attr_accessor :shipping_rate
sig { params(shipping_rate: T.nilable(String)).void }
def initialize(shipping_rate: nil); end
end
# The integer amount in cents (or local equivalent) representing the total amount of the credit note.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# The integer amount in cents (or local equivalent) representing the amount to credit the customer's balance, which will be automatically applied to their next invoice.
sig { returns(T.nilable(Integer)) }
attr_accessor :credit_amount
# The date when this credit note is in effect. Same as `created` unless overwritten. When defined, this value replaces the system-generated 'Date of issue' printed on the credit note PDF.
sig { returns(T.nilable(Integer)) }
attr_accessor :effective_at
# Type of email to send to the customer, one of `credit_note` or `none` and the default is `credit_note`.
sig { returns(T.nilable(String)) }
attr_accessor :email_type
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# ID of the invoice.
sig { returns(String) }
attr_accessor :invoice
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Line items that make up the credit note.
sig { returns(T.nilable(T::Array[::Stripe::CreditNote::ListPreviewLineItemsParams::Line])) }
attr_accessor :lines
# The credit note's memo appears on the credit note PDF.
sig { returns(T.nilable(String)) }
attr_accessor :memo
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The integer amount in cents (or local equivalent) representing the amount that is credited outside of Stripe.
sig { returns(T.nilable(Integer)) }
attr_accessor :out_of_band_amount
# Reason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory`
sig { returns(T.nilable(String)) }
attr_accessor :reason
# The integer amount in cents (or local equivalent) representing the amount to refund. If set, a refund will be created for the charge associated with the invoice.
sig { returns(T.nilable(Integer)) }
attr_accessor :refund_amount
# Refunds to link to this credit note.
sig { returns(T.nilable(T::Array[::Stripe::CreditNote::ListPreviewLineItemsParams::Refund])) }
attr_accessor :refunds
# When shipping_cost contains the shipping_rate from the invoice, the shipping_cost is included in the credit note.
sig { returns(T.nilable(::Stripe::CreditNote::ListPreviewLineItemsParams::ShippingCost)) }
attr_accessor :shipping_cost
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(amount: T.nilable(Integer), credit_amount: T.nilable(Integer), effective_at: T.nilable(Integer), email_type: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), invoice: String, limit: T.nilable(Integer), lines: T.nilable(T::Array[::Stripe::CreditNote::ListPreviewLineItemsParams::Line]), memo: T.nilable(String), metadata: T.nilable(T::Hash[String, String]), out_of_band_amount: T.nilable(Integer), reason: T.nilable(String), refund_amount: T.nilable(Integer), refunds: T.nilable(T::Array[::Stripe::CreditNote::ListPreviewLineItemsParams::Refund]), shipping_cost: T.nilable(::Stripe::CreditNote::ListPreviewLineItemsParams::ShippingCost), starting_after: T.nilable(String)).void
}
def initialize(
amount: nil,
credit_amount: nil,
effective_at: nil,
email_type: nil,
ending_before: nil,
expand: nil,
invoice: nil,
limit: nil,
lines: nil,
memo: nil,
metadata: nil,
out_of_band_amount: nil,
reason: nil,
refund_amount: nil,
refunds: nil,
shipping_cost: nil,
starting_after: nil
); end
end
class VoidCreditNoteParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Issue a credit note to adjust the amount of a finalized invoice. A credit note will first reduce the invoice's amount_remaining (and amount_due), but not below zero.
# This amount is indicated by the credit note's pre_payment_amount. The excess amount is indicated by post_payment_amount, and it can result in any combination of the following:
#
#
# Refunds: create a new refund (using refund_amount) or link existing refunds (using refunds).
# Customer balance credit: credit the customer's balance (using credit_amount) which will be automatically applied to their next invoice when it's finalized.
# Outside of Stripe credit: record the amount that is or will be credited outside of Stripe (using out_of_band_amount).
#
#
# The sum of refunds, customer balance credits, and outside of Stripe credits must equal the post_payment_amount.
#
# You may issue multiple credit notes for an invoice. Each credit note may increment the invoice's pre_payment_credit_notes_amount,
# post_payment_credit_notes_amount, or both, depending on the invoice's amount_remaining at the time of credit note creation.
sig {
params(params: T.any(::Stripe::CreditNote::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::CreditNote)
}
def self.create(params = {}, opts = {}); end
# Returns a list of credit notes.
sig {
params(params: T.any(::Stripe::CreditNote::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# When retrieving a credit note preview, you'll get a lines property containing the first handful of those items. This URL you can retrieve the full (paginated) list of line items.
sig {
params(params: T.any(::Stripe::CreditNote::ListPreviewLineItemsParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list_preview_line_items(params = {}, opts = {}); end
# Get a preview of a credit note without creating it.
sig {
params(params: T.any(::Stripe::CreditNote::PreviewParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::CreditNote)
}
def self.preview(params = {}, opts = {}); end
# Updates an existing credit note.
sig {
params(id: String, params: T.any(::Stripe::CreditNote::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::CreditNote)
}
def self.update(id, params = {}, opts = {}); end
# Marks a credit note as void. Learn more about [voiding credit notes](https://docs.stripe.com/docs/billing/invoices/credit-notes#voiding).
sig {
params(params: T.any(::Stripe::CreditNote::VoidCreditNoteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::CreditNote)
}
def void_credit_note(params = {}, opts = {}); end
# Marks a credit note as void. Learn more about [voiding credit notes](https://docs.stripe.com/docs/billing/invoices/credit-notes#voiding).
sig {
params(id: String, params: T.any(::Stripe::CreditNote::VoidCreditNoteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::CreditNote)
}
def self.void_credit_note(id, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
# The credit note line item object
class CreditNoteLineItem < StripeObject
class DiscountAmount < Stripe::StripeObject
# The amount, in cents (or local equivalent), of the discount.
sig { returns(Integer) }
attr_reader :amount
# The discount that was applied to get this discount amount.
sig { returns(T.any(String, Stripe::Discount)) }
attr_reader :discount
end
class PretaxCreditAmount < Stripe::StripeObject
# The amount, in cents (or local equivalent), of the pretax credit amount.
sig { returns(Integer) }
attr_reader :amount
# The credit balance transaction that was applied to get this pretax credit amount.
sig { returns(T.any(String, Stripe::Billing::CreditBalanceTransaction)) }
attr_reader :credit_balance_transaction
# The discount that was applied to get this pretax credit amount.
sig { returns(T.any(String, Stripe::Discount)) }
attr_reader :discount
# Type of the pretax credit amount referenced.
sig { returns(String) }
attr_reader :type
end
class TaxCalculationReference < Stripe::StripeObject
# The calculation identifier for tax calculation response.
sig { returns(T.nilable(String)) }
attr_reader :calculation_id
# The calculation identifier for tax calculation response line item.
sig { returns(T.nilable(String)) }
attr_reader :calculation_item_id
end
class Tax < Stripe::StripeObject
class TaxRateDetails < Stripe::StripeObject
# Attribute for field tax_rate
sig { returns(String) }
attr_reader :tax_rate
end
# The amount of the tax, in cents (or local equivalent).
sig { returns(Integer) }
attr_reader :amount
# Whether this tax is inclusive or exclusive.
sig { returns(String) }
attr_reader :tax_behavior
# Additional details about the tax rate. Only present when `type` is `tax_rate_details`.
sig { returns(T.nilable(TaxRateDetails)) }
attr_reader :tax_rate_details
# 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.
sig { returns(String) }
attr_reader :taxability_reason
# The amount on which tax is calculated, in cents (or local equivalent).
sig { returns(T.nilable(Integer)) }
attr_reader :taxable_amount
# The type of tax information.
sig { returns(String) }
attr_reader :type
end
# The integer amount in cents (or local equivalent) representing the gross amount being credited for this line item, excluding (exclusive) tax and discounts.
sig { returns(Integer) }
attr_reader :amount
# Description of the item being credited.
sig { returns(T.nilable(String)) }
attr_reader :description
# The integer amount in cents (or local equivalent) representing the discount being credited for this line item.
sig { returns(Integer) }
attr_reader :discount_amount
# The amount of discount calculated per discount for this line item
sig { returns(T::Array[DiscountAmount]) }
attr_reader :discount_amounts
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# ID of the invoice line item being credited
sig { returns(String) }
attr_reader :invoice_line_item
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The pretax credit amounts (ex: discount, credit grants, etc) for this line item.
sig { returns(T::Array[PretaxCreditAmount]) }
attr_reader :pretax_credit_amounts
# The number of units of product being credited.
sig { returns(T.nilable(Integer)) }
attr_reader :quantity
# The tax calculation identifiers of the line item.
sig { returns(T.nilable(TaxCalculationReference)) }
attr_reader :tax_calculation_reference
# The tax rates which apply to the line item.
sig { returns(T::Array[Stripe::TaxRate]) }
attr_reader :tax_rates
# The tax information of the line item.
sig { returns(T.nilable(T::Array[Tax])) }
attr_reader :taxes
# The type of the credit note line item, one of `invoice_line_item` or `custom_line_item`. When the type is `invoice_line_item` there is an additional `invoice_line_item` property on the resource the value of which is the id of the credited line item on the invoice.
sig { returns(String) }
attr_reader :type
# The cost of each unit of product being credited.
sig { returns(T.nilable(Integer)) }
attr_reader :unit_amount
# Same as `unit_amount`, but contains a decimal value with at most 12 decimal places.
sig { returns(T.nilable(String)) }
attr_reader :unit_amount_decimal
end
end
# typed: true
module Stripe
# This object represents a customer of your business. Use it to [create recurring charges](https://stripe.com/docs/invoicing/customer), [save payment](https://stripe.com/docs/payments/save-during-payment) and contact information,
# and track payments that belong to the same customer.
class Customer < APIResource
class Address < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
class InvoiceSettings < Stripe::StripeObject
class CustomField < Stripe::StripeObject
# The name of the custom field.
sig { returns(String) }
attr_reader :name
# The value of the custom field.
sig { returns(String) }
attr_reader :value
end
class RenderingOptions < Stripe::StripeObject
# How line-item prices and amounts will be displayed with respect to tax on invoice PDFs.
sig { returns(T.nilable(String)) }
attr_reader :amount_tax_display
# ID of the invoice rendering template to be used for this customer's invoices. If set, the template will be used on all invoices for this customer unless a template is set directly on the invoice.
sig { returns(T.nilable(String)) }
attr_reader :template
end
# Default custom fields to be displayed on invoices for this customer.
sig { returns(T.nilable(T::Array[CustomField])) }
attr_reader :custom_fields
# ID of a payment method that's attached to the customer, to be used as the customer's default payment method for subscriptions and invoices.
sig { returns(T.nilable(T.any(String, Stripe::PaymentMethod))) }
attr_reader :default_payment_method
# Default footer to be displayed on invoices for this customer.
sig { returns(T.nilable(String)) }
attr_reader :footer
# Default options for invoice PDF rendering for this customer.
sig { returns(T.nilable(RenderingOptions)) }
attr_reader :rendering_options
end
class Shipping < Stripe::StripeObject
class Address < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Attribute for field address
sig { returns(Address) }
attr_reader :address
# The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
sig { returns(T.nilable(String)) }
attr_reader :carrier
# Recipient name.
sig { returns(String) }
attr_reader :name
# Recipient phone (including extension).
sig { returns(T.nilable(String)) }
attr_reader :phone
# The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
sig { returns(T.nilable(String)) }
attr_reader :tracking_number
end
class Tax < Stripe::StripeObject
class Location < Stripe::StripeObject
# The identified tax country of the customer.
sig { returns(String) }
attr_reader :country
# The data source used to infer the customer's location.
sig { returns(String) }
attr_reader :source
# The identified tax state, county, province, or region of the customer.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Surfaces if automatic tax computation is possible given the current customer location information.
sig { returns(String) }
attr_reader :automatic_tax
# A recent IP address of the customer used for tax reporting and tax location inference.
sig { returns(T.nilable(String)) }
attr_reader :ip_address
# The identified tax location of the customer.
sig { returns(T.nilable(Location)) }
attr_reader :location
end
# The customer's address.
sig { returns(T.nilable(Address)) }
attr_reader :address
# The current balance, if any, that's stored on the customer. If negative, the customer has credit to apply to their next invoice. If positive, the customer has an amount owed that's added to their next invoice. The balance only considers amounts that Stripe hasn't successfully applied to any invoice. It doesn't reflect unpaid invoices. This balance is only taken into account after invoices finalize.
sig { returns(Integer) }
attr_reader :balance
# The current funds being held by Stripe on behalf of the customer. You can apply these funds towards payment intents when the source is "cash_balance". The `settings[reconciliation_mode]` field describes if these funds apply to these payment intents manually or automatically.
sig { returns(T.nilable(Stripe::CashBalance)) }
attr_reader :cash_balance
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# Three-letter [ISO code for the currency](https://stripe.com/docs/currencies) the customer can be charged in for recurring billing purposes.
sig { returns(T.nilable(String)) }
attr_reader :currency
# Attribute for field customer_account
sig { returns(T.nilable(String)) }
attr_reader :customer_account
# ID of the default payment source for the customer.
#
# If you use payment methods created through the PaymentMethods API, see the [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) field instead.
sig {
returns(T.nilable(T.any(String, T.any(Stripe::Account, Stripe::BankAccount, Stripe::Card, Stripe::Source))))
}
attr_reader :default_source
# Tracks the most recent state change on any invoice belonging to the customer. Paying an invoice or marking it uncollectible via the API will set this field to false. An automatic payment failure or passing the `invoice.due_date` will set this field to `true`.
#
# If an invoice becomes uncollectible by [dunning](https://stripe.com/docs/billing/automatic-collection), `delinquent` doesn't reset to `false`.
#
# If you care whether the customer has paid their most recent subscription invoice, use `subscription.status` instead. Paying or marking uncollectible any customer invoice regardless of whether it is the latest invoice for a subscription will always set this field to `false`.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :delinquent
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_reader :description
# Describes the current discount active on the customer, if there is one.
sig { returns(T.nilable(Stripe::Discount)) }
attr_reader :discount
# The customer's email address.
sig { returns(T.nilable(String)) }
attr_reader :email
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# The current multi-currency balances, if any, that's stored on the customer. If positive in a currency, the customer has a credit to apply to their next invoice denominated in that currency. If negative, the customer has an amount owed that's added to their next invoice denominated in that currency. These balances don't apply to unpaid invoices. They solely track amounts that Stripe hasn't successfully applied to any invoice. Stripe only applies a balance in a specific currency to an invoice after that invoice (which is in the same currency) finalizes.
sig { returns(T::Hash[String, Integer]) }
attr_reader :invoice_credit_balance
# The prefix for the customer used to generate unique invoice numbers.
sig { returns(T.nilable(String)) }
attr_reader :invoice_prefix
# Attribute for field invoice_settings
sig { returns(InvoiceSettings) }
attr_reader :invoice_settings
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# 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.
sig { returns(T::Hash[String, String]) }
attr_reader :metadata
# The customer's full name or business name.
sig { returns(T.nilable(String)) }
attr_reader :name
# The suffix of the customer's next invoice number (for example, 0001). When the account uses account level sequencing, this parameter is ignored in API requests and the field omitted in API responses.
sig { returns(Integer) }
attr_reader :next_invoice_sequence
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The customer's phone number.
sig { returns(T.nilable(String)) }
attr_reader :phone
# The customer's preferred locales (languages), ordered by preference.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :preferred_locales
# Mailing and shipping address for the customer. Appears on invoices emailed to this customer.
sig { returns(T.nilable(Shipping)) }
attr_reader :shipping
# The customer's payment sources, if any.
sig { returns(Stripe::ListObject) }
attr_reader :sources
# The customer's current subscriptions, if any.
sig { returns(Stripe::ListObject) }
attr_reader :subscriptions
# Attribute for field tax
sig { returns(Tax) }
attr_reader :tax
# Describes the customer's tax exemption status, which is `none`, `exempt`, or `reverse`. When set to `reverse`, invoice and receipt PDFs include the following text: **"Reverse charge"**.
sig { returns(T.nilable(String)) }
attr_reader :tax_exempt
# The customer's tax IDs.
sig { returns(Stripe::ListObject) }
attr_reader :tax_ids
# ID of the test clock that this customer belongs to.
sig { returns(T.nilable(T.any(String, Stripe::TestHelpers::TestClock))) }
attr_reader :test_clock
# Always true for a deleted object
sig { returns(T::Boolean) }
attr_reader :deleted
class DeleteParams < Stripe::RequestParams; end
class UpdateParams < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# A freeform text field for the country. However, in order to activate some tax features, the format should be a two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class CashBalance < Stripe::RequestParams
class Settings < Stripe::RequestParams
# Controls how funds transferred by the customer are applied to payment intents and invoices. Valid options are `automatic`, `manual`, or `merchant_default`. For more information about these reconciliation modes, see [Reconciliation](https://stripe.com/docs/payments/customer-balance/reconciliation).
sig { returns(T.nilable(String)) }
attr_accessor :reconciliation_mode
sig { params(reconciliation_mode: T.nilable(String)).void }
def initialize(reconciliation_mode: nil); end
end
# Settings controlling the behavior of the customer's cash balance,
# such as reconciliation of funds received.
sig { returns(T.nilable(::Stripe::Customer::UpdateParams::CashBalance::Settings)) }
attr_accessor :settings
sig {
params(settings: T.nilable(::Stripe::Customer::UpdateParams::CashBalance::Settings)).void
}
def initialize(settings: nil); end
end
class InvoiceSettings < Stripe::RequestParams
class CustomField < Stripe::RequestParams
# The name of the custom field. This may be up to 40 characters.
sig { returns(String) }
attr_accessor :name
# The value of the custom field. This may be up to 140 characters.
sig { returns(String) }
attr_accessor :value
sig { params(name: String, value: String).void }
def initialize(name: nil, value: nil); end
end
class RenderingOptions < Stripe::RequestParams
# How line-item prices and amounts will be displayed with respect to tax on invoice PDFs. One of `exclude_tax` or `include_inclusive_tax`. `include_inclusive_tax` will include inclusive tax (and exclude exclusive tax) in invoice PDF amounts. `exclude_tax` will exclude all tax (inclusive and exclusive alike) from invoice PDF amounts.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :amount_tax_display
# ID of the invoice rendering template to use for future invoices.
sig { returns(T.nilable(String)) }
attr_accessor :template
sig {
params(amount_tax_display: T.nilable(T.nilable(T.any(String, String))), template: T.nilable(String)).void
}
def initialize(amount_tax_display: nil, template: nil); end
end
# The list of up to 4 default custom fields to be displayed on invoices for this customer. When updating, pass an empty string to remove previously-defined fields.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Customer::UpdateParams::InvoiceSettings::CustomField]))))
}
attr_accessor :custom_fields
# ID of a payment method that's attached to the customer, to be used as the customer's default payment method for subscriptions and invoices.
sig { returns(T.nilable(String)) }
attr_accessor :default_payment_method
# Default footer to be displayed on invoices for this customer.
sig { returns(T.nilable(String)) }
attr_accessor :footer
# Default options for invoice PDF rendering for this customer.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Customer::UpdateParams::InvoiceSettings::RenderingOptions))))
}
attr_accessor :rendering_options
sig {
params(custom_fields: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Customer::UpdateParams::InvoiceSettings::CustomField]))), default_payment_method: T.nilable(String), footer: T.nilable(String), rendering_options: T.nilable(T.nilable(T.any(String, ::Stripe::Customer::UpdateParams::InvoiceSettings::RenderingOptions)))).void
}
def initialize(
custom_fields: nil,
default_payment_method: nil,
footer: nil,
rendering_options: nil
); end
end
class Shipping < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# A freeform text field for the country. However, in order to activate some tax features, the format should be a two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Customer shipping address.
sig { returns(::Stripe::Customer::UpdateParams::Shipping::Address) }
attr_accessor :address
# Customer name.
sig { returns(String) }
attr_accessor :name
# Customer phone (including extension).
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(address: ::Stripe::Customer::UpdateParams::Shipping::Address, name: String, phone: T.nilable(String)).void
}
def initialize(address: nil, name: nil, phone: nil); end
end
class Tax < Stripe::RequestParams
# 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.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :ip_address
# A flag that indicates when Stripe should validate the customer tax location. Defaults to `auto`.
sig { returns(T.nilable(String)) }
attr_accessor :validate_location
sig {
params(ip_address: T.nilable(T.nilable(String)), validate_location: T.nilable(String)).void
}
def initialize(ip_address: nil, validate_location: nil); end
end
# The customer's address.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Customer::UpdateParams::Address))))
}
attr_accessor :address
# An integer amount in cents (or local equivalent) that represents the customer's current balance, which affect the customer's future invoices. A negative amount represents a credit that decreases the amount due on an invoice; a positive amount increases the amount due on an invoice.
sig { returns(T.nilable(Integer)) }
attr_accessor :balance
# Balance information and default balance settings for this customer.
sig { returns(T.nilable(::Stripe::Customer::UpdateParams::CashBalance)) }
attr_accessor :cash_balance
# If you are using payment methods created via the PaymentMethods API, see the [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/update#update_customer-invoice_settings-default_payment_method) parameter.
#
# Provide the ID of a payment source already attached to this customer to make it this customer's default payment source.
#
# If you want to add a new payment source and make it the default, see the [source](https://stripe.com/docs/api/customers/update#update_customer-source) property.
sig { returns(T.nilable(String)) }
attr_accessor :default_source
# An arbitrary string that you can attach to a customer object. It is displayed alongside the customer in the dashboard.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Customer's email address. It's displayed alongside the customer in your dashboard and can be useful for searching and tracking. This may be up to *512 characters*.
sig { returns(T.nilable(String)) }
attr_accessor :email
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The prefix for the customer used to generate unique invoice numbers. Must be 3–12 uppercase letters or numbers.
sig { returns(T.nilable(String)) }
attr_accessor :invoice_prefix
# Default invoice settings for this customer.
sig { returns(T.nilable(::Stripe::Customer::UpdateParams::InvoiceSettings)) }
attr_accessor :invoice_settings
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# The customer's full name or business name.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The sequence to be used on the customer's next invoice. Defaults to 1.
sig { returns(T.nilable(Integer)) }
attr_accessor :next_invoice_sequence
# The customer's phone number.
sig { returns(T.nilable(String)) }
attr_accessor :phone
# Customer's preferred languages, ordered by preference.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :preferred_locales
# The customer's shipping information. Appears on invoices emailed to this customer.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Customer::UpdateParams::Shipping))))
}
attr_accessor :shipping
# Attribute for param field source
sig { returns(T.nilable(String)) }
attr_accessor :source
# Tax details about the customer.
sig { returns(T.nilable(::Stripe::Customer::UpdateParams::Tax)) }
attr_accessor :tax
# The customer's tax exemption. One of `none`, `exempt`, or `reverse`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :tax_exempt
# Attribute for param field validate
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :validate
sig {
params(address: T.nilable(T.nilable(T.any(String, ::Stripe::Customer::UpdateParams::Address))), balance: T.nilable(Integer), cash_balance: T.nilable(::Stripe::Customer::UpdateParams::CashBalance), default_source: T.nilable(String), description: T.nilable(String), email: T.nilable(String), expand: T.nilable(T::Array[String]), invoice_prefix: T.nilable(String), invoice_settings: T.nilable(::Stripe::Customer::UpdateParams::InvoiceSettings), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), name: T.nilable(String), next_invoice_sequence: T.nilable(Integer), phone: T.nilable(String), preferred_locales: T.nilable(T::Array[String]), shipping: T.nilable(T.nilable(T.any(String, ::Stripe::Customer::UpdateParams::Shipping))), source: T.nilable(String), tax: T.nilable(::Stripe::Customer::UpdateParams::Tax), tax_exempt: T.nilable(T.nilable(T.any(String, String))), validate: T.nilable(T::Boolean)).void
}
def initialize(
address: nil,
balance: nil,
cash_balance: nil,
default_source: nil,
description: nil,
email: nil,
expand: nil,
invoice_prefix: nil,
invoice_settings: nil,
metadata: nil,
name: nil,
next_invoice_sequence: nil,
phone: nil,
preferred_locales: nil,
shipping: nil,
source: nil,
tax: nil,
tax_exempt: nil,
validate: nil
); end
end
class DeleteDiscountParams < Stripe::RequestParams; end
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return customers that were created during the given date interval.
sig { returns(T.nilable(T.any(::Stripe::Customer::ListParams::Created, Integer))) }
attr_accessor :created
# A case-sensitive filter on the list based on the customer's `email` field. The value must be a string.
sig { returns(T.nilable(String)) }
attr_accessor :email
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Provides a list of customers that are associated with the specified test clock. The response will not include customers with test clocks if this parameter is not set.
sig { returns(T.nilable(String)) }
attr_accessor :test_clock
sig {
params(created: T.nilable(T.any(::Stripe::Customer::ListParams::Created, Integer)), email: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String), test_clock: T.nilable(String)).void
}
def initialize(
created: nil,
email: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil,
test_clock: nil
); end
end
class CreateParams < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# A freeform text field for the country. However, in order to activate some tax features, the format should be a two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class CashBalance < Stripe::RequestParams
class Settings < Stripe::RequestParams
# Controls how funds transferred by the customer are applied to payment intents and invoices. Valid options are `automatic`, `manual`, or `merchant_default`. For more information about these reconciliation modes, see [Reconciliation](https://stripe.com/docs/payments/customer-balance/reconciliation).
sig { returns(T.nilable(String)) }
attr_accessor :reconciliation_mode
sig { params(reconciliation_mode: T.nilable(String)).void }
def initialize(reconciliation_mode: nil); end
end
# Settings controlling the behavior of the customer's cash balance,
# such as reconciliation of funds received.
sig { returns(T.nilable(::Stripe::Customer::CreateParams::CashBalance::Settings)) }
attr_accessor :settings
sig {
params(settings: T.nilable(::Stripe::Customer::CreateParams::CashBalance::Settings)).void
}
def initialize(settings: nil); end
end
class InvoiceSettings < Stripe::RequestParams
class CustomField < Stripe::RequestParams
# The name of the custom field. This may be up to 40 characters.
sig { returns(String) }
attr_accessor :name
# The value of the custom field. This may be up to 140 characters.
sig { returns(String) }
attr_accessor :value
sig { params(name: String, value: String).void }
def initialize(name: nil, value: nil); end
end
class RenderingOptions < Stripe::RequestParams
# How line-item prices and amounts will be displayed with respect to tax on invoice PDFs. One of `exclude_tax` or `include_inclusive_tax`. `include_inclusive_tax` will include inclusive tax (and exclude exclusive tax) in invoice PDF amounts. `exclude_tax` will exclude all tax (inclusive and exclusive alike) from invoice PDF amounts.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :amount_tax_display
# ID of the invoice rendering template to use for future invoices.
sig { returns(T.nilable(String)) }
attr_accessor :template
sig {
params(amount_tax_display: T.nilable(T.nilable(T.any(String, String))), template: T.nilable(String)).void
}
def initialize(amount_tax_display: nil, template: nil); end
end
# The list of up to 4 default custom fields to be displayed on invoices for this customer. When updating, pass an empty string to remove previously-defined fields.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Customer::CreateParams::InvoiceSettings::CustomField]))))
}
attr_accessor :custom_fields
# ID of a payment method that's attached to the customer, to be used as the customer's default payment method for subscriptions and invoices.
sig { returns(T.nilable(String)) }
attr_accessor :default_payment_method
# Default footer to be displayed on invoices for this customer.
sig { returns(T.nilable(String)) }
attr_accessor :footer
# Default options for invoice PDF rendering for this customer.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Customer::CreateParams::InvoiceSettings::RenderingOptions))))
}
attr_accessor :rendering_options
sig {
params(custom_fields: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Customer::CreateParams::InvoiceSettings::CustomField]))), default_payment_method: T.nilable(String), footer: T.nilable(String), rendering_options: T.nilable(T.nilable(T.any(String, ::Stripe::Customer::CreateParams::InvoiceSettings::RenderingOptions)))).void
}
def initialize(
custom_fields: nil,
default_payment_method: nil,
footer: nil,
rendering_options: nil
); end
end
class Shipping < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# A freeform text field for the country. However, in order to activate some tax features, the format should be a two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Customer shipping address.
sig { returns(::Stripe::Customer::CreateParams::Shipping::Address) }
attr_accessor :address
# Customer name.
sig { returns(String) }
attr_accessor :name
# Customer phone (including extension).
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(address: ::Stripe::Customer::CreateParams::Shipping::Address, name: String, phone: T.nilable(String)).void
}
def initialize(address: nil, name: nil, phone: nil); end
end
class Tax < Stripe::RequestParams
# 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.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :ip_address
# A flag that indicates when Stripe should validate the customer tax location. Defaults to `deferred`.
sig { returns(T.nilable(String)) }
attr_accessor :validate_location
sig {
params(ip_address: T.nilable(T.nilable(String)), validate_location: T.nilable(String)).void
}
def initialize(ip_address: nil, validate_location: nil); end
end
class TaxIdDatum < Stripe::RequestParams
# Type of the tax ID, one of `ad_nrt`, `ae_trn`, `al_tin`, `am_tin`, `ao_tin`, `ar_cuit`, `au_abn`, `au_arn`, `aw_tin`, `az_tin`, `ba_tin`, `bb_tin`, `bd_bin`, `bf_ifu`, `bg_uic`, `bh_vat`, `bj_ifu`, `bo_tin`, `br_cnpj`, `br_cpf`, `bs_tin`, `by_tin`, `ca_bn`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `ca_qst`, `cd_nif`, `ch_uid`, `ch_vat`, `cl_tin`, `cm_niu`, `cn_tin`, `co_nit`, `cr_tin`, `cv_nif`, `de_stn`, `do_rcn`, `ec_ruc`, `eg_tin`, `es_cif`, `et_tin`, `eu_oss_vat`, `eu_vat`, `gb_vat`, `ge_vat`, `gn_nif`, `hk_br`, `hr_oib`, `hu_tin`, `id_npwp`, `il_vat`, `in_gst`, `is_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `ke_pin`, `kg_tin`, `kh_tin`, `kr_brn`, `kz_bin`, `la_tin`, `li_uid`, `li_vat`, `ma_vat`, `md_vat`, `me_pib`, `mk_vat`, `mr_nif`, `mx_rfc`, `my_frp`, `my_itn`, `my_sst`, `ng_tin`, `no_vat`, `no_voec`, `np_pan`, `nz_gst`, `om_vat`, `pe_ruc`, `ph_tin`, `ro_tin`, `rs_pib`, `ru_inn`, `ru_kpp`, `sa_vat`, `sg_gst`, `sg_uen`, `si_tin`, `sn_ninea`, `sr_fin`, `sv_nit`, `th_vat`, `tj_tin`, `tr_tin`, `tw_vat`, `tz_vat`, `ua_vat`, `ug_tin`, `us_ein`, `uy_ruc`, `uz_tin`, `uz_vat`, `ve_rif`, `vn_tin`, `za_vat`, `zm_tin`, or `zw_tin`
sig { returns(String) }
attr_accessor :type
# Value of the tax ID.
sig { returns(String) }
attr_accessor :value
sig { params(type: String, value: String).void }
def initialize(type: nil, value: nil); end
end
# The customer's address.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Customer::CreateParams::Address))))
}
attr_accessor :address
# An integer amount in cents (or local equivalent) that represents the customer's current balance, which affect the customer's future invoices. A negative amount represents a credit that decreases the amount due on an invoice; a positive amount increases the amount due on an invoice.
sig { returns(T.nilable(Integer)) }
attr_accessor :balance
# Balance information and default balance settings for this customer.
sig { returns(T.nilable(::Stripe::Customer::CreateParams::CashBalance)) }
attr_accessor :cash_balance
# An arbitrary string that you can attach to a customer object. It is displayed alongside the customer in the dashboard.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Customer's email address. It's displayed alongside the customer in your dashboard and can be useful for searching and tracking. This may be up to *512 characters*.
sig { returns(T.nilable(String)) }
attr_accessor :email
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The prefix for the customer used to generate unique invoice numbers. Must be 3–12 uppercase letters or numbers.
sig { returns(T.nilable(String)) }
attr_accessor :invoice_prefix
# Default invoice settings for this customer.
sig { returns(T.nilable(::Stripe::Customer::CreateParams::InvoiceSettings)) }
attr_accessor :invoice_settings
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# The customer's full name or business name.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The sequence to be used on the customer's next invoice. Defaults to 1.
sig { returns(T.nilable(Integer)) }
attr_accessor :next_invoice_sequence
# Attribute for param field payment_method
sig { returns(T.nilable(String)) }
attr_accessor :payment_method
# The customer's phone number.
sig { returns(T.nilable(String)) }
attr_accessor :phone
# Customer's preferred languages, ordered by preference.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :preferred_locales
# The customer's shipping information. Appears on invoices emailed to this customer.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Customer::CreateParams::Shipping))))
}
attr_accessor :shipping
# Attribute for param field source
sig { returns(T.nilable(String)) }
attr_accessor :source
# Tax details about the customer.
sig { returns(T.nilable(::Stripe::Customer::CreateParams::Tax)) }
attr_accessor :tax
# The customer's tax exemption. One of `none`, `exempt`, or `reverse`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :tax_exempt
# The customer's tax IDs.
sig { returns(T.nilable(T::Array[::Stripe::Customer::CreateParams::TaxIdDatum])) }
attr_accessor :tax_id_data
# ID of the test clock to attach to the customer.
sig { returns(T.nilable(String)) }
attr_accessor :test_clock
# Attribute for param field validate
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :validate
sig {
params(address: T.nilable(T.nilable(T.any(String, ::Stripe::Customer::CreateParams::Address))), balance: T.nilable(Integer), cash_balance: T.nilable(::Stripe::Customer::CreateParams::CashBalance), description: T.nilable(String), email: T.nilable(String), expand: T.nilable(T::Array[String]), invoice_prefix: T.nilable(String), invoice_settings: T.nilable(::Stripe::Customer::CreateParams::InvoiceSettings), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), name: T.nilable(String), next_invoice_sequence: T.nilable(Integer), payment_method: T.nilable(String), phone: T.nilable(String), preferred_locales: T.nilable(T::Array[String]), shipping: T.nilable(T.nilable(T.any(String, ::Stripe::Customer::CreateParams::Shipping))), source: T.nilable(String), tax: T.nilable(::Stripe::Customer::CreateParams::Tax), tax_exempt: T.nilable(T.nilable(T.any(String, String))), tax_id_data: T.nilable(T::Array[::Stripe::Customer::CreateParams::TaxIdDatum]), test_clock: T.nilable(String), validate: T.nilable(T::Boolean)).void
}
def initialize(
address: nil,
balance: nil,
cash_balance: nil,
description: nil,
email: nil,
expand: nil,
invoice_prefix: nil,
invoice_settings: nil,
metadata: nil,
name: nil,
next_invoice_sequence: nil,
payment_method: nil,
phone: nil,
preferred_locales: nil,
shipping: nil,
source: nil,
tax: nil,
tax_exempt: nil,
tax_id_data: nil,
test_clock: nil,
validate: nil
); end
end
class ListPaymentMethodsParams < Stripe::RequestParams
# This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow.
sig { returns(T.nilable(String)) }
attr_accessor :allow_redisplay
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# An optional filter on the list, based on the object `type` field. Without the filter, the list includes all current and future payment method types. If your integration expects only one type of payment method in the response, make sure to provide a type value in the request.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(allow_redisplay: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String), type: T.nilable(String)).void
}
def initialize(
allow_redisplay: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil,
type: nil
); end
end
class RetrievePaymentMethodParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class SearchParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for pagination across multiple pages of results. Don't include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.
sig { returns(T.nilable(String)) }
attr_accessor :page
# The search query string. See [search query language](https://stripe.com/docs/search#search-query-language) and the list of supported [query fields for customers](https://stripe.com/docs/search#query-fields-for-customers).
sig { returns(String) }
attr_accessor :query
sig {
params(expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), page: T.nilable(String), query: String).void
}
def initialize(expand: nil, limit: nil, page: nil, query: nil); end
end
class CreateFundingInstructionsParams < Stripe::RequestParams
class BankTransfer < Stripe::RequestParams
class EuBankTransfer < Stripe::RequestParams
# The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
sig { returns(String) }
attr_accessor :country
sig { params(country: String).void }
def initialize(country: nil); end
end
# Configuration for eu_bank_transfer funding type.
sig {
returns(T.nilable(::Stripe::Customer::CreateFundingInstructionsParams::BankTransfer::EuBankTransfer))
}
attr_accessor :eu_bank_transfer
# List of address types that should be returned in the financial_addresses response. If not specified, all valid types will be returned.
#
# Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :requested_address_types
# The type of the `bank_transfer`
sig { returns(String) }
attr_accessor :type
sig {
params(eu_bank_transfer: T.nilable(::Stripe::Customer::CreateFundingInstructionsParams::BankTransfer::EuBankTransfer), requested_address_types: T.nilable(T::Array[String]), type: String).void
}
def initialize(eu_bank_transfer: nil, requested_address_types: nil, type: nil); end
end
# Additional parameters for `bank_transfer` funding types
sig { returns(::Stripe::Customer::CreateFundingInstructionsParams::BankTransfer) }
attr_accessor :bank_transfer
# 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).
sig { returns(String) }
attr_accessor :currency
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The `funding_type` to get the instructions for.
sig { returns(String) }
attr_accessor :funding_type
sig {
params(bank_transfer: ::Stripe::Customer::CreateFundingInstructionsParams::BankTransfer, currency: String, expand: T.nilable(T::Array[String]), funding_type: String).void
}
def initialize(bank_transfer: nil, currency: nil, expand: nil, funding_type: nil); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class FundCashBalanceParams < Stripe::RequestParams
# Amount to be used for this test cash balance transaction. A positive integer representing how much to fund in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to fund $1.00 or 100 to fund ¥100, a zero-decimal currency).
sig { returns(Integer) }
attr_accessor :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).
sig { returns(String) }
attr_accessor :currency
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A description of the test funding. This simulates free-text references supplied by customers when making bank transfers to their cash balance. You can use this to test how Stripe's [reconciliation algorithm](https://stripe.com/docs/payments/customer-balance/reconciliation) applies to different user inputs.
sig { returns(T.nilable(String)) }
attr_accessor :reference
sig {
params(amount: Integer, currency: String, expand: T.nilable(T::Array[String]), reference: T.nilable(String)).void
}
def initialize(amount: nil, currency: nil, expand: nil, reference: nil); end
end
# Creates a new customer object.
sig {
params(params: T.any(::Stripe::Customer::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Customer)
}
def self.create(params = {}, opts = {}); end
# Retrieve funding instructions for a customer cash balance. If funding instructions do not yet exist for the customer, new
# funding instructions will be created. If funding instructions have already been created for a given customer, the same
# funding instructions will be retrieved. In other words, we will return the same funding instructions each time.
sig {
params(params: T.any(::Stripe::Customer::CreateFundingInstructionsParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::FundingInstructions)
}
def create_funding_instructions(params = {}, opts = {}); end
# Retrieve funding instructions for a customer cash balance. If funding instructions do not yet exist for the customer, new
# funding instructions will be created. If funding instructions have already been created for a given customer, the same
# funding instructions will be retrieved. In other words, we will return the same funding instructions each time.
sig {
params(customer: String, params: T.any(::Stripe::Customer::CreateFundingInstructionsParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::FundingInstructions)
}
def self.create_funding_instructions(customer, params = {}, opts = {}); end
# Permanently deletes a customer. It cannot be undone. Also immediately cancels any active subscriptions on the customer.
sig {
params(customer: String, params: T.any(::Stripe::Customer::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Customer)
}
def self.delete(customer, params = {}, opts = {}); end
# Permanently deletes a customer. It cannot be undone. Also immediately cancels any active subscriptions on the customer.
sig {
params(params: T.any(::Stripe::Customer::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Customer)
}
def delete(params = {}, opts = {}); end
# Removes the currently applied discount on a customer.
sig {
params(params: T.any(::Stripe::Customer::DeleteDiscountParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Discount)
}
def delete_discount(params = {}, opts = {}); end
# Removes the currently applied discount on a customer.
sig {
params(customer: String, params: T.any(::Stripe::Customer::DeleteDiscountParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Discount)
}
def self.delete_discount(customer, params = {}, opts = {}); end
# Returns a list of your customers. The customers are returned sorted by creation date, with the most recent customers appearing first.
sig {
params(params: T.any(::Stripe::Customer::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Returns a list of PaymentMethods for a given Customer
sig {
params(params: T.any(::Stripe::Customer::ListPaymentMethodsParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list_payment_methods(params = {}, opts = {}); end
# Returns a list of PaymentMethods for a given Customer
sig {
params(customer: String, params: T.any(::Stripe::Customer::ListPaymentMethodsParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list_payment_methods(customer, params = {}, opts = {}); end
# Retrieves a customer's cash balance.
sig {
params(customer: String, params: T.any(::Stripe::Customer::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(T.untyped)
}
def self.retrieve_cash_balance(customer, params = {}, opts = {}); end
# Retrieves a PaymentMethod object for a given Customer.
sig {
params(payment_method: String, params: T.any(::Stripe::Customer::RetrievePaymentMethodParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentMethod)
}
def retrieve_payment_method(payment_method, params = {}, opts = {}); end
# Retrieves a PaymentMethod object for a given Customer.
sig {
params(customer: String, payment_method: String, params: T.any(::Stripe::Customer::RetrievePaymentMethodParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentMethod)
}
def self.retrieve_payment_method(customer, payment_method, params = {}, opts = {}); end
sig {
params(params: T.any(::Stripe::Customer::SearchParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SearchResultObject)
}
def self.search(params = {}, opts = {}); end
sig {
params(params: T.any(::Stripe::Customer::SearchParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped, blk: T.untyped).returns(Stripe::SearchResultObject)
}
def self.search_auto_paging_each(params = {}, opts = {}, &blk); end
# Updates the specified customer by setting the values of the parameters passed. Any parameters not provided will be left unchanged. For example, if you pass the source parameter, that becomes the customer's active source (e.g., a card) to be used for all charges in the future. When you update a customer to a new valid card source by passing the source parameter: for each of the customer's current subscriptions, if the subscription bills automatically and is in the past_due state, then the latest open invoice for the subscription with automatic collection enabled will be retried. This retry will not count as an automatic retry, and will not affect the next regularly scheduled payment for the invoice. Changing the default_source for a customer will not trigger this behavior.
#
# This request accepts mostly the same arguments as the customer creation call.
sig {
params(customer: String, params: T.any(::Stripe::Customer::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Customer)
}
def self.update(customer, params = {}, opts = {}); end
# Changes the settings on a customer's cash balance.
sig {
params(customer: String, params: T.any(::Stripe::Customer::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(T.untyped)
}
def self.update_cash_balance(customer, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
# Each customer has a [Balance](https://stripe.com/docs/api/customers/object#customer_object-balance) value,
# which denotes a debit or credit that's automatically applied to their next invoice upon finalization.
# You may modify the value directly by using the [update customer API](https://stripe.com/docs/api/customers/update),
# or by creating a Customer Balance Transaction, which increments or decrements the customer's `balance` by the specified `amount`.
#
# Related guide: [Customer balance](https://stripe.com/docs/billing/customer/balance)
class CustomerBalanceTransaction < APIResource
# The amount of the transaction. A negative value is a credit for the customer's balance, and a positive value is a debit to the customer's `balance`.
sig { returns(Integer) }
attr_reader :amount
# The ID of the checkout session (if any) that created the transaction.
sig { returns(T.nilable(T.any(String, Stripe::Checkout::Session))) }
attr_reader :checkout_session
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# The ID of the credit note (if any) related to the transaction.
sig { returns(T.nilable(T.any(String, Stripe::CreditNote))) }
attr_reader :credit_note
# 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).
sig { returns(String) }
attr_reader :currency
# The ID of the customer the transaction belongs to.
sig { returns(T.any(String, Stripe::Customer)) }
attr_reader :customer
# Attribute for field customer_account
sig { returns(T.nilable(String)) }
attr_reader :customer_account
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_reader :description
# The customer's `balance` after the transaction was applied. A negative value decreases the amount due on the customer's next invoice. A positive value increases the amount due on the customer's next invoice.
sig { returns(Integer) }
attr_reader :ending_balance
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# The ID of the invoice (if any) related to the transaction.
sig { returns(T.nilable(T.any(String, Stripe::Invoice))) }
attr_reader :invoice
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# 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.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Transaction type: `adjustment`, `applied_to_invoice`, `credit_note`, `initial`, `invoice_overpaid`, `invoice_too_large`, `invoice_too_small`, `unspent_receiver_credit`, `unapplied_from_invoice`, `checkout_session_subscription_payment`, or `checkout_session_subscription_payment_canceled`. See the [Customer Balance page](https://stripe.com/docs/billing/customer/balance#types) to learn more about transaction types.
sig { returns(String) }
attr_reader :type
end
end
# typed: true
module Stripe
# Customers with certain payments enabled have a cash balance, representing funds that were paid
# by the customer to a merchant, but have not yet been allocated to a payment. Cash Balance Transactions
# represent when funds are moved into or out of this balance. This includes funding by the customer, allocation
# to payments, and refunds to the customer.
class CustomerCashBalanceTransaction < APIResource
class AdjustedForOverdraft < Stripe::StripeObject
# The [Balance Transaction](https://stripe.com/docs/api/balance_transactions/object) that corresponds to funds taken out of your Stripe balance.
sig { returns(T.any(String, Stripe::BalanceTransaction)) }
attr_reader :balance_transaction
# The [Cash Balance Transaction](https://stripe.com/docs/api/cash_balance_transactions/object) that brought the customer balance negative, triggering the clawback of funds.
sig { returns(T.any(String, Stripe::CustomerCashBalanceTransaction)) }
attr_reader :linked_transaction
end
class AppliedToPayment < Stripe::StripeObject
# The [Payment Intent](https://stripe.com/docs/api/payment_intents/object) that funds were applied to.
sig { returns(T.any(String, Stripe::PaymentIntent)) }
attr_reader :payment_intent
end
class Funded < Stripe::StripeObject
class BankTransfer < Stripe::StripeObject
class EuBankTransfer < Stripe::StripeObject
# The BIC of the bank of the sender of the funding.
sig { returns(T.nilable(String)) }
attr_reader :bic
# The last 4 digits of the IBAN of the sender of the funding.
sig { returns(T.nilable(String)) }
attr_reader :iban_last4
# The full name of the sender, as supplied by the sending bank.
sig { returns(T.nilable(String)) }
attr_reader :sender_name
end
class GbBankTransfer < Stripe::StripeObject
# The last 4 digits of the account number of the sender of the funding.
sig { returns(T.nilable(String)) }
attr_reader :account_number_last4
# The full name of the sender, as supplied by the sending bank.
sig { returns(T.nilable(String)) }
attr_reader :sender_name
# The sort code of the bank of the sender of the funding
sig { returns(T.nilable(String)) }
attr_reader :sort_code
end
class JpBankTransfer < Stripe::StripeObject
# The name of the bank of the sender of the funding.
sig { returns(T.nilable(String)) }
attr_reader :sender_bank
# The name of the bank branch of the sender of the funding.
sig { returns(T.nilable(String)) }
attr_reader :sender_branch
# The full name of the sender, as supplied by the sending bank.
sig { returns(T.nilable(String)) }
attr_reader :sender_name
end
class UsBankTransfer < Stripe::StripeObject
# The banking network used for this funding.
sig { returns(String) }
attr_reader :network
# The full name of the sender, as supplied by the sending bank.
sig { returns(T.nilable(String)) }
attr_reader :sender_name
end
# Attribute for field eu_bank_transfer
sig { returns(EuBankTransfer) }
attr_reader :eu_bank_transfer
# Attribute for field gb_bank_transfer
sig { returns(GbBankTransfer) }
attr_reader :gb_bank_transfer
# Attribute for field jp_bank_transfer
sig { returns(JpBankTransfer) }
attr_reader :jp_bank_transfer
# The user-supplied reference field on the bank transfer.
sig { returns(T.nilable(String)) }
attr_reader :reference
# 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`.
sig { returns(String) }
attr_reader :type
# Attribute for field us_bank_transfer
sig { returns(UsBankTransfer) }
attr_reader :us_bank_transfer
end
# Attribute for field bank_transfer
sig { returns(BankTransfer) }
attr_reader :bank_transfer
end
class RefundedFromPayment < Stripe::StripeObject
# The [Refund](https://stripe.com/docs/api/refunds/object) that moved these funds into the customer's cash balance.
sig { returns(T.any(String, Stripe::Refund)) }
attr_reader :refund
end
class TransferredToBalance < Stripe::StripeObject
# The [Balance Transaction](https://stripe.com/docs/api/balance_transactions/object) that corresponds to funds transferred to your Stripe balance.
sig { returns(T.any(String, Stripe::BalanceTransaction)) }
attr_reader :balance_transaction
end
class UnappliedFromPayment < Stripe::StripeObject
# The [Payment Intent](https://stripe.com/docs/api/payment_intents/object) that funds were unapplied from.
sig { returns(T.any(String, Stripe::PaymentIntent)) }
attr_reader :payment_intent
end
# Attribute for field adjusted_for_overdraft
sig { returns(AdjustedForOverdraft) }
attr_reader :adjusted_for_overdraft
# Attribute for field applied_to_payment
sig { returns(AppliedToPayment) }
attr_reader :applied_to_payment
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# 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).
sig { returns(String) }
attr_reader :currency
# The customer whose available cash balance changed as a result of this transaction.
sig { returns(T.any(String, Stripe::Customer)) }
attr_reader :customer
# Attribute for field customer_account
sig { returns(T.nilable(String)) }
attr_reader :customer_account
# The total available cash balance for the specified currency after this transaction was applied. Represented in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(Integer) }
attr_reader :ending_balance
# Attribute for field funded
sig { returns(Funded) }
attr_reader :funded
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# The amount by which the cash balance changed, represented in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal). A positive value represents funds being added to the cash balance, a negative value represents funds being removed from the cash balance.
sig { returns(Integer) }
attr_reader :net_amount
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Attribute for field refunded_from_payment
sig { returns(RefundedFromPayment) }
attr_reader :refunded_from_payment
# Attribute for field transferred_to_balance
sig { returns(TransferredToBalance) }
attr_reader :transferred_to_balance
# The type of the cash balance transaction. New types may be added in future. See [Customer Balance](https://stripe.com/docs/payments/customer-balance#types) to learn more about these types.
sig { returns(String) }
attr_reader :type
# Attribute for field unapplied_from_payment
sig { returns(UnappliedFromPayment) }
attr_reader :unapplied_from_payment
end
end
# typed: true
module Stripe
# A Customer Session allows you to grant Stripe's frontend SDKs (like Stripe.js) client-side access
# control over a Customer.
#
# Related guides: [Customer Session with the Payment Element](https://docs.stripe.com/payments/accept-a-payment-deferred?platform=web&type=payment#save-payment-methods),
# [Customer Session with the Pricing Table](https://docs.stripe.com/payments/checkout/pricing-table#customer-session),
# [Customer Session with the Buy Button](https://docs.stripe.com/payment-links/buy-button#pass-an-existing-customer).
class CustomerSession < APIResource
class Components < Stripe::StripeObject
class BuyButton < Stripe::StripeObject
# Whether the buy button is enabled.
sig { returns(T::Boolean) }
attr_reader :enabled
end
class PaymentElement < Stripe::StripeObject
class Features < Stripe::StripeObject
# A list of [`allow_redisplay`](https://docs.stripe.com/api/payment_methods/object#payment_method_object-allow_redisplay) values that controls which saved payment methods the Payment Element displays by filtering to only show payment methods with an `allow_redisplay` value that is present in this list.
#
# If not specified, defaults to ["always"]. In order to display all saved payment methods, specify ["always", "limited", "unspecified"].
sig { returns(T::Array[String]) }
attr_reader :payment_method_allow_redisplay_filters
# Controls whether or not the Payment Element shows saved payment methods. This parameter defaults to `disabled`.
sig { returns(String) }
attr_reader :payment_method_redisplay
# Determines the max number of saved payment methods for the Payment Element to display. This parameter defaults to `3`.
sig { returns(T.nilable(Integer)) }
attr_reader :payment_method_redisplay_limit
# Controls whether the Payment Element displays the option to remove a saved payment method. This parameter defaults to `disabled`.
#
# Allowing buyers to remove their saved payment methods impacts subscriptions that depend on that payment method. Removing the payment method detaches the [`customer` object](https://docs.stripe.com/api/payment_methods/object#payment_method_object-customer) from that [PaymentMethod](https://docs.stripe.com/api/payment_methods).
sig { returns(String) }
attr_reader :payment_method_remove
# Controls whether the Payment Element displays a checkbox offering to save a new payment method. This parameter defaults to `disabled`.
#
# If a customer checks the box, the [`allow_redisplay`](https://docs.stripe.com/api/payment_methods/object#payment_method_object-allow_redisplay) value on the PaymentMethod is set to `'always'` at confirmation time. For PaymentIntents, the [`setup_future_usage`](https://docs.stripe.com/api/payment_intents/object#payment_intent_object-setup_future_usage) value is also set to the value defined in `payment_method_save_usage`.
sig { returns(String) }
attr_reader :payment_method_save
# When using PaymentIntents and the customer checks the save checkbox, this field determines the [`setup_future_usage`](https://docs.stripe.com/api/payment_intents/object#payment_intent_object-setup_future_usage) value used to confirm the PaymentIntent.
#
# When using SetupIntents, directly configure the [`usage`](https://docs.stripe.com/api/setup_intents/object#setup_intent_object-usage) value on SetupIntent creation.
sig { returns(T.nilable(String)) }
attr_reader :payment_method_save_usage
end
# Whether the Payment Element is enabled.
sig { returns(T::Boolean) }
attr_reader :enabled
# This hash defines whether the Payment Element supports certain features.
sig { returns(T.nilable(Features)) }
attr_reader :features
end
class PricingTable < Stripe::StripeObject
# Whether the pricing table is enabled.
sig { returns(T::Boolean) }
attr_reader :enabled
end
# This hash contains whether the buy button is enabled.
sig { returns(BuyButton) }
attr_reader :buy_button
# This hash contains whether the Payment Element is enabled and the features it supports.
sig { returns(PaymentElement) }
attr_reader :payment_element
# This hash contains whether the pricing table is enabled.
sig { returns(PricingTable) }
attr_reader :pricing_table
end
# The client secret of this Customer Session. Used on the client to set up secure access to the given `customer`.
#
# The client secret can be used to provide access to `customer` from your frontend. It should not be stored, logged, or exposed to anyone other than the relevant customer. Make sure that you have TLS enabled on any page that includes the client secret.
sig { returns(String) }
attr_reader :client_secret
# Configuration for the components supported by this Customer Session.
sig { returns(Components) }
attr_reader :components
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# The Customer the Customer Session was created for.
sig { returns(T.any(String, Stripe::Customer)) }
attr_reader :customer
# The Account that the Customer Session was created for.
sig { returns(T.nilable(String)) }
attr_reader :customer_account
# The timestamp at which this Customer Session will expire.
sig { returns(Integer) }
attr_reader :expires_at
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
class CreateParams < Stripe::RequestParams
class Components < Stripe::RequestParams
class BuyButton < Stripe::RequestParams
# Whether the buy button is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
sig { params(enabled: T::Boolean).void }
def initialize(enabled: nil); end
end
class PaymentElement < Stripe::RequestParams
class Features < Stripe::RequestParams
# A list of [`allow_redisplay`](https://docs.stripe.com/api/payment_methods/object#payment_method_object-allow_redisplay) values that controls which saved payment methods the Payment Element displays by filtering to only show payment methods with an `allow_redisplay` value that is present in this list.
#
# If not specified, defaults to ["always"]. In order to display all saved payment methods, specify ["always", "limited", "unspecified"].
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :payment_method_allow_redisplay_filters
# Controls whether or not the Payment Element shows saved payment methods. This parameter defaults to `disabled`.
sig { returns(T.nilable(String)) }
attr_accessor :payment_method_redisplay
# Determines the max number of saved payment methods for the Payment Element to display. This parameter defaults to `3`.
sig { returns(T.nilable(Integer)) }
attr_accessor :payment_method_redisplay_limit
# Controls whether the Payment Element displays the option to remove a saved payment method. This parameter defaults to `disabled`.
#
# Allowing buyers to remove their saved payment methods impacts subscriptions that depend on that payment method. Removing the payment method detaches the [`customer` object](https://docs.stripe.com/api/payment_methods/object#payment_method_object-customer) from that [PaymentMethod](https://docs.stripe.com/api/payment_methods).
sig { returns(T.nilable(String)) }
attr_accessor :payment_method_remove
# Controls whether the Payment Element displays a checkbox offering to save a new payment method. This parameter defaults to `disabled`.
#
# If a customer checks the box, the [`allow_redisplay`](https://docs.stripe.com/api/payment_methods/object#payment_method_object-allow_redisplay) value on the PaymentMethod is set to `'always'` at confirmation time. For PaymentIntents, the [`setup_future_usage`](https://docs.stripe.com/api/payment_intents/object#payment_intent_object-setup_future_usage) value is also set to the value defined in `payment_method_save_usage`.
sig { returns(T.nilable(String)) }
attr_accessor :payment_method_save
# When using PaymentIntents and the customer checks the save checkbox, this field determines the [`setup_future_usage`](https://docs.stripe.com/api/payment_intents/object#payment_intent_object-setup_future_usage) value used to confirm the PaymentIntent.
#
# When using SetupIntents, directly configure the [`usage`](https://docs.stripe.com/api/setup_intents/object#setup_intent_object-usage) value on SetupIntent creation.
sig { returns(T.nilable(String)) }
attr_accessor :payment_method_save_usage
sig {
params(payment_method_allow_redisplay_filters: T.nilable(T::Array[String]), payment_method_redisplay: T.nilable(String), payment_method_redisplay_limit: T.nilable(Integer), payment_method_remove: T.nilable(String), payment_method_save: T.nilable(String), payment_method_save_usage: T.nilable(String)).void
}
def initialize(
payment_method_allow_redisplay_filters: nil,
payment_method_redisplay: nil,
payment_method_redisplay_limit: nil,
payment_method_remove: nil,
payment_method_save: nil,
payment_method_save_usage: nil
); end
end
# Whether the Payment Element is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# This hash defines whether the Payment Element supports certain features.
sig {
returns(T.nilable(::Stripe::CustomerSession::CreateParams::Components::PaymentElement::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::CustomerSession::CreateParams::Components::PaymentElement::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class PricingTable < Stripe::RequestParams
# Whether the pricing table is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
sig { params(enabled: T::Boolean).void }
def initialize(enabled: nil); end
end
# Configuration for buy button.
sig { returns(T.nilable(::Stripe::CustomerSession::CreateParams::Components::BuyButton)) }
attr_accessor :buy_button
# Configuration for the Payment Element.
sig {
returns(T.nilable(::Stripe::CustomerSession::CreateParams::Components::PaymentElement))
}
attr_accessor :payment_element
# Configuration for the pricing table.
sig {
returns(T.nilable(::Stripe::CustomerSession::CreateParams::Components::PricingTable))
}
attr_accessor :pricing_table
sig {
params(buy_button: T.nilable(::Stripe::CustomerSession::CreateParams::Components::BuyButton), payment_element: T.nilable(::Stripe::CustomerSession::CreateParams::Components::PaymentElement), pricing_table: T.nilable(::Stripe::CustomerSession::CreateParams::Components::PricingTable)).void
}
def initialize(buy_button: nil, payment_element: nil, pricing_table: nil); end
end
# Configuration for each component. Exactly 1 component must be enabled.
sig { returns(::Stripe::CustomerSession::CreateParams::Components) }
attr_accessor :components
# The ID of an existing customer for which to create the Customer Session.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# The ID of an existing Account for which to create the Customer Session.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig {
params(components: ::Stripe::CustomerSession::CreateParams::Components, customer: T.nilable(String), customer_account: T.nilable(String), expand: T.nilable(T::Array[String])).void
}
def initialize(components: nil, customer: nil, customer_account: nil, expand: nil); end
end
# Creates a Customer Session object that includes a single-use client secret that you can use on your front-end to grant client-side API access for certain customer resources.
sig {
params(params: T.any(::Stripe::CustomerSession::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::CustomerSession)
}
def self.create(params = {}, opts = {}); end
end
end
# typed: true
module Stripe
# A discount represents the actual application of a [coupon](https://stripe.com/docs/api#coupons) or [promotion code](https://stripe.com/docs/api#promotion_codes).
# It contains information about when the discount began, when it will end, and what it is applied to.
#
# Related guide: [Applying discounts to subscriptions](https://stripe.com/docs/billing/subscriptions/discounts)
class Discount < StripeObject
# The Checkout session that this coupon is applied to, if it is applied to a particular session in payment mode. Will not be present for subscription mode.
sig { returns(T.nilable(String)) }
attr_reader :checkout_session
# A coupon contains information about a percent-off or amount-off discount you
# might want to apply to a customer. Coupons may be applied to [subscriptions](https://stripe.com/docs/api#subscriptions), [invoices](https://stripe.com/docs/api#invoices),
# [checkout sessions](https://stripe.com/docs/api/checkout/sessions), [quotes](https://stripe.com/docs/api#quotes), and more. Coupons do not work with conventional one-off [charges](https://stripe.com/docs/api#create_charge) or [payment intents](https://stripe.com/docs/api/payment_intents).
sig { returns(Stripe::Coupon) }
attr_reader :coupon
# The ID of the customer associated with this discount.
sig { returns(T.nilable(T.any(String, Stripe::Customer))) }
attr_reader :customer
# The ID of the account associated with this discount.
sig { returns(T.nilable(String)) }
attr_reader :customer_account
# If the coupon has a duration of `repeating`, the date that this discount will end. If the coupon has a duration of `once` or `forever`, this attribute will be null.
sig { returns(T.nilable(Integer)) }
attr_reader :end
# The ID of the discount object. Discounts cannot be fetched by ID. Use `expand[]=discounts` in API calls to expand discount IDs in an array.
sig { returns(String) }
attr_reader :id
# The invoice that the discount's coupon was applied to, if it was applied directly to a particular invoice.
sig { returns(T.nilable(String)) }
attr_reader :invoice
# The invoice item `id` (or invoice line item `id` for invoice line items of type='subscription') that the discount's coupon was applied to, if it was applied directly to a particular invoice item or invoice line item.
sig { returns(T.nilable(String)) }
attr_reader :invoice_item
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The promotion code applied to create this discount.
sig { returns(T.nilable(T.any(String, Stripe::PromotionCode))) }
attr_reader :promotion_code
# Date that the coupon was applied.
sig { returns(Integer) }
attr_reader :start
# The subscription that this coupon is applied to, if it is applied to a particular subscription.
sig { returns(T.nilable(String)) }
attr_reader :subscription
# The subscription item that this coupon is applied to, if it is applied to a particular subscription item.
sig { returns(T.nilable(String)) }
attr_reader :subscription_item
# Always true for a deleted object
sig { returns(T::Boolean) }
attr_reader :deleted
end
end
# typed: true
module Stripe
# A dispute occurs when a customer questions your charge with their card issuer.
# When this happens, you have the opportunity to respond to the dispute with
# evidence that shows that the charge is legitimate.
#
# Related guide: [Disputes and fraud](https://stripe.com/docs/disputes)
class Dispute < APIResource
class Evidence < Stripe::StripeObject
class EnhancedEvidence < Stripe::StripeObject
class VisaCompellingEvidence3 < Stripe::StripeObject
class DisputedTransaction < Stripe::StripeObject
class ShippingAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# User Account ID used to log into business platform. Must be recognizable by the user.
sig { returns(T.nilable(String)) }
attr_reader :customer_account_id
# Unique identifier of the cardholder’s device derived from a combination of at least two hardware and software attributes. Must be at least 20 characters.
sig { returns(T.nilable(String)) }
attr_reader :customer_device_fingerprint
# Unique identifier of the cardholder’s device such as a device serial number (e.g., International Mobile Equipment Identity [IMEI]). Must be at least 15 characters.
sig { returns(T.nilable(String)) }
attr_reader :customer_device_id
# The email address of the customer.
sig { returns(T.nilable(String)) }
attr_reader :customer_email_address
# The IP address that the customer used when making the purchase.
sig { returns(T.nilable(String)) }
attr_reader :customer_purchase_ip
# Categorization of disputed payment.
sig { returns(T.nilable(String)) }
attr_reader :merchandise_or_services
# A description of the product or service that was sold.
sig { returns(T.nilable(String)) }
attr_reader :product_description
# The address to which a physical product was shipped. All fields are required for Visa Compelling Evidence 3.0 evidence submission.
sig { returns(T.nilable(ShippingAddress)) }
attr_reader :shipping_address
end
class PriorUndisputedTransaction < Stripe::StripeObject
class ShippingAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Stripe charge ID for the Visa Compelling Evidence 3.0 eligible prior charge.
sig { returns(String) }
attr_reader :charge
# User Account ID used to log into business platform. Must be recognizable by the user.
sig { returns(T.nilable(String)) }
attr_reader :customer_account_id
# Unique identifier of the cardholder’s device derived from a combination of at least two hardware and software attributes. Must be at least 20 characters.
sig { returns(T.nilable(String)) }
attr_reader :customer_device_fingerprint
# Unique identifier of the cardholder’s device such as a device serial number (e.g., International Mobile Equipment Identity [IMEI]). Must be at least 15 characters.
sig { returns(T.nilable(String)) }
attr_reader :customer_device_id
# The email address of the customer.
sig { returns(T.nilable(String)) }
attr_reader :customer_email_address
# The IP address that the customer used when making the purchase.
sig { returns(T.nilable(String)) }
attr_reader :customer_purchase_ip
# A description of the product or service that was sold.
sig { returns(T.nilable(String)) }
attr_reader :product_description
# The address to which a physical product was shipped. All fields are required for Visa Compelling Evidence 3.0 evidence submission.
sig { returns(T.nilable(ShippingAddress)) }
attr_reader :shipping_address
end
# Disputed transaction details for Visa Compelling Evidence 3.0 evidence submission.
sig { returns(T.nilable(DisputedTransaction)) }
attr_reader :disputed_transaction
# List of exactly two prior undisputed transaction objects for Visa Compelling Evidence 3.0 evidence submission.
sig { returns(T::Array[PriorUndisputedTransaction]) }
attr_reader :prior_undisputed_transactions
end
class VisaCompliance < Stripe::StripeObject
# A field acknowledging the fee incurred when countering a Visa compliance dispute. If this field is set to true, evidence can be submitted for the compliance dispute. Stripe collects a 500 USD (or local equivalent) amount to cover the network costs associated with resolving compliance disputes. Stripe refunds the 500 USD network fee if you win the dispute.
sig { returns(T::Boolean) }
attr_reader :fee_acknowledged
end
# Attribute for field visa_compelling_evidence_3
sig { returns(VisaCompellingEvidence3) }
attr_reader :visa_compelling_evidence_3
# Attribute for field visa_compliance
sig { returns(VisaCompliance) }
attr_reader :visa_compliance
end
# Any server or activity logs showing proof that the customer accessed or downloaded the purchased digital product. This information should include IP addresses, corresponding timestamps, and any detailed recorded activity.
sig { returns(T.nilable(String)) }
attr_reader :access_activity_log
# The billing address provided by the customer.
sig { returns(T.nilable(String)) }
attr_reader :billing_address
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Your subscription cancellation policy, as shown to the customer.
sig { returns(T.nilable(T.any(String, Stripe::File))) }
attr_reader :cancellation_policy
# An explanation of how and when the customer was shown your refund policy prior to purchase.
sig { returns(T.nilable(String)) }
attr_reader :cancellation_policy_disclosure
# A justification for why the customer's subscription was not canceled.
sig { returns(T.nilable(String)) }
attr_reader :cancellation_rebuttal
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Any communication with the customer that you feel is relevant to your case. Examples include emails proving that the customer received the product or service, or demonstrating their use of or satisfaction with the product or service.
sig { returns(T.nilable(T.any(String, Stripe::File))) }
attr_reader :customer_communication
# The email address of the customer.
sig { returns(T.nilable(String)) }
attr_reader :customer_email_address
# The name of the customer.
sig { returns(T.nilable(String)) }
attr_reader :customer_name
# The IP address that the customer used when making the purchase.
sig { returns(T.nilable(String)) }
attr_reader :customer_purchase_ip
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) A relevant document or contract showing the customer's signature.
sig { returns(T.nilable(T.any(String, Stripe::File))) }
attr_reader :customer_signature
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Documentation for the prior charge that can uniquely identify the charge, such as a receipt, shipping label, work order, etc. This document should be paired with a similar document from the disputed payment that proves the two payments are separate.
sig { returns(T.nilable(T.any(String, Stripe::File))) }
attr_reader :duplicate_charge_documentation
# An explanation of the difference between the disputed charge versus the prior charge that appears to be a duplicate.
sig { returns(T.nilable(String)) }
attr_reader :duplicate_charge_explanation
# The Stripe ID for the prior charge which appears to be a duplicate of the disputed charge.
sig { returns(T.nilable(String)) }
attr_reader :duplicate_charge_id
# Attribute for field enhanced_evidence
sig { returns(EnhancedEvidence) }
attr_reader :enhanced_evidence
# A description of the product or service that was sold.
sig { returns(T.nilable(String)) }
attr_reader :product_description
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Any receipt or message sent to the customer notifying them of the charge.
sig { returns(T.nilable(T.any(String, Stripe::File))) }
attr_reader :receipt
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Your refund policy, as shown to the customer.
sig { returns(T.nilable(T.any(String, Stripe::File))) }
attr_reader :refund_policy
# Documentation demonstrating that the customer was shown your refund policy prior to purchase.
sig { returns(T.nilable(String)) }
attr_reader :refund_policy_disclosure
# A justification for why the customer is not entitled to a refund.
sig { returns(T.nilable(String)) }
attr_reader :refund_refusal_explanation
# The date on which the customer received or began receiving the purchased service, in a clear human-readable format.
sig { returns(T.nilable(String)) }
attr_reader :service_date
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Documentation showing proof that a service was provided to the customer. This could include a copy of a signed contract, work order, or other form of written agreement.
sig { returns(T.nilable(T.any(String, Stripe::File))) }
attr_reader :service_documentation
# The address to which a physical product was shipped. You should try to include as complete address information as possible.
sig { returns(T.nilable(String)) }
attr_reader :shipping_address
# The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc. If multiple carriers were used for this purchase, please separate them with commas.
sig { returns(T.nilable(String)) }
attr_reader :shipping_carrier
# The date on which a physical product began its route to the shipping address, in a clear human-readable format.
sig { returns(T.nilable(String)) }
attr_reader :shipping_date
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Documentation showing proof that a product was shipped to the customer at the same address the customer provided to you. This could include a copy of the shipment receipt, shipping label, etc. It should show the customer's full shipping address, if possible.
sig { returns(T.nilable(T.any(String, Stripe::File))) }
attr_reader :shipping_documentation
# The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
sig { returns(T.nilable(String)) }
attr_reader :shipping_tracking_number
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Any additional evidence or statements.
sig { returns(T.nilable(T.any(String, Stripe::File))) }
attr_reader :uncategorized_file
# Any additional evidence or statements.
sig { returns(T.nilable(String)) }
attr_reader :uncategorized_text
end
class EvidenceDetails < Stripe::StripeObject
class EnhancedEligibility < Stripe::StripeObject
class VisaCompellingEvidence3 < Stripe::StripeObject
# List of actions required to qualify dispute for Visa Compelling Evidence 3.0 evidence submission.
sig { returns(T::Array[String]) }
attr_reader :required_actions
# Visa Compelling Evidence 3.0 eligibility status.
sig { returns(String) }
attr_reader :status
end
class VisaCompliance < Stripe::StripeObject
# Visa compliance eligibility status.
sig { returns(String) }
attr_reader :status
end
# Attribute for field visa_compelling_evidence_3
sig { returns(VisaCompellingEvidence3) }
attr_reader :visa_compelling_evidence_3
# Attribute for field visa_compliance
sig { returns(VisaCompliance) }
attr_reader :visa_compliance
end
# Date by which evidence must be submitted in order to successfully challenge dispute. Will be 0 if the customer's bank or credit card company doesn't allow a response for this particular dispute.
sig { returns(T.nilable(Integer)) }
attr_reader :due_by
# Attribute for field enhanced_eligibility
sig { returns(EnhancedEligibility) }
attr_reader :enhanced_eligibility
# Whether evidence has been staged for this dispute.
sig { returns(T::Boolean) }
attr_reader :has_evidence
# Whether the last evidence submission was submitted past the due date. Defaults to `false` if no evidence submissions have occurred. If `true`, then delivery of the latest evidence is *not* guaranteed.
sig { returns(T::Boolean) }
attr_reader :past_due
# The number of times evidence has been submitted. Typically, you may only submit evidence once.
sig { returns(Integer) }
attr_reader :submission_count
end
class PaymentMethodDetails < Stripe::StripeObject
class AmazonPay < Stripe::StripeObject
# The AmazonPay dispute type, chargeback or claim
sig { returns(T.nilable(String)) }
attr_reader :dispute_type
end
class Card < Stripe::StripeObject
# Card brand. Can be `amex`, `diners`, `discover`, `eftpos_au`, `jcb`, `link`, `mastercard`, `unionpay`, `visa`, or `unknown`.
sig { returns(String) }
attr_reader :brand
# The type of dispute opened. Different case types may have varying fees and financial impact.
sig { returns(String) }
attr_reader :case_type
# The card network's specific dispute reason code, which maps to one of Stripe's primary dispute categories to simplify response guidance. The [Network code map](https://stripe.com/docs/disputes/categories#network-code-map) lists all available dispute reason codes by network.
sig { returns(T.nilable(String)) }
attr_reader :network_reason_code
end
class Klarna < Stripe::StripeObject
# The reason for the dispute as defined by Klarna
sig { returns(T.nilable(String)) }
attr_reader :reason_code
end
class Paypal < Stripe::StripeObject
# The ID of the dispute in PayPal.
sig { returns(T.nilable(String)) }
attr_reader :case_id
# The reason for the dispute as defined by PayPal
sig { returns(T.nilable(String)) }
attr_reader :reason_code
end
# Attribute for field amazon_pay
sig { returns(AmazonPay) }
attr_reader :amazon_pay
# Attribute for field card
sig { returns(Card) }
attr_reader :card
# Attribute for field klarna
sig { returns(Klarna) }
attr_reader :klarna
# Attribute for field paypal
sig { returns(Paypal) }
attr_reader :paypal
# Payment method type.
sig { returns(String) }
attr_reader :type
end
# Disputed amount. Usually the amount of the charge, but it can differ (usually because of currency fluctuation or because only part of the order is disputed).
sig { returns(Integer) }
attr_reader :amount
# List of zero, one, or two balance transactions that show funds withdrawn and reinstated to your Stripe account as a result of this dispute.
sig { returns(T::Array[Stripe::BalanceTransaction]) }
attr_reader :balance_transactions
# ID of the charge that's disputed.
sig { returns(T.any(String, Stripe::Charge)) }
attr_reader :charge
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# 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).
sig { returns(String) }
attr_reader :currency
# List of eligibility types that are included in `enhanced_evidence`.
sig { returns(T::Array[String]) }
attr_reader :enhanced_eligibility_types
# Attribute for field evidence
sig { returns(Evidence) }
attr_reader :evidence
# Attribute for field evidence_details
sig { returns(EvidenceDetails) }
attr_reader :evidence_details
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# If true, it's still possible to refund the disputed payment. After the payment has been fully refunded, no further funds are withdrawn from your Stripe account as a result of this dispute.
sig { returns(T::Boolean) }
attr_reader :is_charge_refundable
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# 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.
sig { returns(T::Hash[String, String]) }
attr_reader :metadata
# Network-dependent reason code for the dispute.
sig { returns(T.nilable(String)) }
attr_reader :network_reason_code
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# ID of the PaymentIntent that's disputed.
sig { returns(T.nilable(T.any(String, Stripe::PaymentIntent))) }
attr_reader :payment_intent
# Attribute for field payment_method_details
sig { returns(PaymentMethodDetails) }
attr_reader :payment_method_details
# Reason given by cardholder for dispute. Possible values are `bank_cannot_process`, `check_returned`, `credit_not_processed`, `customer_initiated`, `debit_not_authorized`, `duplicate`, `fraudulent`, `general`, `incorrect_account_details`, `insufficient_funds`, `noncompliant`, `product_not_received`, `product_unacceptable`, `subscription_canceled`, or `unrecognized`. Learn more about [dispute reasons](https://stripe.com/docs/disputes/categories).
sig { returns(String) }
attr_reader :reason
# Current status of dispute. Possible values are `warning_needs_response`, `warning_under_review`, `warning_closed`, `needs_response`, `under_review`, `won`, or `lost`.
sig { returns(String) }
attr_reader :status
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return disputes associated to the charge specified by this charge ID.
sig { returns(T.nilable(String)) }
attr_accessor :charge
# Only return disputes that were created during the given date interval.
sig { returns(T.nilable(T.any(::Stripe::Dispute::ListParams::Created, Integer))) }
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Only return disputes associated to the PaymentIntent specified by this PaymentIntent ID.
sig { returns(T.nilable(String)) }
attr_accessor :payment_intent
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(charge: T.nilable(String), created: T.nilable(T.any(::Stripe::Dispute::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), payment_intent: T.nilable(String), starting_after: T.nilable(String)).void
}
def initialize(
charge: nil,
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
payment_intent: nil,
starting_after: nil
); end
end
class UpdateParams < Stripe::RequestParams
class Evidence < Stripe::RequestParams
class EnhancedEvidence < Stripe::RequestParams
class VisaCompellingEvidence3 < Stripe::RequestParams
class DisputedTransaction < Stripe::RequestParams
class ShippingAddress < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :state
sig {
params(city: T.nilable(T.nilable(String)), country: T.nilable(T.nilable(String)), line1: T.nilable(T.nilable(String)), line2: T.nilable(T.nilable(String)), postal_code: T.nilable(T.nilable(String)), state: T.nilable(T.nilable(String))).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# User Account ID used to log into business platform. Must be recognizable by the user.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :customer_account_id
# Unique identifier of the cardholder’s device derived from a combination of at least two hardware and software attributes. Must be at least 20 characters.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :customer_device_fingerprint
# Unique identifier of the cardholder’s device such as a device serial number (e.g., International Mobile Equipment Identity [IMEI]). Must be at least 15 characters.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :customer_device_id
# The email address of the customer.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :customer_email_address
# The IP address that the customer used when making the purchase.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :customer_purchase_ip
# Categorization of disputed payment.
sig { returns(T.nilable(String)) }
attr_accessor :merchandise_or_services
# A description of the product or service that was sold.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :product_description
# The address to which a physical product was shipped. All fields are required for Visa Compelling Evidence 3.0 evidence submission.
sig {
returns(T.nilable(::Stripe::Dispute::UpdateParams::Evidence::EnhancedEvidence::VisaCompellingEvidence3::DisputedTransaction::ShippingAddress))
}
attr_accessor :shipping_address
sig {
params(customer_account_id: T.nilable(T.nilable(String)), customer_device_fingerprint: T.nilable(T.nilable(String)), customer_device_id: T.nilable(T.nilable(String)), customer_email_address: T.nilable(T.nilable(String)), customer_purchase_ip: T.nilable(T.nilable(String)), merchandise_or_services: T.nilable(String), product_description: T.nilable(T.nilable(String)), shipping_address: T.nilable(::Stripe::Dispute::UpdateParams::Evidence::EnhancedEvidence::VisaCompellingEvidence3::DisputedTransaction::ShippingAddress)).void
}
def initialize(
customer_account_id: nil,
customer_device_fingerprint: nil,
customer_device_id: nil,
customer_email_address: nil,
customer_purchase_ip: nil,
merchandise_or_services: nil,
product_description: nil,
shipping_address: nil
); end
end
class PriorUndisputedTransaction < Stripe::RequestParams
class ShippingAddress < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :state
sig {
params(city: T.nilable(T.nilable(String)), country: T.nilable(T.nilable(String)), line1: T.nilable(T.nilable(String)), line2: T.nilable(T.nilable(String)), postal_code: T.nilable(T.nilable(String)), state: T.nilable(T.nilable(String))).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Stripe charge ID for the Visa Compelling Evidence 3.0 eligible prior charge.
sig { returns(String) }
attr_accessor :charge
# User Account ID used to log into business platform. Must be recognizable by the user.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :customer_account_id
# Unique identifier of the cardholder’s device derived from a combination of at least two hardware and software attributes. Must be at least 20 characters.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :customer_device_fingerprint
# Unique identifier of the cardholder’s device such as a device serial number (e.g., International Mobile Equipment Identity [IMEI]). Must be at least 15 characters.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :customer_device_id
# The email address of the customer.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :customer_email_address
# The IP address that the customer used when making the purchase.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :customer_purchase_ip
# A description of the product or service that was sold.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :product_description
# The address to which a physical product was shipped. All fields are required for Visa Compelling Evidence 3.0 evidence submission.
sig {
returns(T.nilable(::Stripe::Dispute::UpdateParams::Evidence::EnhancedEvidence::VisaCompellingEvidence3::PriorUndisputedTransaction::ShippingAddress))
}
attr_accessor :shipping_address
sig {
params(charge: String, customer_account_id: T.nilable(T.nilable(String)), customer_device_fingerprint: T.nilable(T.nilable(String)), customer_device_id: T.nilable(T.nilable(String)), customer_email_address: T.nilable(T.nilable(String)), customer_purchase_ip: T.nilable(T.nilable(String)), product_description: T.nilable(T.nilable(String)), shipping_address: T.nilable(::Stripe::Dispute::UpdateParams::Evidence::EnhancedEvidence::VisaCompellingEvidence3::PriorUndisputedTransaction::ShippingAddress)).void
}
def initialize(
charge: nil,
customer_account_id: nil,
customer_device_fingerprint: nil,
customer_device_id: nil,
customer_email_address: nil,
customer_purchase_ip: nil,
product_description: nil,
shipping_address: nil
); end
end
# Disputed transaction details for Visa Compelling Evidence 3.0 evidence submission.
sig {
returns(T.nilable(::Stripe::Dispute::UpdateParams::Evidence::EnhancedEvidence::VisaCompellingEvidence3::DisputedTransaction))
}
attr_accessor :disputed_transaction
# List of exactly two prior undisputed transaction objects for Visa Compelling Evidence 3.0 evidence submission.
sig {
returns(T.nilable(T::Array[::Stripe::Dispute::UpdateParams::Evidence::EnhancedEvidence::VisaCompellingEvidence3::PriorUndisputedTransaction]))
}
attr_accessor :prior_undisputed_transactions
sig {
params(disputed_transaction: T.nilable(::Stripe::Dispute::UpdateParams::Evidence::EnhancedEvidence::VisaCompellingEvidence3::DisputedTransaction), prior_undisputed_transactions: T.nilable(T::Array[::Stripe::Dispute::UpdateParams::Evidence::EnhancedEvidence::VisaCompellingEvidence3::PriorUndisputedTransaction])).void
}
def initialize(disputed_transaction: nil, prior_undisputed_transactions: nil); end
end
class VisaCompliance < Stripe::RequestParams
# A field acknowledging the fee incurred when countering a Visa compliance dispute. If this field is set to true, evidence can be submitted for the compliance dispute. Stripe collects a 500 USD (or local equivalent) amount to cover the network costs associated with resolving compliance disputes. Stripe refunds the 500 USD network fee if you win the dispute.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :fee_acknowledged
sig { params(fee_acknowledged: T.nilable(T::Boolean)).void }
def initialize(fee_acknowledged: nil); end
end
# Evidence provided for Visa Compelling Evidence 3.0 evidence submission.
sig {
returns(T.nilable(::Stripe::Dispute::UpdateParams::Evidence::EnhancedEvidence::VisaCompellingEvidence3))
}
attr_accessor :visa_compelling_evidence_3
# Evidence provided for Visa compliance evidence submission.
sig {
returns(T.nilable(::Stripe::Dispute::UpdateParams::Evidence::EnhancedEvidence::VisaCompliance))
}
attr_accessor :visa_compliance
sig {
params(visa_compelling_evidence_3: T.nilable(::Stripe::Dispute::UpdateParams::Evidence::EnhancedEvidence::VisaCompellingEvidence3), visa_compliance: T.nilable(::Stripe::Dispute::UpdateParams::Evidence::EnhancedEvidence::VisaCompliance)).void
}
def initialize(visa_compelling_evidence_3: nil, visa_compliance: nil); end
end
# Any server or activity logs showing proof that the customer accessed or downloaded the purchased digital product. This information should include IP addresses, corresponding timestamps, and any detailed recorded activity. Has a maximum character count of 20,000.
sig { returns(T.nilable(String)) }
attr_accessor :access_activity_log
# The billing address provided by the customer.
sig { returns(T.nilable(String)) }
attr_accessor :billing_address
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Your subscription cancellation policy, as shown to the customer.
sig { returns(T.nilable(String)) }
attr_accessor :cancellation_policy
# An explanation of how and when the customer was shown your refund policy prior to purchase. Has a maximum character count of 20,000.
sig { returns(T.nilable(String)) }
attr_accessor :cancellation_policy_disclosure
# A justification for why the customer's subscription was not canceled. Has a maximum character count of 20,000.
sig { returns(T.nilable(String)) }
attr_accessor :cancellation_rebuttal
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Any communication with the customer that you feel is relevant to your case. Examples include emails proving that the customer received the product or service, or demonstrating their use of or satisfaction with the product or service.
sig { returns(T.nilable(String)) }
attr_accessor :customer_communication
# The email address of the customer.
sig { returns(T.nilable(String)) }
attr_accessor :customer_email_address
# The name of the customer.
sig { returns(T.nilable(String)) }
attr_accessor :customer_name
# The IP address that the customer used when making the purchase.
sig { returns(T.nilable(String)) }
attr_accessor :customer_purchase_ip
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) A relevant document or contract showing the customer's signature.
sig { returns(T.nilable(String)) }
attr_accessor :customer_signature
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Documentation for the prior charge that can uniquely identify the charge, such as a receipt, shipping label, work order, etc. This document should be paired with a similar document from the disputed payment that proves the two payments are separate.
sig { returns(T.nilable(String)) }
attr_accessor :duplicate_charge_documentation
# An explanation of the difference between the disputed charge versus the prior charge that appears to be a duplicate. Has a maximum character count of 20,000.
sig { returns(T.nilable(String)) }
attr_accessor :duplicate_charge_explanation
# The Stripe ID for the prior charge which appears to be a duplicate of the disputed charge.
sig { returns(T.nilable(String)) }
attr_accessor :duplicate_charge_id
# Additional evidence for qualifying evidence programs.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Dispute::UpdateParams::Evidence::EnhancedEvidence))))
}
attr_accessor :enhanced_evidence
# A description of the product or service that was sold. Has a maximum character count of 20,000.
sig { returns(T.nilable(String)) }
attr_accessor :product_description
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Any receipt or message sent to the customer notifying them of the charge.
sig { returns(T.nilable(String)) }
attr_accessor :receipt
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Your refund policy, as shown to the customer.
sig { returns(T.nilable(String)) }
attr_accessor :refund_policy
# Documentation demonstrating that the customer was shown your refund policy prior to purchase. Has a maximum character count of 20,000.
sig { returns(T.nilable(String)) }
attr_accessor :refund_policy_disclosure
# A justification for why the customer is not entitled to a refund. Has a maximum character count of 20,000.
sig { returns(T.nilable(String)) }
attr_accessor :refund_refusal_explanation
# The date on which the customer received or began receiving the purchased service, in a clear human-readable format.
sig { returns(T.nilable(String)) }
attr_accessor :service_date
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Documentation showing proof that a service was provided to the customer. This could include a copy of a signed contract, work order, or other form of written agreement.
sig { returns(T.nilable(String)) }
attr_accessor :service_documentation
# The address to which a physical product was shipped. You should try to include as complete address information as possible.
sig { returns(T.nilable(String)) }
attr_accessor :shipping_address
# The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc. If multiple carriers were used for this purchase, please separate them with commas.
sig { returns(T.nilable(String)) }
attr_accessor :shipping_carrier
# The date on which a physical product began its route to the shipping address, in a clear human-readable format.
sig { returns(T.nilable(String)) }
attr_accessor :shipping_date
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Documentation showing proof that a product was shipped to the customer at the same address the customer provided to you. This could include a copy of the shipment receipt, shipping label, etc. It should show the customer's full shipping address, if possible.
sig { returns(T.nilable(String)) }
attr_accessor :shipping_documentation
# The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
sig { returns(T.nilable(String)) }
attr_accessor :shipping_tracking_number
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Any additional evidence or statements.
sig { returns(T.nilable(String)) }
attr_accessor :uncategorized_file
# Any additional evidence or statements. Has a maximum character count of 20,000.
sig { returns(T.nilable(String)) }
attr_accessor :uncategorized_text
sig {
params(access_activity_log: T.nilable(String), billing_address: T.nilable(String), cancellation_policy: T.nilable(String), cancellation_policy_disclosure: T.nilable(String), cancellation_rebuttal: T.nilable(String), customer_communication: T.nilable(String), customer_email_address: T.nilable(String), customer_name: T.nilable(String), customer_purchase_ip: T.nilable(String), customer_signature: T.nilable(String), duplicate_charge_documentation: T.nilable(String), duplicate_charge_explanation: T.nilable(String), duplicate_charge_id: T.nilable(String), enhanced_evidence: T.nilable(T.nilable(T.any(String, ::Stripe::Dispute::UpdateParams::Evidence::EnhancedEvidence))), product_description: T.nilable(String), receipt: T.nilable(String), refund_policy: T.nilable(String), refund_policy_disclosure: T.nilable(String), refund_refusal_explanation: T.nilable(String), service_date: T.nilable(String), service_documentation: T.nilable(String), shipping_address: T.nilable(String), shipping_carrier: T.nilable(String), shipping_date: T.nilable(String), shipping_documentation: T.nilable(String), shipping_tracking_number: T.nilable(String), uncategorized_file: T.nilable(String), uncategorized_text: T.nilable(String)).void
}
def initialize(
access_activity_log: nil,
billing_address: nil,
cancellation_policy: nil,
cancellation_policy_disclosure: nil,
cancellation_rebuttal: nil,
customer_communication: nil,
customer_email_address: nil,
customer_name: nil,
customer_purchase_ip: nil,
customer_signature: nil,
duplicate_charge_documentation: nil,
duplicate_charge_explanation: nil,
duplicate_charge_id: nil,
enhanced_evidence: nil,
product_description: nil,
receipt: nil,
refund_policy: nil,
refund_policy_disclosure: nil,
refund_refusal_explanation: nil,
service_date: nil,
service_documentation: nil,
shipping_address: nil,
shipping_carrier: nil,
shipping_date: nil,
shipping_documentation: nil,
shipping_tracking_number: nil,
uncategorized_file: nil,
uncategorized_text: nil
); end
end
# Evidence to upload, to respond to a dispute. Updating any field in the hash will submit all fields in the hash for review. The combined character count of all fields is limited to 150,000.
sig { returns(T.nilable(::Stripe::Dispute::UpdateParams::Evidence)) }
attr_accessor :evidence
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Whether to immediately submit evidence to the bank. If `false`, evidence is staged on the dispute. Staged evidence is visible in the API and Dashboard, and can be submitted to the bank by making another request with this attribute set to `true` (the default).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :submit
sig {
params(evidence: T.nilable(::Stripe::Dispute::UpdateParams::Evidence), expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), submit: T.nilable(T::Boolean)).void
}
def initialize(evidence: nil, expand: nil, metadata: nil, submit: nil); end
end
class CloseParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Closing the dispute for a charge indicates that you do not have any evidence to submit and are essentially dismissing the dispute, acknowledging it as lost.
#
# The status of the dispute will change from needs_response to lost. Closing a dispute is irreversible.
sig {
params(params: T.any(::Stripe::Dispute::CloseParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Dispute)
}
def close(params = {}, opts = {}); end
# Closing the dispute for a charge indicates that you do not have any evidence to submit and are essentially dismissing the dispute, acknowledging it as lost.
#
# The status of the dispute will change from needs_response to lost. Closing a dispute is irreversible.
sig {
params(dispute: String, params: T.any(::Stripe::Dispute::CloseParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Dispute)
}
def self.close(dispute, params = {}, opts = {}); end
# Returns a list of your disputes.
sig {
params(params: T.any(::Stripe::Dispute::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# When you get a dispute, contacting your customer is always the best first step. If that doesn't work, you can submit evidence to help us resolve the dispute in your favor. You can do this in your [dashboard](https://dashboard.stripe.com/disputes), but if you prefer, you can use the API to submit evidence programmatically.
#
# Depending on your dispute type, different evidence fields will give you a better chance of winning your dispute. To figure out which evidence fields to provide, see our [guide to dispute types](https://docs.stripe.com/docs/disputes/categories).
sig {
params(dispute: String, params: T.any(::Stripe::Dispute::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Dispute)
}
def self.update(dispute, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
module Entitlements
# An active entitlement describes access to a feature for a customer.
class ActiveEntitlement < APIResource
# The [Feature](https://stripe.com/docs/api/entitlements/feature) that the customer is entitled to.
sig { returns(T.any(String, Stripe::Entitlements::Feature)) }
attr_reader :feature
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# A unique key you provide as your own system identifier. This may be up to 80 characters.
sig { returns(String) }
attr_reader :lookup_key
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
class ListParams < Stripe::RequestParams
# The ID of the customer.
sig { returns(String) }
attr_accessor :customer
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(customer: String, ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
customer: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil
); end
end
# Retrieve a list of active entitlements for a customer
sig {
params(params: T.any(::Stripe::Entitlements::ActiveEntitlement::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Entitlements
# A summary of a customer's active entitlements.
class ActiveEntitlementSummary < APIResource
# The customer that is entitled to this feature.
sig { returns(String) }
attr_reader :customer
# The list of entitlements this customer has.
sig { returns(Stripe::ListObject) }
attr_reader :entitlements
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
end
end
end
# typed: true
module Stripe
module Entitlements
# A feature represents a monetizable ability or functionality in your system.
# Features can be assigned to products, and when those products are purchased, Stripe will create an entitlement to the feature for the purchasing customer.
class Feature < APIResource
# Inactive features cannot be attached to new products and will not be returned from the features list endpoint.
sig { returns(T::Boolean) }
attr_reader :active
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# A unique key you provide as your own system identifier. This may be up to 80 characters.
sig { returns(String) }
attr_reader :lookup_key
# Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
sig { returns(T::Hash[String, String]) }
attr_reader :metadata
# The feature's name, for your own purpose, not meant to be displayable to the customer.
sig { returns(String) }
attr_reader :name
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
class ListParams < Stripe::RequestParams
# If set, filter results to only include features with the given archive status.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :archived
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# If set, filter results to only include features with the given lookup_key.
sig { returns(T.nilable(String)) }
attr_accessor :lookup_key
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(archived: T.nilable(T::Boolean), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), lookup_key: T.nilable(String), starting_after: T.nilable(String)).void
}
def initialize(
archived: nil,
ending_before: nil,
expand: nil,
limit: nil,
lookup_key: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A unique key you provide as your own system identifier. This may be up to 80 characters.
sig { returns(String) }
attr_accessor :lookup_key
# Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The feature's name, for your own purpose, not meant to be displayable to the customer.
sig { returns(String) }
attr_accessor :name
sig {
params(expand: T.nilable(T::Array[String]), lookup_key: String, metadata: T.nilable(T::Hash[String, String]), name: String).void
}
def initialize(expand: nil, lookup_key: nil, metadata: nil, name: nil); end
end
class UpdateParams < Stripe::RequestParams
# Inactive features cannot be attached to new products and will not be returned from the features list endpoint.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# The feature's name, for your own purpose, not meant to be displayable to the customer.
sig { returns(T.nilable(String)) }
attr_accessor :name
sig {
params(active: T.nilable(T::Boolean), expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), name: T.nilable(String)).void
}
def initialize(active: nil, expand: nil, metadata: nil, name: nil); end
end
# Creates a feature
sig {
params(params: T.any(::Stripe::Entitlements::Feature::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Entitlements::Feature)
}
def self.create(params = {}, opts = {}); end
# Retrieve a list of features
sig {
params(params: T.any(::Stripe::Entitlements::Feature::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Update a feature's metadata or permanently deactivate it.
sig {
params(id: String, params: T.any(::Stripe::Entitlements::Feature::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Entitlements::Feature)
}
def self.update(id, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
class EphemeralKey < APIResource
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# Time at which the key will expire. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :expires
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The key's secret. You can use this value to make authorized requests to the Stripe API.
sig { returns(String) }
attr_reader :secret
class DeleteParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Invalidates a short-lived API key for a given resource.
sig {
params(key: String, params: T.any(::Stripe::EphemeralKey::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::EphemeralKey)
}
def self.delete(key, params = {}, opts = {}); end
# Invalidates a short-lived API key for a given resource.
sig {
params(params: T.any(::Stripe::EphemeralKey::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::EphemeralKey)
}
def delete(params = {}, opts = {}); end
end
end
# typed: true
module Stripe
# Events are our way of letting you know when something interesting happens in
# your account. When an interesting event occurs, we create a new `Event`
# object. For example, when a charge succeeds, we create a `charge.succeeded`
# event, and when an invoice payment attempt fails, we create an
# `invoice.payment_failed` event. Certain API requests might create multiple
# events. For example, if you create a new subscription for a
# customer, you receive both a `customer.subscription.created` event and a
# `charge.succeeded` event.
#
# Events occur when the state of another API resource changes. The event's data
# field embeds the resource's state at the time of the change. For
# example, a `charge.succeeded` event contains a charge, and an
# `invoice.payment_failed` event contains an invoice.
#
# As with other API resources, you can use endpoints to retrieve an
# [individual event](https://stripe.com/docs/api#retrieve_event) or a [list of events](https://stripe.com/docs/api#list_events)
# from the API. We also have a separate
# [webhooks](http://en.wikipedia.org/wiki/Webhook) system for sending the
# `Event` objects directly to an endpoint on your server. You can manage
# webhooks in your
# [account settings](https://dashboard.stripe.com/account/webhooks). Learn how
# to [listen for events](https://docs.stripe.com/webhooks)
# so that your integration can automatically trigger reactions.
#
# When using [Connect](https://docs.stripe.com/connect), you can also receive event notifications
# that occur in connected accounts. For these events, there's an
# additional `account` attribute in the received `Event` object.
#
# We only guarantee access to events through the [Retrieve Event API](https://stripe.com/docs/api#retrieve_event)
# for 30 days.
class Event < APIResource
class Data < Stripe::StripeObject
# Object containing the API resource relevant to the event. For example, an `invoice.created` event will have a full [invoice object](https://stripe.com/docs/api#invoice_object) as the value of the object key.
sig { returns(T::Hash[String, T.untyped]) }
attr_reader :object
# Object containing the names of the updated attributes and their values prior to the event (only included in events of type `*.updated`). If an array attribute has any updated elements, this object contains the entire array. In Stripe API versions 2017-04-06 or earlier, an updated array attribute in this object includes only the updated array elements.
sig { returns(T::Hash[String, T.untyped]) }
attr_reader :previous_attributes
end
class Reason < Stripe::StripeObject
class AutomationAction < Stripe::StripeObject
class StripeSendWebhookCustomEvent < Stripe::StripeObject
# Set of key-value pairs attached to the action when creating an Automation.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :custom_data
end
# Attribute for field stripe_send_webhook_custom_event
sig { returns(StripeSendWebhookCustomEvent) }
attr_reader :stripe_send_webhook_custom_event
# The trigger name of the automation that triggered this action.
# Please visit [Revenue and retention automations](https://docs.stripe.com/billing/automations#choose-a-trigger) for all possible trigger names.
sig { returns(String) }
attr_reader :trigger
# The type of the `automation_action`.
sig { returns(String) }
attr_reader :type
end
class Request < Stripe::StripeObject
# ID of the API request that caused the event. If null, the event was automatic (e.g., Stripe's automatic subscription handling). Request logs are available in the [dashboard](https://dashboard.stripe.com/logs), but currently not in the API.
sig { returns(T.nilable(String)) }
attr_reader :id
# The idempotency key transmitted during the request, if any. *Note: This property is populated only for events on or after May 23, 2017*.
sig { returns(T.nilable(String)) }
attr_reader :idempotency_key
end
# Attribute for field automation_action
sig { returns(AutomationAction) }
attr_reader :automation_action
# Attribute for field request
sig { returns(Request) }
attr_reader :request
# The type of the reason for the event.
sig { returns(String) }
attr_reader :type
end
class Request < Stripe::StripeObject
# ID of the API request that caused the event. If null, the event was automatic (e.g., Stripe's automatic subscription handling). Request logs are available in the [dashboard](https://dashboard.stripe.com/logs), but currently not in the API.
sig { returns(T.nilable(String)) }
attr_reader :id
# The idempotency key transmitted during the request, if any. *Note: This property is populated only for events on or after May 23, 2017*.
sig { returns(T.nilable(String)) }
attr_reader :idempotency_key
end
# The connected account that originates the event.
sig { returns(String) }
attr_reader :account
# The Stripe API version used to render `data`. This property is populated only for events on or after October 31, 2014.
sig { returns(T.nilable(String)) }
attr_reader :api_version
# Authentication context needed to fetch the event or related object.
sig { returns(String) }
attr_reader :context
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# Attribute for field data
sig { returns(Data) }
attr_reader :data
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Number of webhooks that haven't been successfully delivered (for example, to return a 20x response) to the URLs you specify.
sig { returns(Integer) }
attr_reader :pending_webhooks
# Information about the action that causes the event. Only present when the event is triggered by an API request or an [Automation](https://docs.stripe.com/billing/automations) action.
sig { returns(T.nilable(Reason)) }
attr_reader :reason
# Information on the API request that triggers the event.
sig { returns(T.nilable(Request)) }
attr_reader :request
# Description of the event (for example, `invoice.created` or `charge.refunded`).
sig { returns(String) }
attr_reader :type
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return events that were created during the given date interval.
sig { returns(T.nilable(T.any(::Stripe::Event::ListParams::Created, Integer))) }
attr_accessor :created
# Filter events by whether all webhooks were successfully delivered. If false, events which are still pending or have failed all delivery attempts to a webhook endpoint will be returned.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :delivery_success
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# A string containing a specific event name, or group of events using * as a wildcard. The list will be filtered to include only events with a matching event property.
sig { returns(T.nilable(String)) }
attr_accessor :type
# An array of up to 20 strings containing specific event names. The list will be filtered to include only events with a matching event property. You may pass either `type` or `types`, but not both.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :types
sig {
params(created: T.nilable(T.any(::Stripe::Event::ListParams::Created, Integer)), delivery_success: T.nilable(T::Boolean), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String), type: T.nilable(String), types: T.nilable(T::Array[String])).void
}
def initialize(
created: nil,
delivery_success: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil,
type: nil,
types: nil
); end
end
# List events, going back up to 30 days. Each event data is rendered according to Stripe API version at its creation time, specified in [event object](https://docs.stripe.com/api/events/object) api_version attribute (not according to your current Stripe API version or Stripe-Version header).
sig {
params(params: T.any(::Stripe::Event::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
end
end
# typed: true
module Stripe
# `ExchangeRate` objects allow you to determine the rates that Stripe is currently
# using to convert from one currency to another. Since this number is variable
# throughout the day, there are various reasons why you might want to know the current
# rate (for example, to dynamically price an item for a user with a default
# payment in a foreign currency).
#
# Please refer to our [Exchange Rates API](https://stripe.com/docs/fx-rates) guide for more details.
#
# *[Note: this integration path is supported but no longer recommended]* Additionally,
# you can guarantee that a charge is made with an exchange rate that you expect is
# current. To do so, you must pass in the exchange_rate to charges endpoints. If the
# value is no longer up to date, the charge won't go through. Please refer to our
# [Using with charges](https://stripe.com/docs/exchange-rates) guide for more details.
#
# -----
#
#
#
# *This Exchange Rates API is a Beta Service and is subject to Stripe's terms of service. You may use the API solely for the purpose of transacting on Stripe. For example, the API may be queried in order to:*
#
# - *localize prices for processing payments on Stripe*
# - *reconcile Stripe transactions*
# - *determine how much money to send to a connected account*
# - *determine app fees to charge a connected account*
#
# *Using this Exchange Rates API beta for any purpose other than to transact on Stripe is strictly prohibited and constitutes a violation of Stripe's terms of service.*
class ExchangeRate < APIResource
# Unique identifier for the object. Represented as the three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) in lowercase.
sig { returns(String) }
attr_reader :id
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Hash where the keys are supported currencies and the values are the exchange rate at which the base id currency converts to the key currency.
sig { returns(T::Hash[String, Float]) }
attr_reader :rates
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is the currency that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with the exchange rate for currency X your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and total number of supported payout currencies, and the default is the max.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is the currency that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with the exchange rate for currency X, your subsequent call can include `starting_after=X` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
# Returns a list of objects that contain the rates at which foreign currencies are converted to one another. Only shows the currencies for which Stripe supports.
sig {
params(params: T.any(::Stripe::ExchangeRate::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
end
end
# typed: true
module Stripe
# `Application Fee Refund` objects allow you to refund an application fee that
# has previously been created but not yet refunded. Funds will be refunded to
# the Stripe account from which the fee was originally collected.
#
# Related guide: [Refunding application fees](https://stripe.com/docs/connect/destination-charges#refunding-app-fee)
class ApplicationFeeRefund < APIResource
# Amount, in cents (or local equivalent).
sig { returns(Integer) }
attr_reader :amount
# Balance transaction that describes the impact on your account balance.
sig { returns(T.nilable(T.any(String, Stripe::BalanceTransaction))) }
attr_reader :balance_transaction
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# 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).
sig { returns(String) }
attr_reader :currency
# ID of the application fee that was refunded.
sig { returns(T.any(String, Stripe::ApplicationFee)) }
attr_reader :fee
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# 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.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
end
end
# typed: true
module Stripe
# This object represents files hosted on Stripe's servers. You can upload
# files with the [create file](https://stripe.com/docs/api#create_file) request
# (for example, when uploading dispute evidence). Stripe also
# creates files independently (for example, the results of a [Sigma scheduled
# query](https://docs.stripe.com/api#scheduled_queries)).
#
# Related guide: [File upload guide](https://stripe.com/docs/file-upload)
class File < APIResource
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# The file expires and isn't available at this time in epoch seconds.
sig { returns(T.nilable(Integer)) }
attr_reader :expires_at
# The suitable name for saving the file to a filesystem.
sig { returns(T.nilable(String)) }
attr_reader :filename
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# A list of [file links](https://stripe.com/docs/api#file_links) that point at this file.
sig { returns(T.nilable(Stripe::ListObject)) }
attr_reader :links
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The [purpose](https://stripe.com/docs/file-upload#uploading-a-file) of the uploaded file.
sig { returns(String) }
attr_reader :purpose
# The size of the file object in bytes.
sig { returns(Integer) }
attr_reader :size
# A suitable title for the document.
sig { returns(T.nilable(String)) }
attr_reader :title
# The returned file type (for example, `csv`, `pdf`, `jpg`, or `png`).
sig { returns(T.nilable(String)) }
attr_reader :type
# Use your live secret API key to download the file from this URL.
sig { returns(T.nilable(String)) }
attr_reader :url
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return files that were created during the given date interval.
sig { returns(T.nilable(T.any(::Stripe::File::ListParams::Created, Integer))) }
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Filter queries by the file purpose. If you don't provide a purpose, the queries return unfiltered files.
sig { returns(T.nilable(String)) }
attr_accessor :purpose
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(created: T.nilable(T.any(::Stripe::File::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), purpose: T.nilable(String), starting_after: T.nilable(String)).void
}
def initialize(
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
purpose: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class FileLinkData < Stripe::RequestParams
# Set this to `true` to create a file link for the newly created file. Creating a link is only possible when the file's `purpose` is one of the following: `business_icon`, `business_logo`, `customer_signature`, `dispute_evidence`, `issuing_regulatory_reporting`, `pci_document`, `tax_document_user_upload`, or `terminal_reader_splashscreen`.
sig { returns(T::Boolean) }
attr_accessor :create
# The link isn't available after this future timestamp.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_at
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
sig {
params(create: T::Boolean, expires_at: T.nilable(Integer), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String])))).void
}
def initialize(create: nil, expires_at: nil, metadata: nil); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A file to upload. Make sure that the specifications follow RFC 2388, which defines file transfers for the `multipart/form-data` protocol.
sig { returns(T.untyped) }
attr_accessor :file
# Optional parameters that automatically create a [file link](https://stripe.com/docs/api#file_links) for the newly created file.
sig { returns(T.nilable(::Stripe::File::CreateParams::FileLinkData)) }
attr_accessor :file_link_data
# The [purpose](https://stripe.com/docs/file-upload#uploading-a-file) of the uploaded file.
sig { returns(String) }
attr_accessor :purpose
sig {
params(expand: T.nilable(T::Array[String]), file: T.untyped, file_link_data: T.nilable(::Stripe::File::CreateParams::FileLinkData), purpose: String).void
}
def initialize(expand: nil, file: nil, file_link_data: nil, purpose: nil); end
end
# To upload a file to Stripe, you need to send a request of type multipart/form-data. Include the file you want to upload in the request, and the parameters for creating a file.
#
# All of Stripe's officially supported Client libraries support sending multipart/form-data.
sig {
params(params: T.any(::Stripe::File::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::File)
}
def self.create(params = {}, opts = {}); end
# Returns a list of the files that your account has access to. Stripe sorts and returns the files by their creation dates, placing the most recently created files at the top.
sig {
params(params: T.any(::Stripe::File::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
end
end
# typed: true
module Stripe
# To share the contents of a `File` object with non-Stripe users, you can
# create a `FileLink`. `FileLink`s contain a URL that you can use to
# retrieve the contents of the file without authentication.
class FileLink < APIResource
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# Returns if the link is already expired.
sig { returns(T::Boolean) }
attr_reader :expired
# Time that the link expires.
sig { returns(T.nilable(Integer)) }
attr_reader :expires_at
# The file object this link points to.
sig { returns(T.any(String, Stripe::File)) }
attr_reader :file
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# 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.
sig { returns(T::Hash[String, String]) }
attr_reader :metadata
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The publicly accessible URL to download the file.
sig { returns(T.nilable(String)) }
attr_reader :url
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return links that were created during the given date interval.
sig { returns(T.nilable(T.any(::Stripe::FileLink::ListParams::Created, Integer))) }
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Filter links by their expiration status. By default, Stripe returns all links.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :expired
# Only return links for the given file.
sig { returns(T.nilable(String)) }
attr_accessor :file
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(created: T.nilable(T.any(::Stripe::FileLink::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), expired: T.nilable(T::Boolean), file: T.nilable(String), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
created: nil,
ending_before: nil,
expand: nil,
expired: nil,
file: nil,
limit: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The link isn't usable after this future timestamp.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_at
# The ID of the file. The file's `purpose` must be one of the following: `business_icon`, `business_logo`, `customer_signature`, `dispute_evidence`, `finance_report_run`, `financial_account_statement`, `identity_document_downloadable`, `issuing_regulatory_reporting`, `pci_document`, `selfie`, `sigma_scheduled_query`, `tax_document_user_upload`, or `terminal_reader_splashscreen`.
sig { returns(String) }
attr_accessor :file
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
sig {
params(expand: T.nilable(T::Array[String]), expires_at: T.nilable(Integer), file: String, metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String])))).void
}
def initialize(expand: nil, expires_at: nil, file: nil, metadata: nil); end
end
class UpdateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A future timestamp after which the link will no longer be usable, or `now` to expire the link immediately.
sig { returns(T.nilable(T.nilable(T.any(String, T.any(String, Integer))))) }
attr_accessor :expires_at
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
sig {
params(expand: T.nilable(T::Array[String]), expires_at: T.nilable(T.nilable(T.any(String, T.any(String, Integer)))), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String])))).void
}
def initialize(expand: nil, expires_at: nil, metadata: nil); end
end
# Creates a new file link object.
sig {
params(params: T.any(::Stripe::FileLink::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::FileLink)
}
def self.create(params = {}, opts = {}); end
# Returns a list of file links.
sig {
params(params: T.any(::Stripe::FileLink::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Updates an existing file link object. Expired links can no longer be updated.
sig {
params(link: String, params: T.any(::Stripe::FileLink::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::FileLink)
}
def self.update(link, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
module FinancialConnections
# A Financial Connections Account represents an account that exists outside of Stripe, to which you have been granted some degree of access.
class Account < APIResource
class AccountHolder < Stripe::StripeObject
# The ID of the Stripe account this account belongs to. Should only be present if `account_holder.type` is `account`.
sig { returns(T.any(String, Stripe::Account)) }
attr_reader :account
# ID of the Stripe customer this account belongs to. Present if and only if `account_holder.type` is `customer`.
sig { returns(T.any(String, Stripe::Customer)) }
attr_reader :customer
# Attribute for field customer_account
sig { returns(String) }
attr_reader :customer_account
# Type of account holder that this account belongs to.
sig { returns(String) }
attr_reader :type
end
class Balance < Stripe::StripeObject
class Cash < Stripe::StripeObject
# The funds available to the account holder. Typically this is the current balance after subtracting any outbound pending transactions and adding any inbound pending transactions.
#
# Each key is a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase.
#
# Each value is a integer amount. A positive amount indicates money owed to the account holder. A negative amount indicates money owed by the account holder.
sig { returns(T.nilable(T::Hash[String, Integer])) }
attr_reader :available
end
class Credit < Stripe::StripeObject
# The credit that has been used by the account holder.
#
# Each key is a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase.
#
# Each value is a integer amount. A positive amount indicates money owed to the account holder. A negative amount indicates money owed by the account holder.
sig { returns(T.nilable(T::Hash[String, Integer])) }
attr_reader :used
end
# The time that the external institution calculated this balance. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :as_of
# Attribute for field cash
sig { returns(Cash) }
attr_reader :cash
# Attribute for field credit
sig { returns(Credit) }
attr_reader :credit
# The balances owed to (or by) the account holder, before subtracting any outbound pending transactions or adding any inbound pending transactions.
#
# Each key is a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase.
#
# Each value is a integer amount. A positive amount indicates money owed to the account holder. A negative amount indicates money owed by the account holder.
sig { returns(T::Hash[String, Integer]) }
attr_reader :current
# The `type` of the balance. An additional hash is included on the balance with a name matching this value.
sig { returns(String) }
attr_reader :type
end
class BalanceRefresh < Stripe::StripeObject
# The time at which the last refresh attempt was initiated. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :last_attempted_at
# Time at which the next balance refresh can be initiated. This value will be `null` when `status` is `pending`. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_reader :next_refresh_available_at
# The status of the last refresh attempt.
sig { returns(String) }
attr_reader :status
end
class InferredBalancesRefresh < Stripe::StripeObject
# The time at which the last refresh attempt was initiated. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :last_attempted_at
# Time at which the next inferred balance refresh can be initiated. This value will be `null` when `status` is `pending`. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_reader :next_refresh_available_at
# The status of the last refresh attempt.
sig { returns(String) }
attr_reader :status
end
class OwnershipRefresh < Stripe::StripeObject
# The time at which the last refresh attempt was initiated. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :last_attempted_at
# Time at which the next ownership refresh can be initiated. This value will be `null` when `status` is `pending`. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_reader :next_refresh_available_at
# The status of the last refresh attempt.
sig { returns(String) }
attr_reader :status
end
class TransactionRefresh < Stripe::StripeObject
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# The time at which the last refresh attempt was initiated. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :last_attempted_at
# Time at which the next transaction refresh can be initiated. This value will be `null` when `status` is `pending`. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_reader :next_refresh_available_at
# The status of the last refresh attempt.
sig { returns(String) }
attr_reader :status
end
# The account holder that this account belongs to.
sig { returns(T.nilable(AccountHolder)) }
attr_reader :account_holder
# The most recent information about the account's balance.
sig { returns(T.nilable(Balance)) }
attr_reader :balance
# The state of the most recent attempt to refresh the account balance.
sig { returns(T.nilable(BalanceRefresh)) }
attr_reader :balance_refresh
# The type of the account. Account category is further divided in `subcategory`.
sig { returns(String) }
attr_reader :category
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# A human-readable name that has been assigned to this account, either by the account holder or by the institution.
sig { returns(T.nilable(String)) }
attr_reader :display_name
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# The state of the most recent attempt to refresh the account's inferred balance history.
sig { returns(T.nilable(InferredBalancesRefresh)) }
attr_reader :inferred_balances_refresh
# The ID of the Financial Connections Institution this account belongs to. Note that this relationship may sometimes change in rare circumstances (e.g. institution mergers).
sig { returns(T.nilable(T.any(String, Stripe::FinancialConnections::Institution))) }
attr_reader :institution
# The name of the institution that holds this account.
sig { returns(String) }
attr_reader :institution_name
# The last 4 digits of the account number. If present, this will be 4 numeric characters.
sig { returns(T.nilable(String)) }
attr_reader :last4
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The most recent information about the account's owners.
sig { returns(T.nilable(T.any(String, Stripe::FinancialConnections::AccountOwnership))) }
attr_reader :ownership
# The state of the most recent attempt to refresh the account owners.
sig { returns(T.nilable(OwnershipRefresh)) }
attr_reader :ownership_refresh
# The list of permissions granted by this account.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :permissions
# The status of the link to the account.
sig { returns(String) }
attr_reader :status
# If `category` is `cash`, one of:
#
# - `checking`
# - `savings`
# - `other`
#
# If `category` is `credit`, one of:
#
# - `mortgage`
# - `line_of_credit`
# - `credit_card`
# - `other`
#
# If `category` is `investment` or `other`, this will be `other`.
sig { returns(String) }
attr_reader :subcategory
# The list of data refresh subscriptions requested on this account.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :subscriptions
# The [PaymentMethod type](https://stripe.com/docs/api/payment_methods/object#payment_method_object-type)(s) that can be created from this account.
sig { returns(T::Array[String]) }
attr_reader :supported_payment_method_types
# The state of the most recent attempt to refresh the account transactions.
sig { returns(T.nilable(TransactionRefresh)) }
attr_reader :transaction_refresh
class ListParams < Stripe::RequestParams
class AccountHolder < Stripe::RequestParams
# The ID of the Stripe account whose accounts will be retrieved.
sig { returns(T.nilable(String)) }
attr_accessor :account
# The ID of the Stripe customer whose accounts will be retrieved.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# The Account ID of the Stripe customer whose accounts will be retrieved.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
sig {
params(account: T.nilable(String), customer: T.nilable(String), customer_account: T.nilable(String)).void
}
def initialize(account: nil, customer: nil, customer_account: nil); end
end
# If present, only return accounts that belong to the specified account holder. `account_holder[customer]` and `account_holder[account]` are mutually exclusive.
sig {
returns(T.nilable(::Stripe::FinancialConnections::Account::ListParams::AccountHolder))
}
attr_accessor :account_holder
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# If present, only return accounts that were collected as part of the given session.
sig { returns(T.nilable(String)) }
attr_accessor :session
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(account_holder: T.nilable(::Stripe::FinancialConnections::Account::ListParams::AccountHolder), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), session: T.nilable(String), starting_after: T.nilable(String)).void
}
def initialize(
account_holder: nil,
ending_before: nil,
expand: nil,
limit: nil,
session: nil,
starting_after: nil
); end
end
class ListOwnersParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# The ID of the ownership object to fetch owners from.
sig { returns(String) }
attr_accessor :ownership
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), ownership: String, starting_after: T.nilable(String)).void
}
def initialize(
ending_before: nil,
expand: nil,
limit: nil,
ownership: nil,
starting_after: nil
); end
end
class DisconnectParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class RefreshAccountParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The list of account features that you would like to refresh.
sig { returns(T::Array[String]) }
attr_accessor :features
sig { params(expand: T.nilable(T::Array[String]), features: T::Array[String]).void }
def initialize(expand: nil, features: nil); end
end
class SubscribeParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The list of account features to which you would like to subscribe.
sig { returns(T::Array[String]) }
attr_accessor :features
sig { params(expand: T.nilable(T::Array[String]), features: T::Array[String]).void }
def initialize(expand: nil, features: nil); end
end
class UnsubscribeParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The list of account features from which you would like to unsubscribe.
sig { returns(T::Array[String]) }
attr_accessor :features
sig { params(expand: T.nilable(T::Array[String]), features: T::Array[String]).void }
def initialize(expand: nil, features: nil); end
end
# Disables your access to a Financial Connections Account. You will no longer be able to access data associated with the account (e.g. balances, transactions).
sig {
params(params: T.any(::Stripe::FinancialConnections::Account::DisconnectParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::FinancialConnections::Account)
}
def disconnect(params = {}, opts = {}); end
# Disables your access to a Financial Connections Account. You will no longer be able to access data associated with the account (e.g. balances, transactions).
sig {
params(account: String, params: T.any(::Stripe::FinancialConnections::Account::DisconnectParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::FinancialConnections::Account)
}
def self.disconnect(account, params = {}, opts = {}); end
# Returns a list of Financial Connections Account objects.
sig {
params(params: T.any(::Stripe::FinancialConnections::Account::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Lists all owners for a given Account
sig {
params(params: T.any(::Stripe::FinancialConnections::Account::ListOwnersParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list_owners(params = {}, opts = {}); end
# Lists all owners for a given Account
sig {
params(account: String, params: T.any(::Stripe::FinancialConnections::Account::ListOwnersParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list_owners(account, params = {}, opts = {}); end
# Refreshes the data associated with a Financial Connections Account.
sig {
params(params: T.any(::Stripe::FinancialConnections::Account::RefreshAccountParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::FinancialConnections::Account)
}
def refresh_account(params = {}, opts = {}); end
# Refreshes the data associated with a Financial Connections Account.
sig {
params(account: String, params: T.any(::Stripe::FinancialConnections::Account::RefreshAccountParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::FinancialConnections::Account)
}
def self.refresh_account(account, params = {}, opts = {}); end
# Subscribes to periodic refreshes of data associated with a Financial Connections Account.
sig {
params(params: T.any(::Stripe::FinancialConnections::Account::SubscribeParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::FinancialConnections::Account)
}
def subscribe(params = {}, opts = {}); end
# Subscribes to periodic refreshes of data associated with a Financial Connections Account.
sig {
params(account: String, params: T.any(::Stripe::FinancialConnections::Account::SubscribeParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::FinancialConnections::Account)
}
def self.subscribe(account, params = {}, opts = {}); end
# Unsubscribes from periodic refreshes of data associated with a Financial Connections Account.
sig {
params(params: T.any(::Stripe::FinancialConnections::Account::UnsubscribeParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::FinancialConnections::Account)
}
def unsubscribe(params = {}, opts = {}); end
# Unsubscribes from periodic refreshes of data associated with a Financial Connections Account.
sig {
params(account: String, params: T.any(::Stripe::FinancialConnections::Account::UnsubscribeParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::FinancialConnections::Account)
}
def self.unsubscribe(account, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module FinancialConnections
# A historical balance for the account on a particular day. It may be sourced from a balance snapshot provided by a financial institution, or inferred using transactions data.
class AccountInferredBalance < APIResource
# The time for which this balance was calculated, measured in seconds since the Unix epoch. If the balance was computed by Stripe and not provided directly by a financial institution, it will always be 23:59:59 UTC.
sig { returns(Integer) }
attr_reader :as_of
# The balances owed to (or by) the account holder, before subtracting any outbound pending transactions or adding any inbound pending transactions.
#
# Each key is a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase.
#
# Each value is a integer amount. A positive amount indicates money owed to the account holder. A negative amount indicates money owed by the account holder.
sig { returns(T::Hash[String, Integer]) }
attr_reader :current
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
end
end
end
# typed: true
module Stripe
module FinancialConnections
# Describes an owner of an account.
class AccountOwner < StripeObject
# The email address of the owner.
sig { returns(T.nilable(String)) }
attr_reader :email
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# The full name of the owner.
sig { returns(String) }
attr_reader :name
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The ownership object that this owner belongs to.
sig { returns(String) }
attr_reader :ownership
# The raw phone number of the owner.
sig { returns(T.nilable(String)) }
attr_reader :phone
# The raw physical address of the owner.
sig { returns(T.nilable(String)) }
attr_reader :raw_address
# The timestamp of the refresh that updated this owner.
sig { returns(T.nilable(Integer)) }
attr_reader :refreshed_at
end
end
end
# typed: true
module Stripe
module FinancialConnections
# Describes a snapshot of the owners of an account at a particular point in time.
class AccountOwnership < StripeObject
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# A paginated list of owners for this account.
sig { returns(Stripe::ListObject) }
attr_reader :owners
end
end
end
# typed: true
module Stripe
module FinancialConnections
# An institution represents a financial institution to which an end user can connect using the Financial Connections authentication flow.
class Institution < APIResource
class Features < Stripe::StripeObject
class Balances < Stripe::StripeObject
# Whether the given feature is supported by this institution.
sig { returns(T::Boolean) }
attr_reader :supported
end
class Ownership < Stripe::StripeObject
# Whether the given feature is supported by this institution.
sig { returns(T::Boolean) }
attr_reader :supported
end
class PaymentMethod < Stripe::StripeObject
# Whether the given feature is supported by this institution.
sig { returns(T::Boolean) }
attr_reader :supported
end
class Transactions < Stripe::StripeObject
# Whether the given feature is supported by this institution.
sig { returns(T::Boolean) }
attr_reader :supported
end
# Attribute for field balances
sig { returns(Balances) }
attr_reader :balances
# Attribute for field ownership
sig { returns(Ownership) }
attr_reader :ownership
# Attribute for field payment_method
sig { returns(PaymentMethod) }
attr_reader :payment_method
# Attribute for field transactions
sig { returns(Transactions) }
attr_reader :transactions
end
# The list of countries supported by this institution, formatted as ISO country codes.
sig { returns(T::Array[String]) }
attr_reader :countries
# Attribute for field features
sig { returns(Features) }
attr_reader :features
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# The name of this institution.
sig { returns(String) }
attr_reader :name
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# A list of routing numbers which are known to correspond to this institution. Due to the many to many relationship between institutions and routing numbers, this list may not be comprehensive and routing numbers may also be shared between institutions.
sig { returns(T::Array[String]) }
attr_reader :routing_numbers
# The status of this institution in the Financial Connections authentication flow.
sig { returns(String) }
attr_reader :status
# A URL corresponding to this institution. This URL is also displayed in the authentication flow to help end users confirm that they are authenticating with the right institution.
sig { returns(T.nilable(String)) }
attr_reader :url
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
# Returns a list of Financial Connections Institution objects.
sig {
params(params: T.any(::Stripe::FinancialConnections::Institution::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module FinancialConnections
# A Financial Connections Session is the secure way to programmatically launch the client-side Stripe.js modal that lets your users link their accounts.
class Session < APIResource
class AccountHolder < Stripe::StripeObject
# The ID of the Stripe account this account belongs to. Should only be present if `account_holder.type` is `account`.
sig { returns(T.any(String, Stripe::Account)) }
attr_reader :account
# ID of the Stripe customer this account belongs to. Present if and only if `account_holder.type` is `customer`.
sig { returns(T.any(String, Stripe::Customer)) }
attr_reader :customer
# Attribute for field customer_account
sig { returns(String) }
attr_reader :customer_account
# Type of account holder that this account belongs to.
sig { returns(String) }
attr_reader :type
end
class Filters < Stripe::StripeObject
# Restricts the Session to subcategories of accounts that can be linked. Valid subcategories are: `checking`, `savings`, `mortgage`, `line_of_credit`, `credit_card`.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :account_subcategories
# List of countries from which to filter accounts.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :countries
# Stripe ID of the institution with which the customer should be directed to log in.
sig { returns(String) }
attr_reader :institution
end
class Limits < Stripe::StripeObject
# The number of accounts that can be linked in this Session.
sig { returns(Integer) }
attr_reader :accounts
end
class ManualEntry < Stripe::StripeObject; end
class StatusDetails < Stripe::StripeObject
class Cancelled < Stripe::StripeObject
# The reason for the Session being cancelled.
sig { returns(String) }
attr_reader :reason
end
# Attribute for field cancelled
sig { returns(Cancelled) }
attr_reader :cancelled
end
# The account holder for whom accounts are collected in this session.
sig { returns(T.nilable(AccountHolder)) }
attr_reader :account_holder
# The accounts that were collected as part of this Session.
sig { returns(Stripe::ListObject) }
attr_reader :accounts
# A value that will be passed to the client to launch the authentication flow.
sig { returns(String) }
attr_reader :client_secret
# Attribute for field filters
sig { returns(Filters) }
attr_reader :filters
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Attribute for field limits
sig { returns(Limits) }
attr_reader :limits
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# Attribute for field manual_entry
sig { returns(ManualEntry) }
attr_reader :manual_entry
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Permissions requested for accounts collected during this session.
sig { returns(T::Array[String]) }
attr_reader :permissions
# Data features requested to be retrieved upon account creation.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :prefetch
# For webview integrations only. Upon completing OAuth login in the native browser, the user will be redirected to this URL to return to your app.
sig { returns(String) }
attr_reader :return_url
# The current state of the session.
sig { returns(String) }
attr_reader :status
# Attribute for field status_details
sig { returns(StatusDetails) }
attr_reader :status_details
class CreateParams < Stripe::RequestParams
class AccountHolder < Stripe::RequestParams
# The ID of the Stripe account whose accounts will be retrieved. Should only be present if `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# The ID of the Stripe customer whose accounts will be retrieved. Should only be present if `type` is `customer`.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# The ID of the Stripe customer Account whose accounts will be retrieved. Should only be present if `type` is `customer`.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# Type of account holder to collect accounts for.
sig { returns(String) }
attr_accessor :type
sig {
params(account: T.nilable(String), customer: T.nilable(String), customer_account: T.nilable(String), type: String).void
}
def initialize(account: nil, customer: nil, customer_account: nil, type: nil); end
end
class Filters < Stripe::RequestParams
# Restricts the Session to subcategories of accounts that can be linked. Valid subcategories are: `checking`, `savings`, `mortgage`, `line_of_credit`, `credit_card`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :account_subcategories
# List of countries from which to collect accounts.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :countries
# Stripe ID of the institution with which the customer should be directed to log in.
sig { returns(T.nilable(String)) }
attr_accessor :institution
sig {
params(account_subcategories: T.nilable(T::Array[String]), countries: T.nilable(T::Array[String]), institution: T.nilable(String)).void
}
def initialize(account_subcategories: nil, countries: nil, institution: nil); end
end
class Limits < Stripe::RequestParams
# The number of accounts that can be linked in this Session.
sig { returns(Integer) }
attr_accessor :accounts
sig { params(accounts: Integer).void }
def initialize(accounts: nil); end
end
class ManualEntry < Stripe::RequestParams
# Whether manual entry will be handled by Stripe during the Session.
sig { returns(T.nilable(String)) }
attr_accessor :mode
sig { params(mode: T.nilable(String)).void }
def initialize(mode: nil); end
end
# The account holder to link accounts for.
sig { returns(::Stripe::FinancialConnections::Session::CreateParams::AccountHolder) }
attr_accessor :account_holder
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Filters to restrict the kinds of accounts to collect.
sig { returns(T.nilable(::Stripe::FinancialConnections::Session::CreateParams::Filters)) }
attr_accessor :filters
# Settings for configuring Session-specific limits.
sig { returns(T.nilable(::Stripe::FinancialConnections::Session::CreateParams::Limits)) }
attr_accessor :limits
# Customize manual entry behavior
sig {
returns(T.nilable(::Stripe::FinancialConnections::Session::CreateParams::ManualEntry))
}
attr_accessor :manual_entry
# List of data features that you would like to request access to.
#
# Possible values are `balances`, `transactions`, `ownership`, and `payment_method`.
sig { returns(T::Array[String]) }
attr_accessor :permissions
# List of data features that you would like to retrieve upon account creation.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :prefetch
# For webview integrations only. Upon completing OAuth login in the native browser, the user will be redirected to this URL to return to your app.
sig { returns(T.nilable(String)) }
attr_accessor :return_url
sig {
params(account_holder: ::Stripe::FinancialConnections::Session::CreateParams::AccountHolder, expand: T.nilable(T::Array[String]), filters: T.nilable(::Stripe::FinancialConnections::Session::CreateParams::Filters), limits: T.nilable(::Stripe::FinancialConnections::Session::CreateParams::Limits), manual_entry: T.nilable(::Stripe::FinancialConnections::Session::CreateParams::ManualEntry), permissions: T::Array[String], prefetch: T.nilable(T::Array[String]), return_url: T.nilable(String)).void
}
def initialize(
account_holder: nil,
expand: nil,
filters: nil,
limits: nil,
manual_entry: nil,
permissions: nil,
prefetch: nil,
return_url: nil
); end
end
# To launch the Financial Connections authorization flow, create a Session. The session's client_secret can be used to launch the flow using Stripe.js.
sig {
params(params: T.any(::Stripe::FinancialConnections::Session::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::FinancialConnections::Session)
}
def self.create(params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module FinancialConnections
# A Transaction represents a real transaction that affects a Financial Connections Account balance.
class Transaction < APIResource
class StatusTransitions < Stripe::StripeObject
# Time at which this transaction posted. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_reader :posted_at
# Time at which this transaction was voided. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_reader :void_at
end
# The ID of the Financial Connections Account this transaction belongs to.
sig { returns(String) }
attr_reader :account
# The amount of this transaction, in cents (or local equivalent).
sig { returns(Integer) }
attr_reader :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).
sig { returns(String) }
attr_reader :currency
# The description of this transaction.
sig { returns(String) }
attr_reader :description
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The status of the transaction.
sig { returns(String) }
attr_reader :status
# Attribute for field status_transitions
sig { returns(StatusTransitions) }
attr_reader :status_transitions
# Time at which the transaction was transacted. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :transacted_at
# The token of the transaction refresh that last updated or created this transaction.
sig { returns(String) }
attr_reader :transaction_refresh
# Time at which the object was last updated. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :updated
class ListParams < Stripe::RequestParams
class TransactedAt < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
class TransactionRefresh < Stripe::RequestParams
# Return results where the transactions were created or updated by a refresh that took place after this refresh (non-inclusive).
sig { returns(String) }
attr_accessor :after
sig { params(after: String).void }
def initialize(after: nil); end
end
# The ID of the Financial Connections Account whose transactions will be retrieved.
sig { returns(String) }
attr_accessor :account
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# A filter on the list based on the object `transacted_at` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with the following options:
sig {
returns(T.nilable(T.any(::Stripe::FinancialConnections::Transaction::ListParams::TransactedAt, Integer)))
}
attr_accessor :transacted_at
# A filter on the list based on the object `transaction_refresh` field. The value can be a dictionary with the following options:
sig {
returns(T.nilable(::Stripe::FinancialConnections::Transaction::ListParams::TransactionRefresh))
}
attr_accessor :transaction_refresh
sig {
params(account: String, ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String), transacted_at: T.nilable(T.any(::Stripe::FinancialConnections::Transaction::ListParams::TransactedAt, Integer)), transaction_refresh: T.nilable(::Stripe::FinancialConnections::Transaction::ListParams::TransactionRefresh)).void
}
def initialize(
account: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil,
transacted_at: nil,
transaction_refresh: nil
); end
end
# Returns a list of Financial Connections Transaction objects.
sig {
params(params: T.any(::Stripe::FinancialConnections::Transaction::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Forwarding
# Instructs Stripe to make a request on your behalf using the destination URL. The destination URL
# is activated by Stripe at the time of onboarding. Stripe verifies requests with your credentials
# provided during onboarding, and injects card details from the payment_method into the request.
#
# Stripe redacts all sensitive fields and headers, including authentication credentials and card numbers,
# before storing the request and response data in the forwarding Request object, which are subject to a
# 30-day retention period.
#
# You can provide a Stripe idempotency key to make sure that requests with the same key result in only one
# outbound request. The Stripe idempotency key provided should be unique and different from any idempotency
# keys provided on the underlying third-party request.
#
# Forwarding Requests are synchronous requests that return a response or time out according to
# Stripe's limits.
#
# Related guide: [Forward card details to third-party API endpoints](https://docs.stripe.com/payments/forwarding).
class Request < APIResource
class RequestContext < Stripe::StripeObject
# The time it took in milliseconds for the destination endpoint to respond.
sig { returns(Integer) }
attr_reader :destination_duration
# The IP address of the destination.
sig { returns(String) }
attr_reader :destination_ip_address
end
class RequestDetails < Stripe::StripeObject
class Header < Stripe::StripeObject
# The header name.
sig { returns(String) }
attr_reader :name
# The header value.
sig { returns(String) }
attr_reader :value
end
# The body payload to send to the destination endpoint.
sig { returns(String) }
attr_reader :body
# The headers to include in the forwarded request. Can be omitted if no additional headers (excluding Stripe-generated ones such as the Content-Type header) should be included.
sig { returns(T::Array[Header]) }
attr_reader :headers
# The HTTP method used to call the destination endpoint.
sig { returns(String) }
attr_reader :http_method
end
class ResponseDetails < Stripe::StripeObject
class Header < Stripe::StripeObject
# The header name.
sig { returns(String) }
attr_reader :name
# The header value.
sig { returns(String) }
attr_reader :value
end
# The response body from the destination endpoint to Stripe.
sig { returns(String) }
attr_reader :body
# HTTP headers that the destination endpoint returned.
sig { returns(T::Array[Header]) }
attr_reader :headers
# The HTTP status code that the destination endpoint returned.
sig { returns(Integer) }
attr_reader :status
end
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# 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.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The PaymentMethod to insert into the forwarded request. Forwarding previously consumed PaymentMethods is allowed.
sig { returns(String) }
attr_reader :payment_method
# The field kinds to be replaced in the forwarded request.
sig { returns(T::Array[String]) }
attr_reader :replacements
# Context about the request from Stripe's servers to the destination endpoint.
sig { returns(T.nilable(RequestContext)) }
attr_reader :request_context
# The request that was sent to the destination endpoint. We redact any sensitive fields.
sig { returns(T.nilable(RequestDetails)) }
attr_reader :request_details
# The response that the destination endpoint returned to us. We redact any sensitive fields.
sig { returns(T.nilable(ResponseDetails)) }
attr_reader :response_details
# The destination URL for the forwarded request. Must be supported by the config.
sig { returns(T.nilable(String)) }
attr_reader :url
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Return results where the `created` field is greater than this value.
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Return results where the `created` field is greater than or equal to this value.
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Return results where the `created` field is less than this value.
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Return results where the `created` field is less than or equal to this value.
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Similar to other List endpoints, filters results based on created timestamp. You can pass gt, gte, lt, and lte timestamp values.
sig { returns(T.nilable(::Stripe::Forwarding::Request::ListParams::Created)) }
attr_accessor :created
# A pagination cursor to fetch the previous page of the list. The value must be a ForwardingRequest ID.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A pagination cursor to fetch the next page of the list. The value must be a ForwardingRequest ID.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(created: T.nilable(::Stripe::Forwarding::Request::ListParams::Created), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class Request < Stripe::RequestParams
class Header < Stripe::RequestParams
# The header name.
sig { returns(String) }
attr_accessor :name
# The header value.
sig { returns(String) }
attr_accessor :value
sig { params(name: String, value: String).void }
def initialize(name: nil, value: nil); end
end
# The body payload to send to the destination endpoint.
sig { returns(T.nilable(String)) }
attr_accessor :body
# The headers to include in the forwarded request. Can be omitted if no additional headers (excluding Stripe-generated ones such as the Content-Type header) should be included.
sig {
returns(T.nilable(T::Array[::Stripe::Forwarding::Request::CreateParams::Request::Header]))
}
attr_accessor :headers
sig {
params(body: T.nilable(String), headers: T.nilable(T::Array[::Stripe::Forwarding::Request::CreateParams::Request::Header])).void
}
def initialize(body: nil, headers: nil); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The PaymentMethod to insert into the forwarded request. Forwarding previously consumed PaymentMethods is allowed.
sig { returns(String) }
attr_accessor :payment_method
# The field kinds to be replaced in the forwarded request.
sig { returns(T::Array[String]) }
attr_accessor :replacements
# The request body and headers to be sent to the destination endpoint.
sig { returns(::Stripe::Forwarding::Request::CreateParams::Request) }
attr_accessor :request
# The destination URL for the forwarded request. Must be supported by the config.
sig { returns(String) }
attr_accessor :url
sig {
params(expand: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), payment_method: String, replacements: T::Array[String], request: ::Stripe::Forwarding::Request::CreateParams::Request, url: String).void
}
def initialize(
expand: nil,
metadata: nil,
payment_method: nil,
replacements: nil,
request: nil,
url: nil
); end
end
# Creates a ForwardingRequest object.
sig {
params(params: T.any(::Stripe::Forwarding::Request::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Forwarding::Request)
}
def self.create(params = {}, opts = {}); end
# Lists all ForwardingRequest objects.
sig {
params(params: T.any(::Stripe::Forwarding::Request::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
# Each customer has a [`balance`](https://stripe.com/docs/api/customers/object#customer_object-balance) that is
# automatically applied to future invoices and payments using the `customer_balance` payment method.
# Customers can fund this balance by initiating a bank transfer to any account in the
# `financial_addresses` field.
# Related guide: [Customer balance funding instructions](https://stripe.com/docs/payments/customer-balance/funding-instructions)
class FundingInstructions < APIResource
class BankTransfer < Stripe::StripeObject
class FinancialAddress < Stripe::StripeObject
class Aba < Stripe::StripeObject
class AccountHolderAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
class BankAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Attribute for field account_holder_address
sig { returns(AccountHolderAddress) }
attr_reader :account_holder_address
# The account holder name
sig { returns(String) }
attr_reader :account_holder_name
# The ABA account number
sig { returns(String) }
attr_reader :account_number
# The account type
sig { returns(String) }
attr_reader :account_type
# Attribute for field bank_address
sig { returns(BankAddress) }
attr_reader :bank_address
# The bank name
sig { returns(String) }
attr_reader :bank_name
# The ABA routing number
sig { returns(String) }
attr_reader :routing_number
end
class Iban < Stripe::StripeObject
class AccountHolderAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
class BankAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Attribute for field account_holder_address
sig { returns(AccountHolderAddress) }
attr_reader :account_holder_address
# The name of the person or business that owns the bank account
sig { returns(String) }
attr_reader :account_holder_name
# Attribute for field bank_address
sig { returns(BankAddress) }
attr_reader :bank_address
# The BIC/SWIFT code of the account.
sig { returns(String) }
attr_reader :bic
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(String) }
attr_reader :country
# The IBAN of the account.
sig { returns(String) }
attr_reader :iban
end
class SortCode < Stripe::StripeObject
class AccountHolderAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
class BankAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Attribute for field account_holder_address
sig { returns(AccountHolderAddress) }
attr_reader :account_holder_address
# The name of the person or business that owns the bank account
sig { returns(String) }
attr_reader :account_holder_name
# The account number
sig { returns(String) }
attr_reader :account_number
# Attribute for field bank_address
sig { returns(BankAddress) }
attr_reader :bank_address
# The six-digit sort code
sig { returns(String) }
attr_reader :sort_code
end
class Spei < Stripe::StripeObject
class AccountHolderAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
class BankAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Attribute for field account_holder_address
sig { returns(AccountHolderAddress) }
attr_reader :account_holder_address
# The account holder name
sig { returns(String) }
attr_reader :account_holder_name
# Attribute for field bank_address
sig { returns(BankAddress) }
attr_reader :bank_address
# The three-digit bank code
sig { returns(String) }
attr_reader :bank_code
# The short banking institution name
sig { returns(String) }
attr_reader :bank_name
# The CLABE number
sig { returns(String) }
attr_reader :clabe
end
class Swift < Stripe::StripeObject
class AccountHolderAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
class BankAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Attribute for field account_holder_address
sig { returns(AccountHolderAddress) }
attr_reader :account_holder_address
# The account holder name
sig { returns(String) }
attr_reader :account_holder_name
# The account number
sig { returns(String) }
attr_reader :account_number
# The account type
sig { returns(String) }
attr_reader :account_type
# Attribute for field bank_address
sig { returns(BankAddress) }
attr_reader :bank_address
# The bank name
sig { returns(String) }
attr_reader :bank_name
# The SWIFT code
sig { returns(String) }
attr_reader :swift_code
end
class Zengin < Stripe::StripeObject
class AccountHolderAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
class BankAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Attribute for field account_holder_address
sig { returns(AccountHolderAddress) }
attr_reader :account_holder_address
# The account holder name
sig { returns(T.nilable(String)) }
attr_reader :account_holder_name
# The account number
sig { returns(T.nilable(String)) }
attr_reader :account_number
# The bank account type. In Japan, this can only be `futsu` or `toza`.
sig { returns(T.nilable(String)) }
attr_reader :account_type
# Attribute for field bank_address
sig { returns(BankAddress) }
attr_reader :bank_address
# The bank code of the account
sig { returns(T.nilable(String)) }
attr_reader :bank_code
# The bank name of the account
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# The branch code of the account
sig { returns(T.nilable(String)) }
attr_reader :branch_code
# The branch name of the account
sig { returns(T.nilable(String)) }
attr_reader :branch_name
end
# ABA Records contain U.S. bank account details per the ABA format.
sig { returns(Aba) }
attr_reader :aba
# Iban Records contain E.U. bank account details per the SEPA format.
sig { returns(Iban) }
attr_reader :iban
# Sort Code Records contain U.K. bank account details per the sort code format.
sig { returns(SortCode) }
attr_reader :sort_code
# SPEI Records contain Mexico bank account details per the SPEI format.
sig { returns(Spei) }
attr_reader :spei
# The payment networks supported by this FinancialAddress
sig { returns(T::Array[String]) }
attr_reader :supported_networks
# SWIFT Records contain U.S. bank account details per the SWIFT format.
sig { returns(Swift) }
attr_reader :swift
# The type of financial address
sig { returns(String) }
attr_reader :type
# Zengin Records contain Japan bank account details per the Zengin format.
sig { returns(Zengin) }
attr_reader :zengin
end
# The country of the bank account to fund
sig { returns(String) }
attr_reader :country
# A list of financial addresses that can be used to fund a particular balance
sig { returns(T::Array[FinancialAddress]) }
attr_reader :financial_addresses
# The bank_transfer type
sig { returns(String) }
attr_reader :type
end
# Attribute for field bank_transfer
sig { returns(BankTransfer) }
attr_reader :bank_transfer
# 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).
sig { returns(String) }
attr_reader :currency
# The `funding_type` of the returned instructions
sig { returns(String) }
attr_reader :funding_type
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
end
end
# typed: true
module Stripe
# The FX Quotes API provides three key functions:
# - View current exchange rates: The object shows Stripe's current exchange rate for any given currency pair.
# - Extended quotes: The API provides rate quotes valid for a 1-hour period or a 24-hour period, eliminating uncertainty from FX fluctuations.
# - View FX fees: The API provides information on the FX fees Stripe will charge on your FX transaction, allowing you to anticipate specific settlement amounts before payment costs.
class FxQuote < APIResource
class Rates < Stripe::StripeObject
class RateDetails < Stripe::StripeObject
# The rate for the currency pair.
sig { returns(Float) }
attr_reader :base_rate
# The fee for locking the conversion rates.
sig { returns(Float) }
attr_reader :duration_premium
# The FX fee for the currency pair.
sig { returns(Float) }
attr_reader :fx_fee_rate
# A reference rate for the currency pair provided by the reference rate provider.
sig { returns(T.nilable(Float)) }
attr_reader :reference_rate
# The reference rate provider.
sig { returns(T.nilable(String)) }
attr_reader :reference_rate_provider
end
# The rate that includes the FX fee rate.
sig { returns(Float) }
attr_reader :exchange_rate
# Attribute for field rate_details
sig { returns(RateDetails) }
attr_reader :rate_details
end
class Usage < Stripe::StripeObject
class Payment < Stripe::StripeObject
# The Stripe account ID that the funds will be transferred to.
#
# This field should match the account ID that would be used in the PaymentIntent’s transfer_data[destination] field.
sig { returns(T.nilable(String)) }
attr_reader :destination
# The Stripe account ID that these funds are intended for.
#
# This field must match the account ID that would be used in the PaymentIntent’s on_behalf_of field.
sig { returns(T.nilable(String)) }
attr_reader :on_behalf_of
end
class Transfer < Stripe::StripeObject
# The Stripe account ID that the funds will be transferred to.
#
# This field should match the account ID that would be used in the Transfer’s destination field.
sig { returns(String) }
attr_reader :destination
end
# The details required to use an FX Quote for a payment
sig { returns(T.nilable(Payment)) }
attr_reader :payment
# The details required to use an FX Quote for a transfer
sig { returns(T.nilable(Transfer)) }
attr_reader :transfer
# The transaction type for which the FX Quote will be used.
#
# Can be 'payment' or 'transfer'.
sig { returns(String) }
attr_reader :type
end
# Time at which the quote was created, measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# The duration the exchange rate quote remains valid from creation time. Allowed values are none, hour, and day. Note that for the test mode API available in alpha, you can request an extended quote, but it won't be usable for any transactions.
sig { returns(String) }
attr_reader :lock_duration
# Time at which the quote will expire, measured in seconds since the Unix epoch.
#
# If lock_duration is set to ‘none’ this field will be set to null.
sig { returns(T.nilable(Integer)) }
attr_reader :lock_expires_at
# Lock status of the quote. Transitions from active to expired once past the lock_expires_at timestamp.
#
# Can return value none, active, or expired.
sig { returns(String) }
attr_reader :lock_status
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Information about the rates.
sig { returns(T::Hash[String, Rates]) }
attr_reader :rates
# The currency to convert into, typically this is the currency that you want to settle to your Stripe balance. Three-letter ISO currency code, in lowercase. Must be a supported currency.
sig { returns(String) }
attr_reader :to_currency
# Attribute for field usage
sig { returns(Usage) }
attr_reader :usage
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
class CreateParams < Stripe::RequestParams
class Usage < Stripe::RequestParams
class Payment < Stripe::RequestParams
# The Stripe account ID that the funds will be transferred to.
#
# This field should match the account ID that would be used in the PaymentIntent’s transfer_data[destination] field.
sig { returns(T.nilable(String)) }
attr_accessor :destination
# The Stripe account ID that these funds are intended for.
#
# This field should match the account ID that would be used in the PaymentIntent’s on_behalf_of field.
sig { returns(T.nilable(String)) }
attr_accessor :on_behalf_of
sig { params(destination: T.nilable(String), on_behalf_of: T.nilable(String)).void }
def initialize(destination: nil, on_behalf_of: nil); end
end
class Transfer < Stripe::RequestParams
# The Stripe account ID that the funds will be transferred to.
#
# This field should match the account ID that would be used in the Transfer’s destination field.
sig { returns(String) }
attr_accessor :destination
sig { params(destination: String).void }
def initialize(destination: nil); end
end
# The payment transaction details that are intended for the FX Quote.
sig { returns(T.nilable(::Stripe::FxQuote::CreateParams::Usage::Payment)) }
attr_accessor :payment
# The transfer transaction details that are intended for the FX Quote.
sig { returns(T.nilable(::Stripe::FxQuote::CreateParams::Usage::Transfer)) }
attr_accessor :transfer
# Which transaction the FX Quote will be used for
#
# Can be “payment” | “transfer”
sig { returns(String) }
attr_accessor :type
sig {
params(payment: T.nilable(::Stripe::FxQuote::CreateParams::Usage::Payment), transfer: T.nilable(::Stripe::FxQuote::CreateParams::Usage::Transfer), type: String).void
}
def initialize(payment: nil, transfer: nil, type: nil); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A list of three letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be [supported currencies](https://stripe.com/docs/currencies).
sig { returns(T::Array[String]) }
attr_accessor :from_currencies
# The duration that you wish the quote to be locked for. The quote will be usable for the duration specified. The default is `none`. The maximum is 1 day.
sig { returns(String) }
attr_accessor :lock_duration
# 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).
sig { returns(String) }
attr_accessor :to_currency
# The usage specific information for the quote.
sig { returns(T.nilable(::Stripe::FxQuote::CreateParams::Usage)) }
attr_accessor :usage
sig {
params(expand: T.nilable(T::Array[String]), from_currencies: T::Array[String], lock_duration: String, to_currency: String, usage: T.nilable(::Stripe::FxQuote::CreateParams::Usage)).void
}
def initialize(
expand: nil,
from_currencies: nil,
lock_duration: nil,
to_currency: nil,
usage: nil
); end
end
# Creates an FX Quote object
sig {
params(params: T.any(::Stripe::FxQuote::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::FxQuote)
}
def self.create(params = {}, opts = {}); end
# Returns a list of FX quotes that have been issued. The FX quotes are returned in sorted order, with the most recent FX quotes appearing first.
sig {
params(params: T.any(::Stripe::FxQuote::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
end
end
# typed: true
module Stripe
module Identity
# A VerificationReport is the result of an attempt to collect and verify data from a user.
# The collection of verification checks performed is determined from the `type` and `options`
# parameters used. You can find the result of each verification check performed in the
# appropriate sub-resource: `document`, `id_number`, `selfie`.
#
# Each VerificationReport contains a copy of any data collected by the user as well as
# reference IDs which can be used to access collected images through the [FileUpload](https://stripe.com/docs/api/files)
# API. To configure and create VerificationReports, use the
# [VerificationSession](https://stripe.com/docs/api/identity/verification_sessions) API.
#
# Related guide: [Accessing verification results](https://stripe.com/docs/identity/verification-sessions#results).
class VerificationReport < APIResource
class Document < Stripe::StripeObject
class Address < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
class Dob < Stripe::StripeObject
# Numerical day between 1 and 31.
sig { returns(T.nilable(Integer)) }
attr_reader :day
# Numerical month between 1 and 12.
sig { returns(T.nilable(Integer)) }
attr_reader :month
# The four-digit year.
sig { returns(T.nilable(Integer)) }
attr_reader :year
end
class Error < Stripe::StripeObject
# A short machine-readable string giving the reason for the verification failure.
sig { returns(T.nilable(String)) }
attr_reader :code
# A human-readable message giving the reason for the failure. These messages can be shown to your users.
sig { returns(T.nilable(String)) }
attr_reader :reason
end
class ExpirationDate < Stripe::StripeObject
# Numerical day between 1 and 31.
sig { returns(T.nilable(Integer)) }
attr_reader :day
# Numerical month between 1 and 12.
sig { returns(T.nilable(Integer)) }
attr_reader :month
# The four-digit year.
sig { returns(T.nilable(Integer)) }
attr_reader :year
end
class IssuedDate < Stripe::StripeObject
# Numerical day between 1 and 31.
sig { returns(T.nilable(Integer)) }
attr_reader :day
# Numerical month between 1 and 12.
sig { returns(T.nilable(Integer)) }
attr_reader :month
# The four-digit year.
sig { returns(T.nilable(Integer)) }
attr_reader :year
end
# Address as it appears in the document.
sig { returns(T.nilable(Address)) }
attr_reader :address
# Date of birth as it appears in the document.
sig { returns(T.nilable(Dob)) }
attr_reader :dob
# Details on the verification error. Present when status is `unverified`.
sig { returns(T.nilable(Error)) }
attr_reader :error
# Expiration date of the document.
sig { returns(T.nilable(ExpirationDate)) }
attr_reader :expiration_date
# Array of [File](https://stripe.com/docs/api/files) ids containing images for this document.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :files
# First name as it appears in the document.
sig { returns(T.nilable(String)) }
attr_reader :first_name
# Issued date of the document.
sig { returns(T.nilable(IssuedDate)) }
attr_reader :issued_date
# Issuing country of the document.
sig { returns(T.nilable(String)) }
attr_reader :issuing_country
# Last name as it appears in the document.
sig { returns(T.nilable(String)) }
attr_reader :last_name
# Document ID number.
sig { returns(T.nilable(String)) }
attr_reader :number
# Sex of the person in the document.
sig { returns(T.nilable(String)) }
attr_reader :sex
# Status of this `document` check.
sig { returns(String) }
attr_reader :status
# Type of the document.
sig { returns(T.nilable(String)) }
attr_reader :type
# Place of birth as it appears in the document.
sig { returns(T.nilable(String)) }
attr_reader :unparsed_place_of_birth
# Sex as it appears in the document.
sig { returns(T.nilable(String)) }
attr_reader :unparsed_sex
end
class Email < Stripe::StripeObject
class Error < Stripe::StripeObject
# A short machine-readable string giving the reason for the verification failure.
sig { returns(T.nilable(String)) }
attr_reader :code
# A human-readable message giving the reason for the failure. These messages can be shown to your users.
sig { returns(T.nilable(String)) }
attr_reader :reason
end
# Email to be verified.
sig { returns(T.nilable(String)) }
attr_reader :email
# Details on the verification error. Present when status is `unverified`.
sig { returns(T.nilable(Error)) }
attr_reader :error
# Status of this `email` check.
sig { returns(String) }
attr_reader :status
end
class IdNumber < Stripe::StripeObject
class Dob < Stripe::StripeObject
# Numerical day between 1 and 31.
sig { returns(T.nilable(Integer)) }
attr_reader :day
# Numerical month between 1 and 12.
sig { returns(T.nilable(Integer)) }
attr_reader :month
# The four-digit year.
sig { returns(T.nilable(Integer)) }
attr_reader :year
end
class Error < Stripe::StripeObject
# A short machine-readable string giving the reason for the verification failure.
sig { returns(T.nilable(String)) }
attr_reader :code
# A human-readable message giving the reason for the failure. These messages can be shown to your users.
sig { returns(T.nilable(String)) }
attr_reader :reason
end
# Date of birth.
sig { returns(T.nilable(Dob)) }
attr_reader :dob
# Details on the verification error. Present when status is `unverified`.
sig { returns(T.nilable(Error)) }
attr_reader :error
# First name.
sig { returns(T.nilable(String)) }
attr_reader :first_name
# ID number. When `id_number_type` is `us_ssn`, only the last 4 digits are present.
sig { returns(T.nilable(String)) }
attr_reader :id_number
# Type of ID number.
sig { returns(T.nilable(String)) }
attr_reader :id_number_type
# Last name.
sig { returns(T.nilable(String)) }
attr_reader :last_name
# Status of this `id_number` check.
sig { returns(String) }
attr_reader :status
end
class Options < Stripe::StripeObject
class Document < Stripe::StripeObject
# Array of strings of allowed identity document types. If the provided identity document isn’t one of the allowed types, the verification check will fail with a document_type_not_allowed error code.
sig { returns(T::Array[String]) }
attr_reader :allowed_types
# Collect an ID number and perform an [ID number check](https://stripe.com/docs/identity/verification-checks?type=id-number) with the document’s extracted name and date of birth.
sig { returns(T::Boolean) }
attr_reader :require_id_number
# Disable image uploads, identity document images have to be captured using the device’s camera.
sig { returns(T::Boolean) }
attr_reader :require_live_capture
# Capture a face image and perform a [selfie check](https://stripe.com/docs/identity/verification-checks?type=selfie) comparing a photo ID and a picture of your user’s face. [Learn more](https://stripe.com/docs/identity/selfie).
sig { returns(T::Boolean) }
attr_reader :require_matching_selfie
end
class IdNumber < Stripe::StripeObject; end
# Attribute for field document
sig { returns(Document) }
attr_reader :document
# Attribute for field id_number
sig { returns(IdNumber) }
attr_reader :id_number
end
class Phone < Stripe::StripeObject
class Error < Stripe::StripeObject
# A short machine-readable string giving the reason for the verification failure.
sig { returns(T.nilable(String)) }
attr_reader :code
# A human-readable message giving the reason for the failure. These messages can be shown to your users.
sig { returns(T.nilable(String)) }
attr_reader :reason
end
# Details on the verification error. Present when status is `unverified`.
sig { returns(T.nilable(Error)) }
attr_reader :error
# Phone to be verified.
sig { returns(T.nilable(String)) }
attr_reader :phone
# Status of this `phone` check.
sig { returns(String) }
attr_reader :status
end
class Selfie < Stripe::StripeObject
class Error < Stripe::StripeObject
# A short machine-readable string giving the reason for the verification failure.
sig { returns(T.nilable(String)) }
attr_reader :code
# A human-readable message giving the reason for the failure. These messages can be shown to your users.
sig { returns(T.nilable(String)) }
attr_reader :reason
end
# ID of the [File](https://stripe.com/docs/api/files) holding the image of the identity document used in this check.
sig { returns(T.nilable(String)) }
attr_reader :document
# Details on the verification error. Present when status is `unverified`.
sig { returns(T.nilable(Error)) }
attr_reader :error
# ID of the [File](https://stripe.com/docs/api/files) holding the image of the selfie used in this check.
sig { returns(T.nilable(String)) }
attr_reader :selfie
# Status of this `selfie` check.
sig { returns(String) }
attr_reader :status
end
# A string to reference this user. This can be a customer ID, a session ID, or similar, and can be used to reconcile this verification with your internal systems.
sig { returns(T.nilable(String)) }
attr_reader :client_reference_id
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# Result from a document check
sig { returns(Document) }
attr_reader :document
# Result from a email check
sig { returns(Email) }
attr_reader :email
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Result from an id_number check
sig { returns(IdNumber) }
attr_reader :id_number
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Attribute for field options
sig { returns(Options) }
attr_reader :options
# Result from a phone check
sig { returns(Phone) }
attr_reader :phone
# Result from a selfie check
sig { returns(Selfie) }
attr_reader :selfie
# Type of report.
sig { returns(String) }
attr_reader :type
# The configuration token of a verification flow from the dashboard.
sig { returns(String) }
attr_reader :verification_flow
# ID of the VerificationSession that created this report.
sig { returns(T.nilable(String)) }
attr_reader :verification_session
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# A string to reference this user. This can be a customer ID, a session ID, or similar, and can be used to reconcile this verification with your internal systems.
sig { returns(T.nilable(String)) }
attr_accessor :client_reference_id
# Only return VerificationReports that were created during the given date interval.
sig {
returns(T.nilable(T.any(::Stripe::Identity::VerificationReport::ListParams::Created, Integer)))
}
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return VerificationReports of this type
sig { returns(T.nilable(String)) }
attr_accessor :type
# Only return VerificationReports created by this VerificationSession ID. It is allowed to provide a VerificationIntent ID.
sig { returns(T.nilable(String)) }
attr_accessor :verification_session
sig {
params(client_reference_id: T.nilable(String), created: T.nilable(T.any(::Stripe::Identity::VerificationReport::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String), type: T.nilable(String), verification_session: T.nilable(String)).void
}
def initialize(
client_reference_id: nil,
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil,
type: nil,
verification_session: nil
); end
end
# List all verification reports.
sig {
params(params: T.any(::Stripe::Identity::VerificationReport::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Identity
# A VerificationSession guides you through the process of collecting and verifying the identities
# of your users. It contains details about the type of verification, such as what [verification
# check](https://docs.stripe.com/docs/identity/verification-checks) to perform. Only create one VerificationSession for
# each verification in your system.
#
# A VerificationSession transitions through [multiple
# statuses](https://docs.stripe.com/docs/identity/how-sessions-work) throughout its lifetime as it progresses through
# the verification flow. The VerificationSession contains the user's verified data after
# verification checks are complete.
#
# Related guide: [The Verification Sessions API](https://stripe.com/docs/identity/verification-sessions)
class VerificationSession < APIResource
class LastError < Stripe::StripeObject
# A short machine-readable string giving the reason for the verification or user-session failure.
sig { returns(T.nilable(String)) }
attr_reader :code
# A message that explains the reason for verification or user-session failure.
sig { returns(T.nilable(String)) }
attr_reader :reason
end
class Options < Stripe::StripeObject
class Document < Stripe::StripeObject
# Array of strings of allowed identity document types. If the provided identity document isn’t one of the allowed types, the verification check will fail with a document_type_not_allowed error code.
sig { returns(T::Array[String]) }
attr_reader :allowed_types
# Collect an ID number and perform an [ID number check](https://stripe.com/docs/identity/verification-checks?type=id-number) with the document’s extracted name and date of birth.
sig { returns(T::Boolean) }
attr_reader :require_id_number
# Disable image uploads, identity document images have to be captured using the device’s camera.
sig { returns(T::Boolean) }
attr_reader :require_live_capture
# Capture a face image and perform a [selfie check](https://stripe.com/docs/identity/verification-checks?type=selfie) comparing a photo ID and a picture of your user’s face. [Learn more](https://stripe.com/docs/identity/selfie).
sig { returns(T::Boolean) }
attr_reader :require_matching_selfie
end
class Email < Stripe::StripeObject
# Request one time password verification of `provided_details.email`.
sig { returns(T::Boolean) }
attr_reader :require_verification
end
class IdNumber < Stripe::StripeObject; end
class Phone < Stripe::StripeObject
# Request one time password verification of `provided_details.phone`.
sig { returns(T::Boolean) }
attr_reader :require_verification
end
# Attribute for field document
sig { returns(Document) }
attr_reader :document
# Attribute for field email
sig { returns(Email) }
attr_reader :email
# Attribute for field id_number
sig { returns(IdNumber) }
attr_reader :id_number
# Attribute for field phone
sig { returns(Phone) }
attr_reader :phone
end
class ProvidedDetails < Stripe::StripeObject
# Email of user being verified
sig { returns(String) }
attr_reader :email
# Phone number of user being verified
sig { returns(String) }
attr_reader :phone
end
class Redaction < Stripe::StripeObject
# Indicates whether this object and its related objects have been redacted or not.
sig { returns(String) }
attr_reader :status
end
class VerifiedOutputs < Stripe::StripeObject
class Address < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
class Dob < Stripe::StripeObject
# Numerical day between 1 and 31.
sig { returns(T.nilable(Integer)) }
attr_reader :day
# Numerical month between 1 and 12.
sig { returns(T.nilable(Integer)) }
attr_reader :month
# The four-digit year.
sig { returns(T.nilable(Integer)) }
attr_reader :year
end
# The user's verified address.
sig { returns(T.nilable(Address)) }
attr_reader :address
# The user’s verified date of birth.
sig { returns(T.nilable(Dob)) }
attr_reader :dob
# The user's verified email address
sig { returns(T.nilable(String)) }
attr_reader :email
# The user's verified first name.
sig { returns(T.nilable(String)) }
attr_reader :first_name
# The user's verified id number.
sig { returns(T.nilable(String)) }
attr_reader :id_number
# The user's verified id number type.
sig { returns(T.nilable(String)) }
attr_reader :id_number_type
# The user's verified last name.
sig { returns(T.nilable(String)) }
attr_reader :last_name
# The user's verified phone number
sig { returns(T.nilable(String)) }
attr_reader :phone
# The user's verified sex.
sig { returns(T.nilable(String)) }
attr_reader :sex
# The user's verified place of birth as it appears in the document.
sig { returns(T.nilable(String)) }
attr_reader :unparsed_place_of_birth
# The user's verified sex as it appears in the document.
sig { returns(T.nilable(String)) }
attr_reader :unparsed_sex
end
# A string to reference this user. This can be a customer ID, a session ID, or similar, and can be used to reconcile this verification with your internal systems.
sig { returns(T.nilable(String)) }
attr_reader :client_reference_id
# The short-lived client secret used by Stripe.js to [show a verification modal](https://stripe.com/docs/js/identity/modal) inside your app. This client secret expires after 24 hours and can only be used once. Don’t store it, log it, embed it in a URL, or expose it to anyone other than the user. Make sure that you have TLS enabled on any page that includes the client secret. Refer to our docs on [passing the client secret to the frontend](https://stripe.com/docs/identity/verification-sessions#client-secret) to learn more.
sig { returns(T.nilable(String)) }
attr_reader :client_secret
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# If present, this property tells you the last error encountered when processing the verification.
sig { returns(T.nilable(LastError)) }
attr_reader :last_error
# ID of the most recent VerificationReport. [Learn more about accessing detailed verification results.](https://stripe.com/docs/identity/verification-sessions#results)
sig { returns(T.nilable(T.any(String, Stripe::Identity::VerificationReport))) }
attr_reader :last_verification_report
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# 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.
sig { returns(T::Hash[String, String]) }
attr_reader :metadata
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# A set of options for the session’s verification checks.
sig { returns(T.nilable(Options)) }
attr_reader :options
# Details provided about the user being verified. These details may be shown to the user.
sig { returns(T.nilable(ProvidedDetails)) }
attr_reader :provided_details
# Redaction status of this VerificationSession. If the VerificationSession is not redacted, this field will be null.
sig { returns(T.nilable(Redaction)) }
attr_reader :redaction
# Customer ID
sig { returns(T.nilable(String)) }
attr_reader :related_customer
# Token referencing a Customer Account resource.
sig { returns(T.nilable(String)) }
attr_reader :related_customer_account
# Status of this VerificationSession. [Learn more about the lifecycle of sessions](https://stripe.com/docs/identity/how-sessions-work).
sig { returns(String) }
attr_reader :status
# The type of [verification check](https://stripe.com/docs/identity/verification-checks) to be performed.
sig { returns(String) }
attr_reader :type
# The short-lived URL that you use to redirect a user to Stripe to submit their identity information. This URL expires after 48 hours and can only be used once. Don’t store it, log it, send it in emails or expose it to anyone other than the user. Refer to our docs on [verifying identity documents](https://stripe.com/docs/identity/verify-identity-documents?platform=web&type=redirect) to learn how to redirect users to Stripe.
sig { returns(T.nilable(String)) }
attr_reader :url
# The configuration token of a verification flow from the dashboard.
sig { returns(String) }
attr_reader :verification_flow
# The user’s verified data.
sig { returns(T.nilable(VerifiedOutputs)) }
attr_reader :verified_outputs
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# A string to reference this user. This can be a customer ID, a session ID, or similar, and can be used to reconcile this verification with your internal systems.
sig { returns(T.nilable(String)) }
attr_accessor :client_reference_id
# Only return VerificationSessions that were created during the given date interval.
sig {
returns(T.nilable(T.any(::Stripe::Identity::VerificationSession::ListParams::Created, Integer)))
}
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Attribute for param field related_customer
sig { returns(T.nilable(String)) }
attr_accessor :related_customer
# Attribute for param field related_customer_account
sig { returns(T.nilable(String)) }
attr_accessor :related_customer_account
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return VerificationSessions with this status. [Learn more about the lifecycle of sessions](https://stripe.com/docs/identity/how-sessions-work).
sig { returns(T.nilable(String)) }
attr_accessor :status
sig {
params(client_reference_id: T.nilable(String), created: T.nilable(T.any(::Stripe::Identity::VerificationSession::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), related_customer: T.nilable(String), related_customer_account: T.nilable(String), starting_after: T.nilable(String), status: T.nilable(String)).void
}
def initialize(
client_reference_id: nil,
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
related_customer: nil,
related_customer_account: nil,
starting_after: nil,
status: nil
); end
end
class CreateParams < Stripe::RequestParams
class Options < Stripe::RequestParams
class Document < Stripe::RequestParams
# Array of strings of allowed identity document types. If the provided identity document isn’t one of the allowed types, the verification check will fail with a document_type_not_allowed error code.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :allowed_types
# Collect an ID number and perform an [ID number check](https://stripe.com/docs/identity/verification-checks?type=id-number) with the document’s extracted name and date of birth.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :require_id_number
# Disable image uploads, identity document images have to be captured using the device’s camera.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :require_live_capture
# Capture a face image and perform a [selfie check](https://stripe.com/docs/identity/verification-checks?type=selfie) comparing a photo ID and a picture of your user’s face. [Learn more](https://stripe.com/docs/identity/selfie).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :require_matching_selfie
sig {
params(allowed_types: T.nilable(T::Array[String]), require_id_number: T.nilable(T::Boolean), require_live_capture: T.nilable(T::Boolean), require_matching_selfie: T.nilable(T::Boolean)).void
}
def initialize(
allowed_types: nil,
require_id_number: nil,
require_live_capture: nil,
require_matching_selfie: nil
); end
end
# Options that apply to the [document check](https://stripe.com/docs/identity/verification-checks?type=document).
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Identity::VerificationSession::CreateParams::Options::Document))))
}
attr_accessor :document
sig {
params(document: T.nilable(T.nilable(T.any(String, ::Stripe::Identity::VerificationSession::CreateParams::Options::Document)))).void
}
def initialize(document: nil); end
end
class ProvidedDetails < Stripe::RequestParams
# Email of user being verified
sig { returns(T.nilable(String)) }
attr_accessor :email
# Phone number of user being verified
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig { params(email: T.nilable(String), phone: T.nilable(String)).void }
def initialize(email: nil, phone: nil); end
end
# A string to reference this user. This can be a customer ID, a session ID, or similar, and can be used to reconcile this verification with your internal systems.
sig { returns(T.nilable(String)) }
attr_accessor :client_reference_id
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# A set of options for the session’s verification checks.
sig { returns(T.nilable(::Stripe::Identity::VerificationSession::CreateParams::Options)) }
attr_accessor :options
# Details provided about the user being verified. These details may be shown to the user.
sig {
returns(T.nilable(::Stripe::Identity::VerificationSession::CreateParams::ProvidedDetails))
}
attr_accessor :provided_details
# Customer ID
sig { returns(T.nilable(String)) }
attr_accessor :related_customer
# Token referencing a Customer Account resource.
sig { returns(T.nilable(String)) }
attr_accessor :related_customer_account
# The URL that the user will be redirected to upon completing the verification flow.
sig { returns(T.nilable(String)) }
attr_accessor :return_url
# The type of [verification check](https://stripe.com/docs/identity/verification-checks) to be performed. You must provide a `type` if not passing `verification_flow`.
sig { returns(T.nilable(String)) }
attr_accessor :type
# The ID of a verification flow from the Dashboard. See https://docs.stripe.com/identity/verification-flows.
sig { returns(T.nilable(String)) }
attr_accessor :verification_flow
sig {
params(client_reference_id: T.nilable(String), expand: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), options: T.nilable(::Stripe::Identity::VerificationSession::CreateParams::Options), provided_details: T.nilable(::Stripe::Identity::VerificationSession::CreateParams::ProvidedDetails), related_customer: T.nilable(String), related_customer_account: T.nilable(String), return_url: T.nilable(String), type: T.nilable(String), verification_flow: T.nilable(String)).void
}
def initialize(
client_reference_id: nil,
expand: nil,
metadata: nil,
options: nil,
provided_details: nil,
related_customer: nil,
related_customer_account: nil,
return_url: nil,
type: nil,
verification_flow: nil
); end
end
class UpdateParams < Stripe::RequestParams
class Options < Stripe::RequestParams
class Document < Stripe::RequestParams
# Array of strings of allowed identity document types. If the provided identity document isn’t one of the allowed types, the verification check will fail with a document_type_not_allowed error code.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :allowed_types
# Collect an ID number and perform an [ID number check](https://stripe.com/docs/identity/verification-checks?type=id-number) with the document’s extracted name and date of birth.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :require_id_number
# Disable image uploads, identity document images have to be captured using the device’s camera.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :require_live_capture
# Capture a face image and perform a [selfie check](https://stripe.com/docs/identity/verification-checks?type=selfie) comparing a photo ID and a picture of your user’s face. [Learn more](https://stripe.com/docs/identity/selfie).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :require_matching_selfie
sig {
params(allowed_types: T.nilable(T::Array[String]), require_id_number: T.nilable(T::Boolean), require_live_capture: T.nilable(T::Boolean), require_matching_selfie: T.nilable(T::Boolean)).void
}
def initialize(
allowed_types: nil,
require_id_number: nil,
require_live_capture: nil,
require_matching_selfie: nil
); end
end
# Options that apply to the [document check](https://stripe.com/docs/identity/verification-checks?type=document).
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Identity::VerificationSession::UpdateParams::Options::Document))))
}
attr_accessor :document
sig {
params(document: T.nilable(T.nilable(T.any(String, ::Stripe::Identity::VerificationSession::UpdateParams::Options::Document)))).void
}
def initialize(document: nil); end
end
class ProvidedDetails < Stripe::RequestParams
# Email of user being verified
sig { returns(T.nilable(String)) }
attr_accessor :email
# Phone number of user being verified
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig { params(email: T.nilable(String), phone: T.nilable(String)).void }
def initialize(email: nil, phone: nil); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# A set of options for the session’s verification checks.
sig { returns(T.nilable(::Stripe::Identity::VerificationSession::UpdateParams::Options)) }
attr_accessor :options
# Details provided about the user being verified. These details may be shown to the user.
sig {
returns(T.nilable(::Stripe::Identity::VerificationSession::UpdateParams::ProvidedDetails))
}
attr_accessor :provided_details
# The type of [verification check](https://stripe.com/docs/identity/verification-checks) to be performed.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(expand: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), options: T.nilable(::Stripe::Identity::VerificationSession::UpdateParams::Options), provided_details: T.nilable(::Stripe::Identity::VerificationSession::UpdateParams::ProvidedDetails), type: T.nilable(String)).void
}
def initialize(
expand: nil,
metadata: nil,
options: nil,
provided_details: nil,
type: nil
); end
end
class CancelParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class RedactParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# A VerificationSession object can be canceled when it is in requires_input [status](https://docs.stripe.com/docs/identity/how-sessions-work).
#
# Once canceled, future submission attempts are disabled. This cannot be undone. [Learn more](https://docs.stripe.com/docs/identity/verification-sessions#cancel).
sig {
params(params: T.any(::Stripe::Identity::VerificationSession::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Identity::VerificationSession)
}
def cancel(params = {}, opts = {}); end
# A VerificationSession object can be canceled when it is in requires_input [status](https://docs.stripe.com/docs/identity/how-sessions-work).
#
# Once canceled, future submission attempts are disabled. This cannot be undone. [Learn more](https://docs.stripe.com/docs/identity/verification-sessions#cancel).
sig {
params(session: String, params: T.any(::Stripe::Identity::VerificationSession::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Identity::VerificationSession)
}
def self.cancel(session, params = {}, opts = {}); end
# Creates a VerificationSession object.
#
# After the VerificationSession is created, display a verification modal using the session client_secret or send your users to the session's url.
#
# If your API key is in test mode, verification checks won't actually process, though everything else will occur as if in live mode.
#
# Related guide: [Verify your users' identity documents](https://docs.stripe.com/docs/identity/verify-identity-documents)
sig {
params(params: T.any(::Stripe::Identity::VerificationSession::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Identity::VerificationSession)
}
def self.create(params = {}, opts = {}); end
# Returns a list of VerificationSessions
sig {
params(params: T.any(::Stripe::Identity::VerificationSession::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Redact a VerificationSession to remove all collected information from Stripe. This will redact
# the VerificationSession and all objects related to it, including VerificationReports, Events,
# request logs, etc.
#
# A VerificationSession object can be redacted when it is in requires_input or verified
# [status](https://docs.stripe.com/docs/identity/how-sessions-work). Redacting a VerificationSession in requires_action
# state will automatically cancel it.
#
# The redaction process may take up to four days. When the redaction process is in progress, the
# VerificationSession's redaction.status field will be set to processing; when the process is
# finished, it will change to redacted and an identity.verification_session.redacted event
# will be emitted.
#
# Redaction is irreversible. Redacted objects are still accessible in the Stripe API, but all the
# fields that contain personal data will be replaced by the string [redacted] or a similar
# placeholder. The metadata field will also be erased. Redacted objects cannot be updated or
# used for any purpose.
#
# [Learn more](https://docs.stripe.com/docs/identity/verification-sessions#redact).
sig {
params(params: T.any(::Stripe::Identity::VerificationSession::RedactParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Identity::VerificationSession)
}
def redact(params = {}, opts = {}); end
# Redact a VerificationSession to remove all collected information from Stripe. This will redact
# the VerificationSession and all objects related to it, including VerificationReports, Events,
# request logs, etc.
#
# A VerificationSession object can be redacted when it is in requires_input or verified
# [status](https://docs.stripe.com/docs/identity/how-sessions-work). Redacting a VerificationSession in requires_action
# state will automatically cancel it.
#
# The redaction process may take up to four days. When the redaction process is in progress, the
# VerificationSession's redaction.status field will be set to processing; when the process is
# finished, it will change to redacted and an identity.verification_session.redacted event
# will be emitted.
#
# Redaction is irreversible. Redacted objects are still accessible in the Stripe API, but all the
# fields that contain personal data will be replaced by the string [redacted] or a similar
# placeholder. The metadata field will also be erased. Redacted objects cannot be updated or
# used for any purpose.
#
# [Learn more](https://docs.stripe.com/docs/identity/verification-sessions#redact).
sig {
params(session: String, params: T.any(::Stripe::Identity::VerificationSession::RedactParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Identity::VerificationSession)
}
def self.redact(session, params = {}, opts = {}); end
# Updates a VerificationSession object.
#
# When the session status is requires_input, you can use this method to update the
# verification check and options.
sig {
params(session: String, params: T.any(::Stripe::Identity::VerificationSession::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Identity::VerificationSession)
}
def self.update(session, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
# Invoices are statements of amounts owed by a customer, and are either
# generated one-off, or generated periodically from a subscription.
#
# They contain [invoice items](https://stripe.com/docs/api#invoiceitems), and proration adjustments
# that may be caused by subscription upgrades/downgrades (if necessary).
#
# If your invoice is configured to be billed through automatic charges,
# Stripe automatically finalizes your invoice and attempts payment. Note
# that finalizing the invoice,
# [when automatic](https://stripe.com/docs/invoicing/integration/automatic-advancement-collection), does
# not happen immediately as the invoice is created. Stripe waits
# until one hour after the last webhook was successfully sent (or the last
# webhook timed out after failing). If you (and the platforms you may have
# connected to) have no webhooks configured, Stripe waits one hour after
# creation to finalize the invoice.
#
# If your invoice is configured to be billed by sending an email, then based on your
# [email settings](https://dashboard.stripe.com/account/billing/automatic),
# Stripe will email the invoice to your customer and await payment. These
# emails can contain a link to a hosted page to pay the invoice.
#
# Stripe applies any customer credit on the account before determining the
# amount due for the invoice (i.e., the amount that will be actually
# charged). If the amount due for the invoice is less than Stripe's [minimum allowed charge
# per currency](https://docs.stripe.com/docs/currencies#minimum-and-maximum-charge-amounts), the
# invoice is automatically marked paid, and we add the amount due to the
# customer's credit balance which is applied to the next invoice.
#
# More details on the customer's credit balance are
# [here](https://stripe.com/docs/billing/customer/balance).
#
# Related guide: [Send invoices to customers](https://stripe.com/docs/billing/invoices/sending)
class Invoice < APIResource
class AmountsDue < Stripe::StripeObject
# Incremental amount due for this payment in cents (or local equivalent).
sig { returns(Integer) }
attr_reader :amount
# The amount in cents (or local equivalent) that was paid for this payment.
sig { returns(Integer) }
attr_reader :amount_paid
# The difference between the payment’s amount and amount_paid, in cents (or local equivalent).
sig { returns(Integer) }
attr_reader :amount_remaining
# Number of days from when invoice is finalized until the payment is due.
sig { returns(T.nilable(Integer)) }
attr_reader :days_until_due
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_reader :description
# Date on which a payment plan’s payment is due.
sig { returns(T.nilable(Integer)) }
attr_reader :due_date
# Timestamp when the payment was paid.
sig { returns(T.nilable(Integer)) }
attr_reader :paid_at
# The status of the payment, one of `open`, `paid`, or `past_due`
sig { returns(String) }
attr_reader :status
end
class AutomaticTax < Stripe::StripeObject
class Liability < Stripe::StripeObject
# The connected account being referenced when `type` is `account`.
sig { returns(T.any(String, Stripe::Account)) }
attr_reader :account
# Type of the account referenced.
sig { returns(String) }
attr_reader :type
end
# If Stripe disabled automatic tax, this enum describes why.
sig { returns(T.nilable(String)) }
attr_reader :disabled_reason
# 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.
sig { returns(T::Boolean) }
attr_reader :enabled
# The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
sig { returns(T.nilable(Liability)) }
attr_reader :liability
# The tax provider powering automatic tax.
sig { returns(T.nilable(String)) }
attr_reader :provider
# The status of the most recent automated tax calculation for this invoice.
sig { returns(T.nilable(String)) }
attr_reader :status
end
class ConfirmationSecret < Stripe::StripeObject
# The client_secret of the payment that Stripe creates for the invoice after finalization.
sig { returns(String) }
attr_reader :client_secret
# The type of client_secret. Currently this is always payment_intent, referencing the default payment_intent that Stripe creates during invoice finalization
sig { returns(String) }
attr_reader :type
end
class CustomField < Stripe::StripeObject
# The name of the custom field.
sig { returns(String) }
attr_reader :name
# The value of the custom field.
sig { returns(String) }
attr_reader :value
end
class CustomerAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
class CustomerShipping < Stripe::StripeObject
class Address < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Attribute for field address
sig { returns(Address) }
attr_reader :address
# The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
sig { returns(T.nilable(String)) }
attr_reader :carrier
# Recipient name.
sig { returns(String) }
attr_reader :name
# Recipient phone (including extension).
sig { returns(T.nilable(String)) }
attr_reader :phone
# The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
sig { returns(T.nilable(String)) }
attr_reader :tracking_number
end
class CustomerTaxId < Stripe::StripeObject
# The type of the tax ID, one of `ad_nrt`, `ar_cuit`, `eu_vat`, `bo_tin`, `br_cnpj`, `br_cpf`, `cn_tin`, `co_nit`, `cr_tin`, `do_rcn`, `ec_ruc`, `eu_oss_vat`, `hr_oib`, `pe_ruc`, `ro_tin`, `rs_pib`, `sv_nit`, `uy_ruc`, `ve_rif`, `vn_tin`, `gb_vat`, `nz_gst`, `au_abn`, `au_arn`, `in_gst`, `no_vat`, `no_voec`, `za_vat`, `ch_vat`, `mx_rfc`, `sg_uen`, `ru_inn`, `ru_kpp`, `ca_bn`, `hk_br`, `es_cif`, `tw_vat`, `th_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `li_uid`, `li_vat`, `my_itn`, `us_ein`, `kr_brn`, `ca_qst`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `my_sst`, `sg_gst`, `ae_trn`, `cl_tin`, `sa_vat`, `id_npwp`, `my_frp`, `il_vat`, `ge_vat`, `ua_vat`, `is_vat`, `bg_uic`, `hu_tin`, `si_tin`, `ke_pin`, `tr_tin`, `eg_tin`, `ph_tin`, `al_tin`, `bh_vat`, `kz_bin`, `ng_tin`, `om_vat`, `de_stn`, `ch_uid`, `tz_vat`, `uz_vat`, `uz_tin`, `md_vat`, `ma_vat`, `by_tin`, `ao_tin`, `bs_tin`, `bb_tin`, `cd_nif`, `mr_nif`, `me_pib`, `zw_tin`, `ba_tin`, `gn_nif`, `mk_vat`, `sr_fin`, `sn_ninea`, `am_tin`, `np_pan`, `tj_tin`, `ug_tin`, `zm_tin`, `kh_tin`, `aw_tin`, `az_tin`, `bd_bin`, `bj_ifu`, `et_tin`, `kg_tin`, `la_tin`, `cm_niu`, `cv_nif`, `bf_ifu`, or `unknown`
sig { returns(String) }
attr_reader :type
# The value of the tax ID.
sig { returns(T.nilable(String)) }
attr_reader :value
end
class FromInvoice < Stripe::StripeObject
# The relation between this invoice and the cloned invoice
sig { returns(String) }
attr_reader :action
# The invoice that was cloned.
sig { returns(T.any(String, Stripe::Invoice)) }
attr_reader :invoice
end
class Issuer < Stripe::StripeObject
# The connected account being referenced when `type` is `account`.
sig { returns(T.any(String, Stripe::Account)) }
attr_reader :account
# Type of the account referenced.
sig { returns(String) }
attr_reader :type
end
class LastFinalizationError < Stripe::StripeObject
# For card errors resulting from a card issuer decline, a short string indicating [how to proceed with an error](https://stripe.com/docs/declines#retrying-issuer-declines) if they provide one.
sig { returns(String) }
attr_reader :advice_code
# For card errors, the ID of the failed charge.
sig { returns(String) }
attr_reader :charge
# For some errors that could be handled programmatically, a short string indicating the [error code](https://stripe.com/docs/error-codes) reported.
sig { returns(String) }
attr_reader :code
# For card errors resulting from a card issuer decline, a short string indicating the [card issuer's reason for the decline](https://stripe.com/docs/declines#issuer-declines) if they provide one.
sig { returns(String) }
attr_reader :decline_code
# A URL to more information about the [error code](https://stripe.com/docs/error-codes) reported.
sig { returns(String) }
attr_reader :doc_url
# A human-readable message providing more details about the error. For card errors, these messages can be shown to your users.
sig { returns(String) }
attr_reader :message
# For card errors resulting from a card issuer decline, a 2 digit code which indicates the advice given to merchant by the card network on how to proceed with an error.
sig { returns(String) }
attr_reader :network_advice_code
# For card errors resulting from a card issuer decline, a brand specific 2, 3, or 4 digit code which indicates the reason the authorization failed.
sig { returns(String) }
attr_reader :network_decline_code
# If the error is parameter-specific, the parameter related to the error. For example, you can use this to display a message near the correct form field.
sig { returns(String) }
attr_reader :param
# A PaymentIntent guides you through the process of collecting a payment from your customer.
# We recommend that you create exactly one PaymentIntent for each order or
# customer session in your system. You can reference the PaymentIntent later to
# see the history of payment attempts for a particular session.
#
# A PaymentIntent transitions through
# [multiple statuses](https://stripe.com/docs/payments/intents#intent-statuses)
# throughout its lifetime as it interfaces with Stripe.js to perform
# authentication flows and ultimately creates at most one successful charge.
#
# Related guide: [Payment Intents API](https://stripe.com/docs/payments/payment-intents)
sig { returns(Stripe::PaymentIntent) }
attr_reader :payment_intent
# PaymentMethod objects represent your customer's payment instruments.
# You can use them with [PaymentIntents](https://stripe.com/docs/payments/payment-intents) to collect payments or save them to
# Customer objects to store instrument details for future payments.
#
# Related guides: [Payment Methods](https://stripe.com/docs/payments/payment-methods) and [More Payment Scenarios](https://stripe.com/docs/payments/more-payment-scenarios).
sig { returns(Stripe::PaymentMethod) }
attr_reader :payment_method
# If the error is specific to the type of payment method, the payment method type that had a problem. This field is only populated for invoice-related errors.
sig { returns(String) }
attr_reader :payment_method_type
# A URL to the request log entry in your dashboard.
sig { returns(String) }
attr_reader :request_log_url
# A SetupIntent guides you through the process of setting up and saving a customer's payment credentials for future payments.
# For example, you can use a SetupIntent to set up and save your customer's card without immediately collecting a payment.
# Later, you can use [PaymentIntents](https://stripe.com/docs/api#payment_intents) to drive the payment flow.
#
# Create a SetupIntent when you're ready to collect your customer's payment credentials.
# Don't maintain long-lived, unconfirmed SetupIntents because they might not be valid.
# The SetupIntent transitions through multiple [statuses](https://docs.stripe.com/payments/intents#intent-statuses) as it guides
# you through the setup process.
#
# Successful SetupIntents result in payment credentials that are optimized for future payments.
# For example, cardholders in [certain regions](https://stripe.com/guides/strong-customer-authentication) might need to be run through
# [Strong Customer Authentication](https://docs.stripe.com/strong-customer-authentication) during payment method collection
# to streamline later [off-session payments](https://docs.stripe.com/payments/setup-intents).
# If you use the SetupIntent with a [Customer](https://stripe.com/docs/api#setup_intent_object-customer),
# it automatically attaches the resulting payment method to that Customer after successful setup.
# We recommend using SetupIntents or [setup_future_usage](https://stripe.com/docs/api#payment_intent_object-setup_future_usage) on
# PaymentIntents to save payment methods to prevent saving invalid or unoptimized payment methods.
#
# By using SetupIntents, you can reduce friction for your customers, even as regulations change over time.
#
# Related guide: [Setup Intents API](https://docs.stripe.com/payments/setup-intents)
sig { returns(Stripe::SetupIntent) }
attr_reader :setup_intent
# Attribute for field source
sig { returns(T.any(Stripe::Account, Stripe::BankAccount, Stripe::Card, Stripe::Source)) }
attr_reader :source
# The type of error returned. One of `api_error`, `card_error`, `idempotency_error`, or `invalid_request_error`
sig { returns(String) }
attr_reader :type
end
class Parent < Stripe::StripeObject
class QuoteDetails < Stripe::StripeObject
# The quote that generated this invoice
sig { returns(String) }
attr_reader :quote
end
class SubscriptionDetails < Stripe::StripeObject
class PauseCollection < Stripe::StripeObject
# The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`.
sig { returns(T.nilable(String)) }
attr_reader :behavior
# The time after which the subscription will resume collecting payments.
sig { returns(T.nilable(Integer)) }
attr_reader :resumes_at
end
# Set of [key-value pairs](https://stripe.com/docs/api/metadata) defined as subscription metadata when an invoice is created. Becomes an immutable snapshot of the subscription metadata at the time of invoice finalization.
# *Note: This attribute is populated only for invoices created on or after June 29, 2023.*
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# If specified, payment collection for this subscription will be paused. Note that the subscription status will be unchanged and will not be updated to `paused`. Learn more about [pausing collection](https://stripe.com/docs/billing/subscriptions/pause-payment).
sig { returns(T.nilable(PauseCollection)) }
attr_reader :pause_collection
# The subscription that generated this invoice
sig { returns(T.any(String, Stripe::Subscription)) }
attr_reader :subscription
# Only set for upcoming invoices that preview prorations. The time used to calculate prorations.
sig { returns(Integer) }
attr_reader :subscription_proration_date
end
# Details about the quote that generated this invoice
sig { returns(T.nilable(QuoteDetails)) }
attr_reader :quote_details
# Details about the subscription that generated this invoice
sig { returns(T.nilable(SubscriptionDetails)) }
attr_reader :subscription_details
# The type of parent that generated this invoice
sig { returns(String) }
attr_reader :type
end
class PaymentSettings < Stripe::StripeObject
class PaymentMethodOptions < Stripe::StripeObject
class AcssDebit < Stripe::StripeObject
class MandateOptions < Stripe::StripeObject
# Transaction type of the mandate.
sig { returns(T.nilable(String)) }
attr_reader :transaction_type
end
# Attribute for field mandate_options
sig { returns(MandateOptions) }
attr_reader :mandate_options
# Bank account verification method.
sig { returns(String) }
attr_reader :verification_method
end
class Bancontact < Stripe::StripeObject
# Preferred language of the Bancontact authorization page that the customer is redirected to.
sig { returns(String) }
attr_reader :preferred_language
end
class Card < Stripe::StripeObject
class Installments < Stripe::StripeObject
# Whether Installments are enabled for this Invoice.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :enabled
end
# Attribute for field installments
sig { returns(Installments) }
attr_reader :installments
# We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
sig { returns(T.nilable(String)) }
attr_reader :request_three_d_secure
end
class CustomerBalance < Stripe::StripeObject
class BankTransfer < Stripe::StripeObject
class EuBankTransfer < Stripe::StripeObject
# The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
sig { returns(String) }
attr_reader :country
end
# Attribute for field eu_bank_transfer
sig { returns(EuBankTransfer) }
attr_reader :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`, `mx_bank_transfer`, or `us_bank_transfer`.
sig { returns(T.nilable(String)) }
attr_reader :type
end
# Attribute for field bank_transfer
sig { returns(BankTransfer) }
attr_reader :bank_transfer
# The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
sig { returns(T.nilable(String)) }
attr_reader :funding_type
end
class IdBankTransfer < Stripe::StripeObject; end
class Konbini < Stripe::StripeObject; end
class SepaDebit < Stripe::StripeObject; end
class UsBankAccount < Stripe::StripeObject
class FinancialConnections < Stripe::StripeObject
class Filters < Stripe::StripeObject
# The account subcategories to use to filter for possible accounts to link. Valid subcategories are `checking` and `savings`.
sig { returns(T::Array[String]) }
attr_reader :account_subcategories
# The institution to use to filter for possible accounts to link.
sig { returns(String) }
attr_reader :institution
end
# Attribute for field filters
sig { returns(Filters) }
attr_reader :filters
# The list of permissions to request. The `payment_method` permission must be included.
sig { returns(T::Array[String]) }
attr_reader :permissions
# Data features requested to be retrieved upon account creation.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :prefetch
end
# Attribute for field financial_connections
sig { returns(FinancialConnections) }
attr_reader :financial_connections
# Bank account verification method.
sig { returns(String) }
attr_reader :verification_method
end
# If paying by `acss_debit`, this sub-hash contains details about the Canadian pre-authorized debit payment method options to pass to the invoice’s PaymentIntent.
sig { returns(T.nilable(AcssDebit)) }
attr_reader :acss_debit
# If paying by `bancontact`, this sub-hash contains details about the Bancontact payment method options to pass to the invoice’s PaymentIntent.
sig { returns(T.nilable(Bancontact)) }
attr_reader :bancontact
# If paying by `card`, this sub-hash contains details about the Card payment method options to pass to the invoice’s PaymentIntent.
sig { returns(T.nilable(Card)) }
attr_reader :card
# If paying by `customer_balance`, this sub-hash contains details about the Bank transfer payment method options to pass to the invoice’s PaymentIntent.
sig { returns(T.nilable(CustomerBalance)) }
attr_reader :customer_balance
# If paying by `id_bank_transfer`, this sub-hash contains details about the Indonesia bank transfer payment method options to pass to the invoice’s PaymentIntent.
sig { returns(T.nilable(IdBankTransfer)) }
attr_reader :id_bank_transfer
# If paying by `konbini`, this sub-hash contains details about the Konbini payment method options to pass to the invoice’s PaymentIntent.
sig { returns(T.nilable(Konbini)) }
attr_reader :konbini
# If paying by `sepa_debit`, this sub-hash contains details about the SEPA Direct Debit payment method options to pass to the invoice’s PaymentIntent.
sig { returns(T.nilable(SepaDebit)) }
attr_reader :sepa_debit
# If paying by `us_bank_account`, this sub-hash contains details about the ACH direct debit payment method options to pass to the invoice’s PaymentIntent.
sig { returns(T.nilable(UsBankAccount)) }
attr_reader :us_bank_account
end
# ID of the mandate to be used for this invoice. It must correspond to the payment method used to pay the invoice, including the invoice's default_payment_method or default_source, if set.
sig { returns(T.nilable(String)) }
attr_reader :default_mandate
# Payment-method-specific configuration to provide to the invoice’s PaymentIntent.
sig { returns(T.nilable(PaymentMethodOptions)) }
attr_reader :payment_method_options
# The list of payment method types (e.g. card) to provide to the invoice’s PaymentIntent. If not set, Stripe attempts to automatically determine the types to use by looking at the invoice’s default payment method, the subscription’s default payment method, the customer’s default payment method, and your [invoice template settings](https://dashboard.stripe.com/settings/billing/invoice).
sig { returns(T.nilable(T::Array[String])) }
attr_reader :payment_method_types
end
class Rendering < Stripe::StripeObject
class Pdf < Stripe::StripeObject
# Page size of invoice pdf. Options include a4, letter, and auto. If set to auto, page size will be switched to a4 or letter based on customer locale.
sig { returns(T.nilable(String)) }
attr_reader :page_size
end
# How line-item prices and amounts will be displayed with respect to tax on invoice PDFs.
sig { returns(T.nilable(String)) }
attr_reader :amount_tax_display
# Invoice pdf rendering options
sig { returns(T.nilable(Pdf)) }
attr_reader :pdf
# ID of the rendering template that the invoice is formatted by.
sig { returns(T.nilable(String)) }
attr_reader :template
# Version of the rendering template that the invoice is using.
sig { returns(T.nilable(Integer)) }
attr_reader :template_version
end
class ShippingCost < Stripe::StripeObject
class Tax < Stripe::StripeObject
# Amount of tax applied for this rate.
sig { returns(Integer) }
attr_reader :amount
# Tax rates can be applied to [invoices](/invoicing/taxes/tax-rates), [subscriptions](/billing/taxes/tax-rates) and [Checkout Sessions](/payments/checkout/use-manual-tax-rates) to collect tax.
#
# Related guide: [Tax rates](/billing/taxes/tax-rates)
sig { returns(Stripe::TaxRate) }
attr_reader :rate
# 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.
sig { returns(T.nilable(String)) }
attr_reader :taxability_reason
# The amount on which tax is calculated, in cents (or local equivalent).
sig { returns(T.nilable(Integer)) }
attr_reader :taxable_amount
end
# Total shipping cost before any taxes are applied.
sig { returns(Integer) }
attr_reader :amount_subtotal
# Total tax amount applied due to shipping costs. If no tax was applied, defaults to 0.
sig { returns(Integer) }
attr_reader :amount_tax
# Total shipping cost after taxes are applied.
sig { returns(Integer) }
attr_reader :amount_total
# The ID of the ShippingRate for this invoice.
sig { returns(T.nilable(T.any(String, Stripe::ShippingRate))) }
attr_reader :shipping_rate
# The taxes applied to the shipping rate.
sig { returns(T::Array[Tax]) }
attr_reader :taxes
end
class ShippingDetails < Stripe::StripeObject
class Address < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Attribute for field address
sig { returns(Address) }
attr_reader :address
# The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
sig { returns(T.nilable(String)) }
attr_reader :carrier
# Recipient name.
sig { returns(String) }
attr_reader :name
# Recipient phone (including extension).
sig { returns(T.nilable(String)) }
attr_reader :phone
# The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
sig { returns(T.nilable(String)) }
attr_reader :tracking_number
end
class StatusTransitions < Stripe::StripeObject
# The time that the invoice draft was finalized.
sig { returns(T.nilable(Integer)) }
attr_reader :finalized_at
# The time that the invoice was marked uncollectible.
sig { returns(T.nilable(Integer)) }
attr_reader :marked_uncollectible_at
# The time that the invoice was paid.
sig { returns(T.nilable(Integer)) }
attr_reader :paid_at
# The time that the invoice was voided.
sig { returns(T.nilable(Integer)) }
attr_reader :voided_at
end
class ThresholdReason < Stripe::StripeObject
class ItemReason < Stripe::StripeObject
# The IDs of the line items that triggered the threshold invoice.
sig { returns(T::Array[String]) }
attr_reader :line_item_ids
# The quantity threshold boundary that applied to the given line item.
sig { returns(Integer) }
attr_reader :usage_gte
end
# The total invoice amount threshold boundary if it triggered the threshold invoice.
sig { returns(T.nilable(Integer)) }
attr_reader :amount_gte
# Indicates which line items triggered a threshold invoice.
sig { returns(T::Array[ItemReason]) }
attr_reader :item_reasons
end
class TotalDiscountAmount < Stripe::StripeObject
# The amount, in cents (or local equivalent), of the discount.
sig { returns(Integer) }
attr_reader :amount
# The discount that was applied to get this discount amount.
sig { returns(T.any(String, Stripe::Discount)) }
attr_reader :discount
end
class TotalMarginAmount < Stripe::StripeObject
# The amount, in cents (or local equivalent), of the reduction in line item amount.
sig { returns(Integer) }
attr_reader :amount
# The margin that was applied to get this margin amount.
sig { returns(T.any(String, Stripe::Margin)) }
attr_reader :margin
end
class TotalPretaxCreditAmount < Stripe::StripeObject
# The amount, in cents (or local equivalent), of the pretax credit amount.
sig { returns(Integer) }
attr_reader :amount
# The credit balance transaction that was applied to get this pretax credit amount.
sig { returns(T.nilable(T.any(String, Stripe::Billing::CreditBalanceTransaction))) }
attr_reader :credit_balance_transaction
# The discount that was applied to get this pretax credit amount.
sig { returns(T.any(String, Stripe::Discount)) }
attr_reader :discount
# The margin that was applied to get this pretax credit amount.
sig { returns(T.any(String, Stripe::Margin)) }
attr_reader :margin
# Type of the pretax credit amount referenced.
sig { returns(String) }
attr_reader :type
end
class TotalTax < Stripe::StripeObject
class TaxRateDetails < Stripe::StripeObject
# Attribute for field tax_rate
sig { returns(String) }
attr_reader :tax_rate
end
# The amount of the tax, in cents (or local equivalent).
sig { returns(Integer) }
attr_reader :amount
# Whether this tax is inclusive or exclusive.
sig { returns(String) }
attr_reader :tax_behavior
# Additional details about the tax rate. Only present when `type` is `tax_rate_details`.
sig { returns(T.nilable(TaxRateDetails)) }
attr_reader :tax_rate_details
# 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.
sig { returns(String) }
attr_reader :taxability_reason
# The amount on which tax is calculated, in cents (or local equivalent).
sig { returns(T.nilable(Integer)) }
attr_reader :taxable_amount
# The type of tax information.
sig { returns(String) }
attr_reader :type
end
# The country of the business associated with this invoice, most often the business creating the invoice.
sig { returns(T.nilable(String)) }
attr_reader :account_country
# The public name of the business associated with this invoice, most often the business creating the invoice.
sig { returns(T.nilable(String)) }
attr_reader :account_name
# The account tax IDs associated with the invoice. Only editable when the invoice is a draft.
sig { returns(T.nilable(T::Array[T.any(String, Stripe::TaxId)])) }
attr_reader :account_tax_ids
# Final amount due at this time for this invoice. If the invoice's total is smaller than the minimum charge amount, for example, or if there is account credit that can be applied to the invoice, the `amount_due` may be 0. If there is a positive `starting_balance` for the invoice (the customer owes money), the `amount_due` will also take that into account. The charge that gets generated for the invoice will be for the amount specified in `amount_due`.
sig { returns(Integer) }
attr_reader :amount_due
# Amount that was overpaid on the invoice. The amount overpaid is credited to the customer's credit balance.
sig { returns(Integer) }
attr_reader :amount_overpaid
# The amount, in cents (or local equivalent), that was paid.
sig { returns(Integer) }
attr_reader :amount_paid
# The difference between amount_due and amount_paid, in cents (or local equivalent).
sig { returns(Integer) }
attr_reader :amount_remaining
# This is the sum of all the shipping amounts.
sig { returns(Integer) }
attr_reader :amount_shipping
# List of expected payments and corresponding due dates. This value will be null for invoices where collection_method=charge_automatically.
sig { returns(T.nilable(T::Array[AmountsDue])) }
attr_reader :amounts_due
# ID of the Connect Application that created the invoice.
sig { returns(T.nilable(T.any(String, Stripe::Application))) }
attr_reader :application
# Number of payment attempts made for this invoice, from the perspective of the payment retry schedule. Any payment attempt counts as the first attempt, and subsequently only automatic retries increment the attempt count. In other words, manual payment attempts after the first attempt do not affect the retry schedule. If a failure is returned with a non-retryable return code, the invoice can no longer be retried unless a new payment method is obtained. Retries will continue to be scheduled, and attempt_count will continue to increment, but retries will only be executed if a new payment method is obtained.
sig { returns(Integer) }
attr_reader :attempt_count
# Whether an attempt has been made to pay the invoice. An invoice is not attempted until 1 hour after the `invoice.created` webhook, for example, so you might not want to display that invoice as unpaid to your users.
sig { returns(T::Boolean) }
attr_reader :attempted
# Controls whether Stripe performs [automatic collection](https://stripe.com/docs/invoicing/integration/automatic-advancement-collection) of the invoice. If `false`, the invoice's state doesn't automatically advance without an explicit action.
sig { returns(T::Boolean) }
attr_reader :auto_advance
# Attribute for field automatic_tax
sig { returns(AutomaticTax) }
attr_reader :automatic_tax
# The time when this invoice is currently scheduled to be automatically finalized. The field will be `null` if the invoice is not scheduled to finalize in the future. If the invoice is not in the draft state, this field will always be `null` - see `finalized_at` for the time when an already-finalized invoice was finalized.
sig { returns(T.nilable(Integer)) }
attr_reader :automatically_finalizes_at
# Indicates the reason why the invoice was created.
#
# * `manual`: Unrelated to a subscription, for example, created via the invoice editor.
# * `subscription`: No longer in use. Applies to subscriptions from before May 2018 where no distinction was made between updates, cycles, and thresholds.
# * `subscription_create`: A new subscription was created.
# * `subscription_cycle`: A subscription advanced into a new period.
# * `subscription_threshold`: A subscription reached a billing threshold.
# * `subscription_update`: A subscription was updated.
# * `upcoming`: Reserved for simulated invoices, per the upcoming invoice endpoint.
sig { returns(T.nilable(String)) }
attr_reader :billing_reason
# 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.
sig { returns(String) }
attr_reader :collection_method
# The confirmation secret associated with this invoice. Currently, this contains the client_secret of the PaymentIntent that Stripe creates during invoice finalization.
sig { returns(T.nilable(ConfirmationSecret)) }
attr_reader :confirmation_secret
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# 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).
sig { returns(String) }
attr_reader :currency
# Custom fields displayed on the invoice.
sig { returns(T.nilable(T::Array[CustomField])) }
attr_reader :custom_fields
# The ID of the customer who will be billed.
sig { returns(T.nilable(T.any(String, Stripe::Customer))) }
attr_reader :customer
# The ID of the account who will be billed.
sig { returns(T.nilable(String)) }
attr_reader :customer_account
# The customer's address. Until the invoice is finalized, this field will equal `customer.address`. Once the invoice is finalized, this field will no longer be updated.
sig { returns(T.nilable(CustomerAddress)) }
attr_reader :customer_address
# The customer's email. Until the invoice is finalized, this field will equal `customer.email`. Once the invoice is finalized, this field will no longer be updated.
sig { returns(T.nilable(String)) }
attr_reader :customer_email
# The customer's name. Until the invoice is finalized, this field will equal `customer.name`. Once the invoice is finalized, this field will no longer be updated.
sig { returns(T.nilable(String)) }
attr_reader :customer_name
# The customer's phone number. Until the invoice is finalized, this field will equal `customer.phone`. Once the invoice is finalized, this field will no longer be updated.
sig { returns(T.nilable(String)) }
attr_reader :customer_phone
# The customer's shipping information. Until the invoice is finalized, this field will equal `customer.shipping`. Once the invoice is finalized, this field will no longer be updated.
sig { returns(T.nilable(CustomerShipping)) }
attr_reader :customer_shipping
# The customer's tax exempt status. Until the invoice is finalized, this field will equal `customer.tax_exempt`. Once the invoice is finalized, this field will no longer be updated.
sig { returns(T.nilable(String)) }
attr_reader :customer_tax_exempt
# The customer's tax IDs. Until the invoice is finalized, this field will contain the same tax IDs as `customer.tax_ids`. Once the invoice is finalized, this field will no longer be updated.
sig { returns(T.nilable(T::Array[CustomerTaxId])) }
attr_reader :customer_tax_ids
# The margins applied to the invoice. Can be overridden by line item `margins`. Use `expand[]=default_margins` to expand each margin.
sig { returns(T.nilable(T::Array[T.any(String, Stripe::Margin)])) }
attr_reader :default_margins
# 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.
sig { returns(T.nilable(T.any(String, Stripe::PaymentMethod))) }
attr_reader :default_payment_method
# ID of the default payment source for the invoice. It must belong to the customer associated with the invoice and be in a chargeable state. If not set, defaults to the subscription's default source, if any, or to the customer's default source.
sig {
returns(T.nilable(T.any(String, T.any(Stripe::Account, Stripe::BankAccount, Stripe::Card, Stripe::Source))))
}
attr_reader :default_source
# The tax rates applied to this invoice, if any.
sig { returns(T::Array[Stripe::TaxRate]) }
attr_reader :default_tax_rates
# An arbitrary string attached to the object. Often useful for displaying to users. Referenced as 'memo' in the Dashboard.
sig { returns(T.nilable(String)) }
attr_reader :description
# The discounts applied to the invoice. Line item discounts are applied before invoice discounts. Use `expand[]=discounts` to expand each discount.
sig { returns(T::Array[T.any(String, Stripe::Discount)]) }
attr_reader :discounts
# The date on which payment for this invoice is due. This value will be `null` for invoices where `collection_method=charge_automatically`.
sig { returns(T.nilable(Integer)) }
attr_reader :due_date
# The date when this invoice is in effect. Same as `finalized_at` unless overwritten. When defined, this value replaces the system-generated 'Date of issue' printed on the invoice PDF and receipt.
sig { returns(T.nilable(Integer)) }
attr_reader :effective_at
# Ending customer balance after the invoice is finalized. Invoices are finalized approximately an hour after successful webhook delivery or when payment collection is attempted for the invoice. If the invoice has not been finalized yet, this will be null.
sig { returns(T.nilable(Integer)) }
attr_reader :ending_balance
# Footer displayed on the invoice.
sig { returns(T.nilable(String)) }
attr_reader :footer
# Details of the invoice that was cloned. See the [revision documentation](https://stripe.com/docs/invoicing/invoice-revisions) for more details.
sig { returns(T.nilable(FromInvoice)) }
attr_reader :from_invoice
# The URL for the hosted invoice page, which allows customers to view and pay an invoice. If the invoice has not been finalized yet, this will be null.
sig { returns(T.nilable(String)) }
attr_reader :hosted_invoice_url
# Unique identifier for the object. For preview invoices created using the [create preview](https://stripe.com/docs/api/invoices/create_preview) endpoint, this id will be prefixed with `upcoming_in`.
sig { returns(String) }
attr_reader :id
# The link to download the PDF for the invoice. If the invoice has not been finalized yet, this will be null.
sig { returns(T.nilable(String)) }
attr_reader :invoice_pdf
# Attribute for field issuer
sig { returns(Issuer) }
attr_reader :issuer
# The error encountered during the previous attempt to finalize the invoice. This field is cleared when the invoice is successfully finalized.
sig { returns(T.nilable(LastFinalizationError)) }
attr_reader :last_finalization_error
# The ID of the most recent non-draft revision of this invoice
sig { returns(T.nilable(T.any(String, Stripe::Invoice))) }
attr_reader :latest_revision
# The individual line items that make up the invoice. `lines` is sorted as follows: (1) pending invoice items (including prorations) in reverse chronological order, (2) subscription items in reverse chronological order, and (3) invoice items added after invoice creation in chronological order.
sig { returns(Stripe::ListObject) }
attr_reader :lines
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# 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.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# The time at which payment will next be attempted. This value will be `null` for invoices where `collection_method=send_invoice`.
sig { returns(T.nilable(Integer)) }
attr_reader :next_payment_attempt
# A unique, identifying string that appears on emails sent to the customer for this invoice. This starts with the customer's unique invoice_prefix if it is specified.
sig { returns(T.nilable(String)) }
attr_reader :number
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The account (if any) for which the funds of the invoice payment are intended. If set, the invoice will be presented with the branding and support information of the specified account. See the [Invoices with Connect](https://stripe.com/docs/billing/invoices/connect) documentation for details.
sig { returns(T.nilable(T.any(String, Stripe::Account))) }
attr_reader :on_behalf_of
# The parent that generated this invoice
sig { returns(T.nilable(Parent)) }
attr_reader :parent
# Attribute for field payment_settings
sig { returns(PaymentSettings) }
attr_reader :payment_settings
# Payments for this invoice
sig { returns(Stripe::ListObject) }
attr_reader :payments
# End of the usage period during which invoice items were added to this invoice. This looks back one period for a subscription invoice. Use the [line item period](/api/invoices/line_item#invoice_line_item_object-period) to get the service period for each price.
sig { returns(Integer) }
attr_reader :period_end
# Start of the usage period during which invoice items were added to this invoice. This looks back one period for a subscription invoice. Use the [line item period](/api/invoices/line_item#invoice_line_item_object-period) to get the service period for each price.
sig { returns(Integer) }
attr_reader :period_start
# Total amount of all post-payment credit notes issued for this invoice.
sig { returns(Integer) }
attr_reader :post_payment_credit_notes_amount
# Total amount of all pre-payment credit notes issued for this invoice.
sig { returns(Integer) }
attr_reader :pre_payment_credit_notes_amount
# This is the transaction number that appears on email receipts sent for this invoice.
sig { returns(T.nilable(String)) }
attr_reader :receipt_number
# The rendering-related settings that control how the invoice is displayed on customer-facing surfaces such as PDF and Hosted Invoice Page.
sig { returns(T.nilable(Rendering)) }
attr_reader :rendering
# The details of the cost of shipping, including the ShippingRate applied on the invoice.
sig { returns(T.nilable(ShippingCost)) }
attr_reader :shipping_cost
# Shipping details for the invoice. The Invoice PDF will use the `shipping_details` value if it is set, otherwise the PDF will render the shipping address from the customer.
sig { returns(T.nilable(ShippingDetails)) }
attr_reader :shipping_details
# Starting customer balance before the invoice is finalized. If the invoice has not been finalized yet, this will be the current customer balance. For revision invoices, this also includes any customer balance that was applied to the original invoice.
sig { returns(Integer) }
attr_reader :starting_balance
# Extra information about an invoice for the customer's credit card statement.
sig { returns(T.nilable(String)) }
attr_reader :statement_descriptor
# The status of the invoice, one of `draft`, `open`, `paid`, `uncollectible`, or `void`. [Learn more](https://stripe.com/docs/billing/invoices/workflow#workflow-overview)
sig { returns(T.nilable(String)) }
attr_reader :status
# Attribute for field status_transitions
sig { returns(StatusTransitions) }
attr_reader :status_transitions
# 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
sig { returns(Integer) }
attr_reader :subtotal
# The integer amount in cents (or local equivalent) representing the subtotal of the invoice before any invoice level discount or tax is applied. Item discounts are already incorporated
sig { returns(T.nilable(Integer)) }
attr_reader :subtotal_excluding_tax
# ID of the test clock this invoice belongs to.
sig { returns(T.nilable(T.any(String, Stripe::TestHelpers::TestClock))) }
attr_reader :test_clock
# Attribute for field threshold_reason
sig { returns(ThresholdReason) }
attr_reader :threshold_reason
# Total after discounts and taxes.
sig { returns(Integer) }
attr_reader :total
# The aggregate amounts calculated per discount across all line items.
sig { returns(T.nilable(T::Array[TotalDiscountAmount])) }
attr_reader :total_discount_amounts
# The integer amount in cents (or local equivalent) representing the total amount of the invoice including all discounts but excluding all tax.
sig { returns(T.nilable(Integer)) }
attr_reader :total_excluding_tax
# The aggregate amounts calculated per margin across all line items.
sig { returns(T.nilable(T::Array[TotalMarginAmount])) }
attr_reader :total_margin_amounts
# Contains pretax credit amounts (ex: discount, credit grants, etc) that apply to this invoice. This is a combined list of total_pretax_credit_amounts across all invoice line items.
sig { returns(T.nilable(T::Array[TotalPretaxCreditAmount])) }
attr_reader :total_pretax_credit_amounts
# The aggregate tax information of all line items.
sig { returns(T.nilable(T::Array[TotalTax])) }
attr_reader :total_taxes
# Invoices are automatically paid or sent 1 hour after webhooks are delivered, or until all webhook delivery attempts have [been exhausted](https://stripe.com/docs/billing/webhooks#understand). This field tracks the time when webhooks for this invoice were successfully delivered. If the invoice had no webhooks to deliver, this will be set while the invoice is being created.
sig { returns(T.nilable(Integer)) }
attr_reader :webhooks_delivered_at
# Always true for a deleted object
sig { returns(T::Boolean) }
attr_reader :deleted
class DeleteParams < Stripe::RequestParams; end
class UpdateParams < Stripe::RequestParams
class AmountsDue < Stripe::RequestParams
# The amount in cents (or local equivalent).
sig { returns(Integer) }
attr_accessor :amount
# Number of days from when invoice is finalized until the payment is due.
sig { returns(T.nilable(Integer)) }
attr_accessor :days_until_due
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(String) }
attr_accessor :description
# Date on which a payment plan’s payment is due.
sig { returns(T.nilable(Integer)) }
attr_accessor :due_date
sig {
params(amount: Integer, days_until_due: T.nilable(Integer), description: String, due_date: T.nilable(Integer)).void
}
def initialize(amount: nil, days_until_due: nil, description: nil, due_date: nil); end
end
class AutomaticTax < Stripe::RequestParams
class Liability < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# 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.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
sig { returns(T.nilable(::Stripe::Invoice::UpdateParams::AutomaticTax::Liability)) }
attr_accessor :liability
sig {
params(enabled: T::Boolean, liability: T.nilable(::Stripe::Invoice::UpdateParams::AutomaticTax::Liability)).void
}
def initialize(enabled: nil, liability: nil); end
end
class CustomField < Stripe::RequestParams
# The name of the custom field. This may be up to 40 characters.
sig { returns(String) }
attr_accessor :name
# The value of the custom field. This may be up to 140 characters.
sig { returns(String) }
attr_accessor :value
sig { params(name: String, value: String).void }
def initialize(name: nil, value: nil); end
end
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::Invoice::UpdateParams::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::Invoice::UpdateParams::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig { returns(T.nilable(::Stripe::Invoice::UpdateParams::Discount::DiscountEnd)) }
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::Invoice::UpdateParams::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class Issuer < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
class PaymentSettings < Stripe::RequestParams
class PaymentMethodOptions < Stripe::RequestParams
class AcssDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Transaction type of the mandate.
sig { returns(T.nilable(String)) }
attr_accessor :transaction_type
sig { params(transaction_type: T.nilable(String)).void }
def initialize(transaction_type: nil); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::Invoice::UpdateParams::PaymentSettings::PaymentMethodOptions::AcssDebit::MandateOptions))
}
attr_accessor :mandate_options
# Verification method for the intent
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(mandate_options: T.nilable(::Stripe::Invoice::UpdateParams::PaymentSettings::PaymentMethodOptions::AcssDebit::MandateOptions), verification_method: T.nilable(String)).void
}
def initialize(mandate_options: nil, verification_method: nil); end
end
class Bancontact < Stripe::RequestParams
# Preferred language of the Bancontact authorization page that the customer is redirected to.
sig { returns(T.nilable(String)) }
attr_accessor :preferred_language
sig { params(preferred_language: T.nilable(String)).void }
def initialize(preferred_language: nil); end
end
class Card < Stripe::RequestParams
class Installments < Stripe::RequestParams
class Plan < Stripe::RequestParams
# For `fixed_count` installment plans, this is required. It represents the number of installment payments your customer will make to their credit card.
sig { returns(T.nilable(Integer)) }
attr_accessor :count
# For `fixed_count` installment plans, this is required. It represents the interval between installment payments your customer will make to their credit card.
# One of `month`.
sig { returns(T.nilable(String)) }
attr_accessor :interval
# Type of installment plan, one of `fixed_count`.
sig { returns(String) }
attr_accessor :type
sig {
params(count: T.nilable(Integer), interval: T.nilable(String), type: String).void
}
def initialize(count: nil, interval: nil, type: nil); end
end
# Setting to true enables installments for this invoice.
# Setting to false will prevent any selected plan from applying to a payment.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :enabled
# The selected installment plan to use for this invoice.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::UpdateParams::PaymentSettings::PaymentMethodOptions::Card::Installments::Plan))))
}
attr_accessor :plan
sig {
params(enabled: T.nilable(T::Boolean), plan: T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::UpdateParams::PaymentSettings::PaymentMethodOptions::Card::Installments::Plan)))).void
}
def initialize(enabled: nil, plan: nil); end
end
# Installment configuration for payments attempted on this invoice (Mexico Only).
#
# For more information, see the [installments integration guide](https://stripe.com/docs/payments/installments).
sig {
returns(T.nilable(::Stripe::Invoice::UpdateParams::PaymentSettings::PaymentMethodOptions::Card::Installments))
}
attr_accessor :installments
# We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
sig { returns(T.nilable(String)) }
attr_accessor :request_three_d_secure
sig {
params(installments: T.nilable(::Stripe::Invoice::UpdateParams::PaymentSettings::PaymentMethodOptions::Card::Installments), request_three_d_secure: T.nilable(String)).void
}
def initialize(installments: nil, request_three_d_secure: nil); end
end
class CustomerBalance < Stripe::RequestParams
class BankTransfer < Stripe::RequestParams
class EuBankTransfer < Stripe::RequestParams
# The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
sig { returns(String) }
attr_accessor :country
sig { params(country: String).void }
def initialize(country: nil); end
end
# Configuration for eu_bank_transfer funding type.
sig {
returns(T.nilable(::Stripe::Invoice::UpdateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance::BankTransfer::EuBankTransfer))
}
attr_accessor :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`, `mx_bank_transfer`, or `us_bank_transfer`.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(eu_bank_transfer: T.nilable(::Stripe::Invoice::UpdateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance::BankTransfer::EuBankTransfer), type: T.nilable(String)).void
}
def initialize(eu_bank_transfer: nil, type: nil); end
end
# Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
sig {
returns(T.nilable(::Stripe::Invoice::UpdateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance::BankTransfer))
}
attr_accessor :bank_transfer
# The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
sig { returns(T.nilable(String)) }
attr_accessor :funding_type
sig {
params(bank_transfer: T.nilable(::Stripe::Invoice::UpdateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance::BankTransfer), funding_type: T.nilable(String)).void
}
def initialize(bank_transfer: nil, funding_type: nil); end
end
class IdBankTransfer < Stripe::RequestParams; end
class Konbini < Stripe::RequestParams; end
class SepaDebit < Stripe::RequestParams; end
class UsBankAccount < Stripe::RequestParams
class FinancialConnections < Stripe::RequestParams
class Filters < Stripe::RequestParams
# The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :account_subcategories
# ID of the institution to use to filter for selectable accounts.
sig { returns(T.nilable(String)) }
attr_accessor :institution
sig {
params(account_subcategories: T.nilable(T::Array[String]), institution: T.nilable(String)).void
}
def initialize(account_subcategories: nil, institution: nil); end
end
# Provide filters for the linked accounts that the customer can select for the payment method.
sig {
returns(T.nilable(::Stripe::Invoice::UpdateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount::FinancialConnections::Filters))
}
attr_accessor :filters
# The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :permissions
# List of data features that you would like to retrieve upon account creation.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :prefetch
sig {
params(filters: T.nilable(::Stripe::Invoice::UpdateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount::FinancialConnections::Filters), permissions: T.nilable(T::Array[String]), prefetch: T.nilable(T::Array[String])).void
}
def initialize(filters: nil, permissions: nil, prefetch: nil); end
end
# Additional fields for Financial Connections Session creation
sig {
returns(T.nilable(::Stripe::Invoice::UpdateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount::FinancialConnections))
}
attr_accessor :financial_connections
# Verification method for the intent
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(financial_connections: T.nilable(::Stripe::Invoice::UpdateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount::FinancialConnections), verification_method: T.nilable(String)).void
}
def initialize(financial_connections: nil, verification_method: nil); end
end
# If paying by `acss_debit`, this sub-hash contains details about the Canadian pre-authorized debit payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::UpdateParams::PaymentSettings::PaymentMethodOptions::AcssDebit))))
}
attr_accessor :acss_debit
# If paying by `bancontact`, this sub-hash contains details about the Bancontact payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::UpdateParams::PaymentSettings::PaymentMethodOptions::Bancontact))))
}
attr_accessor :bancontact
# If paying by `card`, this sub-hash contains details about the Card payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::UpdateParams::PaymentSettings::PaymentMethodOptions::Card))))
}
attr_accessor :card
# If paying by `customer_balance`, this sub-hash contains details about the Bank transfer payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::UpdateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance))))
}
attr_accessor :customer_balance
# If paying by `id_bank_transfer`, this sub-hash contains details about the Indonesia bank transfer payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::UpdateParams::PaymentSettings::PaymentMethodOptions::IdBankTransfer))))
}
attr_accessor :id_bank_transfer
# If paying by `konbini`, this sub-hash contains details about the Konbini payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::UpdateParams::PaymentSettings::PaymentMethodOptions::Konbini))))
}
attr_accessor :konbini
# If paying by `sepa_debit`, this sub-hash contains details about the SEPA Direct Debit payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::UpdateParams::PaymentSettings::PaymentMethodOptions::SepaDebit))))
}
attr_accessor :sepa_debit
# If paying by `us_bank_account`, this sub-hash contains details about the ACH direct debit payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::UpdateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount))))
}
attr_accessor :us_bank_account
sig {
params(acss_debit: T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::UpdateParams::PaymentSettings::PaymentMethodOptions::AcssDebit))), bancontact: T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::UpdateParams::PaymentSettings::PaymentMethodOptions::Bancontact))), card: T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::UpdateParams::PaymentSettings::PaymentMethodOptions::Card))), customer_balance: T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::UpdateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance))), id_bank_transfer: T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::UpdateParams::PaymentSettings::PaymentMethodOptions::IdBankTransfer))), konbini: T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::UpdateParams::PaymentSettings::PaymentMethodOptions::Konbini))), sepa_debit: T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::UpdateParams::PaymentSettings::PaymentMethodOptions::SepaDebit))), us_bank_account: T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::UpdateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount)))).void
}
def initialize(
acss_debit: nil,
bancontact: nil,
card: nil,
customer_balance: nil,
id_bank_transfer: nil,
konbini: nil,
sepa_debit: nil,
us_bank_account: nil
); end
end
# ID of the mandate to be used for this invoice. It must correspond to the payment method used to pay the invoice, including the invoice's default_payment_method or default_source, if set.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :default_mandate
# Payment-method-specific configuration to provide to the invoice’s PaymentIntent.
sig {
returns(T.nilable(::Stripe::Invoice::UpdateParams::PaymentSettings::PaymentMethodOptions))
}
attr_accessor :payment_method_options
# The list of payment method types (e.g. card) to provide to the invoice’s PaymentIntent. If not set, Stripe attempts to automatically determine the types to use by looking at the invoice’s default payment method, the subscription’s default payment method, the customer’s default payment method, and your [invoice template settings](https://dashboard.stripe.com/settings/billing/invoice). Should not be specified with payment_method_configuration
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :payment_method_types
sig {
params(default_mandate: T.nilable(T.nilable(String)), payment_method_options: T.nilable(::Stripe::Invoice::UpdateParams::PaymentSettings::PaymentMethodOptions), payment_method_types: T.nilable(T.nilable(T.any(String, T::Array[String])))).void
}
def initialize(
default_mandate: nil,
payment_method_options: nil,
payment_method_types: nil
); end
end
class Rendering < Stripe::RequestParams
class Pdf < Stripe::RequestParams
# Page size for invoice PDF. Can be set to `a4`, `letter`, or `auto`.
# If set to `auto`, invoice PDF page size defaults to `a4` for customers with
# Japanese locale and `letter` for customers with other locales.
sig { returns(T.nilable(String)) }
attr_accessor :page_size
sig { params(page_size: T.nilable(String)).void }
def initialize(page_size: nil); end
end
# How line-item prices and amounts will be displayed with respect to tax on invoice PDFs. One of `exclude_tax` or `include_inclusive_tax`. `include_inclusive_tax` will include inclusive tax (and exclude exclusive tax) in invoice PDF amounts. `exclude_tax` will exclude all tax (inclusive and exclusive alike) from invoice PDF amounts.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :amount_tax_display
# Invoice pdf rendering options
sig { returns(T.nilable(::Stripe::Invoice::UpdateParams::Rendering::Pdf)) }
attr_accessor :pdf
# ID of the invoice rendering template to use for this invoice.
sig { returns(T.nilable(String)) }
attr_accessor :template
# The specific version of invoice rendering template to use for this invoice.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :template_version
sig {
params(amount_tax_display: T.nilable(T.nilable(T.any(String, String))), pdf: T.nilable(::Stripe::Invoice::UpdateParams::Rendering::Pdf), template: T.nilable(String), template_version: T.nilable(T.nilable(T.any(String, Integer)))).void
}
def initialize(amount_tax_display: nil, pdf: nil, template: nil, template_version: nil); end
end
class ShippingCost < Stripe::RequestParams
class ShippingRateData < Stripe::RequestParams
class DeliveryEstimate < Stripe::RequestParams
class Maximum < Stripe::RequestParams
# A unit of time.
sig { returns(String) }
attr_accessor :unit
# Must be greater than 0.
sig { returns(Integer) }
attr_accessor :value
sig { params(unit: String, value: Integer).void }
def initialize(unit: nil, value: nil); end
end
class Minimum < Stripe::RequestParams
# A unit of time.
sig { returns(String) }
attr_accessor :unit
# Must be greater than 0.
sig { returns(Integer) }
attr_accessor :value
sig { params(unit: String, value: Integer).void }
def initialize(unit: nil, value: nil); end
end
# The upper bound of the estimated range. If empty, represents no upper bound i.e., infinite.
sig {
returns(T.nilable(::Stripe::Invoice::UpdateParams::ShippingCost::ShippingRateData::DeliveryEstimate::Maximum))
}
attr_accessor :maximum
# The lower bound of the estimated range. If empty, represents no lower bound.
sig {
returns(T.nilable(::Stripe::Invoice::UpdateParams::ShippingCost::ShippingRateData::DeliveryEstimate::Minimum))
}
attr_accessor :minimum
sig {
params(maximum: T.nilable(::Stripe::Invoice::UpdateParams::ShippingCost::ShippingRateData::DeliveryEstimate::Maximum), minimum: T.nilable(::Stripe::Invoice::UpdateParams::ShippingCost::ShippingRateData::DeliveryEstimate::Minimum)).void
}
def initialize(maximum: nil, minimum: nil); end
end
class FixedAmount < Stripe::RequestParams
class CurrencyOptions < Stripe::RequestParams
# A non-negative integer in cents representing how much to charge.
sig { returns(Integer) }
attr_accessor :amount
# Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
sig { params(amount: Integer, tax_behavior: T.nilable(String)).void }
def initialize(amount: nil, tax_behavior: nil); end
end
# A non-negative integer in cents representing how much to charge.
sig { returns(Integer) }
attr_accessor :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).
sig { returns(String) }
attr_accessor :currency
# Shipping rates defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
sig {
returns(T.nilable(T::Hash[String, ::Stripe::Invoice::UpdateParams::ShippingCost::ShippingRateData::FixedAmount::CurrencyOptions]))
}
attr_accessor :currency_options
sig {
params(amount: Integer, currency: String, currency_options: T.nilable(T::Hash[String, ::Stripe::Invoice::UpdateParams::ShippingCost::ShippingRateData::FixedAmount::CurrencyOptions])).void
}
def initialize(amount: nil, currency: nil, currency_options: nil); end
end
# The estimated range for how long shipping will take, meant to be displayable to the customer. This will appear on CheckoutSessions.
sig {
returns(T.nilable(::Stripe::Invoice::UpdateParams::ShippingCost::ShippingRateData::DeliveryEstimate))
}
attr_accessor :delivery_estimate
# The name of the shipping rate, meant to be displayable to the customer. This will appear on CheckoutSessions.
sig { returns(String) }
attr_accessor :display_name
# Describes a fixed amount to charge for shipping. Must be present if type is `fixed_amount`.
sig {
returns(T.nilable(::Stripe::Invoice::UpdateParams::ShippingCost::ShippingRateData::FixedAmount))
}
attr_accessor :fixed_amount
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID. The Shipping tax code is `txcd_92010001`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_code
# The type of calculation to use on the shipping rate.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(delivery_estimate: T.nilable(::Stripe::Invoice::UpdateParams::ShippingCost::ShippingRateData::DeliveryEstimate), display_name: String, fixed_amount: T.nilable(::Stripe::Invoice::UpdateParams::ShippingCost::ShippingRateData::FixedAmount), metadata: T.nilable(T::Hash[String, String]), tax_behavior: T.nilable(String), tax_code: T.nilable(String), type: T.nilable(String)).void
}
def initialize(
delivery_estimate: nil,
display_name: nil,
fixed_amount: nil,
metadata: nil,
tax_behavior: nil,
tax_code: nil,
type: nil
); end
end
# The ID of the shipping rate to use for this order.
sig { returns(T.nilable(String)) }
attr_accessor :shipping_rate
# Parameters to create a new ad-hoc shipping rate for this order.
sig { returns(T.nilable(::Stripe::Invoice::UpdateParams::ShippingCost::ShippingRateData)) }
attr_accessor :shipping_rate_data
sig {
params(shipping_rate: T.nilable(String), shipping_rate_data: T.nilable(::Stripe::Invoice::UpdateParams::ShippingCost::ShippingRateData)).void
}
def initialize(shipping_rate: nil, shipping_rate_data: nil); end
end
class ShippingDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Shipping address
sig { returns(::Stripe::Invoice::UpdateParams::ShippingDetails::Address) }
attr_accessor :address
# Recipient name.
sig { returns(String) }
attr_accessor :name
# Recipient phone (including extension)
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :phone
sig {
params(address: ::Stripe::Invoice::UpdateParams::ShippingDetails::Address, name: String, phone: T.nilable(T.nilable(String))).void
}
def initialize(address: nil, name: nil, phone: nil); end
end
class TransferData < Stripe::RequestParams
# The amount that will be transferred automatically when the invoice is paid. If no amount is set, the full amount is transferred.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# ID of an existing, connected Stripe account.
sig { returns(String) }
attr_accessor :destination
sig { params(amount: T.nilable(Integer), destination: String).void }
def initialize(amount: nil, destination: nil); end
end
# The account tax IDs associated with the invoice. Only editable when the invoice is a draft.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :account_tax_ids
# List of expected payments and corresponding due dates. Valid only for invoices where `collection_method=send_invoice`.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Invoice::UpdateParams::AmountsDue]))))
}
attr_accessor :amounts_due
# 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).
sig { returns(T.nilable(Integer)) }
attr_accessor :application_fee_amount
# Controls whether Stripe performs [automatic collection](https://stripe.com/docs/invoicing/integration/automatic-advancement-collection) of the invoice.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :auto_advance
# Settings for automatic tax lookup for this invoice.
sig { returns(T.nilable(::Stripe::Invoice::UpdateParams::AutomaticTax)) }
attr_accessor :automatic_tax
# The time when this invoice should be scheduled to finalize. The invoice will be finalized at this time if it is still in draft state. To turn off automatic finalization, set `auto_advance` to false.
sig { returns(T.nilable(Integer)) }
attr_accessor :automatically_finalizes_at
# Either `charge_automatically` or `send_invoice`. This field can be updated only on `draft` invoices.
sig { returns(T.nilable(String)) }
attr_accessor :collection_method
# 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.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Invoice::UpdateParams::CustomField]))))
}
attr_accessor :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.
sig { returns(T.nilable(Integer)) }
attr_accessor :days_until_due
# The ids of the margins to apply to the invoice. Can be overridden by line item `margins`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :default_margins
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :default_payment_method
# ID of the default payment source for the invoice. It must belong to the customer associated with the invoice and be in a chargeable state. If not set, defaults to the subscription's default source, if any, or to the customer's default source.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :default_source
# The tax rates that will apply to any line item that does not have `tax_rates` set. Pass an empty string to remove previously-defined tax rates.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :default_tax_rates
# An arbitrary string attached to the object. Often useful for displaying to users. Referenced as 'memo' in the Dashboard.
sig { returns(T.nilable(String)) }
attr_accessor :description
# The discounts that will apply to the invoice. Pass an empty string to remove previously-defined discounts.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Invoice::UpdateParams::Discount]))))
}
attr_accessor :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.
sig { returns(T.nilable(Integer)) }
attr_accessor :due_date
# The date when this invoice is in effect. Same as `finalized_at` unless overwritten. When defined, this value replaces the system-generated 'Date of issue' printed on the invoice PDF and receipt.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :effective_at
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Footer to be displayed on the invoice.
sig { returns(T.nilable(String)) }
attr_accessor :footer
# The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
sig { returns(T.nilable(::Stripe::Invoice::UpdateParams::Issuer)) }
attr_accessor :issuer
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Set the number for this invoice. If no number is present then a number will be assigned automatically when the invoice is finalized. In many markets, regulations require invoices to be unique, sequential and / or gapless. You are responsible for ensuring this is true across all your different invoicing systems in the event that you edit the invoice number using our API. If you use only Stripe for your invoices and do not change invoice numbers, Stripe handles this aspect of compliance for you automatically.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :number
# The account (if any) for which the funds of the invoice payment are intended. If set, the invoice will be presented with the branding and support information of the specified account. See the [Invoices with Connect](https://stripe.com/docs/billing/invoices/connect) documentation for details.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :on_behalf_of
# Configuration settings for the PaymentIntent that is generated when the invoice is finalized.
sig { returns(T.nilable(::Stripe::Invoice::UpdateParams::PaymentSettings)) }
attr_accessor :payment_settings
# The rendering-related settings that control how the invoice is displayed on customer-facing surfaces such as PDF and Hosted Invoice Page.
sig { returns(T.nilable(::Stripe::Invoice::UpdateParams::Rendering)) }
attr_accessor :rendering
# Settings for the cost of shipping for this invoice.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::UpdateParams::ShippingCost))))
}
attr_accessor :shipping_cost
# Shipping details for the invoice. The Invoice PDF will use the `shipping_details` value if it is set, otherwise the PDF will render the shipping address from the customer.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::UpdateParams::ShippingDetails))))
}
attr_accessor :shipping_details
# Extra information about a charge for the customer's credit card statement. It must contain at least one letter. If not specified and this invoice is part of a subscription, the default `statement_descriptor` will be set to the first subscription item's product's `statement_descriptor`.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
# 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.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::UpdateParams::TransferData))))
}
attr_accessor :transfer_data
sig {
params(account_tax_ids: T.nilable(T.nilable(T.any(String, T::Array[String]))), amounts_due: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Invoice::UpdateParams::AmountsDue]))), application_fee_amount: T.nilable(Integer), auto_advance: T.nilable(T::Boolean), automatic_tax: T.nilable(::Stripe::Invoice::UpdateParams::AutomaticTax), automatically_finalizes_at: T.nilable(Integer), collection_method: T.nilable(String), custom_fields: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Invoice::UpdateParams::CustomField]))), days_until_due: T.nilable(Integer), default_margins: T.nilable(T.nilable(T.any(String, T::Array[String]))), default_payment_method: T.nilable(String), default_source: T.nilable(T.nilable(String)), default_tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String]))), description: T.nilable(String), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Invoice::UpdateParams::Discount]))), due_date: T.nilable(Integer), effective_at: T.nilable(T.nilable(T.any(String, Integer))), expand: T.nilable(T::Array[String]), footer: T.nilable(String), issuer: T.nilable(::Stripe::Invoice::UpdateParams::Issuer), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), number: T.nilable(T.nilable(String)), on_behalf_of: T.nilable(T.nilable(String)), payment_settings: T.nilable(::Stripe::Invoice::UpdateParams::PaymentSettings), rendering: T.nilable(::Stripe::Invoice::UpdateParams::Rendering), shipping_cost: T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::UpdateParams::ShippingCost))), shipping_details: T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::UpdateParams::ShippingDetails))), statement_descriptor: T.nilable(String), transfer_data: T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::UpdateParams::TransferData)))).void
}
def initialize(
account_tax_ids: nil,
amounts_due: nil,
application_fee_amount: nil,
auto_advance: nil,
automatic_tax: nil,
automatically_finalizes_at: nil,
collection_method: nil,
custom_fields: nil,
days_until_due: nil,
default_margins: nil,
default_payment_method: nil,
default_source: nil,
default_tax_rates: nil,
description: nil,
discounts: nil,
due_date: nil,
effective_at: nil,
expand: nil,
footer: nil,
issuer: nil,
metadata: nil,
number: nil,
on_behalf_of: nil,
payment_settings: nil,
rendering: nil,
shipping_cost: nil,
shipping_details: nil,
statement_descriptor: nil,
transfer_data: nil
); end
end
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
class DueDate < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# The collection method of the invoice to retrieve. Either `charge_automatically` or `send_invoice`.
sig { returns(T.nilable(String)) }
attr_accessor :collection_method
# Only return invoices that were created during the given date interval.
sig { returns(T.nilable(T.any(::Stripe::Invoice::ListParams::Created, Integer))) }
attr_accessor :created
# Only return invoices for the customer specified by this customer ID.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# Only return invoices for the account specified by this account ID.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# Attribute for param field due_date
sig { returns(T.nilable(T.any(::Stripe::Invoice::ListParams::DueDate, Integer))) }
attr_accessor :due_date
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# The status of the invoice, one of `draft`, `open`, `paid`, `uncollectible`, or `void`. [Learn more](https://stripe.com/docs/billing/invoices/workflow#workflow-overview)
sig { returns(T.nilable(String)) }
attr_accessor :status
# Only return invoices for the subscription specified by this subscription ID.
sig { returns(T.nilable(String)) }
attr_accessor :subscription
sig {
params(collection_method: T.nilable(String), created: T.nilable(T.any(::Stripe::Invoice::ListParams::Created, Integer)), customer: T.nilable(String), customer_account: T.nilable(String), due_date: T.nilable(T.any(::Stripe::Invoice::ListParams::DueDate, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String), status: T.nilable(String), subscription: T.nilable(String)).void
}
def initialize(
collection_method: nil,
created: nil,
customer: nil,
customer_account: nil,
due_date: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil,
status: nil,
subscription: nil
); end
end
class CreateParams < Stripe::RequestParams
class AmountsDue < Stripe::RequestParams
# The amount in cents (or local equivalent).
sig { returns(Integer) }
attr_accessor :amount
# Number of days from when invoice is finalized until the payment is due.
sig { returns(T.nilable(Integer)) }
attr_accessor :days_until_due
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(String) }
attr_accessor :description
# Date on which a payment plan’s payment is due.
sig { returns(T.nilable(Integer)) }
attr_accessor :due_date
sig {
params(amount: Integer, days_until_due: T.nilable(Integer), description: String, due_date: T.nilable(Integer)).void
}
def initialize(amount: nil, days_until_due: nil, description: nil, due_date: nil); end
end
class AutomaticTax < Stripe::RequestParams
class Liability < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# 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.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
sig { returns(T.nilable(::Stripe::Invoice::CreateParams::AutomaticTax::Liability)) }
attr_accessor :liability
sig {
params(enabled: T::Boolean, liability: T.nilable(::Stripe::Invoice::CreateParams::AutomaticTax::Liability)).void
}
def initialize(enabled: nil, liability: nil); end
end
class CustomField < Stripe::RequestParams
# The name of the custom field. This may be up to 40 characters.
sig { returns(String) }
attr_accessor :name
# The value of the custom field. This may be up to 140 characters.
sig { returns(String) }
attr_accessor :value
sig { params(name: String, value: String).void }
def initialize(name: nil, value: nil); end
end
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::Invoice::CreateParams::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::Invoice::CreateParams::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig { returns(T.nilable(::Stripe::Invoice::CreateParams::Discount::DiscountEnd)) }
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::Invoice::CreateParams::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class FromInvoice < Stripe::RequestParams
# The relation between the new invoice and the original invoice. Currently, only 'revision' is permitted
sig { returns(String) }
attr_accessor :action
# The `id` of the invoice that will be cloned.
sig { returns(String) }
attr_accessor :invoice
sig { params(action: String, invoice: String).void }
def initialize(action: nil, invoice: nil); end
end
class Issuer < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
class PaymentSettings < Stripe::RequestParams
class PaymentMethodOptions < Stripe::RequestParams
class AcssDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Transaction type of the mandate.
sig { returns(T.nilable(String)) }
attr_accessor :transaction_type
sig { params(transaction_type: T.nilable(String)).void }
def initialize(transaction_type: nil); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::Invoice::CreateParams::PaymentSettings::PaymentMethodOptions::AcssDebit::MandateOptions))
}
attr_accessor :mandate_options
# Verification method for the intent
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(mandate_options: T.nilable(::Stripe::Invoice::CreateParams::PaymentSettings::PaymentMethodOptions::AcssDebit::MandateOptions), verification_method: T.nilable(String)).void
}
def initialize(mandate_options: nil, verification_method: nil); end
end
class Bancontact < Stripe::RequestParams
# Preferred language of the Bancontact authorization page that the customer is redirected to.
sig { returns(T.nilable(String)) }
attr_accessor :preferred_language
sig { params(preferred_language: T.nilable(String)).void }
def initialize(preferred_language: nil); end
end
class Card < Stripe::RequestParams
class Installments < Stripe::RequestParams
class Plan < Stripe::RequestParams
# For `fixed_count` installment plans, this is required. It represents the number of installment payments your customer will make to their credit card.
sig { returns(T.nilable(Integer)) }
attr_accessor :count
# For `fixed_count` installment plans, this is required. It represents the interval between installment payments your customer will make to their credit card.
# One of `month`.
sig { returns(T.nilable(String)) }
attr_accessor :interval
# Type of installment plan, one of `fixed_count`.
sig { returns(String) }
attr_accessor :type
sig {
params(count: T.nilable(Integer), interval: T.nilable(String), type: String).void
}
def initialize(count: nil, interval: nil, type: nil); end
end
# Setting to true enables installments for this invoice.
# Setting to false will prevent any selected plan from applying to a payment.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :enabled
# The selected installment plan to use for this invoice.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::CreateParams::PaymentSettings::PaymentMethodOptions::Card::Installments::Plan))))
}
attr_accessor :plan
sig {
params(enabled: T.nilable(T::Boolean), plan: T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::CreateParams::PaymentSettings::PaymentMethodOptions::Card::Installments::Plan)))).void
}
def initialize(enabled: nil, plan: nil); end
end
# Installment configuration for payments attempted on this invoice (Mexico Only).
#
# For more information, see the [installments integration guide](https://stripe.com/docs/payments/installments).
sig {
returns(T.nilable(::Stripe::Invoice::CreateParams::PaymentSettings::PaymentMethodOptions::Card::Installments))
}
attr_accessor :installments
# We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
sig { returns(T.nilable(String)) }
attr_accessor :request_three_d_secure
sig {
params(installments: T.nilable(::Stripe::Invoice::CreateParams::PaymentSettings::PaymentMethodOptions::Card::Installments), request_three_d_secure: T.nilable(String)).void
}
def initialize(installments: nil, request_three_d_secure: nil); end
end
class CustomerBalance < Stripe::RequestParams
class BankTransfer < Stripe::RequestParams
class EuBankTransfer < Stripe::RequestParams
# The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
sig { returns(String) }
attr_accessor :country
sig { params(country: String).void }
def initialize(country: nil); end
end
# Configuration for eu_bank_transfer funding type.
sig {
returns(T.nilable(::Stripe::Invoice::CreateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance::BankTransfer::EuBankTransfer))
}
attr_accessor :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`, `mx_bank_transfer`, or `us_bank_transfer`.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(eu_bank_transfer: T.nilable(::Stripe::Invoice::CreateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance::BankTransfer::EuBankTransfer), type: T.nilable(String)).void
}
def initialize(eu_bank_transfer: nil, type: nil); end
end
# Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
sig {
returns(T.nilable(::Stripe::Invoice::CreateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance::BankTransfer))
}
attr_accessor :bank_transfer
# The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
sig { returns(T.nilable(String)) }
attr_accessor :funding_type
sig {
params(bank_transfer: T.nilable(::Stripe::Invoice::CreateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance::BankTransfer), funding_type: T.nilable(String)).void
}
def initialize(bank_transfer: nil, funding_type: nil); end
end
class IdBankTransfer < Stripe::RequestParams; end
class Konbini < Stripe::RequestParams; end
class SepaDebit < Stripe::RequestParams; end
class UsBankAccount < Stripe::RequestParams
class FinancialConnections < Stripe::RequestParams
class Filters < Stripe::RequestParams
# The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :account_subcategories
# ID of the institution to use to filter for selectable accounts.
sig { returns(T.nilable(String)) }
attr_accessor :institution
sig {
params(account_subcategories: T.nilable(T::Array[String]), institution: T.nilable(String)).void
}
def initialize(account_subcategories: nil, institution: nil); end
end
# Provide filters for the linked accounts that the customer can select for the payment method.
sig {
returns(T.nilable(::Stripe::Invoice::CreateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount::FinancialConnections::Filters))
}
attr_accessor :filters
# The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :permissions
# List of data features that you would like to retrieve upon account creation.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :prefetch
sig {
params(filters: T.nilable(::Stripe::Invoice::CreateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount::FinancialConnections::Filters), permissions: T.nilable(T::Array[String]), prefetch: T.nilable(T::Array[String])).void
}
def initialize(filters: nil, permissions: nil, prefetch: nil); end
end
# Additional fields for Financial Connections Session creation
sig {
returns(T.nilable(::Stripe::Invoice::CreateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount::FinancialConnections))
}
attr_accessor :financial_connections
# Verification method for the intent
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(financial_connections: T.nilable(::Stripe::Invoice::CreateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount::FinancialConnections), verification_method: T.nilable(String)).void
}
def initialize(financial_connections: nil, verification_method: nil); end
end
# If paying by `acss_debit`, this sub-hash contains details about the Canadian pre-authorized debit payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::CreateParams::PaymentSettings::PaymentMethodOptions::AcssDebit))))
}
attr_accessor :acss_debit
# If paying by `bancontact`, this sub-hash contains details about the Bancontact payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::CreateParams::PaymentSettings::PaymentMethodOptions::Bancontact))))
}
attr_accessor :bancontact
# If paying by `card`, this sub-hash contains details about the Card payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::CreateParams::PaymentSettings::PaymentMethodOptions::Card))))
}
attr_accessor :card
# If paying by `customer_balance`, this sub-hash contains details about the Bank transfer payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::CreateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance))))
}
attr_accessor :customer_balance
# If paying by `id_bank_transfer`, this sub-hash contains details about the Indonesia bank transfer payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::CreateParams::PaymentSettings::PaymentMethodOptions::IdBankTransfer))))
}
attr_accessor :id_bank_transfer
# If paying by `konbini`, this sub-hash contains details about the Konbini payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::CreateParams::PaymentSettings::PaymentMethodOptions::Konbini))))
}
attr_accessor :konbini
# If paying by `sepa_debit`, this sub-hash contains details about the SEPA Direct Debit payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::CreateParams::PaymentSettings::PaymentMethodOptions::SepaDebit))))
}
attr_accessor :sepa_debit
# If paying by `us_bank_account`, this sub-hash contains details about the ACH direct debit payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::CreateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount))))
}
attr_accessor :us_bank_account
sig {
params(acss_debit: T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::CreateParams::PaymentSettings::PaymentMethodOptions::AcssDebit))), bancontact: T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::CreateParams::PaymentSettings::PaymentMethodOptions::Bancontact))), card: T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::CreateParams::PaymentSettings::PaymentMethodOptions::Card))), customer_balance: T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::CreateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance))), id_bank_transfer: T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::CreateParams::PaymentSettings::PaymentMethodOptions::IdBankTransfer))), konbini: T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::CreateParams::PaymentSettings::PaymentMethodOptions::Konbini))), sepa_debit: T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::CreateParams::PaymentSettings::PaymentMethodOptions::SepaDebit))), us_bank_account: T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::CreateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount)))).void
}
def initialize(
acss_debit: nil,
bancontact: nil,
card: nil,
customer_balance: nil,
id_bank_transfer: nil,
konbini: nil,
sepa_debit: nil,
us_bank_account: nil
); end
end
# ID of the mandate to be used for this invoice. It must correspond to the payment method used to pay the invoice, including the invoice's default_payment_method or default_source, if set.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :default_mandate
# Payment-method-specific configuration to provide to the invoice’s PaymentIntent.
sig {
returns(T.nilable(::Stripe::Invoice::CreateParams::PaymentSettings::PaymentMethodOptions))
}
attr_accessor :payment_method_options
# The list of payment method types (e.g. card) to provide to the invoice’s PaymentIntent. If not set, Stripe attempts to automatically determine the types to use by looking at the invoice’s default payment method, the subscription’s default payment method, the customer’s default payment method, and your [invoice template settings](https://dashboard.stripe.com/settings/billing/invoice). Should not be specified with payment_method_configuration
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :payment_method_types
sig {
params(default_mandate: T.nilable(T.nilable(String)), payment_method_options: T.nilable(::Stripe::Invoice::CreateParams::PaymentSettings::PaymentMethodOptions), payment_method_types: T.nilable(T.nilable(T.any(String, T::Array[String])))).void
}
def initialize(
default_mandate: nil,
payment_method_options: nil,
payment_method_types: nil
); end
end
class Rendering < Stripe::RequestParams
class Pdf < Stripe::RequestParams
# Page size for invoice PDF. Can be set to `a4`, `letter`, or `auto`.
# If set to `auto`, invoice PDF page size defaults to `a4` for customers with
# Japanese locale and `letter` for customers with other locales.
sig { returns(T.nilable(String)) }
attr_accessor :page_size
sig { params(page_size: T.nilable(String)).void }
def initialize(page_size: nil); end
end
# How line-item prices and amounts will be displayed with respect to tax on invoice PDFs. One of `exclude_tax` or `include_inclusive_tax`. `include_inclusive_tax` will include inclusive tax (and exclude exclusive tax) in invoice PDF amounts. `exclude_tax` will exclude all tax (inclusive and exclusive alike) from invoice PDF amounts.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :amount_tax_display
# Invoice pdf rendering options
sig { returns(T.nilable(::Stripe::Invoice::CreateParams::Rendering::Pdf)) }
attr_accessor :pdf
# ID of the invoice rendering template to use for this invoice.
sig { returns(T.nilable(String)) }
attr_accessor :template
# The specific version of invoice rendering template to use for this invoice.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :template_version
sig {
params(amount_tax_display: T.nilable(T.nilable(T.any(String, String))), pdf: T.nilable(::Stripe::Invoice::CreateParams::Rendering::Pdf), template: T.nilable(String), template_version: T.nilable(T.nilable(T.any(String, Integer)))).void
}
def initialize(amount_tax_display: nil, pdf: nil, template: nil, template_version: nil); end
end
class ShippingCost < Stripe::RequestParams
class ShippingRateData < Stripe::RequestParams
class DeliveryEstimate < Stripe::RequestParams
class Maximum < Stripe::RequestParams
# A unit of time.
sig { returns(String) }
attr_accessor :unit
# Must be greater than 0.
sig { returns(Integer) }
attr_accessor :value
sig { params(unit: String, value: Integer).void }
def initialize(unit: nil, value: nil); end
end
class Minimum < Stripe::RequestParams
# A unit of time.
sig { returns(String) }
attr_accessor :unit
# Must be greater than 0.
sig { returns(Integer) }
attr_accessor :value
sig { params(unit: String, value: Integer).void }
def initialize(unit: nil, value: nil); end
end
# The upper bound of the estimated range. If empty, represents no upper bound i.e., infinite.
sig {
returns(T.nilable(::Stripe::Invoice::CreateParams::ShippingCost::ShippingRateData::DeliveryEstimate::Maximum))
}
attr_accessor :maximum
# The lower bound of the estimated range. If empty, represents no lower bound.
sig {
returns(T.nilable(::Stripe::Invoice::CreateParams::ShippingCost::ShippingRateData::DeliveryEstimate::Minimum))
}
attr_accessor :minimum
sig {
params(maximum: T.nilable(::Stripe::Invoice::CreateParams::ShippingCost::ShippingRateData::DeliveryEstimate::Maximum), minimum: T.nilable(::Stripe::Invoice::CreateParams::ShippingCost::ShippingRateData::DeliveryEstimate::Minimum)).void
}
def initialize(maximum: nil, minimum: nil); end
end
class FixedAmount < Stripe::RequestParams
class CurrencyOptions < Stripe::RequestParams
# A non-negative integer in cents representing how much to charge.
sig { returns(Integer) }
attr_accessor :amount
# Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
sig { params(amount: Integer, tax_behavior: T.nilable(String)).void }
def initialize(amount: nil, tax_behavior: nil); end
end
# A non-negative integer in cents representing how much to charge.
sig { returns(Integer) }
attr_accessor :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).
sig { returns(String) }
attr_accessor :currency
# Shipping rates defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
sig {
returns(T.nilable(T::Hash[String, ::Stripe::Invoice::CreateParams::ShippingCost::ShippingRateData::FixedAmount::CurrencyOptions]))
}
attr_accessor :currency_options
sig {
params(amount: Integer, currency: String, currency_options: T.nilable(T::Hash[String, ::Stripe::Invoice::CreateParams::ShippingCost::ShippingRateData::FixedAmount::CurrencyOptions])).void
}
def initialize(amount: nil, currency: nil, currency_options: nil); end
end
# The estimated range for how long shipping will take, meant to be displayable to the customer. This will appear on CheckoutSessions.
sig {
returns(T.nilable(::Stripe::Invoice::CreateParams::ShippingCost::ShippingRateData::DeliveryEstimate))
}
attr_accessor :delivery_estimate
# The name of the shipping rate, meant to be displayable to the customer. This will appear on CheckoutSessions.
sig { returns(String) }
attr_accessor :display_name
# Describes a fixed amount to charge for shipping. Must be present if type is `fixed_amount`.
sig {
returns(T.nilable(::Stripe::Invoice::CreateParams::ShippingCost::ShippingRateData::FixedAmount))
}
attr_accessor :fixed_amount
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID. The Shipping tax code is `txcd_92010001`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_code
# The type of calculation to use on the shipping rate.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(delivery_estimate: T.nilable(::Stripe::Invoice::CreateParams::ShippingCost::ShippingRateData::DeliveryEstimate), display_name: String, fixed_amount: T.nilable(::Stripe::Invoice::CreateParams::ShippingCost::ShippingRateData::FixedAmount), metadata: T.nilable(T::Hash[String, String]), tax_behavior: T.nilable(String), tax_code: T.nilable(String), type: T.nilable(String)).void
}
def initialize(
delivery_estimate: nil,
display_name: nil,
fixed_amount: nil,
metadata: nil,
tax_behavior: nil,
tax_code: nil,
type: nil
); end
end
# The ID of the shipping rate to use for this order.
sig { returns(T.nilable(String)) }
attr_accessor :shipping_rate
# Parameters to create a new ad-hoc shipping rate for this order.
sig { returns(T.nilable(::Stripe::Invoice::CreateParams::ShippingCost::ShippingRateData)) }
attr_accessor :shipping_rate_data
sig {
params(shipping_rate: T.nilable(String), shipping_rate_data: T.nilable(::Stripe::Invoice::CreateParams::ShippingCost::ShippingRateData)).void
}
def initialize(shipping_rate: nil, shipping_rate_data: nil); end
end
class ShippingDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Shipping address
sig { returns(::Stripe::Invoice::CreateParams::ShippingDetails::Address) }
attr_accessor :address
# Recipient name.
sig { returns(String) }
attr_accessor :name
# Recipient phone (including extension)
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :phone
sig {
params(address: ::Stripe::Invoice::CreateParams::ShippingDetails::Address, name: String, phone: T.nilable(T.nilable(String))).void
}
def initialize(address: nil, name: nil, phone: nil); end
end
class TransferData < Stripe::RequestParams
# The amount that will be transferred automatically when the invoice is paid. If no amount is set, the full amount is transferred.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# ID of an existing, connected Stripe account.
sig { returns(String) }
attr_accessor :destination
sig { params(amount: T.nilable(Integer), destination: String).void }
def initialize(amount: nil, destination: nil); end
end
# The account tax IDs associated with the invoice. Only editable when the invoice is a draft.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :account_tax_ids
# List of expected payments and corresponding due dates. Valid only for invoices where `collection_method=send_invoice`.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Invoice::CreateParams::AmountsDue]))))
}
attr_accessor :amounts_due
# 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).
sig { returns(T.nilable(Integer)) }
attr_accessor :application_fee_amount
# Controls whether Stripe performs [automatic collection](https://stripe.com/docs/invoicing/integration/automatic-advancement-collection) of the invoice. If `false`, the invoice's state doesn't automatically advance without an explicit action.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :auto_advance
# Settings for automatic tax lookup for this invoice.
sig { returns(T.nilable(::Stripe::Invoice::CreateParams::AutomaticTax)) }
attr_accessor :automatic_tax
# The time when this invoice should be scheduled to finalize. The invoice will be finalized at this time if it is still in draft state.
sig { returns(T.nilable(Integer)) }
attr_accessor :automatically_finalizes_at
# 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`.
sig { returns(T.nilable(String)) }
attr_accessor :collection_method
# The currency to create this invoice in. Defaults to that of `customer` if not specified.
sig { returns(T.nilable(String)) }
attr_accessor :currency
# A list of up to 4 custom fields to be displayed on the invoice.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Invoice::CreateParams::CustomField]))))
}
attr_accessor :custom_fields
# The ID of the customer who will be billed.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# The ID of the account who will be billed.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# The number of days from when the invoice is created until it is due. Valid only for invoices where `collection_method=send_invoice`.
sig { returns(T.nilable(Integer)) }
attr_accessor :days_until_due
# The ids of the margins to apply to the invoice. Can be overridden by line item `margins`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :default_margins
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :default_payment_method
# ID of the default payment source for the invoice. It must belong to the customer associated with the invoice and be in a chargeable state. If not set, defaults to the subscription's default source, if any, or to the customer's default source.
sig { returns(T.nilable(String)) }
attr_accessor :default_source
# The tax rates that will apply to any line item that does not have `tax_rates` set.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :default_tax_rates
# An arbitrary string attached to the object. Often useful for displaying to users. Referenced as 'memo' in the Dashboard.
sig { returns(T.nilable(String)) }
attr_accessor :description
# The coupons and promotion codes 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.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Invoice::CreateParams::Discount]))))
}
attr_accessor :discounts
# The date on which payment for this invoice is due. Valid only for invoices where `collection_method=send_invoice`.
sig { returns(T.nilable(Integer)) }
attr_accessor :due_date
# The date when this invoice is in effect. Same as `finalized_at` unless overwritten. When defined, this value replaces the system-generated 'Date of issue' printed on the invoice PDF and receipt.
sig { returns(T.nilable(Integer)) }
attr_accessor :effective_at
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Footer to be displayed on the invoice.
sig { returns(T.nilable(String)) }
attr_accessor :footer
# 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.
sig { returns(T.nilable(::Stripe::Invoice::CreateParams::FromInvoice)) }
attr_accessor :from_invoice
# The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
sig { returns(T.nilable(::Stripe::Invoice::CreateParams::Issuer)) }
attr_accessor :issuer
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Set the number for this invoice. If no number is present then a number will be assigned automatically when the invoice is finalized. In many markets, regulations require invoices to be unique, sequential and / or gapless. You are responsible for ensuring this is true across all your different invoicing systems in the event that you edit the invoice number using our API. If you use only Stripe for your invoices and do not change invoice numbers, Stripe handles this aspect of compliance for you automatically.
sig { returns(T.nilable(String)) }
attr_accessor :number
# The account (if any) for which the funds of the invoice payment are intended. If set, the invoice will be presented with the branding and support information of the specified account. See the [Invoices with Connect](https://stripe.com/docs/billing/invoices/connect) documentation for details.
sig { returns(T.nilable(String)) }
attr_accessor :on_behalf_of
# Configuration settings for the PaymentIntent that is generated when the invoice is finalized.
sig { returns(T.nilable(::Stripe::Invoice::CreateParams::PaymentSettings)) }
attr_accessor :payment_settings
# How to handle pending invoice items on invoice creation. Defaults to `exclude` if the parameter is omitted.
sig { returns(T.nilable(String)) }
attr_accessor :pending_invoice_items_behavior
# The rendering-related settings that control how the invoice is displayed on customer-facing surfaces such as PDF and Hosted Invoice Page.
sig { returns(T.nilable(::Stripe::Invoice::CreateParams::Rendering)) }
attr_accessor :rendering
# Settings for the cost of shipping for this invoice.
sig { returns(T.nilable(::Stripe::Invoice::CreateParams::ShippingCost)) }
attr_accessor :shipping_cost
# Shipping details for the invoice. The Invoice PDF will use the `shipping_details` value if it is set, otherwise the PDF will render the shipping address from the customer.
sig { returns(T.nilable(::Stripe::Invoice::CreateParams::ShippingDetails)) }
attr_accessor :shipping_details
# Extra information about a charge for the customer's credit card statement. It must contain at least one letter. If not specified and this invoice is part of a subscription, the default `statement_descriptor` will be set to the first subscription item's product's `statement_descriptor`.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
# The ID of the subscription to invoice, if any. If set, the created invoice will only include pending invoice items for that subscription. The subscription's billing cycle and regular subscription events won't be affected.
sig { returns(T.nilable(String)) }
attr_accessor :subscription
# 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.
sig { returns(T.nilable(::Stripe::Invoice::CreateParams::TransferData)) }
attr_accessor :transfer_data
sig {
params(account_tax_ids: T.nilable(T.nilable(T.any(String, T::Array[String]))), amounts_due: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Invoice::CreateParams::AmountsDue]))), application_fee_amount: T.nilable(Integer), auto_advance: T.nilable(T::Boolean), automatic_tax: T.nilable(::Stripe::Invoice::CreateParams::AutomaticTax), automatically_finalizes_at: T.nilable(Integer), collection_method: T.nilable(String), currency: T.nilable(String), custom_fields: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Invoice::CreateParams::CustomField]))), customer: T.nilable(String), customer_account: T.nilable(String), days_until_due: T.nilable(Integer), default_margins: T.nilable(T::Array[String]), default_payment_method: T.nilable(String), default_source: T.nilable(String), default_tax_rates: T.nilable(T::Array[String]), description: T.nilable(String), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Invoice::CreateParams::Discount]))), due_date: T.nilable(Integer), effective_at: T.nilable(Integer), expand: T.nilable(T::Array[String]), footer: T.nilable(String), from_invoice: T.nilable(::Stripe::Invoice::CreateParams::FromInvoice), issuer: T.nilable(::Stripe::Invoice::CreateParams::Issuer), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), number: T.nilable(String), on_behalf_of: T.nilable(String), payment_settings: T.nilable(::Stripe::Invoice::CreateParams::PaymentSettings), pending_invoice_items_behavior: T.nilable(String), rendering: T.nilable(::Stripe::Invoice::CreateParams::Rendering), shipping_cost: T.nilable(::Stripe::Invoice::CreateParams::ShippingCost), shipping_details: T.nilable(::Stripe::Invoice::CreateParams::ShippingDetails), statement_descriptor: T.nilable(String), subscription: T.nilable(String), transfer_data: T.nilable(::Stripe::Invoice::CreateParams::TransferData)).void
}
def initialize(
account_tax_ids: nil,
amounts_due: nil,
application_fee_amount: nil,
auto_advance: nil,
automatic_tax: nil,
automatically_finalizes_at: nil,
collection_method: nil,
currency: nil,
custom_fields: nil,
customer: nil,
customer_account: nil,
days_until_due: nil,
default_margins: nil,
default_payment_method: nil,
default_source: nil,
default_tax_rates: nil,
description: nil,
discounts: nil,
due_date: nil,
effective_at: nil,
expand: nil,
footer: nil,
from_invoice: nil,
issuer: nil,
metadata: nil,
number: nil,
on_behalf_of: nil,
payment_settings: nil,
pending_invoice_items_behavior: nil,
rendering: nil,
shipping_cost: nil,
shipping_details: nil,
statement_descriptor: nil,
subscription: nil,
transfer_data: nil
); end
end
class SearchParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for pagination across multiple pages of results. Don't include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.
sig { returns(T.nilable(String)) }
attr_accessor :page
# The search query string. See [search query language](https://stripe.com/docs/search#search-query-language) and the list of supported [query fields for invoices](https://stripe.com/docs/search#query-fields-for-invoices).
sig { returns(String) }
attr_accessor :query
sig {
params(expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), page: T.nilable(String), query: String).void
}
def initialize(expand: nil, limit: nil, page: nil, query: nil); end
end
class AddLinesParams < Stripe::RequestParams
class Line < Stripe::RequestParams
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::Invoice::AddLinesParams::Line::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::Invoice::AddLinesParams::Line::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig { returns(T.nilable(::Stripe::Invoice::AddLinesParams::Line::Discount::DiscountEnd)) }
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::Invoice::AddLinesParams::Line::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class Period < Stripe::RequestParams
# The end of the period, which must be greater than or equal to the start. This value is inclusive.
sig { returns(Integer) }
attr_accessor :end
# The start of the period. This value is inclusive.
sig { returns(Integer) }
attr_accessor :start
sig { params(end_: Integer, start: Integer).void }
def initialize(end_: nil, start: nil); end
end
class PriceData < Stripe::RequestParams
class ProductData < Stripe::RequestParams
# The product's description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes.
sig { returns(T.nilable(String)) }
attr_accessor :description
# A list of up to 8 URLs of images for this product, meant to be displayable to the customer.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :images
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The product's name, meant to be displayable to the customer.
sig { returns(String) }
attr_accessor :name
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
sig { returns(T.nilable(String)) }
attr_accessor :tax_code
sig {
params(description: T.nilable(String), images: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), name: String, tax_code: T.nilable(String)).void
}
def initialize(
description: nil,
images: nil,
metadata: nil,
name: nil,
tax_code: nil
); end
end
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to. One of `product` or `product_data` is required.
sig { returns(T.nilable(String)) }
attr_accessor :product
# Data used to generate a new [Product](https://docs.stripe.com/api/products) object inline. One of `product` or `product_data` is required.
sig {
returns(T.nilable(::Stripe::Invoice::AddLinesParams::Line::PriceData::ProductData))
}
attr_accessor :product_data
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A non-negative integer in cents (or local equivalent) representing how much to charge. One of `unit_amount` or `unit_amount_decimal` is required.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, product: T.nilable(String), product_data: T.nilable(::Stripe::Invoice::AddLinesParams::Line::PriceData::ProductData), tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
product_data: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
class Pricing < Stripe::RequestParams
# The ID of the price object.
sig { returns(T.nilable(String)) }
attr_accessor :price
sig { params(price: T.nilable(String)).void }
def initialize(price: nil); end
end
class TaxAmount < Stripe::RequestParams
class TaxRateData < Stripe::RequestParams
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# An arbitrary string attached to the tax rate for your internal use only. It will not be visible to your customers.
sig { returns(T.nilable(String)) }
attr_accessor :description
# The display name of the tax rate, which will be shown to users.
sig { returns(String) }
attr_accessor :display_name
# This specifies if the tax rate is inclusive or exclusive.
sig { returns(T::Boolean) }
attr_accessor :inclusive
# The jurisdiction for the tax rate. You can use this label field for tax reporting purposes. It also appears on your customer’s invoice.
sig { returns(T.nilable(String)) }
attr_accessor :jurisdiction
# The level of the jurisdiction that imposes this tax rate.
sig { returns(T.nilable(String)) }
attr_accessor :jurisdiction_level
# The statutory tax rate percent. This field accepts decimal values between 0 and 100 inclusive with at most 4 decimal places. To accommodate fixed-amount taxes, set the percentage to zero. Stripe will not display zero percentages on the invoice unless the `amount` of the tax is also zero.
sig { returns(Float) }
attr_accessor :percentage
# [ISO 3166-2 subdivision code](https://en.wikipedia.org/wiki/ISO_3166-2:US), without country prefix. For example, "NY" for New York, United States.
sig { returns(T.nilable(String)) }
attr_accessor :state
# The high-level tax type, such as `vat` or `sales_tax`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_type
sig {
params(country: T.nilable(String), description: T.nilable(String), display_name: String, inclusive: T::Boolean, jurisdiction: T.nilable(String), jurisdiction_level: T.nilable(String), percentage: Float, state: T.nilable(String), tax_type: T.nilable(String)).void
}
def initialize(
country: nil,
description: nil,
display_name: nil,
inclusive: nil,
jurisdiction: nil,
jurisdiction_level: nil,
percentage: nil,
state: nil,
tax_type: nil
); end
end
# The amount, in cents (or local equivalent), of the tax.
sig { returns(Integer) }
attr_accessor :amount
# Data to find or create a TaxRate object.
#
# Stripe automatically creates or reuses a TaxRate object for each tax amount. If the `tax_rate_data` exactly matches a previous value, Stripe will reuse the TaxRate object. TaxRate objects created automatically by Stripe are immediately archived, do not appear in the line item’s `tax_rates`, and cannot be directly added to invoices, payments, or line items.
sig { returns(::Stripe::Invoice::AddLinesParams::Line::TaxAmount::TaxRateData) }
attr_accessor :tax_rate_data
# The reasoning behind this tax, for example, if the product is tax exempt.
sig { returns(T.nilable(String)) }
attr_accessor :taxability_reason
# The amount on which tax is calculated, in cents (or local equivalent).
sig { returns(Integer) }
attr_accessor :taxable_amount
sig {
params(amount: Integer, tax_rate_data: ::Stripe::Invoice::AddLinesParams::Line::TaxAmount::TaxRateData, taxability_reason: T.nilable(String), taxable_amount: Integer).void
}
def initialize(
amount: nil,
tax_rate_data: nil,
taxability_reason: nil,
taxable_amount: nil
); end
end
# The integer amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. If you want to apply a credit to the customer's account, pass a negative amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# An arbitrary string which you can attach to the invoice item. The description is displayed in the invoice for easy tracking.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Controls whether discounts apply to this line item. Defaults to false for prorations or negative line items, and true for all other line items. Cannot be set to true for prorations.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :discountable
# The coupons, promotion codes & existing discounts which apply to the line item. Item discounts are applied before invoice discounts. Pass an empty string to remove previously-defined discounts.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Invoice::AddLinesParams::Line::Discount]))))
}
attr_accessor :discounts
# ID of an unassigned invoice item to assign to this invoice. If not provided, a new item will be created.
sig { returns(T.nilable(String)) }
attr_accessor :invoice_item
# The IDs of the margins to apply to the line item. When set, the `default_margins` on the invoice do not apply to this line item.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :margins
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :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.
sig { returns(T.nilable(::Stripe::Invoice::AddLinesParams::Line::Period)) }
attr_accessor :period
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
sig { returns(T.nilable(::Stripe::Invoice::AddLinesParams::Line::PriceData)) }
attr_accessor :price_data
# The pricing information for the invoice item.
sig { returns(T.nilable(::Stripe::Invoice::AddLinesParams::Line::Pricing)) }
attr_accessor :pricing
# Non-negative integer. The quantity of units for the line item.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# A list of up to 10 tax amounts for this line item. This can be useful if you calculate taxes on your own or use a third-party to calculate them. You cannot set tax amounts if any line item has [tax_rates](https://stripe.com/docs/api/invoices/line_item#invoice_line_item_object-tax_rates) or if the invoice has [default_tax_rates](https://stripe.com/docs/api/invoices/object#invoice_object-default_tax_rates) or uses [automatic tax](https://stripe.com/docs/tax/invoicing). Pass an empty string to remove previously defined tax amounts.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Invoice::AddLinesParams::Line::TaxAmount]))))
}
attr_accessor :tax_amounts
# The tax rates which apply to the line item. When set, the `default_tax_rates` on the invoice do not apply to this line item. Pass an empty string to remove previously-defined tax rates.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
sig {
params(amount: T.nilable(Integer), description: T.nilable(String), discountable: T.nilable(T::Boolean), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Invoice::AddLinesParams::Line::Discount]))), invoice_item: T.nilable(String), margins: T.nilable(T.nilable(T.any(String, T::Array[String]))), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), period: T.nilable(::Stripe::Invoice::AddLinesParams::Line::Period), price_data: T.nilable(::Stripe::Invoice::AddLinesParams::Line::PriceData), pricing: T.nilable(::Stripe::Invoice::AddLinesParams::Line::Pricing), quantity: T.nilable(Integer), tax_amounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Invoice::AddLinesParams::Line::TaxAmount]))), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String])))).void
}
def initialize(
amount: nil,
description: nil,
discountable: nil,
discounts: nil,
invoice_item: nil,
margins: nil,
metadata: nil,
period: nil,
price_data: nil,
pricing: nil,
quantity: nil,
tax_amounts: nil,
tax_rates: nil
); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :invoice_metadata
# The line items to add.
sig { returns(T::Array[::Stripe::Invoice::AddLinesParams::Line]) }
attr_accessor :lines
sig {
params(expand: T.nilable(T::Array[String]), invoice_metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), lines: T::Array[::Stripe::Invoice::AddLinesParams::Line]).void
}
def initialize(expand: nil, invoice_metadata: nil, lines: nil); end
end
class AttachPaymentParams < Stripe::RequestParams
class PaymentRecordData < Stripe::RequestParams
# The amount that was paid out of band.
sig { returns(Integer) }
attr_accessor :amount
# The currency that was paid out of band.
sig { returns(String) }
attr_accessor :currency
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# The type of money movement for this out of band payment record.
sig { returns(String) }
attr_accessor :money_movement_type
# The timestamp when this out of band payment was paid.
sig { returns(T.nilable(Integer)) }
attr_accessor :paid_at
# The reference for this out of band payment record.
sig { returns(T.nilable(String)) }
attr_accessor :payment_reference
sig {
params(amount: Integer, currency: String, metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), money_movement_type: String, paid_at: T.nilable(Integer), payment_reference: T.nilable(String)).void
}
def initialize(
amount: nil,
currency: nil,
metadata: nil,
money_movement_type: nil,
paid_at: nil,
payment_reference: nil
); end
end
# The portion of the `amount` on the PaymentIntent or out of band payment to apply to this invoice. It defaults to the entire amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount_requested
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The ID of the PaymentIntent to attach to the invoice.
sig { returns(T.nilable(String)) }
attr_accessor :payment_intent
# The ID of the PaymentRecord to attach to the invoice.
sig { returns(T.nilable(String)) }
attr_accessor :payment_record
# The PaymentRecord data for attaching an out of band payment to the invoice.
sig { returns(T.nilable(::Stripe::Invoice::AttachPaymentParams::PaymentRecordData)) }
attr_accessor :payment_record_data
sig {
params(amount_requested: T.nilable(Integer), expand: T.nilable(T::Array[String]), payment_intent: T.nilable(String), payment_record: T.nilable(String), payment_record_data: T.nilable(::Stripe::Invoice::AttachPaymentParams::PaymentRecordData)).void
}
def initialize(
amount_requested: nil,
expand: nil,
payment_intent: nil,
payment_record: nil,
payment_record_data: nil
); end
end
class FinalizeInvoiceParams < Stripe::RequestParams
# Controls whether Stripe performs [automatic collection](https://stripe.com/docs/invoicing/integration/automatic-advancement-collection) of the invoice. If `false`, the invoice's state doesn't automatically advance without an explicit action.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :auto_advance
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(auto_advance: T.nilable(T::Boolean), expand: T.nilable(T::Array[String])).void }
def initialize(auto_advance: nil, expand: nil); end
end
class MarkUncollectibleParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class PayParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# In cases where the source used to pay the invoice has insufficient funds, passing `forgive=true` controls whether a charge should be attempted for the full amount available on the source, up to the amount to fully pay the invoice. This effectively forgives the difference between the amount available on the source and the amount due.
#
# Passing `forgive=false` will fail the charge if the source hasn't been pre-funded with the right amount. An example for this case is with ACH Credit Transfers and wires: if the amount wired is less than the amount due by a small amount, you might want to forgive the difference. Defaults to `false`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :forgive
# ID of the mandate to be used for this invoice. It must correspond to the payment method used to pay the invoice, including the payment_method param or the invoice's default_payment_method or default_source, if set.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :mandate
# Indicates if a customer is on or off-session while an invoice payment is attempted. Defaults to `true` (off-session).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :off_session
# Boolean representing whether an invoice is paid outside of Stripe. This will result in no charge being made. Defaults to `false`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :paid_out_of_band
# A PaymentMethod to be charged. The PaymentMethod must be the ID of a PaymentMethod belonging to the customer associated with the invoice being paid.
sig { returns(T.nilable(String)) }
attr_accessor :payment_method
# A payment source to be charged. The source must be the ID of a source belonging to the customer associated with the invoice being paid.
sig { returns(T.nilable(String)) }
attr_accessor :source
sig {
params(expand: T.nilable(T::Array[String]), forgive: T.nilable(T::Boolean), mandate: T.nilable(T.nilable(String)), off_session: T.nilable(T::Boolean), paid_out_of_band: T.nilable(T::Boolean), payment_method: T.nilable(String), source: T.nilable(String)).void
}
def initialize(
expand: nil,
forgive: nil,
mandate: nil,
off_session: nil,
paid_out_of_band: nil,
payment_method: nil,
source: nil
); end
end
class RemoveLinesParams < Stripe::RequestParams
class Line < Stripe::RequestParams
# Either `delete` or `unassign`. Deleted line items are permanently deleted. Unassigned line items can be reassigned to an invoice.
sig { returns(String) }
attr_accessor :behavior
# ID of an existing line item to remove from this invoice.
sig { returns(String) }
attr_accessor :id
sig { params(behavior: String, id: String).void }
def initialize(behavior: nil, id: nil); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :invoice_metadata
# The line items to remove.
sig { returns(T::Array[::Stripe::Invoice::RemoveLinesParams::Line]) }
attr_accessor :lines
sig {
params(expand: T.nilable(T::Array[String]), invoice_metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), lines: T::Array[::Stripe::Invoice::RemoveLinesParams::Line]).void
}
def initialize(expand: nil, invoice_metadata: nil, lines: nil); end
end
class SendInvoiceParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateLinesParams < Stripe::RequestParams
class Line < Stripe::RequestParams
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::Invoice::UpdateLinesParams::Line::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::Invoice::UpdateLinesParams::Line::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::Invoice::UpdateLinesParams::Line::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::Invoice::UpdateLinesParams::Line::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class Period < Stripe::RequestParams
# The end of the period, which must be greater than or equal to the start. This value is inclusive.
sig { returns(Integer) }
attr_accessor :end
# The start of the period. This value is inclusive.
sig { returns(Integer) }
attr_accessor :start
sig { params(end_: Integer, start: Integer).void }
def initialize(end_: nil, start: nil); end
end
class PriceData < Stripe::RequestParams
class ProductData < Stripe::RequestParams
# The product's description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes.
sig { returns(T.nilable(String)) }
attr_accessor :description
# A list of up to 8 URLs of images for this product, meant to be displayable to the customer.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :images
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The product's name, meant to be displayable to the customer.
sig { returns(String) }
attr_accessor :name
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
sig { returns(T.nilable(String)) }
attr_accessor :tax_code
sig {
params(description: T.nilable(String), images: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), name: String, tax_code: T.nilable(String)).void
}
def initialize(
description: nil,
images: nil,
metadata: nil,
name: nil,
tax_code: nil
); end
end
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to. One of `product` or `product_data` is required.
sig { returns(T.nilable(String)) }
attr_accessor :product
# Data used to generate a new [Product](https://docs.stripe.com/api/products) object inline. One of `product` or `product_data` is required.
sig {
returns(T.nilable(::Stripe::Invoice::UpdateLinesParams::Line::PriceData::ProductData))
}
attr_accessor :product_data
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A non-negative integer in cents (or local equivalent) representing how much to charge. One of `unit_amount` or `unit_amount_decimal` is required.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, product: T.nilable(String), product_data: T.nilable(::Stripe::Invoice::UpdateLinesParams::Line::PriceData::ProductData), tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
product_data: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
class Pricing < Stripe::RequestParams
# The ID of the price object.
sig { returns(T.nilable(String)) }
attr_accessor :price
sig { params(price: T.nilable(String)).void }
def initialize(price: nil); end
end
class TaxAmount < Stripe::RequestParams
class TaxRateData < Stripe::RequestParams
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# An arbitrary string attached to the tax rate for your internal use only. It will not be visible to your customers.
sig { returns(T.nilable(String)) }
attr_accessor :description
# The display name of the tax rate, which will be shown to users.
sig { returns(String) }
attr_accessor :display_name
# This specifies if the tax rate is inclusive or exclusive.
sig { returns(T::Boolean) }
attr_accessor :inclusive
# The jurisdiction for the tax rate. You can use this label field for tax reporting purposes. It also appears on your customer’s invoice.
sig { returns(T.nilable(String)) }
attr_accessor :jurisdiction
# The level of the jurisdiction that imposes this tax rate.
sig { returns(T.nilable(String)) }
attr_accessor :jurisdiction_level
# The statutory tax rate percent. This field accepts decimal values between 0 and 100 inclusive with at most 4 decimal places. To accommodate fixed-amount taxes, set the percentage to zero. Stripe will not display zero percentages on the invoice unless the `amount` of the tax is also zero.
sig { returns(Float) }
attr_accessor :percentage
# [ISO 3166-2 subdivision code](https://en.wikipedia.org/wiki/ISO_3166-2:US), without country prefix. For example, "NY" for New York, United States.
sig { returns(T.nilable(String)) }
attr_accessor :state
# The high-level tax type, such as `vat` or `sales_tax`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_type
sig {
params(country: T.nilable(String), description: T.nilable(String), display_name: String, inclusive: T::Boolean, jurisdiction: T.nilable(String), jurisdiction_level: T.nilable(String), percentage: Float, state: T.nilable(String), tax_type: T.nilable(String)).void
}
def initialize(
country: nil,
description: nil,
display_name: nil,
inclusive: nil,
jurisdiction: nil,
jurisdiction_level: nil,
percentage: nil,
state: nil,
tax_type: nil
); end
end
# The amount, in cents (or local equivalent), of the tax.
sig { returns(Integer) }
attr_accessor :amount
# Data to find or create a TaxRate object.
#
# Stripe automatically creates or reuses a TaxRate object for each tax amount. If the `tax_rate_data` exactly matches a previous value, Stripe will reuse the TaxRate object. TaxRate objects created automatically by Stripe are immediately archived, do not appear in the line item’s `tax_rates`, and cannot be directly added to invoices, payments, or line items.
sig { returns(::Stripe::Invoice::UpdateLinesParams::Line::TaxAmount::TaxRateData) }
attr_accessor :tax_rate_data
# The reasoning behind this tax, for example, if the product is tax exempt.
sig { returns(T.nilable(String)) }
attr_accessor :taxability_reason
# The amount on which tax is calculated, in cents (or local equivalent).
sig { returns(Integer) }
attr_accessor :taxable_amount
sig {
params(amount: Integer, tax_rate_data: ::Stripe::Invoice::UpdateLinesParams::Line::TaxAmount::TaxRateData, taxability_reason: T.nilable(String), taxable_amount: Integer).void
}
def initialize(
amount: nil,
tax_rate_data: nil,
taxability_reason: nil,
taxable_amount: nil
); end
end
# The integer amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. If you want to apply a credit to the customer's account, pass a negative amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# An arbitrary string which you can attach to the invoice item. The description is displayed in the invoice for easy tracking.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Controls whether discounts apply to this line item. Defaults to false for prorations or negative line items, and true for all other line items. Cannot be set to true for prorations.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :discountable
# The coupons, promotion codes & existing discounts which apply to the line item. Item discounts are applied before invoice discounts. Pass an empty string to remove previously-defined discounts.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Invoice::UpdateLinesParams::Line::Discount]))))
}
attr_accessor :discounts
# ID of an existing line item on the invoice.
sig { returns(String) }
attr_accessor :id
# The IDs of the margins to apply to the line item. When set, the `default_margins` on the invoice do not apply to this line item.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :margins
# 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`. For [type=subscription](https://stripe.com/docs/api/invoices/line_item#invoice_line_item_object-type) line items, the incoming metadata specified on the request is directly used to set this value, in contrast to [type=invoiceitem](api/invoices/line_item#invoice_line_item_object-type) line items, where any existing metadata on the invoice line is merged with the incoming data.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :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.
sig { returns(T.nilable(::Stripe::Invoice::UpdateLinesParams::Line::Period)) }
attr_accessor :period
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
sig { returns(T.nilable(::Stripe::Invoice::UpdateLinesParams::Line::PriceData)) }
attr_accessor :price_data
# The pricing information for the invoice item.
sig { returns(T.nilable(::Stripe::Invoice::UpdateLinesParams::Line::Pricing)) }
attr_accessor :pricing
# Non-negative integer. The quantity of units for the line item.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# A list of up to 10 tax amounts for this line item. This can be useful if you calculate taxes on your own or use a third-party to calculate them. You cannot set tax amounts if any line item has [tax_rates](https://stripe.com/docs/api/invoices/line_item#invoice_line_item_object-tax_rates) or if the invoice has [default_tax_rates](https://stripe.com/docs/api/invoices/object#invoice_object-default_tax_rates) or uses [automatic tax](https://stripe.com/docs/tax/invoicing). Pass an empty string to remove previously defined tax amounts.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Invoice::UpdateLinesParams::Line::TaxAmount]))))
}
attr_accessor :tax_amounts
# The tax rates which apply to the line item. When set, the `default_tax_rates` on the invoice do not apply to this line item. Pass an empty string to remove previously-defined tax rates.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
sig {
params(amount: T.nilable(Integer), description: T.nilable(String), discountable: T.nilable(T::Boolean), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Invoice::UpdateLinesParams::Line::Discount]))), id: String, margins: T.nilable(T.nilable(T.any(String, T::Array[String]))), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), period: T.nilable(::Stripe::Invoice::UpdateLinesParams::Line::Period), price_data: T.nilable(::Stripe::Invoice::UpdateLinesParams::Line::PriceData), pricing: T.nilable(::Stripe::Invoice::UpdateLinesParams::Line::Pricing), quantity: T.nilable(Integer), tax_amounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Invoice::UpdateLinesParams::Line::TaxAmount]))), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String])))).void
}
def initialize(
amount: nil,
description: nil,
discountable: nil,
discounts: nil,
id: nil,
margins: nil,
metadata: nil,
period: nil,
price_data: nil,
pricing: nil,
quantity: nil,
tax_amounts: nil,
tax_rates: nil
); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`. For [type=subscription](https://stripe.com/docs/api/invoices/line_item#invoice_line_item_object-type) line items, the incoming metadata specified on the request is directly used to set this value, in contrast to [type=invoiceitem](api/invoices/line_item#invoice_line_item_object-type) line items, where any existing metadata on the invoice line is merged with the incoming data.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :invoice_metadata
# The line items to update.
sig { returns(T::Array[::Stripe::Invoice::UpdateLinesParams::Line]) }
attr_accessor :lines
sig {
params(expand: T.nilable(T::Array[String]), invoice_metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), lines: T::Array[::Stripe::Invoice::UpdateLinesParams::Line]).void
}
def initialize(expand: nil, invoice_metadata: nil, lines: nil); end
end
class VoidInvoiceParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class CreatePreviewParams < Stripe::RequestParams
class AutomaticTax < Stripe::RequestParams
class Liability < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# 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.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
sig { returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::AutomaticTax::Liability)) }
attr_accessor :liability
sig {
params(enabled: T::Boolean, liability: T.nilable(::Stripe::Invoice::CreatePreviewParams::AutomaticTax::Liability)).void
}
def initialize(enabled: nil, liability: nil); end
end
class CustomerDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class Shipping < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# A freeform text field for the country. However, in order to activate some tax features, the format should be a two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Customer shipping address.
sig {
returns(::Stripe::Invoice::CreatePreviewParams::CustomerDetails::Shipping::Address)
}
attr_accessor :address
# Customer name.
sig { returns(String) }
attr_accessor :name
# Customer phone (including extension).
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(address: ::Stripe::Invoice::CreatePreviewParams::CustomerDetails::Shipping::Address, name: String, phone: T.nilable(String)).void
}
def initialize(address: nil, name: nil, phone: nil); end
end
class Tax < Stripe::RequestParams
# 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.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :ip_address
sig { params(ip_address: T.nilable(T.nilable(String))).void }
def initialize(ip_address: nil); end
end
class TaxId < Stripe::RequestParams
# Type of the tax ID, one of `ad_nrt`, `ae_trn`, `al_tin`, `am_tin`, `ao_tin`, `ar_cuit`, `au_abn`, `au_arn`, `aw_tin`, `az_tin`, `ba_tin`, `bb_tin`, `bd_bin`, `bf_ifu`, `bg_uic`, `bh_vat`, `bj_ifu`, `bo_tin`, `br_cnpj`, `br_cpf`, `bs_tin`, `by_tin`, `ca_bn`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `ca_qst`, `cd_nif`, `ch_uid`, `ch_vat`, `cl_tin`, `cm_niu`, `cn_tin`, `co_nit`, `cr_tin`, `cv_nif`, `de_stn`, `do_rcn`, `ec_ruc`, `eg_tin`, `es_cif`, `et_tin`, `eu_oss_vat`, `eu_vat`, `gb_vat`, `ge_vat`, `gn_nif`, `hk_br`, `hr_oib`, `hu_tin`, `id_npwp`, `il_vat`, `in_gst`, `is_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `ke_pin`, `kg_tin`, `kh_tin`, `kr_brn`, `kz_bin`, `la_tin`, `li_uid`, `li_vat`, `ma_vat`, `md_vat`, `me_pib`, `mk_vat`, `mr_nif`, `mx_rfc`, `my_frp`, `my_itn`, `my_sst`, `ng_tin`, `no_vat`, `no_voec`, `np_pan`, `nz_gst`, `om_vat`, `pe_ruc`, `ph_tin`, `ro_tin`, `rs_pib`, `ru_inn`, `ru_kpp`, `sa_vat`, `sg_gst`, `sg_uen`, `si_tin`, `sn_ninea`, `sr_fin`, `sv_nit`, `th_vat`, `tj_tin`, `tr_tin`, `tw_vat`, `tz_vat`, `ua_vat`, `ug_tin`, `us_ein`, `uy_ruc`, `uz_tin`, `uz_vat`, `ve_rif`, `vn_tin`, `za_vat`, `zm_tin`, or `zw_tin`
sig { returns(String) }
attr_accessor :type
# Value of the tax ID.
sig { returns(String) }
attr_accessor :value
sig { params(type: String, value: String).void }
def initialize(type: nil, value: nil); end
end
# The customer's address.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::CreatePreviewParams::CustomerDetails::Address))))
}
attr_accessor :address
# The customer's shipping information. Appears on invoices emailed to this customer.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::CreatePreviewParams::CustomerDetails::Shipping))))
}
attr_accessor :shipping
# Tax details about the customer.
sig { returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::CustomerDetails::Tax)) }
attr_accessor :tax
# The customer's tax exemption. One of `none`, `exempt`, or `reverse`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :tax_exempt
# The customer's tax IDs.
sig {
returns(T.nilable(T::Array[::Stripe::Invoice::CreatePreviewParams::CustomerDetails::TaxId]))
}
attr_accessor :tax_ids
sig {
params(address: T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::CreatePreviewParams::CustomerDetails::Address))), shipping: T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::CreatePreviewParams::CustomerDetails::Shipping))), tax: T.nilable(::Stripe::Invoice::CreatePreviewParams::CustomerDetails::Tax), tax_exempt: T.nilable(T.nilable(T.any(String, String))), tax_ids: T.nilable(T::Array[::Stripe::Invoice::CreatePreviewParams::CustomerDetails::TaxId])).void
}
def initialize(address: nil, shipping: nil, tax: nil, tax_exempt: nil, tax_ids: nil); end
end
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::Invoice::CreatePreviewParams::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig { returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::Discount::DiscountEnd)) }
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::Invoice::CreatePreviewParams::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class InvoiceItem < Stripe::RequestParams
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::InvoiceItem::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::Invoice::CreatePreviewParams::InvoiceItem::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::InvoiceItem::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::Invoice::CreatePreviewParams::InvoiceItem::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class Period < Stripe::RequestParams
# The end of the period, which must be greater than or equal to the start. This value is inclusive.
sig { returns(Integer) }
attr_accessor :end
# The start of the period. This value is inclusive.
sig { returns(Integer) }
attr_accessor :start
sig { params(end_: Integer, start: Integer).void }
def initialize(end_: nil, start: nil); end
end
class PriceData < Stripe::RequestParams
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
sig { returns(String) }
attr_accessor :product
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, product: String, tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
# The integer amount in cents (or local equivalent) of previewed invoice item.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :currency
# An arbitrary string which you can attach to the invoice item. The description is displayed in the invoice for easy tracking.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Explicitly controls whether discounts apply to this invoice item. Defaults to true, except for negative invoice items.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :discountable
# The coupons to redeem into discounts for the invoice item in the preview.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Invoice::CreatePreviewParams::InvoiceItem::Discount]))))
}
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :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.
sig { returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::InvoiceItem::Period)) }
attr_accessor :period
# The ID of the price object. One of `price` or `price_data` is required.
sig { returns(T.nilable(String)) }
attr_accessor :price
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
sig { returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::InvoiceItem::PriceData)) }
attr_accessor :price_data
# Non-negative integer. The quantity of units for the invoice item.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :tax_code
# The tax rates that apply to the item. When set, any `default_tax_rates` do not apply to this item.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :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.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(amount: T.nilable(Integer), currency: T.nilable(String), description: T.nilable(String), discountable: T.nilable(T::Boolean), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Invoice::CreatePreviewParams::InvoiceItem::Discount]))), invoiceitem: T.nilable(String), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), period: T.nilable(::Stripe::Invoice::CreatePreviewParams::InvoiceItem::Period), price: T.nilable(String), price_data: T.nilable(::Stripe::Invoice::CreatePreviewParams::InvoiceItem::PriceData), quantity: T.nilable(Integer), tax_behavior: T.nilable(String), tax_code: T.nilable(T.nilable(String)), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String]))), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
amount: nil,
currency: nil,
description: nil,
discountable: nil,
discounts: nil,
invoiceitem: nil,
metadata: nil,
period: nil,
price: nil,
price_data: nil,
quantity: nil,
tax_behavior: nil,
tax_code: nil,
tax_rates: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
class Issuer < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
class ScheduleDetails < Stripe::RequestParams
class Amendment < Stripe::RequestParams
class AmendmentEnd < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
# The ID of a specific discount.
sig { returns(String) }
attr_accessor :discount
sig { params(discount: String).void }
def initialize(discount: nil); end
end
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Use the `end` time of a given discount.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::AmendmentEnd::DiscountEnd))
}
attr_accessor :discount_end
# Time span for the amendment starting from the `amendment_start`.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::AmendmentEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the amendment to end. Must be after the `amendment_start`.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# Select one of three ways to pass the `amendment_end`.
sig { returns(String) }
attr_accessor :type
sig {
params(discount_end: T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::AmendmentEnd::DiscountEnd), duration: T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::AmendmentEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(discount_end: nil, duration: nil, timestamp: nil, type: nil); end
end
class AmendmentStart < Stripe::RequestParams
class AmendmentEnd < Stripe::RequestParams
# The position of the previous amendment in the `amendments` array after which this amendment should begin. Indexes start from 0 and must be less than the index of the current amendment in the array.
sig { returns(Integer) }
attr_accessor :index
sig { params(index: Integer).void }
def initialize(index: nil); end
end
class DiscountEnd < Stripe::RequestParams
# The ID of a specific discount.
sig { returns(String) }
attr_accessor :discount
sig { params(discount: String).void }
def initialize(discount: nil); end
end
# Details of another amendment in the same array, immediately after which this amendment should begin.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::AmendmentStart::AmendmentEnd))
}
attr_accessor :amendment_end
# Use the `end` time of a given discount.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::AmendmentStart::DiscountEnd))
}
attr_accessor :discount_end
# A precise Unix timestamp for the amendment to start.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# Select one of three ways to pass the `amendment_start`.
sig { returns(String) }
attr_accessor :type
sig {
params(amendment_end: T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::AmendmentStart::AmendmentEnd), discount_end: T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::AmendmentStart::DiscountEnd), timestamp: T.nilable(Integer), type: String).void
}
def initialize(amendment_end: nil, discount_end: nil, timestamp: nil, type: nil); end
end
class DiscountAction < Stripe::RequestParams
class Add < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
# The coupon code to redeem.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# An ID of an existing discount for a coupon that was already redeemed.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::DiscountAction::Add::DiscountEnd))
}
attr_accessor :discount_end
# The index, starting at 0, at which to position the new discount. When not supplied, Stripe defaults to appending the discount to the end of the `discounts` array.
sig { returns(T.nilable(Integer)) }
attr_accessor :index
# The promotion code to redeem.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::DiscountAction::Add::DiscountEnd), index: T.nilable(Integer), promotion_code: T.nilable(String)).void
}
def initialize(
coupon: nil,
discount: nil,
discount_end: nil,
index: nil,
promotion_code: nil
); end
end
class Remove < Stripe::RequestParams
# The coupon code to remove from the `discounts` array.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# The ID of a discount to remove from the `discounts` array.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# The ID of a promotion code to remove from the `discounts` array.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, promotion_code: nil); end
end
class Set < Stripe::RequestParams
# The coupon code to replace the `discounts` array with.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# An ID of an existing discount to replace the `discounts` array with.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# An ID of an existing promotion code to replace the `discounts` array with.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, promotion_code: nil); end
end
# Details of the discount to add.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::DiscountAction::Add))
}
attr_accessor :add
# Details of the discount to remove.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::DiscountAction::Remove))
}
attr_accessor :remove
# Details of the discount to replace the existing discounts with.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::DiscountAction::Set))
}
attr_accessor :set
# Determines the type of discount action.
sig { returns(String) }
attr_accessor :type
sig {
params(add: T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::DiscountAction::Add), remove: T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::DiscountAction::Remove), set: T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::DiscountAction::Set), type: String).void
}
def initialize(add: nil, remove: nil, set: nil, type: nil); end
end
class ItemAction < Stripe::RequestParams
class Add < Stripe::RequestParams
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction::Add::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction::Add::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction::Add::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction::Add::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(
coupon: nil,
discount: nil,
discount_end: nil,
promotion_code: nil
); end
end
class Trial < Stripe::RequestParams
# List of price IDs which, if present on the subscription following a paid trial, constitute opting-in to the paid trial. Currently only supports at most 1 price ID.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :converts_to
# Determines the type of trial for this item.
sig { returns(String) }
attr_accessor :type
sig { params(converts_to: T.nilable(T::Array[String]), type: String).void }
def initialize(converts_to: nil, type: nil); end
end
# The discounts applied to the item. Subscription item discounts are applied before subscription discounts.
sig {
returns(T.nilable(T::Array[::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction::Add::Discount]))
}
attr_accessor :discounts
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The ID of the price object.
sig { returns(String) }
attr_accessor :price
# Quantity for this item.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# The tax rates that apply to this subscription item. When set, the `default_tax_rates` on the subscription do not apply to this `subscription_item`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :tax_rates
# Options that configure the trial on the subscription item.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction::Add::Trial))
}
attr_accessor :trial
sig {
params(discounts: T.nilable(T::Array[::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction::Add::Discount]), metadata: T.nilable(T::Hash[String, String]), price: String, quantity: T.nilable(Integer), tax_rates: T.nilable(T::Array[String]), trial: T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction::Add::Trial)).void
}
def initialize(
discounts: nil,
metadata: nil,
price: nil,
quantity: nil,
tax_rates: nil,
trial: nil
); end
end
class Remove < Stripe::RequestParams
# ID of a price to remove.
sig { returns(String) }
attr_accessor :price
sig { params(price: String).void }
def initialize(price: nil); end
end
class Set < Stripe::RequestParams
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction::Set::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction::Set::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction::Set::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction::Set::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(
coupon: nil,
discount: nil,
discount_end: nil,
promotion_code: nil
); end
end
class Trial < Stripe::RequestParams
# List of price IDs which, if present on the subscription following a paid trial, constitute opting-in to the paid trial. Currently only supports at most 1 price ID.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :converts_to
# Determines the type of trial for this item.
sig { returns(String) }
attr_accessor :type
sig { params(converts_to: T.nilable(T::Array[String]), type: String).void }
def initialize(converts_to: nil, type: nil); end
end
# If an item with the `price` already exists, passing this will override the `discounts` array on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `discounts`.
sig {
returns(T.nilable(T::Array[::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction::Set::Discount]))
}
attr_accessor :discounts
# If an item with the `price` already exists, passing this will override the `metadata` on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `metadata`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The ID of the price object.
sig { returns(String) }
attr_accessor :price
# If an item with the `price` already exists, passing this will override the quantity on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `quantity`.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# If an item with the `price` already exists, passing this will override the `tax_rates` array on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `tax_rates`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :tax_rates
# If an item with the `price` already exists, passing this will override the `trial` configuration on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `trial`.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction::Set::Trial))
}
attr_accessor :trial
sig {
params(discounts: T.nilable(T::Array[::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction::Set::Discount]), metadata: T.nilable(T::Hash[String, String]), price: String, quantity: T.nilable(Integer), tax_rates: T.nilable(T::Array[String]), trial: T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction::Set::Trial)).void
}
def initialize(
discounts: nil,
metadata: nil,
price: nil,
quantity: nil,
tax_rates: nil,
trial: nil
); end
end
# Details of the subscription item to add. If an item with the same `price` exists, it will be replaced by this new item. Otherwise, it adds the new item.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction::Add))
}
attr_accessor :add
# Details of the subscription item to remove.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction::Remove))
}
attr_accessor :remove
# Details of the subscription item to replace the existing items with. If an item with the `set[price]` already exists, the `items` array is not cleared. Instead, all of the other `set` properties that are passed in this request will replace the existing values for the configuration item.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction::Set))
}
attr_accessor :set
# Determines the type of item action.
sig { returns(String) }
attr_accessor :type
sig {
params(add: T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction::Add), remove: T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction::Remove), set: T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction::Set), type: String).void
}
def initialize(add: nil, remove: nil, set: nil, type: nil); end
end
class MetadataAction < Stripe::RequestParams
# Key-value pairs to add to schedule phase metadata. These values will merge with existing schedule phase metadata.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :add
# Keys to remove from schedule phase metadata.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :remove
# Key-value pairs to set as schedule phase metadata. Existing schedule phase metadata will be overwritten.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :set
# Select one of three ways to update phase-level `metadata` on subscription schedules.
sig { returns(String) }
attr_accessor :type
sig {
params(add: T.nilable(T::Hash[String, String]), remove: T.nilable(T::Array[String]), set: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), type: String).void
}
def initialize(add: nil, remove: nil, set: nil, type: nil); end
end
class SetPauseCollection < Stripe::RequestParams
class Set < Stripe::RequestParams
# The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`.
sig { returns(String) }
attr_accessor :behavior
sig { params(behavior: String).void }
def initialize(behavior: nil); end
end
# Details of the pause_collection behavior to apply to the amendment.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::SetPauseCollection::Set))
}
attr_accessor :set
# Determines the type of the pause_collection amendment.
sig { returns(String) }
attr_accessor :type
sig {
params(set: T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::SetPauseCollection::Set), type: String).void
}
def initialize(set: nil, type: nil); end
end
class TrialSettings < Stripe::RequestParams
class EndBehavior < Stripe::RequestParams
# Configure how an opt-in following a paid trial is billed when using `billing_behavior: prorate_up_front`.
sig { returns(T.nilable(String)) }
attr_accessor :prorate_up_front
sig { params(prorate_up_front: T.nilable(String)).void }
def initialize(prorate_up_front: nil); end
end
# Defines how the subscription should behave when a trial ends.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::TrialSettings::EndBehavior))
}
attr_accessor :end_behavior
sig {
params(end_behavior: T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::TrialSettings::EndBehavior)).void
}
def initialize(end_behavior: nil); end
end
# Details to identify the end of the time range modified by the proposed change. If not supplied, the amendment is considered a point-in-time operation that only affects the exact timestamp at `amendment_start`, and a restricted set of attributes is supported on the amendment.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::AmendmentEnd))
}
attr_accessor :amendment_end
# Details to identify the earliest timestamp where the proposed change should take effect.
sig {
returns(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::AmendmentStart)
}
attr_accessor :amendment_start
# For point-in-time amendments (having no `amendment_end`), this attribute lets you set or remove whether the subscription's billing cycle anchor is reset at the `amendment_start` timestamp.For time-span based amendments (having both `amendment_start` and `amendment_end`), the only value valid is `automatic`, which removes any previously configured billing cycle anchor resets scheduled to occur during the window of time spanned by the amendment.
sig { returns(T.nilable(String)) }
attr_accessor :billing_cycle_anchor
# Changes to the coupons being redeemed or discounts being applied during the amendment time span.
sig {
returns(T.nilable(T::Array[::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::DiscountAction]))
}
attr_accessor :discount_actions
# Changes to the subscription items during the amendment time span.
sig {
returns(T.nilable(T::Array[::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction]))
}
attr_accessor :item_actions
# Instructions for how to modify phase metadata
sig {
returns(T.nilable(T::Array[::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::MetadataAction]))
}
attr_accessor :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`.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
# Defines how to pause collection for the underlying subscription throughout the duration of the amendment.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::SetPauseCollection))
}
attr_accessor :set_pause_collection
# Ends the subscription schedule early as dictated by either the accompanying amendment's start or end.
sig { returns(T.nilable(String)) }
attr_accessor :set_schedule_end
# Settings related to subscription trials.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::TrialSettings))
}
attr_accessor :trial_settings
sig {
params(amendment_end: T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::AmendmentEnd), amendment_start: ::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::AmendmentStart, billing_cycle_anchor: T.nilable(String), discount_actions: T.nilable(T::Array[::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::DiscountAction]), item_actions: T.nilable(T::Array[::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction]), metadata_actions: T.nilable(T::Array[::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::MetadataAction]), proration_behavior: T.nilable(String), set_pause_collection: T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::SetPauseCollection), set_schedule_end: T.nilable(String), trial_settings: T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment::TrialSettings)).void
}
def initialize(
amendment_end: nil,
amendment_start: nil,
billing_cycle_anchor: nil,
discount_actions: nil,
item_actions: nil,
metadata_actions: nil,
proration_behavior: nil,
set_pause_collection: nil,
set_schedule_end: nil,
trial_settings: nil
); end
end
class Phase < Stripe::RequestParams
class AddInvoiceItem < Stripe::RequestParams
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::AddInvoiceItem::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::AddInvoiceItem::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::AddInvoiceItem::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::AddInvoiceItem::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(
coupon: nil,
discount: nil,
discount_end: nil,
promotion_code: nil
); end
end
class PriceData < Stripe::RequestParams
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
sig { returns(String) }
attr_accessor :product
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge or a negative integer representing the amount to credit to the customer.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, product: String, tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
# The coupons to redeem into discounts for the item.
sig {
returns(T.nilable(T::Array[::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::AddInvoiceItem::Discount]))
}
attr_accessor :discounts
# The ID of the price object. One of `price` or `price_data` is required.
sig { returns(T.nilable(String)) }
attr_accessor :price
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::AddInvoiceItem::PriceData))
}
attr_accessor :price_data
# Quantity for this item. Defaults to 1.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# The tax rates which apply to the item. When set, the `default_tax_rates` do not apply to this item.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
sig {
params(discounts: T.nilable(T::Array[::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::AddInvoiceItem::Discount]), price: T.nilable(String), price_data: T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::AddInvoiceItem::PriceData), quantity: T.nilable(Integer), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String])))).void
}
def initialize(
discounts: nil,
price: nil,
price_data: nil,
quantity: nil,
tax_rates: nil
); end
end
class AutomaticTax < Stripe::RequestParams
class Liability < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# Enabled automatic tax calculation which will automatically compute tax rates on all invoices generated by the subscription.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::AutomaticTax::Liability))
}
attr_accessor :liability
sig {
params(enabled: T::Boolean, liability: T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::AutomaticTax::Liability)).void
}
def initialize(enabled: nil, liability: nil); end
end
class BillingThresholds < Stripe::RequestParams
# Monetary threshold that triggers the subscription to advance to a new billing period
sig { returns(T.nilable(Integer)) }
attr_accessor :amount_gte
# Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :reset_billing_cycle_anchor
sig {
params(amount_gte: T.nilable(Integer), reset_billing_cycle_anchor: T.nilable(T::Boolean)).void
}
def initialize(amount_gte: nil, reset_billing_cycle_anchor: nil); end
end
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class InvoiceSettings < Stripe::RequestParams
class Issuer < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# The account tax IDs associated with this phase of the subscription schedule. Will be set on invoices generated by this phase of the subscription schedule.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :account_tax_ids
# Number of days within which a customer must pay invoices generated by this subscription schedule. This value will be `null` for subscription schedules where `billing=charge_automatically`.
sig { returns(T.nilable(Integer)) }
attr_accessor :days_until_due
# The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::InvoiceSettings::Issuer))
}
attr_accessor :issuer
sig {
params(account_tax_ids: T.nilable(T.nilable(T.any(String, T::Array[String]))), days_until_due: T.nilable(Integer), issuer: T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::InvoiceSettings::Issuer)).void
}
def initialize(account_tax_ids: nil, days_until_due: nil, issuer: nil); end
end
class Item < Stripe::RequestParams
class BillingThresholds < Stripe::RequestParams
# Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))
sig { returns(Integer) }
attr_accessor :usage_gte
sig { params(usage_gte: Integer).void }
def initialize(usage_gte: nil); end
end
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::Item::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::Item::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::Item::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::Item::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(
coupon: nil,
discount: nil,
discount_end: nil,
promotion_code: nil
); end
end
class PriceData < Stripe::RequestParams
class Recurring < Stripe::RequestParams
# Specifies billing frequency. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: T.nilable(Integer)).void }
def initialize(interval: nil, interval_count: nil); end
end
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
sig { returns(String) }
attr_accessor :product
# The recurring components of a price such as `interval` and `interval_count`.
sig {
returns(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::Item::PriceData::Recurring)
}
attr_accessor :recurring
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, product: String, recurring: ::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::Item::PriceData::Recurring, tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
recurring: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
class Trial < Stripe::RequestParams
# List of price IDs which, if present on the subscription following a paid trial, constitute opting-in to the paid trial. Currently only supports at most 1 price ID.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :converts_to
# Determines the type of trial for this item.
sig { returns(String) }
attr_accessor :type
sig { params(converts_to: T.nilable(T::Array[String]), type: String).void }
def initialize(converts_to: nil, type: nil); end
end
# Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::Item::BillingThresholds))))
}
attr_accessor :billing_thresholds
# The coupons to redeem into discounts for the subscription item.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::Item::Discount]))))
}
attr_accessor :discounts
# Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to a configuration item. Metadata on a configuration item will update the underlying subscription item's `metadata` when the phase is entered, adding new keys and replacing existing keys. Individual keys in the subscription item's `metadata` can be unset by posting an empty value to them in the configuration item's `metadata`. To unset all keys in the subscription item's `metadata`, update the subscription item directly or unset every key individually from the configuration item's `metadata`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The plan ID to subscribe to. You may specify the same ID in `plan` and `price`.
sig { returns(T.nilable(String)) }
attr_accessor :plan
# The ID of the price object.
sig { returns(T.nilable(String)) }
attr_accessor :price
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::Item::PriceData))
}
attr_accessor :price_data
# Quantity for the given price. Can be set only if the price's `usage_type` is `licensed` and not `metered`.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
# Options that configure the trial on the subscription item.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::Item::Trial))
}
attr_accessor :trial
sig {
params(billing_thresholds: T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::Item::BillingThresholds))), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::Item::Discount]))), metadata: T.nilable(T::Hash[String, String]), plan: T.nilable(String), price: T.nilable(String), price_data: T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::Item::PriceData), quantity: T.nilable(Integer), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String]))), trial: T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::Item::Trial)).void
}
def initialize(
billing_thresholds: nil,
discounts: nil,
metadata: nil,
plan: nil,
price: nil,
price_data: nil,
quantity: nil,
tax_rates: nil,
trial: nil
); end
end
class PauseCollection < Stripe::RequestParams
# The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`.
sig { returns(String) }
attr_accessor :behavior
sig { params(behavior: String).void }
def initialize(behavior: nil); end
end
class TransferData < Stripe::RequestParams
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
sig { returns(T.nilable(Float)) }
attr_accessor :amount_percent
# ID of an existing, connected Stripe account.
sig { returns(String) }
attr_accessor :destination
sig { params(amount_percent: T.nilable(Float), destination: String).void }
def initialize(amount_percent: nil, destination: nil); end
end
class TrialSettings < Stripe::RequestParams
class EndBehavior < Stripe::RequestParams
# Configure how an opt-in following a paid trial is billed when using `billing_behavior: prorate_up_front`.
sig { returns(T.nilable(String)) }
attr_accessor :prorate_up_front
sig { params(prorate_up_front: T.nilable(String)).void }
def initialize(prorate_up_front: nil); end
end
# Defines how the subscription should behave when a trial ends.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::TrialSettings::EndBehavior))
}
attr_accessor :end_behavior
sig {
params(end_behavior: T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::TrialSettings::EndBehavior)).void
}
def initialize(end_behavior: nil); end
end
# A list of prices and quantities that will generate invoice items appended to the next invoice for this phase. You may pass up to 20 items.
sig {
returns(T.nilable(T::Array[::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::AddInvoiceItem]))
}
attr_accessor :add_invoice_items
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).
sig { returns(T.nilable(Float)) }
attr_accessor :application_fee_percent
# Automatic tax settings for this phase.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::AutomaticTax))
}
attr_accessor :automatic_tax
# Can be set to `phase_start` to set the anchor to the start of the phase or `automatic` to automatically change it if needed. Cannot be set to `phase_start` if this phase specifies a trial. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).
sig { returns(T.nilable(String)) }
attr_accessor :billing_cycle_anchor
# Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::BillingThresholds))))
}
attr_accessor :billing_thresholds
# Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically` on creation.
sig { returns(T.nilable(String)) }
attr_accessor :collection_method
# 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).
sig { returns(T.nilable(String)) }
attr_accessor :currency
# ID of the default payment method for the subscription schedule. It must belong to the customer associated with the subscription schedule. If not set, invoices will use the default payment method in the customer's invoice settings.
sig { returns(T.nilable(String)) }
attr_accessor :default_payment_method
# A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will set the Subscription's [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates), which means they will be the Invoice's [`default_tax_rates`](https://stripe.com/docs/api/invoices/create#create_invoice-default_tax_rates) for any Invoices issued by the Subscription during this Phase.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :default_tax_rates
# Subscription description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :description
# The coupons to redeem into discounts for the schedule phase. If not specified, inherits the discount from the subscription's customer. Pass an empty string to avoid inheriting any discounts.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::Discount]))))
}
attr_accessor :discounts
# The date at which this phase of the subscription schedule ends. If set, `iterations` must not be set.
sig { returns(T.nilable(T.any(Integer, String))) }
attr_accessor :end_date
# All invoices will be billed using the specified settings.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::InvoiceSettings))
}
attr_accessor :invoice_settings
# List of configuration items, each with an attached price, to apply during this phase of the subscription schedule.
sig {
returns(T::Array[::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::Item])
}
attr_accessor :items
# Integer representing the multiplier applied to the price interval. For example, `iterations=2` applied to a price with `interval=month` and `interval_count=3` results in a phase of duration `2 * 3 months = 6 months`. If set, `end_date` must not be set.
sig { returns(T.nilable(Integer)) }
attr_accessor :iterations
# Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to a phase. Metadata on a schedule's phase will update the underlying subscription's `metadata` when the phase is entered, adding new keys and replacing existing keys in the subscription's `metadata`. Individual keys in the subscription's `metadata` can be unset by posting an empty value to them in the phase's `metadata`. To unset all keys in the subscription's `metadata`, update the subscription directly or unset every key individually from the phase's `metadata`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The account on behalf of which to charge, for each of the associated subscription's invoices.
sig { returns(T.nilable(String)) }
attr_accessor :on_behalf_of
# If specified, payment collection for this subscription will be paused. Note that the subscription status will be unchanged and will not be updated to `paused`. Learn more about [pausing collection](https://stripe.com/docs/billing/subscriptions/pause-payment).
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::PauseCollection))
}
attr_accessor :pause_collection
# Controls whether the subscription schedule should create [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when transitioning to this phase if there is a difference in billing configuration. 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 (item price, quantity, etc.) of the current phase.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
# The date at which this phase of the subscription schedule starts or `now`. Must be set on the first phase.
sig { returns(T.nilable(T.any(Integer, String))) }
attr_accessor :start_date
# The data with which to automatically create a Transfer for each of the associated subscription's invoices.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::TransferData))
}
attr_accessor :transfer_data
# If set to true the entire phase is counted as a trial and the customer will not be charged for any fees.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :trial
# Specify trial behavior when crossing phase boundaries
sig { returns(T.nilable(String)) }
attr_accessor :trial_continuation
# Sets the phase to trialing from the start date to this date. Must be before the phase end date, can not be combined with `trial`
sig { returns(T.nilable(T.any(Integer, String))) }
attr_accessor :trial_end
# Settings related to subscription trials.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::TrialSettings))
}
attr_accessor :trial_settings
sig {
params(add_invoice_items: T.nilable(T::Array[::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::AddInvoiceItem]), application_fee_percent: T.nilable(Float), automatic_tax: T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::AutomaticTax), billing_cycle_anchor: T.nilable(String), billing_thresholds: T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::BillingThresholds))), collection_method: T.nilable(String), currency: T.nilable(String), default_payment_method: T.nilable(String), default_tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String]))), description: T.nilable(T.nilable(String)), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::Discount]))), end_date: T.nilable(T.any(Integer, String)), invoice_settings: T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::InvoiceSettings), items: T::Array[::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::Item], iterations: T.nilable(Integer), metadata: T.nilable(T::Hash[String, String]), on_behalf_of: T.nilable(String), pause_collection: T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::PauseCollection), proration_behavior: T.nilable(String), start_date: T.nilable(T.any(Integer, String)), transfer_data: T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::TransferData), trial: T.nilable(T::Boolean), trial_continuation: T.nilable(String), trial_end: T.nilable(T.any(Integer, String)), trial_settings: T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase::TrialSettings)).void
}
def initialize(
add_invoice_items: nil,
application_fee_percent: nil,
automatic_tax: nil,
billing_cycle_anchor: nil,
billing_thresholds: nil,
collection_method: nil,
currency: nil,
default_payment_method: nil,
default_tax_rates: nil,
description: nil,
discounts: nil,
end_date: nil,
invoice_settings: nil,
items: nil,
iterations: nil,
metadata: nil,
on_behalf_of: nil,
pause_collection: nil,
proration_behavior: nil,
start_date: nil,
transfer_data: nil,
trial: nil,
trial_continuation: nil,
trial_end: nil,
trial_settings: nil
); end
end
class Prebilling < Stripe::RequestParams
class BillUntil < Stripe::RequestParams
class AmendmentEnd < Stripe::RequestParams
# The position of the amendment in the `amendments` array at which prebilling should end. Indexes start from 0 and must be less than the total number of supplied amendments.
sig { returns(Integer) }
attr_accessor :index
sig { params(index: Integer).void }
def initialize(index: nil); end
end
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# End the prebilled period when a specified amendment ends.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Prebilling::BillUntil::AmendmentEnd))
}
attr_accessor :amendment_end
# Time span for prebilling, starting from `bill_from`.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Prebilling::BillUntil::Duration))
}
attr_accessor :duration
# End the prebilled period at a precise integer timestamp, starting from the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# Select one of several ways to pass the `bill_until` value.
sig { returns(String) }
attr_accessor :type
sig {
params(amendment_end: T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Prebilling::BillUntil::AmendmentEnd), duration: T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Prebilling::BillUntil::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(amendment_end: nil, duration: nil, timestamp: nil, type: nil); end
end
# The end of the prebilled time period.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Prebilling::BillUntil))
}
attr_accessor :bill_until
# This is used to determine the number of billing cycles to prebill.
sig { returns(T.nilable(Integer)) }
attr_accessor :iterations
sig {
params(bill_until: T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Prebilling::BillUntil), iterations: T.nilable(Integer)).void
}
def initialize(bill_until: nil, iterations: nil); end
end
# Changes to apply to the phases of the subscription schedule, in the order provided.
sig {
returns(T.nilable(T::Array[::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment]))
}
attr_accessor :amendments
# Configures when the subscription schedule generates prorations for phase transitions. Possible values are `prorate_on_next_phase` or `prorate_up_front` with the default being `prorate_on_next_phase`. `prorate_on_next_phase` will apply phase changes and generate prorations at transition time. `prorate_up_front` will bill for all phases within the current billing cycle up front.
sig { returns(T.nilable(String)) }
attr_accessor :billing_behavior
# Controls how prorations and invoices for subscriptions are calculated and orchestrated.
sig { returns(T.nilable(String)) }
attr_accessor :billing_mode
# Behavior of the subscription schedule and underlying subscription when it ends. Possible values are `release` or `cancel` with the default being `release`. `release` will end the subscription schedule and keep the underlying subscription running. `cancel` will end the subscription schedule and cancel the underlying subscription.
sig { returns(T.nilable(String)) }
attr_accessor :end_behavior
# List representing phases of the subscription schedule. Each phase can be customized to have different durations, plans, and coupons. If there are multiple phases, the `end_date` of one phase will always equal the `start_date` of the next phase.
sig {
returns(T.nilable(T::Array[::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase]))
}
attr_accessor :phases
# Provide any time periods to bill in advance.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Prebilling]))))
}
attr_accessor :prebilling
# In cases where the `schedule_details` params update the currently active phase, specifies if and how to prorate at the time of the request.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
sig {
params(amendments: T.nilable(T::Array[::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Amendment]), billing_behavior: T.nilable(String), billing_mode: T.nilable(String), end_behavior: T.nilable(String), phases: T.nilable(T::Array[::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Phase]), prebilling: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Invoice::CreatePreviewParams::ScheduleDetails::Prebilling]))), proration_behavior: T.nilable(String)).void
}
def initialize(
amendments: nil,
billing_behavior: nil,
billing_mode: nil,
end_behavior: nil,
phases: nil,
prebilling: nil,
proration_behavior: nil
); end
end
class SubscriptionDetails < Stripe::RequestParams
class Item < Stripe::RequestParams
class BillingThresholds < Stripe::RequestParams
# Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))
sig { returns(Integer) }
attr_accessor :usage_gte
sig { params(usage_gte: Integer).void }
def initialize(usage_gte: nil); end
end
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::SubscriptionDetails::Item::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::Invoice::CreatePreviewParams::SubscriptionDetails::Item::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::SubscriptionDetails::Item::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::Invoice::CreatePreviewParams::SubscriptionDetails::Item::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class PriceData < Stripe::RequestParams
class Recurring < Stripe::RequestParams
# Specifies billing frequency. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: T.nilable(Integer)).void }
def initialize(interval: nil, interval_count: nil); end
end
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
sig { returns(String) }
attr_accessor :product
# The recurring components of a price such as `interval` and `interval_count`.
sig {
returns(::Stripe::Invoice::CreatePreviewParams::SubscriptionDetails::Item::PriceData::Recurring)
}
attr_accessor :recurring
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, product: String, recurring: ::Stripe::Invoice::CreatePreviewParams::SubscriptionDetails::Item::PriceData::Recurring, tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
recurring: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
# Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::CreatePreviewParams::SubscriptionDetails::Item::BillingThresholds))))
}
attr_accessor :billing_thresholds
# Delete all usage for a given subscription item. You must pass this when deleting a usage records subscription item. `clear_usage` has no effect if the plan has a billing meter attached.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :clear_usage
# A flag that, if set to `true`, will delete the specified item.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :deleted
# The coupons to redeem into discounts for the subscription item.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Invoice::CreatePreviewParams::SubscriptionDetails::Item::Discount]))))
}
attr_accessor :discounts
# Subscription item to update.
sig { returns(T.nilable(String)) }
attr_accessor :id
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Plan ID for this item, as a string.
sig { returns(T.nilable(String)) }
attr_accessor :plan
# The ID of the price object. One of `price` or `price_data` is required. When changing a subscription item's price, `quantity` is set to 1 unless a `quantity` parameter is provided.
sig { returns(T.nilable(String)) }
attr_accessor :price
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::SubscriptionDetails::Item::PriceData))
}
attr_accessor :price_data
# Quantity for this item.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
sig {
params(billing_thresholds: T.nilable(T.nilable(T.any(String, ::Stripe::Invoice::CreatePreviewParams::SubscriptionDetails::Item::BillingThresholds))), clear_usage: T.nilable(T::Boolean), deleted: T.nilable(T::Boolean), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Invoice::CreatePreviewParams::SubscriptionDetails::Item::Discount]))), id: T.nilable(String), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), plan: T.nilable(String), price: T.nilable(String), price_data: T.nilable(::Stripe::Invoice::CreatePreviewParams::SubscriptionDetails::Item::PriceData), quantity: T.nilable(Integer), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String])))).void
}
def initialize(
billing_thresholds: nil,
clear_usage: nil,
deleted: nil,
discounts: nil,
id: nil,
metadata: nil,
plan: nil,
price: nil,
price_data: nil,
quantity: nil,
tax_rates: nil
); end
end
class Prebilling < Stripe::RequestParams
# This is used to determine the number of billing cycles to prebill.
sig { returns(Integer) }
attr_accessor :iterations
sig { params(iterations: Integer).void }
def initialize(iterations: nil); end
end
# 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`.
sig { returns(T.nilable(T.any(String, Integer))) }
attr_accessor :billing_cycle_anchor
# Controls how prorations and invoices for subscriptions are calculated and orchestrated.
sig { returns(T.nilable(String)) }
attr_accessor :billing_mode
# A timestamp at which the subscription should cancel. If set to a date before the current period ends, this will cause a proration if prorations have been enabled using `proration_behavior`. If set during a future period, this will always cause a proration for that period.
sig { returns(T.nilable(T.nilable(T.any(String, T.any(Integer, String))))) }
attr_accessor :cancel_at
# Indicate whether this subscription should cancel at the end of the current period (`current_period_end`). Defaults to `false`. This param will be removed in a future API version. Please use `cancel_at` instead.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :cancel_at_period_end
# This simulates the subscription being canceled or expired immediately.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :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.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :default_tax_rates
# A list of up to 20 subscription items, each with an attached price.
sig {
returns(T.nilable(T::Array[::Stripe::Invoice::CreatePreviewParams::SubscriptionDetails::Item]))
}
attr_accessor :items
# The pre-billing to apply to the subscription as a preview.
sig {
returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::SubscriptionDetails::Prebilling))
}
attr_accessor :prebilling
# Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/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`.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
# If previewing an update to a subscription, and doing proration, `subscription_details.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_details.items`, or `subscription_details.trial_end` are required. Also, `subscription_details.proration_behavior` cannot be set to 'none'.
sig { returns(T.nilable(Integer)) }
attr_accessor :proration_date
# For paused subscriptions, setting `subscription_details.resume_at` to `now` will preview the invoice that will be generated if the subscription is resumed.
sig { returns(T.nilable(String)) }
attr_accessor :resume_at
# Date a subscription is intended to start (can be future or past).
sig { returns(T.nilable(Integer)) }
attr_accessor :start_date
# If provided, the invoice returned will preview updating or creating a subscription with that trial end. If set, one of `subscription_details.items` or `subscription` is required.
sig { returns(T.nilable(T.any(String, Integer))) }
attr_accessor :trial_end
sig {
params(billing_cycle_anchor: T.nilable(T.any(String, Integer)), billing_mode: T.nilable(String), cancel_at: T.nilable(T.nilable(T.any(String, T.any(Integer, String)))), cancel_at_period_end: T.nilable(T::Boolean), cancel_now: T.nilable(T::Boolean), default_tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String]))), items: T.nilable(T::Array[::Stripe::Invoice::CreatePreviewParams::SubscriptionDetails::Item]), prebilling: T.nilable(::Stripe::Invoice::CreatePreviewParams::SubscriptionDetails::Prebilling), proration_behavior: T.nilable(String), proration_date: T.nilable(Integer), resume_at: T.nilable(String), start_date: T.nilable(Integer), trial_end: T.nilable(T.any(String, Integer))).void
}
def initialize(
billing_cycle_anchor: nil,
billing_mode: nil,
cancel_at: nil,
cancel_at_period_end: nil,
cancel_now: nil,
default_tax_rates: nil,
items: nil,
prebilling: nil,
proration_behavior: nil,
proration_date: nil,
resume_at: nil,
start_date: nil,
trial_end: nil
); end
end
# Settings for automatic tax lookup for this invoice preview.
sig { returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::AutomaticTax)) }
attr_accessor :automatic_tax
# The currency to preview this invoice in. Defaults to that of `customer` if not specified.
sig { returns(T.nilable(String)) }
attr_accessor :currency
# The identifier of the customer whose upcoming invoice you'd like to retrieve. If `automatic_tax` is enabled then one of `customer`, `customer_details`, `subscription`, or `schedule` must be set.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# The identifier of the account whose upcoming invoice you'd like to retrieve. If `automatic_tax` is enabled then one of `customer`, `customer_account`, `customer_details`, `subscription`, or `schedule` must be set.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# Details about the customer you want to invoice or overrides for an existing customer. If `automatic_tax` is enabled then one of `customer`, `customer_details`, `subscription`, or `schedule` must be set.
sig { returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::CustomerDetails)) }
attr_accessor :customer_details
# The coupons to redeem into discounts for the invoice preview. If not specified, inherits the discount from the subscription or customer. This works for both coupons directly applied to an invoice and coupons applied to a subscription. Pass an empty string to avoid inheriting any discounts.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Invoice::CreatePreviewParams::Discount]))))
}
attr_accessor :discounts
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# List of invoice items to add or update in the upcoming invoice preview (up to 250).
sig { returns(T.nilable(T::Array[::Stripe::Invoice::CreatePreviewParams::InvoiceItem])) }
attr_accessor :invoice_items
# The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
sig { returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::Issuer)) }
attr_accessor :issuer
# The account (if any) for which the funds of the invoice payment are intended. If set, the invoice will be presented with the branding and support information of the specified account. See the [Invoices with Connect](https://stripe.com/docs/billing/invoices/connect) documentation for details.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :on_behalf_of
# Customizes the types of values to include when calculating the invoice. Defaults to `next` if unspecified.
sig { returns(T.nilable(String)) }
attr_accessor :preview_mode
# The identifier of the schedule whose upcoming invoice you'd like to retrieve. Cannot be used with subscription or subscription fields.
sig { returns(T.nilable(String)) }
attr_accessor :schedule
# The schedule creation or modification params to apply as a preview. Cannot be used with `subscription` or `subscription_` prefixed fields.
sig { returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails)) }
attr_accessor :schedule_details
# The identifier of the subscription for which you'd like to retrieve the upcoming invoice. If not provided, but a `subscription_details.items` is provided, you will preview creating a subscription with those items. If neither `subscription` nor `subscription_details.items` is provided, you will retrieve the next upcoming invoice from among the customer's subscriptions.
sig { returns(T.nilable(String)) }
attr_accessor :subscription
# The subscription creation or modification params to apply as a preview. Cannot be used with `schedule` or `schedule_details` fields.
sig { returns(T.nilable(::Stripe::Invoice::CreatePreviewParams::SubscriptionDetails)) }
attr_accessor :subscription_details
sig {
params(automatic_tax: T.nilable(::Stripe::Invoice::CreatePreviewParams::AutomaticTax), currency: T.nilable(String), customer: T.nilable(String), customer_account: T.nilable(String), customer_details: T.nilable(::Stripe::Invoice::CreatePreviewParams::CustomerDetails), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Invoice::CreatePreviewParams::Discount]))), expand: T.nilable(T::Array[String]), invoice_items: T.nilable(T::Array[::Stripe::Invoice::CreatePreviewParams::InvoiceItem]), issuer: T.nilable(::Stripe::Invoice::CreatePreviewParams::Issuer), on_behalf_of: T.nilable(T.nilable(String)), preview_mode: T.nilable(String), schedule: T.nilable(String), schedule_details: T.nilable(::Stripe::Invoice::CreatePreviewParams::ScheduleDetails), subscription: T.nilable(String), subscription_details: T.nilable(::Stripe::Invoice::CreatePreviewParams::SubscriptionDetails)).void
}
def initialize(
automatic_tax: nil,
currency: nil,
customer: nil,
customer_account: nil,
customer_details: nil,
discounts: nil,
expand: nil,
invoice_items: nil,
issuer: nil,
on_behalf_of: nil,
preview_mode: nil,
schedule: nil,
schedule_details: nil,
subscription: nil,
subscription_details: nil
); end
end
# Adds multiple line items to an invoice. This is only possible when an invoice is still a draft.
sig {
params(params: T.any(::Stripe::Invoice::AddLinesParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Invoice)
}
def add_lines(params = {}, opts = {}); end
# Adds multiple line items to an invoice. This is only possible when an invoice is still a draft.
sig {
params(invoice: String, params: T.any(::Stripe::Invoice::AddLinesParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Invoice)
}
def self.add_lines(invoice, params = {}, opts = {}); end
# Attaches a PaymentIntent or an Out of Band Payment to the invoice, adding it to the list of payments.
#
# For the PaymentIntent, when the PaymentIntent's status changes to succeeded, the payment is credited
# to the invoice, increasing its amount_paid. When the invoice is fully paid, the
# invoice's status becomes paid.
#
# If the PaymentIntent's status is already succeeded when it's attached, it's
# credited to the invoice immediately.
#
# See: [Partial payments](https://docs.stripe.com/docs/invoicing/partial-payments) to learn more.
sig {
params(params: T.any(::Stripe::Invoice::AttachPaymentParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Invoice)
}
def attach_payment(params = {}, opts = {}); end
# Attaches a PaymentIntent or an Out of Band Payment to the invoice, adding it to the list of payments.
#
# For the PaymentIntent, when the PaymentIntent's status changes to succeeded, the payment is credited
# to the invoice, increasing its amount_paid. When the invoice is fully paid, the
# invoice's status becomes paid.
#
# If the PaymentIntent's status is already succeeded when it's attached, it's
# credited to the invoice immediately.
#
# See: [Partial payments](https://docs.stripe.com/docs/invoicing/partial-payments) to learn more.
sig {
params(invoice: String, params: T.any(::Stripe::Invoice::AttachPaymentParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Invoice)
}
def self.attach_payment(invoice, params = {}, opts = {}); end
# 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://docs.stripe.com/api#finalize_invoice) the invoice to your customers.
sig {
params(params: T.any(::Stripe::Invoice::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Invoice)
}
def self.create(params = {}, opts = {}); end
# At any time, you can preview the upcoming invoice for a subscription or subscription schedule. 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.
#
# You can also preview the effects of creating or updating a subscription or subscription schedule, including a preview of any prorations that will take place. To ensure that the actual proration is calculated exactly the same as the previewed proration, you should pass the subscription_details.proration_date parameter when doing the actual subscription update.
#
# The recommended way to get only the prorations being previewed on the invoice is to consider line items where parent.subscription_item_details.proration is true.
#
# 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.
#
# Note: Currency conversion calculations use the latest exchange rates. Exchange rates may vary between the time of the preview and the time of the actual invoice creation. [Learn more](https://docs.stripe.com/currencies/conversions)
sig {
params(params: T.any(::Stripe::Invoice::CreatePreviewParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Invoice)
}
def self.create_preview(params = {}, opts = {}); end
# Permanently deletes a one-off invoice draft. This cannot be undone. Attempts to delete invoices that are no longer in a draft state will fail; once an invoice has been finalized or if an invoice is for a subscription, it must be [voided](https://docs.stripe.com/api#void_invoice).
sig {
params(invoice: String, params: T.any(::Stripe::Invoice::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Invoice)
}
def self.delete(invoice, params = {}, opts = {}); end
# Permanently deletes a one-off invoice draft. This cannot be undone. Attempts to delete invoices that are no longer in a draft state will fail; once an invoice has been finalized or if an invoice is for a subscription, it must be [voided](https://docs.stripe.com/api#void_invoice).
sig {
params(params: T.any(::Stripe::Invoice::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Invoice)
}
def delete(params = {}, opts = {}); end
# Stripe automatically finalizes drafts before sending and attempting payment on invoices. However, if you'd like to finalize a draft invoice manually, you can do so using this method.
sig {
params(params: T.any(::Stripe::Invoice::FinalizeInvoiceParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Invoice)
}
def finalize_invoice(params = {}, opts = {}); end
# Stripe automatically finalizes drafts before sending and attempting payment on invoices. However, if you'd like to finalize a draft invoice manually, you can do so using this method.
sig {
params(invoice: String, params: T.any(::Stripe::Invoice::FinalizeInvoiceParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Invoice)
}
def self.finalize_invoice(invoice, params = {}, opts = {}); end
# 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.
sig {
params(params: T.any(::Stripe::Invoice::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Marking an invoice as uncollectible is useful for keeping track of bad debts that can be written off for accounting purposes.
sig {
params(params: T.any(::Stripe::Invoice::MarkUncollectibleParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Invoice)
}
def mark_uncollectible(params = {}, opts = {}); end
# Marking an invoice as uncollectible is useful for keeping track of bad debts that can be written off for accounting purposes.
sig {
params(invoice: String, params: T.any(::Stripe::Invoice::MarkUncollectibleParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Invoice)
}
def self.mark_uncollectible(invoice, params = {}, opts = {}); end
# 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.
sig {
params(params: T.any(::Stripe::Invoice::PayParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Invoice)
}
def pay(params = {}, opts = {}); end
# 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.
sig {
params(invoice: String, params: T.any(::Stripe::Invoice::PayParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Invoice)
}
def self.pay(invoice, params = {}, opts = {}); end
# Removes multiple line items from an invoice. This is only possible when an invoice is still a draft.
sig {
params(params: T.any(::Stripe::Invoice::RemoveLinesParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Invoice)
}
def remove_lines(params = {}, opts = {}); end
# Removes multiple line items from an invoice. This is only possible when an invoice is still a draft.
sig {
params(invoice: String, params: T.any(::Stripe::Invoice::RemoveLinesParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Invoice)
}
def self.remove_lines(invoice, params = {}, opts = {}); end
sig {
params(params: T.any(::Stripe::Invoice::SearchParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SearchResultObject)
}
def self.search(params = {}, opts = {}); end
sig {
params(params: T.any(::Stripe::Invoice::SearchParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped, blk: T.untyped).returns(Stripe::SearchResultObject)
}
def self.search_auto_paging_each(params = {}, opts = {}, &blk); end
# 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.
sig {
params(params: T.any(::Stripe::Invoice::SendInvoiceParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Invoice)
}
def send_invoice(params = {}, opts = {}); end
# 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.
sig {
params(invoice: String, params: T.any(::Stripe::Invoice::SendInvoiceParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Invoice)
}
def self.send_invoice(invoice, params = {}, opts = {}); end
# Draft invoices are fully editable. Once an invoice is [finalized](https://docs.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://docs.stripe.com/docs/billing/invoices/reconciliation) invoices, pass
# auto_advance=false.
sig {
params(invoice: String, params: T.any(::Stripe::Invoice::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Invoice)
}
def self.update(invoice, params = {}, opts = {}); end
# Updates multiple line items on an invoice. This is only possible when an invoice is still a draft.
sig {
params(params: T.any(::Stripe::Invoice::UpdateLinesParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Invoice)
}
def update_lines(params = {}, opts = {}); end
# Updates multiple line items on an invoice. This is only possible when an invoice is still a draft.
sig {
params(invoice: String, params: T.any(::Stripe::Invoice::UpdateLinesParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Invoice)
}
def self.update_lines(invoice, params = {}, opts = {}); end
# Mark a finalized invoice as void. This cannot be undone. Voiding an invoice is similar to [deletion](https://docs.stripe.com/api#delete_invoice), however it only applies to finalized invoices and maintains a papertrail where the invoice can still be found.
#
# Consult with local regulations to determine whether and how an invoice might be amended, canceled, or voided in the jurisdiction you're doing business in. You might need to [issue another invoice or credit note](https://docs.stripe.com/api#create_invoice) instead. Stripe recommends that you consult with your legal counsel for advice specific to your business.
sig {
params(params: T.any(::Stripe::Invoice::VoidInvoiceParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Invoice)
}
def void_invoice(params = {}, opts = {}); end
# Mark a finalized invoice as void. This cannot be undone. Voiding an invoice is similar to [deletion](https://docs.stripe.com/api#delete_invoice), however it only applies to finalized invoices and maintains a papertrail where the invoice can still be found.
#
# Consult with local regulations to determine whether and how an invoice might be amended, canceled, or voided in the jurisdiction you're doing business in. You might need to [issue another invoice or credit note](https://docs.stripe.com/api#create_invoice) instead. Stripe recommends that you consult with your legal counsel for advice specific to your business.
sig {
params(invoice: String, params: T.any(::Stripe::Invoice::VoidInvoiceParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Invoice)
}
def self.void_invoice(invoice, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
# Invoice Payments represent payments made against invoices. Invoice Payments can
# be accessed in two ways:
# 1. By expanding the `payments` field on the [Invoice](https://stripe.com/docs/api#invoice) resource.
# 2. By using the Invoice Payment retrieve and list endpoints.
#
# Invoice Payments include the mapping between payment objects, such as Payment Intent, and Invoices.
# This resource and its endpoints allows you to easily track if a payment is associated with a specific invoice and
# monitor the allocation details of the payments.
class InvoicePayment < APIResource
class Payment < Stripe::StripeObject
# ID of the successful charge for this payment when `type` is `charge`.Note: charge is only surfaced if the charge object is not associated with a payment intent. If the charge object does have a payment intent, the Invoice Payment surfaces the payment intent instead.
sig { returns(T.any(String, Stripe::Charge)) }
attr_reader :charge
# ID of the PaymentIntent associated with this payment when `type` is `payment_intent`. Note: This property is only populated for invoices finalized on or after March 15th, 2019.
sig { returns(T.any(String, Stripe::PaymentIntent)) }
attr_reader :payment_intent
# ID of the PaymentRecord associated with this payment when `type` is `payment_record`.
sig { returns(T.any(String, Stripe::PaymentRecord)) }
attr_reader :payment_record
# Type of payment object associated with this invoice payment.
sig { returns(String) }
attr_reader :type
end
class StatusTransitions < Stripe::StripeObject
# The time that the payment was canceled.
sig { returns(T.nilable(Integer)) }
attr_reader :canceled_at
# The time that the payment succeeded.
sig { returns(T.nilable(Integer)) }
attr_reader :paid_at
end
# Amount that was actually paid for this invoice, in cents (or local equivalent). This field is null until the payment is `paid`. This amount can be less than the `amount_requested` if the PaymentIntent’s `amount_received` is not sufficient to pay all of the invoices that it is attached to.
sig { returns(T.nilable(Integer)) }
attr_reader :amount_paid
# Amount intended to be paid toward this invoice, in cents (or local equivalent)
sig { returns(Integer) }
attr_reader :amount_requested
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# 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).
sig { returns(String) }
attr_reader :currency
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# The invoice that was paid.
sig { returns(T.any(String, Stripe::Invoice)) }
attr_reader :invoice
# Stripe automatically creates a default InvoicePayment when the invoice is finalized, and keeps it synchronized with the invoice’s `amount_remaining`. The PaymentIntent associated with the default payment can’t be edited or canceled directly.
sig { returns(T::Boolean) }
attr_reader :is_default
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Attribute for field payment
sig { returns(Payment) }
attr_reader :payment
# The status of the payment, one of `open`, `paid`, or `canceled`.
sig { returns(String) }
attr_reader :status
# Attribute for field status_transitions
sig { returns(StatusTransitions) }
attr_reader :status_transitions
end
end
# typed: true
module Stripe
# Invoice Rendering Templates are used to configure how invoices are rendered on surfaces like the PDF. Invoice Rendering Templates
# can be created from within the Dashboard, and they can be used over the API when creating invoices.
class InvoiceRenderingTemplate < APIResource
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# 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.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# A brief description of the template, hidden from customers
sig { returns(T.nilable(String)) }
attr_reader :nickname
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The status of the template, one of `active` or `archived`.
sig { returns(String) }
attr_reader :status
# Version of this template; version increases by one when an update on the template changes any field that controls invoice rendering
sig { returns(Integer) }
attr_reader :version
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Attribute for param field status
sig { returns(T.nilable(String)) }
attr_accessor :status
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String), status: T.nilable(String)).void
}
def initialize(
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil,
status: nil
); end
end
class ArchiveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UnarchiveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Updates the status of an invoice rendering template to ‘archived' so no new Stripe objects (customers, invoices, etc.) can reference it. The template can also no longer be updated. However, if the template is already set on a Stripe object, it will continue to be applied on invoices generated by it.
sig {
params(params: T.any(::Stripe::InvoiceRenderingTemplate::ArchiveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::InvoiceRenderingTemplate)
}
def archive(params = {}, opts = {}); end
# Updates the status of an invoice rendering template to ‘archived' so no new Stripe objects (customers, invoices, etc.) can reference it. The template can also no longer be updated. However, if the template is already set on a Stripe object, it will continue to be applied on invoices generated by it.
sig {
params(template: String, params: T.any(::Stripe::InvoiceRenderingTemplate::ArchiveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::InvoiceRenderingTemplate)
}
def self.archive(template, params = {}, opts = {}); end
# List all templates, ordered by creation date, with the most recently created template appearing first.
sig {
params(params: T.any(::Stripe::InvoiceRenderingTemplate::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Unarchive an invoice rendering template so it can be used on new Stripe objects again.
sig {
params(params: T.any(::Stripe::InvoiceRenderingTemplate::UnarchiveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::InvoiceRenderingTemplate)
}
def unarchive(params = {}, opts = {}); end
# Unarchive an invoice rendering template so it can be used on new Stripe objects again.
sig {
params(template: String, params: T.any(::Stripe::InvoiceRenderingTemplate::UnarchiveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::InvoiceRenderingTemplate)
}
def self.unarchive(template, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
# Invoice Items represent the component lines of an [invoice](https://stripe.com/docs/api/invoices). An invoice item is added to an
# invoice by creating or updating it with an `invoice` field, at which point it will be included as
# [an invoice line item](https://stripe.com/docs/api/invoices/line_item) within
# [invoice.lines](https://stripe.com/docs/api/invoices/object#invoice_object-lines).
#
# Invoice Items can be created before you are ready to actually send the invoice. This can be particularly useful when combined
# with a [subscription](https://stripe.com/docs/api/subscriptions). Sometimes you want to add a charge or credit to a customer, but actually charge
# or credit the customer's card only at the end of a regular billing cycle. This is useful for combining several charges
# (to minimize per-transaction fees), or for having Stripe tabulate your usage-based billing totals.
#
# Related guides: [Integrate with the Invoicing API](https://stripe.com/docs/invoicing/integration), [Subscription Invoices](https://stripe.com/docs/billing/invoices/subscription#adding-upcoming-invoice-items).
class InvoiceItem < APIResource
class Parent < Stripe::StripeObject
class SubscriptionDetails < Stripe::StripeObject
# The subscription that generated this invoice item
sig { returns(String) }
attr_reader :subscription
# The subscription item that generated this invoice item
sig { returns(String) }
attr_reader :subscription_item
end
# Details about the subscription that generated this invoice item
sig { returns(T.nilable(SubscriptionDetails)) }
attr_reader :subscription_details
# The type of parent that generated this invoice item
sig { returns(String) }
attr_reader :type
end
class Period < Stripe::StripeObject
# The end of the period, which must be greater than or equal to the start. This value is inclusive.
sig { returns(Integer) }
attr_reader :end
# The start of the period. This value is inclusive.
sig { returns(Integer) }
attr_reader :start
end
class Pricing < Stripe::StripeObject
class PriceDetails < Stripe::StripeObject
# The ID of the price this item is associated with.
sig { returns(String) }
attr_reader :price
# The ID of the product this item is associated with.
sig { returns(String) }
attr_reader :product
end
# Attribute for field price_details
sig { returns(PriceDetails) }
attr_reader :price_details
# The type of the pricing details.
sig { returns(String) }
attr_reader :type
# The unit amount (in the `currency` specified) of the item which contains a decimal value with at most 12 decimal places.
sig { returns(T.nilable(String)) }
attr_reader :unit_amount_decimal
end
# Amount (in the `currency` specified) of the invoice item. This should always be equal to `unit_amount * quantity`.
sig { returns(Integer) }
attr_reader :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).
sig { returns(String) }
attr_reader :currency
# The ID of the customer who will be billed when this invoice item is billed.
sig { returns(T.any(String, Stripe::Customer)) }
attr_reader :customer
# The ID of the account who will be billed when this invoice item is billed.
sig { returns(T.nilable(String)) }
attr_reader :customer_account
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :date
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_reader :description
# If true, discounts will apply to this invoice item. Always false for prorations.
sig { returns(T::Boolean) }
attr_reader :discountable
# The discounts which apply to the invoice item. Item discounts are applied before invoice discounts. Use `expand[]=discounts` to expand each discount.
sig { returns(T.nilable(T::Array[T.any(String, Stripe::Discount)])) }
attr_reader :discounts
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# The ID of the invoice this invoice item belongs to.
sig { returns(T.nilable(T.any(String, Stripe::Invoice))) }
attr_reader :invoice
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# The margins which apply to the invoice item. When set, the `default_margins` on the invoice do not apply to this invoice item.
sig { returns(T.nilable(T::Array[T.any(String, Stripe::Margin)])) }
attr_reader :margins
# 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.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The parent that generated this invoice item.
sig { returns(T.nilable(Parent)) }
attr_reader :parent
# Attribute for field period
sig { returns(Period) }
attr_reader :period
# The pricing information of the invoice item.
sig { returns(T.nilable(Pricing)) }
attr_reader :pricing
# Whether the invoice item was created automatically as a proration adjustment when the customer switched plans.
sig { returns(T::Boolean) }
attr_reader :proration
# Quantity of units for the invoice item. If the invoice item is a proration, the quantity of the subscription that the proration was computed for.
sig { returns(Integer) }
attr_reader :quantity
# The tax rates which apply to the invoice item. When set, the `default_tax_rates` on the invoice do not apply to this invoice item.
sig { returns(T.nilable(T::Array[Stripe::TaxRate])) }
attr_reader :tax_rates
# ID of the test clock this invoice item belongs to.
sig { returns(T.nilable(T.any(String, Stripe::TestHelpers::TestClock))) }
attr_reader :test_clock
# Always true for a deleted object
sig { returns(T::Boolean) }
attr_reader :deleted
class DeleteParams < Stripe::RequestParams; end
class UpdateParams < Stripe::RequestParams
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::InvoiceItem::UpdateParams::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::InvoiceItem::UpdateParams::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig { returns(T.nilable(::Stripe::InvoiceItem::UpdateParams::Discount::DiscountEnd)) }
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::InvoiceItem::UpdateParams::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class Period < Stripe::RequestParams
# The end of the period, which must be greater than or equal to the start. This value is inclusive.
sig { returns(Integer) }
attr_accessor :end
# The start of the period. This value is inclusive.
sig { returns(Integer) }
attr_accessor :start
sig { params(end_: Integer, start: Integer).void }
def initialize(end_: nil, start: nil); end
end
class PriceData < Stripe::RequestParams
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
sig { returns(String) }
attr_accessor :product
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, product: String, tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
class Pricing < Stripe::RequestParams
# The ID of the price object.
sig { returns(T.nilable(String)) }
attr_accessor :price
sig { params(price: T.nilable(String)).void }
def initialize(price: nil); end
end
# The integer amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. If you want to apply a credit to the customer's account, pass a negative amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# An arbitrary string which you can attach to the invoice item. The description is displayed in the invoice for easy tracking.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Controls whether discounts apply to this invoice item. Defaults to false for prorations or negative invoice items, and true for all other invoice items. Cannot be set to true for prorations.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :discountable
# The coupons, promotion codes & existing discounts which apply to the invoice item or invoice line item. Item discounts are applied before invoice discounts. Pass an empty string to remove previously-defined discounts.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceItem::UpdateParams::Discount]))))
}
attr_accessor :discounts
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The ids of the margins to apply to the invoice item. When set, the `default_margins` on the invoice do not apply to this invoice item.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :margins
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :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.
sig { returns(T.nilable(::Stripe::InvoiceItem::UpdateParams::Period)) }
attr_accessor :period
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
sig { returns(T.nilable(::Stripe::InvoiceItem::UpdateParams::PriceData)) }
attr_accessor :price_data
# The pricing information for the invoice item.
sig { returns(T.nilable(::Stripe::InvoiceItem::UpdateParams::Pricing)) }
attr_accessor :pricing
# Non-negative integer. The quantity of units for the invoice item.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :tax_code
# The tax rates which apply to the invoice item. When set, the `default_tax_rates` on the invoice do not apply to this invoice item. Pass an empty string to remove previously-defined tax rates.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
# The decimal unit amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. This `unit_amount_decimal` will be multiplied by the quantity to get the full amount. Passing in a negative `unit_amount_decimal` will reduce the `amount_due` on the invoice. Accepts at most 12 decimal places.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(amount: T.nilable(Integer), description: T.nilable(String), discountable: T.nilable(T::Boolean), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceItem::UpdateParams::Discount]))), expand: T.nilable(T::Array[String]), margins: T.nilable(T.nilable(T.any(String, T::Array[String]))), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), period: T.nilable(::Stripe::InvoiceItem::UpdateParams::Period), price_data: T.nilable(::Stripe::InvoiceItem::UpdateParams::PriceData), pricing: T.nilable(::Stripe::InvoiceItem::UpdateParams::Pricing), quantity: T.nilable(Integer), tax_behavior: T.nilable(String), tax_code: T.nilable(T.nilable(String)), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String]))), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
amount: nil,
description: nil,
discountable: nil,
discounts: nil,
expand: nil,
margins: nil,
metadata: nil,
period: nil,
price_data: nil,
pricing: nil,
quantity: nil,
tax_behavior: nil,
tax_code: nil,
tax_rates: nil,
unit_amount_decimal: nil
); end
end
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return invoice items that were created during the given date interval.
sig { returns(T.nilable(T.any(::Stripe::InvoiceItem::ListParams::Created, Integer))) }
attr_accessor :created
# The identifier of the customer whose invoice items to return. If none is provided, all invoice items will be returned.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# The identifier of the account whose invoice items to return. If none is provided, all invoice items will be returned.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Only return invoice items belonging to this invoice. If none is provided, all invoice items will be returned. If specifying an invoice, no customer identifier is needed.
sig { returns(T.nilable(String)) }
attr_accessor :invoice
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Set to `true` to only show pending invoice items, which are not yet attached to any invoices. Set to `false` to only show invoice items already attached to invoices. If unspecified, no filter is applied.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :pending
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(created: T.nilable(T.any(::Stripe::InvoiceItem::ListParams::Created, Integer)), customer: T.nilable(String), customer_account: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), invoice: T.nilable(String), limit: T.nilable(Integer), pending: T.nilable(T::Boolean), starting_after: T.nilable(String)).void
}
def initialize(
created: nil,
customer: nil,
customer_account: nil,
ending_before: nil,
expand: nil,
invoice: nil,
limit: nil,
pending: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::InvoiceItem::CreateParams::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::InvoiceItem::CreateParams::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig { returns(T.nilable(::Stripe::InvoiceItem::CreateParams::Discount::DiscountEnd)) }
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::InvoiceItem::CreateParams::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class Period < Stripe::RequestParams
# The end of the period, which must be greater than or equal to the start. This value is inclusive.
sig { returns(Integer) }
attr_accessor :end
# The start of the period. This value is inclusive.
sig { returns(Integer) }
attr_accessor :start
sig { params(end_: Integer, start: Integer).void }
def initialize(end_: nil, start: nil); end
end
class PriceData < Stripe::RequestParams
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
sig { returns(String) }
attr_accessor :product
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, product: String, tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
class Pricing < Stripe::RequestParams
# The ID of the price object.
sig { returns(T.nilable(String)) }
attr_accessor :price
sig { params(price: T.nilable(String)).void }
def initialize(price: nil); end
end
# The integer amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. Passing in a negative `amount` will reduce the `amount_due` on the invoice.
sig { returns(T.nilable(Integer)) }
attr_accessor :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).
sig { returns(T.nilable(String)) }
attr_accessor :currency
# The ID of the customer who will be billed when this invoice item is billed.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# The ID of the account who will be billed when this invoice item is billed.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# An arbitrary string which you can attach to the invoice item. The description is displayed in the invoice for easy tracking.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Controls whether discounts apply to this invoice item. Defaults to false for prorations or negative invoice items, and true for all other invoice items.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :discountable
# The coupons and promotion codes to redeem into discounts for the invoice item or invoice line item.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceItem::CreateParams::Discount]))))
}
attr_accessor :discounts
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The ID of an existing invoice to add this invoice item to. When left blank, the invoice item will be added to the next upcoming scheduled invoice. This is useful when adding invoice items in response to an invoice.created webhook. You can only add invoice items to draft invoices and there is a maximum of 250 items per invoice.
sig { returns(T.nilable(String)) }
attr_accessor :invoice
# The ids of the margins to apply to the invoice item. When set, the `default_margins` on the invoice do not apply to this invoice item.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :margins
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :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.
sig { returns(T.nilable(::Stripe::InvoiceItem::CreateParams::Period)) }
attr_accessor :period
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
sig { returns(T.nilable(::Stripe::InvoiceItem::CreateParams::PriceData)) }
attr_accessor :price_data
# The pricing information for the invoice item.
sig { returns(T.nilable(::Stripe::InvoiceItem::CreateParams::Pricing)) }
attr_accessor :pricing
# Non-negative integer. The quantity of units for the invoice item.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# The ID of a subscription to add this invoice item to. When left blank, the invoice item is added to the next upcoming scheduled invoice. When set, scheduled invoices for subscriptions other than the specified subscription will ignore the invoice item. Use this when you want to express that an invoice item has been accrued within the context of a particular subscription.
sig { returns(T.nilable(String)) }
attr_accessor :subscription
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :tax_code
# The tax rates which apply to the invoice item. When set, the `default_tax_rates` on the invoice do not apply to this invoice item.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :tax_rates
# The decimal unit amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. This `unit_amount_decimal` will be multiplied by the quantity to get the full amount. Passing in a negative `unit_amount_decimal` will reduce the `amount_due` on the invoice. Accepts at most 12 decimal places.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(amount: T.nilable(Integer), currency: T.nilable(String), customer: T.nilable(String), customer_account: T.nilable(String), description: T.nilable(String), discountable: T.nilable(T::Boolean), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceItem::CreateParams::Discount]))), expand: T.nilable(T::Array[String]), invoice: T.nilable(String), margins: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), period: T.nilable(::Stripe::InvoiceItem::CreateParams::Period), price_data: T.nilable(::Stripe::InvoiceItem::CreateParams::PriceData), pricing: T.nilable(::Stripe::InvoiceItem::CreateParams::Pricing), quantity: T.nilable(Integer), subscription: T.nilable(String), tax_behavior: T.nilable(String), tax_code: T.nilable(T.nilable(String)), tax_rates: T.nilable(T::Array[String]), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
amount: nil,
currency: nil,
customer: nil,
customer_account: nil,
description: nil,
discountable: nil,
discounts: nil,
expand: nil,
invoice: nil,
margins: nil,
metadata: nil,
period: nil,
price_data: nil,
pricing: nil,
quantity: nil,
subscription: nil,
tax_behavior: nil,
tax_code: nil,
tax_rates: nil,
unit_amount_decimal: nil
); end
end
# Creates an item to be added to a draft invoice (up to 250 items per invoice). If no invoice is specified, the item will be on the next invoice created for the customer specified.
sig {
params(params: T.any(::Stripe::InvoiceItem::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::InvoiceItem)
}
def self.create(params = {}, opts = {}); end
# Deletes an invoice item, removing it from an invoice. Deleting invoice items is only possible when they're not attached to invoices, or if it's attached to a draft invoice.
sig {
params(invoiceitem: String, params: T.any(::Stripe::InvoiceItem::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::InvoiceItem)
}
def self.delete(invoiceitem, params = {}, opts = {}); end
# Deletes an invoice item, removing it from an invoice. Deleting invoice items is only possible when they're not attached to invoices, or if it's attached to a draft invoice.
sig {
params(params: T.any(::Stripe::InvoiceItem::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::InvoiceItem)
}
def delete(params = {}, opts = {}); end
# Returns a list of your invoice items. Invoice items are returned sorted by creation date, with the most recently created invoice items appearing first.
sig {
params(params: T.any(::Stripe::InvoiceItem::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Updates the amount or description of an invoice item on an upcoming invoice. Updating an invoice item is only possible before the invoice it's attached to is closed.
sig {
params(invoiceitem: String, params: T.any(::Stripe::InvoiceItem::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::InvoiceItem)
}
def self.update(invoiceitem, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
module Issuing
# When an [issued card](https://stripe.com/docs/issuing) is used to make a purchase, an Issuing `Authorization`
# object is created. [Authorizations](https://stripe.com/docs/issuing/purchases/authorizations) must be approved for the
# purchase to be completed successfully.
#
# Related guide: [Issued card authorizations](https://stripe.com/docs/issuing/purchases/authorizations)
class Authorization < APIResource
class AmountDetails < Stripe::StripeObject
# The fee charged by the ATM for the cash withdrawal.
sig { returns(T.nilable(Integer)) }
attr_reader :atm_fee
# The amount of cash requested by the cardholder.
sig { returns(T.nilable(Integer)) }
attr_reader :cashback_amount
end
class Fleet < Stripe::StripeObject
class CardholderPromptData < Stripe::StripeObject
# [Deprecated] An alphanumeric ID, though typical point of sales only support numeric entry. The card program can be configured to prompt for a vehicle ID, driver ID, or generic ID.
sig { returns(T.nilable(String)) }
attr_reader :alphanumeric_id
# Driver ID.
sig { returns(T.nilable(String)) }
attr_reader :driver_id
# Odometer reading.
sig { returns(T.nilable(Integer)) }
attr_reader :odometer
# An alphanumeric ID. This field is used when a vehicle ID, driver ID, or generic ID is entered by the cardholder, but the merchant or card network did not specify the prompt type.
sig { returns(T.nilable(String)) }
attr_reader :unspecified_id
# User ID.
sig { returns(T.nilable(String)) }
attr_reader :user_id
# Vehicle number.
sig { returns(T.nilable(String)) }
attr_reader :vehicle_number
end
class ReportedBreakdown < Stripe::StripeObject
class Fuel < Stripe::StripeObject
# Gross fuel amount that should equal Fuel Quantity multiplied by Fuel Unit Cost, inclusive of taxes.
sig { returns(T.nilable(String)) }
attr_reader :gross_amount_decimal
end
class NonFuel < Stripe::StripeObject
# Gross non-fuel amount that should equal the sum of the line items, inclusive of taxes.
sig { returns(T.nilable(String)) }
attr_reader :gross_amount_decimal
end
class Tax < Stripe::StripeObject
# Amount of state or provincial Sales Tax included in the transaction amount. `null` if not reported by merchant or not subject to tax.
sig { returns(T.nilable(String)) }
attr_reader :local_amount_decimal
# Amount of national Sales Tax or VAT included in the transaction amount. `null` if not reported by merchant or not subject to tax.
sig { returns(T.nilable(String)) }
attr_reader :national_amount_decimal
end
# Breakdown of fuel portion of the purchase.
sig { returns(T.nilable(Fuel)) }
attr_reader :fuel
# Breakdown of non-fuel portion of the purchase.
sig { returns(T.nilable(NonFuel)) }
attr_reader :non_fuel
# Information about tax included in this transaction.
sig { returns(T.nilable(Tax)) }
attr_reader :tax
end
# Answers to prompts presented to the cardholder at the point of sale. Prompted fields vary depending on the configuration of your physical fleet cards. Typical points of sale support only numeric entry.
sig { returns(T.nilable(CardholderPromptData)) }
attr_reader :cardholder_prompt_data
# The type of purchase.
sig { returns(T.nilable(String)) }
attr_reader :purchase_type
# More information about the total amount. Typically this information is received from the merchant after the authorization has been approved and the fuel dispensed. This information is not guaranteed to be accurate as some merchants may provide unreliable data.
sig { returns(T.nilable(ReportedBreakdown)) }
attr_reader :reported_breakdown
# The type of fuel service.
sig { returns(T.nilable(String)) }
attr_reader :service_type
end
class FraudChallenge < Stripe::StripeObject
# The method by which the fraud challenge was delivered to the cardholder.
sig { returns(String) }
attr_reader :channel
# The status of the fraud challenge.
sig { returns(String) }
attr_reader :status
# If the challenge is not deliverable, the reason why.
sig { returns(T.nilable(String)) }
attr_reader :undeliverable_reason
end
class Fuel < Stripe::StripeObject
# [Conexxus Payment System Product Code](https://www.conexxus.org/conexxus-payment-system-product-codes) identifying the primary fuel product purchased.
sig { returns(T.nilable(String)) }
attr_reader :industry_product_code
# The quantity of `unit`s of fuel that was dispensed, represented as a decimal string with at most 12 decimal places.
sig { returns(T.nilable(String)) }
attr_reader :quantity_decimal
# The type of fuel that was purchased.
sig { returns(T.nilable(String)) }
attr_reader :type
# The units for `quantity_decimal`.
sig { returns(T.nilable(String)) }
attr_reader :unit
# The cost in cents per each unit of fuel, represented as a decimal string with at most 12 decimal places.
sig { returns(T.nilable(String)) }
attr_reader :unit_cost_decimal
end
class MerchantData < Stripe::StripeObject
# A categorization of the seller's type of business. See our [merchant categories guide](https://stripe.com/docs/issuing/merchant-categories) for a list of possible values.
sig { returns(String) }
attr_reader :category
# The merchant category code for the seller’s business
sig { returns(String) }
attr_reader :category_code
# City where the seller is located
sig { returns(T.nilable(String)) }
attr_reader :city
# Country where the seller is located
sig { returns(T.nilable(String)) }
attr_reader :country
# Name of the seller
sig { returns(T.nilable(String)) }
attr_reader :name
# Identifier assigned to the seller by the card network. Different card networks may assign different network_id fields to the same merchant.
sig { returns(String) }
attr_reader :network_id
# Postal code where the seller is located
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State where the seller is located
sig { returns(T.nilable(String)) }
attr_reader :state
# The seller's tax identification number. Currently populated for French merchants only.
sig { returns(T.nilable(String)) }
attr_reader :tax_id
# An ID assigned by the seller to the location of the sale.
sig { returns(T.nilable(String)) }
attr_reader :terminal_id
# URL provided by the merchant on a 3DS request
sig { returns(T.nilable(String)) }
attr_reader :url
end
class NetworkData < Stripe::StripeObject
# Identifier assigned to the acquirer by the card network. Sometimes this value is not provided by the network; in this case, the value will be `null`.
sig { returns(T.nilable(String)) }
attr_reader :acquiring_institution_id
# The System Trace Audit Number (STAN) is a 6-digit identifier assigned by the acquirer. Prefer `network_data.transaction_id` if present, unless you have special requirements.
sig { returns(T.nilable(String)) }
attr_reader :system_trace_audit_number
# Unique identifier for the authorization assigned by the card network used to match subsequent messages, disputes, and transactions.
sig { returns(T.nilable(String)) }
attr_reader :transaction_id
end
class PendingRequest < Stripe::StripeObject
class AmountDetails < Stripe::StripeObject
# The fee charged by the ATM for the cash withdrawal.
sig { returns(T.nilable(Integer)) }
attr_reader :atm_fee
# The amount of cash requested by the cardholder.
sig { returns(T.nilable(Integer)) }
attr_reader :cashback_amount
end
# The additional amount Stripe will hold if the authorization is approved, in the card's [currency](https://stripe.com/docs/api#issuing_authorization_object-pending-request-currency) and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(Integer) }
attr_reader :amount
# Detailed breakdown of amount components. These amounts are denominated in `currency` and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(T.nilable(AmountDetails)) }
attr_reader :amount_details
# 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).
sig { returns(String) }
attr_reader :currency
# If set `true`, you may provide [amount](https://stripe.com/docs/api/issuing/authorizations/approve#approve_issuing_authorization-amount) to control how much to hold for the authorization.
sig { returns(T::Boolean) }
attr_reader :is_amount_controllable
# The amount the merchant is requesting to be authorized in the `merchant_currency`. The amount is in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(Integer) }
attr_reader :merchant_amount
# The local currency the merchant is requesting to authorize.
sig { returns(String) }
attr_reader :merchant_currency
# The card network's estimate of the likelihood that an authorization is fraudulent. Takes on values between 1 and 99.
sig { returns(T.nilable(Integer)) }
attr_reader :network_risk_score
end
class RequestHistory < Stripe::StripeObject
class AmountDetails < Stripe::StripeObject
# The fee charged by the ATM for the cash withdrawal.
sig { returns(T.nilable(Integer)) }
attr_reader :atm_fee
# The amount of cash requested by the cardholder.
sig { returns(T.nilable(Integer)) }
attr_reader :cashback_amount
end
# The `pending_request.amount` at the time of the request, presented in your card's currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal). Stripe held this amount from your account to fund the authorization if the request was approved.
sig { returns(Integer) }
attr_reader :amount
# Detailed breakdown of amount components. These amounts are denominated in `currency` and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(T.nilable(AmountDetails)) }
attr_reader :amount_details
# Whether this request was approved.
sig { returns(T::Boolean) }
attr_reader :approved
# A code created by Stripe which is shared with the merchant to validate the authorization. This field will be populated if the authorization message was approved. The code typically starts with the letter "S", followed by a six-digit number. For example, "S498162". Please note that the code is not guaranteed to be unique across authorizations.
sig { returns(T.nilable(String)) }
attr_reader :authorization_code
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# 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).
sig { returns(String) }
attr_reader :currency
# The `pending_request.merchant_amount` at the time of the request, presented in the `merchant_currency` and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(Integer) }
attr_reader :merchant_amount
# The currency that was collected by the merchant and presented to the cardholder for the authorization. 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).
sig { returns(String) }
attr_reader :merchant_currency
# The card network's estimate of the likelihood that an authorization is fraudulent. Takes on values between 1 and 99.
sig { returns(T.nilable(Integer)) }
attr_reader :network_risk_score
# When an authorization is approved or declined by you or by Stripe, this field provides additional detail on the reason for the outcome.
sig { returns(String) }
attr_reader :reason
# If the `request_history.reason` is `webhook_error` because the direct webhook response is invalid (for example, parsing errors or missing parameters), we surface a more detailed error message via this field.
sig { returns(T.nilable(String)) }
attr_reader :reason_message
# Time when the card network received an authorization request from the acquirer in UTC. Referred to by networks as transmission time.
sig { returns(T.nilable(Integer)) }
attr_reader :requested_at
end
class Treasury < Stripe::StripeObject
# The array of [ReceivedCredits](https://stripe.com/docs/api/treasury/received_credits) associated with this authorization
sig { returns(T::Array[String]) }
attr_reader :received_credits
# The array of [ReceivedDebits](https://stripe.com/docs/api/treasury/received_debits) associated with this authorization
sig { returns(T::Array[String]) }
attr_reader :received_debits
# The Treasury [Transaction](https://stripe.com/docs/api/treasury/transactions) associated with this authorization
sig { returns(T.nilable(String)) }
attr_reader :transaction
end
class VerificationData < Stripe::StripeObject
class AuthenticationExemption < Stripe::StripeObject
# The entity that requested the exemption, either the acquiring merchant or the Issuing user.
sig { returns(String) }
attr_reader :claimed_by
# The specific exemption claimed for this authorization.
sig { returns(String) }
attr_reader :type
end
class ThreeDSecure < Stripe::StripeObject
# The outcome of the 3D Secure authentication request.
sig { returns(String) }
attr_reader :result
end
# Whether the cardholder provided an address first line and if it matched the cardholder’s `billing.address.line1`.
sig { returns(String) }
attr_reader :address_line1_check
# Whether the cardholder provided a postal code and if it matched the cardholder’s `billing.address.postal_code`.
sig { returns(String) }
attr_reader :address_postal_code_check
# The exemption applied to this authorization.
sig { returns(T.nilable(AuthenticationExemption)) }
attr_reader :authentication_exemption
# Whether the cardholder provided a CVC and if it matched Stripe’s record.
sig { returns(String) }
attr_reader :cvc_check
# Whether the cardholder provided an expiry date and if it matched Stripe’s record.
sig { returns(String) }
attr_reader :expiry_check
# The postal code submitted as part of the authorization used for postal code verification.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# 3D Secure details.
sig { returns(T.nilable(ThreeDSecure)) }
attr_reader :three_d_secure
end
# The total amount that was authorized or rejected. This amount is in `currency` and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal). `amount` should be the same as `merchant_amount`, unless `currency` and `merchant_currency` are different.
sig { returns(Integer) }
attr_reader :amount
# Detailed breakdown of amount components. These amounts are denominated in `currency` and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(T.nilable(AmountDetails)) }
attr_reader :amount_details
# Whether the authorization has been approved.
sig { returns(T::Boolean) }
attr_reader :approved
# How the card details were provided.
sig { returns(String) }
attr_reader :authorization_method
# List of balance transactions associated with this authorization.
sig { returns(T::Array[Stripe::BalanceTransaction]) }
attr_reader :balance_transactions
# You can [create physical or virtual cards](https://stripe.com/docs/issuing) that are issued to cardholders.
sig { returns(Stripe::Issuing::Card) }
attr_reader :card
# The cardholder to whom this authorization belongs.
sig { returns(T.nilable(T.any(String, Stripe::Issuing::Cardholder))) }
attr_reader :cardholder
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# The currency of the cardholder. This currency can be different from the currency presented at authorization and the `merchant_currency` field on this authorization. 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).
sig { returns(String) }
attr_reader :currency
# Fleet-specific information for authorizations using Fleet cards.
sig { returns(T.nilable(Fleet)) }
attr_reader :fleet
# Fraud challenges sent to the cardholder, if this authorization was declined for fraud risk reasons.
sig { returns(T.nilable(T::Array[FraudChallenge])) }
attr_reader :fraud_challenges
# Information about fuel that was purchased with this transaction. Typically this information is received from the merchant after the authorization has been approved and the fuel dispensed.
sig { returns(T.nilable(Fuel)) }
attr_reader :fuel
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# The total amount that was authorized or rejected. This amount is in the `merchant_currency` and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal). `merchant_amount` should be the same as `amount`, unless `merchant_currency` and `currency` are different.
sig { returns(Integer) }
attr_reader :merchant_amount
# The local currency that was presented to the cardholder for the authorization. This currency can be different from the cardholder currency and the `currency` field on this authorization. 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).
sig { returns(String) }
attr_reader :merchant_currency
# Attribute for field merchant_data
sig { returns(MerchantData) }
attr_reader :merchant_data
# 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.
sig { returns(T::Hash[String, String]) }
attr_reader :metadata
# Details about the authorization, such as identifiers, set by the card network.
sig { returns(T.nilable(NetworkData)) }
attr_reader :network_data
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The pending authorization request. This field will only be non-null during an `issuing_authorization.request` webhook.
sig { returns(T.nilable(PendingRequest)) }
attr_reader :pending_request
# History of every time a `pending_request` authorization was approved/declined, either by you directly or by Stripe (e.g. based on your spending_controls). If the merchant changes the authorization by performing an incremental authorization, you can look at this field to see the previous requests for the authorization. This field can be helpful in determining why a given authorization was approved/declined.
sig { returns(T::Array[RequestHistory]) }
attr_reader :request_history
# The current status of the authorization in its lifecycle.
sig { returns(String) }
attr_reader :status
# [Token](https://stripe.com/docs/api/issuing/tokens/object) object used for this authorization. If a network token was not used for this authorization, this field will be null.
sig { returns(T.nilable(T.any(String, Stripe::Issuing::Token))) }
attr_reader :token
# List of [transactions](https://stripe.com/docs/api/issuing/transactions) associated with this authorization.
sig { returns(T::Array[Stripe::Issuing::Transaction]) }
attr_reader :transactions
# [Treasury](https://stripe.com/docs/api/treasury) details related to this authorization if it was created on a [FinancialAccount](https://stripe.com/docs/api/treasury/financial_accounts).
sig { returns(T.nilable(Treasury)) }
attr_reader :treasury
# Attribute for field verification_data
sig { returns(VerificationData) }
attr_reader :verification_data
# Whether the authorization bypassed fraud risk checks because the cardholder has previously completed a fraud challenge on a similar high-risk authorization from the same merchant.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :verified_by_fraud_challenge
# The digital wallet used for this transaction. One of `apple_pay`, `google_pay`, or `samsung_pay`. Will populate as `null` when no digital wallet was utilized.
sig { returns(T.nilable(String)) }
attr_reader :wallet
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return authorizations that belong to the given card.
sig { returns(T.nilable(String)) }
attr_accessor :card
# Only return authorizations that belong to the given cardholder.
sig { returns(T.nilable(String)) }
attr_accessor :cardholder
# Only return authorizations that were created during the given date interval.
sig {
returns(T.nilable(T.any(::Stripe::Issuing::Authorization::ListParams::Created, Integer)))
}
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return authorizations with the given status. One of `pending`, `closed`, or `reversed`.
sig { returns(T.nilable(String)) }
attr_accessor :status
sig {
params(card: T.nilable(String), cardholder: T.nilable(String), created: T.nilable(T.any(::Stripe::Issuing::Authorization::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String), status: T.nilable(String)).void
}
def initialize(
card: nil,
cardholder: nil,
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil,
status: nil
); end
end
class UpdateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
sig {
params(expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String])))).void
}
def initialize(expand: nil, metadata: nil); end
end
class ApproveParams < Stripe::RequestParams
# If the authorization's `pending_request.is_amount_controllable` property is `true`, you may provide this value to control how much to hold for the authorization. Must be positive (use [`decline`](https://stripe.com/docs/api/issuing/authorizations/decline) to decline an authorization request).
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
sig {
params(amount: T.nilable(Integer), expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String])))).void
}
def initialize(amount: nil, expand: nil, metadata: nil); end
end
class DeclineParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
sig {
params(expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String])))).void
}
def initialize(expand: nil, metadata: nil); end
end
class CreateParams < Stripe::RequestParams
class AmountDetails < Stripe::RequestParams
# The ATM withdrawal fee.
sig { returns(T.nilable(Integer)) }
attr_accessor :atm_fee
# The amount of cash requested by the cardholder.
sig { returns(T.nilable(Integer)) }
attr_accessor :cashback_amount
sig { params(atm_fee: T.nilable(Integer), cashback_amount: T.nilable(Integer)).void }
def initialize(atm_fee: nil, cashback_amount: nil); end
end
class Fleet < Stripe::RequestParams
class CardholderPromptData < Stripe::RequestParams
# Driver ID.
sig { returns(T.nilable(String)) }
attr_accessor :driver_id
# Odometer reading.
sig { returns(T.nilable(Integer)) }
attr_accessor :odometer
# An alphanumeric ID. This field is used when a vehicle ID, driver ID, or generic ID is entered by the cardholder, but the merchant or card network did not specify the prompt type.
sig { returns(T.nilable(String)) }
attr_accessor :unspecified_id
# User ID.
sig { returns(T.nilable(String)) }
attr_accessor :user_id
# Vehicle number.
sig { returns(T.nilable(String)) }
attr_accessor :vehicle_number
sig {
params(driver_id: T.nilable(String), odometer: T.nilable(Integer), unspecified_id: T.nilable(String), user_id: T.nilable(String), vehicle_number: T.nilable(String)).void
}
def initialize(
driver_id: nil,
odometer: nil,
unspecified_id: nil,
user_id: nil,
vehicle_number: nil
); end
end
class ReportedBreakdown < Stripe::RequestParams
class Fuel < Stripe::RequestParams
# Gross fuel amount that should equal Fuel Volume multipled by Fuel Unit Cost, inclusive of taxes.
sig { returns(T.nilable(String)) }
attr_accessor :gross_amount_decimal
sig { params(gross_amount_decimal: T.nilable(String)).void }
def initialize(gross_amount_decimal: nil); end
end
class NonFuel < Stripe::RequestParams
# Gross non-fuel amount that should equal the sum of the line items, inclusive of taxes.
sig { returns(T.nilable(String)) }
attr_accessor :gross_amount_decimal
sig { params(gross_amount_decimal: T.nilable(String)).void }
def initialize(gross_amount_decimal: nil); end
end
class Tax < Stripe::RequestParams
# Amount of state or provincial Sales Tax included in the transaction amount. Null if not reported by merchant or not subject to tax.
sig { returns(T.nilable(String)) }
attr_accessor :local_amount_decimal
# Amount of national Sales Tax or VAT included in the transaction amount. Null if not reported by merchant or not subject to tax.
sig { returns(T.nilable(String)) }
attr_accessor :national_amount_decimal
sig {
params(local_amount_decimal: T.nilable(String), national_amount_decimal: T.nilable(String)).void
}
def initialize(local_amount_decimal: nil, national_amount_decimal: nil); end
end
# Breakdown of fuel portion of the purchase.
sig {
returns(T.nilable(::Stripe::Issuing::Authorization::CreateParams::Fleet::ReportedBreakdown::Fuel))
}
attr_accessor :fuel
# Breakdown of non-fuel portion of the purchase.
sig {
returns(T.nilable(::Stripe::Issuing::Authorization::CreateParams::Fleet::ReportedBreakdown::NonFuel))
}
attr_accessor :non_fuel
# Information about tax included in this transaction.
sig {
returns(T.nilable(::Stripe::Issuing::Authorization::CreateParams::Fleet::ReportedBreakdown::Tax))
}
attr_accessor :tax
sig {
params(fuel: T.nilable(::Stripe::Issuing::Authorization::CreateParams::Fleet::ReportedBreakdown::Fuel), non_fuel: T.nilable(::Stripe::Issuing::Authorization::CreateParams::Fleet::ReportedBreakdown::NonFuel), tax: T.nilable(::Stripe::Issuing::Authorization::CreateParams::Fleet::ReportedBreakdown::Tax)).void
}
def initialize(fuel: nil, non_fuel: nil, tax: nil); end
end
# Answers to prompts presented to the cardholder at the point of sale. Prompted fields vary depending on the configuration of your physical fleet cards. Typical points of sale support only numeric entry.
sig {
returns(T.nilable(::Stripe::Issuing::Authorization::CreateParams::Fleet::CardholderPromptData))
}
attr_accessor :cardholder_prompt_data
# The type of purchase. One of `fuel_purchase`, `non_fuel_purchase`, or `fuel_and_non_fuel_purchase`.
sig { returns(T.nilable(String)) }
attr_accessor :purchase_type
# More information about the total amount. This information is not guaranteed to be accurate as some merchants may provide unreliable data.
sig {
returns(T.nilable(::Stripe::Issuing::Authorization::CreateParams::Fleet::ReportedBreakdown))
}
attr_accessor :reported_breakdown
# The type of fuel service. One of `non_fuel_transaction`, `full_service`, or `self_service`.
sig { returns(T.nilable(String)) }
attr_accessor :service_type
sig {
params(cardholder_prompt_data: T.nilable(::Stripe::Issuing::Authorization::CreateParams::Fleet::CardholderPromptData), purchase_type: T.nilable(String), reported_breakdown: T.nilable(::Stripe::Issuing::Authorization::CreateParams::Fleet::ReportedBreakdown), service_type: T.nilable(String)).void
}
def initialize(
cardholder_prompt_data: nil,
purchase_type: nil,
reported_breakdown: nil,
service_type: nil
); end
end
class Fuel < Stripe::RequestParams
# [Conexxus Payment System Product Code](https://www.conexxus.org/conexxus-payment-system-product-codes) identifying the primary fuel product purchased.
sig { returns(T.nilable(String)) }
attr_accessor :industry_product_code
# The quantity of `unit`s of fuel that was dispensed, represented as a decimal string with at most 12 decimal places.
sig { returns(T.nilable(String)) }
attr_accessor :quantity_decimal
# The type of fuel that was purchased. One of `diesel`, `unleaded_plus`, `unleaded_regular`, `unleaded_super`, or `other`.
sig { returns(T.nilable(String)) }
attr_accessor :type
# The units for `quantity_decimal`. One of `charging_minute`, `imperial_gallon`, `kilogram`, `kilowatt_hour`, `liter`, `pound`, `us_gallon`, or `other`.
sig { returns(T.nilable(String)) }
attr_accessor :unit
# The cost in cents per each unit of fuel, represented as a decimal string with at most 12 decimal places.
sig { returns(T.nilable(String)) }
attr_accessor :unit_cost_decimal
sig {
params(industry_product_code: T.nilable(String), quantity_decimal: T.nilable(String), type: T.nilable(String), unit: T.nilable(String), unit_cost_decimal: T.nilable(String)).void
}
def initialize(
industry_product_code: nil,
quantity_decimal: nil,
type: nil,
unit: nil,
unit_cost_decimal: nil
); end
end
class MerchantData < Stripe::RequestParams
# A categorization of the seller's type of business. See our [merchant categories guide](https://stripe.com/docs/issuing/merchant-categories) for a list of possible values.
sig { returns(T.nilable(String)) }
attr_accessor :category
# City where the seller is located
sig { returns(T.nilable(String)) }
attr_accessor :city
# Country where the seller is located
sig { returns(T.nilable(String)) }
attr_accessor :country
# Name of the seller
sig { returns(T.nilable(String)) }
attr_accessor :name
# Identifier assigned to the seller by the card network. Different card networks may assign different network_id fields to the same merchant.
sig { returns(T.nilable(String)) }
attr_accessor :network_id
# Postal code where the seller is located
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State where the seller is located
sig { returns(T.nilable(String)) }
attr_accessor :state
# An ID assigned by the seller to the location of the sale.
sig { returns(T.nilable(String)) }
attr_accessor :terminal_id
# URL provided by the merchant on a 3DS request
sig { returns(T.nilable(String)) }
attr_accessor :url
sig {
params(category: T.nilable(String), city: T.nilable(String), country: T.nilable(String), name: T.nilable(String), network_id: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), terminal_id: T.nilable(String), url: T.nilable(String)).void
}
def initialize(
category: nil,
city: nil,
country: nil,
name: nil,
network_id: nil,
postal_code: nil,
state: nil,
terminal_id: nil,
url: nil
); end
end
class NetworkData < Stripe::RequestParams
# Identifier assigned to the acquirer by the card network.
sig { returns(T.nilable(String)) }
attr_accessor :acquiring_institution_id
sig { params(acquiring_institution_id: T.nilable(String)).void }
def initialize(acquiring_institution_id: nil); end
end
class VerificationData < Stripe::RequestParams
class AuthenticationExemption < Stripe::RequestParams
# The entity that requested the exemption, either the acquiring merchant or the Issuing user.
sig { returns(String) }
attr_accessor :claimed_by
# The specific exemption claimed for this authorization.
sig { returns(String) }
attr_accessor :type
sig { params(claimed_by: String, type: String).void }
def initialize(claimed_by: nil, type: nil); end
end
class ThreeDSecure < Stripe::RequestParams
# The outcome of the 3D Secure authentication request.
sig { returns(String) }
attr_accessor :result
sig { params(result: String).void }
def initialize(result: nil); end
end
# Whether the cardholder provided an address first line and if it matched the cardholder’s `billing.address.line1`.
sig { returns(T.nilable(String)) }
attr_accessor :address_line1_check
# Whether the cardholder provided a postal code and if it matched the cardholder’s `billing.address.postal_code`.
sig { returns(T.nilable(String)) }
attr_accessor :address_postal_code_check
# The exemption applied to this authorization.
sig {
returns(T.nilable(::Stripe::Issuing::Authorization::CreateParams::VerificationData::AuthenticationExemption))
}
attr_accessor :authentication_exemption
# Whether the cardholder provided a CVC and if it matched Stripe’s record.
sig { returns(T.nilable(String)) }
attr_accessor :cvc_check
# Whether the cardholder provided an expiry date and if it matched Stripe’s record.
sig { returns(T.nilable(String)) }
attr_accessor :expiry_check
# 3D Secure details.
sig {
returns(T.nilable(::Stripe::Issuing::Authorization::CreateParams::VerificationData::ThreeDSecure))
}
attr_accessor :three_d_secure
sig {
params(address_line1_check: T.nilable(String), address_postal_code_check: T.nilable(String), authentication_exemption: T.nilable(::Stripe::Issuing::Authorization::CreateParams::VerificationData::AuthenticationExemption), cvc_check: T.nilable(String), expiry_check: T.nilable(String), three_d_secure: T.nilable(::Stripe::Issuing::Authorization::CreateParams::VerificationData::ThreeDSecure)).void
}
def initialize(
address_line1_check: nil,
address_postal_code_check: nil,
authentication_exemption: nil,
cvc_check: nil,
expiry_check: nil,
three_d_secure: nil
); end
end
# The total amount to attempt to authorize. This amount is in the provided currency, or defaults to the card's currency, and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# Detailed breakdown of amount components. These amounts are denominated in `currency` and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(T.nilable(::Stripe::Issuing::Authorization::CreateParams::AmountDetails)) }
attr_accessor :amount_details
# How the card details were provided. Defaults to online.
sig { returns(T.nilable(String)) }
attr_accessor :authorization_method
# Card associated with this authorization.
sig { returns(String) }
attr_accessor :card
# The currency of the authorization. If not provided, defaults to the currency of the card. 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).
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Fleet-specific information for authorizations using Fleet cards.
sig { returns(T.nilable(::Stripe::Issuing::Authorization::CreateParams::Fleet)) }
attr_accessor :fleet
# Information about fuel that was purchased with this transaction.
sig { returns(T.nilable(::Stripe::Issuing::Authorization::CreateParams::Fuel)) }
attr_accessor :fuel
# If set `true`, you may provide [amount](https://stripe.com/docs/api/issuing/authorizations/approve#approve_issuing_authorization-amount) to control how much to hold for the authorization.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :is_amount_controllable
# The total amount to attempt to authorize. This amount is in the provided merchant currency, and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(T.nilable(Integer)) }
attr_accessor :merchant_amount
# The currency of the authorization. If not provided, defaults to the currency of the card. 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).
sig { returns(T.nilable(String)) }
attr_accessor :merchant_currency
# Details about the seller (grocery store, e-commerce website, etc.) where the card authorization happened.
sig { returns(T.nilable(::Stripe::Issuing::Authorization::CreateParams::MerchantData)) }
attr_accessor :merchant_data
# Details about the authorization, such as identifiers, set by the card network.
sig { returns(T.nilable(::Stripe::Issuing::Authorization::CreateParams::NetworkData)) }
attr_accessor :network_data
# Verifications that Stripe performed on information that the cardholder provided to the merchant.
sig { returns(T.nilable(::Stripe::Issuing::Authorization::CreateParams::VerificationData)) }
attr_accessor :verification_data
# The digital wallet used for this transaction. One of `apple_pay`, `google_pay`, or `samsung_pay`. Will populate as `null` when no digital wallet was utilized.
sig { returns(T.nilable(String)) }
attr_accessor :wallet
sig {
params(amount: T.nilable(Integer), amount_details: T.nilable(::Stripe::Issuing::Authorization::CreateParams::AmountDetails), authorization_method: T.nilable(String), card: String, currency: T.nilable(String), expand: T.nilable(T::Array[String]), fleet: T.nilable(::Stripe::Issuing::Authorization::CreateParams::Fleet), fuel: T.nilable(::Stripe::Issuing::Authorization::CreateParams::Fuel), is_amount_controllable: T.nilable(T::Boolean), merchant_amount: T.nilable(Integer), merchant_currency: T.nilable(String), merchant_data: T.nilable(::Stripe::Issuing::Authorization::CreateParams::MerchantData), network_data: T.nilable(::Stripe::Issuing::Authorization::CreateParams::NetworkData), verification_data: T.nilable(::Stripe::Issuing::Authorization::CreateParams::VerificationData), wallet: T.nilable(String)).void
}
def initialize(
amount: nil,
amount_details: nil,
authorization_method: nil,
card: nil,
currency: nil,
expand: nil,
fleet: nil,
fuel: nil,
is_amount_controllable: nil,
merchant_amount: nil,
merchant_currency: nil,
merchant_data: nil,
network_data: nil,
verification_data: nil,
wallet: nil
); end
end
class CaptureParams < Stripe::RequestParams
class PurchaseDetails < Stripe::RequestParams
class Fleet < Stripe::RequestParams
class CardholderPromptData < Stripe::RequestParams
# Driver ID.
sig { returns(T.nilable(String)) }
attr_accessor :driver_id
# Odometer reading.
sig { returns(T.nilable(Integer)) }
attr_accessor :odometer
# An alphanumeric ID. This field is used when a vehicle ID, driver ID, or generic ID is entered by the cardholder, but the merchant or card network did not specify the prompt type.
sig { returns(T.nilable(String)) }
attr_accessor :unspecified_id
# User ID.
sig { returns(T.nilable(String)) }
attr_accessor :user_id
# Vehicle number.
sig { returns(T.nilable(String)) }
attr_accessor :vehicle_number
sig {
params(driver_id: T.nilable(String), odometer: T.nilable(Integer), unspecified_id: T.nilable(String), user_id: T.nilable(String), vehicle_number: T.nilable(String)).void
}
def initialize(
driver_id: nil,
odometer: nil,
unspecified_id: nil,
user_id: nil,
vehicle_number: nil
); end
end
class ReportedBreakdown < Stripe::RequestParams
class Fuel < Stripe::RequestParams
# Gross fuel amount that should equal Fuel Volume multipled by Fuel Unit Cost, inclusive of taxes.
sig { returns(T.nilable(String)) }
attr_accessor :gross_amount_decimal
sig { params(gross_amount_decimal: T.nilable(String)).void }
def initialize(gross_amount_decimal: nil); end
end
class NonFuel < Stripe::RequestParams
# Gross non-fuel amount that should equal the sum of the line items, inclusive of taxes.
sig { returns(T.nilable(String)) }
attr_accessor :gross_amount_decimal
sig { params(gross_amount_decimal: T.nilable(String)).void }
def initialize(gross_amount_decimal: nil); end
end
class Tax < Stripe::RequestParams
# Amount of state or provincial Sales Tax included in the transaction amount. Null if not reported by merchant or not subject to tax.
sig { returns(T.nilable(String)) }
attr_accessor :local_amount_decimal
# Amount of national Sales Tax or VAT included in the transaction amount. Null if not reported by merchant or not subject to tax.
sig { returns(T.nilable(String)) }
attr_accessor :national_amount_decimal
sig {
params(local_amount_decimal: T.nilable(String), national_amount_decimal: T.nilable(String)).void
}
def initialize(local_amount_decimal: nil, national_amount_decimal: nil); end
end
# Breakdown of fuel portion of the purchase.
sig {
returns(T.nilable(::Stripe::Issuing::Authorization::CaptureParams::PurchaseDetails::Fleet::ReportedBreakdown::Fuel))
}
attr_accessor :fuel
# Breakdown of non-fuel portion of the purchase.
sig {
returns(T.nilable(::Stripe::Issuing::Authorization::CaptureParams::PurchaseDetails::Fleet::ReportedBreakdown::NonFuel))
}
attr_accessor :non_fuel
# Information about tax included in this transaction.
sig {
returns(T.nilable(::Stripe::Issuing::Authorization::CaptureParams::PurchaseDetails::Fleet::ReportedBreakdown::Tax))
}
attr_accessor :tax
sig {
params(fuel: T.nilable(::Stripe::Issuing::Authorization::CaptureParams::PurchaseDetails::Fleet::ReportedBreakdown::Fuel), non_fuel: T.nilable(::Stripe::Issuing::Authorization::CaptureParams::PurchaseDetails::Fleet::ReportedBreakdown::NonFuel), tax: T.nilable(::Stripe::Issuing::Authorization::CaptureParams::PurchaseDetails::Fleet::ReportedBreakdown::Tax)).void
}
def initialize(fuel: nil, non_fuel: nil, tax: nil); end
end
# Answers to prompts presented to the cardholder at the point of sale. Prompted fields vary depending on the configuration of your physical fleet cards. Typical points of sale support only numeric entry.
sig {
returns(T.nilable(::Stripe::Issuing::Authorization::CaptureParams::PurchaseDetails::Fleet::CardholderPromptData))
}
attr_accessor :cardholder_prompt_data
# The type of purchase. One of `fuel_purchase`, `non_fuel_purchase`, or `fuel_and_non_fuel_purchase`.
sig { returns(T.nilable(String)) }
attr_accessor :purchase_type
# More information about the total amount. This information is not guaranteed to be accurate as some merchants may provide unreliable data.
sig {
returns(T.nilable(::Stripe::Issuing::Authorization::CaptureParams::PurchaseDetails::Fleet::ReportedBreakdown))
}
attr_accessor :reported_breakdown
# The type of fuel service. One of `non_fuel_transaction`, `full_service`, or `self_service`.
sig { returns(T.nilable(String)) }
attr_accessor :service_type
sig {
params(cardholder_prompt_data: T.nilable(::Stripe::Issuing::Authorization::CaptureParams::PurchaseDetails::Fleet::CardholderPromptData), purchase_type: T.nilable(String), reported_breakdown: T.nilable(::Stripe::Issuing::Authorization::CaptureParams::PurchaseDetails::Fleet::ReportedBreakdown), service_type: T.nilable(String)).void
}
def initialize(
cardholder_prompt_data: nil,
purchase_type: nil,
reported_breakdown: nil,
service_type: nil
); end
end
class Flight < Stripe::RequestParams
class Segment < Stripe::RequestParams
# The three-letter IATA airport code of the flight's destination.
sig { returns(T.nilable(String)) }
attr_accessor :arrival_airport_code
# The airline carrier code.
sig { returns(T.nilable(String)) }
attr_accessor :carrier
# The three-letter IATA airport code that the flight departed from.
sig { returns(T.nilable(String)) }
attr_accessor :departure_airport_code
# The flight number.
sig { returns(T.nilable(String)) }
attr_accessor :flight_number
# The flight's service class.
sig { returns(T.nilable(String)) }
attr_accessor :service_class
# Whether a stopover is allowed on this flight.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :stopover_allowed
sig {
params(arrival_airport_code: T.nilable(String), carrier: T.nilable(String), departure_airport_code: T.nilable(String), flight_number: T.nilable(String), service_class: T.nilable(String), stopover_allowed: T.nilable(T::Boolean)).void
}
def initialize(
arrival_airport_code: nil,
carrier: nil,
departure_airport_code: nil,
flight_number: nil,
service_class: nil,
stopover_allowed: nil
); end
end
# The time that the flight departed.
sig { returns(T.nilable(Integer)) }
attr_accessor :departure_at
# The name of the passenger.
sig { returns(T.nilable(String)) }
attr_accessor :passenger_name
# Whether the ticket is refundable.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :refundable
# The legs of the trip.
sig {
returns(T.nilable(T::Array[::Stripe::Issuing::Authorization::CaptureParams::PurchaseDetails::Flight::Segment]))
}
attr_accessor :segments
# The travel agency that issued the ticket.
sig { returns(T.nilable(String)) }
attr_accessor :travel_agency
sig {
params(departure_at: T.nilable(Integer), passenger_name: T.nilable(String), refundable: T.nilable(T::Boolean), segments: T.nilable(T::Array[::Stripe::Issuing::Authorization::CaptureParams::PurchaseDetails::Flight::Segment]), travel_agency: T.nilable(String)).void
}
def initialize(
departure_at: nil,
passenger_name: nil,
refundable: nil,
segments: nil,
travel_agency: nil
); end
end
class Fuel < Stripe::RequestParams
# [Conexxus Payment System Product Code](https://www.conexxus.org/conexxus-payment-system-product-codes) identifying the primary fuel product purchased.
sig { returns(T.nilable(String)) }
attr_accessor :industry_product_code
# The quantity of `unit`s of fuel that was dispensed, represented as a decimal string with at most 12 decimal places.
sig { returns(T.nilable(String)) }
attr_accessor :quantity_decimal
# The type of fuel that was purchased. One of `diesel`, `unleaded_plus`, `unleaded_regular`, `unleaded_super`, or `other`.
sig { returns(T.nilable(String)) }
attr_accessor :type
# The units for `quantity_decimal`. One of `charging_minute`, `imperial_gallon`, `kilogram`, `kilowatt_hour`, `liter`, `pound`, `us_gallon`, or `other`.
sig { returns(T.nilable(String)) }
attr_accessor :unit
# The cost in cents per each unit of fuel, represented as a decimal string with at most 12 decimal places.
sig { returns(T.nilable(String)) }
attr_accessor :unit_cost_decimal
sig {
params(industry_product_code: T.nilable(String), quantity_decimal: T.nilable(String), type: T.nilable(String), unit: T.nilable(String), unit_cost_decimal: T.nilable(String)).void
}
def initialize(
industry_product_code: nil,
quantity_decimal: nil,
type: nil,
unit: nil,
unit_cost_decimal: nil
); end
end
class Lodging < Stripe::RequestParams
# The time of checking into the lodging.
sig { returns(T.nilable(Integer)) }
attr_accessor :check_in_at
# The number of nights stayed at the lodging.
sig { returns(T.nilable(Integer)) }
attr_accessor :nights
sig { params(check_in_at: T.nilable(Integer), nights: T.nilable(Integer)).void }
def initialize(check_in_at: nil, nights: nil); end
end
class Receipt < Stripe::RequestParams
# Attribute for param field description
sig { returns(T.nilable(String)) }
attr_accessor :description
# Attribute for param field quantity
sig { returns(T.nilable(String)) }
attr_accessor :quantity
# Attribute for param field total
sig { returns(T.nilable(Integer)) }
attr_accessor :total
# Attribute for param field unit_cost
sig { returns(T.nilable(Integer)) }
attr_accessor :unit_cost
sig {
params(description: T.nilable(String), quantity: T.nilable(String), total: T.nilable(Integer), unit_cost: T.nilable(Integer)).void
}
def initialize(description: nil, quantity: nil, total: nil, unit_cost: nil); end
end
# Fleet-specific information for transactions using Fleet cards.
sig {
returns(T.nilable(::Stripe::Issuing::Authorization::CaptureParams::PurchaseDetails::Fleet))
}
attr_accessor :fleet
# Information about the flight that was purchased with this transaction.
sig {
returns(T.nilable(::Stripe::Issuing::Authorization::CaptureParams::PurchaseDetails::Flight))
}
attr_accessor :flight
# Information about fuel that was purchased with this transaction.
sig {
returns(T.nilable(::Stripe::Issuing::Authorization::CaptureParams::PurchaseDetails::Fuel))
}
attr_accessor :fuel
# Information about lodging that was purchased with this transaction.
sig {
returns(T.nilable(::Stripe::Issuing::Authorization::CaptureParams::PurchaseDetails::Lodging))
}
attr_accessor :lodging
# The line items in the purchase.
sig {
returns(T.nilable(T::Array[::Stripe::Issuing::Authorization::CaptureParams::PurchaseDetails::Receipt]))
}
attr_accessor :receipt
# A merchant-specific order number.
sig { returns(T.nilable(String)) }
attr_accessor :reference
sig {
params(fleet: T.nilable(::Stripe::Issuing::Authorization::CaptureParams::PurchaseDetails::Fleet), flight: T.nilable(::Stripe::Issuing::Authorization::CaptureParams::PurchaseDetails::Flight), fuel: T.nilable(::Stripe::Issuing::Authorization::CaptureParams::PurchaseDetails::Fuel), lodging: T.nilable(::Stripe::Issuing::Authorization::CaptureParams::PurchaseDetails::Lodging), receipt: T.nilable(T::Array[::Stripe::Issuing::Authorization::CaptureParams::PurchaseDetails::Receipt]), reference: T.nilable(String)).void
}
def initialize(
fleet: nil,
flight: nil,
fuel: nil,
lodging: nil,
receipt: nil,
reference: nil
); end
end
# The amount to capture from the authorization. If not provided, the full amount of the authorization will be captured. This amount is in the authorization currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(T.nilable(Integer)) }
attr_accessor :capture_amount
# Whether to close the authorization after capture. Defaults to true. Set to false to enable multi-capture flows.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :close_authorization
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Additional purchase information that is optionally provided by the merchant.
sig { returns(T.nilable(::Stripe::Issuing::Authorization::CaptureParams::PurchaseDetails)) }
attr_accessor :purchase_details
sig {
params(capture_amount: T.nilable(Integer), close_authorization: T.nilable(T::Boolean), expand: T.nilable(T::Array[String]), purchase_details: T.nilable(::Stripe::Issuing::Authorization::CaptureParams::PurchaseDetails)).void
}
def initialize(
capture_amount: nil,
close_authorization: nil,
expand: nil,
purchase_details: nil
); end
end
class ExpireParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class FinalizeAmountParams < Stripe::RequestParams
class Fleet < Stripe::RequestParams
class CardholderPromptData < Stripe::RequestParams
# Driver ID.
sig { returns(T.nilable(String)) }
attr_accessor :driver_id
# Odometer reading.
sig { returns(T.nilable(Integer)) }
attr_accessor :odometer
# An alphanumeric ID. This field is used when a vehicle ID, driver ID, or generic ID is entered by the cardholder, but the merchant or card network did not specify the prompt type.
sig { returns(T.nilable(String)) }
attr_accessor :unspecified_id
# User ID.
sig { returns(T.nilable(String)) }
attr_accessor :user_id
# Vehicle number.
sig { returns(T.nilable(String)) }
attr_accessor :vehicle_number
sig {
params(driver_id: T.nilable(String), odometer: T.nilable(Integer), unspecified_id: T.nilable(String), user_id: T.nilable(String), vehicle_number: T.nilable(String)).void
}
def initialize(
driver_id: nil,
odometer: nil,
unspecified_id: nil,
user_id: nil,
vehicle_number: nil
); end
end
class ReportedBreakdown < Stripe::RequestParams
class Fuel < Stripe::RequestParams
# Gross fuel amount that should equal Fuel Volume multipled by Fuel Unit Cost, inclusive of taxes.
sig { returns(T.nilable(String)) }
attr_accessor :gross_amount_decimal
sig { params(gross_amount_decimal: T.nilable(String)).void }
def initialize(gross_amount_decimal: nil); end
end
class NonFuel < Stripe::RequestParams
# Gross non-fuel amount that should equal the sum of the line items, inclusive of taxes.
sig { returns(T.nilable(String)) }
attr_accessor :gross_amount_decimal
sig { params(gross_amount_decimal: T.nilable(String)).void }
def initialize(gross_amount_decimal: nil); end
end
class Tax < Stripe::RequestParams
# Amount of state or provincial Sales Tax included in the transaction amount. Null if not reported by merchant or not subject to tax.
sig { returns(T.nilable(String)) }
attr_accessor :local_amount_decimal
# Amount of national Sales Tax or VAT included in the transaction amount. Null if not reported by merchant or not subject to tax.
sig { returns(T.nilable(String)) }
attr_accessor :national_amount_decimal
sig {
params(local_amount_decimal: T.nilable(String), national_amount_decimal: T.nilable(String)).void
}
def initialize(local_amount_decimal: nil, national_amount_decimal: nil); end
end
# Breakdown of fuel portion of the purchase.
sig {
returns(T.nilable(::Stripe::Issuing::Authorization::FinalizeAmountParams::Fleet::ReportedBreakdown::Fuel))
}
attr_accessor :fuel
# Breakdown of non-fuel portion of the purchase.
sig {
returns(T.nilable(::Stripe::Issuing::Authorization::FinalizeAmountParams::Fleet::ReportedBreakdown::NonFuel))
}
attr_accessor :non_fuel
# Information about tax included in this transaction.
sig {
returns(T.nilable(::Stripe::Issuing::Authorization::FinalizeAmountParams::Fleet::ReportedBreakdown::Tax))
}
attr_accessor :tax
sig {
params(fuel: T.nilable(::Stripe::Issuing::Authorization::FinalizeAmountParams::Fleet::ReportedBreakdown::Fuel), non_fuel: T.nilable(::Stripe::Issuing::Authorization::FinalizeAmountParams::Fleet::ReportedBreakdown::NonFuel), tax: T.nilable(::Stripe::Issuing::Authorization::FinalizeAmountParams::Fleet::ReportedBreakdown::Tax)).void
}
def initialize(fuel: nil, non_fuel: nil, tax: nil); end
end
# Answers to prompts presented to the cardholder at the point of sale. Prompted fields vary depending on the configuration of your physical fleet cards. Typical points of sale support only numeric entry.
sig {
returns(T.nilable(::Stripe::Issuing::Authorization::FinalizeAmountParams::Fleet::CardholderPromptData))
}
attr_accessor :cardholder_prompt_data
# The type of purchase. One of `fuel_purchase`, `non_fuel_purchase`, or `fuel_and_non_fuel_purchase`.
sig { returns(T.nilable(String)) }
attr_accessor :purchase_type
# More information about the total amount. This information is not guaranteed to be accurate as some merchants may provide unreliable data.
sig {
returns(T.nilable(::Stripe::Issuing::Authorization::FinalizeAmountParams::Fleet::ReportedBreakdown))
}
attr_accessor :reported_breakdown
# The type of fuel service. One of `non_fuel_transaction`, `full_service`, or `self_service`.
sig { returns(T.nilable(String)) }
attr_accessor :service_type
sig {
params(cardholder_prompt_data: T.nilable(::Stripe::Issuing::Authorization::FinalizeAmountParams::Fleet::CardholderPromptData), purchase_type: T.nilable(String), reported_breakdown: T.nilable(::Stripe::Issuing::Authorization::FinalizeAmountParams::Fleet::ReportedBreakdown), service_type: T.nilable(String)).void
}
def initialize(
cardholder_prompt_data: nil,
purchase_type: nil,
reported_breakdown: nil,
service_type: nil
); end
end
class Fuel < Stripe::RequestParams
# [Conexxus Payment System Product Code](https://www.conexxus.org/conexxus-payment-system-product-codes) identifying the primary fuel product purchased.
sig { returns(T.nilable(String)) }
attr_accessor :industry_product_code
# The quantity of `unit`s of fuel that was dispensed, represented as a decimal string with at most 12 decimal places.
sig { returns(T.nilable(String)) }
attr_accessor :quantity_decimal
# The type of fuel that was purchased. One of `diesel`, `unleaded_plus`, `unleaded_regular`, `unleaded_super`, or `other`.
sig { returns(T.nilable(String)) }
attr_accessor :type
# The units for `quantity_decimal`. One of `charging_minute`, `imperial_gallon`, `kilogram`, `kilowatt_hour`, `liter`, `pound`, `us_gallon`, or `other`.
sig { returns(T.nilable(String)) }
attr_accessor :unit
# The cost in cents per each unit of fuel, represented as a decimal string with at most 12 decimal places.
sig { returns(T.nilable(String)) }
attr_accessor :unit_cost_decimal
sig {
params(industry_product_code: T.nilable(String), quantity_decimal: T.nilable(String), type: T.nilable(String), unit: T.nilable(String), unit_cost_decimal: T.nilable(String)).void
}
def initialize(
industry_product_code: nil,
quantity_decimal: nil,
type: nil,
unit: nil,
unit_cost_decimal: nil
); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The final authorization amount that will be captured by the merchant. This amount is in the authorization currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(Integer) }
attr_accessor :final_amount
# Fleet-specific information for authorizations using Fleet cards.
sig { returns(T.nilable(::Stripe::Issuing::Authorization::FinalizeAmountParams::Fleet)) }
attr_accessor :fleet
# Information about fuel that was purchased with this transaction.
sig { returns(T.nilable(::Stripe::Issuing::Authorization::FinalizeAmountParams::Fuel)) }
attr_accessor :fuel
sig {
params(expand: T.nilable(T::Array[String]), final_amount: Integer, fleet: T.nilable(::Stripe::Issuing::Authorization::FinalizeAmountParams::Fleet), fuel: T.nilable(::Stripe::Issuing::Authorization::FinalizeAmountParams::Fuel)).void
}
def initialize(expand: nil, final_amount: nil, fleet: nil, fuel: nil); end
end
class RespondParams < Stripe::RequestParams
# Whether to simulate the user confirming that the transaction was legitimate (true) or telling Stripe that it was fraudulent (false).
sig { returns(T::Boolean) }
attr_accessor :confirmed
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(confirmed: T::Boolean, expand: T.nilable(T::Array[String])).void }
def initialize(confirmed: nil, expand: nil); end
end
class IncrementParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The amount to increment the authorization by. This amount is in the authorization currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(Integer) }
attr_accessor :increment_amount
# If set `true`, you may provide [amount](https://stripe.com/docs/api/issuing/authorizations/approve#approve_issuing_authorization-amount) to control how much to hold for the authorization.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :is_amount_controllable
sig {
params(expand: T.nilable(T::Array[String]), increment_amount: Integer, is_amount_controllable: T.nilable(T::Boolean)).void
}
def initialize(expand: nil, increment_amount: nil, is_amount_controllable: nil); end
end
class ReverseParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The amount to reverse from the authorization. If not provided, the full amount of the authorization will be reversed. This amount is in the authorization currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(T.nilable(Integer)) }
attr_accessor :reverse_amount
sig { params(expand: T.nilable(T::Array[String]), reverse_amount: T.nilable(Integer)).void }
def initialize(expand: nil, reverse_amount: nil); end
end
# [Deprecated] Approves a pending Issuing Authorization object. This request should be made within the timeout window of the [real-time authorization](https://docs.stripe.com/docs/issuing/controls/real-time-authorizations) flow.
# This method is deprecated. Instead, [respond directly to the webhook request to approve an authorization](https://docs.stripe.com/docs/issuing/controls/real-time-authorizations#authorization-handling).
sig {
params(params: T.any(::Stripe::Issuing::Authorization::ApproveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Authorization)
}
def approve(params = {}, opts = {}); end
# [Deprecated] Approves a pending Issuing Authorization object. This request should be made within the timeout window of the [real-time authorization](https://docs.stripe.com/docs/issuing/controls/real-time-authorizations) flow.
# This method is deprecated. Instead, [respond directly to the webhook request to approve an authorization](https://docs.stripe.com/docs/issuing/controls/real-time-authorizations#authorization-handling).
sig {
params(authorization: String, params: T.any(::Stripe::Issuing::Authorization::ApproveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Authorization)
}
def self.approve(authorization, params = {}, opts = {}); end
# [Deprecated] Declines a pending Issuing Authorization object. This request should be made within the timeout window of the [real time authorization](https://docs.stripe.com/docs/issuing/controls/real-time-authorizations) flow.
# This method is deprecated. Instead, [respond directly to the webhook request to decline an authorization](https://docs.stripe.com/docs/issuing/controls/real-time-authorizations#authorization-handling).
sig {
params(params: T.any(::Stripe::Issuing::Authorization::DeclineParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Authorization)
}
def decline(params = {}, opts = {}); end
# [Deprecated] Declines a pending Issuing Authorization object. This request should be made within the timeout window of the [real time authorization](https://docs.stripe.com/docs/issuing/controls/real-time-authorizations) flow.
# This method is deprecated. Instead, [respond directly to the webhook request to decline an authorization](https://docs.stripe.com/docs/issuing/controls/real-time-authorizations#authorization-handling).
sig {
params(authorization: String, params: T.any(::Stripe::Issuing::Authorization::DeclineParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Authorization)
}
def self.decline(authorization, params = {}, opts = {}); end
# Returns a list of Issuing Authorization objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.
sig {
params(params: T.any(::Stripe::Issuing::Authorization::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Updates the specified Issuing Authorization object by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
sig {
params(authorization: String, params: T.any(::Stripe::Issuing::Authorization::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Authorization)
}
def self.update(authorization, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Issuing
# You can [create physical or virtual cards](https://stripe.com/docs/issuing) that are issued to cardholders.
class Card < APIResource
class Shipping < Stripe::StripeObject
class Address < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
class AddressValidation < Stripe::StripeObject
class NormalizedAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# The address validation capabilities to use.
sig { returns(String) }
attr_reader :mode
# The normalized shipping address.
sig { returns(T.nilable(NormalizedAddress)) }
attr_reader :normalized_address
# The validation result for the shipping address.
sig { returns(T.nilable(String)) }
attr_reader :result
end
class Customs < Stripe::StripeObject
# A registration number used for customs in Europe. See [https://www.gov.uk/eori](https://www.gov.uk/eori) for the UK and [https://ec.europa.eu/taxation_customs/business/customs-procedures-import-and-export/customs-procedures/economic-operators-registration-and-identification-number-eori_en](https://ec.europa.eu/taxation_customs/business/customs-procedures-import-and-export/customs-procedures/economic-operators-registration-and-identification-number-eori_en) for the EU.
sig { returns(T.nilable(String)) }
attr_reader :eori_number
end
# Attribute for field address
sig { returns(Address) }
attr_reader :address
# Address validation details for the shipment.
sig { returns(T.nilable(AddressValidation)) }
attr_reader :address_validation
# The delivery company that shipped a card.
sig { returns(T.nilable(String)) }
attr_reader :carrier
# Additional information that may be required for clearing customs.
sig { returns(T.nilable(Customs)) }
attr_reader :customs
# A unix timestamp representing a best estimate of when the card will be delivered.
sig { returns(T.nilable(Integer)) }
attr_reader :eta
# Recipient name.
sig { returns(String) }
attr_reader :name
# The phone number of the receiver of the shipment. Our courier partners will use this number to contact you in the event of card delivery issues. For individual shipments to the EU/UK, if this field is empty, we will provide them with the phone number provided when the cardholder was initially created.
sig { returns(T.nilable(String)) }
attr_reader :phone_number
# Whether a signature is required for card delivery. This feature is only supported for US users. Standard shipping service does not support signature on delivery. The default value for standard shipping service is false and for express and priority services is true.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :require_signature
# Shipment service, such as `standard` or `express`.
sig { returns(String) }
attr_reader :service
# The delivery status of the card.
sig { returns(T.nilable(String)) }
attr_reader :status
# A tracking number for a card shipment.
sig { returns(T.nilable(String)) }
attr_reader :tracking_number
# A link to the shipping carrier's site where you can view detailed information about a card shipment.
sig { returns(T.nilable(String)) }
attr_reader :tracking_url
# Packaging options.
sig { returns(String) }
attr_reader :type
end
class SpendingControls < Stripe::StripeObject
class SpendingLimit < Stripe::StripeObject
# Maximum amount allowed to spend per interval. This amount is in the card's currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(Integer) }
attr_reader :amount
# Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) this limit applies to. Omitting this field will apply the limit to all categories.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :categories
# Interval (or event) to which the amount applies.
sig { returns(String) }
attr_reader :interval
end
# Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to allow. All other categories will be blocked. Cannot be set with `blocked_categories`.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :allowed_categories
# Array of strings containing representing countries from which authorizations will be allowed. Authorizations from merchants in all other countries will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `blocked_merchant_countries`. Provide an empty value to unset this control.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :allowed_merchant_countries
# Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to decline. All other categories will be allowed. Cannot be set with `allowed_categories`.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :blocked_categories
# Array of strings containing representing countries from which authorizations will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `allowed_merchant_countries`. Provide an empty value to unset this control.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :blocked_merchant_countries
# Limit spending with amount-based rules that apply across any cards this card replaced (i.e., its `replacement_for` card and _that_ card's `replacement_for` card, up the chain).
sig { returns(T.nilable(T::Array[SpendingLimit])) }
attr_reader :spending_limits
# Currency of the amounts within `spending_limits`. Always the same as the currency of the card.
sig { returns(T.nilable(String)) }
attr_reader :spending_limits_currency
end
class Wallets < Stripe::StripeObject
class ApplePay < Stripe::StripeObject
# Apple Pay Eligibility
sig { returns(T::Boolean) }
attr_reader :eligible
# Reason the card is ineligible for Apple Pay
sig { returns(T.nilable(String)) }
attr_reader :ineligible_reason
end
class GooglePay < Stripe::StripeObject
# Google Pay Eligibility
sig { returns(T::Boolean) }
attr_reader :eligible
# Reason the card is ineligible for Google Pay
sig { returns(T.nilable(String)) }
attr_reader :ineligible_reason
end
# Attribute for field apple_pay
sig { returns(ApplePay) }
attr_reader :apple_pay
# Attribute for field google_pay
sig { returns(GooglePay) }
attr_reader :google_pay
# Unique identifier for a card used with digital wallets
sig { returns(T.nilable(String)) }
attr_reader :primary_account_identifier
end
# The brand of the card.
sig { returns(String) }
attr_reader :brand
# The reason why the card was canceled.
sig { returns(T.nilable(String)) }
attr_reader :cancellation_reason
# An Issuing `Cardholder` object represents an individual or business entity who is [issued](https://stripe.com/docs/issuing) cards.
#
# Related guide: [How to create a cardholder](https://stripe.com/docs/issuing/cards/virtual/issue-cards#create-cardholder)
sig { returns(Stripe::Issuing::Cardholder) }
attr_reader :cardholder
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Supported currencies are `usd` in the US, `eur` in the EU, and `gbp` in the UK.
sig { returns(String) }
attr_reader :currency
# The card's CVC. For security reasons, this is only available for virtual cards, and will be omitted unless you explicitly request it with [the `expand` parameter](https://stripe.com/docs/api/expanding_objects). Additionally, it's only available via the ["Retrieve a card" endpoint](https://stripe.com/docs/api/issuing/cards/retrieve), not via "List all cards" or any other endpoint.
sig { returns(String) }
attr_reader :cvc
# The expiration month of the card.
sig { returns(Integer) }
attr_reader :exp_month
# The expiration year of the card.
sig { returns(Integer) }
attr_reader :exp_year
# The financial account this card is attached to.
sig { returns(T.nilable(String)) }
attr_reader :financial_account
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# The last 4 digits of the card number.
sig { returns(String) }
attr_reader :last4
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# 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.
sig { returns(T::Hash[String, String]) }
attr_reader :metadata
# The full unredacted card number. For security reasons, this is only available for virtual cards, and will be omitted unless you explicitly request it with [the `expand` parameter](https://stripe.com/docs/api/expanding_objects). Additionally, it's only available via the ["Retrieve a card" endpoint](https://stripe.com/docs/api/issuing/cards/retrieve), not via "List all cards" or any other endpoint.
sig { returns(String) }
attr_reader :number
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The personalization design object belonging to this card.
sig { returns(T.nilable(T.any(String, Stripe::Issuing::PersonalizationDesign))) }
attr_reader :personalization_design
# The latest card that replaces this card, if any.
sig { returns(T.nilable(T.any(String, Stripe::Issuing::Card))) }
attr_reader :replaced_by
# The card this card replaces, if any.
sig { returns(T.nilable(T.any(String, Stripe::Issuing::Card))) }
attr_reader :replacement_for
# The reason why the previous card needed to be replaced.
sig { returns(T.nilable(String)) }
attr_reader :replacement_reason
# Where and how the card will be shipped.
sig { returns(T.nilable(Shipping)) }
attr_reader :shipping
# Attribute for field spending_controls
sig { returns(SpendingControls) }
attr_reader :spending_controls
# Whether authorizations can be approved on this card. May be blocked from activating cards depending on past-due Cardholder requirements. Defaults to `inactive`.
sig { returns(String) }
attr_reader :status
# The type of the card.
sig { returns(String) }
attr_reader :type
# Information relating to digital wallets (like Apple Pay and Google Pay).
sig { returns(T.nilable(Wallets)) }
attr_reader :wallets
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return cards belonging to the Cardholder with the provided ID.
sig { returns(T.nilable(String)) }
attr_accessor :cardholder
# Only return cards that were issued during the given date interval.
sig { returns(T.nilable(T.any(::Stripe::Issuing::Card::ListParams::Created, Integer))) }
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Only return cards that have the given expiration month.
sig { returns(T.nilable(Integer)) }
attr_accessor :exp_month
# Only return cards that have the given expiration year.
sig { returns(T.nilable(Integer)) }
attr_accessor :exp_year
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Only return cards that have the given last four digits.
sig { returns(T.nilable(String)) }
attr_accessor :last4
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Attribute for param field personalization_design
sig { returns(T.nilable(String)) }
attr_accessor :personalization_design
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return cards that have the given status. One of `active`, `inactive`, or `canceled`.
sig { returns(T.nilable(String)) }
attr_accessor :status
# Only return cards that have the given type. One of `virtual` or `physical`.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(cardholder: T.nilable(String), created: T.nilable(T.any(::Stripe::Issuing::Card::ListParams::Created, Integer)), ending_before: T.nilable(String), exp_month: T.nilable(Integer), exp_year: T.nilable(Integer), expand: T.nilable(T::Array[String]), last4: T.nilable(String), limit: T.nilable(Integer), personalization_design: T.nilable(String), starting_after: T.nilable(String), status: T.nilable(String), type: T.nilable(String)).void
}
def initialize(
cardholder: nil,
created: nil,
ending_before: nil,
exp_month: nil,
exp_year: nil,
expand: nil,
last4: nil,
limit: nil,
personalization_design: nil,
starting_after: nil,
status: nil,
type: nil
); end
end
class CreateParams < Stripe::RequestParams
class Pin < Stripe::RequestParams
# The card's desired new PIN, encrypted under Stripe's public key.
sig { returns(T.nilable(String)) }
attr_accessor :encrypted_number
sig { params(encrypted_number: T.nilable(String)).void }
def initialize(encrypted_number: nil); end
end
class Shipping < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(String) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(String) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(String) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(String) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: String, country: String, line1: String, line2: T.nilable(String), postal_code: String, state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class AddressValidation < Stripe::RequestParams
# The address validation capabilities to use.
sig { returns(String) }
attr_accessor :mode
sig { params(mode: String).void }
def initialize(mode: nil); end
end
class Customs < Stripe::RequestParams
# The Economic Operators Registration and Identification (EORI) number to use for Customs. Required for bulk shipments to Europe.
sig { returns(T.nilable(String)) }
attr_accessor :eori_number
sig { params(eori_number: T.nilable(String)).void }
def initialize(eori_number: nil); end
end
# The address that the card is shipped to.
sig { returns(::Stripe::Issuing::Card::CreateParams::Shipping::Address) }
attr_accessor :address
# Address validation settings.
sig {
returns(T.nilable(::Stripe::Issuing::Card::CreateParams::Shipping::AddressValidation))
}
attr_accessor :address_validation
# Customs information for the shipment.
sig { returns(T.nilable(::Stripe::Issuing::Card::CreateParams::Shipping::Customs)) }
attr_accessor :customs
# The name printed on the shipping label when shipping the card.
sig { returns(String) }
attr_accessor :name
# Phone number of the recipient of the shipment.
sig { returns(T.nilable(String)) }
attr_accessor :phone_number
# Whether a signature is required for card delivery.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :require_signature
# Shipment service.
sig { returns(T.nilable(String)) }
attr_accessor :service
# Packaging options.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(address: ::Stripe::Issuing::Card::CreateParams::Shipping::Address, address_validation: T.nilable(::Stripe::Issuing::Card::CreateParams::Shipping::AddressValidation), customs: T.nilable(::Stripe::Issuing::Card::CreateParams::Shipping::Customs), name: String, phone_number: T.nilable(String), require_signature: T.nilable(T::Boolean), service: T.nilable(String), type: T.nilable(String)).void
}
def initialize(
address: nil,
address_validation: nil,
customs: nil,
name: nil,
phone_number: nil,
require_signature: nil,
service: nil,
type: nil
); end
end
class SpendingControls < Stripe::RequestParams
class SpendingLimit < Stripe::RequestParams
# Maximum amount allowed to spend per interval.
sig { returns(Integer) }
attr_accessor :amount
# Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) this limit applies to. Omitting this field will apply the limit to all categories.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :categories
# Interval (or event) to which the amount applies.
sig { returns(String) }
attr_accessor :interval
sig {
params(amount: Integer, categories: T.nilable(T::Array[String]), interval: String).void
}
def initialize(amount: nil, categories: nil, interval: nil); end
end
# Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to allow. All other categories will be blocked. Cannot be set with `blocked_categories`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :allowed_categories
# Array of strings containing representing countries from which authorizations will be allowed. Authorizations from merchants in all other countries will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `blocked_merchant_countries`. Provide an empty value to unset this control.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :allowed_merchant_countries
# Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to decline. All other categories will be allowed. Cannot be set with `allowed_categories`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :blocked_categories
# Array of strings containing representing countries from which authorizations will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `allowed_merchant_countries`. Provide an empty value to unset this control.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :blocked_merchant_countries
# Limit spending with amount-based rules that apply across any cards this card replaced (i.e., its `replacement_for` card and _that_ card's `replacement_for` card, up the chain).
sig {
returns(T.nilable(T::Array[::Stripe::Issuing::Card::CreateParams::SpendingControls::SpendingLimit]))
}
attr_accessor :spending_limits
sig {
params(allowed_categories: T.nilable(T::Array[String]), allowed_merchant_countries: T.nilable(T::Array[String]), blocked_categories: T.nilable(T::Array[String]), blocked_merchant_countries: T.nilable(T::Array[String]), spending_limits: T.nilable(T::Array[::Stripe::Issuing::Card::CreateParams::SpendingControls::SpendingLimit])).void
}
def initialize(
allowed_categories: nil,
allowed_merchant_countries: nil,
blocked_categories: nil,
blocked_merchant_countries: nil,
spending_limits: nil
); end
end
# The [Cardholder](https://stripe.com/docs/api#issuing_cardholder_object) object with which the card will be associated.
sig { returns(T.nilable(String)) }
attr_accessor :cardholder
# The currency for the card.
sig { returns(String) }
attr_accessor :currency
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The new financial account ID the card will be associated with. This field allows a card to be reassigned to a different financial account.
sig { returns(T.nilable(String)) }
attr_accessor :financial_account
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The personalization design object belonging to this card.
sig { returns(T.nilable(String)) }
attr_accessor :personalization_design
# The desired PIN for this card.
sig { returns(T.nilable(::Stripe::Issuing::Card::CreateParams::Pin)) }
attr_accessor :pin
# The card this is meant to be a replacement for (if any).
sig { returns(T.nilable(String)) }
attr_accessor :replacement_for
# If `replacement_for` is specified, this should indicate why that card is being replaced.
sig { returns(T.nilable(String)) }
attr_accessor :replacement_reason
# The second line to print on the card. Max length: 24 characters.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :second_line
# The address where the card will be shipped.
sig { returns(T.nilable(::Stripe::Issuing::Card::CreateParams::Shipping)) }
attr_accessor :shipping
# Rules that control spending for this card. Refer to our [documentation](https://stripe.com/docs/issuing/controls/spending-controls) for more details.
sig { returns(T.nilable(::Stripe::Issuing::Card::CreateParams::SpendingControls)) }
attr_accessor :spending_controls
# Whether authorizations can be approved on this card. May be blocked from activating cards depending on past-due Cardholder requirements. Defaults to `inactive`.
sig { returns(T.nilable(String)) }
attr_accessor :status
# The type of card to issue. Possible values are `physical` or `virtual`.
sig { returns(String) }
attr_accessor :type
sig {
params(cardholder: T.nilable(String), currency: String, expand: T.nilable(T::Array[String]), financial_account: T.nilable(String), metadata: T.nilable(T::Hash[String, String]), personalization_design: T.nilable(String), pin: T.nilable(::Stripe::Issuing::Card::CreateParams::Pin), replacement_for: T.nilable(String), replacement_reason: T.nilable(String), second_line: T.nilable(T.nilable(String)), shipping: T.nilable(::Stripe::Issuing::Card::CreateParams::Shipping), spending_controls: T.nilable(::Stripe::Issuing::Card::CreateParams::SpendingControls), status: T.nilable(String), type: String).void
}
def initialize(
cardholder: nil,
currency: nil,
expand: nil,
financial_account: nil,
metadata: nil,
personalization_design: nil,
pin: nil,
replacement_for: nil,
replacement_reason: nil,
second_line: nil,
shipping: nil,
spending_controls: nil,
status: nil,
type: nil
); end
end
class UpdateParams < Stripe::RequestParams
class Pin < Stripe::RequestParams
# The card's desired new PIN, encrypted under Stripe's public key.
sig { returns(T.nilable(String)) }
attr_accessor :encrypted_number
sig { params(encrypted_number: T.nilable(String)).void }
def initialize(encrypted_number: nil); end
end
class Shipping < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(String) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(String) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(String) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(String) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: String, country: String, line1: String, line2: T.nilable(String), postal_code: String, state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class AddressValidation < Stripe::RequestParams
# The address validation capabilities to use.
sig { returns(String) }
attr_accessor :mode
sig { params(mode: String).void }
def initialize(mode: nil); end
end
class Customs < Stripe::RequestParams
# The Economic Operators Registration and Identification (EORI) number to use for Customs. Required for bulk shipments to Europe.
sig { returns(T.nilable(String)) }
attr_accessor :eori_number
sig { params(eori_number: T.nilable(String)).void }
def initialize(eori_number: nil); end
end
# The address that the card is shipped to.
sig { returns(::Stripe::Issuing::Card::UpdateParams::Shipping::Address) }
attr_accessor :address
# Address validation settings.
sig {
returns(T.nilable(::Stripe::Issuing::Card::UpdateParams::Shipping::AddressValidation))
}
attr_accessor :address_validation
# Customs information for the shipment.
sig { returns(T.nilable(::Stripe::Issuing::Card::UpdateParams::Shipping::Customs)) }
attr_accessor :customs
# The name printed on the shipping label when shipping the card.
sig { returns(String) }
attr_accessor :name
# Phone number of the recipient of the shipment.
sig { returns(T.nilable(String)) }
attr_accessor :phone_number
# Whether a signature is required for card delivery.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :require_signature
# Shipment service.
sig { returns(T.nilable(String)) }
attr_accessor :service
# Packaging options.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(address: ::Stripe::Issuing::Card::UpdateParams::Shipping::Address, address_validation: T.nilable(::Stripe::Issuing::Card::UpdateParams::Shipping::AddressValidation), customs: T.nilable(::Stripe::Issuing::Card::UpdateParams::Shipping::Customs), name: String, phone_number: T.nilable(String), require_signature: T.nilable(T::Boolean), service: T.nilable(String), type: T.nilable(String)).void
}
def initialize(
address: nil,
address_validation: nil,
customs: nil,
name: nil,
phone_number: nil,
require_signature: nil,
service: nil,
type: nil
); end
end
class SpendingControls < Stripe::RequestParams
class SpendingLimit < Stripe::RequestParams
# Maximum amount allowed to spend per interval.
sig { returns(Integer) }
attr_accessor :amount
# Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) this limit applies to. Omitting this field will apply the limit to all categories.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :categories
# Interval (or event) to which the amount applies.
sig { returns(String) }
attr_accessor :interval
sig {
params(amount: Integer, categories: T.nilable(T::Array[String]), interval: String).void
}
def initialize(amount: nil, categories: nil, interval: nil); end
end
# Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to allow. All other categories will be blocked. Cannot be set with `blocked_categories`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :allowed_categories
# Array of strings containing representing countries from which authorizations will be allowed. Authorizations from merchants in all other countries will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `blocked_merchant_countries`. Provide an empty value to unset this control.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :allowed_merchant_countries
# Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to decline. All other categories will be allowed. Cannot be set with `allowed_categories`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :blocked_categories
# Array of strings containing representing countries from which authorizations will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `allowed_merchant_countries`. Provide an empty value to unset this control.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :blocked_merchant_countries
# Limit spending with amount-based rules that apply across any cards this card replaced (i.e., its `replacement_for` card and _that_ card's `replacement_for` card, up the chain).
sig {
returns(T.nilable(T::Array[::Stripe::Issuing::Card::UpdateParams::SpendingControls::SpendingLimit]))
}
attr_accessor :spending_limits
sig {
params(allowed_categories: T.nilable(T::Array[String]), allowed_merchant_countries: T.nilable(T::Array[String]), blocked_categories: T.nilable(T::Array[String]), blocked_merchant_countries: T.nilable(T::Array[String]), spending_limits: T.nilable(T::Array[::Stripe::Issuing::Card::UpdateParams::SpendingControls::SpendingLimit])).void
}
def initialize(
allowed_categories: nil,
allowed_merchant_countries: nil,
blocked_categories: nil,
blocked_merchant_countries: nil,
spending_limits: nil
); end
end
# Reason why the `status` of this card is `canceled`.
sig { returns(T.nilable(String)) }
attr_accessor :cancellation_reason
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Attribute for param field personalization_design
sig { returns(T.nilable(String)) }
attr_accessor :personalization_design
# The desired new PIN for this card.
sig { returns(T.nilable(::Stripe::Issuing::Card::UpdateParams::Pin)) }
attr_accessor :pin
# Updated shipping information for the card.
sig { returns(T.nilable(::Stripe::Issuing::Card::UpdateParams::Shipping)) }
attr_accessor :shipping
# Rules that control spending for this card. Refer to our [documentation](https://stripe.com/docs/issuing/controls/spending-controls) for more details.
sig { returns(T.nilable(::Stripe::Issuing::Card::UpdateParams::SpendingControls)) }
attr_accessor :spending_controls
# Dictates whether authorizations can be approved on this card. May be blocked from activating cards depending on past-due Cardholder requirements. Defaults to `inactive`. If this card is being canceled because it was lost or stolen, this information should be provided as `cancellation_reason`.
sig { returns(T.nilable(String)) }
attr_accessor :status
sig {
params(cancellation_reason: T.nilable(String), expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), personalization_design: T.nilable(String), pin: T.nilable(::Stripe::Issuing::Card::UpdateParams::Pin), shipping: T.nilable(::Stripe::Issuing::Card::UpdateParams::Shipping), spending_controls: T.nilable(::Stripe::Issuing::Card::UpdateParams::SpendingControls), status: T.nilable(String)).void
}
def initialize(
cancellation_reason: nil,
expand: nil,
metadata: nil,
personalization_design: nil,
pin: nil,
shipping: nil,
spending_controls: nil,
status: nil
); end
end
class DeliverCardParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class FailCardParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class ReturnCardParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class ShipCardParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class SubmitCardParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Creates an Issuing Card object.
sig {
params(params: T.any(::Stripe::Issuing::Card::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Card)
}
def self.create(params = {}, opts = {}); end
# Returns a list of Issuing Card objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.
sig {
params(params: T.any(::Stripe::Issuing::Card::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Updates the specified Issuing Card object by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
sig {
params(card: String, params: T.any(::Stripe::Issuing::Card::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Card)
}
def self.update(card, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Issuing
# An Issuing `Cardholder` object represents an individual or business entity who is [issued](https://stripe.com/docs/issuing) cards.
#
# Related guide: [How to create a cardholder](https://stripe.com/docs/issuing/cards/virtual/issue-cards#create-cardholder)
class Cardholder < APIResource
class Billing < Stripe::StripeObject
class Address < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Attribute for field address
sig { returns(Address) }
attr_reader :address
end
class Company < Stripe::StripeObject
# Whether the company's business ID number was provided.
sig { returns(T::Boolean) }
attr_reader :tax_id_provided
end
class Individual < Stripe::StripeObject
class CardIssuing < Stripe::StripeObject
class UserTermsAcceptance < Stripe::StripeObject
# The Unix timestamp marking when the cardholder accepted the Authorized User Terms.
sig { returns(T.nilable(Integer)) }
attr_reader :date
# The IP address from which the cardholder accepted the Authorized User Terms.
sig { returns(T.nilable(String)) }
attr_reader :ip
# The user agent of the browser from which the cardholder accepted the Authorized User Terms.
sig { returns(T.nilable(String)) }
attr_reader :user_agent
end
# Information about cardholder acceptance of Celtic [Authorized User Terms](https://stripe.com/docs/issuing/cards#accept-authorized-user-terms). Required for cards backed by a Celtic program.
sig { returns(T.nilable(UserTermsAcceptance)) }
attr_reader :user_terms_acceptance
end
class Dob < Stripe::StripeObject
# The day of birth, between 1 and 31.
sig { returns(T.nilable(Integer)) }
attr_reader :day
# The month of birth, between 1 and 12.
sig { returns(T.nilable(Integer)) }
attr_reader :month
# The four-digit year of birth.
sig { returns(T.nilable(Integer)) }
attr_reader :year
end
class Verification < Stripe::StripeObject
class Document < Stripe::StripeObject
# The back of a document returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`.
sig { returns(T.nilable(T.any(String, Stripe::File))) }
attr_reader :back
# The front of a document returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`.
sig { returns(T.nilable(T.any(String, Stripe::File))) }
attr_reader :front
end
# An identifying document, either a passport or local ID card.
sig { returns(T.nilable(Document)) }
attr_reader :document
end
# Information related to the card_issuing program for this cardholder.
sig { returns(T.nilable(CardIssuing)) }
attr_reader :card_issuing
# The date of birth of this cardholder.
sig { returns(T.nilable(Dob)) }
attr_reader :dob
# The first name of this cardholder. Required before activating Cards. This field cannot contain any numbers, special characters (except periods, commas, hyphens, spaces and apostrophes) or non-latin letters.
sig { returns(T.nilable(String)) }
attr_reader :first_name
# The last name of this cardholder. Required before activating Cards. This field cannot contain any numbers, special characters (except periods, commas, hyphens, spaces and apostrophes) or non-latin letters.
sig { returns(T.nilable(String)) }
attr_reader :last_name
# Government-issued ID document for this cardholder.
sig { returns(T.nilable(Verification)) }
attr_reader :verification
end
class Requirements < Stripe::StripeObject
# If `disabled_reason` is present, all cards will decline authorizations with `cardholder_verification_required` reason.
sig { returns(T.nilable(String)) }
attr_reader :disabled_reason
# Array of fields that need to be collected in order to verify and re-enable the cardholder.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :past_due
end
class SpendingControls < Stripe::StripeObject
class SpendingLimit < Stripe::StripeObject
# Maximum amount allowed to spend per interval. This amount is in the card's currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(Integer) }
attr_reader :amount
# Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) this limit applies to. Omitting this field will apply the limit to all categories.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :categories
# Interval (or event) to which the amount applies.
sig { returns(String) }
attr_reader :interval
end
# Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to allow. All other categories will be blocked. Cannot be set with `blocked_categories`.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :allowed_categories
# Array of strings containing representing countries from which authorizations will be allowed. Authorizations from merchants in all other countries will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `blocked_merchant_countries`. Provide an empty value to unset this control.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :allowed_merchant_countries
# Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to decline. All other categories will be allowed. Cannot be set with `allowed_categories`.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :blocked_categories
# Array of strings containing representing countries from which authorizations will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `allowed_merchant_countries`. Provide an empty value to unset this control.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :blocked_merchant_countries
# Limit spending with amount-based rules that apply across this cardholder's cards.
sig { returns(T.nilable(T::Array[SpendingLimit])) }
attr_reader :spending_limits
# Currency of the amounts within `spending_limits`.
sig { returns(T.nilable(String)) }
attr_reader :spending_limits_currency
end
# Attribute for field billing
sig { returns(Billing) }
attr_reader :billing
# Additional information about a `company` cardholder.
sig { returns(T.nilable(Company)) }
attr_reader :company
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# The cardholder's email address.
sig { returns(T.nilable(String)) }
attr_reader :email
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Additional information about an `individual` cardholder.
sig { returns(T.nilable(Individual)) }
attr_reader :individual
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# 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.
sig { returns(T::Hash[String, String]) }
attr_reader :metadata
# The cardholder's name. This will be printed on cards issued to them.
sig { returns(String) }
attr_reader :name
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :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.
sig { returns(T.nilable(String)) }
attr_reader :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.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :preferred_locales
# Attribute for field requirements
sig { returns(Requirements) }
attr_reader :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.
sig { returns(T.nilable(SpendingControls)) }
attr_reader :spending_controls
# Specifies whether to permit authorizations on this cardholder's cards.
sig { returns(String) }
attr_reader :status
# One of `individual` or `company`. See [Choose a cardholder type](https://stripe.com/docs/issuing/other/choose-cardholder) for more details.
sig { returns(String) }
attr_reader :type
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return cardholders that were created during the given date interval.
sig {
returns(T.nilable(T.any(::Stripe::Issuing::Cardholder::ListParams::Created, Integer)))
}
attr_accessor :created
# Only return cardholders that have the given email address.
sig { returns(T.nilable(String)) }
attr_accessor :email
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Only return cardholders that have the given phone number.
sig { returns(T.nilable(String)) }
attr_accessor :phone_number
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return cardholders that have the given status. One of `active`, `inactive`, or `blocked`.
sig { returns(T.nilable(String)) }
attr_accessor :status
# Only return cardholders that have the given type. One of `individual` or `company`.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(created: T.nilable(T.any(::Stripe::Issuing::Cardholder::ListParams::Created, Integer)), email: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), phone_number: T.nilable(String), starting_after: T.nilable(String), status: T.nilable(String), type: T.nilable(String)).void
}
def initialize(
created: nil,
email: nil,
ending_before: nil,
expand: nil,
limit: nil,
phone_number: nil,
starting_after: nil,
status: nil,
type: nil
); end
end
class CreateParams < Stripe::RequestParams
class Billing < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(String) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(String) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(String) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(String) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: String, country: String, line1: String, line2: T.nilable(String), postal_code: String, state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# The cardholder’s billing address.
sig { returns(::Stripe::Issuing::Cardholder::CreateParams::Billing::Address) }
attr_accessor :address
sig {
params(address: ::Stripe::Issuing::Cardholder::CreateParams::Billing::Address).void
}
def initialize(address: nil); end
end
class Company < Stripe::RequestParams
# The entity's business ID number.
sig { returns(T.nilable(String)) }
attr_accessor :tax_id
sig { params(tax_id: T.nilable(String)).void }
def initialize(tax_id: nil); end
end
class Individual < Stripe::RequestParams
class CardIssuing < Stripe::RequestParams
class UserTermsAcceptance < Stripe::RequestParams
# The Unix timestamp marking when the cardholder accepted the Authorized User Terms. Required for Celtic Spend Card users.
sig { returns(T.nilable(Integer)) }
attr_accessor :date
# The IP address from which the cardholder accepted the Authorized User Terms. Required for Celtic Spend Card users.
sig { returns(T.nilable(String)) }
attr_accessor :ip
# The user agent of the browser from which the cardholder accepted the Authorized User Terms.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :user_agent
sig {
params(date: T.nilable(Integer), ip: T.nilable(String), user_agent: T.nilable(T.nilable(String))).void
}
def initialize(date: nil, ip: nil, user_agent: nil); end
end
# Information about cardholder acceptance of Celtic [Authorized User Terms](https://stripe.com/docs/issuing/cards#accept-authorized-user-terms). Required for cards backed by a Celtic program.
sig {
returns(T.nilable(::Stripe::Issuing::Cardholder::CreateParams::Individual::CardIssuing::UserTermsAcceptance))
}
attr_accessor :user_terms_acceptance
sig {
params(user_terms_acceptance: T.nilable(::Stripe::Issuing::Cardholder::CreateParams::Individual::CardIssuing::UserTermsAcceptance)).void
}
def initialize(user_terms_acceptance: nil); end
end
class Dob < Stripe::RequestParams
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
class Verification < Stripe::RequestParams
class Document < Stripe::RequestParams
# The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`.
sig { returns(T.nilable(String)) }
attr_accessor :back
# The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`.
sig { returns(T.nilable(String)) }
attr_accessor :front
sig { params(back: T.nilable(String), front: T.nilable(String)).void }
def initialize(back: nil, front: nil); end
end
# An identifying document, either a passport or local ID card.
sig {
returns(T.nilable(::Stripe::Issuing::Cardholder::CreateParams::Individual::Verification::Document))
}
attr_accessor :document
sig {
params(document: T.nilable(::Stripe::Issuing::Cardholder::CreateParams::Individual::Verification::Document)).void
}
def initialize(document: nil); end
end
# Information related to the card_issuing program for this cardholder.
sig {
returns(T.nilable(::Stripe::Issuing::Cardholder::CreateParams::Individual::CardIssuing))
}
attr_accessor :card_issuing
# The date of birth of this cardholder. Cardholders must be older than 13 years old.
sig { returns(T.nilable(::Stripe::Issuing::Cardholder::CreateParams::Individual::Dob)) }
attr_accessor :dob
# The first name of this cardholder. Required before activating Cards. This field cannot contain any numbers, special characters (except periods, commas, hyphens, spaces and apostrophes) or non-latin letters.
sig { returns(T.nilable(String)) }
attr_accessor :first_name
# The last name of this cardholder. Required before activating Cards. This field cannot contain any numbers, special characters (except periods, commas, hyphens, spaces and apostrophes) or non-latin letters.
sig { returns(T.nilable(String)) }
attr_accessor :last_name
# Government-issued ID document for this cardholder.
sig {
returns(T.nilable(::Stripe::Issuing::Cardholder::CreateParams::Individual::Verification))
}
attr_accessor :verification
sig {
params(card_issuing: T.nilable(::Stripe::Issuing::Cardholder::CreateParams::Individual::CardIssuing), dob: T.nilable(::Stripe::Issuing::Cardholder::CreateParams::Individual::Dob), first_name: T.nilable(String), last_name: T.nilable(String), verification: T.nilable(::Stripe::Issuing::Cardholder::CreateParams::Individual::Verification)).void
}
def initialize(
card_issuing: nil,
dob: nil,
first_name: nil,
last_name: nil,
verification: nil
); end
end
class SpendingControls < Stripe::RequestParams
class SpendingLimit < Stripe::RequestParams
# Maximum amount allowed to spend per interval.
sig { returns(Integer) }
attr_accessor :amount
# Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) this limit applies to. Omitting this field will apply the limit to all categories.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :categories
# Interval (or event) to which the amount applies.
sig { returns(String) }
attr_accessor :interval
sig {
params(amount: Integer, categories: T.nilable(T::Array[String]), interval: String).void
}
def initialize(amount: nil, categories: nil, interval: nil); end
end
# Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to allow. All other categories will be blocked. Cannot be set with `blocked_categories`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :allowed_categories
# Array of strings containing representing countries from which authorizations will be allowed. Authorizations from merchants in all other countries will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `blocked_merchant_countries`. Provide an empty value to unset this control.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :allowed_merchant_countries
# Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to decline. All other categories will be allowed. Cannot be set with `allowed_categories`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :blocked_categories
# Array of strings containing representing countries from which authorizations will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `allowed_merchant_countries`. Provide an empty value to unset this control.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :blocked_merchant_countries
# Limit spending with amount-based rules that apply across this cardholder's cards.
sig {
returns(T.nilable(T::Array[::Stripe::Issuing::Cardholder::CreateParams::SpendingControls::SpendingLimit]))
}
attr_accessor :spending_limits
# Currency of amounts within `spending_limits`. Defaults to your merchant country's currency.
sig { returns(T.nilable(String)) }
attr_accessor :spending_limits_currency
sig {
params(allowed_categories: T.nilable(T::Array[String]), allowed_merchant_countries: T.nilable(T::Array[String]), blocked_categories: T.nilable(T::Array[String]), blocked_merchant_countries: T.nilable(T::Array[String]), spending_limits: T.nilable(T::Array[::Stripe::Issuing::Cardholder::CreateParams::SpendingControls::SpendingLimit]), spending_limits_currency: T.nilable(String)).void
}
def initialize(
allowed_categories: nil,
allowed_merchant_countries: nil,
blocked_categories: nil,
blocked_merchant_countries: nil,
spending_limits: nil,
spending_limits_currency: nil
); end
end
# The cardholder's billing address.
sig { returns(::Stripe::Issuing::Cardholder::CreateParams::Billing) }
attr_accessor :billing
# Additional information about a `company` cardholder.
sig { returns(T.nilable(::Stripe::Issuing::Cardholder::CreateParams::Company)) }
attr_accessor :company
# The cardholder's email address.
sig { returns(T.nilable(String)) }
attr_accessor :email
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Additional information about an `individual` cardholder.
sig { returns(T.nilable(::Stripe::Issuing::Cardholder::CreateParams::Individual)) }
attr_accessor :individual
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The cardholder's name. This will be printed on cards issued to them. The maximum length of this field is 24 characters. This field cannot contain any special characters or numbers.
sig { returns(String) }
attr_accessor :name
# The cardholder's phone number. This will be transformed to [E.164](https://en.wikipedia.org/wiki/E.164) if it is not provided in that format already. 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.
sig { returns(T.nilable(String)) }
attr_accessor :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.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :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.
sig { returns(T.nilable(::Stripe::Issuing::Cardholder::CreateParams::SpendingControls)) }
attr_accessor :spending_controls
# Specifies whether to permit authorizations on this cardholder's cards. Defaults to `active`.
sig { returns(T.nilable(String)) }
attr_accessor :status
# One of `individual` or `company`. See [Choose a cardholder type](https://stripe.com/docs/issuing/other/choose-cardholder) for more details.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(billing: ::Stripe::Issuing::Cardholder::CreateParams::Billing, company: T.nilable(::Stripe::Issuing::Cardholder::CreateParams::Company), email: T.nilable(String), expand: T.nilable(T::Array[String]), individual: T.nilable(::Stripe::Issuing::Cardholder::CreateParams::Individual), metadata: T.nilable(T::Hash[String, String]), name: String, phone_number: T.nilable(String), preferred_locales: T.nilable(T::Array[String]), spending_controls: T.nilable(::Stripe::Issuing::Cardholder::CreateParams::SpendingControls), status: T.nilable(String), type: T.nilable(String)).void
}
def initialize(
billing: nil,
company: nil,
email: nil,
expand: nil,
individual: nil,
metadata: nil,
name: nil,
phone_number: nil,
preferred_locales: nil,
spending_controls: nil,
status: nil,
type: nil
); end
end
class UpdateParams < Stripe::RequestParams
class Billing < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(String) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(String) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(String) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(String) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: String, country: String, line1: String, line2: T.nilable(String), postal_code: String, state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# The cardholder’s billing address.
sig { returns(::Stripe::Issuing::Cardholder::UpdateParams::Billing::Address) }
attr_accessor :address
sig {
params(address: ::Stripe::Issuing::Cardholder::UpdateParams::Billing::Address).void
}
def initialize(address: nil); end
end
class Company < Stripe::RequestParams
# The entity's business ID number.
sig { returns(T.nilable(String)) }
attr_accessor :tax_id
sig { params(tax_id: T.nilable(String)).void }
def initialize(tax_id: nil); end
end
class Individual < Stripe::RequestParams
class CardIssuing < Stripe::RequestParams
class UserTermsAcceptance < Stripe::RequestParams
# The Unix timestamp marking when the cardholder accepted the Authorized User Terms. Required for Celtic Spend Card users.
sig { returns(T.nilable(Integer)) }
attr_accessor :date
# The IP address from which the cardholder accepted the Authorized User Terms. Required for Celtic Spend Card users.
sig { returns(T.nilable(String)) }
attr_accessor :ip
# The user agent of the browser from which the cardholder accepted the Authorized User Terms.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :user_agent
sig {
params(date: T.nilable(Integer), ip: T.nilable(String), user_agent: T.nilable(T.nilable(String))).void
}
def initialize(date: nil, ip: nil, user_agent: nil); end
end
# Information about cardholder acceptance of Celtic [Authorized User Terms](https://stripe.com/docs/issuing/cards#accept-authorized-user-terms). Required for cards backed by a Celtic program.
sig {
returns(T.nilable(::Stripe::Issuing::Cardholder::UpdateParams::Individual::CardIssuing::UserTermsAcceptance))
}
attr_accessor :user_terms_acceptance
sig {
params(user_terms_acceptance: T.nilable(::Stripe::Issuing::Cardholder::UpdateParams::Individual::CardIssuing::UserTermsAcceptance)).void
}
def initialize(user_terms_acceptance: nil); end
end
class Dob < Stripe::RequestParams
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
class Verification < Stripe::RequestParams
class Document < Stripe::RequestParams
# The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`.
sig { returns(T.nilable(String)) }
attr_accessor :back
# The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`.
sig { returns(T.nilable(String)) }
attr_accessor :front
sig { params(back: T.nilable(String), front: T.nilable(String)).void }
def initialize(back: nil, front: nil); end
end
# An identifying document, either a passport or local ID card.
sig {
returns(T.nilable(::Stripe::Issuing::Cardholder::UpdateParams::Individual::Verification::Document))
}
attr_accessor :document
sig {
params(document: T.nilable(::Stripe::Issuing::Cardholder::UpdateParams::Individual::Verification::Document)).void
}
def initialize(document: nil); end
end
# Information related to the card_issuing program for this cardholder.
sig {
returns(T.nilable(::Stripe::Issuing::Cardholder::UpdateParams::Individual::CardIssuing))
}
attr_accessor :card_issuing
# The date of birth of this cardholder. Cardholders must be older than 13 years old.
sig { returns(T.nilable(::Stripe::Issuing::Cardholder::UpdateParams::Individual::Dob)) }
attr_accessor :dob
# The first name of this cardholder. Required before activating Cards. This field cannot contain any numbers, special characters (except periods, commas, hyphens, spaces and apostrophes) or non-latin letters.
sig { returns(T.nilable(String)) }
attr_accessor :first_name
# The last name of this cardholder. Required before activating Cards. This field cannot contain any numbers, special characters (except periods, commas, hyphens, spaces and apostrophes) or non-latin letters.
sig { returns(T.nilable(String)) }
attr_accessor :last_name
# Government-issued ID document for this cardholder.
sig {
returns(T.nilable(::Stripe::Issuing::Cardholder::UpdateParams::Individual::Verification))
}
attr_accessor :verification
sig {
params(card_issuing: T.nilable(::Stripe::Issuing::Cardholder::UpdateParams::Individual::CardIssuing), dob: T.nilable(::Stripe::Issuing::Cardholder::UpdateParams::Individual::Dob), first_name: T.nilable(String), last_name: T.nilable(String), verification: T.nilable(::Stripe::Issuing::Cardholder::UpdateParams::Individual::Verification)).void
}
def initialize(
card_issuing: nil,
dob: nil,
first_name: nil,
last_name: nil,
verification: nil
); end
end
class SpendingControls < Stripe::RequestParams
class SpendingLimit < Stripe::RequestParams
# Maximum amount allowed to spend per interval.
sig { returns(Integer) }
attr_accessor :amount
# Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) this limit applies to. Omitting this field will apply the limit to all categories.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :categories
# Interval (or event) to which the amount applies.
sig { returns(String) }
attr_accessor :interval
sig {
params(amount: Integer, categories: T.nilable(T::Array[String]), interval: String).void
}
def initialize(amount: nil, categories: nil, interval: nil); end
end
# Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to allow. All other categories will be blocked. Cannot be set with `blocked_categories`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :allowed_categories
# Array of strings containing representing countries from which authorizations will be allowed. Authorizations from merchants in all other countries will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `blocked_merchant_countries`. Provide an empty value to unset this control.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :allowed_merchant_countries
# Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to decline. All other categories will be allowed. Cannot be set with `allowed_categories`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :blocked_categories
# Array of strings containing representing countries from which authorizations will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `allowed_merchant_countries`. Provide an empty value to unset this control.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :blocked_merchant_countries
# Limit spending with amount-based rules that apply across this cardholder's cards.
sig {
returns(T.nilable(T::Array[::Stripe::Issuing::Cardholder::UpdateParams::SpendingControls::SpendingLimit]))
}
attr_accessor :spending_limits
# Currency of amounts within `spending_limits`. Defaults to your merchant country's currency.
sig { returns(T.nilable(String)) }
attr_accessor :spending_limits_currency
sig {
params(allowed_categories: T.nilable(T::Array[String]), allowed_merchant_countries: T.nilable(T::Array[String]), blocked_categories: T.nilable(T::Array[String]), blocked_merchant_countries: T.nilable(T::Array[String]), spending_limits: T.nilable(T::Array[::Stripe::Issuing::Cardholder::UpdateParams::SpendingControls::SpendingLimit]), spending_limits_currency: T.nilable(String)).void
}
def initialize(
allowed_categories: nil,
allowed_merchant_countries: nil,
blocked_categories: nil,
blocked_merchant_countries: nil,
spending_limits: nil,
spending_limits_currency: nil
); end
end
# The cardholder's billing address.
sig { returns(T.nilable(::Stripe::Issuing::Cardholder::UpdateParams::Billing)) }
attr_accessor :billing
# Additional information about a `company` cardholder.
sig { returns(T.nilable(::Stripe::Issuing::Cardholder::UpdateParams::Company)) }
attr_accessor :company
# The cardholder's email address.
sig { returns(T.nilable(String)) }
attr_accessor :email
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Additional information about an `individual` cardholder.
sig { returns(T.nilable(::Stripe::Issuing::Cardholder::UpdateParams::Individual)) }
attr_accessor :individual
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# 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) for more details.
sig { returns(T.nilable(String)) }
attr_accessor :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.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :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.
sig { returns(T.nilable(::Stripe::Issuing::Cardholder::UpdateParams::SpendingControls)) }
attr_accessor :spending_controls
# Specifies whether to permit authorizations on this cardholder's cards.
sig { returns(T.nilable(String)) }
attr_accessor :status
sig {
params(billing: T.nilable(::Stripe::Issuing::Cardholder::UpdateParams::Billing), company: T.nilable(::Stripe::Issuing::Cardholder::UpdateParams::Company), email: T.nilable(String), expand: T.nilable(T::Array[String]), individual: T.nilable(::Stripe::Issuing::Cardholder::UpdateParams::Individual), metadata: T.nilable(T::Hash[String, String]), phone_number: T.nilable(String), preferred_locales: T.nilable(T::Array[String]), spending_controls: T.nilable(::Stripe::Issuing::Cardholder::UpdateParams::SpendingControls), status: T.nilable(String)).void
}
def initialize(
billing: nil,
company: nil,
email: nil,
expand: nil,
individual: nil,
metadata: nil,
phone_number: nil,
preferred_locales: nil,
spending_controls: nil,
status: nil
); end
end
# Creates a new Issuing Cardholder object that can be issued cards.
sig {
params(params: T.any(::Stripe::Issuing::Cardholder::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Cardholder)
}
def self.create(params = {}, opts = {}); end
# Returns a list of Issuing Cardholder objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.
sig {
params(params: T.any(::Stripe::Issuing::Cardholder::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Updates the specified Issuing Cardholder object by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
sig {
params(cardholder: String, params: T.any(::Stripe::Issuing::Cardholder::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Cardholder)
}
def self.update(cardholder, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Issuing
# Every time an applicant submits an application for a Charge Card product your platform offers, or every time your platform takes a proactive credit decision on an existing account, you must record the decision by creating a new `CreditUnderwritingRecord` object on a connected account.
#
# [Follow the guide](https://stripe.com/docs/issuing/credit/report-credit-decisions-and-manage-aans) to learn about your requirements as a platform.
class CreditUnderwritingRecord < APIResource
class Application < Stripe::StripeObject
# The channel through which the applicant has submitted their application.
sig { returns(String) }
attr_reader :application_method
# Scope of demand made by the applicant.
sig { returns(String) }
attr_reader :purpose
# Date when the applicant submitted their application.
sig { returns(Integer) }
attr_reader :submitted_at
end
class CreditUser < Stripe::StripeObject
# Email of the applicant or accountholder.
sig { returns(String) }
attr_reader :email
# Full name of the company or person.
sig { returns(String) }
attr_reader :name
end
class Decision < Stripe::StripeObject
class ApplicationRejected < Stripe::StripeObject
# Details about the `reasons.other` when present.
sig { returns(T.nilable(String)) }
attr_reader :reason_other_explanation
# List of reasons why the application was rejected up to 4 reasons, in order of importance.
sig { returns(T::Array[String]) }
attr_reader :reasons
end
class CreditLimitApproved < Stripe::StripeObject
# Credit amount approved. An approved credit limit is required before you can set a amount in the [CreditPolicy API](https://stripe.com/docs/api/issuing/credit_policy).
sig { returns(Integer) }
attr_reader :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).
sig { returns(String) }
attr_reader :currency
end
class CreditLimitDecreased < Stripe::StripeObject
# Credit amount approved after decrease. An approved credit limit is required before you can set a amount in the [CreditPolicy API](https://stripe.com/docs/api/issuing/credit_policy).
sig { returns(Integer) }
attr_reader :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).
sig { returns(String) }
attr_reader :currency
# Details about the `reasons.other` when present.
sig { returns(T.nilable(String)) }
attr_reader :reason_other_explanation
# List of reasons why the existing credit was decreased, up to 4 reasons, in order of importance.
sig { returns(T::Array[String]) }
attr_reader :reasons
end
class CreditLineClosed < Stripe::StripeObject
# Details about the `reasons.other` when present.
sig { returns(T.nilable(String)) }
attr_reader :reason_other_explanation
# List of reasons why the existing account was closed, up to 4 reasons, in order of importance.
sig { returns(T::Array[String]) }
attr_reader :reasons
end
# Details about a decision application_rejected.
sig { returns(T.nilable(ApplicationRejected)) }
attr_reader :application_rejected
# Details about a decision credit_limit_approved.
sig { returns(T.nilable(CreditLimitApproved)) }
attr_reader :credit_limit_approved
# Details about a decision credit_limit_decreased.
sig { returns(T.nilable(CreditLimitDecreased)) }
attr_reader :credit_limit_decreased
# Details about a decision credit_line_closed.
sig { returns(T.nilable(CreditLineClosed)) }
attr_reader :credit_line_closed
# Outcome of the decision.
sig { returns(String) }
attr_reader :type
end
class UnderwritingException < Stripe::StripeObject
# Written explanation for the exception.
sig { returns(String) }
attr_reader :explanation
# The decision before the exception was applied.
sig { returns(String) }
attr_reader :original_decision_type
end
# For decisions triggered by an application, details about the submission.
sig { returns(T.nilable(Application)) }
attr_reader :application
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# The event that triggered the underwriting.
sig { returns(String) }
attr_reader :created_from
# Attribute for field credit_user
sig { returns(CreditUser) }
attr_reader :credit_user
# Date when a decision was made.
sig { returns(T.nilable(Integer)) }
attr_reader :decided_at
# Details about the decision.
sig { returns(T.nilable(Decision)) }
attr_reader :decision
# For underwriting initiated by an application, a decision must be taken 30 days after the submission.
sig { returns(T.nilable(Integer)) }
attr_reader :decision_deadline
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# 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.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# File containing regulatory reporting data for the decision. Required if you are subject to this [reporting requirement](https://stripe.com/docs/issuing/credit/report-required-regulatory-data-for-credit-decisions).
sig { returns(T.nilable(String)) }
attr_reader :regulatory_reporting_file
# If an exception to the usual underwriting criteria was made for this application, details about the exception must be provided. Exceptions should only be granted in rare circumstances, in consultation with Stripe Compliance.
sig { returns(T.nilable(UnderwritingException)) }
attr_reader :underwriting_exception
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
class CorrectParams < Stripe::RequestParams
class Application < Stripe::RequestParams
# The channel through which the applicant has submitted their application. Defaults to `online`.
sig { returns(T.nilable(String)) }
attr_accessor :application_method
# Scope of demand made by the applicant.
sig { returns(String) }
attr_accessor :purpose
# Date when the applicant submitted their application.
sig { returns(Integer) }
attr_accessor :submitted_at
sig {
params(application_method: T.nilable(String), purpose: String, submitted_at: Integer).void
}
def initialize(application_method: nil, purpose: nil, submitted_at: nil); end
end
class CreditUser < Stripe::RequestParams
# Email of the applicant or accountholder.
sig { returns(String) }
attr_accessor :email
# Full name of the company or person.
sig { returns(String) }
attr_accessor :name
sig { params(email: String, name: String).void }
def initialize(email: nil, name: nil); end
end
class Decision < Stripe::RequestParams
class ApplicationRejected < Stripe::RequestParams
# Details about the `reasons.other` when present.
sig { returns(T.nilable(String)) }
attr_accessor :reason_other_explanation
# List of reasons why the application was rejected, up to 4 reasons, in order of importance.
sig { returns(T::Array[String]) }
attr_accessor :reasons
sig {
params(reason_other_explanation: T.nilable(String), reasons: T::Array[String]).void
}
def initialize(reason_other_explanation: nil, reasons: nil); end
end
class CreditLimitApproved < Stripe::RequestParams
# The credit approved, in the currency of the account and [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(Integer) }
attr_accessor :amount
# The currency of the credit approved, will default to the Account's Issuing currency.
sig { returns(T.nilable(String)) }
attr_accessor :currency
sig { params(amount: Integer, currency: T.nilable(String)).void }
def initialize(amount: nil, currency: nil); end
end
class CreditLimitDecreased < Stripe::RequestParams
# The credit approved, in the currency of the account and [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(Integer) }
attr_accessor :amount
# The currency of the credit approved, will default to the Account's Issuing currency.
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Details about the `reasons.other` when present.
sig { returns(T.nilable(String)) }
attr_accessor :reason_other_explanation
# List of reasons why the existing credit was decreased, up to 4 reasons, in order of importance.
sig { returns(T::Array[String]) }
attr_accessor :reasons
sig {
params(amount: Integer, currency: T.nilable(String), reason_other_explanation: T.nilable(String), reasons: T::Array[String]).void
}
def initialize(
amount: nil,
currency: nil,
reason_other_explanation: nil,
reasons: nil
); end
end
class CreditLineClosed < Stripe::RequestParams
# Details about the `reasons.other` when present.
sig { returns(T.nilable(String)) }
attr_accessor :reason_other_explanation
# List of reasons why the credit line was closed, up to 4 reasons, in order of importance.
sig { returns(T::Array[String]) }
attr_accessor :reasons
sig {
params(reason_other_explanation: T.nilable(String), reasons: T::Array[String]).void
}
def initialize(reason_other_explanation: nil, reasons: nil); end
end
# Details about the application rejection.
sig {
returns(T.nilable(::Stripe::Issuing::CreditUnderwritingRecord::CorrectParams::Decision::ApplicationRejected))
}
attr_accessor :application_rejected
# Details about the credit limit approved. An approved credit limit is required before you can set a `credit_limit_amount` in the [CreditPolicy API](https://stripe.com/docs/api/issuing/credit_policy/)
sig {
returns(T.nilable(::Stripe::Issuing::CreditUnderwritingRecord::CorrectParams::Decision::CreditLimitApproved))
}
attr_accessor :credit_limit_approved
# Details about the credit limit decreased.
sig {
returns(T.nilable(::Stripe::Issuing::CreditUnderwritingRecord::CorrectParams::Decision::CreditLimitDecreased))
}
attr_accessor :credit_limit_decreased
# Details about the credit line closed.
sig {
returns(T.nilable(::Stripe::Issuing::CreditUnderwritingRecord::CorrectParams::Decision::CreditLineClosed))
}
attr_accessor :credit_line_closed
# Outcome of the decision.
sig { returns(String) }
attr_accessor :type
sig {
params(application_rejected: T.nilable(::Stripe::Issuing::CreditUnderwritingRecord::CorrectParams::Decision::ApplicationRejected), credit_limit_approved: T.nilable(::Stripe::Issuing::CreditUnderwritingRecord::CorrectParams::Decision::CreditLimitApproved), credit_limit_decreased: T.nilable(::Stripe::Issuing::CreditUnderwritingRecord::CorrectParams::Decision::CreditLimitDecreased), credit_line_closed: T.nilable(::Stripe::Issuing::CreditUnderwritingRecord::CorrectParams::Decision::CreditLineClosed), type: String).void
}
def initialize(
application_rejected: nil,
credit_limit_approved: nil,
credit_limit_decreased: nil,
credit_line_closed: nil,
type: nil
); end
end
class UnderwritingException < Stripe::RequestParams
# Written explanation for the exception.
sig { returns(String) }
attr_accessor :explanation
# The decision before the exception was applied.
sig { returns(String) }
attr_accessor :original_decision_type
sig { params(explanation: String, original_decision_type: String).void }
def initialize(explanation: nil, original_decision_type: nil); end
end
# Details about the application submission.
sig {
returns(T.nilable(::Stripe::Issuing::CreditUnderwritingRecord::CorrectParams::Application))
}
attr_accessor :application
# Information about the company or person applying or holding the account.
sig {
returns(T.nilable(::Stripe::Issuing::CreditUnderwritingRecord::CorrectParams::CreditUser))
}
attr_accessor :credit_user
# Date when a decision was made.
sig { returns(T.nilable(Integer)) }
attr_accessor :decided_at
# Details about the decision.
sig {
returns(T.nilable(::Stripe::Issuing::CreditUnderwritingRecord::CorrectParams::Decision))
}
attr_accessor :decision
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# File containing regulatory reporting data for the decision. Required if you are subject to this [reporting requirement](https://stripe.com/docs/issuing/credit/report-required-regulatory-data-for-credit-decisions). Optional if previously provided and no changes are needed.
sig { returns(T.nilable(String)) }
attr_accessor :regulatory_reporting_file
# If an exception to the usual underwriting criteria was made for this decision, details about the exception must be provided. Exceptions should only be granted in rare circumstances, in consultation with Stripe Compliance.
sig {
returns(T.nilable(::Stripe::Issuing::CreditUnderwritingRecord::CorrectParams::UnderwritingException))
}
attr_accessor :underwriting_exception
sig {
params(application: T.nilable(::Stripe::Issuing::CreditUnderwritingRecord::CorrectParams::Application), credit_user: T.nilable(::Stripe::Issuing::CreditUnderwritingRecord::CorrectParams::CreditUser), decided_at: T.nilable(Integer), decision: T.nilable(::Stripe::Issuing::CreditUnderwritingRecord::CorrectParams::Decision), expand: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), regulatory_reporting_file: T.nilable(String), underwriting_exception: T.nilable(::Stripe::Issuing::CreditUnderwritingRecord::CorrectParams::UnderwritingException)).void
}
def initialize(
application: nil,
credit_user: nil,
decided_at: nil,
decision: nil,
expand: nil,
metadata: nil,
regulatory_reporting_file: nil,
underwriting_exception: nil
); end
end
class ReportDecisionParams < Stripe::RequestParams
class Decision < Stripe::RequestParams
class ApplicationRejected < Stripe::RequestParams
# Details about the `reasons.other` when present.
sig { returns(T.nilable(String)) }
attr_accessor :reason_other_explanation
# List of reasons why the application was rejected, up to 4 reasons, in order of importance.
sig { returns(T::Array[String]) }
attr_accessor :reasons
sig {
params(reason_other_explanation: T.nilable(String), reasons: T::Array[String]).void
}
def initialize(reason_other_explanation: nil, reasons: nil); end
end
class CreditLimitApproved < Stripe::RequestParams
# The credit approved, in the currency of the account and [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(Integer) }
attr_accessor :amount
# The currency of the credit approved, will default to the Account's Issuing currency.
sig { returns(T.nilable(String)) }
attr_accessor :currency
sig { params(amount: Integer, currency: T.nilable(String)).void }
def initialize(amount: nil, currency: nil); end
end
# Details about the application rejection.
sig {
returns(T.nilable(::Stripe::Issuing::CreditUnderwritingRecord::ReportDecisionParams::Decision::ApplicationRejected))
}
attr_accessor :application_rejected
# Details about the credit limit approved. An approved credit limit is required before you can set a `credit_limit_amount` in the [CreditPolicy API](https://stripe.com/docs/api/issuing/credit_policy/)
sig {
returns(T.nilable(::Stripe::Issuing::CreditUnderwritingRecord::ReportDecisionParams::Decision::CreditLimitApproved))
}
attr_accessor :credit_limit_approved
# Outcome of the decision.
sig { returns(String) }
attr_accessor :type
sig {
params(application_rejected: T.nilable(::Stripe::Issuing::CreditUnderwritingRecord::ReportDecisionParams::Decision::ApplicationRejected), credit_limit_approved: T.nilable(::Stripe::Issuing::CreditUnderwritingRecord::ReportDecisionParams::Decision::CreditLimitApproved), type: String).void
}
def initialize(application_rejected: nil, credit_limit_approved: nil, type: nil); end
end
class UnderwritingException < Stripe::RequestParams
# Written explanation for the exception.
sig { returns(String) }
attr_accessor :explanation
# The decision before the exception was applied.
sig { returns(String) }
attr_accessor :original_decision_type
sig { params(explanation: String, original_decision_type: String).void }
def initialize(explanation: nil, original_decision_type: nil); end
end
# Date when a decision was made.
sig { returns(Integer) }
attr_accessor :decided_at
# Details about the decision.
sig { returns(::Stripe::Issuing::CreditUnderwritingRecord::ReportDecisionParams::Decision) }
attr_accessor :decision
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# File containing regulatory reporting data for the decision. Required if you are subject to this [reporting requirement](https://stripe.com/docs/issuing/credit/report-required-regulatory-data-for-credit-decisions).
sig { returns(T.nilable(String)) }
attr_accessor :regulatory_reporting_file
# If an exception to the usual underwriting criteria was made for this decision, details about the exception must be provided. Exceptions should only be granted in rare circumstances, in consultation with Stripe Compliance.
sig {
returns(T.nilable(::Stripe::Issuing::CreditUnderwritingRecord::ReportDecisionParams::UnderwritingException))
}
attr_accessor :underwriting_exception
sig {
params(decided_at: Integer, decision: ::Stripe::Issuing::CreditUnderwritingRecord::ReportDecisionParams::Decision, expand: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), regulatory_reporting_file: T.nilable(String), underwriting_exception: T.nilable(::Stripe::Issuing::CreditUnderwritingRecord::ReportDecisionParams::UnderwritingException)).void
}
def initialize(
decided_at: nil,
decision: nil,
expand: nil,
metadata: nil,
regulatory_reporting_file: nil,
underwriting_exception: nil
); end
end
class CreateFromApplicationParams < Stripe::RequestParams
class Application < Stripe::RequestParams
# The channel through which the applicant has submitted their application. Defaults to `online`.
sig { returns(T.nilable(String)) }
attr_accessor :application_method
# Scope of demand made by the applicant.
sig { returns(String) }
attr_accessor :purpose
# Date when the applicant submitted their application.
sig { returns(Integer) }
attr_accessor :submitted_at
sig {
params(application_method: T.nilable(String), purpose: String, submitted_at: Integer).void
}
def initialize(application_method: nil, purpose: nil, submitted_at: nil); end
end
class CreditUser < Stripe::RequestParams
# Email of the applicant or accountholder.
sig { returns(String) }
attr_accessor :email
# Full name of the company or person.
sig { returns(String) }
attr_accessor :name
sig { params(email: String, name: String).void }
def initialize(email: nil, name: nil); end
end
# Details about the application submission.
sig {
returns(::Stripe::Issuing::CreditUnderwritingRecord::CreateFromApplicationParams::Application)
}
attr_accessor :application
# Information about the company or person applying or holding the account.
sig {
returns(::Stripe::Issuing::CreditUnderwritingRecord::CreateFromApplicationParams::CreditUser)
}
attr_accessor :credit_user
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
sig {
params(application: ::Stripe::Issuing::CreditUnderwritingRecord::CreateFromApplicationParams::Application, credit_user: ::Stripe::Issuing::CreditUnderwritingRecord::CreateFromApplicationParams::CreditUser, expand: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String])).void
}
def initialize(application: nil, credit_user: nil, expand: nil, metadata: nil); end
end
class CreateFromProactiveReviewParams < Stripe::RequestParams
class CreditUser < Stripe::RequestParams
# Email of the applicant or accountholder.
sig { returns(String) }
attr_accessor :email
# Full name of the company or person.
sig { returns(String) }
attr_accessor :name
sig { params(email: String, name: String).void }
def initialize(email: nil, name: nil); end
end
class Decision < Stripe::RequestParams
class CreditLimitApproved < Stripe::RequestParams
# The credit approved, in the currency of the account and [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(Integer) }
attr_accessor :amount
# The currency of the credit approved, will default to the Account's Issuing currency.
sig { returns(T.nilable(String)) }
attr_accessor :currency
sig { params(amount: Integer, currency: T.nilable(String)).void }
def initialize(amount: nil, currency: nil); end
end
class CreditLimitDecreased < Stripe::RequestParams
# The credit approved, in the currency of the account and [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(Integer) }
attr_accessor :amount
# The currency of the credit approved, will default to the Account's Issuing currency.
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Details about the `reasons.other` when present.
sig { returns(T.nilable(String)) }
attr_accessor :reason_other_explanation
# List of reasons why the existing credit was decreased, up to 4 reasons, in order of importance.
sig { returns(T::Array[String]) }
attr_accessor :reasons
sig {
params(amount: Integer, currency: T.nilable(String), reason_other_explanation: T.nilable(String), reasons: T::Array[String]).void
}
def initialize(
amount: nil,
currency: nil,
reason_other_explanation: nil,
reasons: nil
); end
end
class CreditLineClosed < Stripe::RequestParams
# Details about the `reasons.other` when present.
sig { returns(T.nilable(String)) }
attr_accessor :reason_other_explanation
# List of reasons why the credit line was closed, up to 4 reasons, in order of importance.
sig { returns(T::Array[String]) }
attr_accessor :reasons
sig {
params(reason_other_explanation: T.nilable(String), reasons: T::Array[String]).void
}
def initialize(reason_other_explanation: nil, reasons: nil); end
end
# Details about the credit limit approved. An approved credit limit is required before you can set a `credit_limit_amount` in the [CreditPolicy API](https://stripe.com/docs/api/issuing/credit_policy/)
sig {
returns(T.nilable(::Stripe::Issuing::CreditUnderwritingRecord::CreateFromProactiveReviewParams::Decision::CreditLimitApproved))
}
attr_accessor :credit_limit_approved
# Details about the credit limit decreased.
sig {
returns(T.nilable(::Stripe::Issuing::CreditUnderwritingRecord::CreateFromProactiveReviewParams::Decision::CreditLimitDecreased))
}
attr_accessor :credit_limit_decreased
# Details about the credit line closed.
sig {
returns(T.nilable(::Stripe::Issuing::CreditUnderwritingRecord::CreateFromProactiveReviewParams::Decision::CreditLineClosed))
}
attr_accessor :credit_line_closed
# Outcome of the decision.
sig { returns(String) }
attr_accessor :type
sig {
params(credit_limit_approved: T.nilable(::Stripe::Issuing::CreditUnderwritingRecord::CreateFromProactiveReviewParams::Decision::CreditLimitApproved), credit_limit_decreased: T.nilable(::Stripe::Issuing::CreditUnderwritingRecord::CreateFromProactiveReviewParams::Decision::CreditLimitDecreased), credit_line_closed: T.nilable(::Stripe::Issuing::CreditUnderwritingRecord::CreateFromProactiveReviewParams::Decision::CreditLineClosed), type: String).void
}
def initialize(
credit_limit_approved: nil,
credit_limit_decreased: nil,
credit_line_closed: nil,
type: nil
); end
end
class UnderwritingException < Stripe::RequestParams
# Written explanation for the exception.
sig { returns(String) }
attr_accessor :explanation
# The decision before the exception was applied.
sig { returns(String) }
attr_accessor :original_decision_type
sig { params(explanation: String, original_decision_type: String).void }
def initialize(explanation: nil, original_decision_type: nil); end
end
# Information about the company or person applying or holding the account.
sig {
returns(::Stripe::Issuing::CreditUnderwritingRecord::CreateFromProactiveReviewParams::CreditUser)
}
attr_accessor :credit_user
# Date when a decision was made.
sig { returns(Integer) }
attr_accessor :decided_at
# Details about the decision.
sig {
returns(::Stripe::Issuing::CreditUnderwritingRecord::CreateFromProactiveReviewParams::Decision)
}
attr_accessor :decision
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# File containing regulatory reporting data for the decision. Required if you are subject to this [reporting requirement](https://stripe.com/docs/issuing/credit/report-required-regulatory-data-for-credit-decisions).
sig { returns(T.nilable(String)) }
attr_accessor :regulatory_reporting_file
# If an exception to the usual underwriting criteria was made for this decision, details about the exception must be provided. Exceptions should only be granted in rare circumstances, in consultation with Stripe Compliance.
sig {
returns(T.nilable(::Stripe::Issuing::CreditUnderwritingRecord::CreateFromProactiveReviewParams::UnderwritingException))
}
attr_accessor :underwriting_exception
sig {
params(credit_user: ::Stripe::Issuing::CreditUnderwritingRecord::CreateFromProactiveReviewParams::CreditUser, decided_at: Integer, decision: ::Stripe::Issuing::CreditUnderwritingRecord::CreateFromProactiveReviewParams::Decision, expand: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), regulatory_reporting_file: T.nilable(String), underwriting_exception: T.nilable(::Stripe::Issuing::CreditUnderwritingRecord::CreateFromProactiveReviewParams::UnderwritingException)).void
}
def initialize(
credit_user: nil,
decided_at: nil,
decision: nil,
expand: nil,
metadata: nil,
regulatory_reporting_file: nil,
underwriting_exception: nil
); end
end
# Update a CreditUnderwritingRecord object to correct mistakes.
sig {
params(params: T.any(::Stripe::Issuing::CreditUnderwritingRecord::CorrectParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::CreditUnderwritingRecord)
}
def correct(params = {}, opts = {}); end
# Update a CreditUnderwritingRecord object to correct mistakes.
sig {
params(credit_underwriting_record: String, params: T.any(::Stripe::Issuing::CreditUnderwritingRecord::CorrectParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::CreditUnderwritingRecord)
}
def self.correct(credit_underwriting_record, params = {}, opts = {}); end
# Creates a CreditUnderwritingRecord object with information about a credit application submission.
sig {
params(params: T.any(::Stripe::Issuing::CreditUnderwritingRecord::CreateFromApplicationParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::CreditUnderwritingRecord)
}
def self.create_from_application(params = {}, opts = {}); end
# Creates a CreditUnderwritingRecord object from an underwriting decision coming from a proactive review of an existing accountholder.
sig {
params(params: T.any(::Stripe::Issuing::CreditUnderwritingRecord::CreateFromProactiveReviewParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::CreditUnderwritingRecord)
}
def self.create_from_proactive_review(params = {}, opts = {}); end
# Retrieves a list of CreditUnderwritingRecord objects. The objects are sorted in descending order by creation date, with the most-recently-created object appearing first.
sig {
params(params: T.any(::Stripe::Issuing::CreditUnderwritingRecord::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Update a CreditUnderwritingRecord object from a decision made on a credit application.
sig {
params(params: T.any(::Stripe::Issuing::CreditUnderwritingRecord::ReportDecisionParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::CreditUnderwritingRecord)
}
def report_decision(params = {}, opts = {}); end
# Update a CreditUnderwritingRecord object from a decision made on a credit application.
sig {
params(credit_underwriting_record: String, params: T.any(::Stripe::Issuing::CreditUnderwritingRecord::ReportDecisionParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::CreditUnderwritingRecord)
}
def self.report_decision(credit_underwriting_record, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Issuing
# As a [card issuer](https://stripe.com/docs/issuing), you can dispute transactions that the cardholder does not recognize, suspects to be fraudulent, or has other issues with.
#
# Related guide: [Issuing disputes](https://stripe.com/docs/issuing/purchases/disputes)
class Dispute < APIResource
class Evidence < Stripe::StripeObject
class Canceled < Stripe::StripeObject
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
sig { returns(T.nilable(T.any(String, Stripe::File))) }
attr_reader :additional_documentation
# Date when order was canceled.
sig { returns(T.nilable(Integer)) }
attr_reader :canceled_at
# Whether the cardholder was provided with a cancellation policy.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :cancellation_policy_provided
# Reason for canceling the order.
sig { returns(T.nilable(String)) }
attr_reader :cancellation_reason
# Date when the cardholder expected to receive the product.
sig { returns(T.nilable(Integer)) }
attr_reader :expected_at
# Explanation of why the cardholder is disputing this transaction.
sig { returns(T.nilable(String)) }
attr_reader :explanation
# Description of the merchandise or service that was purchased.
sig { returns(T.nilable(String)) }
attr_reader :product_description
# Whether the product was a merchandise or service.
sig { returns(T.nilable(String)) }
attr_reader :product_type
# Result of cardholder's attempt to return the product.
sig { returns(T.nilable(String)) }
attr_reader :return_status
# Date when the product was returned or attempted to be returned.
sig { returns(T.nilable(Integer)) }
attr_reader :returned_at
end
class Duplicate < Stripe::StripeObject
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
sig { returns(T.nilable(T.any(String, Stripe::File))) }
attr_reader :additional_documentation
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Copy of the card statement showing that the product had already been paid for.
sig { returns(T.nilable(T.any(String, Stripe::File))) }
attr_reader :card_statement
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Copy of the receipt showing that the product had been paid for in cash.
sig { returns(T.nilable(T.any(String, Stripe::File))) }
attr_reader :cash_receipt
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Image of the front and back of the check that was used to pay for the product.
sig { returns(T.nilable(T.any(String, Stripe::File))) }
attr_reader :check_image
# Explanation of why the cardholder is disputing this transaction.
sig { returns(T.nilable(String)) }
attr_reader :explanation
# Transaction (e.g., ipi_...) that the disputed transaction is a duplicate of. Of the two or more transactions that are copies of each other, this is original undisputed one.
sig { returns(T.nilable(String)) }
attr_reader :original_transaction
end
class Fraudulent < Stripe::StripeObject
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
sig { returns(T.nilable(T.any(String, Stripe::File))) }
attr_reader :additional_documentation
# Explanation of why the cardholder is disputing this transaction.
sig { returns(T.nilable(String)) }
attr_reader :explanation
end
class MerchandiseNotAsDescribed < Stripe::StripeObject
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
sig { returns(T.nilable(T.any(String, Stripe::File))) }
attr_reader :additional_documentation
# Explanation of why the cardholder is disputing this transaction.
sig { returns(T.nilable(String)) }
attr_reader :explanation
# Date when the product was received.
sig { returns(T.nilable(Integer)) }
attr_reader :received_at
# Description of the cardholder's attempt to return the product.
sig { returns(T.nilable(String)) }
attr_reader :return_description
# Result of cardholder's attempt to return the product.
sig { returns(T.nilable(String)) }
attr_reader :return_status
# Date when the product was returned or attempted to be returned.
sig { returns(T.nilable(Integer)) }
attr_reader :returned_at
end
class NoValidAuthorization < Stripe::StripeObject
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
sig { returns(T.nilable(T.any(String, Stripe::File))) }
attr_reader :additional_documentation
# Explanation of why the cardholder is disputing this transaction.
sig { returns(T.nilable(String)) }
attr_reader :explanation
end
class NotReceived < Stripe::StripeObject
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
sig { returns(T.nilable(T.any(String, Stripe::File))) }
attr_reader :additional_documentation
# Date when the cardholder expected to receive the product.
sig { returns(T.nilable(Integer)) }
attr_reader :expected_at
# Explanation of why the cardholder is disputing this transaction.
sig { returns(T.nilable(String)) }
attr_reader :explanation
# Description of the merchandise or service that was purchased.
sig { returns(T.nilable(String)) }
attr_reader :product_description
# Whether the product was a merchandise or service.
sig { returns(T.nilable(String)) }
attr_reader :product_type
end
class Other < Stripe::StripeObject
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
sig { returns(T.nilable(T.any(String, Stripe::File))) }
attr_reader :additional_documentation
# Explanation of why the cardholder is disputing this transaction.
sig { returns(T.nilable(String)) }
attr_reader :explanation
# Description of the merchandise or service that was purchased.
sig { returns(T.nilable(String)) }
attr_reader :product_description
# Whether the product was a merchandise or service.
sig { returns(T.nilable(String)) }
attr_reader :product_type
end
class ServiceNotAsDescribed < Stripe::StripeObject
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
sig { returns(T.nilable(T.any(String, Stripe::File))) }
attr_reader :additional_documentation
# Date when order was canceled.
sig { returns(T.nilable(Integer)) }
attr_reader :canceled_at
# Reason for canceling the order.
sig { returns(T.nilable(String)) }
attr_reader :cancellation_reason
# Explanation of why the cardholder is disputing this transaction.
sig { returns(T.nilable(String)) }
attr_reader :explanation
# Date when the product was received.
sig { returns(T.nilable(Integer)) }
attr_reader :received_at
end
# Attribute for field canceled
sig { returns(Canceled) }
attr_reader :canceled
# Attribute for field duplicate
sig { returns(Duplicate) }
attr_reader :duplicate
# Attribute for field fraudulent
sig { returns(Fraudulent) }
attr_reader :fraudulent
# Attribute for field merchandise_not_as_described
sig { returns(MerchandiseNotAsDescribed) }
attr_reader :merchandise_not_as_described
# Attribute for field no_valid_authorization
sig { returns(NoValidAuthorization) }
attr_reader :no_valid_authorization
# Attribute for field not_received
sig { returns(NotReceived) }
attr_reader :not_received
# Attribute for field other
sig { returns(Other) }
attr_reader :other
# The reason for filing the dispute. Its value will match the field containing the evidence.
sig { returns(String) }
attr_reader :reason
# Attribute for field service_not_as_described
sig { returns(ServiceNotAsDescribed) }
attr_reader :service_not_as_described
end
class Treasury < Stripe::StripeObject
# The Treasury [DebitReversal](https://stripe.com/docs/api/treasury/debit_reversals) representing this Issuing dispute
sig { returns(T.nilable(String)) }
attr_reader :debit_reversal
# The Treasury [ReceivedDebit](https://stripe.com/docs/api/treasury/received_debits) that is being disputed.
sig { returns(String) }
attr_reader :received_debit
end
# Disputed amount in the card's currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal). Usually the amount of the `transaction`, but can differ (usually because of currency fluctuation).
sig { returns(Integer) }
attr_reader :amount
# List of balance transactions associated with the dispute.
sig { returns(T.nilable(T::Array[Stripe::BalanceTransaction])) }
attr_reader :balance_transactions
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# The currency the `transaction` was made in.
sig { returns(String) }
attr_reader :currency
# Attribute for field evidence
sig { returns(Evidence) }
attr_reader :evidence
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# The enum that describes the dispute loss outcome. If the dispute is not lost, this field will be absent. New enum values may be added in the future, so be sure to handle unknown values.
sig { returns(String) }
attr_reader :loss_reason
# 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.
sig { returns(T::Hash[String, String]) }
attr_reader :metadata
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Current status of the dispute.
sig { returns(String) }
attr_reader :status
# The transaction being disputed.
sig { returns(T.any(String, Stripe::Issuing::Transaction)) }
attr_reader :transaction
# [Treasury](https://stripe.com/docs/api/treasury) details related to this dispute if it was created on a [FinancialAccount](/docs/api/treasury/financial_accounts
sig { returns(T.nilable(Treasury)) }
attr_reader :treasury
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return Issuing disputes that were created during the given date interval.
sig { returns(T.nilable(T.any(::Stripe::Issuing::Dispute::ListParams::Created, Integer))) }
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Select Issuing disputes with the given status.
sig { returns(T.nilable(String)) }
attr_accessor :status
# Select the Issuing dispute for the given transaction.
sig { returns(T.nilable(String)) }
attr_accessor :transaction
sig {
params(created: T.nilable(T.any(::Stripe::Issuing::Dispute::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String), status: T.nilable(String), transaction: T.nilable(String)).void
}
def initialize(
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil,
status: nil,
transaction: nil
); end
end
class CreateParams < Stripe::RequestParams
class Evidence < Stripe::RequestParams
class Canceled < Stripe::RequestParams
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :additional_documentation
# Date when order was canceled.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :canceled_at
# Whether the cardholder was provided with a cancellation policy.
sig { returns(T.nilable(T.nilable(T.any(String, T::Boolean)))) }
attr_accessor :cancellation_policy_provided
# Reason for canceling the order.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :cancellation_reason
# Date when the cardholder expected to receive the product.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :expected_at
# Explanation of why the cardholder is disputing this transaction.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :explanation
# Description of the merchandise or service that was purchased.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :product_description
# Whether the product was a merchandise or service.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :product_type
# Result of cardholder's attempt to return the product.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :return_status
# Date when the product was returned or attempted to be returned.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :returned_at
sig {
params(additional_documentation: T.nilable(T.nilable(String)), canceled_at: T.nilable(T.nilable(T.any(String, Integer))), cancellation_policy_provided: T.nilable(T.nilable(T.any(String, T::Boolean))), cancellation_reason: T.nilable(T.nilable(String)), expected_at: T.nilable(T.nilable(T.any(String, Integer))), explanation: T.nilable(T.nilable(String)), product_description: T.nilable(T.nilable(String)), product_type: T.nilable(T.nilable(T.any(String, String))), return_status: T.nilable(T.nilable(T.any(String, String))), returned_at: T.nilable(T.nilable(T.any(String, Integer)))).void
}
def initialize(
additional_documentation: nil,
canceled_at: nil,
cancellation_policy_provided: nil,
cancellation_reason: nil,
expected_at: nil,
explanation: nil,
product_description: nil,
product_type: nil,
return_status: nil,
returned_at: nil
); end
end
class Duplicate < Stripe::RequestParams
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :additional_documentation
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Copy of the card statement showing that the product had already been paid for.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :card_statement
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Copy of the receipt showing that the product had been paid for in cash.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :cash_receipt
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Image of the front and back of the check that was used to pay for the product.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :check_image
# Explanation of why the cardholder is disputing this transaction.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :explanation
# Transaction (e.g., ipi_...) that the disputed transaction is a duplicate of. Of the two or more transactions that are copies of each other, this is original undisputed one.
sig { returns(T.nilable(String)) }
attr_accessor :original_transaction
sig {
params(additional_documentation: T.nilable(T.nilable(String)), card_statement: T.nilable(T.nilable(String)), cash_receipt: T.nilable(T.nilable(String)), check_image: T.nilable(T.nilable(String)), explanation: T.nilable(T.nilable(String)), original_transaction: T.nilable(String)).void
}
def initialize(
additional_documentation: nil,
card_statement: nil,
cash_receipt: nil,
check_image: nil,
explanation: nil,
original_transaction: nil
); end
end
class Fraudulent < Stripe::RequestParams
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :additional_documentation
# Explanation of why the cardholder is disputing this transaction.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :explanation
sig {
params(additional_documentation: T.nilable(T.nilable(String)), explanation: T.nilable(T.nilable(String))).void
}
def initialize(additional_documentation: nil, explanation: nil); end
end
class MerchandiseNotAsDescribed < Stripe::RequestParams
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :additional_documentation
# Explanation of why the cardholder is disputing this transaction.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :explanation
# Date when the product was received.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :received_at
# Description of the cardholder's attempt to return the product.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :return_description
# Result of cardholder's attempt to return the product.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :return_status
# Date when the product was returned or attempted to be returned.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :returned_at
sig {
params(additional_documentation: T.nilable(T.nilable(String)), explanation: T.nilable(T.nilable(String)), received_at: T.nilable(T.nilable(T.any(String, Integer))), return_description: T.nilable(T.nilable(String)), return_status: T.nilable(T.nilable(T.any(String, String))), returned_at: T.nilable(T.nilable(T.any(String, Integer)))).void
}
def initialize(
additional_documentation: nil,
explanation: nil,
received_at: nil,
return_description: nil,
return_status: nil,
returned_at: nil
); end
end
class NoValidAuthorization < Stripe::RequestParams
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :additional_documentation
# Explanation of why the cardholder is disputing this transaction.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :explanation
sig {
params(additional_documentation: T.nilable(T.nilable(String)), explanation: T.nilable(T.nilable(String))).void
}
def initialize(additional_documentation: nil, explanation: nil); end
end
class NotReceived < Stripe::RequestParams
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :additional_documentation
# Date when the cardholder expected to receive the product.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :expected_at
# Explanation of why the cardholder is disputing this transaction.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :explanation
# Description of the merchandise or service that was purchased.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :product_description
# Whether the product was a merchandise or service.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :product_type
sig {
params(additional_documentation: T.nilable(T.nilable(String)), expected_at: T.nilable(T.nilable(T.any(String, Integer))), explanation: T.nilable(T.nilable(String)), product_description: T.nilable(T.nilable(String)), product_type: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(
additional_documentation: nil,
expected_at: nil,
explanation: nil,
product_description: nil,
product_type: nil
); end
end
class Other < Stripe::RequestParams
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :additional_documentation
# Explanation of why the cardholder is disputing this transaction.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :explanation
# Description of the merchandise or service that was purchased.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :product_description
# Whether the product was a merchandise or service.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :product_type
sig {
params(additional_documentation: T.nilable(T.nilable(String)), explanation: T.nilable(T.nilable(String)), product_description: T.nilable(T.nilable(String)), product_type: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(
additional_documentation: nil,
explanation: nil,
product_description: nil,
product_type: nil
); end
end
class ServiceNotAsDescribed < Stripe::RequestParams
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :additional_documentation
# Date when order was canceled.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :canceled_at
# Reason for canceling the order.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :cancellation_reason
# Explanation of why the cardholder is disputing this transaction.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :explanation
# Date when the product was received.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :received_at
sig {
params(additional_documentation: T.nilable(T.nilable(String)), canceled_at: T.nilable(T.nilable(T.any(String, Integer))), cancellation_reason: T.nilable(T.nilable(String)), explanation: T.nilable(T.nilable(String)), received_at: T.nilable(T.nilable(T.any(String, Integer)))).void
}
def initialize(
additional_documentation: nil,
canceled_at: nil,
cancellation_reason: nil,
explanation: nil,
received_at: nil
); end
end
# Evidence provided when `reason` is 'canceled'.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::Dispute::CreateParams::Evidence::Canceled))))
}
attr_accessor :canceled
# Evidence provided when `reason` is 'duplicate'.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::Dispute::CreateParams::Evidence::Duplicate))))
}
attr_accessor :duplicate
# Evidence provided when `reason` is 'fraudulent'.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::Dispute::CreateParams::Evidence::Fraudulent))))
}
attr_accessor :fraudulent
# Evidence provided when `reason` is 'merchandise_not_as_described'.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::Dispute::CreateParams::Evidence::MerchandiseNotAsDescribed))))
}
attr_accessor :merchandise_not_as_described
# Evidence provided when `reason` is 'no_valid_authorization'.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::Dispute::CreateParams::Evidence::NoValidAuthorization))))
}
attr_accessor :no_valid_authorization
# Evidence provided when `reason` is 'not_received'.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::Dispute::CreateParams::Evidence::NotReceived))))
}
attr_accessor :not_received
# Evidence provided when `reason` is 'other'.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::Dispute::CreateParams::Evidence::Other))))
}
attr_accessor :other
# The reason for filing the dispute. The evidence should be submitted in the field of the same name.
sig { returns(T.nilable(String)) }
attr_accessor :reason
# Evidence provided when `reason` is 'service_not_as_described'.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::Dispute::CreateParams::Evidence::ServiceNotAsDescribed))))
}
attr_accessor :service_not_as_described
sig {
params(canceled: T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::Dispute::CreateParams::Evidence::Canceled))), duplicate: T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::Dispute::CreateParams::Evidence::Duplicate))), fraudulent: T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::Dispute::CreateParams::Evidence::Fraudulent))), merchandise_not_as_described: T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::Dispute::CreateParams::Evidence::MerchandiseNotAsDescribed))), no_valid_authorization: T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::Dispute::CreateParams::Evidence::NoValidAuthorization))), not_received: T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::Dispute::CreateParams::Evidence::NotReceived))), other: T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::Dispute::CreateParams::Evidence::Other))), reason: T.nilable(String), service_not_as_described: T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::Dispute::CreateParams::Evidence::ServiceNotAsDescribed)))).void
}
def initialize(
canceled: nil,
duplicate: nil,
fraudulent: nil,
merchandise_not_as_described: nil,
no_valid_authorization: nil,
not_received: nil,
other: nil,
reason: nil,
service_not_as_described: nil
); end
end
class Treasury < Stripe::RequestParams
# The ID of the ReceivedDebit to initiate an Issuings dispute for.
sig { returns(String) }
attr_accessor :received_debit
sig { params(received_debit: String).void }
def initialize(received_debit: nil); end
end
# The dispute amount in the card's currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal). If not set, defaults to the full transaction amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# Evidence provided for the dispute.
sig { returns(T.nilable(::Stripe::Issuing::Dispute::CreateParams::Evidence)) }
attr_accessor :evidence
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The ID of the issuing transaction to create a dispute for. For transaction on Treasury FinancialAccounts, use `treasury.received_debit`.
sig { returns(T.nilable(String)) }
attr_accessor :transaction
# Params for disputes related to Treasury FinancialAccounts
sig { returns(T.nilable(::Stripe::Issuing::Dispute::CreateParams::Treasury)) }
attr_accessor :treasury
sig {
params(amount: T.nilable(Integer), evidence: T.nilable(::Stripe::Issuing::Dispute::CreateParams::Evidence), expand: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), transaction: T.nilable(String), treasury: T.nilable(::Stripe::Issuing::Dispute::CreateParams::Treasury)).void
}
def initialize(
amount: nil,
evidence: nil,
expand: nil,
metadata: nil,
transaction: nil,
treasury: nil
); end
end
class UpdateParams < Stripe::RequestParams
class Evidence < Stripe::RequestParams
class Canceled < Stripe::RequestParams
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :additional_documentation
# Date when order was canceled.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :canceled_at
# Whether the cardholder was provided with a cancellation policy.
sig { returns(T.nilable(T.nilable(T.any(String, T::Boolean)))) }
attr_accessor :cancellation_policy_provided
# Reason for canceling the order.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :cancellation_reason
# Date when the cardholder expected to receive the product.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :expected_at
# Explanation of why the cardholder is disputing this transaction.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :explanation
# Description of the merchandise or service that was purchased.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :product_description
# Whether the product was a merchandise or service.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :product_type
# Result of cardholder's attempt to return the product.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :return_status
# Date when the product was returned or attempted to be returned.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :returned_at
sig {
params(additional_documentation: T.nilable(T.nilable(String)), canceled_at: T.nilable(T.nilable(T.any(String, Integer))), cancellation_policy_provided: T.nilable(T.nilable(T.any(String, T::Boolean))), cancellation_reason: T.nilable(T.nilable(String)), expected_at: T.nilable(T.nilable(T.any(String, Integer))), explanation: T.nilable(T.nilable(String)), product_description: T.nilable(T.nilable(String)), product_type: T.nilable(T.nilable(T.any(String, String))), return_status: T.nilable(T.nilable(T.any(String, String))), returned_at: T.nilable(T.nilable(T.any(String, Integer)))).void
}
def initialize(
additional_documentation: nil,
canceled_at: nil,
cancellation_policy_provided: nil,
cancellation_reason: nil,
expected_at: nil,
explanation: nil,
product_description: nil,
product_type: nil,
return_status: nil,
returned_at: nil
); end
end
class Duplicate < Stripe::RequestParams
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :additional_documentation
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Copy of the card statement showing that the product had already been paid for.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :card_statement
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Copy of the receipt showing that the product had been paid for in cash.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :cash_receipt
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Image of the front and back of the check that was used to pay for the product.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :check_image
# Explanation of why the cardholder is disputing this transaction.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :explanation
# Transaction (e.g., ipi_...) that the disputed transaction is a duplicate of. Of the two or more transactions that are copies of each other, this is original undisputed one.
sig { returns(T.nilable(String)) }
attr_accessor :original_transaction
sig {
params(additional_documentation: T.nilable(T.nilable(String)), card_statement: T.nilable(T.nilable(String)), cash_receipt: T.nilable(T.nilable(String)), check_image: T.nilable(T.nilable(String)), explanation: T.nilable(T.nilable(String)), original_transaction: T.nilable(String)).void
}
def initialize(
additional_documentation: nil,
card_statement: nil,
cash_receipt: nil,
check_image: nil,
explanation: nil,
original_transaction: nil
); end
end
class Fraudulent < Stripe::RequestParams
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :additional_documentation
# Explanation of why the cardholder is disputing this transaction.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :explanation
sig {
params(additional_documentation: T.nilable(T.nilable(String)), explanation: T.nilable(T.nilable(String))).void
}
def initialize(additional_documentation: nil, explanation: nil); end
end
class MerchandiseNotAsDescribed < Stripe::RequestParams
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :additional_documentation
# Explanation of why the cardholder is disputing this transaction.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :explanation
# Date when the product was received.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :received_at
# Description of the cardholder's attempt to return the product.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :return_description
# Result of cardholder's attempt to return the product.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :return_status
# Date when the product was returned or attempted to be returned.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :returned_at
sig {
params(additional_documentation: T.nilable(T.nilable(String)), explanation: T.nilable(T.nilable(String)), received_at: T.nilable(T.nilable(T.any(String, Integer))), return_description: T.nilable(T.nilable(String)), return_status: T.nilable(T.nilable(T.any(String, String))), returned_at: T.nilable(T.nilable(T.any(String, Integer)))).void
}
def initialize(
additional_documentation: nil,
explanation: nil,
received_at: nil,
return_description: nil,
return_status: nil,
returned_at: nil
); end
end
class NoValidAuthorization < Stripe::RequestParams
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :additional_documentation
# Explanation of why the cardholder is disputing this transaction.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :explanation
sig {
params(additional_documentation: T.nilable(T.nilable(String)), explanation: T.nilable(T.nilable(String))).void
}
def initialize(additional_documentation: nil, explanation: nil); end
end
class NotReceived < Stripe::RequestParams
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :additional_documentation
# Date when the cardholder expected to receive the product.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :expected_at
# Explanation of why the cardholder is disputing this transaction.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :explanation
# Description of the merchandise or service that was purchased.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :product_description
# Whether the product was a merchandise or service.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :product_type
sig {
params(additional_documentation: T.nilable(T.nilable(String)), expected_at: T.nilable(T.nilable(T.any(String, Integer))), explanation: T.nilable(T.nilable(String)), product_description: T.nilable(T.nilable(String)), product_type: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(
additional_documentation: nil,
expected_at: nil,
explanation: nil,
product_description: nil,
product_type: nil
); end
end
class Other < Stripe::RequestParams
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :additional_documentation
# Explanation of why the cardholder is disputing this transaction.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :explanation
# Description of the merchandise or service that was purchased.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :product_description
# Whether the product was a merchandise or service.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :product_type
sig {
params(additional_documentation: T.nilable(T.nilable(String)), explanation: T.nilable(T.nilable(String)), product_description: T.nilable(T.nilable(String)), product_type: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(
additional_documentation: nil,
explanation: nil,
product_description: nil,
product_type: nil
); end
end
class ServiceNotAsDescribed < Stripe::RequestParams
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :additional_documentation
# Date when order was canceled.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :canceled_at
# Reason for canceling the order.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :cancellation_reason
# Explanation of why the cardholder is disputing this transaction.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :explanation
# Date when the product was received.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :received_at
sig {
params(additional_documentation: T.nilable(T.nilable(String)), canceled_at: T.nilable(T.nilable(T.any(String, Integer))), cancellation_reason: T.nilable(T.nilable(String)), explanation: T.nilable(T.nilable(String)), received_at: T.nilable(T.nilable(T.any(String, Integer)))).void
}
def initialize(
additional_documentation: nil,
canceled_at: nil,
cancellation_reason: nil,
explanation: nil,
received_at: nil
); end
end
# Evidence provided when `reason` is 'canceled'.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::Dispute::UpdateParams::Evidence::Canceled))))
}
attr_accessor :canceled
# Evidence provided when `reason` is 'duplicate'.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::Dispute::UpdateParams::Evidence::Duplicate))))
}
attr_accessor :duplicate
# Evidence provided when `reason` is 'fraudulent'.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::Dispute::UpdateParams::Evidence::Fraudulent))))
}
attr_accessor :fraudulent
# Evidence provided when `reason` is 'merchandise_not_as_described'.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::Dispute::UpdateParams::Evidence::MerchandiseNotAsDescribed))))
}
attr_accessor :merchandise_not_as_described
# Evidence provided when `reason` is 'no_valid_authorization'.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::Dispute::UpdateParams::Evidence::NoValidAuthorization))))
}
attr_accessor :no_valid_authorization
# Evidence provided when `reason` is 'not_received'.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::Dispute::UpdateParams::Evidence::NotReceived))))
}
attr_accessor :not_received
# Evidence provided when `reason` is 'other'.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::Dispute::UpdateParams::Evidence::Other))))
}
attr_accessor :other
# The reason for filing the dispute. The evidence should be submitted in the field of the same name.
sig { returns(T.nilable(String)) }
attr_accessor :reason
# Evidence provided when `reason` is 'service_not_as_described'.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::Dispute::UpdateParams::Evidence::ServiceNotAsDescribed))))
}
attr_accessor :service_not_as_described
sig {
params(canceled: T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::Dispute::UpdateParams::Evidence::Canceled))), duplicate: T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::Dispute::UpdateParams::Evidence::Duplicate))), fraudulent: T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::Dispute::UpdateParams::Evidence::Fraudulent))), merchandise_not_as_described: T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::Dispute::UpdateParams::Evidence::MerchandiseNotAsDescribed))), no_valid_authorization: T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::Dispute::UpdateParams::Evidence::NoValidAuthorization))), not_received: T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::Dispute::UpdateParams::Evidence::NotReceived))), other: T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::Dispute::UpdateParams::Evidence::Other))), reason: T.nilable(String), service_not_as_described: T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::Dispute::UpdateParams::Evidence::ServiceNotAsDescribed)))).void
}
def initialize(
canceled: nil,
duplicate: nil,
fraudulent: nil,
merchandise_not_as_described: nil,
no_valid_authorization: nil,
not_received: nil,
other: nil,
reason: nil,
service_not_as_described: nil
); end
end
# The dispute amount in the card's currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# Evidence provided for the dispute.
sig { returns(T.nilable(::Stripe::Issuing::Dispute::UpdateParams::Evidence)) }
attr_accessor :evidence
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
sig {
params(amount: T.nilable(Integer), evidence: T.nilable(::Stripe::Issuing::Dispute::UpdateParams::Evidence), expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String])))).void
}
def initialize(amount: nil, evidence: nil, expand: nil, metadata: nil); end
end
class SubmitParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
sig {
params(expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String])))).void
}
def initialize(expand: nil, metadata: nil); end
end
# Creates an Issuing Dispute object. Individual pieces of evidence within the evidence object are optional at this point. Stripe only validates that required evidence is present during submission. Refer to [Dispute reasons and evidence](https://docs.stripe.com/docs/issuing/purchases/disputes#dispute-reasons-and-evidence) for more details about evidence requirements.
sig {
params(params: T.any(::Stripe::Issuing::Dispute::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Dispute)
}
def self.create(params = {}, opts = {}); end
# Returns a list of Issuing Dispute objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.
sig {
params(params: T.any(::Stripe::Issuing::Dispute::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Submits an Issuing Dispute to the card network. Stripe validates that all evidence fields required for the dispute's reason are present. For more details, see [Dispute reasons and evidence](https://docs.stripe.com/docs/issuing/purchases/disputes#dispute-reasons-and-evidence).
sig {
params(params: T.any(::Stripe::Issuing::Dispute::SubmitParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Dispute)
}
def submit(params = {}, opts = {}); end
# Submits an Issuing Dispute to the card network. Stripe validates that all evidence fields required for the dispute's reason are present. For more details, see [Dispute reasons and evidence](https://docs.stripe.com/docs/issuing/purchases/disputes#dispute-reasons-and-evidence).
sig {
params(dispute: String, params: T.any(::Stripe::Issuing::Dispute::SubmitParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Dispute)
}
def self.submit(dispute, params = {}, opts = {}); end
# Updates the specified Issuing Dispute object by setting the values of the parameters passed. Any parameters not provided will be left unchanged. Properties on the evidence object can be unset by passing in an empty string.
sig {
params(dispute: String, params: T.any(::Stripe::Issuing::Dispute::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Dispute)
}
def self.update(dispute, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Issuing
# Represents a record from the card network of a money movement or change in state for an Issuing dispute. These records are included in the settlement reports that we receive from networks and expose to users as Settlement objects.
class DisputeSettlementDetail < APIResource
class NetworkData < Stripe::StripeObject
# The date the transaction was processed by the card network. This can be different from the date the seller recorded the transaction depending on when the acquirer submits the transaction to the network.
sig { returns(T.nilable(String)) }
attr_reader :processing_date
end
# Disputed amount in the card’s currency and in the smallest currency unit. Usually the amount of the transaction, but can differ (usually because of currency fluctuation).
sig { returns(Integer) }
attr_reader :amount
# The card used to make the original transaction.
sig { returns(String) }
attr_reader :card
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# The currency the original transaction was made in. 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).
sig { returns(String) }
attr_reader :currency
# The ID of the linked dispute.
sig { returns(String) }
attr_reader :dispute
# The type of event corresponding to this dispute settlement detail, representing the stage in the dispute network lifecycle.
sig { returns(String) }
attr_reader :event_type
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# The card network for this dispute settlement detail. One of ["visa", "mastercard", "maestro"]
sig { returns(String) }
attr_reader :network
# Details about the transaction, such as processing dates, set by the card network.
sig { returns(T.nilable(NetworkData)) }
attr_reader :network_data
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The ID of the linked card network settlement.
sig { returns(T.nilable(String)) }
attr_reader :settlement
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Select the Issuing dispute settlement details for the given settlement.
sig { returns(T.nilable(String)) }
attr_accessor :settlement
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), settlement: T.nilable(String), starting_after: T.nilable(String)).void
}
def initialize(
ending_before: nil,
expand: nil,
limit: nil,
settlement: nil,
starting_after: nil
); end
end
# Returns a list of Issuing DisputeSettlementDetail objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.
sig {
params(params: T.any(::Stripe::Issuing::DisputeSettlementDetail::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Issuing
# A fraud liability debit occurs when Stripe debits a platform's account for fraud losses on Issuing transactions.
class FraudLiabilityDebit < APIResource
# Debited amount. This is equal to the disputed amount and is given in the card’s currency and in the smallest currency unit.
sig { returns(Integer) }
attr_reader :amount
# ID of the [balance transaction](https://stripe.com/docs/api/balance_transactions) associated with this debit.
sig { returns(T.nilable(T.any(String, Stripe::BalanceTransaction))) }
attr_reader :balance_transaction
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# The currency of the debit. 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).
sig { returns(String) }
attr_reader :currency
# The ID of the linked dispute.
sig { returns(String) }
attr_reader :dispute
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return Issuing Fraud Liability Debits that were created during the given date interval.
sig {
returns(T.nilable(T.any(::Stripe::Issuing::FraudLiabilityDebit::ListParams::Created, Integer)))
}
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(created: T.nilable(T.any(::Stripe::Issuing::FraudLiabilityDebit::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil
); end
end
# Returns a list of Issuing FraudLiabilityDebit objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.
sig {
params(params: T.any(::Stripe::Issuing::FraudLiabilityDebit::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Issuing
# A Personalization Design is a logical grouping of a Physical Bundle, card logo, and carrier text that represents a product line.
class PersonalizationDesign < APIResource
class CarrierText < Stripe::StripeObject
# The footer body text of the carrier letter.
sig { returns(T.nilable(String)) }
attr_reader :footer_body
# The footer title text of the carrier letter.
sig { returns(T.nilable(String)) }
attr_reader :footer_title
# The header body text of the carrier letter.
sig { returns(T.nilable(String)) }
attr_reader :header_body
# The header title text of the carrier letter.
sig { returns(T.nilable(String)) }
attr_reader :header_title
end
class Preferences < Stripe::StripeObject
# Whether we use this personalization design to create cards when one isn't specified. A connected account uses the Connect platform's default design if no personalization design is set as the default design.
sig { returns(T::Boolean) }
attr_reader :is_default
# Whether this personalization design is used to create cards when one is not specified and a default for this connected account does not exist.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :is_platform_default
end
class RejectionReasons < Stripe::StripeObject
# The reason(s) the card logo was rejected.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :card_logo
# The reason(s) the carrier text was rejected.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :carrier_text
end
# The file for the card logo to use with physical bundles that support card logos. Must have a `purpose` value of `issuing_logo`.
sig { returns(T.nilable(T.any(String, Stripe::File))) }
attr_reader :card_logo
# Hash containing carrier text, for use with physical bundles that support carrier text.
sig { returns(T.nilable(CarrierText)) }
attr_reader :carrier_text
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# A lookup key used to retrieve personalization designs dynamically from a static string. This may be up to 200 characters.
sig { returns(T.nilable(String)) }
attr_reader :lookup_key
# 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.
sig { returns(T::Hash[String, String]) }
attr_reader :metadata
# Friendly display name.
sig { returns(T.nilable(String)) }
attr_reader :name
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The physical bundle object belonging to this personalization design.
sig { returns(T.any(String, Stripe::Issuing::PhysicalBundle)) }
attr_reader :physical_bundle
# Attribute for field preferences
sig { returns(Preferences) }
attr_reader :preferences
# Attribute for field rejection_reasons
sig { returns(RejectionReasons) }
attr_reader :rejection_reasons
# Whether this personalization design can be used to create cards.
sig { returns(String) }
attr_reader :status
class ListParams < Stripe::RequestParams
class Preferences < Stripe::RequestParams
# Only return the personalization design that's set as the default. A connected account uses the Connect platform's default design if no personalization design is set as the default.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :is_default
# Only return the personalization design that is set as the Connect platform's default. This parameter is only applicable to connected accounts.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :is_platform_default
sig {
params(is_default: T.nilable(T::Boolean), is_platform_default: T.nilable(T::Boolean)).void
}
def initialize(is_default: nil, is_platform_default: nil); end
end
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Only return personalization designs with the given lookup keys.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :lookup_keys
# Only return personalization designs with the given preferences.
sig {
returns(T.nilable(::Stripe::Issuing::PersonalizationDesign::ListParams::Preferences))
}
attr_accessor :preferences
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return personalization designs with the given status.
sig { returns(T.nilable(String)) }
attr_accessor :status
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), lookup_keys: T.nilable(T::Array[String]), preferences: T.nilable(::Stripe::Issuing::PersonalizationDesign::ListParams::Preferences), starting_after: T.nilable(String), status: T.nilable(String)).void
}
def initialize(
ending_before: nil,
expand: nil,
limit: nil,
lookup_keys: nil,
preferences: nil,
starting_after: nil,
status: nil
); end
end
class CreateParams < Stripe::RequestParams
class CarrierText < Stripe::RequestParams
# The footer body text of the carrier letter.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :footer_body
# The footer title text of the carrier letter.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :footer_title
# The header body text of the carrier letter.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :header_body
# The header title text of the carrier letter.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :header_title
sig {
params(footer_body: T.nilable(T.nilable(String)), footer_title: T.nilable(T.nilable(String)), header_body: T.nilable(T.nilable(String)), header_title: T.nilable(T.nilable(String))).void
}
def initialize(
footer_body: nil,
footer_title: nil,
header_body: nil,
header_title: nil
); end
end
class Preferences < Stripe::RequestParams
# Whether we use this personalization design to create cards when one isn't specified. A connected account uses the Connect platform's default design if no personalization design is set as the default design.
sig { returns(T::Boolean) }
attr_accessor :is_default
sig { params(is_default: T::Boolean).void }
def initialize(is_default: nil); end
end
# The file for the card logo, for use with physical bundles that support card logos. Must have a `purpose` value of `issuing_logo`.
sig { returns(T.nilable(String)) }
attr_accessor :card_logo
# Hash containing carrier text, for use with physical bundles that support carrier text.
sig {
returns(T.nilable(::Stripe::Issuing::PersonalizationDesign::CreateParams::CarrierText))
}
attr_accessor :carrier_text
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A lookup key used to retrieve personalization designs dynamically from a static string. This may be up to 200 characters.
sig { returns(T.nilable(String)) }
attr_accessor :lookup_key
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Friendly display name.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The physical bundle object belonging to this personalization design.
sig { returns(String) }
attr_accessor :physical_bundle
# Information on whether this personalization design is used to create cards when one is not specified.
sig {
returns(T.nilable(::Stripe::Issuing::PersonalizationDesign::CreateParams::Preferences))
}
attr_accessor :preferences
# If set to true, will atomically remove the lookup key from the existing personalization design, and assign it to this personalization design.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :transfer_lookup_key
sig {
params(card_logo: T.nilable(String), carrier_text: T.nilable(::Stripe::Issuing::PersonalizationDesign::CreateParams::CarrierText), expand: T.nilable(T::Array[String]), lookup_key: T.nilable(String), metadata: T.nilable(T::Hash[String, String]), name: T.nilable(String), physical_bundle: String, preferences: T.nilable(::Stripe::Issuing::PersonalizationDesign::CreateParams::Preferences), transfer_lookup_key: T.nilable(T::Boolean)).void
}
def initialize(
card_logo: nil,
carrier_text: nil,
expand: nil,
lookup_key: nil,
metadata: nil,
name: nil,
physical_bundle: nil,
preferences: nil,
transfer_lookup_key: nil
); end
end
class UpdateParams < Stripe::RequestParams
class CarrierText < Stripe::RequestParams
# The footer body text of the carrier letter.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :footer_body
# The footer title text of the carrier letter.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :footer_title
# The header body text of the carrier letter.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :header_body
# The header title text of the carrier letter.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :header_title
sig {
params(footer_body: T.nilable(T.nilable(String)), footer_title: T.nilable(T.nilable(String)), header_body: T.nilable(T.nilable(String)), header_title: T.nilable(T.nilable(String))).void
}
def initialize(
footer_body: nil,
footer_title: nil,
header_body: nil,
header_title: nil
); end
end
class Preferences < Stripe::RequestParams
# Whether we use this personalization design to create cards when one isn't specified. A connected account uses the Connect platform's default design if no personalization design is set as the default design.
sig { returns(T::Boolean) }
attr_accessor :is_default
sig { params(is_default: T::Boolean).void }
def initialize(is_default: nil); end
end
# The file for the card logo, for use with physical bundles that support card logos. Must have a `purpose` value of `issuing_logo`.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :card_logo
# Hash containing carrier text, for use with physical bundles that support carrier text.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::PersonalizationDesign::UpdateParams::CarrierText))))
}
attr_accessor :carrier_text
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A lookup key used to retrieve personalization designs dynamically from a static string. This may be up to 200 characters.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :lookup_key
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Friendly display name. Providing an empty string will set the field to null.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :name
# The physical bundle object belonging to this personalization design.
sig { returns(T.nilable(String)) }
attr_accessor :physical_bundle
# Information on whether this personalization design is used to create cards when one is not specified.
sig {
returns(T.nilable(::Stripe::Issuing::PersonalizationDesign::UpdateParams::Preferences))
}
attr_accessor :preferences
# If set to true, will atomically remove the lookup key from the existing personalization design, and assign it to this personalization design.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :transfer_lookup_key
sig {
params(card_logo: T.nilable(T.nilable(String)), carrier_text: T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::PersonalizationDesign::UpdateParams::CarrierText))), expand: T.nilable(T::Array[String]), lookup_key: T.nilable(T.nilable(String)), metadata: T.nilable(T::Hash[String, String]), name: T.nilable(T.nilable(String)), physical_bundle: T.nilable(String), preferences: T.nilable(::Stripe::Issuing::PersonalizationDesign::UpdateParams::Preferences), transfer_lookup_key: T.nilable(T::Boolean)).void
}
def initialize(
card_logo: nil,
carrier_text: nil,
expand: nil,
lookup_key: nil,
metadata: nil,
name: nil,
physical_bundle: nil,
preferences: nil,
transfer_lookup_key: nil
); end
end
class ActivateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class DeactivateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class RejectParams < Stripe::RequestParams
class RejectionReasons < Stripe::RequestParams
# The reason(s) the card logo was rejected.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :card_logo
# The reason(s) the carrier text was rejected.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :carrier_text
sig {
params(card_logo: T.nilable(T::Array[String]), carrier_text: T.nilable(T::Array[String])).void
}
def initialize(card_logo: nil, carrier_text: nil); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The reason(s) the personalization design was rejected.
sig { returns(::Stripe::Issuing::PersonalizationDesign::RejectParams::RejectionReasons) }
attr_accessor :rejection_reasons
sig {
params(expand: T.nilable(T::Array[String]), rejection_reasons: ::Stripe::Issuing::PersonalizationDesign::RejectParams::RejectionReasons).void
}
def initialize(expand: nil, rejection_reasons: nil); end
end
# Creates a personalization design object.
sig {
params(params: T.any(::Stripe::Issuing::PersonalizationDesign::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::PersonalizationDesign)
}
def self.create(params = {}, opts = {}); end
# Returns a list of personalization design objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.
sig {
params(params: T.any(::Stripe::Issuing::PersonalizationDesign::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Updates a card personalization object.
sig {
params(personalization_design: String, params: T.any(::Stripe::Issuing::PersonalizationDesign::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::PersonalizationDesign)
}
def self.update(personalization_design, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Issuing
# A Physical Bundle represents the bundle of physical items - card stock, carrier letter, and envelope - that is shipped to a cardholder when you create a physical card.
class PhysicalBundle < APIResource
class Features < Stripe::StripeObject
# The policy for how to use card logo images in a card design with this physical bundle.
sig { returns(String) }
attr_reader :card_logo
# The policy for how to use carrier letter text in a card design with this physical bundle.
sig { returns(String) }
attr_reader :carrier_text
# The policy for how to use a second line on a card with this physical bundle.
sig { returns(String) }
attr_reader :second_line
end
# Attribute for field features
sig { returns(Features) }
attr_reader :features
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# Friendly display name.
sig { returns(String) }
attr_reader :name
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Whether this physical bundle can be used to create cards.
sig { returns(String) }
attr_reader :status
# Whether this physical bundle is a standard Stripe offering or custom-made for you.
sig { returns(String) }
attr_reader :type
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return physical bundles with the given status.
sig { returns(T.nilable(String)) }
attr_accessor :status
# Only return physical bundles with the given type.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String), status: T.nilable(String), type: T.nilable(String)).void
}
def initialize(
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil,
status: nil,
type: nil
); end
end
# Returns a list of physical bundle objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.
sig {
params(params: T.any(::Stripe::Issuing::PhysicalBundle::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Issuing
# When a non-stripe BIN is used, any use of an [issued card](https://stripe.com/docs/issuing) must be settled directly with the card network. The net amount owed is represented by an Issuing `Settlement` object.
class Settlement < APIResource
# The Bank Identification Number reflecting this settlement record.
sig { returns(String) }
attr_reader :bin
# The date that the transactions are cleared and posted to user's accounts.
sig { returns(Integer) }
attr_reader :clearing_date
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# 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).
sig { returns(String) }
attr_reader :currency
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# The total interchange received as reimbursement for the transactions.
sig { returns(Integer) }
attr_reader :interchange_fees_amount
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# 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.
sig { returns(T::Hash[String, String]) }
attr_reader :metadata
# The total net amount required to settle with the network.
sig { returns(Integer) }
attr_reader :net_total_amount
# The card network for this settlement report. One of ["visa", "maestro"]
sig { returns(String) }
attr_reader :network
# The total amount of fees owed to the network.
sig { returns(Integer) }
attr_reader :network_fees_amount
# The Settlement Identification Number assigned by the network.
sig { returns(String) }
attr_reader :network_settlement_identifier
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The total amount of any additional fees assessed by the card network.
sig { returns(Integer) }
attr_reader :other_fees_amount
# The total number of additional fees assessed by the card network.
sig { returns(Integer) }
attr_reader :other_fees_count
# One of `international` or `uk_national_net`.
sig { returns(String) }
attr_reader :settlement_service
# The current processing status of this settlement.
sig { returns(String) }
attr_reader :status
# The total transaction amount reflected in this settlement.
sig { returns(Integer) }
attr_reader :transaction_amount
# The total number of transactions reflected in this settlement.
sig { returns(Integer) }
attr_reader :transaction_count
end
end
end
# typed: true
module Stripe
module Issuing
# An issuing token object is created when an issued card is added to a digital wallet. As a [card issuer](https://stripe.com/docs/issuing), you can [view and manage these tokens](https://stripe.com/docs/issuing/controls/token-management) through Stripe.
class Token < APIResource
class NetworkData < Stripe::StripeObject
class Device < Stripe::StripeObject
# An obfuscated ID derived from the device ID.
sig { returns(String) }
attr_reader :device_fingerprint
# The IP address of the device at provisioning time.
sig { returns(String) }
attr_reader :ip_address
# The geographic latitude/longitude coordinates of the device at provisioning time. The format is [+-]decimal/[+-]decimal.
sig { returns(String) }
attr_reader :location
# The name of the device used for tokenization.
sig { returns(String) }
attr_reader :name
# The phone number of the device used for tokenization.
sig { returns(String) }
attr_reader :phone_number
# The type of device used for tokenization.
sig { returns(String) }
attr_reader :type
end
class Mastercard < Stripe::StripeObject
# A unique reference ID from MasterCard to represent the card account number.
sig { returns(String) }
attr_reader :card_reference_id
# The network-unique identifier for the token.
sig { returns(String) }
attr_reader :token_reference_id
# The ID of the entity requesting tokenization, specific to MasterCard.
sig { returns(String) }
attr_reader :token_requestor_id
# The name of the entity requesting tokenization, if known. This is directly provided from MasterCard.
sig { returns(String) }
attr_reader :token_requestor_name
end
class Visa < Stripe::StripeObject
# A unique reference ID from Visa to represent the card account number.
sig { returns(String) }
attr_reader :card_reference_id
# The network-unique identifier for the token.
sig { returns(String) }
attr_reader :token_reference_id
# The ID of the entity requesting tokenization, specific to Visa.
sig { returns(String) }
attr_reader :token_requestor_id
# Degree of risk associated with the token between `01` and `99`, with higher number indicating higher risk. A `00` value indicates the token was not scored by Visa.
sig { returns(String) }
attr_reader :token_risk_score
end
class WalletProvider < Stripe::StripeObject
class CardholderAddress < Stripe::StripeObject
# The street address of the cardholder tokenizing the card.
sig { returns(String) }
attr_reader :line1
# The postal code of the cardholder tokenizing the card.
sig { returns(String) }
attr_reader :postal_code
end
# The wallet provider-given account ID of the digital wallet the token belongs to.
sig { returns(String) }
attr_reader :account_id
# An evaluation on the trustworthiness of the wallet account between 1 and 5. A higher score indicates more trustworthy.
sig { returns(Integer) }
attr_reader :account_trust_score
# The method used for tokenizing a card.
sig { returns(String) }
attr_reader :card_number_source
# Attribute for field cardholder_address
sig { returns(CardholderAddress) }
attr_reader :cardholder_address
# The name of the cardholder tokenizing the card.
sig { returns(String) }
attr_reader :cardholder_name
# An evaluation on the trustworthiness of the device. A higher score indicates more trustworthy.
sig { returns(Integer) }
attr_reader :device_trust_score
# The hashed email address of the cardholder's account with the wallet provider.
sig { returns(String) }
attr_reader :hashed_account_email_address
# The reasons for suggested tokenization given by the card network.
sig { returns(T::Array[String]) }
attr_reader :reason_codes
# The recommendation on responding to the tokenization request.
sig { returns(String) }
attr_reader :suggested_decision
# The version of the standard for mapping reason codes followed by the wallet provider.
sig { returns(String) }
attr_reader :suggested_decision_version
end
# Attribute for field device
sig { returns(Device) }
attr_reader :device
# Attribute for field mastercard
sig { returns(Mastercard) }
attr_reader :mastercard
# The network that the token is associated with. An additional hash is included with a name matching this value, containing tokenization data specific to the card network.
sig { returns(String) }
attr_reader :type
# Attribute for field visa
sig { returns(Visa) }
attr_reader :visa
# Attribute for field wallet_provider
sig { returns(WalletProvider) }
attr_reader :wallet_provider
end
# Card associated with this token.
sig { returns(T.any(String, Stripe::Issuing::Card)) }
attr_reader :card
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# The hashed ID derived from the device ID from the card network associated with the token.
sig { returns(T.nilable(String)) }
attr_reader :device_fingerprint
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# The last four digits of the token.
sig { returns(String) }
attr_reader :last4
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# The token service provider / card network associated with the token.
sig { returns(String) }
attr_reader :network
# Attribute for field network_data
sig { returns(NetworkData) }
attr_reader :network_data
# Time at which the token was last updated by the card network. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :network_updated_at
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The usage state of the token.
sig { returns(String) }
attr_reader :status
# The digital wallet for this token, if one was used.
sig { returns(String) }
attr_reader :wallet_provider
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# The Issuing card identifier to list tokens for.
sig { returns(String) }
attr_accessor :card
# Only return Issuing tokens that were created during the given date interval.
sig { returns(T.nilable(T.any(::Stripe::Issuing::Token::ListParams::Created, Integer))) }
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Select Issuing tokens with the given status.
sig { returns(T.nilable(String)) }
attr_accessor :status
sig {
params(card: String, created: T.nilable(T.any(::Stripe::Issuing::Token::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String), status: T.nilable(String)).void
}
def initialize(
card: nil,
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil,
status: nil
); end
end
class UpdateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Specifies which status the token should be updated to.
sig { returns(String) }
attr_accessor :status
sig { params(expand: T.nilable(T::Array[String]), status: String).void }
def initialize(expand: nil, status: nil); end
end
# Lists all Issuing Token objects for a given card.
sig {
params(params: T.any(::Stripe::Issuing::Token::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Attempts to update the specified Issuing Token object to the status specified.
sig {
params(token: String, params: T.any(::Stripe::Issuing::Token::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Token)
}
def self.update(token, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Issuing
# Any use of an [issued card](https://stripe.com/docs/issuing) that results in funds entering or leaving
# your Stripe account, such as a completed purchase or refund, is represented by an Issuing
# `Transaction` object.
#
# Related guide: [Issued card transactions](https://stripe.com/docs/issuing/purchases/transactions)
class Transaction < APIResource
class AmountDetails < Stripe::StripeObject
# The fee charged by the ATM for the cash withdrawal.
sig { returns(T.nilable(Integer)) }
attr_reader :atm_fee
# The amount of cash requested by the cardholder.
sig { returns(T.nilable(Integer)) }
attr_reader :cashback_amount
end
class MerchantData < Stripe::StripeObject
# A categorization of the seller's type of business. See our [merchant categories guide](https://stripe.com/docs/issuing/merchant-categories) for a list of possible values.
sig { returns(String) }
attr_reader :category
# The merchant category code for the seller’s business
sig { returns(String) }
attr_reader :category_code
# City where the seller is located
sig { returns(T.nilable(String)) }
attr_reader :city
# Country where the seller is located
sig { returns(T.nilable(String)) }
attr_reader :country
# Name of the seller
sig { returns(T.nilable(String)) }
attr_reader :name
# Identifier assigned to the seller by the card network. Different card networks may assign different network_id fields to the same merchant.
sig { returns(String) }
attr_reader :network_id
# Postal code where the seller is located
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State where the seller is located
sig { returns(T.nilable(String)) }
attr_reader :state
# The seller's tax identification number. Currently populated for French merchants only.
sig { returns(T.nilable(String)) }
attr_reader :tax_id
# An ID assigned by the seller to the location of the sale.
sig { returns(T.nilable(String)) }
attr_reader :terminal_id
# URL provided by the merchant on a 3DS request
sig { returns(T.nilable(String)) }
attr_reader :url
end
class NetworkData < Stripe::StripeObject
# A code created by Stripe which is shared with the merchant to validate the authorization. This field will be populated if the authorization message was approved. The code typically starts with the letter "S", followed by a six-digit number. For example, "S498162". Please note that the code is not guaranteed to be unique across authorizations.
sig { returns(T.nilable(String)) }
attr_reader :authorization_code
# The date the transaction was processed by the card network. This can be different from the date the seller recorded the transaction depending on when the acquirer submits the transaction to the network.
sig { returns(T.nilable(String)) }
attr_reader :processing_date
# Unique identifier for the authorization assigned by the card network used to match subsequent messages, disputes, and transactions.
sig { returns(T.nilable(String)) }
attr_reader :transaction_id
end
class PurchaseDetails < Stripe::StripeObject
class Fleet < Stripe::StripeObject
class CardholderPromptData < Stripe::StripeObject
# Driver ID.
sig { returns(T.nilable(String)) }
attr_reader :driver_id
# Odometer reading.
sig { returns(T.nilable(Integer)) }
attr_reader :odometer
# An alphanumeric ID. This field is used when a vehicle ID, driver ID, or generic ID is entered by the cardholder, but the merchant or card network did not specify the prompt type.
sig { returns(T.nilable(String)) }
attr_reader :unspecified_id
# User ID.
sig { returns(T.nilable(String)) }
attr_reader :user_id
# Vehicle number.
sig { returns(T.nilable(String)) }
attr_reader :vehicle_number
end
class ReportedBreakdown < Stripe::StripeObject
class Fuel < Stripe::StripeObject
# Gross fuel amount that should equal Fuel Volume multipled by Fuel Unit Cost, inclusive of taxes.
sig { returns(T.nilable(String)) }
attr_reader :gross_amount_decimal
end
class NonFuel < Stripe::StripeObject
# Gross non-fuel amount that should equal the sum of the line items, inclusive of taxes.
sig { returns(T.nilable(String)) }
attr_reader :gross_amount_decimal
end
class Tax < Stripe::StripeObject
# Amount of state or provincial Sales Tax included in the transaction amount. Null if not reported by merchant or not subject to tax.
sig { returns(T.nilable(String)) }
attr_reader :local_amount_decimal
# Amount of national Sales Tax or VAT included in the transaction amount. Null if not reported by merchant or not subject to tax.
sig { returns(T.nilable(String)) }
attr_reader :national_amount_decimal
end
# Breakdown of fuel portion of the purchase.
sig { returns(T.nilable(Fuel)) }
attr_reader :fuel
# Breakdown of non-fuel portion of the purchase.
sig { returns(T.nilable(NonFuel)) }
attr_reader :non_fuel
# Information about tax included in this transaction.
sig { returns(T.nilable(Tax)) }
attr_reader :tax
end
# Answers to prompts presented to cardholder at point of sale.
sig { returns(T.nilable(CardholderPromptData)) }
attr_reader :cardholder_prompt_data
# The type of purchase. One of `fuel_purchase`, `non_fuel_purchase`, or `fuel_and_non_fuel_purchase`.
sig { returns(T.nilable(String)) }
attr_reader :purchase_type
# More information about the total amount. This information is not guaranteed to be accurate as some merchants may provide unreliable data.
sig { returns(T.nilable(ReportedBreakdown)) }
attr_reader :reported_breakdown
# The type of fuel service. One of `non_fuel_transaction`, `full_service`, or `self_service`.
sig { returns(T.nilable(String)) }
attr_reader :service_type
end
class Flight < Stripe::StripeObject
class Segment < Stripe::StripeObject
# The three-letter IATA airport code of the flight's destination.
sig { returns(T.nilable(String)) }
attr_reader :arrival_airport_code
# The airline carrier code.
sig { returns(T.nilable(String)) }
attr_reader :carrier
# The three-letter IATA airport code that the flight departed from.
sig { returns(T.nilable(String)) }
attr_reader :departure_airport_code
# The flight number.
sig { returns(T.nilable(String)) }
attr_reader :flight_number
# The flight's service class.
sig { returns(T.nilable(String)) }
attr_reader :service_class
# Whether a stopover is allowed on this flight.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :stopover_allowed
end
# The time that the flight departed.
sig { returns(T.nilable(Integer)) }
attr_reader :departure_at
# The name of the passenger.
sig { returns(T.nilable(String)) }
attr_reader :passenger_name
# Whether the ticket is refundable.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :refundable
# The legs of the trip.
sig { returns(T.nilable(T::Array[Segment])) }
attr_reader :segments
# The travel agency that issued the ticket.
sig { returns(T.nilable(String)) }
attr_reader :travel_agency
end
class Fuel < Stripe::StripeObject
# [Conexxus Payment System Product Code](https://www.conexxus.org/conexxus-payment-system-product-codes) identifying the primary fuel product purchased.
sig { returns(T.nilable(String)) }
attr_reader :industry_product_code
# The quantity of `unit`s of fuel that was dispensed, represented as a decimal string with at most 12 decimal places.
sig { returns(T.nilable(String)) }
attr_reader :quantity_decimal
# The type of fuel that was purchased. One of `diesel`, `unleaded_plus`, `unleaded_regular`, `unleaded_super`, or `other`.
sig { returns(String) }
attr_reader :type
# The units for `quantity_decimal`. One of `charging_minute`, `imperial_gallon`, `kilogram`, `kilowatt_hour`, `liter`, `pound`, `us_gallon`, or `other`.
sig { returns(String) }
attr_reader :unit
# The cost in cents per each unit of fuel, represented as a decimal string with at most 12 decimal places.
sig { returns(String) }
attr_reader :unit_cost_decimal
end
class Lodging < Stripe::StripeObject
# The time of checking into the lodging.
sig { returns(T.nilable(Integer)) }
attr_reader :check_in_at
# The number of nights stayed at the lodging.
sig { returns(T.nilable(Integer)) }
attr_reader :nights
end
class Receipt < Stripe::StripeObject
# The description of the item. The maximum length of this field is 26 characters.
sig { returns(T.nilable(String)) }
attr_reader :description
# The quantity of the item.
sig { returns(T.nilable(Float)) }
attr_reader :quantity
# The total for this line item in cents.
sig { returns(T.nilable(Integer)) }
attr_reader :total
# The unit cost of the item in cents.
sig { returns(T.nilable(Integer)) }
attr_reader :unit_cost
end
# Fleet-specific information for transactions using Fleet cards.
sig { returns(T.nilable(Fleet)) }
attr_reader :fleet
# Information about the flight that was purchased with this transaction.
sig { returns(T.nilable(Flight)) }
attr_reader :flight
# Information about fuel that was purchased with this transaction.
sig { returns(T.nilable(Fuel)) }
attr_reader :fuel
# Information about lodging that was purchased with this transaction.
sig { returns(T.nilable(Lodging)) }
attr_reader :lodging
# The line items in the purchase.
sig { returns(T.nilable(T::Array[Receipt])) }
attr_reader :receipt
# A merchant-specific order number.
sig { returns(T.nilable(String)) }
attr_reader :reference
end
class Treasury < Stripe::StripeObject
# The Treasury [ReceivedCredit](https://stripe.com/docs/api/treasury/received_credits) representing this Issuing transaction if it is a refund
sig { returns(T.nilable(String)) }
attr_reader :received_credit
# The Treasury [ReceivedDebit](https://stripe.com/docs/api/treasury/received_debits) representing this Issuing transaction if it is a capture
sig { returns(T.nilable(String)) }
attr_reader :received_debit
end
# The transaction amount, which will be reflected in your balance. This amount is in your currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(Integer) }
attr_reader :amount
# Detailed breakdown of amount components. These amounts are denominated in `currency` and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(T.nilable(AmountDetails)) }
attr_reader :amount_details
# The `Authorization` object that led to this transaction.
sig { returns(T.nilable(T.any(String, Stripe::Issuing::Authorization))) }
attr_reader :authorization
# ID of the [balance transaction](https://stripe.com/docs/api/balance_transactions) associated with this transaction.
sig { returns(T.nilable(T.any(String, Stripe::BalanceTransaction))) }
attr_reader :balance_transaction
# The card used to make this transaction.
sig { returns(T.any(String, Stripe::Issuing::Card)) }
attr_reader :card
# The cardholder to whom this transaction belongs.
sig { returns(T.nilable(T.any(String, Stripe::Issuing::Cardholder))) }
attr_reader :cardholder
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# 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).
sig { returns(String) }
attr_reader :currency
# If you've disputed the transaction, the ID of the dispute.
sig { returns(T.nilable(T.any(String, Stripe::Issuing::Dispute))) }
attr_reader :dispute
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# The amount that the merchant will receive, denominated in `merchant_currency` and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal). It will be different from `amount` if the merchant is taking payment in a different currency.
sig { returns(Integer) }
attr_reader :merchant_amount
# The currency with which the merchant is taking payment.
sig { returns(String) }
attr_reader :merchant_currency
# Attribute for field merchant_data
sig { returns(MerchantData) }
attr_reader :merchant_data
# 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.
sig { returns(T::Hash[String, String]) }
attr_reader :metadata
# Details about the transaction, such as processing dates, set by the card network.
sig { returns(T.nilable(NetworkData)) }
attr_reader :network_data
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Additional purchase information that is optionally provided by the merchant.
sig { returns(T.nilable(PurchaseDetails)) }
attr_reader :purchase_details
# The ID of the [settlement](https://stripe.com/docs/api/issuing/settlements) to which this transaction belongs.
sig { returns(T.nilable(T.any(String, Stripe::Issuing::Settlement))) }
attr_reader :settlement
# [Token](https://stripe.com/docs/api/issuing/tokens/object) object used for this transaction. If a network token was not used for this transaction, this field will be null.
sig { returns(T.nilable(T.any(String, Stripe::Issuing::Token))) }
attr_reader :token
# [Treasury](https://stripe.com/docs/api/treasury) details related to this transaction if it was created on a [FinancialAccount](/docs/api/treasury/financial_accounts
sig { returns(T.nilable(Treasury)) }
attr_reader :treasury
# The nature of the transaction.
sig { returns(String) }
attr_reader :type
# The digital wallet used for this transaction. One of `apple_pay`, `google_pay`, or `samsung_pay`.
sig { returns(T.nilable(String)) }
attr_reader :wallet
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return transactions that belong to the given card.
sig { returns(T.nilable(String)) }
attr_accessor :card
# Only return transactions that belong to the given cardholder.
sig { returns(T.nilable(String)) }
attr_accessor :cardholder
# Only return transactions that were created during the given date interval.
sig {
returns(T.nilable(T.any(::Stripe::Issuing::Transaction::ListParams::Created, Integer)))
}
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Only return transactions that are associated with the given settlement.
sig { returns(T.nilable(String)) }
attr_accessor :settlement
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return transactions that have the given type. One of `capture` or `refund`.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(card: T.nilable(String), cardholder: T.nilable(String), created: T.nilable(T.any(::Stripe::Issuing::Transaction::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), settlement: T.nilable(String), starting_after: T.nilable(String), type: T.nilable(String)).void
}
def initialize(
card: nil,
cardholder: nil,
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
settlement: nil,
starting_after: nil,
type: nil
); end
end
class UpdateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
sig {
params(expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String])))).void
}
def initialize(expand: nil, metadata: nil); end
end
class RefundParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The total amount to attempt to refund. This amount is in the provided currency, or defaults to the cards currency, and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(T.nilable(Integer)) }
attr_accessor :refund_amount
sig { params(expand: T.nilable(T::Array[String]), refund_amount: T.nilable(Integer)).void }
def initialize(expand: nil, refund_amount: nil); end
end
class CreateForceCaptureParams < Stripe::RequestParams
class MerchantData < Stripe::RequestParams
# A categorization of the seller's type of business. See our [merchant categories guide](https://stripe.com/docs/issuing/merchant-categories) for a list of possible values.
sig { returns(T.nilable(String)) }
attr_accessor :category
# City where the seller is located
sig { returns(T.nilable(String)) }
attr_accessor :city
# Country where the seller is located
sig { returns(T.nilable(String)) }
attr_accessor :country
# Name of the seller
sig { returns(T.nilable(String)) }
attr_accessor :name
# Identifier assigned to the seller by the card network. Different card networks may assign different network_id fields to the same merchant.
sig { returns(T.nilable(String)) }
attr_accessor :network_id
# Postal code where the seller is located
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State where the seller is located
sig { returns(T.nilable(String)) }
attr_accessor :state
# An ID assigned by the seller to the location of the sale.
sig { returns(T.nilable(String)) }
attr_accessor :terminal_id
# URL provided by the merchant on a 3DS request
sig { returns(T.nilable(String)) }
attr_accessor :url
sig {
params(category: T.nilable(String), city: T.nilable(String), country: T.nilable(String), name: T.nilable(String), network_id: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), terminal_id: T.nilable(String), url: T.nilable(String)).void
}
def initialize(
category: nil,
city: nil,
country: nil,
name: nil,
network_id: nil,
postal_code: nil,
state: nil,
terminal_id: nil,
url: nil
); end
end
class PurchaseDetails < Stripe::RequestParams
class Fleet < Stripe::RequestParams
class CardholderPromptData < Stripe::RequestParams
# Driver ID.
sig { returns(T.nilable(String)) }
attr_accessor :driver_id
# Odometer reading.
sig { returns(T.nilable(Integer)) }
attr_accessor :odometer
# An alphanumeric ID. This field is used when a vehicle ID, driver ID, or generic ID is entered by the cardholder, but the merchant or card network did not specify the prompt type.
sig { returns(T.nilable(String)) }
attr_accessor :unspecified_id
# User ID.
sig { returns(T.nilable(String)) }
attr_accessor :user_id
# Vehicle number.
sig { returns(T.nilable(String)) }
attr_accessor :vehicle_number
sig {
params(driver_id: T.nilable(String), odometer: T.nilable(Integer), unspecified_id: T.nilable(String), user_id: T.nilable(String), vehicle_number: T.nilable(String)).void
}
def initialize(
driver_id: nil,
odometer: nil,
unspecified_id: nil,
user_id: nil,
vehicle_number: nil
); end
end
class ReportedBreakdown < Stripe::RequestParams
class Fuel < Stripe::RequestParams
# Gross fuel amount that should equal Fuel Volume multipled by Fuel Unit Cost, inclusive of taxes.
sig { returns(T.nilable(String)) }
attr_accessor :gross_amount_decimal
sig { params(gross_amount_decimal: T.nilable(String)).void }
def initialize(gross_amount_decimal: nil); end
end
class NonFuel < Stripe::RequestParams
# Gross non-fuel amount that should equal the sum of the line items, inclusive of taxes.
sig { returns(T.nilable(String)) }
attr_accessor :gross_amount_decimal
sig { params(gross_amount_decimal: T.nilable(String)).void }
def initialize(gross_amount_decimal: nil); end
end
class Tax < Stripe::RequestParams
# Amount of state or provincial Sales Tax included in the transaction amount. Null if not reported by merchant or not subject to tax.
sig { returns(T.nilable(String)) }
attr_accessor :local_amount_decimal
# Amount of national Sales Tax or VAT included in the transaction amount. Null if not reported by merchant or not subject to tax.
sig { returns(T.nilable(String)) }
attr_accessor :national_amount_decimal
sig {
params(local_amount_decimal: T.nilable(String), national_amount_decimal: T.nilable(String)).void
}
def initialize(local_amount_decimal: nil, national_amount_decimal: nil); end
end
# Breakdown of fuel portion of the purchase.
sig {
returns(T.nilable(::Stripe::Issuing::Transaction::CreateForceCaptureParams::PurchaseDetails::Fleet::ReportedBreakdown::Fuel))
}
attr_accessor :fuel
# Breakdown of non-fuel portion of the purchase.
sig {
returns(T.nilable(::Stripe::Issuing::Transaction::CreateForceCaptureParams::PurchaseDetails::Fleet::ReportedBreakdown::NonFuel))
}
attr_accessor :non_fuel
# Information about tax included in this transaction.
sig {
returns(T.nilable(::Stripe::Issuing::Transaction::CreateForceCaptureParams::PurchaseDetails::Fleet::ReportedBreakdown::Tax))
}
attr_accessor :tax
sig {
params(fuel: T.nilable(::Stripe::Issuing::Transaction::CreateForceCaptureParams::PurchaseDetails::Fleet::ReportedBreakdown::Fuel), non_fuel: T.nilable(::Stripe::Issuing::Transaction::CreateForceCaptureParams::PurchaseDetails::Fleet::ReportedBreakdown::NonFuel), tax: T.nilable(::Stripe::Issuing::Transaction::CreateForceCaptureParams::PurchaseDetails::Fleet::ReportedBreakdown::Tax)).void
}
def initialize(fuel: nil, non_fuel: nil, tax: nil); end
end
# Answers to prompts presented to the cardholder at the point of sale. Prompted fields vary depending on the configuration of your physical fleet cards. Typical points of sale support only numeric entry.
sig {
returns(T.nilable(::Stripe::Issuing::Transaction::CreateForceCaptureParams::PurchaseDetails::Fleet::CardholderPromptData))
}
attr_accessor :cardholder_prompt_data
# The type of purchase. One of `fuel_purchase`, `non_fuel_purchase`, or `fuel_and_non_fuel_purchase`.
sig { returns(T.nilable(String)) }
attr_accessor :purchase_type
# More information about the total amount. This information is not guaranteed to be accurate as some merchants may provide unreliable data.
sig {
returns(T.nilable(::Stripe::Issuing::Transaction::CreateForceCaptureParams::PurchaseDetails::Fleet::ReportedBreakdown))
}
attr_accessor :reported_breakdown
# The type of fuel service. One of `non_fuel_transaction`, `full_service`, or `self_service`.
sig { returns(T.nilable(String)) }
attr_accessor :service_type
sig {
params(cardholder_prompt_data: T.nilable(::Stripe::Issuing::Transaction::CreateForceCaptureParams::PurchaseDetails::Fleet::CardholderPromptData), purchase_type: T.nilable(String), reported_breakdown: T.nilable(::Stripe::Issuing::Transaction::CreateForceCaptureParams::PurchaseDetails::Fleet::ReportedBreakdown), service_type: T.nilable(String)).void
}
def initialize(
cardholder_prompt_data: nil,
purchase_type: nil,
reported_breakdown: nil,
service_type: nil
); end
end
class Flight < Stripe::RequestParams
class Segment < Stripe::RequestParams
# The three-letter IATA airport code of the flight's destination.
sig { returns(T.nilable(String)) }
attr_accessor :arrival_airport_code
# The airline carrier code.
sig { returns(T.nilable(String)) }
attr_accessor :carrier
# The three-letter IATA airport code that the flight departed from.
sig { returns(T.nilable(String)) }
attr_accessor :departure_airport_code
# The flight number.
sig { returns(T.nilable(String)) }
attr_accessor :flight_number
# The flight's service class.
sig { returns(T.nilable(String)) }
attr_accessor :service_class
# Whether a stopover is allowed on this flight.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :stopover_allowed
sig {
params(arrival_airport_code: T.nilable(String), carrier: T.nilable(String), departure_airport_code: T.nilable(String), flight_number: T.nilable(String), service_class: T.nilable(String), stopover_allowed: T.nilable(T::Boolean)).void
}
def initialize(
arrival_airport_code: nil,
carrier: nil,
departure_airport_code: nil,
flight_number: nil,
service_class: nil,
stopover_allowed: nil
); end
end
# The time that the flight departed.
sig { returns(T.nilable(Integer)) }
attr_accessor :departure_at
# The name of the passenger.
sig { returns(T.nilable(String)) }
attr_accessor :passenger_name
# Whether the ticket is refundable.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :refundable
# The legs of the trip.
sig {
returns(T.nilable(T::Array[::Stripe::Issuing::Transaction::CreateForceCaptureParams::PurchaseDetails::Flight::Segment]))
}
attr_accessor :segments
# The travel agency that issued the ticket.
sig { returns(T.nilable(String)) }
attr_accessor :travel_agency
sig {
params(departure_at: T.nilable(Integer), passenger_name: T.nilable(String), refundable: T.nilable(T::Boolean), segments: T.nilable(T::Array[::Stripe::Issuing::Transaction::CreateForceCaptureParams::PurchaseDetails::Flight::Segment]), travel_agency: T.nilable(String)).void
}
def initialize(
departure_at: nil,
passenger_name: nil,
refundable: nil,
segments: nil,
travel_agency: nil
); end
end
class Fuel < Stripe::RequestParams
# [Conexxus Payment System Product Code](https://www.conexxus.org/conexxus-payment-system-product-codes) identifying the primary fuel product purchased.
sig { returns(T.nilable(String)) }
attr_accessor :industry_product_code
# The quantity of `unit`s of fuel that was dispensed, represented as a decimal string with at most 12 decimal places.
sig { returns(T.nilable(String)) }
attr_accessor :quantity_decimal
# The type of fuel that was purchased. One of `diesel`, `unleaded_plus`, `unleaded_regular`, `unleaded_super`, or `other`.
sig { returns(T.nilable(String)) }
attr_accessor :type
# The units for `quantity_decimal`. One of `charging_minute`, `imperial_gallon`, `kilogram`, `kilowatt_hour`, `liter`, `pound`, `us_gallon`, or `other`.
sig { returns(T.nilable(String)) }
attr_accessor :unit
# The cost in cents per each unit of fuel, represented as a decimal string with at most 12 decimal places.
sig { returns(T.nilable(String)) }
attr_accessor :unit_cost_decimal
sig {
params(industry_product_code: T.nilable(String), quantity_decimal: T.nilable(String), type: T.nilable(String), unit: T.nilable(String), unit_cost_decimal: T.nilable(String)).void
}
def initialize(
industry_product_code: nil,
quantity_decimal: nil,
type: nil,
unit: nil,
unit_cost_decimal: nil
); end
end
class Lodging < Stripe::RequestParams
# The time of checking into the lodging.
sig { returns(T.nilable(Integer)) }
attr_accessor :check_in_at
# The number of nights stayed at the lodging.
sig { returns(T.nilable(Integer)) }
attr_accessor :nights
sig { params(check_in_at: T.nilable(Integer), nights: T.nilable(Integer)).void }
def initialize(check_in_at: nil, nights: nil); end
end
class Receipt < Stripe::RequestParams
# Attribute for param field description
sig { returns(T.nilable(String)) }
attr_accessor :description
# Attribute for param field quantity
sig { returns(T.nilable(String)) }
attr_accessor :quantity
# Attribute for param field total
sig { returns(T.nilable(Integer)) }
attr_accessor :total
# Attribute for param field unit_cost
sig { returns(T.nilable(Integer)) }
attr_accessor :unit_cost
sig {
params(description: T.nilable(String), quantity: T.nilable(String), total: T.nilable(Integer), unit_cost: T.nilable(Integer)).void
}
def initialize(description: nil, quantity: nil, total: nil, unit_cost: nil); end
end
# Fleet-specific information for transactions using Fleet cards.
sig {
returns(T.nilable(::Stripe::Issuing::Transaction::CreateForceCaptureParams::PurchaseDetails::Fleet))
}
attr_accessor :fleet
# Information about the flight that was purchased with this transaction.
sig {
returns(T.nilable(::Stripe::Issuing::Transaction::CreateForceCaptureParams::PurchaseDetails::Flight))
}
attr_accessor :flight
# Information about fuel that was purchased with this transaction.
sig {
returns(T.nilable(::Stripe::Issuing::Transaction::CreateForceCaptureParams::PurchaseDetails::Fuel))
}
attr_accessor :fuel
# Information about lodging that was purchased with this transaction.
sig {
returns(T.nilable(::Stripe::Issuing::Transaction::CreateForceCaptureParams::PurchaseDetails::Lodging))
}
attr_accessor :lodging
# The line items in the purchase.
sig {
returns(T.nilable(T::Array[::Stripe::Issuing::Transaction::CreateForceCaptureParams::PurchaseDetails::Receipt]))
}
attr_accessor :receipt
# A merchant-specific order number.
sig { returns(T.nilable(String)) }
attr_accessor :reference
sig {
params(fleet: T.nilable(::Stripe::Issuing::Transaction::CreateForceCaptureParams::PurchaseDetails::Fleet), flight: T.nilable(::Stripe::Issuing::Transaction::CreateForceCaptureParams::PurchaseDetails::Flight), fuel: T.nilable(::Stripe::Issuing::Transaction::CreateForceCaptureParams::PurchaseDetails::Fuel), lodging: T.nilable(::Stripe::Issuing::Transaction::CreateForceCaptureParams::PurchaseDetails::Lodging), receipt: T.nilable(T::Array[::Stripe::Issuing::Transaction::CreateForceCaptureParams::PurchaseDetails::Receipt]), reference: T.nilable(String)).void
}
def initialize(
fleet: nil,
flight: nil,
fuel: nil,
lodging: nil,
receipt: nil,
reference: nil
); end
end
# The total amount to attempt to capture. This amount is in the provided currency, or defaults to the cards currency, and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(Integer) }
attr_accessor :amount
# Card associated with this transaction.
sig { returns(String) }
attr_accessor :card
# The currency of the capture. If not provided, defaults to the currency of the card. 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).
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Details about the seller (grocery store, e-commerce website, etc.) where the card authorization happened.
sig {
returns(T.nilable(::Stripe::Issuing::Transaction::CreateForceCaptureParams::MerchantData))
}
attr_accessor :merchant_data
# Additional purchase information that is optionally provided by the merchant.
sig {
returns(T.nilable(::Stripe::Issuing::Transaction::CreateForceCaptureParams::PurchaseDetails))
}
attr_accessor :purchase_details
sig {
params(amount: Integer, card: String, currency: T.nilable(String), expand: T.nilable(T::Array[String]), merchant_data: T.nilable(::Stripe::Issuing::Transaction::CreateForceCaptureParams::MerchantData), purchase_details: T.nilable(::Stripe::Issuing::Transaction::CreateForceCaptureParams::PurchaseDetails)).void
}
def initialize(
amount: nil,
card: nil,
currency: nil,
expand: nil,
merchant_data: nil,
purchase_details: nil
); end
end
class CreateUnlinkedRefundParams < Stripe::RequestParams
class MerchantData < Stripe::RequestParams
# A categorization of the seller's type of business. See our [merchant categories guide](https://stripe.com/docs/issuing/merchant-categories) for a list of possible values.
sig { returns(T.nilable(String)) }
attr_accessor :category
# City where the seller is located
sig { returns(T.nilable(String)) }
attr_accessor :city
# Country where the seller is located
sig { returns(T.nilable(String)) }
attr_accessor :country
# Name of the seller
sig { returns(T.nilable(String)) }
attr_accessor :name
# Identifier assigned to the seller by the card network. Different card networks may assign different network_id fields to the same merchant.
sig { returns(T.nilable(String)) }
attr_accessor :network_id
# Postal code where the seller is located
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State where the seller is located
sig { returns(T.nilable(String)) }
attr_accessor :state
# An ID assigned by the seller to the location of the sale.
sig { returns(T.nilable(String)) }
attr_accessor :terminal_id
# URL provided by the merchant on a 3DS request
sig { returns(T.nilable(String)) }
attr_accessor :url
sig {
params(category: T.nilable(String), city: T.nilable(String), country: T.nilable(String), name: T.nilable(String), network_id: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), terminal_id: T.nilable(String), url: T.nilable(String)).void
}
def initialize(
category: nil,
city: nil,
country: nil,
name: nil,
network_id: nil,
postal_code: nil,
state: nil,
terminal_id: nil,
url: nil
); end
end
class PurchaseDetails < Stripe::RequestParams
class Fleet < Stripe::RequestParams
class CardholderPromptData < Stripe::RequestParams
# Driver ID.
sig { returns(T.nilable(String)) }
attr_accessor :driver_id
# Odometer reading.
sig { returns(T.nilable(Integer)) }
attr_accessor :odometer
# An alphanumeric ID. This field is used when a vehicle ID, driver ID, or generic ID is entered by the cardholder, but the merchant or card network did not specify the prompt type.
sig { returns(T.nilable(String)) }
attr_accessor :unspecified_id
# User ID.
sig { returns(T.nilable(String)) }
attr_accessor :user_id
# Vehicle number.
sig { returns(T.nilable(String)) }
attr_accessor :vehicle_number
sig {
params(driver_id: T.nilable(String), odometer: T.nilable(Integer), unspecified_id: T.nilable(String), user_id: T.nilable(String), vehicle_number: T.nilable(String)).void
}
def initialize(
driver_id: nil,
odometer: nil,
unspecified_id: nil,
user_id: nil,
vehicle_number: nil
); end
end
class ReportedBreakdown < Stripe::RequestParams
class Fuel < Stripe::RequestParams
# Gross fuel amount that should equal Fuel Volume multipled by Fuel Unit Cost, inclusive of taxes.
sig { returns(T.nilable(String)) }
attr_accessor :gross_amount_decimal
sig { params(gross_amount_decimal: T.nilable(String)).void }
def initialize(gross_amount_decimal: nil); end
end
class NonFuel < Stripe::RequestParams
# Gross non-fuel amount that should equal the sum of the line items, inclusive of taxes.
sig { returns(T.nilable(String)) }
attr_accessor :gross_amount_decimal
sig { params(gross_amount_decimal: T.nilable(String)).void }
def initialize(gross_amount_decimal: nil); end
end
class Tax < Stripe::RequestParams
# Amount of state or provincial Sales Tax included in the transaction amount. Null if not reported by merchant or not subject to tax.
sig { returns(T.nilable(String)) }
attr_accessor :local_amount_decimal
# Amount of national Sales Tax or VAT included in the transaction amount. Null if not reported by merchant or not subject to tax.
sig { returns(T.nilable(String)) }
attr_accessor :national_amount_decimal
sig {
params(local_amount_decimal: T.nilable(String), national_amount_decimal: T.nilable(String)).void
}
def initialize(local_amount_decimal: nil, national_amount_decimal: nil); end
end
# Breakdown of fuel portion of the purchase.
sig {
returns(T.nilable(::Stripe::Issuing::Transaction::CreateUnlinkedRefundParams::PurchaseDetails::Fleet::ReportedBreakdown::Fuel))
}
attr_accessor :fuel
# Breakdown of non-fuel portion of the purchase.
sig {
returns(T.nilable(::Stripe::Issuing::Transaction::CreateUnlinkedRefundParams::PurchaseDetails::Fleet::ReportedBreakdown::NonFuel))
}
attr_accessor :non_fuel
# Information about tax included in this transaction.
sig {
returns(T.nilable(::Stripe::Issuing::Transaction::CreateUnlinkedRefundParams::PurchaseDetails::Fleet::ReportedBreakdown::Tax))
}
attr_accessor :tax
sig {
params(fuel: T.nilable(::Stripe::Issuing::Transaction::CreateUnlinkedRefundParams::PurchaseDetails::Fleet::ReportedBreakdown::Fuel), non_fuel: T.nilable(::Stripe::Issuing::Transaction::CreateUnlinkedRefundParams::PurchaseDetails::Fleet::ReportedBreakdown::NonFuel), tax: T.nilable(::Stripe::Issuing::Transaction::CreateUnlinkedRefundParams::PurchaseDetails::Fleet::ReportedBreakdown::Tax)).void
}
def initialize(fuel: nil, non_fuel: nil, tax: nil); end
end
# Answers to prompts presented to the cardholder at the point of sale. Prompted fields vary depending on the configuration of your physical fleet cards. Typical points of sale support only numeric entry.
sig {
returns(T.nilable(::Stripe::Issuing::Transaction::CreateUnlinkedRefundParams::PurchaseDetails::Fleet::CardholderPromptData))
}
attr_accessor :cardholder_prompt_data
# The type of purchase. One of `fuel_purchase`, `non_fuel_purchase`, or `fuel_and_non_fuel_purchase`.
sig { returns(T.nilable(String)) }
attr_accessor :purchase_type
# More information about the total amount. This information is not guaranteed to be accurate as some merchants may provide unreliable data.
sig {
returns(T.nilable(::Stripe::Issuing::Transaction::CreateUnlinkedRefundParams::PurchaseDetails::Fleet::ReportedBreakdown))
}
attr_accessor :reported_breakdown
# The type of fuel service. One of `non_fuel_transaction`, `full_service`, or `self_service`.
sig { returns(T.nilable(String)) }
attr_accessor :service_type
sig {
params(cardholder_prompt_data: T.nilable(::Stripe::Issuing::Transaction::CreateUnlinkedRefundParams::PurchaseDetails::Fleet::CardholderPromptData), purchase_type: T.nilable(String), reported_breakdown: T.nilable(::Stripe::Issuing::Transaction::CreateUnlinkedRefundParams::PurchaseDetails::Fleet::ReportedBreakdown), service_type: T.nilable(String)).void
}
def initialize(
cardholder_prompt_data: nil,
purchase_type: nil,
reported_breakdown: nil,
service_type: nil
); end
end
class Flight < Stripe::RequestParams
class Segment < Stripe::RequestParams
# The three-letter IATA airport code of the flight's destination.
sig { returns(T.nilable(String)) }
attr_accessor :arrival_airport_code
# The airline carrier code.
sig { returns(T.nilable(String)) }
attr_accessor :carrier
# The three-letter IATA airport code that the flight departed from.
sig { returns(T.nilable(String)) }
attr_accessor :departure_airport_code
# The flight number.
sig { returns(T.nilable(String)) }
attr_accessor :flight_number
# The flight's service class.
sig { returns(T.nilable(String)) }
attr_accessor :service_class
# Whether a stopover is allowed on this flight.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :stopover_allowed
sig {
params(arrival_airport_code: T.nilable(String), carrier: T.nilable(String), departure_airport_code: T.nilable(String), flight_number: T.nilable(String), service_class: T.nilable(String), stopover_allowed: T.nilable(T::Boolean)).void
}
def initialize(
arrival_airport_code: nil,
carrier: nil,
departure_airport_code: nil,
flight_number: nil,
service_class: nil,
stopover_allowed: nil
); end
end
# The time that the flight departed.
sig { returns(T.nilable(Integer)) }
attr_accessor :departure_at
# The name of the passenger.
sig { returns(T.nilable(String)) }
attr_accessor :passenger_name
# Whether the ticket is refundable.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :refundable
# The legs of the trip.
sig {
returns(T.nilable(T::Array[::Stripe::Issuing::Transaction::CreateUnlinkedRefundParams::PurchaseDetails::Flight::Segment]))
}
attr_accessor :segments
# The travel agency that issued the ticket.
sig { returns(T.nilable(String)) }
attr_accessor :travel_agency
sig {
params(departure_at: T.nilable(Integer), passenger_name: T.nilable(String), refundable: T.nilable(T::Boolean), segments: T.nilable(T::Array[::Stripe::Issuing::Transaction::CreateUnlinkedRefundParams::PurchaseDetails::Flight::Segment]), travel_agency: T.nilable(String)).void
}
def initialize(
departure_at: nil,
passenger_name: nil,
refundable: nil,
segments: nil,
travel_agency: nil
); end
end
class Fuel < Stripe::RequestParams
# [Conexxus Payment System Product Code](https://www.conexxus.org/conexxus-payment-system-product-codes) identifying the primary fuel product purchased.
sig { returns(T.nilable(String)) }
attr_accessor :industry_product_code
# The quantity of `unit`s of fuel that was dispensed, represented as a decimal string with at most 12 decimal places.
sig { returns(T.nilable(String)) }
attr_accessor :quantity_decimal
# The type of fuel that was purchased. One of `diesel`, `unleaded_plus`, `unleaded_regular`, `unleaded_super`, or `other`.
sig { returns(T.nilable(String)) }
attr_accessor :type
# The units for `quantity_decimal`. One of `charging_minute`, `imperial_gallon`, `kilogram`, `kilowatt_hour`, `liter`, `pound`, `us_gallon`, or `other`.
sig { returns(T.nilable(String)) }
attr_accessor :unit
# The cost in cents per each unit of fuel, represented as a decimal string with at most 12 decimal places.
sig { returns(T.nilable(String)) }
attr_accessor :unit_cost_decimal
sig {
params(industry_product_code: T.nilable(String), quantity_decimal: T.nilable(String), type: T.nilable(String), unit: T.nilable(String), unit_cost_decimal: T.nilable(String)).void
}
def initialize(
industry_product_code: nil,
quantity_decimal: nil,
type: nil,
unit: nil,
unit_cost_decimal: nil
); end
end
class Lodging < Stripe::RequestParams
# The time of checking into the lodging.
sig { returns(T.nilable(Integer)) }
attr_accessor :check_in_at
# The number of nights stayed at the lodging.
sig { returns(T.nilable(Integer)) }
attr_accessor :nights
sig { params(check_in_at: T.nilable(Integer), nights: T.nilable(Integer)).void }
def initialize(check_in_at: nil, nights: nil); end
end
class Receipt < Stripe::RequestParams
# Attribute for param field description
sig { returns(T.nilable(String)) }
attr_accessor :description
# Attribute for param field quantity
sig { returns(T.nilable(String)) }
attr_accessor :quantity
# Attribute for param field total
sig { returns(T.nilable(Integer)) }
attr_accessor :total
# Attribute for param field unit_cost
sig { returns(T.nilable(Integer)) }
attr_accessor :unit_cost
sig {
params(description: T.nilable(String), quantity: T.nilable(String), total: T.nilable(Integer), unit_cost: T.nilable(Integer)).void
}
def initialize(description: nil, quantity: nil, total: nil, unit_cost: nil); end
end
# Fleet-specific information for transactions using Fleet cards.
sig {
returns(T.nilable(::Stripe::Issuing::Transaction::CreateUnlinkedRefundParams::PurchaseDetails::Fleet))
}
attr_accessor :fleet
# Information about the flight that was purchased with this transaction.
sig {
returns(T.nilable(::Stripe::Issuing::Transaction::CreateUnlinkedRefundParams::PurchaseDetails::Flight))
}
attr_accessor :flight
# Information about fuel that was purchased with this transaction.
sig {
returns(T.nilable(::Stripe::Issuing::Transaction::CreateUnlinkedRefundParams::PurchaseDetails::Fuel))
}
attr_accessor :fuel
# Information about lodging that was purchased with this transaction.
sig {
returns(T.nilable(::Stripe::Issuing::Transaction::CreateUnlinkedRefundParams::PurchaseDetails::Lodging))
}
attr_accessor :lodging
# The line items in the purchase.
sig {
returns(T.nilable(T::Array[::Stripe::Issuing::Transaction::CreateUnlinkedRefundParams::PurchaseDetails::Receipt]))
}
attr_accessor :receipt
# A merchant-specific order number.
sig { returns(T.nilable(String)) }
attr_accessor :reference
sig {
params(fleet: T.nilable(::Stripe::Issuing::Transaction::CreateUnlinkedRefundParams::PurchaseDetails::Fleet), flight: T.nilable(::Stripe::Issuing::Transaction::CreateUnlinkedRefundParams::PurchaseDetails::Flight), fuel: T.nilable(::Stripe::Issuing::Transaction::CreateUnlinkedRefundParams::PurchaseDetails::Fuel), lodging: T.nilable(::Stripe::Issuing::Transaction::CreateUnlinkedRefundParams::PurchaseDetails::Lodging), receipt: T.nilable(T::Array[::Stripe::Issuing::Transaction::CreateUnlinkedRefundParams::PurchaseDetails::Receipt]), reference: T.nilable(String)).void
}
def initialize(
fleet: nil,
flight: nil,
fuel: nil,
lodging: nil,
receipt: nil,
reference: nil
); end
end
# The total amount to attempt to refund. This amount is in the provided currency, or defaults to the cards currency, and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(Integer) }
attr_accessor :amount
# Card associated with this unlinked refund transaction.
sig { returns(String) }
attr_accessor :card
# The currency of the unlinked refund. If not provided, defaults to the currency of the card. 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).
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Details about the seller (grocery store, e-commerce website, etc.) where the card authorization happened.
sig {
returns(T.nilable(::Stripe::Issuing::Transaction::CreateUnlinkedRefundParams::MerchantData))
}
attr_accessor :merchant_data
# Additional purchase information that is optionally provided by the merchant.
sig {
returns(T.nilable(::Stripe::Issuing::Transaction::CreateUnlinkedRefundParams::PurchaseDetails))
}
attr_accessor :purchase_details
sig {
params(amount: Integer, card: String, currency: T.nilable(String), expand: T.nilable(T::Array[String]), merchant_data: T.nilable(::Stripe::Issuing::Transaction::CreateUnlinkedRefundParams::MerchantData), purchase_details: T.nilable(::Stripe::Issuing::Transaction::CreateUnlinkedRefundParams::PurchaseDetails)).void
}
def initialize(
amount: nil,
card: nil,
currency: nil,
expand: nil,
merchant_data: nil,
purchase_details: nil
); end
end
# Returns a list of Issuing Transaction objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.
sig {
params(params: T.any(::Stripe::Issuing::Transaction::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Updates the specified Issuing Transaction object by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
sig {
params(transaction: String, params: T.any(::Stripe::Issuing::Transaction::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Transaction)
}
def self.update(transaction, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
# A line item.
class LineItem < APIResource
class AdjustableQuantity < Stripe::StripeObject
# Attribute for field enabled
sig { returns(T::Boolean) }
attr_reader :enabled
# Attribute for field maximum
sig { returns(T.nilable(Integer)) }
attr_reader :maximum
# Attribute for field minimum
sig { returns(T.nilable(Integer)) }
attr_reader :minimum
end
class Discount < Stripe::StripeObject
# The amount discounted.
sig { returns(Integer) }
attr_reader :amount
# A discount represents the actual application of a [coupon](https://stripe.com/docs/api#coupons) or [promotion code](https://stripe.com/docs/api#promotion_codes).
# It contains information about when the discount began, when it will end, and what it is applied to.
#
# Related guide: [Applying discounts to subscriptions](https://stripe.com/docs/billing/subscriptions/discounts)
sig { returns(Stripe::Discount) }
attr_reader :discount
end
class Display < Stripe::StripeObject
# Attribute for field description
sig { returns(T.nilable(String)) }
attr_reader :description
# Attribute for field images
sig { returns(T::Array[String]) }
attr_reader :images
# Attribute for field name
sig { returns(String) }
attr_reader :name
end
class TaxCalculationReference < Stripe::StripeObject
# The calculation identifier for tax calculation response.
sig { returns(T.nilable(String)) }
attr_reader :calculation_id
# The calculation identifier for tax calculation response line item.
sig { returns(T.nilable(String)) }
attr_reader :calculation_item_id
end
class Tax < Stripe::StripeObject
# Amount of tax applied for this rate.
sig { returns(Integer) }
attr_reader :amount
# Tax rates can be applied to [invoices](/invoicing/taxes/tax-rates), [subscriptions](/billing/taxes/tax-rates) and [Checkout Sessions](/payments/checkout/use-manual-tax-rates) to collect tax.
#
# Related guide: [Tax rates](/billing/taxes/tax-rates)
sig { returns(Stripe::TaxRate) }
attr_reader :rate
# 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.
sig { returns(T.nilable(String)) }
attr_reader :taxability_reason
# The amount on which tax is calculated, in cents (or local equivalent).
sig { returns(T.nilable(Integer)) }
attr_reader :taxable_amount
end
# Attribute for field adjustable_quantity
sig { returns(T.nilable(AdjustableQuantity)) }
attr_reader :adjustable_quantity
# Total discount amount applied. If no discounts were applied, defaults to 0.
sig { returns(Integer) }
attr_reader :amount_discount
# Total before any discounts or taxes are applied.
sig { returns(Integer) }
attr_reader :amount_subtotal
# Total tax amount applied. If no tax was applied, defaults to 0.
sig { returns(Integer) }
attr_reader :amount_tax
# Total after discounts and taxes.
sig { returns(Integer) }
attr_reader :amount_total
# 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).
sig { returns(String) }
attr_reader :currency
# An arbitrary string attached to the object. Often useful for displaying to users. Defaults to product name.
sig { returns(T.nilable(String)) }
attr_reader :description
# The discounts applied to the line item.
sig { returns(T::Array[Discount]) }
attr_reader :discounts
# Attribute for field display
sig { returns(Display) }
attr_reader :display
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# 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.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The price used to generate the line item.
sig { returns(T.nilable(Stripe::Price)) }
attr_reader :price
# The ID of the product for this line item.
#
# This will always be the same as `price.product`.
sig { returns(T.any(String, Stripe::Product)) }
attr_reader :product
# The quantity of products being purchased.
sig { returns(T.nilable(Integer)) }
attr_reader :quantity
# The tax calculation identifiers of the line item.
sig { returns(T.nilable(TaxCalculationReference)) }
attr_reader :tax_calculation_reference
# The taxes applied to the line item.
sig { returns(T::Array[Tax]) }
attr_reader :taxes
end
end
# typed: true
module Stripe
# Invoice Line Items represent the individual lines within an [invoice](https://stripe.com/docs/api/invoices) and only exist within the context of an invoice.
#
# Each line item is backed by either an [invoice item](https://stripe.com/docs/api/invoiceitems) or a [subscription item](https://stripe.com/docs/api/subscription_items).
class InvoiceLineItem < APIResource
class DiscountAmount < Stripe::StripeObject
# The amount, in cents (or local equivalent), of the discount.
sig { returns(Integer) }
attr_reader :amount
# The discount that was applied to get this discount amount.
sig { returns(T.any(String, Stripe::Discount)) }
attr_reader :discount
end
class MarginAmount < Stripe::StripeObject
# The amount, in cents (or local equivalent), of the reduction in line item amount.
sig { returns(Integer) }
attr_reader :amount
# The margin that was applied to get this margin amount.
sig { returns(T.any(String, Stripe::Margin)) }
attr_reader :margin
end
class Parent < Stripe::StripeObject
class InvoiceItemDetails < Stripe::StripeObject
class ProrationDetails < Stripe::StripeObject
class CreditedItems < Stripe::StripeObject
# Invoice containing the credited invoice line items
sig { returns(String) }
attr_reader :invoice
# Credited invoice line items
sig { returns(T::Array[String]) }
attr_reader :invoice_line_items
end
# For a credit proration `line_item`, the original debit line_items to which the credit proration applies.
sig { returns(T.nilable(CreditedItems)) }
attr_reader :credited_items
end
# The invoice item that generated this line item
sig { returns(String) }
attr_reader :invoice_item
# Whether this is a proration
sig { returns(T::Boolean) }
attr_reader :proration
# Additional details for proration line items
sig { returns(T.nilable(ProrationDetails)) }
attr_reader :proration_details
# The subscription that the invoice item belongs to
sig { returns(T.nilable(String)) }
attr_reader :subscription
end
class SubscriptionItemDetails < Stripe::StripeObject
class ProrationDetails < Stripe::StripeObject
class CreditedItems < Stripe::StripeObject
# Invoice containing the credited invoice line items
sig { returns(String) }
attr_reader :invoice
# Credited invoice line items
sig { returns(T::Array[String]) }
attr_reader :invoice_line_items
end
# For a credit proration `line_item`, the original debit line_items to which the credit proration applies.
sig { returns(T.nilable(CreditedItems)) }
attr_reader :credited_items
end
# The invoice item that generated this line item
sig { returns(T.nilable(String)) }
attr_reader :invoice_item
# Whether this is a proration
sig { returns(T::Boolean) }
attr_reader :proration
# Additional details for proration line items
sig { returns(T.nilable(ProrationDetails)) }
attr_reader :proration_details
# The subscription that the subscription item belongs to
sig { returns(T.nilable(String)) }
attr_reader :subscription
# The subscription item that generated this line item
sig { returns(String) }
attr_reader :subscription_item
end
# Details about the invoice item that generated this line item
sig { returns(T.nilable(InvoiceItemDetails)) }
attr_reader :invoice_item_details
# Details about the subscription item that generated this line item
sig { returns(T.nilable(SubscriptionItemDetails)) }
attr_reader :subscription_item_details
# The type of parent that generated this line item
sig { returns(String) }
attr_reader :type
end
class Period < Stripe::StripeObject
# The end of the period, which must be greater than or equal to the start. This value is inclusive.
sig { returns(Integer) }
attr_reader :end
# The start of the period. This value is inclusive.
sig { returns(Integer) }
attr_reader :start
end
class PretaxCreditAmount < Stripe::StripeObject
# The amount, in cents (or local equivalent), of the pretax credit amount.
sig { returns(Integer) }
attr_reader :amount
# The credit balance transaction that was applied to get this pretax credit amount.
sig { returns(T.nilable(T.any(String, Stripe::Billing::CreditBalanceTransaction))) }
attr_reader :credit_balance_transaction
# The discount that was applied to get this pretax credit amount.
sig { returns(T.any(String, Stripe::Discount)) }
attr_reader :discount
# The margin that was applied to get this pretax credit amount.
sig { returns(T.any(String, Stripe::Margin)) }
attr_reader :margin
# Type of the pretax credit amount referenced.
sig { returns(String) }
attr_reader :type
end
class Pricing < Stripe::StripeObject
class PriceDetails < Stripe::StripeObject
# The ID of the price this item is associated with.
sig { returns(String) }
attr_reader :price
# The ID of the product this item is associated with.
sig { returns(String) }
attr_reader :product
end
# Attribute for field price_details
sig { returns(PriceDetails) }
attr_reader :price_details
# The type of the pricing details.
sig { returns(String) }
attr_reader :type
# The unit amount (in the `currency` specified) of the item which contains a decimal value with at most 12 decimal places.
sig { returns(T.nilable(String)) }
attr_reader :unit_amount_decimal
end
class TaxCalculationReference < Stripe::StripeObject
# The calculation identifier for tax calculation response.
sig { returns(T.nilable(String)) }
attr_reader :calculation_id
# The calculation identifier for tax calculation response line item.
sig { returns(T.nilable(String)) }
attr_reader :calculation_item_id
end
class Tax < Stripe::StripeObject
class TaxRateDetails < Stripe::StripeObject
# Attribute for field tax_rate
sig { returns(String) }
attr_reader :tax_rate
end
# The amount of the tax, in cents (or local equivalent).
sig { returns(Integer) }
attr_reader :amount
# Whether this tax is inclusive or exclusive.
sig { returns(String) }
attr_reader :tax_behavior
# Additional details about the tax rate. Only present when `type` is `tax_rate_details`.
sig { returns(T.nilable(TaxRateDetails)) }
attr_reader :tax_rate_details
# 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.
sig { returns(String) }
attr_reader :taxability_reason
# The amount on which tax is calculated, in cents (or local equivalent).
sig { returns(T.nilable(Integer)) }
attr_reader :taxable_amount
# The type of tax information.
sig { returns(String) }
attr_reader :type
end
# The amount, in cents (or local equivalent).
sig { returns(Integer) }
attr_reader :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).
sig { returns(String) }
attr_reader :currency
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_reader :description
# The amount of discount calculated per discount for this line item.
sig { returns(T.nilable(T::Array[DiscountAmount])) }
attr_reader :discount_amounts
# If true, discounts will apply to this line item. Always false for prorations.
sig { returns(T::Boolean) }
attr_reader :discountable
# The discounts applied to the invoice line item. Line item discounts are applied before invoice discounts. Use `expand[]=discounts` to expand each discount.
sig { returns(T::Array[T.any(String, Stripe::Discount)]) }
attr_reader :discounts
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# The ID of the invoice that contains this line item.
sig { returns(T.nilable(String)) }
attr_reader :invoice
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# The amount of margin calculated per margin for this line item.
sig { returns(T.nilable(T::Array[MarginAmount])) }
attr_reader :margin_amounts
# The margins applied to the line item. When set, the `default_margins` on the invoice do not apply to the line item. Use `expand[]=margins` to expand each margin.
sig { returns(T.nilable(T::Array[T.any(String, Stripe::Margin)])) }
attr_reader :margins
# 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. Note that for line items with `type=subscription`, `metadata` reflects the current metadata from the subscription associated with the line item, unless the invoice line was directly updated with different metadata after creation.
sig { returns(T::Hash[String, String]) }
attr_reader :metadata
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The parent that generated this line item.
sig { returns(T.nilable(Parent)) }
attr_reader :parent
# Attribute for field period
sig { returns(Period) }
attr_reader :period
# Contains pretax credit amounts (ex: discount, credit grants, etc) that apply to this line item.
sig { returns(T.nilable(T::Array[PretaxCreditAmount])) }
attr_reader :pretax_credit_amounts
# The pricing information of the line item.
sig { returns(T.nilable(Pricing)) }
attr_reader :pricing
# The quantity of the subscription, if the line item is a subscription or a proration.
sig { returns(T.nilable(Integer)) }
attr_reader :quantity
# Attribute for field subscription
sig { returns(T.nilable(T.any(String, Stripe::Subscription))) }
attr_reader :subscription
# The tax calculation identifiers of the line item.
sig { returns(T.nilable(TaxCalculationReference)) }
attr_reader :tax_calculation_reference
# The tax information of the line item.
sig { returns(T.nilable(T::Array[Tax])) }
attr_reader :taxes
class UpdateParams < Stripe::RequestParams
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::InvoiceLineItem::UpdateParams::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::InvoiceLineItem::UpdateParams::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig { returns(T.nilable(::Stripe::InvoiceLineItem::UpdateParams::Discount::DiscountEnd)) }
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::InvoiceLineItem::UpdateParams::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class Period < Stripe::RequestParams
# The end of the period, which must be greater than or equal to the start. This value is inclusive.
sig { returns(Integer) }
attr_accessor :end
# The start of the period. This value is inclusive.
sig { returns(Integer) }
attr_accessor :start
sig { params(end_: Integer, start: Integer).void }
def initialize(end_: nil, start: nil); end
end
class PriceData < Stripe::RequestParams
class ProductData < Stripe::RequestParams
# The product's description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes.
sig { returns(T.nilable(String)) }
attr_accessor :description
# A list of up to 8 URLs of images for this product, meant to be displayable to the customer.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :images
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The product's name, meant to be displayable to the customer.
sig { returns(String) }
attr_accessor :name
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
sig { returns(T.nilable(String)) }
attr_accessor :tax_code
sig {
params(description: T.nilable(String), images: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), name: String, tax_code: T.nilable(String)).void
}
def initialize(
description: nil,
images: nil,
metadata: nil,
name: nil,
tax_code: nil
); end
end
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to. One of `product` or `product_data` is required.
sig { returns(T.nilable(String)) }
attr_accessor :product
# Data used to generate a new [Product](https://docs.stripe.com/api/products) object inline. One of `product` or `product_data` is required.
sig { returns(T.nilable(::Stripe::InvoiceLineItem::UpdateParams::PriceData::ProductData)) }
attr_accessor :product_data
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A non-negative integer in cents (or local equivalent) representing how much to charge. One of `unit_amount` or `unit_amount_decimal` is required.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, product: T.nilable(String), product_data: T.nilable(::Stripe::InvoiceLineItem::UpdateParams::PriceData::ProductData), tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
product_data: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
class Pricing < Stripe::RequestParams
# The ID of the price object.
sig { returns(T.nilable(String)) }
attr_accessor :price
sig { params(price: T.nilable(String)).void }
def initialize(price: nil); end
end
class TaxAmount < Stripe::RequestParams
class TaxRateData < Stripe::RequestParams
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# An arbitrary string attached to the tax rate for your internal use only. It will not be visible to your customers.
sig { returns(T.nilable(String)) }
attr_accessor :description
# The display name of the tax rate, which will be shown to users.
sig { returns(String) }
attr_accessor :display_name
# This specifies if the tax rate is inclusive or exclusive.
sig { returns(T::Boolean) }
attr_accessor :inclusive
# The jurisdiction for the tax rate. You can use this label field for tax reporting purposes. It also appears on your customer’s invoice.
sig { returns(T.nilable(String)) }
attr_accessor :jurisdiction
# The level of the jurisdiction that imposes this tax rate.
sig { returns(T.nilable(String)) }
attr_accessor :jurisdiction_level
# The statutory tax rate percent. This field accepts decimal values between 0 and 100 inclusive with at most 4 decimal places. To accommodate fixed-amount taxes, set the percentage to zero. Stripe will not display zero percentages on the invoice unless the `amount` of the tax is also zero.
sig { returns(Float) }
attr_accessor :percentage
# [ISO 3166-2 subdivision code](https://en.wikipedia.org/wiki/ISO_3166-2:US), without country prefix. For example, "NY" for New York, United States.
sig { returns(T.nilable(String)) }
attr_accessor :state
# The high-level tax type, such as `vat` or `sales_tax`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_type
sig {
params(country: T.nilable(String), description: T.nilable(String), display_name: String, inclusive: T::Boolean, jurisdiction: T.nilable(String), jurisdiction_level: T.nilable(String), percentage: Float, state: T.nilable(String), tax_type: T.nilable(String)).void
}
def initialize(
country: nil,
description: nil,
display_name: nil,
inclusive: nil,
jurisdiction: nil,
jurisdiction_level: nil,
percentage: nil,
state: nil,
tax_type: nil
); end
end
# The amount, in cents (or local equivalent), of the tax.
sig { returns(Integer) }
attr_accessor :amount
# Data to find or create a TaxRate object.
#
# Stripe automatically creates or reuses a TaxRate object for each tax amount. If the `tax_rate_data` exactly matches a previous value, Stripe will reuse the TaxRate object. TaxRate objects created automatically by Stripe are immediately archived, do not appear in the line item’s `tax_rates`, and cannot be directly added to invoices, payments, or line items.
sig { returns(::Stripe::InvoiceLineItem::UpdateParams::TaxAmount::TaxRateData) }
attr_accessor :tax_rate_data
# The reasoning behind this tax, for example, if the product is tax exempt.
sig { returns(T.nilable(String)) }
attr_accessor :taxability_reason
# The amount on which tax is calculated, in cents (or local equivalent).
sig { returns(Integer) }
attr_accessor :taxable_amount
sig {
params(amount: Integer, tax_rate_data: ::Stripe::InvoiceLineItem::UpdateParams::TaxAmount::TaxRateData, taxability_reason: T.nilable(String), taxable_amount: Integer).void
}
def initialize(
amount: nil,
tax_rate_data: nil,
taxability_reason: nil,
taxable_amount: nil
); end
end
# The integer amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. If you want to apply a credit to the customer's account, pass a negative amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# An arbitrary string which you can attach to the invoice item. The description is displayed in the invoice for easy tracking.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Controls whether discounts apply to this line item. Defaults to false for prorations or negative line items, and true for all other line items. Cannot be set to true for prorations.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :discountable
# The coupons, promotion codes & existing discounts which apply to the line item. Item discounts are applied before invoice discounts. Pass an empty string to remove previously-defined discounts.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceLineItem::UpdateParams::Discount]))))
}
attr_accessor :discounts
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The IDs of the margins to apply to the line item. When set, the `default_margins` on the invoice do not apply to this line item.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :margins
# 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`. For [type=subscription](https://stripe.com/docs/api/invoices/line_item#invoice_line_item_object-type) line items, the incoming metadata specified on the request is directly used to set this value, in contrast to [type=invoiceitem](api/invoices/line_item#invoice_line_item_object-type) line items, where any existing metadata on the invoice line is merged with the incoming data.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :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.
sig { returns(T.nilable(::Stripe::InvoiceLineItem::UpdateParams::Period)) }
attr_accessor :period
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
sig { returns(T.nilable(::Stripe::InvoiceLineItem::UpdateParams::PriceData)) }
attr_accessor :price_data
# The pricing information for the invoice item.
sig { returns(T.nilable(::Stripe::InvoiceLineItem::UpdateParams::Pricing)) }
attr_accessor :pricing
# Non-negative integer. The quantity of units for the line item.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# A list of up to 10 tax amounts for this line item. This can be useful if you calculate taxes on your own or use a third-party to calculate them. You cannot set tax amounts if any line item has [tax_rates](https://stripe.com/docs/api/invoices/line_item#invoice_line_item_object-tax_rates) or if the invoice has [default_tax_rates](https://stripe.com/docs/api/invoices/object#invoice_object-default_tax_rates) or uses [automatic tax](https://stripe.com/docs/tax/invoicing). Pass an empty string to remove previously defined tax amounts.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceLineItem::UpdateParams::TaxAmount]))))
}
attr_accessor :tax_amounts
# The tax rates which apply to the line item. When set, the `default_tax_rates` on the invoice do not apply to this line item. Pass an empty string to remove previously-defined tax rates.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
sig {
params(amount: T.nilable(Integer), description: T.nilable(String), discountable: T.nilable(T::Boolean), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceLineItem::UpdateParams::Discount]))), expand: T.nilable(T::Array[String]), margins: T.nilable(T.nilable(T.any(String, T::Array[String]))), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), period: T.nilable(::Stripe::InvoiceLineItem::UpdateParams::Period), price_data: T.nilable(::Stripe::InvoiceLineItem::UpdateParams::PriceData), pricing: T.nilable(::Stripe::InvoiceLineItem::UpdateParams::Pricing), quantity: T.nilable(Integer), tax_amounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceLineItem::UpdateParams::TaxAmount]))), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String])))).void
}
def initialize(
amount: nil,
description: nil,
discountable: nil,
discounts: nil,
expand: nil,
margins: nil,
metadata: nil,
period: nil,
price_data: nil,
pricing: nil,
quantity: nil,
tax_amounts: nil,
tax_rates: nil
); end
end
# Updates an invoice's line item. Some fields, such as tax_amounts, only live on the invoice line item,
# so they can only be updated through this endpoint. Other fields, such as amount, live on both the invoice
# item and the invoice line item, so updates on this endpoint will propagate to the invoice item as well.
# Updating an invoice's line item is only possible before the invoice is finalized.
sig {
params(invoice: String, line_item_id: String, params: T.any(::Stripe::InvoiceLineItem::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::InvoiceLineItem)
}
def self.update(invoice, line_item_id, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
# Login Links are single-use URLs that takes an Express account to the login page for their Stripe dashboard.
# A Login Link differs from an [Account Link](https://stripe.com/docs/api/account_links) in that it takes the user directly to their [Express dashboard for the specified account](https://stripe.com/docs/connect/integrate-express-dashboard#create-login-link)
class LoginLink < APIResource
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The URL for the login link.
sig { returns(String) }
attr_reader :url
end
end
# typed: true
module Stripe
# A Mandate is a record of the permission that your customer gives you to debit their payment method.
class Mandate < APIResource
class CustomerAcceptance < Stripe::StripeObject
class Offline < Stripe::StripeObject; end
class Online < Stripe::StripeObject
# The customer accepts the mandate from this IP address.
sig { returns(T.nilable(String)) }
attr_reader :ip_address
# The customer accepts the mandate using the user agent of the browser.
sig { returns(T.nilable(String)) }
attr_reader :user_agent
end
# The time that the customer accepts the mandate.
sig { returns(T.nilable(Integer)) }
attr_reader :accepted_at
# Attribute for field offline
sig { returns(Offline) }
attr_reader :offline
# Attribute for field online
sig { returns(Online) }
attr_reader :online
# The mandate includes the type of customer acceptance information, such as: `online` or `offline`.
sig { returns(String) }
attr_reader :type
end
class MultiUse < Stripe::StripeObject; end
class PaymentMethodDetails < Stripe::StripeObject
class AcssDebit < Stripe::StripeObject
# List of Stripe products where this mandate can be selected automatically.
sig { returns(T::Array[String]) }
attr_reader :default_for
# Description of the interval. Only required if the 'payment_schedule' parameter is 'interval' or 'combined'.
sig { returns(T.nilable(String)) }
attr_reader :interval_description
# Payment schedule for the mandate.
sig { returns(String) }
attr_reader :payment_schedule
# Transaction type of the mandate.
sig { returns(String) }
attr_reader :transaction_type
end
class AmazonPay < Stripe::StripeObject; end
class AuBecsDebit < Stripe::StripeObject
# The URL of the mandate. This URL generally contains sensitive information about the customer and should be shared with them exclusively.
sig { returns(String) }
attr_reader :url
end
class BacsDebit < Stripe::StripeObject
# The status of the mandate on the Bacs network. Can be one of `pending`, `revoked`, `refused`, or `accepted`.
sig { returns(String) }
attr_reader :network_status
# The unique reference identifying the mandate on the Bacs network.
sig { returns(String) }
attr_reader :reference
# When the mandate is revoked on the Bacs network this field displays the reason for the revocation.
sig { returns(T.nilable(String)) }
attr_reader :revocation_reason
# The URL that will contain the mandate that the customer has signed.
sig { returns(String) }
attr_reader :url
end
class Card < Stripe::StripeObject; end
class Cashapp < Stripe::StripeObject; end
class KakaoPay < Stripe::StripeObject; end
class KrCard < Stripe::StripeObject; end
class Link < Stripe::StripeObject; end
class NaverPay < Stripe::StripeObject; end
class NzBankAccount < Stripe::StripeObject; end
class Paypal < Stripe::StripeObject
# The PayPal Billing Agreement ID (BAID). This is an ID generated by PayPal which represents the mandate between the merchant and the customer.
sig { returns(T.nilable(String)) }
attr_reader :billing_agreement_id
# Uniquely identifies this particular PayPal account. You can use this attribute to check whether two PayPal accounts are the same.
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# PayPal account PayerID. This identifier uniquely identifies the PayPal customer.
sig { returns(T.nilable(String)) }
attr_reader :payer_id
# Owner's verified email. Values are verified or provided by PayPal directly
# (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(String)) }
attr_reader :verified_email
end
class Payto < Stripe::StripeObject
# Amount that will be collected. It is required when `amount_type` is `fixed`.
sig { returns(T.nilable(Integer)) }
attr_reader :amount
# The type of amount that will be collected. The amount charged must be exact or up to the value of `amount` param for `fixed` or `maximum` type respectively.
sig { returns(String) }
attr_reader :amount_type
# Date, in YYYY-MM-DD format, after which payments will not be collected. Defaults to no end date.
sig { returns(T.nilable(String)) }
attr_reader :end_date
# The periodicity at which payments will be collected.
sig { returns(String) }
attr_reader :payment_schedule
# The number of payments that will be made during a payment period. Defaults to 1 except for when `payment_schedule` is `adhoc`. In that case, it defaults to no limit.
sig { returns(T.nilable(Integer)) }
attr_reader :payments_per_period
# The purpose for which payments are made. Defaults to retail.
sig { returns(T.nilable(String)) }
attr_reader :purpose
# Date, in YYYY-MM-DD format, from which payments will be collected. Defaults to confirmation time.
sig { returns(T.nilable(String)) }
attr_reader :start_date
end
class RevolutPay < Stripe::StripeObject; end
class SepaDebit < Stripe::StripeObject
# The unique reference of the mandate.
sig { returns(String) }
attr_reader :reference
# The URL of the mandate. This URL generally contains sensitive information about the customer and should be shared with them exclusively.
sig { returns(String) }
attr_reader :url
end
class UsBankAccount < Stripe::StripeObject
# Mandate collection method
sig { returns(String) }
attr_reader :collection_method
end
# Attribute for field acss_debit
sig { returns(AcssDebit) }
attr_reader :acss_debit
# Attribute for field amazon_pay
sig { returns(AmazonPay) }
attr_reader :amazon_pay
# Attribute for field au_becs_debit
sig { returns(AuBecsDebit) }
attr_reader :au_becs_debit
# Attribute for field bacs_debit
sig { returns(BacsDebit) }
attr_reader :bacs_debit
# Attribute for field card
sig { returns(Card) }
attr_reader :card
# Attribute for field cashapp
sig { returns(Cashapp) }
attr_reader :cashapp
# Attribute for field kakao_pay
sig { returns(KakaoPay) }
attr_reader :kakao_pay
# Attribute for field kr_card
sig { returns(KrCard) }
attr_reader :kr_card
# Attribute for field link
sig { returns(Link) }
attr_reader :link
# Attribute for field naver_pay
sig { returns(NaverPay) }
attr_reader :naver_pay
# Attribute for field nz_bank_account
sig { returns(NzBankAccount) }
attr_reader :nz_bank_account
# Attribute for field paypal
sig { returns(Paypal) }
attr_reader :paypal
# Attribute for field payto
sig { returns(Payto) }
attr_reader :payto
# Attribute for field revolut_pay
sig { returns(RevolutPay) }
attr_reader :revolut_pay
# Attribute for field sepa_debit
sig { returns(SepaDebit) }
attr_reader :sepa_debit
# This mandate corresponds with a specific payment method type. The `payment_method_details` includes an additional hash with the same name and contains mandate information that's specific to that payment method.
sig { returns(String) }
attr_reader :type
# Attribute for field us_bank_account
sig { returns(UsBankAccount) }
attr_reader :us_bank_account
end
class SingleUse < Stripe::StripeObject
# The amount of the payment on a single use mandate.
sig { returns(Integer) }
attr_reader :amount
# The currency of the payment on a single use mandate.
sig { returns(String) }
attr_reader :currency
end
# Attribute for field customer_acceptance
sig { returns(CustomerAcceptance) }
attr_reader :customer_acceptance
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# Attribute for field multi_use
sig { returns(MultiUse) }
attr_reader :multi_use
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The account (if any) that the mandate is intended for.
sig { returns(String) }
attr_reader :on_behalf_of
# ID of the payment method associated with this mandate.
sig { returns(T.any(String, Stripe::PaymentMethod)) }
attr_reader :payment_method
# Attribute for field payment_method_details
sig { returns(PaymentMethodDetails) }
attr_reader :payment_method_details
# Attribute for field single_use
sig { returns(SingleUse) }
attr_reader :single_use
# The mandate status indicates whether or not you can use it to initiate a payment.
sig { returns(String) }
attr_reader :status
# The type of the mandate.
sig { returns(String) }
attr_reader :type
end
end
# typed: true
module Stripe
# A (partner) margin represents a specific discount distributed in partner reseller programs to business partners who
# resell products and services and earn a discount (margin) for doing so.
class Margin < APIResource
# Whether the margin can be applied to invoices, invoice items, or invoice line items. Defaults to `true`.
sig { returns(T::Boolean) }
attr_reader :active
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# 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.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# Name of the margin that's displayed on, for example, invoices.
sig { returns(T.nilable(String)) }
attr_reader :name
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Percent that will be taken off the subtotal before tax (after all other discounts and promotions) of any invoice to which the margin is applied.
sig { returns(Float) }
attr_reader :percent_off
# Time at which the object was last updated. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :updated
class ListParams < Stripe::RequestParams
# Only return margins that are active or inactive. For example, pass `true` to only list active margins.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(active: T.nilable(T::Boolean), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
active: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
# Whether the margin can be applied to invoices, invoice items, or invoice line items or not. Defaults to `true`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Name of the margin, which is displayed to customers, such as on invoices.
sig { returns(T.nilable(String)) }
attr_accessor :name
# Percent that will be taken off the subtotal before tax (after all other discounts and promotions) of any invoice to which the margin is applied.
sig { returns(Float) }
attr_accessor :percent_off
sig {
params(active: T.nilable(T::Boolean), expand: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), name: T.nilable(String), percent_off: Float).void
}
def initialize(active: nil, expand: nil, metadata: nil, name: nil, percent_off: nil); end
end
class UpdateParams < Stripe::RequestParams
# Whether the margin can be applied to invoices, invoice items, or invoice line items or not.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Name of the margin, which is displayed to customers, such as on invoices.
sig { returns(T.nilable(String)) }
attr_accessor :name
sig {
params(active: T.nilable(T::Boolean), expand: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), name: T.nilable(String)).void
}
def initialize(active: nil, expand: nil, metadata: nil, name: nil); end
end
# Create a margin object to be used with invoices, invoice items, and invoice line items for a customer to represent a partner discount. A margin has a percent_off which is the percent that will be taken off the subtotal after all items and other discounts and promotions) of any invoices for a customer. Calculation of prorations do not include any partner margins applied on the original invoice item.
sig {
params(params: T.any(::Stripe::Margin::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Margin)
}
def self.create(params = {}, opts = {}); end
# Retrieve a list of your margins.
sig {
params(params: T.any(::Stripe::Margin::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Update the specified margin object. Certain fields of the margin object are not editable.
sig {
params(margin: String, params: T.any(::Stripe::Margin::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Margin)
}
def self.update(margin, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
# An Order describes a purchase being made by a customer, including the
# products & quantities being purchased, the order status, the payment information,
# and the billing/shipping details.
#
# Related guide: [Orders overview](https://stripe.com/docs/orders)
class Order < APIResource
class AutomaticTax < Stripe::StripeObject
# Whether Stripe automatically computes tax on this Order.
sig { returns(T::Boolean) }
attr_reader :enabled
# The status of the most recent automated tax calculation for this Order.
sig { returns(T.nilable(String)) }
attr_reader :status
end
class BillingDetails < Stripe::StripeObject
class Address < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Billing address for the order.
sig { returns(T.nilable(Address)) }
attr_reader :address
# Email address for the order.
sig { returns(T.nilable(String)) }
attr_reader :email
# Full name for the order.
sig { returns(T.nilable(String)) }
attr_reader :name
# Billing phone number for the order (including extension).
sig { returns(T.nilable(String)) }
attr_reader :phone
end
class Payment < Stripe::StripeObject
class Settings < Stripe::StripeObject
class AutomaticPaymentMethods < Stripe::StripeObject
# Whether this Order has been opted into managing payment method types via the [Stripe Dashboard](https://dashboard.stripe.com/settings/payment_methods).
sig { returns(T::Boolean) }
attr_reader :enabled
end
class PaymentMethodOptions < Stripe::StripeObject
class AcssDebit < Stripe::StripeObject
class MandateOptions < Stripe::StripeObject
# A URL for custom mandate text
sig { returns(String) }
attr_reader :custom_mandate_url
# Description of the interval. Only required if the 'payment_schedule' parameter is 'interval' or 'combined'.
sig { returns(T.nilable(String)) }
attr_reader :interval_description
# Payment schedule for the mandate.
sig { returns(T.nilable(String)) }
attr_reader :payment_schedule
# Transaction type of the mandate.
sig { returns(T.nilable(String)) }
attr_reader :transaction_type
end
# Attribute for field mandate_options
sig { returns(MandateOptions) }
attr_reader :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(String) }
attr_reader :target_date
# Bank account verification method.
sig { returns(String) }
attr_reader :verification_method
end
class AfterpayClearpay < Stripe::StripeObject
# Controls when the funds will be captured from the customer's account.
sig { returns(String) }
attr_reader :capture_method
# Order identifier shown to the user in Afterpay's online portal. We recommend using a value that helps you answer any questions a customer might have about the payment. The identifier is limited to 128 characters and may contain only letters, digits, underscores, backslashes and dashes.
sig { returns(T.nilable(String)) }
attr_reader :reference
# Indicates that you intend to make future payments with the payment method.
#
# Providing this parameter will [attach the payment method](https://stripe.com/docs/payments/save-during-payment) to the order's Customer, if present, after the order's PaymentIntent is confirmed and any required actions from the user are complete. If no Customer was provided, the payment method can still be [attached](https://stripe.com/docs/api/payment_methods/attach) to a Customer after the transaction completes.
#
# When processing card payments, Stripe also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as [SCA](https://stripe.com/docs/strong-customer-authentication).
#
# If `setup_future_usage` is already set and you are performing a request using a publishable key, you may only update the value from `on_session` to `off_session`.
sig { returns(String) }
attr_reader :setup_future_usage
end
class Alipay < Stripe::StripeObject
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Bancontact < Stripe::StripeObject
# Preferred language of the Bancontact authorization page that the customer is redirected to.
sig { returns(String) }
attr_reader :preferred_language
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Card < Stripe::StripeObject
# Controls when the funds will be captured from the customer's account.
sig { returns(String) }
attr_reader :capture_method
# Indicates that you intend to make future payments with the payment method.
#
# Providing this parameter will [attach the payment method](https://stripe.com/docs/payments/save-during-payment) to the order's Customer, if present, after the order's PaymentIntent is confirmed and any required actions from the user are complete. If no Customer was provided, the payment method can still be [attached](https://stripe.com/docs/api/payment_methods/attach) to a Customer after the transaction completes.
#
# When processing card payments, Stripe also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as [SCA](https://stripe.com/docs/strong-customer-authentication).
#
# If `setup_future_usage` is already set and you are performing a request using a publishable key, you may only update the value from `on_session` to `off_session`.
sig { returns(String) }
attr_reader :setup_future_usage
end
class CustomerBalance < Stripe::StripeObject
class BankTransfer < Stripe::StripeObject
class EuBankTransfer < Stripe::StripeObject
# The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
sig { returns(String) }
attr_reader :country
end
# Attribute for field eu_bank_transfer
sig { returns(EuBankTransfer) }
attr_reader :eu_bank_transfer
# List of address types that should be returned in the financial_addresses response. If not specified, all valid types will be returned.
#
# Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`.
sig { returns(T::Array[String]) }
attr_reader :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`, `mx_bank_transfer`, or `us_bank_transfer`.
sig { returns(T.nilable(String)) }
attr_reader :type
end
# Attribute for field bank_transfer
sig { returns(BankTransfer) }
attr_reader :bank_transfer
# The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
sig { returns(T.nilable(String)) }
attr_reader :funding_type
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Ideal < Stripe::StripeObject
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Klarna < Stripe::StripeObject
# Controls when the funds will be captured from the customer's account.
sig { returns(String) }
attr_reader :capture_method
# Preferred locale of the Klarna checkout page that the customer is redirected to.
sig { returns(T.nilable(String)) }
attr_reader :preferred_locale
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Link < Stripe::StripeObject
# Controls when the funds will be captured from the customer's account.
sig { returns(String) }
attr_reader :capture_method
# [Deprecated] This is a legacy parameter that no longer has any function.
sig { returns(T.nilable(String)) }
attr_reader :persistent_token
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Oxxo < Stripe::StripeObject
# The number of calendar days before an OXXO invoice expires. For example, if you create an OXXO invoice on Monday and you set expires_after_days to 2, the OXXO invoice will expire on Wednesday at 23:59 America/Mexico_City time.
sig { returns(Integer) }
attr_reader :expires_after_days
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class P24 < Stripe::StripeObject
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Paypal < Stripe::StripeObject
class LineItem < Stripe::StripeObject
class Tax < Stripe::StripeObject
# The tax for a single unit of the line item in minor units. Cannot be a negative number.
sig { returns(Integer) }
attr_reader :amount
# The tax behavior for the line item.
sig { returns(String) }
attr_reader :behavior
end
# Type of the line item.
sig { returns(String) }
attr_reader :category
# Description of the line item.
sig { returns(String) }
attr_reader :description
# Descriptive name of the line item.
sig { returns(String) }
attr_reader :name
# Quantity of the line item. Cannot be a negative number.
sig { returns(Integer) }
attr_reader :quantity
# Client facing stock keeping unit, article number or similar.
sig { returns(String) }
attr_reader :sku
# The Stripe account ID of the connected account that sells the item. This is only needed when using [Separate Charges and Transfers](https://docs.stripe.com/connect/separate-charges-and-transfers).
sig { returns(String) }
attr_reader :sold_by
# Attribute for field tax
sig { returns(Tax) }
attr_reader :tax
# Price for a single unit of the line item in minor units. Cannot be a negative number.
sig { returns(Integer) }
attr_reader :unit_amount
end
# Controls when the funds will be captured from the customer's account.
sig { returns(String) }
attr_reader :capture_method
# The line items purchased by the customer.
sig { returns(T::Array[LineItem]) }
attr_reader :line_items
# Preferred locale of the PayPal checkout page that the customer is redirected to.
sig { returns(T.nilable(String)) }
attr_reader :preferred_locale
# A reference of the PayPal transaction visible to customer which is mapped to PayPal's invoice ID. This must be a globally unique ID if you have configured in your PayPal settings to block multiple payments per invoice ID.
sig { returns(T.nilable(String)) }
attr_reader :reference
# A reference of the PayPal transaction visible to customer which is mapped to PayPal's invoice ID. This must be a globally unique ID if you have configured in your PayPal settings to block multiple payments per invoice ID.
sig { returns(T.nilable(String)) }
attr_reader :reference_id
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
# The Stripe connected account IDs of the sellers on the platform for this transaction (optional). Only allowed when [separate charges and transfers](https://stripe.com/docs/connect/separate-charges-and-transfers) are used.
sig { returns(T::Array[String]) }
attr_reader :subsellers
end
class SepaDebit < Stripe::StripeObject
class MandateOptions < Stripe::StripeObject
# Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'STRIPE'.
sig { returns(String) }
attr_reader :reference_prefix
end
# Attribute for field mandate_options
sig { returns(MandateOptions) }
attr_reader :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(String) }
attr_reader :target_date
end
class Sofort < Stripe::StripeObject
# Preferred language of the SOFORT authorization page that the customer is redirected to.
sig { returns(T.nilable(String)) }
attr_reader :preferred_language
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class WechatPay < Stripe::StripeObject
# The app ID registered with WeChat Pay. Only required when client is ios or android.
sig { returns(T.nilable(String)) }
attr_reader :app_id
# The client type that the end customer will pay from
sig { returns(T.nilable(String)) }
attr_reader :client
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
# Attribute for field acss_debit
sig { returns(AcssDebit) }
attr_reader :acss_debit
# Attribute for field afterpay_clearpay
sig { returns(AfterpayClearpay) }
attr_reader :afterpay_clearpay
# Attribute for field alipay
sig { returns(Alipay) }
attr_reader :alipay
# Attribute for field bancontact
sig { returns(Bancontact) }
attr_reader :bancontact
# Attribute for field card
sig { returns(Card) }
attr_reader :card
# Attribute for field customer_balance
sig { returns(CustomerBalance) }
attr_reader :customer_balance
# Attribute for field ideal
sig { returns(Ideal) }
attr_reader :ideal
# Attribute for field klarna
sig { returns(Klarna) }
attr_reader :klarna
# Attribute for field link
sig { returns(Link) }
attr_reader :link
# Attribute for field oxxo
sig { returns(Oxxo) }
attr_reader :oxxo
# Attribute for field p24
sig { returns(P24) }
attr_reader :p24
# Attribute for field paypal
sig { returns(Paypal) }
attr_reader :paypal
# Attribute for field sepa_debit
sig { returns(SepaDebit) }
attr_reader :sepa_debit
# Attribute for field sofort
sig { returns(Sofort) }
attr_reader :sofort
# Attribute for field wechat_pay
sig { returns(WechatPay) }
attr_reader :wechat_pay
end
class TransferData < Stripe::StripeObject
# The amount that will be transferred automatically when the order is paid. If no amount is set, the full amount is transferred. There cannot be any line items with recurring prices when using this field.
sig { returns(T.nilable(Integer)) }
attr_reader :amount
# ID of the Connected account receiving the transfer.
sig { returns(T.any(String, Stripe::Account)) }
attr_reader :destination
end
# The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account.
sig { returns(T.nilable(Integer)) }
attr_reader :application_fee_amount
# Indicates whether order has been opted into using [Stripe Dashboard](https://dashboard.stripe.com/settings/payment_methods) to manage payment method types.
sig { returns(T.nilable(AutomaticPaymentMethods)) }
attr_reader :automatic_payment_methods
# PaymentMethod-specific configuration to provide to the order's PaymentIntent.
sig { returns(T.nilable(PaymentMethodOptions)) }
attr_reader :payment_method_options
# The list of [payment method types](https://stripe.com/docs/payments/payment-methods/overview) to provide to the order's PaymentIntent. Do not include this attribute if you prefer to manage your payment methods from the [Stripe Dashboard](https://dashboard.stripe.com/settings/payment_methods).
sig { returns(T.nilable(T::Array[String])) }
attr_reader :payment_method_types
# The URL to redirect the customer to after they authenticate their payment.
sig { returns(T.nilable(String)) }
attr_reader :return_url
# For non-card charges, you can use this value as the complete description that appears on your customers' statements. Must contain at least one letter, maximum 22 characters.
sig { returns(T.nilable(String)) }
attr_reader :statement_descriptor
# Provides information about a card payment that customers see on their statements. Concatenated with the prefix (shortened descriptor) or statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 22 characters for the concatenated descriptor.
sig { returns(T.nilable(String)) }
attr_reader :statement_descriptor_suffix
# Provides configuration for completing a transfer for the order after it is paid.
sig { returns(T.nilable(TransferData)) }
attr_reader :transfer_data
end
# ID of the payment intent associated with this order. Null when the order is `open`.
sig { returns(T.nilable(T.any(String, Stripe::PaymentIntent))) }
attr_reader :payment_intent
# Settings describing how the order should configure generated PaymentIntents.
sig { returns(T.nilable(Settings)) }
attr_reader :settings
# The status of the underlying payment associated with this order, if any. Null when the order is `open`.
sig { returns(T.nilable(String)) }
attr_reader :status
end
class ShippingCost < Stripe::StripeObject
class Tax < Stripe::StripeObject
# Amount of tax applied for this rate.
sig { returns(Integer) }
attr_reader :amount
# Tax rates can be applied to [invoices](/invoicing/taxes/tax-rates), [subscriptions](/billing/taxes/tax-rates) and [Checkout Sessions](/payments/checkout/use-manual-tax-rates) to collect tax.
#
# Related guide: [Tax rates](/billing/taxes/tax-rates)
sig { returns(Stripe::TaxRate) }
attr_reader :rate
# 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.
sig { returns(T.nilable(String)) }
attr_reader :taxability_reason
# The amount on which tax is calculated, in cents (or local equivalent).
sig { returns(T.nilable(Integer)) }
attr_reader :taxable_amount
end
# Total shipping cost before any discounts or taxes are applied.
sig { returns(Integer) }
attr_reader :amount_subtotal
# Total tax amount applied due to shipping costs. If no tax was applied, defaults to 0.
sig { returns(Integer) }
attr_reader :amount_tax
# Total shipping cost after discounts and taxes are applied.
sig { returns(Integer) }
attr_reader :amount_total
# The ID of the ShippingRate for this order.
sig { returns(T.nilable(T.any(String, Stripe::ShippingRate))) }
attr_reader :shipping_rate
# The taxes applied to the shipping rate.
sig { returns(T::Array[Tax]) }
attr_reader :taxes
end
class ShippingDetails < Stripe::StripeObject
class Address < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Recipient shipping address. Required if the order includes products that are shippable.
sig { returns(T.nilable(Address)) }
attr_reader :address
# Recipient name.
sig { returns(T.nilable(String)) }
attr_reader :name
# Recipient phone (including extension).
sig { returns(T.nilable(String)) }
attr_reader :phone
end
class TaxDetails < Stripe::StripeObject
class TaxId < Stripe::StripeObject
# The type of the tax ID, one of `ad_nrt`, `ar_cuit`, `eu_vat`, `bo_tin`, `br_cnpj`, `br_cpf`, `cn_tin`, `co_nit`, `cr_tin`, `do_rcn`, `ec_ruc`, `eu_oss_vat`, `hr_oib`, `pe_ruc`, `ro_tin`, `rs_pib`, `sv_nit`, `uy_ruc`, `ve_rif`, `vn_tin`, `gb_vat`, `nz_gst`, `au_abn`, `au_arn`, `in_gst`, `no_vat`, `no_voec`, `za_vat`, `ch_vat`, `mx_rfc`, `sg_uen`, `ru_inn`, `ru_kpp`, `ca_bn`, `hk_br`, `es_cif`, `tw_vat`, `th_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `li_uid`, `li_vat`, `my_itn`, `us_ein`, `kr_brn`, `ca_qst`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `my_sst`, `sg_gst`, `ae_trn`, `cl_tin`, `sa_vat`, `id_npwp`, `my_frp`, `il_vat`, `ge_vat`, `ua_vat`, `is_vat`, `bg_uic`, `hu_tin`, `si_tin`, `ke_pin`, `tr_tin`, `eg_tin`, `ph_tin`, `al_tin`, `bh_vat`, `kz_bin`, `ng_tin`, `om_vat`, `de_stn`, `ch_uid`, `tz_vat`, `uz_vat`, `uz_tin`, `md_vat`, `ma_vat`, `by_tin`, `ao_tin`, `bs_tin`, `bb_tin`, `cd_nif`, `mr_nif`, `me_pib`, `zw_tin`, `ba_tin`, `gn_nif`, `mk_vat`, `sr_fin`, `sn_ninea`, `am_tin`, `np_pan`, `tj_tin`, `ug_tin`, `zm_tin`, `kh_tin`, `aw_tin`, `az_tin`, `bd_bin`, `bj_ifu`, `et_tin`, `kg_tin`, `la_tin`, `cm_niu`, `cv_nif`, `bf_ifu`, or `unknown`
sig { returns(String) }
attr_reader :type
# The value of the tax ID.
sig { returns(T.nilable(String)) }
attr_reader :value
end
# Describes the purchaser's tax exemption status. One of `none`, `exempt`, or `reverse`.
sig { returns(String) }
attr_reader :tax_exempt
# The purchaser's tax IDs to be used in calculation of tax for this Order.
sig { returns(T::Array[TaxId]) }
attr_reader :tax_ids
end
class TotalDetails < Stripe::StripeObject
class Breakdown < Stripe::StripeObject
class Discount < Stripe::StripeObject
# The amount discounted.
sig { returns(Integer) }
attr_reader :amount
# A discount represents the actual application of a [coupon](https://stripe.com/docs/api#coupons) or [promotion code](https://stripe.com/docs/api#promotion_codes).
# It contains information about when the discount began, when it will end, and what it is applied to.
#
# Related guide: [Applying discounts to subscriptions](https://stripe.com/docs/billing/subscriptions/discounts)
sig { returns(Stripe::Discount) }
attr_reader :discount
end
class Tax < Stripe::StripeObject
# Amount of tax applied for this rate.
sig { returns(Integer) }
attr_reader :amount
# Tax rates can be applied to [invoices](/invoicing/taxes/tax-rates), [subscriptions](/billing/taxes/tax-rates) and [Checkout Sessions](/payments/checkout/use-manual-tax-rates) to collect tax.
#
# Related guide: [Tax rates](/billing/taxes/tax-rates)
sig { returns(Stripe::TaxRate) }
attr_reader :rate
# 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.
sig { returns(T.nilable(String)) }
attr_reader :taxability_reason
# The amount on which tax is calculated, in cents (or local equivalent).
sig { returns(T.nilable(Integer)) }
attr_reader :taxable_amount
end
# The aggregated discounts.
sig { returns(T::Array[Discount]) }
attr_reader :discounts
# The aggregated tax amounts by rate.
sig { returns(T::Array[Tax]) }
attr_reader :taxes
end
# This is the sum of all the discounts.
sig { returns(Integer) }
attr_reader :amount_discount
# This is the sum of all the shipping amounts.
sig { returns(T.nilable(Integer)) }
attr_reader :amount_shipping
# This is the sum of all the tax amounts.
sig { returns(Integer) }
attr_reader :amount_tax
# Attribute for field breakdown
sig { returns(Breakdown) }
attr_reader :breakdown
end
# Order cost before any discounts or taxes are applied. A positive integer representing the subtotal of the order in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency).
sig { returns(Integer) }
attr_reader :amount_subtotal
# Total order cost after discounts and taxes are applied. A positive integer representing the cost of the order in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). To submit an order, the total must be either 0 or at least $0.50 USD or [equivalent in charge currency](https://stripe.com/docs/currencies#minimum-and-maximum-charge-amounts).
sig { returns(Integer) }
attr_reader :amount_total
# ID of the Connect application that created the Order, if any.
sig { returns(T.nilable(T.any(String, Stripe::Application))) }
attr_reader :application
# Attribute for field automatic_tax
sig { returns(AutomaticTax) }
attr_reader :automatic_tax
# Customer billing details associated with the order.
sig { returns(T.nilable(BillingDetails)) }
attr_reader :billing_details
# The client secret of this Order. Used for client-side retrieval using a publishable key.
#
# The client secret can be used to complete a payment for an Order from your frontend. It should not be stored, logged, embedded in URLs, or exposed to anyone other than the customer. Make sure that you have TLS enabled on any page that includes the client secret.
#
# Refer to our docs for [creating and processing an order](https://stripe.com/docs/orders-beta/create-and-process) to learn about how client_secret should be handled.
sig { returns(T.nilable(String)) }
attr_reader :client_secret
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# 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).
sig { returns(String) }
attr_reader :currency
# The customer which this orders belongs to.
sig { returns(T.nilable(T.any(String, Stripe::Customer))) }
attr_reader :customer
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_reader :description
# The discounts applied to the order. Use `expand[]=discounts` to expand each discount.
sig { returns(T.nilable(T::Array[T.any(String, Stripe::Discount)])) }
attr_reader :discounts
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# A recent IP address of the purchaser used for tax reporting and tax location inference.
sig { returns(T.nilable(String)) }
attr_reader :ip_address
# A list of line items the customer is ordering. Each line item includes information about the product, the quantity, and the resulting cost. There is a maximum of 100 line items.
sig { returns(Stripe::ListObject) }
attr_reader :line_items
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# 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.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Attribute for field payment
sig { returns(Payment) }
attr_reader :payment
# The details of the customer cost of shipping, including the customer chosen ShippingRate.
sig { returns(T.nilable(ShippingCost)) }
attr_reader :shipping_cost
# Customer shipping information associated with the order.
sig { returns(T.nilable(ShippingDetails)) }
attr_reader :shipping_details
# The overall status of the order.
sig { returns(String) }
attr_reader :status
# Attribute for field tax_details
sig { returns(TaxDetails) }
attr_reader :tax_details
# Attribute for field total_details
sig { returns(TotalDetails) }
attr_reader :total_details
class ListParams < Stripe::RequestParams
# Only return orders for the given customer.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(customer: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
customer: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class AutomaticTax < Stripe::RequestParams
# Enable automatic tax calculation which will automatically compute tax rates on this order.
sig { returns(T::Boolean) }
attr_accessor :enabled
sig { params(enabled: T::Boolean).void }
def initialize(enabled: nil); end
end
class BillingDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State/province as an [ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2) subdivision code, without country prefix. Example: "NY" or "TX".
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# The billing address provided by the customer.
sig { returns(T.nilable(::Stripe::Order::CreateParams::BillingDetails::Address)) }
attr_accessor :address
# The billing email provided by the customer.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The billing name provided by the customer.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The billing phone number provided by the customer.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(address: T.nilable(::Stripe::Order::CreateParams::BillingDetails::Address), email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(address: nil, email: nil, name: nil, phone: nil); end
end
class Discount < Stripe::RequestParams
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, promotion_code: nil); end
end
class LineItem < Stripe::RequestParams
class Discount < Stripe::RequestParams
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
sig { params(coupon: T.nilable(String), discount: T.nilable(String)).void }
def initialize(coupon: nil, discount: nil); end
end
class PriceData < Stripe::RequestParams
# 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).
sig { returns(T.nilable(String)) }
attr_accessor :currency
# ID of the [Product](https://docs.stripe.com/api/products) this [Price](https://docs.stripe.com/api/prices) belongs to.
#
# Use this to implement a variable-pricing model in your integration. This is required if `product_data` is not specified.
sig { returns(T.nilable(String)) }
attr_accessor :product
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: T.nilable(String), product: T.nilable(String), tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
class ProductData < Stripe::RequestParams
class PackageDimensions < Stripe::RequestParams
# Height, in inches. Maximum precision is 2 decimal places.
sig { returns(Float) }
attr_accessor :height
# Length, in inches. Maximum precision is 2 decimal places.
sig { returns(Float) }
attr_accessor :length
# Weight, in ounces. Maximum precision is 2 decimal places.
sig { returns(Float) }
attr_accessor :weight
# Width, in inches. Maximum precision is 2 decimal places.
sig { returns(Float) }
attr_accessor :width
sig { params(height: Float, length: Float, weight: Float, width: Float).void }
def initialize(height: nil, length: nil, weight: nil, width: nil); end
end
# The product's description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :description
# A unique identifier for this product.
#
# `product_data` automatically creates a Product with this ID. If a Product with the same ID already exists, then `product_data` re-uses it to avoid duplicates. If any of the fields in the existing Product are different from the values in `product_data`, `product_data` updates the existing Product with the new information. So set `product_data[id]` to the same string every time you sell the same product, but don't re-use the same string for different products.
sig { returns(String) }
attr_accessor :id
# A list of up to 8 URLs of images for this product, meant to be displayable to the customer.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :images
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# The product's name, meant to be displayable to the customer.
sig { returns(String) }
attr_accessor :name
# The dimensions of this product for shipping purposes.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Order::CreateParams::LineItem::ProductData::PackageDimensions))))
}
attr_accessor :package_dimensions
# Whether this product is shipped (i.e., physical goods).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :shippable
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :tax_code
# A URL of a publicly-accessible webpage for this product.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :url
sig {
params(description: T.nilable(T.nilable(String)), id: String, images: T.nilable(T.nilable(T.any(String, T::Array[String]))), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), name: String, package_dimensions: T.nilable(T.nilable(T.any(String, ::Stripe::Order::CreateParams::LineItem::ProductData::PackageDimensions))), shippable: T.nilable(T::Boolean), tax_code: T.nilable(T.nilable(String)), url: T.nilable(T.nilable(String))).void
}
def initialize(
description: nil,
id: nil,
images: nil,
metadata: nil,
name: nil,
package_dimensions: nil,
shippable: nil,
tax_code: nil,
url: nil
); end
end
# The description for the line item. Will default to the name of the associated product.
sig { returns(T.nilable(String)) }
attr_accessor :description
# The discounts applied to this line item.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Order::CreateParams::LineItem::Discount]))))
}
attr_accessor :discounts
# The ID of a [Price](https://docs.stripe.com/api/prices) to add to the Order.
#
# The `price` parameter is an alternative to using the `product` parameter. If each of your products are sold at a single price, you can set `Product.default_price` and then pass the `product` parameter when creating a line item. If your products are sold at several possible prices, use the `price` parameter to explicitly specify which one to use.
sig { returns(T.nilable(String)) }
attr_accessor :price
# Data used to generate a new Price object inline.
#
# The `price_data` parameter is an alternative to using the `product` or `price` parameters. If you create a Product upfront and configure a `Product.default_price`, pass the `product` parameter when creating a line item. If you prefer not to define Products upfront, or if you charge variable prices, pass the `price_data` parameter to describe the price for this line item.
#
# Each time you pass `price_data` we create a Price for the Product. This Price is hidden in both the Dashboard and API lists and cannot be reused.
sig { returns(T.nilable(::Stripe::Order::CreateParams::LineItem::PriceData)) }
attr_accessor :price_data
# The ID of a [Product](https://docs.stripe.com/api/products) to add to the Order.
#
# The Product must have a `default_price` specified. Otherwise, specify the price by passing the `price` or `price_data` parameter.
sig { returns(T.nilable(String)) }
attr_accessor :product
# Defines a [Product](https://docs.stripe.com/api/products) inline and adds it to the Order.
#
# `product_data` is an alternative to the `product` parameter. If you created a Product upfront, use the `product` parameter to refer to the existing Product. But if you prefer not to create Products upfront, pass the `product_data` parameter to define a Product inline as part of configuring the Order.
#
# `product_data` automatically creates a Product, just as if you had manually created the Product. If a Product with the same ID already exists, then `product_data` re-uses it to avoid duplicates.
sig { returns(T.nilable(::Stripe::Order::CreateParams::LineItem::ProductData)) }
attr_accessor :product_data
# The quantity of the line item.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# The tax rates applied to this line item.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
sig {
params(description: T.nilable(String), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Order::CreateParams::LineItem::Discount]))), price: T.nilable(String), price_data: T.nilable(::Stripe::Order::CreateParams::LineItem::PriceData), product: T.nilable(String), product_data: T.nilable(::Stripe::Order::CreateParams::LineItem::ProductData), quantity: T.nilable(Integer), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String])))).void
}
def initialize(
description: nil,
discounts: nil,
price: nil,
price_data: nil,
product: nil,
product_data: nil,
quantity: nil,
tax_rates: nil
); end
end
class Payment < Stripe::RequestParams
class Settings < Stripe::RequestParams
class PaymentMethodOptions < Stripe::RequestParams
class AcssDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# A URL for custom mandate text to render during confirmation step.
# The URL will be rendered with additional GET parameters `payment_intent` and `payment_intent_client_secret` when confirming a Payment Intent,
# or `setup_intent` and `setup_intent_client_secret` when confirming a Setup Intent.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :custom_mandate_url
# Description of the mandate interval. Only required if 'payment_schedule' parameter is 'interval' or 'combined'.
sig { returns(T.nilable(String)) }
attr_accessor :interval_description
# Payment schedule for the mandate.
sig { returns(T.nilable(String)) }
attr_accessor :payment_schedule
# Transaction type of the mandate.
sig { returns(T.nilable(String)) }
attr_accessor :transaction_type
sig {
params(custom_mandate_url: T.nilable(T.nilable(String)), interval_description: T.nilable(String), payment_schedule: T.nilable(String), transaction_type: T.nilable(String)).void
}
def initialize(
custom_mandate_url: nil,
interval_description: nil,
payment_schedule: nil,
transaction_type: nil
); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::Order::CreateParams::Payment::Settings::PaymentMethodOptions::AcssDebit::MandateOptions))
}
attr_accessor :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
# Bank account verification method.
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(mandate_options: T.nilable(::Stripe::Order::CreateParams::Payment::Settings::PaymentMethodOptions::AcssDebit::MandateOptions), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), target_date: T.nilable(String), verification_method: T.nilable(String)).void
}
def initialize(
mandate_options: nil,
setup_future_usage: nil,
target_date: nil,
verification_method: nil
); end
end
class AfterpayClearpay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(String)) }
attr_accessor :capture_method
# An internal identifier or reference this payment corresponds to. The identifier is limited to 128 characters and may contain only letters, digits, underscores, backslashes and dashes.
sig { returns(T.nilable(String)) }
attr_accessor :reference
# Indicates that you intend to make future payments with the payment method.
#
# Providing this parameter will [attach the payment method](https://stripe.com/docs/payments/save-during-payment) to the order's Customer, if present, after the order's PaymentIntent is confirmed and any required actions from the user are complete. If no Customer was provided, the payment method can still be [attached](https://stripe.com/docs/api/payment_methods/attach) to a Customer after the transaction completes.
#
# When processing card payments, Stripe also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as [SCA](https://stripe.com/docs/strong-customer-authentication).
#
# If `setup_future_usage` is already set and you are performing a request using a publishable key, you may only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(String), reference: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(capture_method: nil, reference: nil, setup_future_usage: nil); end
end
class Alipay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void }
def initialize(setup_future_usage: nil); end
end
class Bancontact < Stripe::RequestParams
# Preferred language of the Bancontact authorization page that the customer is redirected to.
sig { returns(T.nilable(String)) }
attr_accessor :preferred_language
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(preferred_language: T.nilable(String), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(preferred_language: nil, setup_future_usage: nil); end
end
class Card < Stripe::RequestParams
# Controls when the funds will be captured from the customer's account.
sig { returns(T.nilable(String)) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with the payment method.
#
# Providing this parameter will [attach the payment method](https://stripe.com/docs/payments/save-during-payment) to the order's Customer, if present, after the order's PaymentIntent is confirmed and any required actions from the user are complete. If no Customer was provided, the payment method can still be [attached](https://stripe.com/docs/api/payment_methods/attach) to a Customer after the transaction completes.
#
# When processing card payments, Stripe also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as [SCA](https://stripe.com/docs/strong-customer-authentication).
#
# If `setup_future_usage` is already set and you are performing a request using a publishable key, you may only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class CustomerBalance < Stripe::RequestParams
class BankTransfer < Stripe::RequestParams
class EuBankTransfer < Stripe::RequestParams
# The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
sig { returns(String) }
attr_accessor :country
sig { params(country: String).void }
def initialize(country: nil); end
end
# Configuration for the eu_bank_transfer funding type.
sig {
returns(T.nilable(::Stripe::Order::CreateParams::Payment::Settings::PaymentMethodOptions::CustomerBalance::BankTransfer::EuBankTransfer))
}
attr_accessor :eu_bank_transfer
# List of address types that should be returned in the financial_addresses response. If not specified, all valid types will be returned.
#
# Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :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`, `mx_bank_transfer`, or `us_bank_transfer`.
sig { returns(String) }
attr_accessor :type
sig {
params(eu_bank_transfer: T.nilable(::Stripe::Order::CreateParams::Payment::Settings::PaymentMethodOptions::CustomerBalance::BankTransfer::EuBankTransfer), requested_address_types: T.nilable(T::Array[String]), type: String).void
}
def initialize(eu_bank_transfer: nil, requested_address_types: nil, type: nil); end
end
# Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
sig {
returns(T.nilable(::Stripe::Order::CreateParams::Payment::Settings::PaymentMethodOptions::CustomerBalance::BankTransfer))
}
attr_accessor :bank_transfer
# The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
sig { returns(T.nilable(String)) }
attr_accessor :funding_type
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(bank_transfer: T.nilable(::Stripe::Order::CreateParams::Payment::Settings::PaymentMethodOptions::CustomerBalance::BankTransfer), funding_type: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(bank_transfer: nil, funding_type: nil, setup_future_usage: nil); end
end
class Ideal < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void }
def initialize(setup_future_usage: nil); end
end
class Klarna < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Preferred language of the Klarna authorization page that the customer is redirected to
sig { returns(T.nilable(String)) }
attr_accessor :preferred_locale
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), preferred_locale: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(
capture_method: nil,
preferred_locale: nil,
setup_future_usage: nil
); end
end
class Link < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# [Deprecated] This is a legacy parameter that no longer has any function.
sig { returns(T.nilable(String)) }
attr_accessor :persistent_token
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), persistent_token: T.nilable(String), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(
capture_method: nil,
persistent_token: nil,
setup_future_usage: nil
); end
end
class Oxxo < Stripe::RequestParams
# The number of calendar days before an OXXO voucher expires. For example, if you create an OXXO voucher on Monday and you set expires_after_days to 2, the OXXO invoice will expire on Wednesday at 23:59 America/Mexico_City time.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_after_days
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(expires_after_days: T.nilable(Integer), setup_future_usage: T.nilable(String)).void
}
def initialize(expires_after_days: nil, setup_future_usage: nil); end
end
class P24 < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
# Confirm that the payer has accepted the P24 terms and conditions.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :tos_shown_and_accepted
sig {
params(setup_future_usage: T.nilable(String), tos_shown_and_accepted: T.nilable(T::Boolean)).void
}
def initialize(setup_future_usage: nil, tos_shown_and_accepted: nil); end
end
class Paypal < Stripe::RequestParams
class LineItem < Stripe::RequestParams
class Tax < Stripe::RequestParams
# The tax for a single unit of the line item in minor units. Cannot be a negative number.
sig { returns(Integer) }
attr_accessor :amount
# The tax behavior for the line item.
sig { returns(String) }
attr_accessor :behavior
sig { params(amount: Integer, behavior: String).void }
def initialize(amount: nil, behavior: nil); end
end
# Type of the line item.
sig { returns(T.nilable(String)) }
attr_accessor :category
# Description of the line item.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Descriptive name of the line item.
sig { returns(String) }
attr_accessor :name
# Quantity of the line item. Must be a positive number.
sig { returns(Integer) }
attr_accessor :quantity
# Client facing stock keeping unit, article number or similar.
sig { returns(T.nilable(String)) }
attr_accessor :sku
# The Stripe account ID of the connected account that sells the item.
sig { returns(T.nilable(String)) }
attr_accessor :sold_by
# The tax information for the line item.
sig {
returns(T.nilable(::Stripe::Order::CreateParams::Payment::Settings::PaymentMethodOptions::Paypal::LineItem::Tax))
}
attr_accessor :tax
# Price for a single unit of the line item in minor units. Cannot be a negative number.
sig { returns(Integer) }
attr_accessor :unit_amount
sig {
params(category: T.nilable(String), description: T.nilable(String), name: String, quantity: Integer, sku: T.nilable(String), sold_by: T.nilable(String), tax: T.nilable(::Stripe::Order::CreateParams::Payment::Settings::PaymentMethodOptions::Paypal::LineItem::Tax), unit_amount: Integer).void
}
def initialize(
category: nil,
description: nil,
name: nil,
quantity: nil,
sku: nil,
sold_by: nil,
tax: nil,
unit_amount: nil
); end
end
# Controls when the funds will be captured from the customer's account.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# The line items purchased by the customer.
sig {
returns(T.nilable(T::Array[::Stripe::Order::CreateParams::Payment::Settings::PaymentMethodOptions::Paypal::LineItem]))
}
attr_accessor :line_items
# [Preferred locale](https://stripe.com/docs/payments/paypal/supported-locales) of the PayPal checkout page that the customer is redirected to.
sig { returns(T.nilable(String)) }
attr_accessor :preferred_locale
# A reference of the PayPal transaction visible to customer which is mapped to PayPal's invoice ID. This must be a globally unique ID if you have configured in your PayPal settings to block multiple payments per invoice ID.
sig { returns(T.nilable(String)) }
attr_accessor :reference
# A reference of the PayPal transaction visible to customer which is mapped to PayPal's invoice ID. This must be a globally unique ID if you have configured in your PayPal settings to block multiple payments per invoice ID.
sig { returns(T.nilable(String)) }
attr_accessor :reference_id
# The risk correlation ID for an on-session payment using a saved PayPal payment method.
sig { returns(T.nilable(String)) }
attr_accessor :risk_correlation_id
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# The Stripe connected account IDs of the sellers on the platform for this transaction (optional). Only allowed when [separate charges and transfers](https://stripe.com/docs/connect/separate-charges-and-transfers) are used.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :subsellers
sig {
params(capture_method: T.nilable(T.nilable(String)), line_items: T.nilable(T::Array[::Stripe::Order::CreateParams::Payment::Settings::PaymentMethodOptions::Paypal::LineItem]), preferred_locale: T.nilable(String), reference: T.nilable(String), reference_id: T.nilable(String), risk_correlation_id: T.nilable(String), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), subsellers: T.nilable(T::Array[String])).void
}
def initialize(
capture_method: nil,
line_items: nil,
preferred_locale: nil,
reference: nil,
reference_id: nil,
risk_correlation_id: nil,
setup_future_usage: nil,
subsellers: nil
); end
end
class SepaDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'STRIPE'.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :reference_prefix
sig { params(reference_prefix: T.nilable(T.nilable(String))).void }
def initialize(reference_prefix: nil); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::Order::CreateParams::Payment::Settings::PaymentMethodOptions::SepaDebit::MandateOptions))
}
attr_accessor :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
sig {
params(mandate_options: T.nilable(::Stripe::Order::CreateParams::Payment::Settings::PaymentMethodOptions::SepaDebit::MandateOptions), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), target_date: T.nilable(String)).void
}
def initialize(mandate_options: nil, setup_future_usage: nil, target_date: nil); end
end
class Sofort < Stripe::RequestParams
# Language shown to the payer on redirect.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :preferred_language
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(preferred_language: T.nilable(T.nilable(T.any(String, String))), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(preferred_language: nil, setup_future_usage: nil); end
end
class WechatPay < Stripe::RequestParams
# The app ID registered with WeChat Pay. Only required when client is ios or android.
sig { returns(T.nilable(String)) }
attr_accessor :app_id
# The client type that the end customer will pay from
sig { returns(T.nilable(String)) }
attr_accessor :client
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(app_id: T.nilable(String), client: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(app_id: nil, client: nil, setup_future_usage: nil); end
end
# If paying by `acss_debit`, this sub-hash contains details about the ACSS Debit payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(::Stripe::Order::CreateParams::Payment::Settings::PaymentMethodOptions::AcssDebit))
}
attr_accessor :acss_debit
# If paying by `afterpay_clearpay`, this sub-hash contains details about the AfterpayClearpay payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(::Stripe::Order::CreateParams::Payment::Settings::PaymentMethodOptions::AfterpayClearpay))
}
attr_accessor :afterpay_clearpay
# If paying by `alipay`, this sub-hash contains details about the Alipay payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(::Stripe::Order::CreateParams::Payment::Settings::PaymentMethodOptions::Alipay))
}
attr_accessor :alipay
# If paying by `bancontact`, this sub-hash contains details about the Bancontact payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(::Stripe::Order::CreateParams::Payment::Settings::PaymentMethodOptions::Bancontact))
}
attr_accessor :bancontact
# If paying by `card`, this sub-hash contains details about the Card payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(::Stripe::Order::CreateParams::Payment::Settings::PaymentMethodOptions::Card))
}
attr_accessor :card
# If paying by `customer_balance`, this sub-hash contains details about the Customer Balance payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(::Stripe::Order::CreateParams::Payment::Settings::PaymentMethodOptions::CustomerBalance))
}
attr_accessor :customer_balance
# If paying by `ideal`, this sub-hash contains details about the iDEAL payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(::Stripe::Order::CreateParams::Payment::Settings::PaymentMethodOptions::Ideal))
}
attr_accessor :ideal
# If paying by `klarna`, this sub-hash contains details about the Klarna payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(::Stripe::Order::CreateParams::Payment::Settings::PaymentMethodOptions::Klarna))
}
attr_accessor :klarna
# If paying by `link`, this sub-hash contains details about the Link payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(::Stripe::Order::CreateParams::Payment::Settings::PaymentMethodOptions::Link))
}
attr_accessor :link
# If paying by `oxxo`, this sub-hash contains details about the OXXO payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(::Stripe::Order::CreateParams::Payment::Settings::PaymentMethodOptions::Oxxo))
}
attr_accessor :oxxo
# If paying by `p24`, this sub-hash contains details about the P24 payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(::Stripe::Order::CreateParams::Payment::Settings::PaymentMethodOptions::P24))
}
attr_accessor :p24
# If paying by `paypal`, this sub-hash contains details about the PayPal payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(::Stripe::Order::CreateParams::Payment::Settings::PaymentMethodOptions::Paypal))
}
attr_accessor :paypal
# If paying by `sepa_debit`, this sub-hash contains details about the SEPA Debit payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(::Stripe::Order::CreateParams::Payment::Settings::PaymentMethodOptions::SepaDebit))
}
attr_accessor :sepa_debit
# If paying by `sofort`, this sub-hash contains details about the Sofort payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(::Stripe::Order::CreateParams::Payment::Settings::PaymentMethodOptions::Sofort))
}
attr_accessor :sofort
# If paying by `wechat_pay`, this sub-hash contains details about the WeChat Pay payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(::Stripe::Order::CreateParams::Payment::Settings::PaymentMethodOptions::WechatPay))
}
attr_accessor :wechat_pay
sig {
params(acss_debit: T.nilable(::Stripe::Order::CreateParams::Payment::Settings::PaymentMethodOptions::AcssDebit), afterpay_clearpay: T.nilable(::Stripe::Order::CreateParams::Payment::Settings::PaymentMethodOptions::AfterpayClearpay), alipay: T.nilable(::Stripe::Order::CreateParams::Payment::Settings::PaymentMethodOptions::Alipay), bancontact: T.nilable(::Stripe::Order::CreateParams::Payment::Settings::PaymentMethodOptions::Bancontact), card: T.nilable(::Stripe::Order::CreateParams::Payment::Settings::PaymentMethodOptions::Card), customer_balance: T.nilable(::Stripe::Order::CreateParams::Payment::Settings::PaymentMethodOptions::CustomerBalance), ideal: T.nilable(::Stripe::Order::CreateParams::Payment::Settings::PaymentMethodOptions::Ideal), klarna: T.nilable(::Stripe::Order::CreateParams::Payment::Settings::PaymentMethodOptions::Klarna), link: T.nilable(::Stripe::Order::CreateParams::Payment::Settings::PaymentMethodOptions::Link), oxxo: T.nilable(::Stripe::Order::CreateParams::Payment::Settings::PaymentMethodOptions::Oxxo), p24: T.nilable(::Stripe::Order::CreateParams::Payment::Settings::PaymentMethodOptions::P24), paypal: T.nilable(::Stripe::Order::CreateParams::Payment::Settings::PaymentMethodOptions::Paypal), sepa_debit: T.nilable(::Stripe::Order::CreateParams::Payment::Settings::PaymentMethodOptions::SepaDebit), sofort: T.nilable(::Stripe::Order::CreateParams::Payment::Settings::PaymentMethodOptions::Sofort), wechat_pay: T.nilable(::Stripe::Order::CreateParams::Payment::Settings::PaymentMethodOptions::WechatPay)).void
}
def initialize(
acss_debit: nil,
afterpay_clearpay: nil,
alipay: nil,
bancontact: nil,
card: nil,
customer_balance: nil,
ideal: nil,
klarna: nil,
link: nil,
oxxo: nil,
p24: nil,
paypal: nil,
sepa_debit: nil,
sofort: nil,
wechat_pay: nil
); end
end
class TransferData < Stripe::RequestParams
# The amount that will be transferred automatically when the order is paid. If no amount is set, the full amount is transferred. There cannot be any line items with recurring prices when using this field.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# ID of the Connected account receiving the transfer.
sig { returns(String) }
attr_accessor :destination
sig { params(amount: T.nilable(Integer), destination: String).void }
def initialize(amount: nil, destination: nil); end
end
# The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account.
sig { returns(T.nilable(Integer)) }
attr_accessor :application_fee_amount
# PaymentMethod-specific configuration to provide to the order's PaymentIntent.
sig {
returns(T.nilable(::Stripe::Order::CreateParams::Payment::Settings::PaymentMethodOptions))
}
attr_accessor :payment_method_options
# The list of [payment method types](https://stripe.com/docs/payments/payment-methods/overview) to provide to the order's PaymentIntent. Do not include this attribute if you prefer to manage your payment methods from the [Stripe Dashboard](https://dashboard.stripe.com/settings/payment_methods).
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :payment_method_types
# The URL to redirect the customer to after they authenticate their payment.
sig { returns(T.nilable(String)) }
attr_accessor :return_url
# For non-card charges, you can use this value as the complete description that appears on your customers' statements. Must contain at least one letter, maximum 22 characters.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
# Provides information about a card payment that customers see on their statements. Concatenated with the prefix (shortened descriptor) or statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 22 characters for the concatenated descriptor.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor_suffix
# Provides configuration for completing a transfer for the order after it is paid.
sig { returns(T.nilable(::Stripe::Order::CreateParams::Payment::Settings::TransferData)) }
attr_accessor :transfer_data
sig {
params(application_fee_amount: T.nilable(Integer), payment_method_options: T.nilable(::Stripe::Order::CreateParams::Payment::Settings::PaymentMethodOptions), payment_method_types: T.nilable(T::Array[String]), return_url: T.nilable(String), statement_descriptor: T.nilable(String), statement_descriptor_suffix: T.nilable(String), transfer_data: T.nilable(::Stripe::Order::CreateParams::Payment::Settings::TransferData)).void
}
def initialize(
application_fee_amount: nil,
payment_method_options: nil,
payment_method_types: nil,
return_url: nil,
statement_descriptor: nil,
statement_descriptor_suffix: nil,
transfer_data: nil
); end
end
# Settings describing how the order should configure generated PaymentIntents.
sig { returns(::Stripe::Order::CreateParams::Payment::Settings) }
attr_accessor :settings
sig { params(settings: ::Stripe::Order::CreateParams::Payment::Settings).void }
def initialize(settings: nil); end
end
class ShippingCost < Stripe::RequestParams
class ShippingRateData < Stripe::RequestParams
class DeliveryEstimate < Stripe::RequestParams
class Maximum < Stripe::RequestParams
# A unit of time.
sig { returns(String) }
attr_accessor :unit
# Must be greater than 0.
sig { returns(Integer) }
attr_accessor :value
sig { params(unit: String, value: Integer).void }
def initialize(unit: nil, value: nil); end
end
class Minimum < Stripe::RequestParams
# A unit of time.
sig { returns(String) }
attr_accessor :unit
# Must be greater than 0.
sig { returns(Integer) }
attr_accessor :value
sig { params(unit: String, value: Integer).void }
def initialize(unit: nil, value: nil); end
end
# The upper bound of the estimated range. If empty, represents no upper bound i.e., infinite.
sig {
returns(T.nilable(::Stripe::Order::CreateParams::ShippingCost::ShippingRateData::DeliveryEstimate::Maximum))
}
attr_accessor :maximum
# The lower bound of the estimated range. If empty, represents no lower bound.
sig {
returns(T.nilable(::Stripe::Order::CreateParams::ShippingCost::ShippingRateData::DeliveryEstimate::Minimum))
}
attr_accessor :minimum
sig {
params(maximum: T.nilable(::Stripe::Order::CreateParams::ShippingCost::ShippingRateData::DeliveryEstimate::Maximum), minimum: T.nilable(::Stripe::Order::CreateParams::ShippingCost::ShippingRateData::DeliveryEstimate::Minimum)).void
}
def initialize(maximum: nil, minimum: nil); end
end
class FixedAmount < Stripe::RequestParams
class CurrencyOptions < Stripe::RequestParams
# A non-negative integer in cents representing how much to charge.
sig { returns(Integer) }
attr_accessor :amount
# Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
sig { params(amount: Integer, tax_behavior: T.nilable(String)).void }
def initialize(amount: nil, tax_behavior: nil); end
end
# A non-negative integer in cents representing how much to charge.
sig { returns(Integer) }
attr_accessor :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).
sig { returns(String) }
attr_accessor :currency
# Shipping rates defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
sig {
returns(T.nilable(T::Hash[String, ::Stripe::Order::CreateParams::ShippingCost::ShippingRateData::FixedAmount::CurrencyOptions]))
}
attr_accessor :currency_options
sig {
params(amount: Integer, currency: String, currency_options: T.nilable(T::Hash[String, ::Stripe::Order::CreateParams::ShippingCost::ShippingRateData::FixedAmount::CurrencyOptions])).void
}
def initialize(amount: nil, currency: nil, currency_options: nil); end
end
# The estimated range for how long shipping will take, meant to be displayable to the customer. This will appear on CheckoutSessions.
sig {
returns(T.nilable(::Stripe::Order::CreateParams::ShippingCost::ShippingRateData::DeliveryEstimate))
}
attr_accessor :delivery_estimate
# The name of the shipping rate, meant to be displayable to the customer. This will appear on CheckoutSessions.
sig { returns(String) }
attr_accessor :display_name
# Describes a fixed amount to charge for shipping. Must be present if type is `fixed_amount`.
sig {
returns(T.nilable(::Stripe::Order::CreateParams::ShippingCost::ShippingRateData::FixedAmount))
}
attr_accessor :fixed_amount
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID. The Shipping tax code is `txcd_92010001`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_code
# The type of calculation to use on the shipping rate.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(delivery_estimate: T.nilable(::Stripe::Order::CreateParams::ShippingCost::ShippingRateData::DeliveryEstimate), display_name: String, fixed_amount: T.nilable(::Stripe::Order::CreateParams::ShippingCost::ShippingRateData::FixedAmount), metadata: T.nilable(T::Hash[String, String]), tax_behavior: T.nilable(String), tax_code: T.nilable(String), type: T.nilable(String)).void
}
def initialize(
delivery_estimate: nil,
display_name: nil,
fixed_amount: nil,
metadata: nil,
tax_behavior: nil,
tax_code: nil,
type: nil
); end
end
# The ID of the shipping rate to use for this order.
sig { returns(T.nilable(String)) }
attr_accessor :shipping_rate
# Parameters to create a new ad-hoc shipping rate for this order.
sig { returns(T.nilable(::Stripe::Order::CreateParams::ShippingCost::ShippingRateData)) }
attr_accessor :shipping_rate_data
sig {
params(shipping_rate: T.nilable(String), shipping_rate_data: T.nilable(::Stripe::Order::CreateParams::ShippingCost::ShippingRateData)).void
}
def initialize(shipping_rate: nil, shipping_rate_data: nil); end
end
class ShippingDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State/province as an [ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2) subdivision code, without country prefix. Example: "NY" or "TX".
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# The shipping address for the order.
sig { returns(::Stripe::Order::CreateParams::ShippingDetails::Address) }
attr_accessor :address
# The name of the recipient of the order.
sig { returns(String) }
attr_accessor :name
# The phone number (including extension) for the recipient of the order.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :phone
sig {
params(address: ::Stripe::Order::CreateParams::ShippingDetails::Address, name: String, phone: T.nilable(T.nilable(String))).void
}
def initialize(address: nil, name: nil, phone: nil); end
end
class TaxDetails < Stripe::RequestParams
class TaxId < Stripe::RequestParams
# Type of the tax ID, one of `ad_nrt`, `ae_trn`, `al_tin`, `am_tin`, `ao_tin`, `ar_cuit`, `au_abn`, `au_arn`, `aw_tin`, `az_tin`, `ba_tin`, `bb_tin`, `bd_bin`, `bf_ifu`, `bg_uic`, `bh_vat`, `bj_ifu`, `bo_tin`, `br_cnpj`, `br_cpf`, `bs_tin`, `by_tin`, `ca_bn`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `ca_qst`, `cd_nif`, `ch_uid`, `ch_vat`, `cl_tin`, `cm_niu`, `cn_tin`, `co_nit`, `cr_tin`, `cv_nif`, `de_stn`, `do_rcn`, `ec_ruc`, `eg_tin`, `es_cif`, `et_tin`, `eu_oss_vat`, `eu_vat`, `gb_vat`, `ge_vat`, `gn_nif`, `hk_br`, `hr_oib`, `hu_tin`, `id_npwp`, `il_vat`, `in_gst`, `is_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `ke_pin`, `kg_tin`, `kh_tin`, `kr_brn`, `kz_bin`, `la_tin`, `li_uid`, `li_vat`, `ma_vat`, `md_vat`, `me_pib`, `mk_vat`, `mr_nif`, `mx_rfc`, `my_frp`, `my_itn`, `my_sst`, `ng_tin`, `no_vat`, `no_voec`, `np_pan`, `nz_gst`, `om_vat`, `pe_ruc`, `ph_tin`, `ro_tin`, `rs_pib`, `ru_inn`, `ru_kpp`, `sa_vat`, `sg_gst`, `sg_uen`, `si_tin`, `sn_ninea`, `sr_fin`, `sv_nit`, `th_vat`, `tj_tin`, `tr_tin`, `tw_vat`, `tz_vat`, `ua_vat`, `ug_tin`, `us_ein`, `uy_ruc`, `uz_tin`, `uz_vat`, `ve_rif`, `vn_tin`, `za_vat`, `zm_tin`, or `zw_tin`
sig { returns(String) }
attr_accessor :type
# Value of the tax ID.
sig { returns(String) }
attr_accessor :value
sig { params(type: String, value: String).void }
def initialize(type: nil, value: nil); end
end
# The purchaser's tax exemption status. One of `none`, `exempt`, or `reverse`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :tax_exempt
# The purchaser's tax IDs to be used for this order.
sig { returns(T.nilable(T::Array[::Stripe::Order::CreateParams::TaxDetails::TaxId])) }
attr_accessor :tax_ids
sig {
params(tax_exempt: T.nilable(T.nilable(T.any(String, String))), tax_ids: T.nilable(T::Array[::Stripe::Order::CreateParams::TaxDetails::TaxId])).void
}
def initialize(tax_exempt: nil, tax_ids: nil); end
end
# Settings for automatic tax calculation for this order.
sig { returns(T.nilable(::Stripe::Order::CreateParams::AutomaticTax)) }
attr_accessor :automatic_tax
# Billing details for the customer. If a customer is provided, this will be automatically populated with values from that customer if override values are not provided.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Order::CreateParams::BillingDetails))))
}
attr_accessor :billing_details
# 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).
sig { returns(String) }
attr_accessor :currency
# The customer associated with this order.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# The coupons, promotion codes, and/or discounts to apply to the order.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Order::CreateParams::Discount]))))
}
attr_accessor :discounts
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The IP address of the purchaser for this order.
sig { returns(T.nilable(String)) }
attr_accessor :ip_address
# A list of line items the customer is ordering. Each line item includes information about the product, the quantity, and the resulting cost.
sig { returns(T::Array[::Stripe::Order::CreateParams::LineItem]) }
attr_accessor :line_items
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Payment information associated with the order, including payment settings.
sig { returns(T.nilable(::Stripe::Order::CreateParams::Payment)) }
attr_accessor :payment
# Settings for the customer cost of shipping for this order.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Order::CreateParams::ShippingCost))))
}
attr_accessor :shipping_cost
# Shipping details for the order.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Order::CreateParams::ShippingDetails))))
}
attr_accessor :shipping_details
# Additional tax details about the purchaser to be used for this order.
sig { returns(T.nilable(::Stripe::Order::CreateParams::TaxDetails)) }
attr_accessor :tax_details
sig {
params(automatic_tax: T.nilable(::Stripe::Order::CreateParams::AutomaticTax), billing_details: T.nilable(T.nilable(T.any(String, ::Stripe::Order::CreateParams::BillingDetails))), currency: String, customer: T.nilable(String), description: T.nilable(String), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Order::CreateParams::Discount]))), expand: T.nilable(T::Array[String]), ip_address: T.nilable(String), line_items: T::Array[::Stripe::Order::CreateParams::LineItem], metadata: T.nilable(T::Hash[String, String]), payment: T.nilable(::Stripe::Order::CreateParams::Payment), shipping_cost: T.nilable(T.nilable(T.any(String, ::Stripe::Order::CreateParams::ShippingCost))), shipping_details: T.nilable(T.nilable(T.any(String, ::Stripe::Order::CreateParams::ShippingDetails))), tax_details: T.nilable(::Stripe::Order::CreateParams::TaxDetails)).void
}
def initialize(
automatic_tax: nil,
billing_details: nil,
currency: nil,
customer: nil,
description: nil,
discounts: nil,
expand: nil,
ip_address: nil,
line_items: nil,
metadata: nil,
payment: nil,
shipping_cost: nil,
shipping_details: nil,
tax_details: nil
); end
end
class UpdateParams < Stripe::RequestParams
class AutomaticTax < Stripe::RequestParams
# Enable automatic tax calculation which will automatically compute tax rates on this order.
sig { returns(T::Boolean) }
attr_accessor :enabled
sig { params(enabled: T::Boolean).void }
def initialize(enabled: nil); end
end
class BillingDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State/province as an [ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2) subdivision code, without country prefix. Example: "NY" or "TX".
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# The billing address provided by the customer.
sig { returns(T.nilable(::Stripe::Order::UpdateParams::BillingDetails::Address)) }
attr_accessor :address
# The billing email provided by the customer.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The billing name provided by the customer.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The billing phone number provided by the customer.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(address: T.nilable(::Stripe::Order::UpdateParams::BillingDetails::Address), email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(address: nil, email: nil, name: nil, phone: nil); end
end
class Discount < Stripe::RequestParams
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, promotion_code: nil); end
end
class LineItem < Stripe::RequestParams
class Discount < Stripe::RequestParams
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
sig { params(coupon: T.nilable(String), discount: T.nilable(String)).void }
def initialize(coupon: nil, discount: nil); end
end
class PriceData < Stripe::RequestParams
# 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).
sig { returns(T.nilable(String)) }
attr_accessor :currency
# ID of the [Product](https://docs.stripe.com/api/products) this [Price](https://docs.stripe.com/api/prices) belongs to.
#
# Use this to implement a variable-pricing model in your integration. This is required if `product_data` is not specified.
sig { returns(T.nilable(String)) }
attr_accessor :product
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: T.nilable(String), product: T.nilable(String), tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
class ProductData < Stripe::RequestParams
class PackageDimensions < Stripe::RequestParams
# Height, in inches. Maximum precision is 2 decimal places.
sig { returns(Float) }
attr_accessor :height
# Length, in inches. Maximum precision is 2 decimal places.
sig { returns(Float) }
attr_accessor :length
# Weight, in ounces. Maximum precision is 2 decimal places.
sig { returns(Float) }
attr_accessor :weight
# Width, in inches. Maximum precision is 2 decimal places.
sig { returns(Float) }
attr_accessor :width
sig { params(height: Float, length: Float, weight: Float, width: Float).void }
def initialize(height: nil, length: nil, weight: nil, width: nil); end
end
# The product's description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :description
# A unique identifier for this product.
#
# `product_data` automatically creates a Product with this ID. If a Product with the same ID already exists, then `product_data` re-uses it to avoid duplicates. If any of the fields in the existing Product are different from the values in `product_data`, `product_data` updates the existing Product with the new information. So set `product_data[id]` to the same string every time you sell the same product, but don't re-use the same string for different products.
sig { returns(String) }
attr_accessor :id
# A list of up to 8 URLs of images for this product, meant to be displayable to the customer.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :images
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# The product's name, meant to be displayable to the customer.
sig { returns(String) }
attr_accessor :name
# The dimensions of this product for shipping purposes.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Order::UpdateParams::LineItem::ProductData::PackageDimensions))))
}
attr_accessor :package_dimensions
# Whether this product is shipped (i.e., physical goods).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :shippable
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :tax_code
# A URL of a publicly-accessible webpage for this product.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :url
sig {
params(description: T.nilable(T.nilable(String)), id: String, images: T.nilable(T.nilable(T.any(String, T::Array[String]))), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), name: String, package_dimensions: T.nilable(T.nilable(T.any(String, ::Stripe::Order::UpdateParams::LineItem::ProductData::PackageDimensions))), shippable: T.nilable(T::Boolean), tax_code: T.nilable(T.nilable(String)), url: T.nilable(T.nilable(String))).void
}
def initialize(
description: nil,
id: nil,
images: nil,
metadata: nil,
name: nil,
package_dimensions: nil,
shippable: nil,
tax_code: nil,
url: nil
); end
end
# The description for the line item. Will default to the name of the associated product.
sig { returns(T.nilable(String)) }
attr_accessor :description
# The discounts applied to this line item.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Order::UpdateParams::LineItem::Discount]))))
}
attr_accessor :discounts
# The ID of an existing line item on the order.
sig { returns(T.nilable(String)) }
attr_accessor :id
# The ID of a [Price](https://docs.stripe.com/api/prices) to add to the Order.
#
# The `price` parameter is an alternative to using the `product` parameter. If each of your products are sold at a single price, you can set `Product.default_price` and then pass the `product` parameter when creating a line item. If your products are sold at several possible prices, use the `price` parameter to explicitly specify which one to use.
sig { returns(T.nilable(String)) }
attr_accessor :price
# Data used to generate a new Price object inline.
#
# The `price_data` parameter is an alternative to using the `product` or `price` parameters. If you create a Product upfront and configure a `Product.default_price`, pass the `product` parameter when creating a line item. If you prefer not to define Products upfront, or if you charge variable prices, pass the `price_data` parameter to describe the price for this line item.
#
# Each time you pass `price_data` we create a Price for the Product. This Price is hidden in both the Dashboard and API lists and cannot be reused.
sig { returns(T.nilable(::Stripe::Order::UpdateParams::LineItem::PriceData)) }
attr_accessor :price_data
# The ID of a [Product](https://docs.stripe.com/api/products) to add to the Order.
#
# The Product must have a `default_price` specified. Otherwise, specify the price by passing the `price` or `price_data` parameter.
sig { returns(T.nilable(String)) }
attr_accessor :product
# Defines a [Product](https://docs.stripe.com/api/products) inline and adds it to the Order.
#
# `product_data` is an alternative to the `product` parameter. If you created a Product upfront, use the `product` parameter to refer to the existing Product. But if you prefer not to create Products upfront, pass the `product_data` parameter to define a Product inline as part of configuring the Order.
#
# `product_data` automatically creates a Product, just as if you had manually created the Product. If a Product with the same ID already exists, then `product_data` re-uses it to avoid duplicates.
sig { returns(T.nilable(::Stripe::Order::UpdateParams::LineItem::ProductData)) }
attr_accessor :product_data
# The quantity of the line item.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# The tax rates applied to this line item.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
sig {
params(description: T.nilable(String), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Order::UpdateParams::LineItem::Discount]))), id: T.nilable(String), price: T.nilable(String), price_data: T.nilable(::Stripe::Order::UpdateParams::LineItem::PriceData), product: T.nilable(String), product_data: T.nilable(::Stripe::Order::UpdateParams::LineItem::ProductData), quantity: T.nilable(Integer), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String])))).void
}
def initialize(
description: nil,
discounts: nil,
id: nil,
price: nil,
price_data: nil,
product: nil,
product_data: nil,
quantity: nil,
tax_rates: nil
); end
end
class Payment < Stripe::RequestParams
class Settings < Stripe::RequestParams
class PaymentMethodOptions < Stripe::RequestParams
class AcssDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# A URL for custom mandate text to render during confirmation step.
# The URL will be rendered with additional GET parameters `payment_intent` and `payment_intent_client_secret` when confirming a Payment Intent,
# or `setup_intent` and `setup_intent_client_secret` when confirming a Setup Intent.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :custom_mandate_url
# Description of the mandate interval. Only required if 'payment_schedule' parameter is 'interval' or 'combined'.
sig { returns(T.nilable(String)) }
attr_accessor :interval_description
# Payment schedule for the mandate.
sig { returns(T.nilable(String)) }
attr_accessor :payment_schedule
# Transaction type of the mandate.
sig { returns(T.nilable(String)) }
attr_accessor :transaction_type
sig {
params(custom_mandate_url: T.nilable(T.nilable(String)), interval_description: T.nilable(String), payment_schedule: T.nilable(String), transaction_type: T.nilable(String)).void
}
def initialize(
custom_mandate_url: nil,
interval_description: nil,
payment_schedule: nil,
transaction_type: nil
); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::Order::UpdateParams::Payment::Settings::PaymentMethodOptions::AcssDebit::MandateOptions))
}
attr_accessor :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
# Bank account verification method.
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(mandate_options: T.nilable(::Stripe::Order::UpdateParams::Payment::Settings::PaymentMethodOptions::AcssDebit::MandateOptions), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), target_date: T.nilable(String), verification_method: T.nilable(String)).void
}
def initialize(
mandate_options: nil,
setup_future_usage: nil,
target_date: nil,
verification_method: nil
); end
end
class AfterpayClearpay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(String)) }
attr_accessor :capture_method
# An internal identifier or reference this payment corresponds to. The identifier is limited to 128 characters and may contain only letters, digits, underscores, backslashes and dashes.
sig { returns(T.nilable(String)) }
attr_accessor :reference
# Indicates that you intend to make future payments with the payment method.
#
# Providing this parameter will [attach the payment method](https://stripe.com/docs/payments/save-during-payment) to the order's Customer, if present, after the order's PaymentIntent is confirmed and any required actions from the user are complete. If no Customer was provided, the payment method can still be [attached](https://stripe.com/docs/api/payment_methods/attach) to a Customer after the transaction completes.
#
# When processing card payments, Stripe also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as [SCA](https://stripe.com/docs/strong-customer-authentication).
#
# If `setup_future_usage` is already set and you are performing a request using a publishable key, you may only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(String), reference: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(capture_method: nil, reference: nil, setup_future_usage: nil); end
end
class Alipay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void }
def initialize(setup_future_usage: nil); end
end
class Bancontact < Stripe::RequestParams
# Preferred language of the Bancontact authorization page that the customer is redirected to.
sig { returns(T.nilable(String)) }
attr_accessor :preferred_language
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(preferred_language: T.nilable(String), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(preferred_language: nil, setup_future_usage: nil); end
end
class Card < Stripe::RequestParams
# Controls when the funds will be captured from the customer's account.
sig { returns(T.nilable(String)) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with the payment method.
#
# Providing this parameter will [attach the payment method](https://stripe.com/docs/payments/save-during-payment) to the order's Customer, if present, after the order's PaymentIntent is confirmed and any required actions from the user are complete. If no Customer was provided, the payment method can still be [attached](https://stripe.com/docs/api/payment_methods/attach) to a Customer after the transaction completes.
#
# When processing card payments, Stripe also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as [SCA](https://stripe.com/docs/strong-customer-authentication).
#
# If `setup_future_usage` is already set and you are performing a request using a publishable key, you may only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class CustomerBalance < Stripe::RequestParams
class BankTransfer < Stripe::RequestParams
class EuBankTransfer < Stripe::RequestParams
# The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
sig { returns(String) }
attr_accessor :country
sig { params(country: String).void }
def initialize(country: nil); end
end
# Configuration for the eu_bank_transfer funding type.
sig {
returns(T.nilable(::Stripe::Order::UpdateParams::Payment::Settings::PaymentMethodOptions::CustomerBalance::BankTransfer::EuBankTransfer))
}
attr_accessor :eu_bank_transfer
# List of address types that should be returned in the financial_addresses response. If not specified, all valid types will be returned.
#
# Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :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`, `mx_bank_transfer`, or `us_bank_transfer`.
sig { returns(String) }
attr_accessor :type
sig {
params(eu_bank_transfer: T.nilable(::Stripe::Order::UpdateParams::Payment::Settings::PaymentMethodOptions::CustomerBalance::BankTransfer::EuBankTransfer), requested_address_types: T.nilable(T::Array[String]), type: String).void
}
def initialize(eu_bank_transfer: nil, requested_address_types: nil, type: nil); end
end
# Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
sig {
returns(T.nilable(::Stripe::Order::UpdateParams::Payment::Settings::PaymentMethodOptions::CustomerBalance::BankTransfer))
}
attr_accessor :bank_transfer
# The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
sig { returns(T.nilable(String)) }
attr_accessor :funding_type
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(bank_transfer: T.nilable(::Stripe::Order::UpdateParams::Payment::Settings::PaymentMethodOptions::CustomerBalance::BankTransfer), funding_type: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(bank_transfer: nil, funding_type: nil, setup_future_usage: nil); end
end
class Ideal < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void }
def initialize(setup_future_usage: nil); end
end
class Klarna < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Preferred language of the Klarna authorization page that the customer is redirected to
sig { returns(T.nilable(String)) }
attr_accessor :preferred_locale
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), preferred_locale: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(
capture_method: nil,
preferred_locale: nil,
setup_future_usage: nil
); end
end
class Link < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# [Deprecated] This is a legacy parameter that no longer has any function.
sig { returns(T.nilable(String)) }
attr_accessor :persistent_token
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), persistent_token: T.nilable(String), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(
capture_method: nil,
persistent_token: nil,
setup_future_usage: nil
); end
end
class Oxxo < Stripe::RequestParams
# The number of calendar days before an OXXO voucher expires. For example, if you create an OXXO voucher on Monday and you set expires_after_days to 2, the OXXO invoice will expire on Wednesday at 23:59 America/Mexico_City time.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_after_days
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(expires_after_days: T.nilable(Integer), setup_future_usage: T.nilable(String)).void
}
def initialize(expires_after_days: nil, setup_future_usage: nil); end
end
class P24 < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
# Confirm that the payer has accepted the P24 terms and conditions.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :tos_shown_and_accepted
sig {
params(setup_future_usage: T.nilable(String), tos_shown_and_accepted: T.nilable(T::Boolean)).void
}
def initialize(setup_future_usage: nil, tos_shown_and_accepted: nil); end
end
class Paypal < Stripe::RequestParams
class LineItem < Stripe::RequestParams
class Tax < Stripe::RequestParams
# The tax for a single unit of the line item in minor units. Cannot be a negative number.
sig { returns(Integer) }
attr_accessor :amount
# The tax behavior for the line item.
sig { returns(String) }
attr_accessor :behavior
sig { params(amount: Integer, behavior: String).void }
def initialize(amount: nil, behavior: nil); end
end
# Type of the line item.
sig { returns(T.nilable(String)) }
attr_accessor :category
# Description of the line item.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Descriptive name of the line item.
sig { returns(String) }
attr_accessor :name
# Quantity of the line item. Must be a positive number.
sig { returns(Integer) }
attr_accessor :quantity
# Client facing stock keeping unit, article number or similar.
sig { returns(T.nilable(String)) }
attr_accessor :sku
# The Stripe account ID of the connected account that sells the item.
sig { returns(T.nilable(String)) }
attr_accessor :sold_by
# The tax information for the line item.
sig {
returns(T.nilable(::Stripe::Order::UpdateParams::Payment::Settings::PaymentMethodOptions::Paypal::LineItem::Tax))
}
attr_accessor :tax
# Price for a single unit of the line item in minor units. Cannot be a negative number.
sig { returns(Integer) }
attr_accessor :unit_amount
sig {
params(category: T.nilable(String), description: T.nilable(String), name: String, quantity: Integer, sku: T.nilable(String), sold_by: T.nilable(String), tax: T.nilable(::Stripe::Order::UpdateParams::Payment::Settings::PaymentMethodOptions::Paypal::LineItem::Tax), unit_amount: Integer).void
}
def initialize(
category: nil,
description: nil,
name: nil,
quantity: nil,
sku: nil,
sold_by: nil,
tax: nil,
unit_amount: nil
); end
end
# Controls when the funds will be captured from the customer's account.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# The line items purchased by the customer.
sig {
returns(T.nilable(T::Array[::Stripe::Order::UpdateParams::Payment::Settings::PaymentMethodOptions::Paypal::LineItem]))
}
attr_accessor :line_items
# [Preferred locale](https://stripe.com/docs/payments/paypal/supported-locales) of the PayPal checkout page that the customer is redirected to.
sig { returns(T.nilable(String)) }
attr_accessor :preferred_locale
# A reference of the PayPal transaction visible to customer which is mapped to PayPal's invoice ID. This must be a globally unique ID if you have configured in your PayPal settings to block multiple payments per invoice ID.
sig { returns(T.nilable(String)) }
attr_accessor :reference
# A reference of the PayPal transaction visible to customer which is mapped to PayPal's invoice ID. This must be a globally unique ID if you have configured in your PayPal settings to block multiple payments per invoice ID.
sig { returns(T.nilable(String)) }
attr_accessor :reference_id
# The risk correlation ID for an on-session payment using a saved PayPal payment method.
sig { returns(T.nilable(String)) }
attr_accessor :risk_correlation_id
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# The Stripe connected account IDs of the sellers on the platform for this transaction (optional). Only allowed when [separate charges and transfers](https://stripe.com/docs/connect/separate-charges-and-transfers) are used.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :subsellers
sig {
params(capture_method: T.nilable(T.nilable(String)), line_items: T.nilable(T::Array[::Stripe::Order::UpdateParams::Payment::Settings::PaymentMethodOptions::Paypal::LineItem]), preferred_locale: T.nilable(String), reference: T.nilable(String), reference_id: T.nilable(String), risk_correlation_id: T.nilable(String), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), subsellers: T.nilable(T::Array[String])).void
}
def initialize(
capture_method: nil,
line_items: nil,
preferred_locale: nil,
reference: nil,
reference_id: nil,
risk_correlation_id: nil,
setup_future_usage: nil,
subsellers: nil
); end
end
class SepaDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'STRIPE'.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :reference_prefix
sig { params(reference_prefix: T.nilable(T.nilable(String))).void }
def initialize(reference_prefix: nil); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::Order::UpdateParams::Payment::Settings::PaymentMethodOptions::SepaDebit::MandateOptions))
}
attr_accessor :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
sig {
params(mandate_options: T.nilable(::Stripe::Order::UpdateParams::Payment::Settings::PaymentMethodOptions::SepaDebit::MandateOptions), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), target_date: T.nilable(String)).void
}
def initialize(mandate_options: nil, setup_future_usage: nil, target_date: nil); end
end
class Sofort < Stripe::RequestParams
# Language shown to the payer on redirect.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :preferred_language
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(preferred_language: T.nilable(T.nilable(T.any(String, String))), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(preferred_language: nil, setup_future_usage: nil); end
end
class WechatPay < Stripe::RequestParams
# The app ID registered with WeChat Pay. Only required when client is ios or android.
sig { returns(T.nilable(String)) }
attr_accessor :app_id
# The client type that the end customer will pay from
sig { returns(T.nilable(String)) }
attr_accessor :client
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(app_id: T.nilable(String), client: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(app_id: nil, client: nil, setup_future_usage: nil); end
end
# If paying by `acss_debit`, this sub-hash contains details about the ACSS Debit payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Order::UpdateParams::Payment::Settings::PaymentMethodOptions::AcssDebit))))
}
attr_accessor :acss_debit
# If paying by `afterpay_clearpay`, this sub-hash contains details about the AfterpayClearpay payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Order::UpdateParams::Payment::Settings::PaymentMethodOptions::AfterpayClearpay))))
}
attr_accessor :afterpay_clearpay
# If paying by `alipay`, this sub-hash contains details about the Alipay payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Order::UpdateParams::Payment::Settings::PaymentMethodOptions::Alipay))))
}
attr_accessor :alipay
# If paying by `bancontact`, this sub-hash contains details about the Bancontact payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Order::UpdateParams::Payment::Settings::PaymentMethodOptions::Bancontact))))
}
attr_accessor :bancontact
# If paying by `card`, this sub-hash contains details about the Card payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Order::UpdateParams::Payment::Settings::PaymentMethodOptions::Card))))
}
attr_accessor :card
# If paying by `customer_balance`, this sub-hash contains details about the Customer Balance payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Order::UpdateParams::Payment::Settings::PaymentMethodOptions::CustomerBalance))))
}
attr_accessor :customer_balance
# If paying by `ideal`, this sub-hash contains details about the iDEAL payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Order::UpdateParams::Payment::Settings::PaymentMethodOptions::Ideal))))
}
attr_accessor :ideal
# If paying by `klarna`, this sub-hash contains details about the Klarna payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Order::UpdateParams::Payment::Settings::PaymentMethodOptions::Klarna))))
}
attr_accessor :klarna
# If paying by `link`, this sub-hash contains details about the Link payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Order::UpdateParams::Payment::Settings::PaymentMethodOptions::Link))))
}
attr_accessor :link
# If paying by `oxxo`, this sub-hash contains details about the OXXO payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Order::UpdateParams::Payment::Settings::PaymentMethodOptions::Oxxo))))
}
attr_accessor :oxxo
# If paying by `p24`, this sub-hash contains details about the P24 payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Order::UpdateParams::Payment::Settings::PaymentMethodOptions::P24))))
}
attr_accessor :p24
# If paying by `paypal`, this sub-hash contains details about the PayPal payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Order::UpdateParams::Payment::Settings::PaymentMethodOptions::Paypal))))
}
attr_accessor :paypal
# If paying by `sepa_debit`, this sub-hash contains details about the SEPA Debit payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Order::UpdateParams::Payment::Settings::PaymentMethodOptions::SepaDebit))))
}
attr_accessor :sepa_debit
# If paying by `sofort`, this sub-hash contains details about the Sofort payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Order::UpdateParams::Payment::Settings::PaymentMethodOptions::Sofort))))
}
attr_accessor :sofort
# If paying by `wechat_pay`, this sub-hash contains details about the WeChat Pay payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Order::UpdateParams::Payment::Settings::PaymentMethodOptions::WechatPay))))
}
attr_accessor :wechat_pay
sig {
params(acss_debit: T.nilable(T.nilable(T.any(String, ::Stripe::Order::UpdateParams::Payment::Settings::PaymentMethodOptions::AcssDebit))), afterpay_clearpay: T.nilable(T.nilable(T.any(String, ::Stripe::Order::UpdateParams::Payment::Settings::PaymentMethodOptions::AfterpayClearpay))), alipay: T.nilable(T.nilable(T.any(String, ::Stripe::Order::UpdateParams::Payment::Settings::PaymentMethodOptions::Alipay))), bancontact: T.nilable(T.nilable(T.any(String, ::Stripe::Order::UpdateParams::Payment::Settings::PaymentMethodOptions::Bancontact))), card: T.nilable(T.nilable(T.any(String, ::Stripe::Order::UpdateParams::Payment::Settings::PaymentMethodOptions::Card))), customer_balance: T.nilable(T.nilable(T.any(String, ::Stripe::Order::UpdateParams::Payment::Settings::PaymentMethodOptions::CustomerBalance))), ideal: T.nilable(T.nilable(T.any(String, ::Stripe::Order::UpdateParams::Payment::Settings::PaymentMethodOptions::Ideal))), klarna: T.nilable(T.nilable(T.any(String, ::Stripe::Order::UpdateParams::Payment::Settings::PaymentMethodOptions::Klarna))), link: T.nilable(T.nilable(T.any(String, ::Stripe::Order::UpdateParams::Payment::Settings::PaymentMethodOptions::Link))), oxxo: T.nilable(T.nilable(T.any(String, ::Stripe::Order::UpdateParams::Payment::Settings::PaymentMethodOptions::Oxxo))), p24: T.nilable(T.nilable(T.any(String, ::Stripe::Order::UpdateParams::Payment::Settings::PaymentMethodOptions::P24))), paypal: T.nilable(T.nilable(T.any(String, ::Stripe::Order::UpdateParams::Payment::Settings::PaymentMethodOptions::Paypal))), sepa_debit: T.nilable(T.nilable(T.any(String, ::Stripe::Order::UpdateParams::Payment::Settings::PaymentMethodOptions::SepaDebit))), sofort: T.nilable(T.nilable(T.any(String, ::Stripe::Order::UpdateParams::Payment::Settings::PaymentMethodOptions::Sofort))), wechat_pay: T.nilable(T.nilable(T.any(String, ::Stripe::Order::UpdateParams::Payment::Settings::PaymentMethodOptions::WechatPay)))).void
}
def initialize(
acss_debit: nil,
afterpay_clearpay: nil,
alipay: nil,
bancontact: nil,
card: nil,
customer_balance: nil,
ideal: nil,
klarna: nil,
link: nil,
oxxo: nil,
p24: nil,
paypal: nil,
sepa_debit: nil,
sofort: nil,
wechat_pay: nil
); end
end
class TransferData < Stripe::RequestParams
# The amount that will be transferred automatically when the order is paid. If no amount is set, the full amount is transferred. There cannot be any line items with recurring prices when using this field.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# ID of the Connected account receiving the transfer.
sig { returns(String) }
attr_accessor :destination
sig { params(amount: T.nilable(Integer), destination: String).void }
def initialize(amount: nil, destination: nil); end
end
# The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :application_fee_amount
# PaymentMethod-specific configuration to provide to the order's PaymentIntent.
sig {
returns(T.nilable(::Stripe::Order::UpdateParams::Payment::Settings::PaymentMethodOptions))
}
attr_accessor :payment_method_options
# The list of [payment method types](https://stripe.com/docs/payments/payment-methods/overview) to provide to the order's PaymentIntent. Do not include this attribute if you prefer to manage your payment methods from the [Stripe Dashboard](https://dashboard.stripe.com/settings/payment_methods).
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :payment_method_types
# The URL to redirect the customer to after they authenticate their payment.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :return_url
# For non-card charges, you can use this value as the complete description that appears on your customers' statements. Must contain at least one letter, maximum 22 characters.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
# Provides information about a card payment that customers see on their statements. Concatenated with the prefix (shortened descriptor) or statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 22 characters for the concatenated descriptor.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor_suffix
# Provides configuration for completing a transfer for the order after it is paid.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Order::UpdateParams::Payment::Settings::TransferData))))
}
attr_accessor :transfer_data
sig {
params(application_fee_amount: T.nilable(T.nilable(T.any(String, Integer))), payment_method_options: T.nilable(::Stripe::Order::UpdateParams::Payment::Settings::PaymentMethodOptions), payment_method_types: T.nilable(T::Array[String]), return_url: T.nilable(T.nilable(String)), statement_descriptor: T.nilable(String), statement_descriptor_suffix: T.nilable(String), transfer_data: T.nilable(T.nilable(T.any(String, ::Stripe::Order::UpdateParams::Payment::Settings::TransferData)))).void
}
def initialize(
application_fee_amount: nil,
payment_method_options: nil,
payment_method_types: nil,
return_url: nil,
statement_descriptor: nil,
statement_descriptor_suffix: nil,
transfer_data: nil
); end
end
# Settings describing how the order should configure generated PaymentIntents.
sig { returns(::Stripe::Order::UpdateParams::Payment::Settings) }
attr_accessor :settings
sig { params(settings: ::Stripe::Order::UpdateParams::Payment::Settings).void }
def initialize(settings: nil); end
end
class ShippingCost < Stripe::RequestParams
class ShippingRateData < Stripe::RequestParams
class DeliveryEstimate < Stripe::RequestParams
class Maximum < Stripe::RequestParams
# A unit of time.
sig { returns(String) }
attr_accessor :unit
# Must be greater than 0.
sig { returns(Integer) }
attr_accessor :value
sig { params(unit: String, value: Integer).void }
def initialize(unit: nil, value: nil); end
end
class Minimum < Stripe::RequestParams
# A unit of time.
sig { returns(String) }
attr_accessor :unit
# Must be greater than 0.
sig { returns(Integer) }
attr_accessor :value
sig { params(unit: String, value: Integer).void }
def initialize(unit: nil, value: nil); end
end
# The upper bound of the estimated range. If empty, represents no upper bound i.e., infinite.
sig {
returns(T.nilable(::Stripe::Order::UpdateParams::ShippingCost::ShippingRateData::DeliveryEstimate::Maximum))
}
attr_accessor :maximum
# The lower bound of the estimated range. If empty, represents no lower bound.
sig {
returns(T.nilable(::Stripe::Order::UpdateParams::ShippingCost::ShippingRateData::DeliveryEstimate::Minimum))
}
attr_accessor :minimum
sig {
params(maximum: T.nilable(::Stripe::Order::UpdateParams::ShippingCost::ShippingRateData::DeliveryEstimate::Maximum), minimum: T.nilable(::Stripe::Order::UpdateParams::ShippingCost::ShippingRateData::DeliveryEstimate::Minimum)).void
}
def initialize(maximum: nil, minimum: nil); end
end
class FixedAmount < Stripe::RequestParams
class CurrencyOptions < Stripe::RequestParams
# A non-negative integer in cents representing how much to charge.
sig { returns(Integer) }
attr_accessor :amount
# Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
sig { params(amount: Integer, tax_behavior: T.nilable(String)).void }
def initialize(amount: nil, tax_behavior: nil); end
end
# A non-negative integer in cents representing how much to charge.
sig { returns(Integer) }
attr_accessor :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).
sig { returns(String) }
attr_accessor :currency
# Shipping rates defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
sig {
returns(T.nilable(T::Hash[String, ::Stripe::Order::UpdateParams::ShippingCost::ShippingRateData::FixedAmount::CurrencyOptions]))
}
attr_accessor :currency_options
sig {
params(amount: Integer, currency: String, currency_options: T.nilable(T::Hash[String, ::Stripe::Order::UpdateParams::ShippingCost::ShippingRateData::FixedAmount::CurrencyOptions])).void
}
def initialize(amount: nil, currency: nil, currency_options: nil); end
end
# The estimated range for how long shipping will take, meant to be displayable to the customer. This will appear on CheckoutSessions.
sig {
returns(T.nilable(::Stripe::Order::UpdateParams::ShippingCost::ShippingRateData::DeliveryEstimate))
}
attr_accessor :delivery_estimate
# The name of the shipping rate, meant to be displayable to the customer. This will appear on CheckoutSessions.
sig { returns(String) }
attr_accessor :display_name
# Describes a fixed amount to charge for shipping. Must be present if type is `fixed_amount`.
sig {
returns(T.nilable(::Stripe::Order::UpdateParams::ShippingCost::ShippingRateData::FixedAmount))
}
attr_accessor :fixed_amount
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID. The Shipping tax code is `txcd_92010001`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_code
# The type of calculation to use on the shipping rate.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(delivery_estimate: T.nilable(::Stripe::Order::UpdateParams::ShippingCost::ShippingRateData::DeliveryEstimate), display_name: String, fixed_amount: T.nilable(::Stripe::Order::UpdateParams::ShippingCost::ShippingRateData::FixedAmount), metadata: T.nilable(T::Hash[String, String]), tax_behavior: T.nilable(String), tax_code: T.nilable(String), type: T.nilable(String)).void
}
def initialize(
delivery_estimate: nil,
display_name: nil,
fixed_amount: nil,
metadata: nil,
tax_behavior: nil,
tax_code: nil,
type: nil
); end
end
# The ID of the shipping rate to use for this order.
sig { returns(T.nilable(String)) }
attr_accessor :shipping_rate
# Parameters to create a new ad-hoc shipping rate for this order.
sig { returns(T.nilable(::Stripe::Order::UpdateParams::ShippingCost::ShippingRateData)) }
attr_accessor :shipping_rate_data
sig {
params(shipping_rate: T.nilable(String), shipping_rate_data: T.nilable(::Stripe::Order::UpdateParams::ShippingCost::ShippingRateData)).void
}
def initialize(shipping_rate: nil, shipping_rate_data: nil); end
end
class ShippingDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State/province as an [ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2) subdivision code, without country prefix. Example: "NY" or "TX".
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# The shipping address for the order.
sig { returns(::Stripe::Order::UpdateParams::ShippingDetails::Address) }
attr_accessor :address
# The name of the recipient of the order.
sig { returns(String) }
attr_accessor :name
# The phone number (including extension) for the recipient of the order.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :phone
sig {
params(address: ::Stripe::Order::UpdateParams::ShippingDetails::Address, name: String, phone: T.nilable(T.nilable(String))).void
}
def initialize(address: nil, name: nil, phone: nil); end
end
class TaxDetails < Stripe::RequestParams
class TaxId < Stripe::RequestParams
# Type of the tax ID, one of `ad_nrt`, `ae_trn`, `al_tin`, `am_tin`, `ao_tin`, `ar_cuit`, `au_abn`, `au_arn`, `aw_tin`, `az_tin`, `ba_tin`, `bb_tin`, `bd_bin`, `bf_ifu`, `bg_uic`, `bh_vat`, `bj_ifu`, `bo_tin`, `br_cnpj`, `br_cpf`, `bs_tin`, `by_tin`, `ca_bn`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `ca_qst`, `cd_nif`, `ch_uid`, `ch_vat`, `cl_tin`, `cm_niu`, `cn_tin`, `co_nit`, `cr_tin`, `cv_nif`, `de_stn`, `do_rcn`, `ec_ruc`, `eg_tin`, `es_cif`, `et_tin`, `eu_oss_vat`, `eu_vat`, `gb_vat`, `ge_vat`, `gn_nif`, `hk_br`, `hr_oib`, `hu_tin`, `id_npwp`, `il_vat`, `in_gst`, `is_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `ke_pin`, `kg_tin`, `kh_tin`, `kr_brn`, `kz_bin`, `la_tin`, `li_uid`, `li_vat`, `ma_vat`, `md_vat`, `me_pib`, `mk_vat`, `mr_nif`, `mx_rfc`, `my_frp`, `my_itn`, `my_sst`, `ng_tin`, `no_vat`, `no_voec`, `np_pan`, `nz_gst`, `om_vat`, `pe_ruc`, `ph_tin`, `ro_tin`, `rs_pib`, `ru_inn`, `ru_kpp`, `sa_vat`, `sg_gst`, `sg_uen`, `si_tin`, `sn_ninea`, `sr_fin`, `sv_nit`, `th_vat`, `tj_tin`, `tr_tin`, `tw_vat`, `tz_vat`, `ua_vat`, `ug_tin`, `us_ein`, `uy_ruc`, `uz_tin`, `uz_vat`, `ve_rif`, `vn_tin`, `za_vat`, `zm_tin`, or `zw_tin`
sig { returns(String) }
attr_accessor :type
# Value of the tax ID.
sig { returns(String) }
attr_accessor :value
sig { params(type: String, value: String).void }
def initialize(type: nil, value: nil); end
end
# The purchaser's tax exemption status. One of `none`, `exempt`, or `reverse`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :tax_exempt
# The purchaser's tax IDs to be used for this order.
sig { returns(T.nilable(T::Array[::Stripe::Order::UpdateParams::TaxDetails::TaxId])) }
attr_accessor :tax_ids
sig {
params(tax_exempt: T.nilable(T.nilable(T.any(String, String))), tax_ids: T.nilable(T::Array[::Stripe::Order::UpdateParams::TaxDetails::TaxId])).void
}
def initialize(tax_exempt: nil, tax_ids: nil); end
end
# Settings for automatic tax calculation for this order.
sig { returns(T.nilable(::Stripe::Order::UpdateParams::AutomaticTax)) }
attr_accessor :automatic_tax
# Billing details for the customer. If a customer is provided, this will be automatically populated with values from that customer if override values are not provided.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Order::UpdateParams::BillingDetails))))
}
attr_accessor :billing_details
# 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).
sig { returns(T.nilable(String)) }
attr_accessor :currency
# The customer associated with this order.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :description
# The coupons, promotion codes, and/or discounts to apply to the order. Pass the empty string `""` to unset this field.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Order::UpdateParams::Discount]))))
}
attr_accessor :discounts
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The IP address of the purchaser for this order.
sig { returns(T.nilable(String)) }
attr_accessor :ip_address
# A list of line items the customer is ordering. Each line item includes information about the product, the quantity, and the resulting cost.
sig { returns(T.nilable(T::Array[::Stripe::Order::UpdateParams::LineItem])) }
attr_accessor :line_items
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Payment information associated with the order, including payment settings.
sig { returns(T.nilable(::Stripe::Order::UpdateParams::Payment)) }
attr_accessor :payment
# Settings for the customer cost of shipping for this order.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Order::UpdateParams::ShippingCost))))
}
attr_accessor :shipping_cost
# Shipping details for the order.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Order::UpdateParams::ShippingDetails))))
}
attr_accessor :shipping_details
# Additional tax details about the purchaser to be used for this order.
sig { returns(T.nilable(::Stripe::Order::UpdateParams::TaxDetails)) }
attr_accessor :tax_details
sig {
params(automatic_tax: T.nilable(::Stripe::Order::UpdateParams::AutomaticTax), billing_details: T.nilable(T.nilable(T.any(String, ::Stripe::Order::UpdateParams::BillingDetails))), currency: T.nilable(String), customer: T.nilable(String), description: T.nilable(T.nilable(String)), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Order::UpdateParams::Discount]))), expand: T.nilable(T::Array[String]), ip_address: T.nilable(String), line_items: T.nilable(T::Array[::Stripe::Order::UpdateParams::LineItem]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), payment: T.nilable(::Stripe::Order::UpdateParams::Payment), shipping_cost: T.nilable(T.nilable(T.any(String, ::Stripe::Order::UpdateParams::ShippingCost))), shipping_details: T.nilable(T.nilable(T.any(String, ::Stripe::Order::UpdateParams::ShippingDetails))), tax_details: T.nilable(::Stripe::Order::UpdateParams::TaxDetails)).void
}
def initialize(
automatic_tax: nil,
billing_details: nil,
currency: nil,
customer: nil,
description: nil,
discounts: nil,
expand: nil,
ip_address: nil,
line_items: nil,
metadata: nil,
payment: nil,
shipping_cost: nil,
shipping_details: nil,
tax_details: nil
); end
end
class ListLineItemsParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
class CancelParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class ReopenParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class SubmitParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# `expected_total` should always be set to the order's `amount_total` field. If they don't match, submitting the order will fail. This helps detect race conditions where something else concurrently modifies the order.
sig { returns(Integer) }
attr_accessor :expected_total
sig { params(expand: T.nilable(T::Array[String]), expected_total: Integer).void }
def initialize(expand: nil, expected_total: nil); end
end
# Cancels the order as well as the payment intent if one is attached.
sig {
params(params: T.any(::Stripe::Order::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Order)
}
def cancel(params = {}, opts = {}); end
# Cancels the order as well as the payment intent if one is attached.
sig {
params(id: String, params: T.any(::Stripe::Order::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Order)
}
def self.cancel(id, params = {}, opts = {}); end
# Creates a new open order object.
sig {
params(params: T.any(::Stripe::Order::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Order)
}
def self.create(params = {}, opts = {}); end
# Returns a list of your orders. The orders are returned sorted by creation date, with the most recently created orders appearing first.
sig {
params(params: T.any(::Stripe::Order::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# When retrieving an order, there is an includable line_items property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items.
sig {
params(params: T.any(::Stripe::Order::ListLineItemsParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list_line_items(params = {}, opts = {}); end
# When retrieving an order, there is an includable line_items property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items.
sig {
params(id: String, params: T.any(::Stripe::Order::ListLineItemsParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list_line_items(id, params = {}, opts = {}); end
# Reopens a submitted order.
sig {
params(params: T.any(::Stripe::Order::ReopenParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Order)
}
def reopen(params = {}, opts = {}); end
# Reopens a submitted order.
sig {
params(id: String, params: T.any(::Stripe::Order::ReopenParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Order)
}
def self.reopen(id, params = {}, opts = {}); end
# Submitting an Order transitions the status to processing and creates a PaymentIntent object so the order can be paid. If the Order has an amount_total of 0, no PaymentIntent object will be created. Once the order is submitted, its contents cannot be changed, unless the [reopen](https://docs.stripe.com/api#reopen_order) method is called.
sig {
params(params: T.any(::Stripe::Order::SubmitParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Order)
}
def submit(params = {}, opts = {}); end
# Submitting an Order transitions the status to processing and creates a PaymentIntent object so the order can be paid. If the Order has an amount_total of 0, no PaymentIntent object will be created. Once the order is submitted, its contents cannot be changed, unless the [reopen](https://docs.stripe.com/api#reopen_order) method is called.
sig {
params(id: String, params: T.any(::Stripe::Order::SubmitParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Order)
}
def self.submit(id, params = {}, opts = {}); end
# Updates the specific order by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
sig {
params(id: String, params: T.any(::Stripe::Order::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Order)
}
def self.update(id, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
# A Payment Attempt Record represents an individual attempt at making a payment, on or off Stripe.
# Each payment attempt tries to collect a fixed amount of money from a fixed customer and payment
# method. Payment Attempt Records are attached to Payment Records. Only one attempt per Payment Record
# can have guaranteed funds.
class PaymentAttemptRecord < APIResource
class AmountCanceled < Stripe::StripeObject
# 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).
sig { returns(String) }
attr_reader :currency
# A positive integer representing the amount in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) for example, 100 cents for 1 USD or 100 for 100 JPY, a zero-decimal currency.
sig { returns(Integer) }
attr_reader :value
end
class AmountFailed < Stripe::StripeObject
# 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).
sig { returns(String) }
attr_reader :currency
# A positive integer representing the amount in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) for example, 100 cents for 1 USD or 100 for 100 JPY, a zero-decimal currency.
sig { returns(Integer) }
attr_reader :value
end
class AmountGuaranteed < Stripe::StripeObject
# 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).
sig { returns(String) }
attr_reader :currency
# A positive integer representing the amount in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) for example, 100 cents for 1 USD or 100 for 100 JPY, a zero-decimal currency.
sig { returns(Integer) }
attr_reader :value
end
class AmountRequested < Stripe::StripeObject
# 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).
sig { returns(String) }
attr_reader :currency
# A positive integer representing the amount in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) for example, 100 cents for 1 USD or 100 for 100 JPY, a zero-decimal currency.
sig { returns(Integer) }
attr_reader :value
end
class CustomerDetails < Stripe::StripeObject
# ID of the Stripe Customer associated with this payment.
sig { returns(T.nilable(String)) }
attr_reader :customer
# The customer's email address.
sig { returns(T.nilable(String)) }
attr_reader :email
# The customer's name.
sig { returns(T.nilable(String)) }
attr_reader :name
# The customer's phone number.
sig { returns(T.nilable(String)) }
attr_reader :phone
end
class PaymentMethodDetails < Stripe::StripeObject
class AchCreditTransfer < Stripe::StripeObject
# Account number to transfer funds to.
sig { returns(T.nilable(String)) }
attr_reader :account_number
# Name of the bank associated with the routing number.
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# Routing transit number for the bank account to transfer funds to.
sig { returns(T.nilable(String)) }
attr_reader :routing_number
# SWIFT code of the bank associated with the routing number.
sig { returns(T.nilable(String)) }
attr_reader :swift_code
end
class AchDebit < Stripe::StripeObject
# Type of entity that holds the account. This can be either `individual` or `company`.
sig { returns(T.nilable(String)) }
attr_reader :account_holder_type
# Name of the bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# Two-letter ISO code representing the country the bank account is located in.
sig { returns(T.nilable(String)) }
attr_reader :country
# Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Last four digits of the bank account number.
sig { returns(T.nilable(String)) }
attr_reader :last4
# Routing transit number of the bank account.
sig { returns(T.nilable(String)) }
attr_reader :routing_number
end
class AcssDebit < Stripe::StripeObject
# Name of the bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Institution number of the bank account
sig { returns(T.nilable(String)) }
attr_reader :institution_number
# Last four digits of the bank account number.
sig { returns(T.nilable(String)) }
attr_reader :last4
# ID of the mandate used to make this payment.
sig { returns(String) }
attr_reader :mandate
# Transit number of the bank account.
sig { returns(T.nilable(String)) }
attr_reader :transit_number
end
class Affirm < Stripe::StripeObject
# ID of the [location](https://stripe.com/docs/api/terminal/locations) that this transaction's reader is assigned to.
sig { returns(String) }
attr_reader :location
# ID of the [reader](https://stripe.com/docs/api/terminal/readers) this transaction was made on.
sig { returns(String) }
attr_reader :reader
# The Affirm transaction ID associated with this payment.
sig { returns(T.nilable(String)) }
attr_reader :transaction_id
end
class AfterpayClearpay < Stripe::StripeObject
# The Afterpay order ID associated with this payment intent.
sig { returns(T.nilable(String)) }
attr_reader :order_id
# Order identifier shown to the merchant in Afterpay’s online portal.
sig { returns(T.nilable(String)) }
attr_reader :reference
end
class Alipay < Stripe::StripeObject
# Uniquely identifies this particular Alipay account. You can use this attribute to check whether two Alipay accounts are the same.
sig { returns(String) }
attr_reader :buyer_id
# Uniquely identifies this particular Alipay account. You can use this attribute to check whether two Alipay accounts are the same.
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Transaction ID of this particular Alipay transaction.
sig { returns(T.nilable(String)) }
attr_reader :transaction_id
end
class Alma < Stripe::StripeObject; end
class AmazonPay < Stripe::StripeObject
class Funding < Stripe::StripeObject
class Card < Stripe::StripeObject
# Card brand. Can be `amex`, `diners`, `discover`, `eftpos_au`, `jcb`, `link`, `mastercard`, `unionpay`, `visa`, or `unknown`.
sig { returns(T.nilable(String)) }
attr_reader :brand
# The [product code](https://stripe.com/docs/card-product-codes) that identifies the specific program or product associated with a card. (For internal use only and not typically available in standard API requests.)
sig { returns(T.nilable(String)) }
attr_reader :brand_product
# 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.
sig { returns(T.nilable(String)) }
attr_reader :country
# Two-digit number representing the card's expiration month.
sig { returns(T.nilable(Integer)) }
attr_reader :exp_month
# Four-digit number representing the card's expiration year.
sig { returns(T.nilable(Integer)) }
attr_reader :exp_year
# Card funding type. Can be `credit`, `debit`, `prepaid`, or `unknown`.
sig { returns(T.nilable(String)) }
attr_reader :funding
# The last four digits of the card.
sig { returns(T.nilable(String)) }
attr_reader :last4
end
# Attribute for field card
sig { returns(Card) }
attr_reader :card
# funding type of the underlying payment method.
sig { returns(T.nilable(String)) }
attr_reader :type
end
# Attribute for field funding
sig { returns(Funding) }
attr_reader :funding
end
class AuBecsDebit < Stripe::StripeObject
# Bank-State-Branch number of the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bsb_number
# Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Last four digits of the bank account number.
sig { returns(T.nilable(String)) }
attr_reader :last4
# ID of the mandate used to make this payment.
sig { returns(String) }
attr_reader :mandate
end
class BacsDebit < Stripe::StripeObject
# Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Last four digits of the bank account number.
sig { returns(T.nilable(String)) }
attr_reader :last4
# ID of the mandate used to make this payment.
sig { returns(T.nilable(String)) }
attr_reader :mandate
# Sort code of the bank account. (e.g., `10-20-30`)
sig { returns(T.nilable(String)) }
attr_reader :sort_code
end
class Bancontact < Stripe::StripeObject
# Bank code of bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_code
# Name of the bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# Bank Identifier Code of the bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bic
# The ID of the SEPA Direct Debit PaymentMethod which was generated by this Charge.
sig { returns(T.nilable(T.any(String, Stripe::PaymentMethod))) }
attr_reader :generated_sepa_debit
# The mandate for the SEPA Direct Debit PaymentMethod which was generated by this Charge.
sig { returns(T.nilable(T.any(String, Stripe::Mandate))) }
attr_reader :generated_sepa_debit_mandate
# Last four characters of the IBAN.
sig { returns(T.nilable(String)) }
attr_reader :iban_last4
# Preferred language of the Bancontact authorization page that the customer is redirected to.
# Can be one of `en`, `de`, `fr`, or `nl`
sig { returns(T.nilable(String)) }
attr_reader :preferred_language
# Owner's verified full name. Values are verified or provided by Bancontact directly
# (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(String)) }
attr_reader :verified_name
end
class Billie < Stripe::StripeObject; end
class BillingDetails < Stripe::StripeObject
class Address < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# A representation of a physical address.
sig { returns(Address) }
attr_reader :address
# The billing email associated with the method of payment.
sig { returns(T.nilable(String)) }
attr_reader :email
# The billing name associated with the method of payment.
sig { returns(T.nilable(String)) }
attr_reader :name
# The billing phone number associated with the method of payment.
sig { returns(T.nilable(String)) }
attr_reader :phone
end
class Blik < Stripe::StripeObject
# A unique and immutable identifier assigned by BLIK to every buyer.
sig { returns(T.nilable(String)) }
attr_reader :buyer_id
end
class Boleto < Stripe::StripeObject
# The tax ID of the customer (CPF for individuals consumers or CNPJ for businesses consumers)
sig { returns(String) }
attr_reader :tax_id
end
class Card < Stripe::StripeObject
class Checks < Stripe::StripeObject
# Attribute for field address_line1_check
sig { returns(T.nilable(String)) }
attr_reader :address_line1_check
# Attribute for field address_postal_code_check
sig { returns(T.nilable(String)) }
attr_reader :address_postal_code_check
# Attribute for field cvc_check
sig { returns(T.nilable(String)) }
attr_reader :cvc_check
end
class NetworkToken < Stripe::StripeObject
# Attribute for field used
sig { returns(T::Boolean) }
attr_reader :used
end
class ThreeDSecure < Stripe::StripeObject
# Attribute for field authentication_flow
sig { returns(T.nilable(String)) }
attr_reader :authentication_flow
# Attribute for field result
sig { returns(T.nilable(String)) }
attr_reader :result
# Attribute for field result_reason
sig { returns(T.nilable(String)) }
attr_reader :result_reason
# Attribute for field version
sig { returns(T.nilable(String)) }
attr_reader :version
end
# Card brand. Can be `amex`, `diners`, `discover`, `eftpos_au`, `jcb`, `link`, `mastercard`, `unionpay`, `visa`, or `unknown`.
sig { returns(String) }
attr_reader :brand
# When using manual capture, a future timestamp at which the charge will be automatically refunded if uncaptured.
sig { returns(Integer) }
attr_reader :capture_before
# Check results by Card networks on Card address and CVC at time of payment.
sig { returns(T.nilable(Checks)) }
attr_reader :checks
# 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.
sig { returns(T.nilable(String)) }
attr_reader :country
# Two-digit number representing the card's expiration month.
sig { returns(Integer) }
attr_reader :exp_month
# Four-digit number representing the card's expiration year.
sig { returns(Integer) }
attr_reader :exp_year
# Uniquely identifies this particular card number. You can use this attribute to check whether two customers who’ve signed up with you are using the same card number, for example. For payment methods that tokenize card information (Apple Pay, Google Pay), the tokenized number might be provided instead of the underlying card number.
#
# *As of May 1, 2021, card fingerprint in India for Connect changed to allow two fingerprints for the same card---one for India and one for the rest of the world.*
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Card funding type. Can be `credit`, `debit`, `prepaid`, or `unknown`.
sig { returns(String) }
attr_reader :funding
# The last four digits of the card.
sig { returns(String) }
attr_reader :last4
# True if this payment was marked as MOTO and out of scope for SCA.
sig { returns(T::Boolean) }
attr_reader :moto
# Identifies which network this charge was processed on. Can be `amex`, `cartes_bancaires`, `diners`, `discover`, `eftpos_au`, `interac`, `jcb`, `link`, `mastercard`, `unionpay`, `visa`, or `unknown`.
sig { returns(T.nilable(String)) }
attr_reader :network
# If this card has network token credentials, this contains the details of the network token credentials.
sig { returns(T.nilable(NetworkToken)) }
attr_reader :network_token
# This is used by the financial networks to identify a transaction. Visa calls this the Transaction ID, Mastercard calls this the Trace ID, and American Express calls this the Acquirer Reference Data. This value will be present if it is returned by the financial network in the authorization response, and null otherwise.
sig { returns(T.nilable(String)) }
attr_reader :network_transaction_id
# Populated if this transaction used 3D Secure authentication.
sig { returns(T.nilable(ThreeDSecure)) }
attr_reader :three_d_secure
end
class CardPresent < Stripe::StripeObject
class Offline < Stripe::StripeObject
# Time at which the payment was collected while offline
sig { returns(T.nilable(Integer)) }
attr_reader :stored_at
# The method used to process this payment method offline. Only deferred is allowed.
sig { returns(T.nilable(String)) }
attr_reader :type
end
class Receipt < Stripe::StripeObject
# The type of account being debited or credited
sig { returns(String) }
attr_reader :account_type
# EMV tag 9F26, cryptogram generated by the integrated circuit chip.
sig { returns(T.nilable(String)) }
attr_reader :application_cryptogram
# Mnenomic of the Application Identifier.
sig { returns(T.nilable(String)) }
attr_reader :application_preferred_name
# Identifier for this transaction.
sig { returns(T.nilable(String)) }
attr_reader :authorization_code
# EMV tag 8A. A code returned by the card issuer.
sig { returns(T.nilable(String)) }
attr_reader :authorization_response_code
# Describes the method used by the cardholder to verify ownership of the card. One of the following: `approval`, `failure`, `none`, `offline_pin`, `offline_pin_and_signature`, `online_pin`, or `signature`.
sig { returns(T.nilable(String)) }
attr_reader :cardholder_verification_method
# EMV tag 84. Similar to the application identifier stored on the integrated circuit chip.
sig { returns(T.nilable(String)) }
attr_reader :dedicated_file_name
# The outcome of a series of EMV functions performed by the card reader.
sig { returns(T.nilable(String)) }
attr_reader :terminal_verification_results
# An indication of various EMV functions performed during the transaction.
sig { returns(T.nilable(String)) }
attr_reader :transaction_status_information
end
class Wallet < Stripe::StripeObject
# The type of mobile wallet, one of `apple_pay`, `google_pay`, `samsung_pay`, or `unknown`.
sig { returns(String) }
attr_reader :type
end
# The authorized amount
sig { returns(T.nilable(Integer)) }
attr_reader :amount_authorized
# Card brand. Can be `amex`, `diners`, `discover`, `eftpos_au`, `jcb`, `link`, `mastercard`, `unionpay`, `visa`, or `unknown`.
sig { returns(T.nilable(String)) }
attr_reader :brand
# The [product code](https://stripe.com/docs/card-product-codes) that identifies the specific program or product associated with a card.
sig { returns(T.nilable(String)) }
attr_reader :brand_product
# When using manual capture, a future timestamp after which the charge will be automatically refunded if uncaptured.
sig { returns(Integer) }
attr_reader :capture_before
# The cardholder name as read from the card, in [ISO 7813](https://en.wikipedia.org/wiki/ISO/IEC_7813) format. May include alphanumeric characters, special characters and first/last name separator (`/`). In some cases, the cardholder name may not be available depending on how the issuer has configured the card. Cardholder name is typically not available on swipe or contactless payments, such as those made with Apple Pay and Google Pay.
sig { returns(T.nilable(String)) }
attr_reader :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.
sig { returns(T.nilable(String)) }
attr_reader :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.)
sig { returns(T.nilable(String)) }
attr_reader :description
# Authorization response cryptogram.
sig { returns(T.nilable(String)) }
attr_reader :emv_auth_data
# Two-digit number representing the card's expiration month.
sig { returns(Integer) }
attr_reader :exp_month
# Four-digit number representing the card's expiration year.
sig { returns(Integer) }
attr_reader :exp_year
# Uniquely identifies this particular card number. You can use this attribute to check whether two customers who’ve signed up with you are using the same card number, for example. For payment methods that tokenize card information (Apple Pay, Google Pay), the tokenized number might be provided instead of the underlying card number.
#
# *As of May 1, 2021, card fingerprint in India for Connect changed to allow two fingerprints for the same card---one for India and one for the rest of the world.*
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Card funding type. Can be `credit`, `debit`, `prepaid`, or `unknown`.
sig { returns(T.nilable(String)) }
attr_reader :funding
# ID of a card PaymentMethod generated from the card_present PaymentMethod that may be attached to a Customer for future transactions. Only present if it was possible to generate a card PaymentMethod.
sig { returns(T.nilable(String)) }
attr_reader :generated_card
# Issuer identification number of the card. (For internal use only and not typically available in standard API requests.)
sig { returns(T.nilable(String)) }
attr_reader :iin
# Whether this [PaymentIntent](https://stripe.com/docs/api/payment_intents) is eligible for incremental authorizations. Request support using [request_incremental_authorization_support](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-payment_method_options-card_present-request_incremental_authorization_support).
sig { returns(T::Boolean) }
attr_reader :incremental_authorization_supported
# The name of the card's issuing bank. (For internal use only and not typically available in standard API requests.)
sig { returns(T.nilable(String)) }
attr_reader :issuer
# The last four digits of the card.
sig { returns(T.nilable(String)) }
attr_reader :last4
# Identifies which network this charge was processed on. Can be `amex`, `cartes_bancaires`, `diners`, `discover`, `eftpos_au`, `interac`, `jcb`, `link`, `mastercard`, `unionpay`, `visa`, or `unknown`.
sig { returns(T.nilable(String)) }
attr_reader :network
# This is used by the financial networks to identify a transaction. Visa calls this the Transaction ID, Mastercard calls this the Trace ID, and American Express calls this the Acquirer Reference Data. This value will be present if it is returned by the financial network in the authorization response, and null otherwise.
sig { returns(T.nilable(String)) }
attr_reader :network_transaction_id
# Details about payments collected offline.
sig { returns(T.nilable(Offline)) }
attr_reader :offline
# Defines whether the authorized amount can be over-captured or not
sig { returns(T::Boolean) }
attr_reader :overcapture_supported
# EMV tag 5F2D. Preferred languages specified by the integrated circuit chip.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :preferred_locales
# How card details were read in this transaction.
sig { returns(T.nilable(String)) }
attr_reader :read_method
# A collection of fields required to be displayed on receipts. Only required for EMV transactions.
sig { returns(T.nilable(Receipt)) }
attr_reader :receipt
# Attribute for field wallet
sig { returns(Wallet) }
attr_reader :wallet
end
class Cashapp < Stripe::StripeObject
# A unique and immutable identifier assigned by Cash App to every buyer.
sig { returns(T.nilable(String)) }
attr_reader :buyer_id
# A public identifier for buyers using Cash App.
sig { returns(T.nilable(String)) }
attr_reader :cashtag
end
class Custom < Stripe::StripeObject
# Display name for the custom (user-defined) payment method type used to make this payment.
sig { returns(String) }
attr_reader :display_name
# The custom payment method type associated with this payment.
sig { returns(T.nilable(String)) }
attr_reader :type
end
class CustomerBalance < Stripe::StripeObject; end
class Eps < Stripe::StripeObject
# The customer's bank. Should be one of `arzte_und_apotheker_bank`, `austrian_anadi_bank_ag`, `bank_austria`, `bankhaus_carl_spangler`, `bankhaus_schelhammer_und_schattera_ag`, `bawag_psk_ag`, `bks_bank_ag`, `brull_kallmus_bank_ag`, `btv_vier_lander_bank`, `capital_bank_grawe_gruppe_ag`, `deutsche_bank_ag`, `dolomitenbank`, `easybank_ag`, `erste_bank_und_sparkassen`, `hypo_alpeadriabank_international_ag`, `hypo_noe_lb_fur_niederosterreich_u_wien`, `hypo_oberosterreich_salzburg_steiermark`, `hypo_tirol_bank_ag`, `hypo_vorarlberg_bank_ag`, `hypo_bank_burgenland_aktiengesellschaft`, `marchfelder_bank`, `oberbank_ag`, `raiffeisen_bankengruppe_osterreich`, `schoellerbank_ag`, `sparda_bank_wien`, `volksbank_gruppe`, `volkskreditbank_ag`, or `vr_bank_braunau`.
sig { returns(T.nilable(String)) }
attr_reader :bank
# Owner's verified full name. Values are verified or provided by EPS directly
# (if supported) at the time of authorization or settlement. They cannot be set or mutated.
# EPS rarely provides this information so the attribute is usually empty.
sig { returns(T.nilable(String)) }
attr_reader :verified_name
end
class Fpx < Stripe::StripeObject
# Account holder type, if provided. Can be one of `individual` or `company`.
sig { returns(T.nilable(String)) }
attr_reader :account_holder_type
# The customer's bank. Can be one of `affin_bank`, `agrobank`, `alliance_bank`, `ambank`, `bank_islam`, `bank_muamalat`, `bank_rakyat`, `bsn`, `cimb`, `hong_leong_bank`, `hsbc`, `kfh`, `maybank2u`, `ocbc`, `public_bank`, `rhb`, `standard_chartered`, `uob`, `deutsche_bank`, `maybank2e`, `pb_enterprise`, or `bank_of_china`.
sig { returns(String) }
attr_reader :bank
# Unique transaction id generated by FPX for every request from the merchant
sig { returns(T.nilable(String)) }
attr_reader :transaction_id
end
class Giropay < Stripe::StripeObject
# Bank code of bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_code
# Name of the bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# Bank Identifier Code of the bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bic
# Owner's verified full name. Values are verified or provided by Giropay directly
# (if supported) at the time of authorization or settlement. They cannot be set or mutated.
# Giropay rarely provides this information so the attribute is usually empty.
sig { returns(T.nilable(String)) }
attr_reader :verified_name
end
class Gopay < Stripe::StripeObject; end
class Grabpay < Stripe::StripeObject
# Unique transaction id generated by GrabPay
sig { returns(T.nilable(String)) }
attr_reader :transaction_id
end
class IdBankTransfer < Stripe::StripeObject
# Account number of the bank account to transfer funds to.
sig { returns(String) }
attr_reader :account_number
# Bank where the account is located.
sig { returns(String) }
attr_reader :bank
# Local bank code of the bank.
sig { returns(String) }
attr_reader :bank_code
# Name of the bank associated with the bank account.
sig { returns(String) }
attr_reader :bank_name
# Merchant name and billing details name, for the customer to check for the correct merchant when performing the bank transfer.
sig { returns(String) }
attr_reader :display_name
end
class Ideal < Stripe::StripeObject
# The customer's bank. Can be one of `abn_amro`, `asn_bank`, `bunq`, `handelsbanken`, `ing`, `knab`, `moneyou`, `n26`, `nn`, `rabobank`, `regiobank`, `revolut`, `sns_bank`, `triodos_bank`, `van_lanschot`, or `yoursafe`.
sig { returns(T.nilable(String)) }
attr_reader :bank
# The Bank Identifier Code of the customer's bank.
sig { returns(T.nilable(String)) }
attr_reader :bic
# The ID of the SEPA Direct Debit PaymentMethod which was generated by this Charge.
sig { returns(T.nilable(T.any(String, Stripe::PaymentMethod))) }
attr_reader :generated_sepa_debit
# The mandate for the SEPA Direct Debit PaymentMethod which was generated by this Charge.
sig { returns(T.nilable(T.any(String, Stripe::Mandate))) }
attr_reader :generated_sepa_debit_mandate
# Last four characters of the IBAN.
sig { returns(T.nilable(String)) }
attr_reader :iban_last4
# Owner's verified full name. Values are verified or provided by iDEAL directly
# (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(String)) }
attr_reader :verified_name
end
class InteracPresent < Stripe::StripeObject
class Receipt < Stripe::StripeObject
# The type of account being debited or credited
sig { returns(String) }
attr_reader :account_type
# EMV tag 9F26, cryptogram generated by the integrated circuit chip.
sig { returns(T.nilable(String)) }
attr_reader :application_cryptogram
# Mnenomic of the Application Identifier.
sig { returns(T.nilable(String)) }
attr_reader :application_preferred_name
# Identifier for this transaction.
sig { returns(T.nilable(String)) }
attr_reader :authorization_code
# EMV tag 8A. A code returned by the card issuer.
sig { returns(T.nilable(String)) }
attr_reader :authorization_response_code
# Describes the method used by the cardholder to verify ownership of the card. One of the following: `approval`, `failure`, `none`, `offline_pin`, `offline_pin_and_signature`, `online_pin`, or `signature`.
sig { returns(T.nilable(String)) }
attr_reader :cardholder_verification_method
# EMV tag 84. Similar to the application identifier stored on the integrated circuit chip.
sig { returns(T.nilable(String)) }
attr_reader :dedicated_file_name
# The outcome of a series of EMV functions performed by the card reader.
sig { returns(T.nilable(String)) }
attr_reader :terminal_verification_results
# An indication of various EMV functions performed during the transaction.
sig { returns(T.nilable(String)) }
attr_reader :transaction_status_information
end
# Card brand. Can be `interac`, `mastercard` or `visa`.
sig { returns(T.nilable(String)) }
attr_reader :brand
# The cardholder name as read from the card, in [ISO 7813](https://en.wikipedia.org/wiki/ISO/IEC_7813) format. May include alphanumeric characters, special characters and first/last name separator (`/`). In some cases, the cardholder name may not be available depending on how the issuer has configured the card. Cardholder name is typically not available on swipe or contactless payments, such as those made with Apple Pay and Google Pay.
sig { returns(T.nilable(String)) }
attr_reader :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.
sig { returns(T.nilable(String)) }
attr_reader :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.)
sig { returns(T.nilable(String)) }
attr_reader :description
# Authorization response cryptogram.
sig { returns(T.nilable(String)) }
attr_reader :emv_auth_data
# Two-digit number representing the card's expiration month.
sig { returns(Integer) }
attr_reader :exp_month
# Four-digit number representing the card's expiration year.
sig { returns(Integer) }
attr_reader :exp_year
# Uniquely identifies this particular card number. You can use this attribute to check whether two customers who’ve signed up with you are using the same card number, for example. For payment methods that tokenize card information (Apple Pay, Google Pay), the tokenized number might be provided instead of the underlying card number.
#
# *As of May 1, 2021, card fingerprint in India for Connect changed to allow two fingerprints for the same card---one for India and one for the rest of the world.*
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Card funding type. Can be `credit`, `debit`, `prepaid`, or `unknown`.
sig { returns(T.nilable(String)) }
attr_reader :funding
# ID of a card PaymentMethod generated from the card_present PaymentMethod that may be attached to a Customer for future transactions. Only present if it was possible to generate a card PaymentMethod.
sig { returns(T.nilable(String)) }
attr_reader :generated_card
# Issuer identification number of the card. (For internal use only and not typically available in standard API requests.)
sig { returns(T.nilable(String)) }
attr_reader :iin
# The name of the card's issuing bank. (For internal use only and not typically available in standard API requests.)
sig { returns(T.nilable(String)) }
attr_reader :issuer
# The last four digits of the card.
sig { returns(T.nilable(String)) }
attr_reader :last4
# Identifies which network this charge was processed on. Can be `amex`, `cartes_bancaires`, `diners`, `discover`, `eftpos_au`, `interac`, `jcb`, `link`, `mastercard`, `unionpay`, `visa`, or `unknown`.
sig { returns(T.nilable(String)) }
attr_reader :network
# This is used by the financial networks to identify a transaction. Visa calls this the Transaction ID, Mastercard calls this the Trace ID, and American Express calls this the Acquirer Reference Data. This value will be present if it is returned by the financial network in the authorization response, and null otherwise.
sig { returns(T.nilable(String)) }
attr_reader :network_transaction_id
# EMV tag 5F2D. Preferred languages specified by the integrated circuit chip.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :preferred_locales
# How card details were read in this transaction.
sig { returns(T.nilable(String)) }
attr_reader :read_method
# A collection of fields required to be displayed on receipts. Only required for EMV transactions.
sig { returns(T.nilable(Receipt)) }
attr_reader :receipt
end
class KakaoPay < Stripe::StripeObject
# A unique identifier for the buyer as determined by the local payment processor.
sig { returns(T.nilable(String)) }
attr_reader :buyer_id
end
class Klarna < Stripe::StripeObject
class PayerDetails < Stripe::StripeObject
class Address < Stripe::StripeObject
# The payer address country
sig { returns(T.nilable(String)) }
attr_reader :country
end
# The payer's address
sig { returns(T.nilable(Address)) }
attr_reader :address
end
# The payer details for this transaction.
sig { returns(T.nilable(PayerDetails)) }
attr_reader :payer_details
# The Klarna payment method used for this transaction.
# Can be one of `pay_later`, `pay_now`, `pay_with_financing`, or `pay_in_installments`
sig { returns(T.nilable(String)) }
attr_reader :payment_method_category
# Preferred language of the Klarna authorization page that the customer is redirected to.
# Can be one of `de-AT`, `en-AT`, `nl-BE`, `fr-BE`, `en-BE`, `de-DE`, `en-DE`, `da-DK`, `en-DK`, `es-ES`, `en-ES`, `fi-FI`, `sv-FI`, `en-FI`, `en-GB`, `en-IE`, `it-IT`, `en-IT`, `nl-NL`, `en-NL`, `nb-NO`, `en-NO`, `sv-SE`, `en-SE`, `en-US`, `es-US`, `fr-FR`, `en-FR`, `cs-CZ`, `en-CZ`, `ro-RO`, `en-RO`, `el-GR`, `en-GR`, `en-AU`, `en-NZ`, `en-CA`, `fr-CA`, `pl-PL`, `en-PL`, `pt-PT`, `en-PT`, `de-CH`, `fr-CH`, `it-CH`, or `en-CH`
sig { returns(T.nilable(String)) }
attr_reader :preferred_locale
end
class Konbini < Stripe::StripeObject
class Store < Stripe::StripeObject
# The name of the convenience store chain where the payment was completed.
sig { returns(T.nilable(String)) }
attr_reader :chain
end
# If the payment succeeded, this contains the details of the convenience store where the payment was completed.
sig { returns(T.nilable(Store)) }
attr_reader :store
end
class KrCard < Stripe::StripeObject
# The local credit or debit card brand.
sig { returns(T.nilable(String)) }
attr_reader :brand
# A unique identifier for the buyer as determined by the local payment processor.
sig { returns(T.nilable(String)) }
attr_reader :buyer_id
# The last four digits of the card. This may not be present for American Express cards.
sig { returns(T.nilable(String)) }
attr_reader :last4
end
class Link < Stripe::StripeObject
# Two-letter ISO code representing the funding source country beneath the Link payment.
# You could use this attribute to get a sense of international fees.
sig { returns(T.nilable(String)) }
attr_reader :country
end
class MbWay < Stripe::StripeObject; end
class Mobilepay < Stripe::StripeObject
class Card < Stripe::StripeObject
# Brand of the card used in the transaction
sig { returns(T.nilable(String)) }
attr_reader :brand
# Two-letter ISO code representing the country of the card
sig { returns(T.nilable(String)) }
attr_reader :country
# Two digit number representing the card's expiration month
sig { returns(T.nilable(Integer)) }
attr_reader :exp_month
# Two digit number representing the card's expiration year
sig { returns(T.nilable(Integer)) }
attr_reader :exp_year
# The last 4 digits of the card
sig { returns(T.nilable(String)) }
attr_reader :last4
end
# Internal card details
sig { returns(T.nilable(Card)) }
attr_reader :card
end
class Multibanco < Stripe::StripeObject
# Entity number associated with this Multibanco payment.
sig { returns(T.nilable(String)) }
attr_reader :entity
# Reference number associated with this Multibanco payment.
sig { returns(T.nilable(String)) }
attr_reader :reference
end
class NaverPay < Stripe::StripeObject
# A unique identifier for the buyer as determined by the local payment processor.
sig { returns(T.nilable(String)) }
attr_reader :buyer_id
end
class NzBankAccount < Stripe::StripeObject
# The name on the bank account. Only present if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod’s billing details.
sig { returns(T.nilable(String)) }
attr_reader :account_holder_name
# The numeric code for the bank account's bank.
sig { returns(String) }
attr_reader :bank_code
# The name of the bank.
sig { returns(String) }
attr_reader :bank_name
# The numeric code for the bank account's bank branch.
sig { returns(String) }
attr_reader :branch_code
# Last four digits of the bank account number.
sig { returns(String) }
attr_reader :last4
# The suffix of the bank account number.
sig { returns(T.nilable(String)) }
attr_reader :suffix
end
class Oxxo < Stripe::StripeObject
# OXXO reference number
sig { returns(T.nilable(String)) }
attr_reader :number
end
class P24 < Stripe::StripeObject
# The customer's bank. Can be one of `ing`, `citi_handlowy`, `tmobile_usbugi_bankowe`, `plus_bank`, `etransfer_pocztowy24`, `banki_spbdzielcze`, `bank_nowy_bfg_sa`, `getin_bank`, `velobank`, `blik`, `noble_pay`, `ideabank`, `envelobank`, `santander_przelew24`, `nest_przelew`, `mbank_mtransfer`, `inteligo`, `pbac_z_ipko`, `bnp_paribas`, `credit_agricole`, `toyota_bank`, `bank_pekao_sa`, `volkswagen_bank`, `bank_millennium`, `alior_bank`, or `boz`.
sig { returns(T.nilable(String)) }
attr_reader :bank
# Unique reference for this Przelewy24 payment.
sig { returns(T.nilable(String)) }
attr_reader :reference
# Owner's verified full name. Values are verified or provided by Przelewy24 directly
# (if supported) at the time of authorization or settlement. They cannot be set or mutated.
# Przelewy24 rarely provides this information so the attribute is usually empty.
sig { returns(T.nilable(String)) }
attr_reader :verified_name
end
class PayByBank < Stripe::StripeObject; end
class Payco < Stripe::StripeObject
# A unique identifier for the buyer as determined by the local payment processor.
sig { returns(T.nilable(String)) }
attr_reader :buyer_id
end
class Paynow < Stripe::StripeObject
# Reference number associated with this PayNow payment
sig { returns(T.nilable(String)) }
attr_reader :reference
end
class Paypal < Stripe::StripeObject
class SellerProtection < Stripe::StripeObject
# An array of conditions that are covered for the transaction, if applicable.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :dispute_categories
# Indicates whether the transaction is eligible for PayPal's seller protection.
sig { returns(String) }
attr_reader :status
end
class Shipping < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
class VerifiedAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Two-letter ISO code representing the buyer's country. Values are provided by PayPal directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(String)) }
attr_reader :country
# Owner's email. Values are provided by PayPal directly
# (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(String)) }
attr_reader :payer_email
# PayPal account PayerID. This identifier uniquely identifies the PayPal customer.
sig { returns(T.nilable(String)) }
attr_reader :payer_id
# Owner's full name. Values provided by PayPal directly
# (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(String)) }
attr_reader :payer_name
# The level of protection offered as defined by PayPal Seller Protection for Merchants, for this transaction.
sig { returns(T.nilable(SellerProtection)) }
attr_reader :seller_protection
# The shipping address for the customer, as supplied by the merchant at the point of payment
# execution. This shipping address will not be updated if the merchant updates the shipping
# address on the PaymentIntent after the PaymentIntent was successfully confirmed.
sig { returns(T.nilable(Shipping)) }
attr_reader :shipping
# A unique ID generated by PayPal for this transaction.
sig { returns(T.nilable(String)) }
attr_reader :transaction_id
# The shipping address for the customer, as supplied by the merchant at the point of payment
# execution. This shipping address will not be updated if the merchant updates the shipping
# address on the PaymentIntent after the PaymentIntent was successfully confirmed.
sig { returns(T.nilable(VerifiedAddress)) }
attr_reader :verified_address
# Owner's verified email. Values are verified or provided by PayPal directly
# (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(String)) }
attr_reader :verified_email
# Owner's verified full name. Values are verified or provided by PayPal directly
# (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(String)) }
attr_reader :verified_name
end
class Payto < Stripe::StripeObject
# Bank-State-Branch number of the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bsb_number
# Last four digits of the bank account number.
sig { returns(T.nilable(String)) }
attr_reader :last4
# ID of the mandate used to make this payment.
sig { returns(String) }
attr_reader :mandate
# The PayID alias for the bank account.
sig { returns(T.nilable(String)) }
attr_reader :pay_id
end
class Pix < Stripe::StripeObject
# Unique transaction id generated by BCB
sig { returns(T.nilable(String)) }
attr_reader :bank_transaction_id
end
class Promptpay < Stripe::StripeObject
# Bill reference generated by PromptPay
sig { returns(T.nilable(String)) }
attr_reader :reference
end
class Qris < Stripe::StripeObject; end
class Rechnung < Stripe::StripeObject; end
class RevolutPay < Stripe::StripeObject
class Funding < Stripe::StripeObject
class Card < Stripe::StripeObject
# Card brand. Can be `amex`, `diners`, `discover`, `eftpos_au`, `jcb`, `link`, `mastercard`, `unionpay`, `visa`, or `unknown`.
sig { returns(T.nilable(String)) }
attr_reader :brand
# The [product code](https://stripe.com/docs/card-product-codes) that identifies the specific program or product associated with a card. (For internal use only and not typically available in standard API requests.)
sig { returns(T.nilable(String)) }
attr_reader :brand_product
# 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.
sig { returns(T.nilable(String)) }
attr_reader :country
# Two-digit number representing the card's expiration month.
sig { returns(T.nilable(Integer)) }
attr_reader :exp_month
# Four-digit number representing the card's expiration year.
sig { returns(T.nilable(Integer)) }
attr_reader :exp_year
# Card funding type. Can be `credit`, `debit`, `prepaid`, or `unknown`.
sig { returns(T.nilable(String)) }
attr_reader :funding
# The last four digits of the card.
sig { returns(T.nilable(String)) }
attr_reader :last4
end
# Attribute for field card
sig { returns(Card) }
attr_reader :card
# funding type of the underlying payment method.
sig { returns(T.nilable(String)) }
attr_reader :type
end
# Attribute for field funding
sig { returns(Funding) }
attr_reader :funding
end
class SamsungPay < Stripe::StripeObject
# A unique identifier for the buyer as determined by the local payment processor.
sig { returns(T.nilable(String)) }
attr_reader :buyer_id
end
class Satispay < Stripe::StripeObject; end
class SepaCreditTransfer < Stripe::StripeObject
# Name of the bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# Bank Identifier Code of the bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bic
# IBAN of the bank account to transfer funds to.
sig { returns(T.nilable(String)) }
attr_reader :iban
end
class SepaDebit < Stripe::StripeObject
# Bank code of bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_code
# Branch code of bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :branch_code
# Two-letter ISO code representing the country the bank account is located in.
sig { returns(T.nilable(String)) }
attr_reader :country
# Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Last four characters of the IBAN.
sig { returns(T.nilable(String)) }
attr_reader :last4
# Find the ID of the mandate used for this payment under the [payment_method_details.sepa_debit.mandate](https://stripe.com/docs/api/charges/object#charge_object-payment_method_details-sepa_debit-mandate) property on the Charge. Use this mandate ID to [retrieve the Mandate](https://stripe.com/docs/api/mandates/retrieve).
sig { returns(T.nilable(String)) }
attr_reader :mandate
end
class Shopeepay < Stripe::StripeObject; end
class Sofort < Stripe::StripeObject
# Bank code of bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_code
# Name of the bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# Bank Identifier Code of the bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bic
# Two-letter ISO code representing the country the bank account is located in.
sig { returns(T.nilable(String)) }
attr_reader :country
# The ID of the SEPA Direct Debit PaymentMethod which was generated by this Charge.
sig { returns(T.nilable(T.any(String, Stripe::PaymentMethod))) }
attr_reader :generated_sepa_debit
# The mandate for the SEPA Direct Debit PaymentMethod which was generated by this Charge.
sig { returns(T.nilable(T.any(String, Stripe::Mandate))) }
attr_reader :generated_sepa_debit_mandate
# Last four characters of the IBAN.
sig { returns(T.nilable(String)) }
attr_reader :iban_last4
# Preferred language of the SOFORT authorization page that the customer is redirected to.
# Can be one of `de`, `en`, `es`, `fr`, `it`, `nl`, or `pl`
sig { returns(T.nilable(String)) }
attr_reader :preferred_language
# Owner's verified full name. Values are verified or provided by SOFORT directly
# (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(String)) }
attr_reader :verified_name
end
class StripeAccount < Stripe::StripeObject; end
class StripeBalance < Stripe::StripeObject
# The connected account ID whose Stripe balance to use as the source of payment
sig { returns(T.nilable(String)) }
attr_reader :account
# The [source_type](https://docs.stripe.com/api/balance/balance_object#balance_object-available-source_types) of the balance
sig { returns(String) }
attr_reader :source_type
end
class Swish < Stripe::StripeObject
# Uniquely identifies the payer's Swish account. You can use this attribute to check whether two Swish transactions were paid for by the same payer
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Payer bank reference number for the payment
sig { returns(T.nilable(String)) }
attr_reader :payment_reference
# The last four digits of the Swish account phone number
sig { returns(T.nilable(String)) }
attr_reader :verified_phone_last4
end
class Twint < Stripe::StripeObject; end
class UsBankAccount < Stripe::StripeObject
# Account holder type: individual or company.
sig { returns(T.nilable(String)) }
attr_reader :account_holder_type
# Account type: checkings or savings. Defaults to checking if omitted.
sig { returns(T.nilable(String)) }
attr_reader :account_type
# Name of the bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Last four digits of the bank account number.
sig { returns(T.nilable(String)) }
attr_reader :last4
# ID of the mandate used to make this payment.
sig { returns(T.any(String, Stripe::Mandate)) }
attr_reader :mandate
# Reference number to locate ACH payments with customer's bank.
sig { returns(T.nilable(String)) }
attr_reader :payment_reference
# Routing number of the bank account.
sig { returns(T.nilable(String)) }
attr_reader :routing_number
end
class Wechat < Stripe::StripeObject; end
class WechatPay < Stripe::StripeObject
# Uniquely identifies this particular WeChat Pay account. You can use this attribute to check whether two WeChat accounts are the same.
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# ID of the [location](https://stripe.com/docs/api/terminal/locations) that this transaction's reader is assigned to.
sig { returns(String) }
attr_reader :location
# ID of the [reader](https://stripe.com/docs/api/terminal/readers) this transaction was made on.
sig { returns(String) }
attr_reader :reader
# Transaction ID of this particular WeChat Pay transaction.
sig { returns(T.nilable(String)) }
attr_reader :transaction_id
end
class Zip < Stripe::StripeObject; end
# Attribute for field ach_credit_transfer
sig { returns(AchCreditTransfer) }
attr_reader :ach_credit_transfer
# Attribute for field ach_debit
sig { returns(AchDebit) }
attr_reader :ach_debit
# Attribute for field acss_debit
sig { returns(AcssDebit) }
attr_reader :acss_debit
# Attribute for field affirm
sig { returns(Affirm) }
attr_reader :affirm
# Attribute for field afterpay_clearpay
sig { returns(AfterpayClearpay) }
attr_reader :afterpay_clearpay
# Attribute for field alipay
sig { returns(Alipay) }
attr_reader :alipay
# Attribute for field alma
sig { returns(Alma) }
attr_reader :alma
# Attribute for field amazon_pay
sig { returns(AmazonPay) }
attr_reader :amazon_pay
# Attribute for field au_becs_debit
sig { returns(AuBecsDebit) }
attr_reader :au_becs_debit
# Attribute for field bacs_debit
sig { returns(BacsDebit) }
attr_reader :bacs_debit
# Attribute for field bancontact
sig { returns(Bancontact) }
attr_reader :bancontact
# Attribute for field billie
sig { returns(Billie) }
attr_reader :billie
# The billing details associated with the method of payment.
sig { returns(T.nilable(BillingDetails)) }
attr_reader :billing_details
# Attribute for field blik
sig { returns(Blik) }
attr_reader :blik
# Attribute for field boleto
sig { returns(Boleto) }
attr_reader :boleto
# Details of the card used for this payment attempt.
sig { returns(Card) }
attr_reader :card
# Attribute for field card_present
sig { returns(CardPresent) }
attr_reader :card_present
# Attribute for field cashapp
sig { returns(Cashapp) }
attr_reader :cashapp
# Custom Payment Methods represent Payment Method types not modeled directly in
# the Stripe API. This resource consists of details about the custom payment method
# used for this payment attempt.
sig { returns(Custom) }
attr_reader :custom
# Attribute for field customer_balance
sig { returns(CustomerBalance) }
attr_reader :customer_balance
# Attribute for field eps
sig { returns(Eps) }
attr_reader :eps
# Attribute for field fpx
sig { returns(Fpx) }
attr_reader :fpx
# Attribute for field giropay
sig { returns(Giropay) }
attr_reader :giropay
# Attribute for field gopay
sig { returns(Gopay) }
attr_reader :gopay
# Attribute for field grabpay
sig { returns(Grabpay) }
attr_reader :grabpay
# Attribute for field id_bank_transfer
sig { returns(IdBankTransfer) }
attr_reader :id_bank_transfer
# Attribute for field ideal
sig { returns(Ideal) }
attr_reader :ideal
# Attribute for field interac_present
sig { returns(InteracPresent) }
attr_reader :interac_present
# Attribute for field kakao_pay
sig { returns(KakaoPay) }
attr_reader :kakao_pay
# Attribute for field klarna
sig { returns(Klarna) }
attr_reader :klarna
# Attribute for field konbini
sig { returns(Konbini) }
attr_reader :konbini
# Attribute for field kr_card
sig { returns(KrCard) }
attr_reader :kr_card
# Attribute for field link
sig { returns(Link) }
attr_reader :link
# Attribute for field mb_way
sig { returns(MbWay) }
attr_reader :mb_way
# Attribute for field mobilepay
sig { returns(Mobilepay) }
attr_reader :mobilepay
# Attribute for field multibanco
sig { returns(Multibanco) }
attr_reader :multibanco
# Attribute for field naver_pay
sig { returns(NaverPay) }
attr_reader :naver_pay
# Attribute for field nz_bank_account
sig { returns(NzBankAccount) }
attr_reader :nz_bank_account
# Attribute for field oxxo
sig { returns(Oxxo) }
attr_reader :oxxo
# Attribute for field p24
sig { returns(P24) }
attr_reader :p24
# Attribute for field pay_by_bank
sig { returns(PayByBank) }
attr_reader :pay_by_bank
# Attribute for field payco
sig { returns(Payco) }
attr_reader :payco
# ID of the Stripe PaymentMethod used to make this payment.
sig { returns(T.nilable(String)) }
attr_reader :payment_method
# Attribute for field paynow
sig { returns(Paynow) }
attr_reader :paynow
# Attribute for field paypal
sig { returns(Paypal) }
attr_reader :paypal
# Attribute for field payto
sig { returns(Payto) }
attr_reader :payto
# Attribute for field pix
sig { returns(Pix) }
attr_reader :pix
# Attribute for field promptpay
sig { returns(Promptpay) }
attr_reader :promptpay
# Attribute for field qris
sig { returns(Qris) }
attr_reader :qris
# Attribute for field rechnung
sig { returns(Rechnung) }
attr_reader :rechnung
# Attribute for field revolut_pay
sig { returns(RevolutPay) }
attr_reader :revolut_pay
# Attribute for field samsung_pay
sig { returns(SamsungPay) }
attr_reader :samsung_pay
# Attribute for field satispay
sig { returns(Satispay) }
attr_reader :satispay
# Attribute for field sepa_credit_transfer
sig { returns(SepaCreditTransfer) }
attr_reader :sepa_credit_transfer
# Attribute for field sepa_debit
sig { returns(SepaDebit) }
attr_reader :sepa_debit
# Attribute for field shopeepay
sig { returns(Shopeepay) }
attr_reader :shopeepay
# Attribute for field sofort
sig { returns(Sofort) }
attr_reader :sofort
# Attribute for field stripe_account
sig { returns(StripeAccount) }
attr_reader :stripe_account
# Attribute for field stripe_balance
sig { returns(StripeBalance) }
attr_reader :stripe_balance
# Attribute for field swish
sig { returns(Swish) }
attr_reader :swish
# Attribute for field twint
sig { returns(Twint) }
attr_reader :twint
# The type of transaction-specific details of the payment method used in the payment. See [PaymentMethod.type](https://stripe.com/docs/api/payment_methods/object#payment_method_object-type) for the full list of possible types.
# An additional hash is included on `payment_method_details` with a name matching this value.
# It contains information specific to the payment method.
sig { returns(String) }
attr_reader :type
# Attribute for field us_bank_account
sig { returns(UsBankAccount) }
attr_reader :us_bank_account
# Attribute for field wechat
sig { returns(Wechat) }
attr_reader :wechat
# Attribute for field wechat_pay
sig { returns(WechatPay) }
attr_reader :wechat_pay
# Attribute for field zip
sig { returns(Zip) }
attr_reader :zip
end
class ShippingDetails < Stripe::StripeObject
class Address < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# A representation of a physical address.
sig { returns(Address) }
attr_reader :address
# The shipping recipient's name.
sig { returns(T.nilable(String)) }
attr_reader :name
# The shipping recipient's phone number.
sig { returns(T.nilable(String)) }
attr_reader :phone
end
# A representation of an amount of money, consisting of an amount and a currency.
sig { returns(AmountCanceled) }
attr_reader :amount_canceled
# A representation of an amount of money, consisting of an amount and a currency.
sig { returns(AmountFailed) }
attr_reader :amount_failed
# A representation of an amount of money, consisting of an amount and a currency.
sig { returns(AmountGuaranteed) }
attr_reader :amount_guaranteed
# A representation of an amount of money, consisting of an amount and a currency.
sig { returns(AmountRequested) }
attr_reader :amount_requested
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# Customer information for this payment.
sig { returns(T.nilable(CustomerDetails)) }
attr_reader :customer_details
# Indicates whether the customer was present in your checkout flow during this payment.
sig { returns(T.nilable(String)) }
attr_reader :customer_presence
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_reader :description
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# 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.
sig { returns(T::Hash[String, String]) }
attr_reader :metadata
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Information about the Payment Method debited for this payment.
sig { returns(T.nilable(PaymentMethodDetails)) }
attr_reader :payment_method_details
# ID of the Payment Record this Payment Attempt Record belongs to.
sig { returns(T.nilable(String)) }
attr_reader :payment_record
# An opaque string for manual reconciliation of this payment, for example a check number or a payment processor ID.
sig { returns(T.nilable(String)) }
attr_reader :payment_reference
# Indicates who reported the payment.
sig { returns(String) }
attr_reader :reported_by
# Shipping information for this payment.
sig { returns(T.nilable(ShippingDetails)) }
attr_reader :shipping_details
class ListParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The ID of the Payment Record.
sig { returns(String) }
attr_accessor :payment_record
sig { params(expand: T.nilable(T::Array[String]), payment_record: String).void }
def initialize(expand: nil, payment_record: nil); end
end
# List all the Payment Attempt Records attached to the specified Payment Record.
sig {
params(params: T.any(::Stripe::PaymentAttemptRecord::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
end
end
# typed: true
module Stripe
# A PaymentIntent guides you through the process of collecting a payment from your customer.
# We recommend that you create exactly one PaymentIntent for each order or
# customer session in your system. You can reference the PaymentIntent later to
# see the history of payment attempts for a particular session.
#
# A PaymentIntent transitions through
# [multiple statuses](https://stripe.com/docs/payments/intents#intent-statuses)
# throughout its lifetime as it interfaces with Stripe.js to perform
# authentication flows and ultimately creates at most one successful charge.
#
# Related guide: [Payment Intents API](https://stripe.com/docs/payments/payment-intents)
class PaymentIntent < APIResource
class AmountDetails < Stripe::StripeObject
class Shipping < Stripe::StripeObject
# Portion of the amount that is for shipping.
sig { returns(T.nilable(Integer)) }
attr_reader :amount
# The postal code that represents the shipping source.
sig { returns(T.nilable(String)) }
attr_reader :from_postal_code
# The postal code that represents the shipping destination.
sig { returns(T.nilable(String)) }
attr_reader :to_postal_code
end
class Tax < Stripe::StripeObject
# Total portion of the amount that is for tax.
sig { returns(T.nilable(Integer)) }
attr_reader :total_tax_amount
end
class Tip < Stripe::StripeObject
# Portion of the amount that corresponds to a tip.
sig { returns(Integer) }
attr_reader :amount
end
# The amount an item was discounted for.
sig { returns(Integer) }
attr_reader :discount_amount
# A list of line items, each containing information about a product in the PaymentIntent. There is a maximum of 100 line items.
sig { returns(Stripe::ListObject) }
attr_reader :line_items
# Attribute for field shipping
sig { returns(Shipping) }
attr_reader :shipping
# Attribute for field tax
sig { returns(Tax) }
attr_reader :tax
# Attribute for field tip
sig { returns(Tip) }
attr_reader :tip
end
class AutomaticPaymentMethods < Stripe::StripeObject
# Controls whether this PaymentIntent will accept redirect-based payment methods.
#
# Redirect-based payment methods may require your customer to be redirected to a payment method's app or site for authentication or additional steps. To [confirm](https://stripe.com/docs/api/payment_intents/confirm) this PaymentIntent, you may be required to provide a `return_url` to redirect customers back to your site after they authenticate or complete the payment.
sig { returns(String) }
attr_reader :allow_redirects
# Automatically calculates compatible payment methods
sig { returns(T::Boolean) }
attr_reader :enabled
end
class Hooks < Stripe::StripeObject
class Inputs < Stripe::StripeObject
class Tax < Stripe::StripeObject
# The [TaxCalculation](https://stripe.com/docs/api/tax/calculations) id
sig { returns(String) }
attr_reader :calculation
end
# Attribute for field tax
sig { returns(Tax) }
attr_reader :tax
end
# Attribute for field inputs
sig { returns(Inputs) }
attr_reader :inputs
end
class LastPaymentError < Stripe::StripeObject
# For card errors resulting from a card issuer decline, a short string indicating [how to proceed with an error](https://stripe.com/docs/declines#retrying-issuer-declines) if they provide one.
sig { returns(String) }
attr_reader :advice_code
# For card errors, the ID of the failed charge.
sig { returns(String) }
attr_reader :charge
# For some errors that could be handled programmatically, a short string indicating the [error code](https://stripe.com/docs/error-codes) reported.
sig { returns(String) }
attr_reader :code
# For card errors resulting from a card issuer decline, a short string indicating the [card issuer's reason for the decline](https://stripe.com/docs/declines#issuer-declines) if they provide one.
sig { returns(String) }
attr_reader :decline_code
# A URL to more information about the [error code](https://stripe.com/docs/error-codes) reported.
sig { returns(String) }
attr_reader :doc_url
# A human-readable message providing more details about the error. For card errors, these messages can be shown to your users.
sig { returns(String) }
attr_reader :message
# For card errors resulting from a card issuer decline, a 2 digit code which indicates the advice given to merchant by the card network on how to proceed with an error.
sig { returns(String) }
attr_reader :network_advice_code
# For card errors resulting from a card issuer decline, a brand specific 2, 3, or 4 digit code which indicates the reason the authorization failed.
sig { returns(String) }
attr_reader :network_decline_code
# If the error is parameter-specific, the parameter related to the error. For example, you can use this to display a message near the correct form field.
sig { returns(String) }
attr_reader :param
# A PaymentIntent guides you through the process of collecting a payment from your customer.
# We recommend that you create exactly one PaymentIntent for each order or
# customer session in your system. You can reference the PaymentIntent later to
# see the history of payment attempts for a particular session.
#
# A PaymentIntent transitions through
# [multiple statuses](https://stripe.com/docs/payments/intents#intent-statuses)
# throughout its lifetime as it interfaces with Stripe.js to perform
# authentication flows and ultimately creates at most one successful charge.
#
# Related guide: [Payment Intents API](https://stripe.com/docs/payments/payment-intents)
sig { returns(Stripe::PaymentIntent) }
attr_reader :payment_intent
# PaymentMethod objects represent your customer's payment instruments.
# You can use them with [PaymentIntents](https://stripe.com/docs/payments/payment-intents) to collect payments or save them to
# Customer objects to store instrument details for future payments.
#
# Related guides: [Payment Methods](https://stripe.com/docs/payments/payment-methods) and [More Payment Scenarios](https://stripe.com/docs/payments/more-payment-scenarios).
sig { returns(Stripe::PaymentMethod) }
attr_reader :payment_method
# If the error is specific to the type of payment method, the payment method type that had a problem. This field is only populated for invoice-related errors.
sig { returns(String) }
attr_reader :payment_method_type
# A URL to the request log entry in your dashboard.
sig { returns(String) }
attr_reader :request_log_url
# A SetupIntent guides you through the process of setting up and saving a customer's payment credentials for future payments.
# For example, you can use a SetupIntent to set up and save your customer's card without immediately collecting a payment.
# Later, you can use [PaymentIntents](https://stripe.com/docs/api#payment_intents) to drive the payment flow.
#
# Create a SetupIntent when you're ready to collect your customer's payment credentials.
# Don't maintain long-lived, unconfirmed SetupIntents because they might not be valid.
# The SetupIntent transitions through multiple [statuses](https://docs.stripe.com/payments/intents#intent-statuses) as it guides
# you through the setup process.
#
# Successful SetupIntents result in payment credentials that are optimized for future payments.
# For example, cardholders in [certain regions](https://stripe.com/guides/strong-customer-authentication) might need to be run through
# [Strong Customer Authentication](https://docs.stripe.com/strong-customer-authentication) during payment method collection
# to streamline later [off-session payments](https://docs.stripe.com/payments/setup-intents).
# If you use the SetupIntent with a [Customer](https://stripe.com/docs/api#setup_intent_object-customer),
# it automatically attaches the resulting payment method to that Customer after successful setup.
# We recommend using SetupIntents or [setup_future_usage](https://stripe.com/docs/api#payment_intent_object-setup_future_usage) on
# PaymentIntents to save payment methods to prevent saving invalid or unoptimized payment methods.
#
# By using SetupIntents, you can reduce friction for your customers, even as regulations change over time.
#
# Related guide: [Setup Intents API](https://docs.stripe.com/payments/setup-intents)
sig { returns(Stripe::SetupIntent) }
attr_reader :setup_intent
# Attribute for field source
sig { returns(T.any(Stripe::Account, Stripe::BankAccount, Stripe::Card, Stripe::Source)) }
attr_reader :source
# The type of error returned. One of `api_error`, `card_error`, `idempotency_error`, or `invalid_request_error`
sig { returns(String) }
attr_reader :type
end
class NextAction < Stripe::StripeObject
class AlipayHandleRedirect < Stripe::StripeObject
# The native data to be used with Alipay SDK you must redirect your customer to in order to authenticate the payment in an Android App.
sig { returns(T.nilable(String)) }
attr_reader :native_data
# The native URL you must redirect your customer to in order to authenticate the payment in an iOS App.
sig { returns(T.nilable(String)) }
attr_reader :native_url
# If the customer does not exit their browser while authenticating, they will be redirected to this specified URL after completion.
sig { returns(T.nilable(String)) }
attr_reader :return_url
# The URL you must redirect your customer to in order to authenticate the payment.
sig { returns(T.nilable(String)) }
attr_reader :url
end
class BoletoDisplayDetails < Stripe::StripeObject
# The timestamp after which the boleto expires.
sig { returns(T.nilable(Integer)) }
attr_reader :expires_at
# The URL to the hosted boleto voucher page, which allows customers to view the boleto voucher.
sig { returns(T.nilable(String)) }
attr_reader :hosted_voucher_url
# The boleto number.
sig { returns(T.nilable(String)) }
attr_reader :number
# The URL to the downloadable boleto voucher PDF.
sig { returns(T.nilable(String)) }
attr_reader :pdf
end
class CardAwaitNotification < Stripe::StripeObject
# The time that payment will be attempted. If customer approval is required, they need to provide approval before this time.
sig { returns(T.nilable(Integer)) }
attr_reader :charge_attempt_at
# For payments greater than INR 15000, the customer must provide explicit approval of the payment with their bank. For payments of lower amount, no customer action is required.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :customer_approval_required
end
class CashappHandleRedirectOrDisplayQrCode < Stripe::StripeObject
class QrCode < Stripe::StripeObject
# The date (unix timestamp) when the QR code expires.
sig { returns(Integer) }
attr_reader :expires_at
# The image_url_png string used to render QR code
sig { returns(String) }
attr_reader :image_url_png
# The image_url_svg string used to render QR code
sig { returns(String) }
attr_reader :image_url_svg
end
# The URL to the hosted Cash App Pay instructions page, which allows customers to view the QR code, and supports QR code refreshing on expiration.
sig { returns(String) }
attr_reader :hosted_instructions_url
# The url for mobile redirect based auth
sig { returns(String) }
attr_reader :mobile_auth_url
# Attribute for field qr_code
sig { returns(QrCode) }
attr_reader :qr_code
end
class DisplayBankTransferInstructions < Stripe::StripeObject
class FinancialAddress < Stripe::StripeObject
class Aba < Stripe::StripeObject
class AccountHolderAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
class BankAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Attribute for field account_holder_address
sig { returns(AccountHolderAddress) }
attr_reader :account_holder_address
# The account holder name
sig { returns(String) }
attr_reader :account_holder_name
# The ABA account number
sig { returns(String) }
attr_reader :account_number
# The account type
sig { returns(String) }
attr_reader :account_type
# Attribute for field bank_address
sig { returns(BankAddress) }
attr_reader :bank_address
# The bank name
sig { returns(String) }
attr_reader :bank_name
# The ABA routing number
sig { returns(String) }
attr_reader :routing_number
end
class Iban < Stripe::StripeObject
class AccountHolderAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
class BankAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Attribute for field account_holder_address
sig { returns(AccountHolderAddress) }
attr_reader :account_holder_address
# The name of the person or business that owns the bank account
sig { returns(String) }
attr_reader :account_holder_name
# Attribute for field bank_address
sig { returns(BankAddress) }
attr_reader :bank_address
# The BIC/SWIFT code of the account.
sig { returns(String) }
attr_reader :bic
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(String) }
attr_reader :country
# The IBAN of the account.
sig { returns(String) }
attr_reader :iban
end
class SortCode < Stripe::StripeObject
class AccountHolderAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
class BankAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Attribute for field account_holder_address
sig { returns(AccountHolderAddress) }
attr_reader :account_holder_address
# The name of the person or business that owns the bank account
sig { returns(String) }
attr_reader :account_holder_name
# The account number
sig { returns(String) }
attr_reader :account_number
# Attribute for field bank_address
sig { returns(BankAddress) }
attr_reader :bank_address
# The six-digit sort code
sig { returns(String) }
attr_reader :sort_code
end
class Spei < Stripe::StripeObject
class AccountHolderAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
class BankAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Attribute for field account_holder_address
sig { returns(AccountHolderAddress) }
attr_reader :account_holder_address
# The account holder name
sig { returns(String) }
attr_reader :account_holder_name
# Attribute for field bank_address
sig { returns(BankAddress) }
attr_reader :bank_address
# The three-digit bank code
sig { returns(String) }
attr_reader :bank_code
# The short banking institution name
sig { returns(String) }
attr_reader :bank_name
# The CLABE number
sig { returns(String) }
attr_reader :clabe
end
class Swift < Stripe::StripeObject
class AccountHolderAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
class BankAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Attribute for field account_holder_address
sig { returns(AccountHolderAddress) }
attr_reader :account_holder_address
# The account holder name
sig { returns(String) }
attr_reader :account_holder_name
# The account number
sig { returns(String) }
attr_reader :account_number
# The account type
sig { returns(String) }
attr_reader :account_type
# Attribute for field bank_address
sig { returns(BankAddress) }
attr_reader :bank_address
# The bank name
sig { returns(String) }
attr_reader :bank_name
# The SWIFT code
sig { returns(String) }
attr_reader :swift_code
end
class Zengin < Stripe::StripeObject
class AccountHolderAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
class BankAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Attribute for field account_holder_address
sig { returns(AccountHolderAddress) }
attr_reader :account_holder_address
# The account holder name
sig { returns(T.nilable(String)) }
attr_reader :account_holder_name
# The account number
sig { returns(T.nilable(String)) }
attr_reader :account_number
# The bank account type. In Japan, this can only be `futsu` or `toza`.
sig { returns(T.nilable(String)) }
attr_reader :account_type
# Attribute for field bank_address
sig { returns(BankAddress) }
attr_reader :bank_address
# The bank code of the account
sig { returns(T.nilable(String)) }
attr_reader :bank_code
# The bank name of the account
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# The branch code of the account
sig { returns(T.nilable(String)) }
attr_reader :branch_code
# The branch name of the account
sig { returns(T.nilable(String)) }
attr_reader :branch_name
end
# ABA Records contain U.S. bank account details per the ABA format.
sig { returns(Aba) }
attr_reader :aba
# Iban Records contain E.U. bank account details per the SEPA format.
sig { returns(Iban) }
attr_reader :iban
# Sort Code Records contain U.K. bank account details per the sort code format.
sig { returns(SortCode) }
attr_reader :sort_code
# SPEI Records contain Mexico bank account details per the SPEI format.
sig { returns(Spei) }
attr_reader :spei
# The payment networks supported by this FinancialAddress
sig { returns(T::Array[String]) }
attr_reader :supported_networks
# SWIFT Records contain U.S. bank account details per the SWIFT format.
sig { returns(Swift) }
attr_reader :swift
# The type of financial address
sig { returns(String) }
attr_reader :type
# Zengin Records contain Japan bank account details per the Zengin format.
sig { returns(Zengin) }
attr_reader :zengin
end
# The remaining amount that needs to be transferred to complete the payment.
sig { returns(T.nilable(Integer)) }
attr_reader :amount_remaining
# 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).
sig { returns(T.nilable(String)) }
attr_reader :currency
# A list of financial addresses that can be used to fund the customer balance
sig { returns(T::Array[FinancialAddress]) }
attr_reader :financial_addresses
# A link to a hosted page that guides your customer through completing the transfer.
sig { returns(T.nilable(String)) }
attr_reader :hosted_instructions_url
# A string identifying this payment. Instruct your customer to include this code in the reference or memo field of their bank transfer.
sig { returns(T.nilable(String)) }
attr_reader :reference
# Type of bank transfer
sig { returns(String) }
attr_reader :type
end
class KonbiniDisplayDetails < Stripe::StripeObject
class Stores < Stripe::StripeObject
class Familymart < Stripe::StripeObject
# The confirmation number.
sig { returns(String) }
attr_reader :confirmation_number
# The payment code.
sig { returns(String) }
attr_reader :payment_code
end
class Lawson < Stripe::StripeObject
# The confirmation number.
sig { returns(String) }
attr_reader :confirmation_number
# The payment code.
sig { returns(String) }
attr_reader :payment_code
end
class Ministop < Stripe::StripeObject
# The confirmation number.
sig { returns(String) }
attr_reader :confirmation_number
# The payment code.
sig { returns(String) }
attr_reader :payment_code
end
class Seicomart < Stripe::StripeObject
# The confirmation number.
sig { returns(String) }
attr_reader :confirmation_number
# The payment code.
sig { returns(String) }
attr_reader :payment_code
end
# FamilyMart instruction details.
sig { returns(T.nilable(Familymart)) }
attr_reader :familymart
# Lawson instruction details.
sig { returns(T.nilable(Lawson)) }
attr_reader :lawson
# Ministop instruction details.
sig { returns(T.nilable(Ministop)) }
attr_reader :ministop
# Seicomart instruction details.
sig { returns(T.nilable(Seicomart)) }
attr_reader :seicomart
end
# The timestamp at which the pending Konbini payment expires.
sig { returns(Integer) }
attr_reader :expires_at
# The URL for the Konbini payment instructions page, which allows customers to view and print a Konbini voucher.
sig { returns(T.nilable(String)) }
attr_reader :hosted_voucher_url
# Attribute for field stores
sig { returns(Stores) }
attr_reader :stores
end
class MultibancoDisplayDetails < Stripe::StripeObject
# Entity number associated with this Multibanco payment.
sig { returns(T.nilable(String)) }
attr_reader :entity
# The timestamp at which the Multibanco voucher expires.
sig { returns(T.nilable(Integer)) }
attr_reader :expires_at
# The URL for the hosted Multibanco voucher page, which allows customers to view a Multibanco voucher.
sig { returns(T.nilable(String)) }
attr_reader :hosted_voucher_url
# Reference number associated with this Multibanco payment.
sig { returns(T.nilable(String)) }
attr_reader :reference
end
class OxxoDisplayDetails < Stripe::StripeObject
# The timestamp after which the OXXO voucher expires.
sig { returns(T.nilable(Integer)) }
attr_reader :expires_after
# The URL for the hosted OXXO voucher page, which allows customers to view and print an OXXO voucher.
sig { returns(T.nilable(String)) }
attr_reader :hosted_voucher_url
# OXXO reference number.
sig { returns(T.nilable(String)) }
attr_reader :number
end
class PaynowDisplayQrCode < Stripe::StripeObject
# The raw data string used to generate QR code, it should be used together with QR code library.
sig { returns(String) }
attr_reader :data
# The URL to the hosted PayNow instructions page, which allows customers to view the PayNow QR code.
sig { returns(T.nilable(String)) }
attr_reader :hosted_instructions_url
# The image_url_png string used to render QR code
sig { returns(String) }
attr_reader :image_url_png
# The image_url_svg string used to render QR code
sig { returns(String) }
attr_reader :image_url_svg
end
class PixDisplayQrCode < Stripe::StripeObject
# The raw data string used to generate QR code, it should be used together with QR code library.
sig { returns(String) }
attr_reader :data
# The date (unix timestamp) when the PIX expires.
sig { returns(Integer) }
attr_reader :expires_at
# The URL to the hosted pix instructions page, which allows customers to view the pix QR code.
sig { returns(String) }
attr_reader :hosted_instructions_url
# The image_url_png string used to render png QR code
sig { returns(String) }
attr_reader :image_url_png
# The image_url_svg string used to render svg QR code
sig { returns(String) }
attr_reader :image_url_svg
end
class PromptpayDisplayQrCode < Stripe::StripeObject
# The raw data string used to generate QR code, it should be used together with QR code library.
sig { returns(String) }
attr_reader :data
# The URL to the hosted PromptPay instructions page, which allows customers to view the PromptPay QR code.
sig { returns(String) }
attr_reader :hosted_instructions_url
# The PNG path used to render the QR code, can be used as the source in an HTML img tag
sig { returns(String) }
attr_reader :image_url_png
# The SVG path used to render the QR code, can be used as the source in an HTML img tag
sig { returns(String) }
attr_reader :image_url_svg
end
class RedirectToUrl < Stripe::StripeObject
# If the customer does not exit their browser while authenticating, they will be redirected to this specified URL after completion.
sig { returns(T.nilable(String)) }
attr_reader :return_url
# The URL you must redirect your customer to in order to authenticate the payment.
sig { returns(T.nilable(String)) }
attr_reader :url
end
class SwishHandleRedirectOrDisplayQrCode < Stripe::StripeObject
class QrCode < Stripe::StripeObject
# The raw data string used to generate QR code, it should be used together with QR code library.
sig { returns(String) }
attr_reader :data
# The image_url_png string used to render QR code
sig { returns(String) }
attr_reader :image_url_png
# The image_url_svg string used to render QR code
sig { returns(String) }
attr_reader :image_url_svg
end
# The URL to the hosted Swish instructions page, which allows customers to view the QR code.
sig { returns(String) }
attr_reader :hosted_instructions_url
# The url for mobile redirect based auth (for internal use only and not typically available in standard API requests).
sig { returns(String) }
attr_reader :mobile_auth_url
# Attribute for field qr_code
sig { returns(QrCode) }
attr_reader :qr_code
end
class VerifyWithMicrodeposits < Stripe::StripeObject
# The timestamp when the microdeposits are expected to land.
sig { returns(Integer) }
attr_reader :arrival_date
# The URL for the hosted verification page, which allows customers to verify their bank account.
sig { returns(String) }
attr_reader :hosted_verification_url
# The type of the microdeposit sent to the customer. Used to distinguish between different verification methods.
sig { returns(T.nilable(String)) }
attr_reader :microdeposit_type
end
class WechatPayDisplayQrCode < Stripe::StripeObject
# The data being used to generate QR code
sig { returns(String) }
attr_reader :data
# The URL to the hosted WeChat Pay instructions page, which allows customers to view the WeChat Pay QR code.
sig { returns(String) }
attr_reader :hosted_instructions_url
# The base64 image data for a pre-generated QR code
sig { returns(String) }
attr_reader :image_data_url
# The image_url_png string used to render QR code
sig { returns(String) }
attr_reader :image_url_png
# The image_url_svg string used to render QR code
sig { returns(String) }
attr_reader :image_url_svg
end
class WechatPayRedirectToAndroidApp < Stripe::StripeObject
# app_id is the APP ID registered on WeChat open platform
sig { returns(String) }
attr_reader :app_id
# nonce_str is a random string
sig { returns(String) }
attr_reader :nonce_str
# package is static value
sig { returns(String) }
attr_reader :package
# an unique merchant ID assigned by WeChat Pay
sig { returns(String) }
attr_reader :partner_id
# an unique trading ID assigned by WeChat Pay
sig { returns(String) }
attr_reader :prepay_id
# A signature
sig { returns(String) }
attr_reader :sign
# Specifies the current time in epoch format
sig { returns(String) }
attr_reader :timestamp
end
class WechatPayRedirectToIosApp < Stripe::StripeObject
# An universal link that redirect to WeChat Pay app
sig { returns(String) }
attr_reader :native_url
end
# Attribute for field alipay_handle_redirect
sig { returns(AlipayHandleRedirect) }
attr_reader :alipay_handle_redirect
# Attribute for field boleto_display_details
sig { returns(BoletoDisplayDetails) }
attr_reader :boleto_display_details
# Attribute for field card_await_notification
sig { returns(CardAwaitNotification) }
attr_reader :card_await_notification
# Attribute for field cashapp_handle_redirect_or_display_qr_code
sig { returns(CashappHandleRedirectOrDisplayQrCode) }
attr_reader :cashapp_handle_redirect_or_display_qr_code
# Attribute for field display_bank_transfer_instructions
sig { returns(DisplayBankTransferInstructions) }
attr_reader :display_bank_transfer_instructions
# Attribute for field konbini_display_details
sig { returns(KonbiniDisplayDetails) }
attr_reader :konbini_display_details
# Attribute for field multibanco_display_details
sig { returns(MultibancoDisplayDetails) }
attr_reader :multibanco_display_details
# Attribute for field oxxo_display_details
sig { returns(OxxoDisplayDetails) }
attr_reader :oxxo_display_details
# Attribute for field paynow_display_qr_code
sig { returns(PaynowDisplayQrCode) }
attr_reader :paynow_display_qr_code
# Attribute for field pix_display_qr_code
sig { returns(PixDisplayQrCode) }
attr_reader :pix_display_qr_code
# Attribute for field promptpay_display_qr_code
sig { returns(PromptpayDisplayQrCode) }
attr_reader :promptpay_display_qr_code
# Attribute for field redirect_to_url
sig { returns(RedirectToUrl) }
attr_reader :redirect_to_url
# Attribute for field swish_handle_redirect_or_display_qr_code
sig { returns(SwishHandleRedirectOrDisplayQrCode) }
attr_reader :swish_handle_redirect_or_display_qr_code
# Type of the next action to perform. Refer to the other child attributes under `next_action` for available values. Examples include: `redirect_to_url`, `use_stripe_sdk`, `alipay_handle_redirect`, `oxxo_display_details`, or `verify_with_microdeposits`.
sig { returns(String) }
attr_reader :type
# When confirming a PaymentIntent with Stripe.js, Stripe.js depends on the contents of this dictionary to invoke authentication flows. The shape of the contents is subject to change and is only intended to be used by Stripe.js.
sig { returns(T::Hash[String, T.untyped]) }
attr_reader :use_stripe_sdk
# Attribute for field verify_with_microdeposits
sig { returns(VerifyWithMicrodeposits) }
attr_reader :verify_with_microdeposits
# Attribute for field wechat_pay_display_qr_code
sig { returns(WechatPayDisplayQrCode) }
attr_reader :wechat_pay_display_qr_code
# Attribute for field wechat_pay_redirect_to_android_app
sig { returns(WechatPayRedirectToAndroidApp) }
attr_reader :wechat_pay_redirect_to_android_app
# Attribute for field wechat_pay_redirect_to_ios_app
sig { returns(WechatPayRedirectToIosApp) }
attr_reader :wechat_pay_redirect_to_ios_app
end
class PaymentDetails < Stripe::StripeObject
class CarRental < Stripe::StripeObject
class Affiliate < Stripe::StripeObject
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_reader :name
end
class Delivery < Stripe::StripeObject
class Recipient < Stripe::StripeObject
# The email of the recipient the ticket is delivered to.
sig { returns(String) }
attr_reader :email
# The name of the recipient the ticket is delivered to.
sig { returns(String) }
attr_reader :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(String) }
attr_reader :phone
end
# The delivery method for the payment
sig { returns(String) }
attr_reader :mode
# Attribute for field recipient
sig { returns(Recipient) }
attr_reader :recipient
end
class Distance < Stripe::StripeObject
# Distance traveled.
sig { returns(Integer) }
attr_reader :amount
# Unit of measurement for the distance traveled. One of `miles` or `kilometers`
sig { returns(String) }
attr_reader :unit
end
class Driver < Stripe::StripeObject
# Driver's identification number.
sig { returns(String) }
attr_reader :driver_identification_number
# Driver's tax number.
sig { returns(String) }
attr_reader :driver_tax_number
# Full name of the driver on the reservation.
sig { returns(String) }
attr_reader :name
end
class PickupAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
class ReturnAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Attribute for field affiliate
sig { returns(Affiliate) }
attr_reader :affiliate
# The booking number associated with the car rental.
sig { returns(String) }
attr_reader :booking_number
# Class code of the car.
sig { returns(String) }
attr_reader :car_class_code
# Make of the car.
sig { returns(String) }
attr_reader :car_make
# Model of the car.
sig { returns(String) }
attr_reader :car_model
# The name of the rental car company.
sig { returns(String) }
attr_reader :company
# The customer service phone number of the car rental company.
sig { returns(String) }
attr_reader :customer_service_phone_number
# Number of days the car is being rented.
sig { returns(Integer) }
attr_reader :days_rented
# Attribute for field delivery
sig { returns(Delivery) }
attr_reader :delivery
# Attribute for field distance
sig { returns(Distance) }
attr_reader :distance
# The details of the drivers associated with the trip.
sig { returns(T::Array[Driver]) }
attr_reader :drivers
# List of additional charges being billed.
sig { returns(T::Array[String]) }
attr_reader :extra_charges
# Indicates if the customer did not keep nor cancel their booking.
sig { returns(T::Boolean) }
attr_reader :no_show
# Attribute for field pickup_address
sig { returns(PickupAddress) }
attr_reader :pickup_address
# Car pick-up time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :pickup_at
# Name of the pickup location.
sig { returns(String) }
attr_reader :pickup_location_name
# Rental rate.
sig { returns(Integer) }
attr_reader :rate_amount
# The frequency at which the rate amount is applied. One of `day`, `week` or `month`
sig { returns(String) }
attr_reader :rate_interval
# The full name of the person or entity renting the car.
sig { returns(String) }
attr_reader :renter_name
# Attribute for field return_address
sig { returns(ReturnAddress) }
attr_reader :return_address
# Car return time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :return_at
# Name of the return location.
sig { returns(String) }
attr_reader :return_location_name
# Indicates whether the goods or services are tax-exempt or tax is not collected.
sig { returns(T::Boolean) }
attr_reader :tax_exempt
# The vehicle identification number of the car.
sig { returns(String) }
attr_reader :vehicle_identification_number
end
class EventDetails < Stripe::StripeObject
class Address < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
class Affiliate < Stripe::StripeObject
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_reader :name
end
class Delivery < Stripe::StripeObject
class Recipient < Stripe::StripeObject
# The email of the recipient the ticket is delivered to.
sig { returns(String) }
attr_reader :email
# The name of the recipient the ticket is delivered to.
sig { returns(String) }
attr_reader :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(String) }
attr_reader :phone
end
# The delivery method for the payment
sig { returns(String) }
attr_reader :mode
# Attribute for field recipient
sig { returns(Recipient) }
attr_reader :recipient
end
# Indicates if the tickets are digitally checked when entering the venue.
sig { returns(T::Boolean) }
attr_reader :access_controlled_venue
# Attribute for field address
sig { returns(Address) }
attr_reader :address
# Attribute for field affiliate
sig { returns(Affiliate) }
attr_reader :affiliate
# The name of the company
sig { returns(String) }
attr_reader :company
# Attribute for field delivery
sig { returns(Delivery) }
attr_reader :delivery
# Event end time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :ends_at
# Type of the event entertainment (concert, sports event etc)
sig { returns(String) }
attr_reader :genre
# The name of the event.
sig { returns(String) }
attr_reader :name
# Event start time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :starts_at
end
class Subscription < Stripe::StripeObject
class Affiliate < Stripe::StripeObject
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_reader :name
end
class BillingInterval < Stripe::StripeObject
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_reader :count
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_reader :interval
end
# Attribute for field affiliate
sig { returns(Affiliate) }
attr_reader :affiliate
# Info whether the subscription will be auto renewed upon expiry.
sig { returns(T::Boolean) }
attr_reader :auto_renewal
# Attribute for field billing_interval
sig { returns(BillingInterval) }
attr_reader :billing_interval
# Subscription end time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :ends_at
# Name of the product on subscription. e.g. Apple Music Subscription.
sig { returns(String) }
attr_reader :name
# Subscription start time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :starts_at
end
# Attribute for field car_rental
sig { returns(CarRental) }
attr_reader :car_rental
# Some customers might be required by their company or organization to provide this information. If so, provide this value. Otherwise you can ignore this field.
sig { returns(T.nilable(String)) }
attr_reader :customer_reference
# Attribute for field event_details
sig { returns(EventDetails) }
attr_reader :event_details
# A unique value assigned by the business to identify the transaction.
sig { returns(T.nilable(String)) }
attr_reader :order_reference
# Attribute for field subscription
sig { returns(Subscription) }
attr_reader :subscription
end
class PaymentMethodConfigurationDetails < Stripe::StripeObject
# ID of the payment method configuration used.
sig { returns(String) }
attr_reader :id
# ID of the parent payment method configuration used.
sig { returns(T.nilable(String)) }
attr_reader :parent
end
class PaymentMethodOptions < Stripe::StripeObject
class AcssDebit < Stripe::StripeObject
class MandateOptions < Stripe::StripeObject
# A URL for custom mandate text
sig { returns(String) }
attr_reader :custom_mandate_url
# Description of the interval. Only required if the 'payment_schedule' parameter is 'interval' or 'combined'.
sig { returns(T.nilable(String)) }
attr_reader :interval_description
# Payment schedule for the mandate.
sig { returns(T.nilable(String)) }
attr_reader :payment_schedule
# Transaction type of the mandate.
sig { returns(T.nilable(String)) }
attr_reader :transaction_type
end
# Attribute for field mandate_options
sig { returns(MandateOptions) }
attr_reader :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(String) }
attr_reader :target_date
# Bank account verification method.
sig { returns(String) }
attr_reader :verification_method
end
class Affirm < Stripe::StripeObject
# Controls when the funds will be captured from the customer's account.
sig { returns(String) }
attr_reader :capture_method
# Preferred language of the Affirm authorization page that the customer is redirected to.
sig { returns(String) }
attr_reader :preferred_locale
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class AfterpayClearpay < Stripe::StripeObject
# Controls when the funds will be captured from the customer's account.
sig { returns(String) }
attr_reader :capture_method
# An internal identifier or reference that this payment corresponds to. You must limit the identifier to 128 characters, and it can only contain letters, numbers, underscores, backslashes, and dashes.
# This field differs from the statement descriptor and item name.
sig { returns(T.nilable(String)) }
attr_reader :reference
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Alipay < Stripe::StripeObject
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Alma < Stripe::StripeObject
# Controls when the funds will be captured from the customer's account.
sig { returns(String) }
attr_reader :capture_method
end
class AmazonPay < Stripe::StripeObject
# Controls when the funds will be captured from the customer's account.
sig { returns(String) }
attr_reader :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class AuBecsDebit < Stripe::StripeObject
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(String) }
attr_reader :target_date
end
class BacsDebit < Stripe::StripeObject
class MandateOptions < Stripe::StripeObject
# Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'DDIC' or 'STRIPE'.
sig { returns(String) }
attr_reader :reference_prefix
end
# Attribute for field mandate_options
sig { returns(MandateOptions) }
attr_reader :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(String) }
attr_reader :target_date
end
class Bancontact < Stripe::StripeObject
# Preferred language of the Bancontact authorization page that the customer is redirected to.
sig { returns(String) }
attr_reader :preferred_language
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Billie < Stripe::StripeObject
# Controls when the funds will be captured from the customer's account.
sig { returns(String) }
attr_reader :capture_method
end
class Blik < Stripe::StripeObject
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Boleto < Stripe::StripeObject
# The number of calendar days before a Boleto voucher expires. For example, if you create a Boleto voucher on Monday and you set expires_after_days to 2, the Boleto voucher will expire on Wednesday at 23:59 America/Sao_Paulo time.
sig { returns(Integer) }
attr_reader :expires_after_days
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Card < Stripe::StripeObject
class Installments < Stripe::StripeObject
class AvailablePlan < Stripe::StripeObject
# For `fixed_count` installment plans, this is the number of installment payments your customer will make to their credit card.
sig { returns(T.nilable(Integer)) }
attr_reader :count
# For `fixed_count` installment plans, this is the interval between installment payments your customer will make to their credit card.
# One of `month`.
sig { returns(T.nilable(String)) }
attr_reader :interval
# Type of installment plan, one of `fixed_count`.
sig { returns(String) }
attr_reader :type
end
class Plan < Stripe::StripeObject
# For `fixed_count` installment plans, this is the number of installment payments your customer will make to their credit card.
sig { returns(T.nilable(Integer)) }
attr_reader :count
# For `fixed_count` installment plans, this is the interval between installment payments your customer will make to their credit card.
# One of `month`.
sig { returns(T.nilable(String)) }
attr_reader :interval
# Type of installment plan, one of `fixed_count`.
sig { returns(String) }
attr_reader :type
end
# Installment plans that may be selected for this PaymentIntent.
sig { returns(T.nilable(T::Array[AvailablePlan])) }
attr_reader :available_plans
# Whether Installments are enabled for this PaymentIntent.
sig { returns(T::Boolean) }
attr_reader :enabled
# Installment plan selected for this PaymentIntent.
sig { returns(T.nilable(Plan)) }
attr_reader :plan
end
class MandateOptions < Stripe::StripeObject
# Amount to be charged for future payments.
sig { returns(Integer) }
attr_reader :amount
# One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.
sig { returns(String) }
attr_reader :amount_type
# A description of the mandate or subscription that is meant to be displayed to the customer.
sig { returns(T.nilable(String)) }
attr_reader :description
# End date of the mandate or subscription. If not provided, the mandate will be active until canceled. If provided, end date should be after start date.
sig { returns(T.nilable(Integer)) }
attr_reader :end_date
# Specifies payment frequency. One of `day`, `week`, `month`, `year`, or `sporadic`.
sig { returns(String) }
attr_reader :interval
# The number of intervals between payments. For example, `interval=month` and `interval_count=3` indicates one payment every three months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks). This parameter is optional when `interval=sporadic`.
sig { returns(T.nilable(Integer)) }
attr_reader :interval_count
# Unique identifier for the mandate or subscription.
sig { returns(String) }
attr_reader :reference
# Start date of the mandate or subscription. Start date should not be lesser than yesterday.
sig { returns(Integer) }
attr_reader :start_date
# Specifies the type of mandates supported. Possible values are `india`.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :supported_types
end
class StatementDetails < Stripe::StripeObject
class Address < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(String) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(String) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(String) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(String) }
attr_reader :line2
# ZIP or postal code.
sig { returns(String) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(String) }
attr_reader :state
end
# Attribute for field address
sig { returns(Address) }
attr_reader :address
# Phone number
sig { returns(String) }
attr_reader :phone
end
# Controls when the funds will be captured from the customer's account.
sig { returns(String) }
attr_reader :capture_method
# Installment details for this payment (Mexico only).
#
# For more information, see the [installments integration guide](https://stripe.com/docs/payments/installments).
sig { returns(T.nilable(Installments)) }
attr_reader :installments
# Configuration options for setting up an eMandate for cards issued in India.
sig { returns(T.nilable(MandateOptions)) }
attr_reader :mandate_options
# Selected network to process this payment intent on. Depends on the available networks of the card attached to the payment intent. Can be only set confirm-time.
sig { returns(T.nilable(String)) }
attr_reader :network
# Request ability to [decrement the authorization](https://stripe.com/docs/payments/decremental-authorization) for this PaymentIntent.
sig { returns(String) }
attr_reader :request_decremental_authorization
# Request ability to [capture beyond the standard authorization validity window](https://stripe.com/docs/payments/extended-authorization) for this PaymentIntent.
sig { returns(String) }
attr_reader :request_extended_authorization
# Request ability to [increment the authorization](https://stripe.com/docs/payments/incremental-authorization) for this PaymentIntent.
sig { returns(String) }
attr_reader :request_incremental_authorization
# Request ability to make [multiple captures](https://stripe.com/docs/payments/multicapture) for this PaymentIntent.
sig { returns(String) }
attr_reader :request_multicapture
# Request ability to [overcapture](https://stripe.com/docs/payments/overcapture) for this PaymentIntent.
sig { returns(String) }
attr_reader :request_overcapture
# Request partial authorization on this PaymentIntent.
sig { returns(String) }
attr_reader :request_partial_authorization
# We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. If not provided, this value defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
sig { returns(T.nilable(String)) }
attr_reader :request_three_d_secure
# When enabled, using a card that is attached to a customer will require the CVC to be provided again (i.e. using the cvc_token parameter).
sig { returns(T::Boolean) }
attr_reader :require_cvc_recollection
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
# Provides information about a card payment that customers see on their statements. Concatenated with the Kana prefix (shortened Kana descriptor) or Kana statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 22 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 22 characters.
sig { returns(String) }
attr_reader :statement_descriptor_suffix_kana
# Provides information about a card payment that customers see on their statements. Concatenated with the Kanji prefix (shortened Kanji descriptor) or Kanji statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 17 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 17 characters.
sig { returns(String) }
attr_reader :statement_descriptor_suffix_kanji
# Attribute for field statement_details
sig { returns(StatementDetails) }
attr_reader :statement_details
end
class CardPresent < Stripe::StripeObject
class Routing < Stripe::StripeObject
# Requested routing priority
sig { returns(T.nilable(String)) }
attr_reader :requested_priority
end
# Request ability to capture this payment beyond the standard [authorization validity window](https://stripe.com/docs/terminal/features/extended-authorizations#authorization-validity)
sig { returns(T.nilable(T::Boolean)) }
attr_reader :request_extended_authorization
# Request ability to [increment](https://stripe.com/docs/terminal/features/incremental-authorizations) this PaymentIntent if the combination of MCC and card brand is eligible. Check [incremental_authorization_supported](https://stripe.com/docs/api/charges/object#charge_object-payment_method_details-card_present-incremental_authorization_supported) in the [Confirm](https://stripe.com/docs/api/payment_intents/confirm) response to verify support.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :request_incremental_authorization_support
# Attribute for field routing
sig { returns(Routing) }
attr_reader :routing
end
class Cashapp < Stripe::StripeObject
# Controls when the funds will be captured from the customer's account.
sig { returns(String) }
attr_reader :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class CustomerBalance < Stripe::StripeObject
class BankTransfer < Stripe::StripeObject
class EuBankTransfer < Stripe::StripeObject
# The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
sig { returns(String) }
attr_reader :country
end
# Attribute for field eu_bank_transfer
sig { returns(EuBankTransfer) }
attr_reader :eu_bank_transfer
# List of address types that should be returned in the financial_addresses response. If not specified, all valid types will be returned.
#
# Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`.
sig { returns(T::Array[String]) }
attr_reader :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`, `mx_bank_transfer`, or `us_bank_transfer`.
sig { returns(T.nilable(String)) }
attr_reader :type
end
# Attribute for field bank_transfer
sig { returns(BankTransfer) }
attr_reader :bank_transfer
# The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
sig { returns(T.nilable(String)) }
attr_reader :funding_type
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Eps < Stripe::StripeObject
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Fpx < Stripe::StripeObject
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Giropay < Stripe::StripeObject
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Gopay < Stripe::StripeObject
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Grabpay < Stripe::StripeObject
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class IdBankTransfer < Stripe::StripeObject
# The UNIX timestamp until which the virtual bank account is valid. Permitted range is from now till 2678400 seconds (31 days) from now.
sig { returns(T.nilable(Integer)) }
attr_reader :expires_after
# The UNIX timestamp until which the virtual bank account is valid. Permitted range is from now until 30 days from now. If unset, it defaults to 1 days from now.
sig { returns(T.nilable(Integer)) }
attr_reader :expires_at
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Ideal < Stripe::StripeObject
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class InteracPresent < Stripe::StripeObject; end
class KakaoPay < Stripe::StripeObject
# Controls when the funds will be captured from the customer's account.
sig { returns(String) }
attr_reader :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Klarna < Stripe::StripeObject
# Controls when the funds will be captured from the customer's account.
sig { returns(String) }
attr_reader :capture_method
# Preferred locale of the Klarna checkout page that the customer is redirected to.
sig { returns(T.nilable(String)) }
attr_reader :preferred_locale
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Konbini < Stripe::StripeObject
# An optional 10 to 11 digit numeric-only string determining the confirmation code at applicable convenience stores.
sig { returns(T.nilable(String)) }
attr_reader :confirmation_number
# The number of calendar days (between 1 and 60) after which Konbini payment instructions will expire. For example, if a PaymentIntent is confirmed with Konbini and `expires_after_days` set to 2 on Monday JST, the instructions will expire on Wednesday 23:59:59 JST.
sig { returns(T.nilable(Integer)) }
attr_reader :expires_after_days
# The timestamp at which the Konbini payment instructions will expire. Only one of `expires_after_days` or `expires_at` may be set.
sig { returns(T.nilable(Integer)) }
attr_reader :expires_at
# A product descriptor of up to 22 characters, which will appear to customers at the convenience store.
sig { returns(T.nilable(String)) }
attr_reader :product_description
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class KrCard < Stripe::StripeObject
# Controls when the funds will be captured from the customer's account.
sig { returns(String) }
attr_reader :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Link < Stripe::StripeObject
# Controls when the funds will be captured from the customer's account.
sig { returns(String) }
attr_reader :capture_method
# [Deprecated] This is a legacy parameter that no longer has any function.
sig { returns(T.nilable(String)) }
attr_reader :persistent_token
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class MbWay < Stripe::StripeObject
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Mobilepay < Stripe::StripeObject
# Controls when the funds will be captured from the customer's account.
sig { returns(String) }
attr_reader :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Multibanco < Stripe::StripeObject
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class NaverPay < Stripe::StripeObject
# Controls when the funds will be captured from the customer's account.
sig { returns(String) }
attr_reader :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class NzBankAccount < Stripe::StripeObject
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(String) }
attr_reader :target_date
end
class Oxxo < Stripe::StripeObject
# The number of calendar days before an OXXO invoice expires. For example, if you create an OXXO invoice on Monday and you set expires_after_days to 2, the OXXO invoice will expire on Wednesday at 23:59 America/Mexico_City time.
sig { returns(Integer) }
attr_reader :expires_after_days
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class P24 < Stripe::StripeObject
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class PayByBank < Stripe::StripeObject; end
class Payco < Stripe::StripeObject
# Controls when the funds will be captured from the customer's account.
sig { returns(String) }
attr_reader :capture_method
end
class Paynow < Stripe::StripeObject
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Paypal < Stripe::StripeObject
class LineItem < Stripe::StripeObject
class Tax < Stripe::StripeObject
# The tax for a single unit of the line item in minor units. Cannot be a negative number.
sig { returns(Integer) }
attr_reader :amount
# The tax behavior for the line item.
sig { returns(String) }
attr_reader :behavior
end
# Type of the line item.
sig { returns(String) }
attr_reader :category
# Description of the line item.
sig { returns(String) }
attr_reader :description
# Descriptive name of the line item.
sig { returns(String) }
attr_reader :name
# Quantity of the line item. Cannot be a negative number.
sig { returns(Integer) }
attr_reader :quantity
# Client facing stock keeping unit, article number or similar.
sig { returns(String) }
attr_reader :sku
# The Stripe account ID of the connected account that sells the item. This is only needed when using [Separate Charges and Transfers](https://docs.stripe.com/connect/separate-charges-and-transfers).
sig { returns(String) }
attr_reader :sold_by
# Attribute for field tax
sig { returns(Tax) }
attr_reader :tax
# Price for a single unit of the line item in minor units. Cannot be a negative number.
sig { returns(Integer) }
attr_reader :unit_amount
end
# Controls when the funds will be captured from the customer's account.
sig { returns(String) }
attr_reader :capture_method
# The line items purchased by the customer.
sig { returns(T::Array[LineItem]) }
attr_reader :line_items
# Preferred locale of the PayPal checkout page that the customer is redirected to.
sig { returns(T.nilable(String)) }
attr_reader :preferred_locale
# A reference of the PayPal transaction visible to customer which is mapped to PayPal's invoice ID. This must be a globally unique ID if you have configured in your PayPal settings to block multiple payments per invoice ID.
sig { returns(T.nilable(String)) }
attr_reader :reference
# A reference of the PayPal transaction visible to customer which is mapped to PayPal's invoice ID. This must be a globally unique ID if you have configured in your PayPal settings to block multiple payments per invoice ID.
sig { returns(T.nilable(String)) }
attr_reader :reference_id
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
# The Stripe connected account IDs of the sellers on the platform for this transaction (optional). Only allowed when [separate charges and transfers](https://stripe.com/docs/connect/separate-charges-and-transfers) are used.
sig { returns(T::Array[String]) }
attr_reader :subsellers
end
class Payto < Stripe::StripeObject
class MandateOptions < Stripe::StripeObject
# Amount that will be collected. It is required when `amount_type` is `fixed`.
sig { returns(T.nilable(Integer)) }
attr_reader :amount
# The type of amount that will be collected. The amount charged must be exact or up to the value of `amount` param for `fixed` or `maximum` type respectively.
sig { returns(T.nilable(String)) }
attr_reader :amount_type
# Date, in YYYY-MM-DD format, after which payments will not be collected. Defaults to no end date.
sig { returns(T.nilable(String)) }
attr_reader :end_date
# The periodicity at which payments will be collected.
sig { returns(T.nilable(String)) }
attr_reader :payment_schedule
# The number of payments that will be made during a payment period. Defaults to 1 except for when `payment_schedule` is `adhoc`. In that case, it defaults to no limit.
sig { returns(T.nilable(Integer)) }
attr_reader :payments_per_period
# The purpose for which payments are made. Defaults to retail.
sig { returns(T.nilable(String)) }
attr_reader :purpose
end
# Attribute for field mandate_options
sig { returns(MandateOptions) }
attr_reader :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Pix < Stripe::StripeObject
# The number of seconds (between 10 and 1209600) after which Pix payment will expire.
sig { returns(T.nilable(Integer)) }
attr_reader :expires_after_seconds
# The timestamp at which the Pix expires.
sig { returns(T.nilable(Integer)) }
attr_reader :expires_at
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Promptpay < Stripe::StripeObject
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Qris < Stripe::StripeObject
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Rechnung < Stripe::StripeObject; end
class RevolutPay < Stripe::StripeObject
# Controls when the funds will be captured from the customer's account.
sig { returns(String) }
attr_reader :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class SamsungPay < Stripe::StripeObject
# Controls when the funds will be captured from the customer's account.
sig { returns(String) }
attr_reader :capture_method
end
class Satispay < Stripe::StripeObject
# Controls when the funds will be captured from the customer's account.
sig { returns(String) }
attr_reader :capture_method
end
class SepaDebit < Stripe::StripeObject
class MandateOptions < Stripe::StripeObject
# Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'STRIPE'.
sig { returns(String) }
attr_reader :reference_prefix
end
# Attribute for field mandate_options
sig { returns(MandateOptions) }
attr_reader :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(String) }
attr_reader :target_date
end
class Shopeepay < Stripe::StripeObject
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Sofort < Stripe::StripeObject
# Preferred language of the SOFORT authorization page that the customer is redirected to.
sig { returns(T.nilable(String)) }
attr_reader :preferred_language
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class StripeBalance < Stripe::StripeObject
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Swish < Stripe::StripeObject
# A reference for this payment to be displayed in the Swish app.
sig { returns(T.nilable(String)) }
attr_reader :reference
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Twint < Stripe::StripeObject
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class UsBankAccount < Stripe::StripeObject
class FinancialConnections < Stripe::StripeObject
class Filters < Stripe::StripeObject
# The account subcategories to use to filter for possible accounts to link. Valid subcategories are `checking` and `savings`.
sig { returns(T::Array[String]) }
attr_reader :account_subcategories
# The institution to use to filter for possible accounts to link.
sig { returns(String) }
attr_reader :institution
end
class ManualEntry < Stripe::StripeObject
# Settings for configuring manual entry of account details.
sig { returns(String) }
attr_reader :mode
end
# Attribute for field filters
sig { returns(Filters) }
attr_reader :filters
# Attribute for field manual_entry
sig { returns(ManualEntry) }
attr_reader :manual_entry
# The list of permissions to request. The `payment_method` permission must be included.
sig { returns(T::Array[String]) }
attr_reader :permissions
# Data features requested to be retrieved upon account creation.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :prefetch
# For webview integrations only. Upon completing OAuth login in the native browser, the user will be redirected to this URL to return to your app.
sig { returns(String) }
attr_reader :return_url
end
class MandateOptions < Stripe::StripeObject
# Mandate collection method
sig { returns(String) }
attr_reader :collection_method
end
# Attribute for field financial_connections
sig { returns(FinancialConnections) }
attr_reader :financial_connections
# Attribute for field mandate_options
sig { returns(MandateOptions) }
attr_reader :mandate_options
# Preferred transaction settlement speed
sig { returns(String) }
attr_reader :preferred_settlement_speed
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(String) }
attr_reader :target_date
# Bank account verification method.
sig { returns(String) }
attr_reader :verification_method
end
class WechatPay < Stripe::StripeObject
# The app ID registered with WeChat Pay. Only required when client is ios or android.
sig { returns(T.nilable(String)) }
attr_reader :app_id
# The client type that the end customer will pay from
sig { returns(T.nilable(String)) }
attr_reader :client
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
class Zip < Stripe::StripeObject
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(String) }
attr_reader :setup_future_usage
end
# Attribute for field acss_debit
sig { returns(AcssDebit) }
attr_reader :acss_debit
# Attribute for field affirm
sig { returns(Affirm) }
attr_reader :affirm
# Attribute for field afterpay_clearpay
sig { returns(AfterpayClearpay) }
attr_reader :afterpay_clearpay
# Attribute for field alipay
sig { returns(Alipay) }
attr_reader :alipay
# Attribute for field alma
sig { returns(Alma) }
attr_reader :alma
# Attribute for field amazon_pay
sig { returns(AmazonPay) }
attr_reader :amazon_pay
# Attribute for field au_becs_debit
sig { returns(AuBecsDebit) }
attr_reader :au_becs_debit
# Attribute for field bacs_debit
sig { returns(BacsDebit) }
attr_reader :bacs_debit
# Attribute for field bancontact
sig { returns(Bancontact) }
attr_reader :bancontact
# Attribute for field billie
sig { returns(Billie) }
attr_reader :billie
# Attribute for field blik
sig { returns(Blik) }
attr_reader :blik
# Attribute for field boleto
sig { returns(Boleto) }
attr_reader :boleto
# Attribute for field card
sig { returns(Card) }
attr_reader :card
# Attribute for field card_present
sig { returns(CardPresent) }
attr_reader :card_present
# Attribute for field cashapp
sig { returns(Cashapp) }
attr_reader :cashapp
# Attribute for field customer_balance
sig { returns(CustomerBalance) }
attr_reader :customer_balance
# Attribute for field eps
sig { returns(Eps) }
attr_reader :eps
# Attribute for field fpx
sig { returns(Fpx) }
attr_reader :fpx
# Attribute for field giropay
sig { returns(Giropay) }
attr_reader :giropay
# Attribute for field gopay
sig { returns(Gopay) }
attr_reader :gopay
# Attribute for field grabpay
sig { returns(Grabpay) }
attr_reader :grabpay
# Attribute for field id_bank_transfer
sig { returns(IdBankTransfer) }
attr_reader :id_bank_transfer
# Attribute for field ideal
sig { returns(Ideal) }
attr_reader :ideal
# Attribute for field interac_present
sig { returns(InteracPresent) }
attr_reader :interac_present
# Attribute for field kakao_pay
sig { returns(KakaoPay) }
attr_reader :kakao_pay
# Attribute for field klarna
sig { returns(Klarna) }
attr_reader :klarna
# Attribute for field konbini
sig { returns(Konbini) }
attr_reader :konbini
# Attribute for field kr_card
sig { returns(KrCard) }
attr_reader :kr_card
# Attribute for field link
sig { returns(Link) }
attr_reader :link
# Attribute for field mb_way
sig { returns(MbWay) }
attr_reader :mb_way
# Attribute for field mobilepay
sig { returns(Mobilepay) }
attr_reader :mobilepay
# Attribute for field multibanco
sig { returns(Multibanco) }
attr_reader :multibanco
# Attribute for field naver_pay
sig { returns(NaverPay) }
attr_reader :naver_pay
# Attribute for field nz_bank_account
sig { returns(NzBankAccount) }
attr_reader :nz_bank_account
# Attribute for field oxxo
sig { returns(Oxxo) }
attr_reader :oxxo
# Attribute for field p24
sig { returns(P24) }
attr_reader :p24
# Attribute for field pay_by_bank
sig { returns(PayByBank) }
attr_reader :pay_by_bank
# Attribute for field payco
sig { returns(Payco) }
attr_reader :payco
# Attribute for field paynow
sig { returns(Paynow) }
attr_reader :paynow
# Attribute for field paypal
sig { returns(Paypal) }
attr_reader :paypal
# Attribute for field payto
sig { returns(Payto) }
attr_reader :payto
# Attribute for field pix
sig { returns(Pix) }
attr_reader :pix
# Attribute for field promptpay
sig { returns(Promptpay) }
attr_reader :promptpay
# Attribute for field qris
sig { returns(Qris) }
attr_reader :qris
# Attribute for field rechnung
sig { returns(Rechnung) }
attr_reader :rechnung
# Attribute for field revolut_pay
sig { returns(RevolutPay) }
attr_reader :revolut_pay
# Attribute for field samsung_pay
sig { returns(SamsungPay) }
attr_reader :samsung_pay
# Attribute for field satispay
sig { returns(Satispay) }
attr_reader :satispay
# Attribute for field sepa_debit
sig { returns(SepaDebit) }
attr_reader :sepa_debit
# Attribute for field shopeepay
sig { returns(Shopeepay) }
attr_reader :shopeepay
# Attribute for field sofort
sig { returns(Sofort) }
attr_reader :sofort
# Attribute for field stripe_balance
sig { returns(StripeBalance) }
attr_reader :stripe_balance
# Attribute for field swish
sig { returns(Swish) }
attr_reader :swish
# Attribute for field twint
sig { returns(Twint) }
attr_reader :twint
# Attribute for field us_bank_account
sig { returns(UsBankAccount) }
attr_reader :us_bank_account
# Attribute for field wechat_pay
sig { returns(WechatPay) }
attr_reader :wechat_pay
# Attribute for field zip
sig { returns(Zip) }
attr_reader :zip
end
class PresentmentDetails < Stripe::StripeObject
# Amount intended to be collected by this payment, denominated in presentment_currency.
sig { returns(Integer) }
attr_reader :presentment_amount
# Currency presented to the customer during payment.
sig { returns(String) }
attr_reader :presentment_currency
end
class Processing < Stripe::StripeObject
class Card < Stripe::StripeObject
class CustomerNotification < Stripe::StripeObject
# Whether customer approval has been requested for this payment. For payments greater than INR 15000 or mandate amount, the customer must provide explicit approval of the payment with their bank.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :approval_requested
# If customer approval is required, they need to provide approval before this time.
sig { returns(T.nilable(Integer)) }
attr_reader :completes_at
end
# Attribute for field customer_notification
sig { returns(CustomerNotification) }
attr_reader :customer_notification
end
# Attribute for field card
sig { returns(Card) }
attr_reader :card
# Type of the payment method for which payment is in `processing` state, one of `card`.
sig { returns(String) }
attr_reader :type
end
class Shipping < Stripe::StripeObject
class Address < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Attribute for field address
sig { returns(Address) }
attr_reader :address
# The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
sig { returns(T.nilable(String)) }
attr_reader :carrier
# Recipient name.
sig { returns(String) }
attr_reader :name
# Recipient phone (including extension).
sig { returns(T.nilable(String)) }
attr_reader :phone
# The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
sig { returns(T.nilable(String)) }
attr_reader :tracking_number
end
class TransferData < Stripe::StripeObject
# The amount transferred to the destination account. This transfer will occur automatically after the payment succeeds. If no amount is specified, by default the entire payment amount is transferred to the destination account.
# The amount must be less than or equal to the [amount](https://stripe.com/docs/api/payment_intents/object#payment_intent_object-amount), and must be a positive integer
# representing how much to transfer in the smallest currency unit (e.g., 100 cents to charge $1.00).
sig { returns(Integer) }
attr_reader :amount
# The account (if any) that the payment is attributed to for tax reporting, and where funds from the payment are transferred to after payment success.
sig { returns(T.any(String, Stripe::Account)) }
attr_reader :destination
end
# Amount intended to be collected by this PaymentIntent. A positive integer representing how much to charge in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is $0.50 US or [equivalent in charge currency](https://stripe.com/docs/currencies#minimum-and-maximum-charge-amounts). The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99).
sig { returns(Integer) }
attr_reader :amount
# Amount that can be captured from this PaymentIntent.
sig { returns(Integer) }
attr_reader :amount_capturable
# Attribute for field amount_details
sig { returns(AmountDetails) }
attr_reader :amount_details
# Amount that this PaymentIntent collects.
sig { returns(Integer) }
attr_reader :amount_received
# ID of the Connect application that created the PaymentIntent.
sig { returns(T.nilable(T.any(String, Stripe::Application))) }
attr_reader :application
# The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. The amount of the application fee collected will be capped at the total amount captured. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
sig { returns(T.nilable(Integer)) }
attr_reader :application_fee_amount
# Settings to configure compatible payment methods from the [Stripe Dashboard](https://dashboard.stripe.com/settings/payment_methods)
sig { returns(T.nilable(AutomaticPaymentMethods)) }
attr_reader :automatic_payment_methods
# Populated when `status` is `canceled`, this is the time at which the PaymentIntent was canceled. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_reader :canceled_at
# Reason for cancellation of this PaymentIntent, either user-provided (`duplicate`, `fraudulent`, `requested_by_customer`, or `abandoned`) or generated by Stripe internally (`failed_invoice`, `void_invoice`, `automatic`, or `expired`).
sig { returns(T.nilable(String)) }
attr_reader :cancellation_reason
# Controls when the funds will be captured from the customer's account.
sig { returns(String) }
attr_reader :capture_method
# The client secret of this PaymentIntent. Used for client-side retrieval using a publishable key.
#
# The client secret can be used to complete a payment from your frontend. It should not be stored, logged, or exposed to anyone other than the customer. Make sure that you have TLS enabled on any page that includes the client secret.
#
# Refer to our docs to [accept a payment](https://stripe.com/docs/payments/accept-a-payment?ui=elements) and learn about how `client_secret` should be handled.
sig { returns(T.nilable(String)) }
attr_reader :client_secret
# Describes whether we can confirm this PaymentIntent automatically, or if it requires customer action to confirm the payment.
sig { returns(String) }
attr_reader :confirmation_method
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# 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).
sig { returns(String) }
attr_reader :currency
# ID of the Customer this PaymentIntent belongs to, if one exists.
#
# Payment methods attached to other Customers cannot be used with this PaymentIntent.
#
# If [setup_future_usage](https://stripe.com/docs/api#payment_intent_object-setup_future_usage) is set and this PaymentIntent's payment method is not `card_present`, then the payment method attaches to the Customer after the PaymentIntent has been confirmed and any required actions from the user are complete. If the payment method is `card_present` and isn't a digital wallet, then a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card is created and attached to the Customer instead.
sig { returns(T.nilable(T.any(String, Stripe::Customer))) }
attr_reader :customer
# ID of the Account this PaymentIntent belongs to, if one exists.
#
# Payment methods attached to other Accounts cannot be used with this PaymentIntent.
#
# If [setup_future_usage](https://stripe.com/docs/api#payment_intent_object-setup_future_usage) is set and this PaymentIntent's payment method is not `card_present`, then the payment method attaches to the Account after the PaymentIntent has been confirmed and any required actions from the user are complete. If the payment method is `card_present` and isn't a digital wallet, then a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card is created and attached to the Account instead.
sig { returns(T.nilable(String)) }
attr_reader :customer_account
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_reader :description
# The FX Quote used for the PaymentIntent.
sig { returns(T.nilable(String)) }
attr_reader :fx_quote
# Attribute for field hooks
sig { returns(Hooks) }
attr_reader :hooks
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# The payment error encountered in the previous PaymentIntent confirmation. It will be cleared if the PaymentIntent is later updated for any reason.
sig { returns(T.nilable(LastPaymentError)) }
attr_reader :last_payment_error
# ID of the latest [Charge object](https://stripe.com/docs/api/charges) created by this PaymentIntent. This property is `null` until PaymentIntent confirmation is attempted.
sig { returns(T.nilable(T.any(String, Stripe::Charge))) }
attr_reader :latest_charge
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# 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. Learn more about [storing information in metadata](https://stripe.com/docs/payments/payment-intents/creating-payment-intents#storing-information-in-metadata).
sig { returns(T::Hash[String, String]) }
attr_reader :metadata
# If present, this property tells you what actions you need to take in order for your customer to fulfill a payment using the provided source.
sig { returns(T.nilable(NextAction)) }
attr_reader :next_action
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The account (if any) for which the funds of the PaymentIntent are intended. See the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts) for details.
sig { returns(T.nilable(T.any(String, Stripe::Account))) }
attr_reader :on_behalf_of
# Attribute for field payment_details
sig { returns(PaymentDetails) }
attr_reader :payment_details
# ID of the payment method used in this PaymentIntent.
sig { returns(T.nilable(T.any(String, Stripe::PaymentMethod))) }
attr_reader :payment_method
# Information about the [payment method configuration](https://stripe.com/docs/api/payment_method_configurations) used for this PaymentIntent.
sig { returns(T.nilable(PaymentMethodConfigurationDetails)) }
attr_reader :payment_method_configuration_details
# Payment-method-specific configuration for this PaymentIntent.
sig { returns(T.nilable(PaymentMethodOptions)) }
attr_reader :payment_method_options
# The list of payment method types (e.g. card) that this PaymentIntent is allowed to use. A comprehensive list of valid payment method types can be found [here](https://docs.stripe.com/api/payment_methods/object#payment_method_object-type).
sig { returns(T::Array[String]) }
attr_reader :payment_method_types
# Attribute for field presentment_details
sig { returns(PresentmentDetails) }
attr_reader :presentment_details
# If present, this property tells you about the processing state of the payment.
sig { returns(T.nilable(Processing)) }
attr_reader :processing
# Email address that the receipt for the resulting payment will be sent to. If `receipt_email` is specified for a payment in live mode, a receipt will be sent regardless of your [email settings](https://dashboard.stripe.com/account/emails).
sig { returns(T.nilable(String)) }
attr_reader :receipt_email
# ID of the review associated with this PaymentIntent, if any.
sig { returns(T.nilable(T.any(String, Stripe::Review))) }
attr_reader :review
# Indicates whether confirmation for this PaymentIntent using a secret key is `required` or `optional`.
sig { returns(String) }
attr_reader :secret_key_confirmation
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_reader :setup_future_usage
# Shipping information for this PaymentIntent.
sig { returns(T.nilable(Shipping)) }
attr_reader :shipping
# This is a legacy field that will be removed in the future. It is the ID of the Source object that is associated with this PaymentIntent, if one was supplied.
sig {
returns(T.nilable(T.any(String, T.any(Stripe::Account, Stripe::BankAccount, Stripe::Card, Stripe::Source))))
}
attr_reader :source
# Text that appears on the customer's statement as the statement descriptor for a non-card charge. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
#
# Setting this value for a card charge returns an error. For card charges, set the [statement_descriptor_suffix](https://docs.stripe.com/get-started/account/statement-descriptors#dynamic) instead.
sig { returns(T.nilable(String)) }
attr_reader :statement_descriptor
# Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement.
sig { returns(T.nilable(String)) }
attr_reader :statement_descriptor_suffix
# Status of this PaymentIntent, one of `requires_payment_method`, `requires_confirmation`, `requires_action`, `processing`, `requires_capture`, `canceled`, or `succeeded`. Read more about each PaymentIntent [status](https://stripe.com/docs/payments/intents#intent-statuses).
sig { returns(String) }
attr_reader :status
# The data that automatically creates a Transfer after the payment finalizes. Learn more about the [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
sig { returns(T.nilable(TransferData)) }
attr_reader :transfer_data
# A string that identifies the resulting payment as part of a group. Learn more about the [use case for connected accounts](https://stripe.com/docs/connect/separate-charges-and-transfers).
sig { returns(T.nilable(String)) }
attr_reader :transfer_group
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp or a dictionary with a number of different query options.
sig { returns(T.nilable(T.any(::Stripe::PaymentIntent::ListParams::Created, Integer))) }
attr_accessor :created
# Only return PaymentIntents for the customer that this customer ID specifies.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# Only return PaymentIntents for the account that this ID specifies.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(created: T.nilable(T.any(::Stripe::PaymentIntent::ListParams::Created, Integer)), customer: T.nilable(String), customer_account: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
created: nil,
customer: nil,
customer_account: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class AutomaticPaymentMethods < Stripe::RequestParams
# Controls whether this PaymentIntent will accept redirect-based payment methods.
#
# Redirect-based payment methods may require your customer to be redirected to a payment method's app or site for authentication or additional steps. To [confirm](https://stripe.com/docs/api/payment_intents/confirm) this PaymentIntent, you may be required to provide a `return_url` to redirect customers back to your site after they authenticate or complete the payment.
sig { returns(T.nilable(String)) }
attr_accessor :allow_redirects
# Whether this feature is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
sig { params(allow_redirects: T.nilable(String), enabled: T::Boolean).void }
def initialize(allow_redirects: nil, enabled: nil); end
end
class Hooks < Stripe::RequestParams
class Inputs < Stripe::RequestParams
class Tax < Stripe::RequestParams
# The [TaxCalculation](https://stripe.com/docs/api/tax/calculations) id
sig { returns(T.nilable(String)) }
attr_accessor :calculation
sig { params(calculation: T.nilable(String)).void }
def initialize(calculation: nil); end
end
# Tax arguments for automations
sig { returns(T.nilable(::Stripe::PaymentIntent::CreateParams::Hooks::Inputs::Tax)) }
attr_accessor :tax
sig {
params(tax: T.nilable(::Stripe::PaymentIntent::CreateParams::Hooks::Inputs::Tax)).void
}
def initialize(tax: nil); end
end
# Arguments passed in automations
sig { returns(T.nilable(::Stripe::PaymentIntent::CreateParams::Hooks::Inputs)) }
attr_accessor :inputs
sig { params(inputs: T.nilable(::Stripe::PaymentIntent::CreateParams::Hooks::Inputs)).void }
def initialize(inputs: nil); end
end
class MandateData < Stripe::RequestParams
class CustomerAcceptance < Stripe::RequestParams
class Offline < Stripe::RequestParams; end
class Online < Stripe::RequestParams
# The IP address from which the Mandate was accepted by the customer.
sig { returns(String) }
attr_accessor :ip_address
# The user agent of the browser from which the Mandate was accepted by the customer.
sig { returns(String) }
attr_accessor :user_agent
sig { params(ip_address: String, user_agent: String).void }
def initialize(ip_address: nil, user_agent: nil); end
end
# The time at which the customer accepted the Mandate.
sig { returns(T.nilable(Integer)) }
attr_accessor :accepted_at
# If this is a Mandate accepted offline, this hash contains details about the offline acceptance.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::MandateData::CustomerAcceptance::Offline))
}
attr_accessor :offline
# If this is a Mandate accepted online, this hash contains details about the online acceptance.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::MandateData::CustomerAcceptance::Online))
}
attr_accessor :online
# The type of customer acceptance information included with the Mandate. One of `online` or `offline`.
sig { returns(String) }
attr_accessor :type
sig {
params(accepted_at: T.nilable(Integer), offline: T.nilable(::Stripe::PaymentIntent::CreateParams::MandateData::CustomerAcceptance::Offline), online: T.nilable(::Stripe::PaymentIntent::CreateParams::MandateData::CustomerAcceptance::Online), type: String).void
}
def initialize(accepted_at: nil, offline: nil, online: nil, type: nil); end
end
# This hash contains details about the customer acceptance of the Mandate.
sig { returns(::Stripe::PaymentIntent::CreateParams::MandateData::CustomerAcceptance) }
attr_accessor :customer_acceptance
sig {
params(customer_acceptance: ::Stripe::PaymentIntent::CreateParams::MandateData::CustomerAcceptance).void
}
def initialize(customer_acceptance: nil); end
end
class PaymentDetails < Stripe::RequestParams
class CarRental < Stripe::RequestParams
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::CarRental::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::CarRental::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
class Distance < Stripe::RequestParams
# Distance traveled.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# Unit of measurement for the distance traveled. One of `miles` or `kilometers`.
sig { returns(T.nilable(String)) }
attr_accessor :unit
sig { params(amount: T.nilable(Integer), unit: T.nilable(String)).void }
def initialize(amount: nil, unit: nil); end
end
class Driver < Stripe::RequestParams
# Driver's identification number.
sig { returns(T.nilable(String)) }
attr_accessor :driver_identification_number
# Driver's tax number.
sig { returns(T.nilable(String)) }
attr_accessor :driver_tax_number
# Full name of the person or entity on the car reservation.
sig { returns(String) }
attr_accessor :name
sig {
params(driver_identification_number: T.nilable(String), driver_tax_number: T.nilable(String), name: String).void
}
def initialize(
driver_identification_number: nil,
driver_tax_number: nil,
name: nil
); end
end
class PickupAddress < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class ReturnAddress < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::CarRental::Affiliate))
}
attr_accessor :affiliate
# The booking number associated with the car rental.
sig { returns(String) }
attr_accessor :booking_number
# Class code of the car.
sig { returns(T.nilable(String)) }
attr_accessor :car_class_code
# Make of the car.
sig { returns(T.nilable(String)) }
attr_accessor :car_make
# Model of the car.
sig { returns(T.nilable(String)) }
attr_accessor :car_model
# The name of the rental car company.
sig { returns(T.nilable(String)) }
attr_accessor :company
# The customer service phone number of the car rental company.
sig { returns(T.nilable(String)) }
attr_accessor :customer_service_phone_number
# Number of days the car is being rented.
sig { returns(Integer) }
attr_accessor :days_rented
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::CarRental::Delivery))
}
attr_accessor :delivery
# The details of the distance traveled during the rental period.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::CarRental::Distance))
}
attr_accessor :distance
# The details of the passengers in the travel reservation
sig {
returns(T.nilable(T::Array[::Stripe::PaymentIntent::CreateParams::PaymentDetails::CarRental::Driver]))
}
attr_accessor :drivers
# List of additional charges being billed.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :extra_charges
# Indicates if the customer did not keep nor cancel their booking.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :no_show
# Car pick-up address.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::CarRental::PickupAddress))
}
attr_accessor :pickup_address
# Car pick-up time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :pickup_at
# Name of the pickup location.
sig { returns(T.nilable(String)) }
attr_accessor :pickup_location_name
# Rental rate.
sig { returns(T.nilable(Integer)) }
attr_accessor :rate_amount
# The frequency at which the rate amount is applied. One of `day`, `week` or `month`
sig { returns(T.nilable(String)) }
attr_accessor :rate_interval
# The name of the person or entity renting the car.
sig { returns(T.nilable(String)) }
attr_accessor :renter_name
# Car return address.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::CarRental::ReturnAddress))
}
attr_accessor :return_address
# Car return time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :return_at
# Name of the return location.
sig { returns(T.nilable(String)) }
attr_accessor :return_location_name
# Indicates whether the goods or services are tax-exempt or tax is not collected.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :tax_exempt
# The vehicle identification number.
sig { returns(T.nilable(String)) }
attr_accessor :vehicle_identification_number
sig {
params(affiliate: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::CarRental::Affiliate), booking_number: String, car_class_code: T.nilable(String), car_make: T.nilable(String), car_model: T.nilable(String), company: T.nilable(String), customer_service_phone_number: T.nilable(String), days_rented: Integer, delivery: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::CarRental::Delivery), distance: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::CarRental::Distance), drivers: T.nilable(T::Array[::Stripe::PaymentIntent::CreateParams::PaymentDetails::CarRental::Driver]), extra_charges: T.nilable(T::Array[String]), no_show: T.nilable(T::Boolean), pickup_address: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::CarRental::PickupAddress), pickup_at: Integer, pickup_location_name: T.nilable(String), rate_amount: T.nilable(Integer), rate_interval: T.nilable(String), renter_name: T.nilable(String), return_address: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::CarRental::ReturnAddress), return_at: Integer, return_location_name: T.nilable(String), tax_exempt: T.nilable(T::Boolean), vehicle_identification_number: T.nilable(String)).void
}
def initialize(
affiliate: nil,
booking_number: nil,
car_class_code: nil,
car_make: nil,
car_model: nil,
company: nil,
customer_service_phone_number: nil,
days_rented: nil,
delivery: nil,
distance: nil,
drivers: nil,
extra_charges: nil,
no_show: nil,
pickup_address: nil,
pickup_at: nil,
pickup_location_name: nil,
rate_amount: nil,
rate_interval: nil,
renter_name: nil,
return_address: nil,
return_at: nil,
return_location_name: nil,
tax_exempt: nil,
vehicle_identification_number: nil
); end
end
class EventDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::EventDetails::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::EventDetails::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
# Indicates if the tickets are digitally checked when entering the venue.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :access_controlled_venue
# The event location's address.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::EventDetails::Address))
}
attr_accessor :address
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::EventDetails::Affiliate))
}
attr_accessor :affiliate
# The name of the company
sig { returns(T.nilable(String)) }
attr_accessor :company
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::EventDetails::Delivery))
}
attr_accessor :delivery
# Event end time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :ends_at
# Type of the event entertainment (concert, sports event etc)
sig { returns(T.nilable(String)) }
attr_accessor :genre
# The name of the event.
sig { returns(String) }
attr_accessor :name
# Event start time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :starts_at
sig {
params(access_controlled_venue: T.nilable(T::Boolean), address: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::EventDetails::Address), affiliate: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::EventDetails::Affiliate), company: T.nilable(String), delivery: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::EventDetails::Delivery), ends_at: T.nilable(Integer), genre: T.nilable(String), name: String, starts_at: T.nilable(Integer)).void
}
def initialize(
access_controlled_venue: nil,
address: nil,
affiliate: nil,
company: nil,
delivery: nil,
ends_at: nil,
genre: nil,
name: nil,
starts_at: nil
); end
end
class Flight < Stripe::RequestParams
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::Flight::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::Flight::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
class Passenger < Stripe::RequestParams
# Full name of the person or entity on the flight reservation.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Segment < Stripe::RequestParams
# The flight segment amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# The International Air Transport Association (IATA) airport code for the arrival airport.
sig { returns(T.nilable(String)) }
attr_accessor :arrival_airport
# The arrival time for the flight segment. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :arrives_at
# The International Air Transport Association (IATA) carrier code of the carrier operating the flight segment.
sig { returns(T.nilable(String)) }
attr_accessor :carrier
# The departure time for the flight segment. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :departs_at
# The International Air Transport Association (IATA) airport code for the departure airport.
sig { returns(T.nilable(String)) }
attr_accessor :departure_airport
# The flight number associated with the segment
sig { returns(T.nilable(String)) }
attr_accessor :flight_number
# The fare class for the segment.
sig { returns(T.nilable(String)) }
attr_accessor :service_class
sig {
params(amount: T.nilable(Integer), arrival_airport: T.nilable(String), arrives_at: T.nilable(Integer), carrier: T.nilable(String), departs_at: Integer, departure_airport: T.nilable(String), flight_number: T.nilable(String), service_class: T.nilable(String)).void
}
def initialize(
amount: nil,
arrival_airport: nil,
arrives_at: nil,
carrier: nil,
departs_at: nil,
departure_airport: nil,
flight_number: nil,
service_class: nil
); end
end
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::Flight::Affiliate))
}
attr_accessor :affiliate
# The agency number (i.e. International Air Transport Association (IATA) agency number) of the travel agency that made the booking.
sig { returns(T.nilable(String)) }
attr_accessor :agency_number
# The International Air Transport Association (IATA) carrier code of the carrier that issued the ticket.
sig { returns(T.nilable(String)) }
attr_accessor :carrier
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::Flight::Delivery))
}
attr_accessor :delivery
# The name of the person or entity on the reservation.
sig { returns(T.nilable(String)) }
attr_accessor :passenger_name
# The details of the passengers in the travel reservation.
sig {
returns(T.nilable(T::Array[::Stripe::PaymentIntent::CreateParams::PaymentDetails::Flight::Passenger]))
}
attr_accessor :passengers
# The individual flight segments associated with the trip.
sig {
returns(T::Array[::Stripe::PaymentIntent::CreateParams::PaymentDetails::Flight::Segment])
}
attr_accessor :segments
# The ticket number associated with the travel reservation.
sig { returns(T.nilable(String)) }
attr_accessor :ticket_number
sig {
params(affiliate: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::Flight::Affiliate), agency_number: T.nilable(String), carrier: T.nilable(String), delivery: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::Flight::Delivery), passenger_name: T.nilable(String), passengers: T.nilable(T::Array[::Stripe::PaymentIntent::CreateParams::PaymentDetails::Flight::Passenger]), segments: T::Array[::Stripe::PaymentIntent::CreateParams::PaymentDetails::Flight::Segment], ticket_number: T.nilable(String)).void
}
def initialize(
affiliate: nil,
agency_number: nil,
carrier: nil,
delivery: nil,
passenger_name: nil,
passengers: nil,
segments: nil,
ticket_number: nil
); end
end
class Lodging < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::Lodging::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::Lodging::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
class Passenger < Stripe::RequestParams
# Full name of the person or entity on the lodging reservation.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
# The lodging location's address.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::Lodging::Address))
}
attr_accessor :address
# The number of adults on the booking
sig { returns(T.nilable(Integer)) }
attr_accessor :adults
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::Lodging::Affiliate))
}
attr_accessor :affiliate
# The booking number associated with the lodging reservation.
sig { returns(T.nilable(String)) }
attr_accessor :booking_number
# The lodging category
sig { returns(T.nilable(String)) }
attr_accessor :category
# Lodging check-in time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :checkin_at
# Lodging check-out time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :checkout_at
# The customer service phone number of the lodging company.
sig { returns(T.nilable(String)) }
attr_accessor :customer_service_phone_number
# The daily lodging room rate.
sig { returns(T.nilable(Integer)) }
attr_accessor :daily_room_rate_amount
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::Lodging::Delivery))
}
attr_accessor :delivery
# List of additional charges being billed.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :extra_charges
# Indicates whether the lodging location is compliant with the Fire Safety Act.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :fire_safety_act_compliance
# The name of the lodging location.
sig { returns(T.nilable(String)) }
attr_accessor :name
# Indicates if the customer did not keep their booking while failing to cancel the reservation.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :no_show
# The number of rooms on the booking
sig { returns(T.nilable(Integer)) }
attr_accessor :number_of_rooms
# The details of the passengers in the travel reservation
sig {
returns(T.nilable(T::Array[::Stripe::PaymentIntent::CreateParams::PaymentDetails::Lodging::Passenger]))
}
attr_accessor :passengers
# The phone number of the lodging location.
sig { returns(T.nilable(String)) }
attr_accessor :property_phone_number
# The room class for this purchase.
sig { returns(T.nilable(String)) }
attr_accessor :room_class
# The number of room nights
sig { returns(T.nilable(Integer)) }
attr_accessor :room_nights
# The total tax amount associating with the room reservation.
sig { returns(T.nilable(Integer)) }
attr_accessor :total_room_tax_amount
# The total tax amount
sig { returns(T.nilable(Integer)) }
attr_accessor :total_tax_amount
sig {
params(address: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::Lodging::Address), adults: T.nilable(Integer), affiliate: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::Lodging::Affiliate), booking_number: T.nilable(String), category: T.nilable(String), checkin_at: Integer, checkout_at: Integer, customer_service_phone_number: T.nilable(String), daily_room_rate_amount: T.nilable(Integer), delivery: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::Lodging::Delivery), extra_charges: T.nilable(T::Array[String]), fire_safety_act_compliance: T.nilable(T::Boolean), name: T.nilable(String), no_show: T.nilable(T::Boolean), number_of_rooms: T.nilable(Integer), passengers: T.nilable(T::Array[::Stripe::PaymentIntent::CreateParams::PaymentDetails::Lodging::Passenger]), property_phone_number: T.nilable(String), room_class: T.nilable(String), room_nights: T.nilable(Integer), total_room_tax_amount: T.nilable(Integer), total_tax_amount: T.nilable(Integer)).void
}
def initialize(
address: nil,
adults: nil,
affiliate: nil,
booking_number: nil,
category: nil,
checkin_at: nil,
checkout_at: nil,
customer_service_phone_number: nil,
daily_room_rate_amount: nil,
delivery: nil,
extra_charges: nil,
fire_safety_act_compliance: nil,
name: nil,
no_show: nil,
number_of_rooms: nil,
passengers: nil,
property_phone_number: nil,
room_class: nil,
room_nights: nil,
total_room_tax_amount: nil,
total_tax_amount: nil
); end
end
class Subscription < Stripe::RequestParams
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class BillingInterval < Stripe::RequestParams
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :count
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
sig { params(count: Integer, interval: String).void }
def initialize(count: nil, interval: nil); end
end
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::Subscription::Affiliate))
}
attr_accessor :affiliate
# Info whether the subscription will be auto renewed upon expiry.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :auto_renewal
# Subscription billing details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::Subscription::BillingInterval))
}
attr_accessor :billing_interval
# Subscription end time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :ends_at
# Name of the product on subscription. e.g. Apple Music Subscription
sig { returns(String) }
attr_accessor :name
# Subscription start time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :starts_at
sig {
params(affiliate: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::Subscription::Affiliate), auto_renewal: T.nilable(T::Boolean), billing_interval: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::Subscription::BillingInterval), ends_at: T.nilable(Integer), name: String, starts_at: T.nilable(Integer)).void
}
def initialize(
affiliate: nil,
auto_renewal: nil,
billing_interval: nil,
ends_at: nil,
name: nil,
starts_at: nil
); end
end
# Car rental details for this PaymentIntent.
sig { returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::CarRental)) }
attr_accessor :car_rental
# Some customers might be required by their company or organization to provide this information. If so, provide this value. Otherwise you can ignore this field.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :customer_reference
# Event details for this PaymentIntent
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::EventDetails))
}
attr_accessor :event_details
# Flight reservation details for this PaymentIntent
sig { returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::Flight)) }
attr_accessor :flight
# Lodging reservation details for this PaymentIntent
sig { returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::Lodging)) }
attr_accessor :lodging
# A unique value assigned by the business to identify the transaction.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :order_reference
# Subscription details for this PaymentIntent
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::Subscription))
}
attr_accessor :subscription
sig {
params(car_rental: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::CarRental), customer_reference: T.nilable(T.nilable(String)), event_details: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::EventDetails), flight: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::Flight), lodging: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::Lodging), order_reference: T.nilable(T.nilable(String)), subscription: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails::Subscription)).void
}
def initialize(
car_rental: nil,
customer_reference: nil,
event_details: nil,
flight: nil,
lodging: nil,
order_reference: nil,
subscription: nil
); end
end
class PaymentMethodData < Stripe::RequestParams
class AcssDebit < Stripe::RequestParams
# Customer's bank account number.
sig { returns(String) }
attr_accessor :account_number
# Institution number of the customer's bank.
sig { returns(String) }
attr_accessor :institution_number
# Transit number of the customer's bank.
sig { returns(String) }
attr_accessor :transit_number
sig {
params(account_number: String, institution_number: String, transit_number: String).void
}
def initialize(account_number: nil, institution_number: nil, transit_number: nil); end
end
class Affirm < Stripe::RequestParams; end
class AfterpayClearpay < Stripe::RequestParams; end
class Alipay < Stripe::RequestParams; end
class Alma < Stripe::RequestParams; end
class AmazonPay < Stripe::RequestParams; end
class AuBecsDebit < Stripe::RequestParams
# The account number for the bank account.
sig { returns(String) }
attr_accessor :account_number
# Bank-State-Branch number of the bank account.
sig { returns(String) }
attr_accessor :bsb_number
sig { params(account_number: String, bsb_number: String).void }
def initialize(account_number: nil, bsb_number: nil); end
end
class BacsDebit < Stripe::RequestParams
# Account number of the bank account that the funds will be debited from.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Sort code of the bank account. (e.g., `10-20-30`)
sig { returns(T.nilable(String)) }
attr_accessor :sort_code
sig { params(account_number: T.nilable(String), sort_code: T.nilable(String)).void }
def initialize(account_number: nil, sort_code: nil); end
end
class Bancontact < Stripe::RequestParams; end
class Billie < Stripe::RequestParams; end
class BillingDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Billing address.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodData::BillingDetails::Address))))
}
attr_accessor :address
# Email address.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :email
# Full name.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :name
# Billing phone number (including extension).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :phone
# Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
sig { returns(T.nilable(String)) }
attr_accessor :tax_id
sig {
params(address: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodData::BillingDetails::Address))), email: T.nilable(T.nilable(String)), name: T.nilable(T.nilable(String)), phone: T.nilable(T.nilable(String)), tax_id: T.nilable(String)).void
}
def initialize(address: nil, email: nil, name: nil, phone: nil, tax_id: nil); end
end
class Blik < Stripe::RequestParams; end
class Boleto < Stripe::RequestParams
# The tax ID of the customer (CPF for individual consumers or CNPJ for businesses consumers)
sig { returns(String) }
attr_accessor :tax_id
sig { params(tax_id: String).void }
def initialize(tax_id: nil); end
end
class Cashapp < Stripe::RequestParams; end
class CustomerBalance < Stripe::RequestParams; end
class Eps < Stripe::RequestParams
# The customer's bank.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class Fpx < Stripe::RequestParams
# Account holder type for FPX transaction
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_type
# The customer's bank.
sig { returns(String) }
attr_accessor :bank
sig { params(account_holder_type: T.nilable(String), bank: String).void }
def initialize(account_holder_type: nil, bank: nil); end
end
class Giropay < Stripe::RequestParams; end
class Gopay < Stripe::RequestParams; end
class Grabpay < Stripe::RequestParams; end
class IdBankTransfer < Stripe::RequestParams
# Bank where the account is held.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class Ideal < Stripe::RequestParams
# The customer's bank. Only use this parameter for existing customers. Don't use it for new customers.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class InteracPresent < Stripe::RequestParams; end
class KakaoPay < Stripe::RequestParams; end
class Klarna < Stripe::RequestParams
class Dob < Stripe::RequestParams
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
# Customer's date of birth
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Klarna::Dob))
}
attr_accessor :dob
sig {
params(dob: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Klarna::Dob)).void
}
def initialize(dob: nil); end
end
class Konbini < Stripe::RequestParams; end
class KrCard < Stripe::RequestParams; end
class Link < Stripe::RequestParams; end
class MbWay < Stripe::RequestParams; end
class Mobilepay < Stripe::RequestParams; end
class Multibanco < Stripe::RequestParams; end
class NaverPay < Stripe::RequestParams
# Whether to use Naver Pay points or a card to fund this transaction. If not provided, this defaults to `card`.
sig { returns(T.nilable(String)) }
attr_accessor :funding
sig { params(funding: T.nilable(String)).void }
def initialize(funding: nil); end
end
class NzBankAccount < Stripe::RequestParams
# The name on the bank account. Only required if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod’s billing details.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_name
# The account number for the bank account.
sig { returns(String) }
attr_accessor :account_number
# The numeric code for the bank account's bank.
sig { returns(String) }
attr_accessor :bank_code
# The numeric code for the bank account's bank branch.
sig { returns(String) }
attr_accessor :branch_code
# Attribute for param field reference
sig { returns(T.nilable(String)) }
attr_accessor :reference
# The suffix of the bank account number.
sig { returns(String) }
attr_accessor :suffix
sig {
params(account_holder_name: T.nilable(String), account_number: String, bank_code: String, branch_code: String, reference: T.nilable(String), suffix: String).void
}
def initialize(
account_holder_name: nil,
account_number: nil,
bank_code: nil,
branch_code: nil,
reference: nil,
suffix: nil
); end
end
class Oxxo < Stripe::RequestParams; end
class P24 < Stripe::RequestParams
# The customer's bank.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class PayByBank < Stripe::RequestParams; end
class Payco < Stripe::RequestParams; end
class Paynow < Stripe::RequestParams; end
class Paypal < Stripe::RequestParams; end
class Payto < Stripe::RequestParams
# The account number for the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Bank-State-Branch number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :bsb_number
# The PayID alias for the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :pay_id
sig {
params(account_number: T.nilable(String), bsb_number: T.nilable(String), pay_id: T.nilable(String)).void
}
def initialize(account_number: nil, bsb_number: nil, pay_id: nil); end
end
class Pix < Stripe::RequestParams; end
class Promptpay < Stripe::RequestParams; end
class Qris < Stripe::RequestParams; end
class RadarOptions < Stripe::RequestParams
# A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
sig { returns(T.nilable(String)) }
attr_accessor :session
sig { params(session: T.nilable(String)).void }
def initialize(session: nil); end
end
class Rechnung < Stripe::RequestParams
class Dob < Stripe::RequestParams
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
# Customer's date of birth
sig { returns(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Rechnung::Dob) }
attr_accessor :dob
sig {
params(dob: ::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Rechnung::Dob).void
}
def initialize(dob: nil); end
end
class RevolutPay < Stripe::RequestParams; end
class SamsungPay < Stripe::RequestParams; end
class Satispay < Stripe::RequestParams; end
class SepaDebit < Stripe::RequestParams
# IBAN of the bank account.
sig { returns(String) }
attr_accessor :iban
sig { params(iban: String).void }
def initialize(iban: nil); end
end
class Shopeepay < Stripe::RequestParams; end
class Sofort < Stripe::RequestParams
# Two-letter ISO code representing the country the bank account is located in.
sig { returns(String) }
attr_accessor :country
sig { params(country: String).void }
def initialize(country: nil); end
end
class StripeBalance < Stripe::RequestParams
# The connected account ID whose Stripe balance to use as the source of payment
sig { returns(T.nilable(String)) }
attr_accessor :account
# The [source_type](https://docs.stripe.com/api/balance/balance_object#balance_object-available-source_types) of the balance
sig { returns(T.nilable(String)) }
attr_accessor :source_type
sig { params(account: T.nilable(String), source_type: T.nilable(String)).void }
def initialize(account: nil, source_type: nil); end
end
class Swish < Stripe::RequestParams; end
class Twint < Stripe::RequestParams; end
class UsBankAccount < Stripe::RequestParams
# Account holder type: individual or company.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_type
# Account number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Account type: checkings or savings. Defaults to checking if omitted.
sig { returns(T.nilable(String)) }
attr_accessor :account_type
# The ID of a Financial Connections Account to use as a payment method.
sig { returns(T.nilable(String)) }
attr_accessor :financial_connections_account
# Routing number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :routing_number
sig {
params(account_holder_type: T.nilable(String), account_number: T.nilable(String), account_type: T.nilable(String), financial_connections_account: T.nilable(String), routing_number: T.nilable(String)).void
}
def initialize(
account_holder_type: nil,
account_number: nil,
account_type: nil,
financial_connections_account: nil,
routing_number: nil
); end
end
class WechatPay < Stripe::RequestParams; end
class Zip < Stripe::RequestParams; end
# If this is an `acss_debit` PaymentMethod, this hash contains details about the ACSS Debit payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::AcssDebit))
}
attr_accessor :acss_debit
# If this is an `affirm` PaymentMethod, this hash contains details about the Affirm payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Affirm)) }
attr_accessor :affirm
# If this is an `AfterpayClearpay` PaymentMethod, this hash contains details about the AfterpayClearpay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::AfterpayClearpay))
}
attr_accessor :afterpay_clearpay
# If this is an `Alipay` PaymentMethod, this hash contains details about the Alipay payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Alipay)) }
attr_accessor :alipay
# This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :allow_redisplay
# If this is a Alma PaymentMethod, this hash contains details about the Alma payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Alma)) }
attr_accessor :alma
# If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::AmazonPay))
}
attr_accessor :amazon_pay
# If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::AuBecsDebit))
}
attr_accessor :au_becs_debit
# If this is a `bacs_debit` PaymentMethod, this hash contains details about the Bacs Direct Debit bank account.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::BacsDebit))
}
attr_accessor :bacs_debit
# If this is a `bancontact` PaymentMethod, this hash contains details about the Bancontact payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Bancontact))
}
attr_accessor :bancontact
# If this is a `billie` PaymentMethod, this hash contains details about the Billie payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Billie)) }
attr_accessor :billie
# Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::BillingDetails))
}
attr_accessor :billing_details
# If this is a `blik` PaymentMethod, this hash contains details about the BLIK payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Blik)) }
attr_accessor :blik
# If this is a `boleto` PaymentMethod, this hash contains details about the Boleto payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Boleto)) }
attr_accessor :boleto
# If this is a `cashapp` PaymentMethod, this hash contains details about the Cash App Pay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Cashapp))
}
attr_accessor :cashapp
# If this is a `customer_balance` PaymentMethod, this hash contains details about the CustomerBalance payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::CustomerBalance))
}
attr_accessor :customer_balance
# If this is an `eps` PaymentMethod, this hash contains details about the EPS payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Eps)) }
attr_accessor :eps
# If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Fpx)) }
attr_accessor :fpx
# If this is a `giropay` PaymentMethod, this hash contains details about the Giropay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Giropay))
}
attr_accessor :giropay
# If this is a Gopay PaymentMethod, this hash contains details about the Gopay payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Gopay)) }
attr_accessor :gopay
# If this is a `grabpay` PaymentMethod, this hash contains details about the GrabPay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Grabpay))
}
attr_accessor :grabpay
# If this is an `IdBankTransfer` PaymentMethod, this hash contains details about the IdBankTransfer payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::IdBankTransfer))
}
attr_accessor :id_bank_transfer
# If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Ideal)) }
attr_accessor :ideal
# If this is an `interac_present` PaymentMethod, this hash contains details about the Interac Present payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::InteracPresent))
}
attr_accessor :interac_present
# If this is a `kakao_pay` PaymentMethod, this hash contains details about the Kakao Pay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::KakaoPay))
}
attr_accessor :kakao_pay
# If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Klarna)) }
attr_accessor :klarna
# If this is a `konbini` PaymentMethod, this hash contains details about the Konbini payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Konbini))
}
attr_accessor :konbini
# If this is a `kr_card` PaymentMethod, this hash contains details about the Korean Card payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::KrCard)) }
attr_accessor :kr_card
# If this is an `Link` PaymentMethod, this hash contains details about the Link payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Link)) }
attr_accessor :link
# If this is a MB WAY PaymentMethod, this hash contains details about the MB WAY payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::MbWay)) }
attr_accessor :mb_way
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# If this is a `mobilepay` PaymentMethod, this hash contains details about the MobilePay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Mobilepay))
}
attr_accessor :mobilepay
# If this is a `multibanco` PaymentMethod, this hash contains details about the Multibanco payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Multibanco))
}
attr_accessor :multibanco
# If this is a `naver_pay` PaymentMethod, this hash contains details about the Naver Pay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::NaverPay))
}
attr_accessor :naver_pay
# If this is an nz_bank_account PaymentMethod, this hash contains details about the nz_bank_account payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::NzBankAccount))
}
attr_accessor :nz_bank_account
# If this is an `oxxo` PaymentMethod, this hash contains details about the OXXO payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Oxxo)) }
attr_accessor :oxxo
# If this is a `p24` PaymentMethod, this hash contains details about the P24 payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::P24)) }
attr_accessor :p24
# If this is a `pay_by_bank` PaymentMethod, this hash contains details about the PayByBank payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::PayByBank))
}
attr_accessor :pay_by_bank
# If this is a `payco` PaymentMethod, this hash contains details about the PAYCO payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Payco)) }
attr_accessor :payco
# If this is a `paynow` PaymentMethod, this hash contains details about the PayNow payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Paynow)) }
attr_accessor :paynow
# If this is a `paypal` PaymentMethod, this hash contains details about the PayPal payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Paypal)) }
attr_accessor :paypal
# If this is a `payto` PaymentMethod, this hash contains details about the PayTo payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Payto)) }
attr_accessor :payto
# If this is a `pix` PaymentMethod, this hash contains details about the Pix payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Pix)) }
attr_accessor :pix
# If this is a `promptpay` PaymentMethod, this hash contains details about the PromptPay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Promptpay))
}
attr_accessor :promptpay
# If this is a `qris` PaymentMethod, this hash contains details about the QRIS payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Qris)) }
attr_accessor :qris
# Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::RadarOptions))
}
attr_accessor :radar_options
# If this is a `rechnung` PaymentMethod, this hash contains details about the Rechnung payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Rechnung))
}
attr_accessor :rechnung
# If this is a `revolut_pay` PaymentMethod, this hash contains details about the Revolut Pay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::RevolutPay))
}
attr_accessor :revolut_pay
# If this is a `samsung_pay` PaymentMethod, this hash contains details about the SamsungPay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::SamsungPay))
}
attr_accessor :samsung_pay
# If this is a `satispay` PaymentMethod, this hash contains details about the Satispay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Satispay))
}
attr_accessor :satispay
# If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::SepaDebit))
}
attr_accessor :sepa_debit
# If this is a Shopeepay PaymentMethod, this hash contains details about the Shopeepay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Shopeepay))
}
attr_accessor :shopeepay
# If this is a `sofort` PaymentMethod, this hash contains details about the SOFORT payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Sofort)) }
attr_accessor :sofort
# This hash contains details about the Stripe balance payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::StripeBalance))
}
attr_accessor :stripe_balance
# If this is a `swish` PaymentMethod, this hash contains details about the Swish payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Swish)) }
attr_accessor :swish
# If this is a TWINT PaymentMethod, this hash contains details about the TWINT payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Twint)) }
attr_accessor :twint
# The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
sig { returns(String) }
attr_accessor :type
# If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::UsBankAccount))
}
attr_accessor :us_bank_account
# If this is an `wechat_pay` PaymentMethod, this hash contains details about the wechat_pay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::WechatPay))
}
attr_accessor :wechat_pay
# If this is a `zip` PaymentMethod, this hash contains details about the Zip payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Zip)) }
attr_accessor :zip
sig {
params(acss_debit: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::AcssDebit), affirm: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Affirm), afterpay_clearpay: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::AfterpayClearpay), alipay: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Alipay), allow_redisplay: T.nilable(String), alma: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Alma), amazon_pay: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::AmazonPay), au_becs_debit: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::AuBecsDebit), bacs_debit: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::BacsDebit), bancontact: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Bancontact), billie: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Billie), billing_details: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::BillingDetails), blik: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Blik), boleto: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Boleto), cashapp: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Cashapp), customer_balance: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::CustomerBalance), eps: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Eps), fpx: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Fpx), giropay: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Giropay), gopay: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Gopay), grabpay: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Grabpay), id_bank_transfer: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::IdBankTransfer), ideal: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Ideal), interac_present: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::InteracPresent), kakao_pay: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::KakaoPay), klarna: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Klarna), konbini: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Konbini), kr_card: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::KrCard), link: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Link), mb_way: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::MbWay), metadata: T.nilable(T::Hash[String, String]), mobilepay: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Mobilepay), multibanco: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Multibanco), naver_pay: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::NaverPay), nz_bank_account: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::NzBankAccount), oxxo: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Oxxo), p24: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::P24), pay_by_bank: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::PayByBank), payco: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Payco), paynow: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Paynow), paypal: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Paypal), payto: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Payto), pix: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Pix), promptpay: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Promptpay), qris: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Qris), radar_options: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::RadarOptions), rechnung: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Rechnung), revolut_pay: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::RevolutPay), samsung_pay: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::SamsungPay), satispay: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Satispay), sepa_debit: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::SepaDebit), shopeepay: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Shopeepay), sofort: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Sofort), stripe_balance: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::StripeBalance), swish: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Swish), twint: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Twint), type: String, us_bank_account: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::UsBankAccount), wechat_pay: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::WechatPay), zip: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData::Zip)).void
}
def initialize(
acss_debit: nil,
affirm: nil,
afterpay_clearpay: nil,
alipay: nil,
allow_redisplay: nil,
alma: nil,
amazon_pay: nil,
au_becs_debit: nil,
bacs_debit: nil,
bancontact: nil,
billie: nil,
billing_details: nil,
blik: nil,
boleto: nil,
cashapp: nil,
customer_balance: nil,
eps: nil,
fpx: nil,
giropay: nil,
gopay: nil,
grabpay: nil,
id_bank_transfer: nil,
ideal: nil,
interac_present: nil,
kakao_pay: nil,
klarna: nil,
konbini: nil,
kr_card: nil,
link: nil,
mb_way: nil,
metadata: nil,
mobilepay: nil,
multibanco: nil,
naver_pay: nil,
nz_bank_account: nil,
oxxo: nil,
p24: nil,
pay_by_bank: nil,
payco: nil,
paynow: nil,
paypal: nil,
payto: nil,
pix: nil,
promptpay: nil,
qris: nil,
radar_options: nil,
rechnung: nil,
revolut_pay: nil,
samsung_pay: nil,
satispay: nil,
sepa_debit: nil,
shopeepay: nil,
sofort: nil,
stripe_balance: nil,
swish: nil,
twint: nil,
type: nil,
us_bank_account: nil,
wechat_pay: nil,
zip: nil
); end
end
class PaymentMethodOptions < Stripe::RequestParams
class AcssDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# A URL for custom mandate text to render during confirmation step.
# The URL will be rendered with additional GET parameters `payment_intent` and `payment_intent_client_secret` when confirming a Payment Intent,
# or `setup_intent` and `setup_intent_client_secret` when confirming a Setup Intent.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :custom_mandate_url
# Description of the mandate interval. Only required if 'payment_schedule' parameter is 'interval' or 'combined'.
sig { returns(T.nilable(String)) }
attr_accessor :interval_description
# Payment schedule for the mandate.
sig { returns(T.nilable(String)) }
attr_accessor :payment_schedule
# Transaction type of the mandate.
sig { returns(T.nilable(String)) }
attr_accessor :transaction_type
sig {
params(custom_mandate_url: T.nilable(T.nilable(String)), interval_description: T.nilable(String), payment_schedule: T.nilable(String), transaction_type: T.nilable(String)).void
}
def initialize(
custom_mandate_url: nil,
interval_description: nil,
payment_schedule: nil,
transaction_type: nil
); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::AcssDebit::MandateOptions))
}
attr_accessor :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
# Bank account verification method.
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(mandate_options: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::AcssDebit::MandateOptions), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), target_date: T.nilable(String), verification_method: T.nilable(String)).void
}
def initialize(
mandate_options: nil,
setup_future_usage: nil,
target_date: nil,
verification_method: nil
); end
end
class Affirm < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Preferred language of the Affirm authorization page that the customer is redirected to.
sig { returns(T.nilable(String)) }
attr_accessor :preferred_locale
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), preferred_locale: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(capture_method: nil, preferred_locale: nil, setup_future_usage: nil); end
end
class AfterpayClearpay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# An internal identifier or reference that this payment corresponds to. You must limit the identifier to 128 characters, and it can only contain letters, numbers, underscores, backslashes, and dashes.
# This field differs from the statement descriptor and item name.
sig { returns(T.nilable(String)) }
attr_accessor :reference
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), reference: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(capture_method: nil, reference: nil, setup_future_usage: nil); end
end
class Alipay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void }
def initialize(setup_future_usage: nil); end
end
class Alma < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
sig { params(capture_method: T.nilable(T.nilable(String))).void }
def initialize(capture_method: nil); end
end
class AmazonPay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class AuBecsDebit < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
sig {
params(setup_future_usage: T.nilable(T.nilable(T.any(String, String))), target_date: T.nilable(String)).void
}
def initialize(setup_future_usage: nil, target_date: nil); end
end
class BacsDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'DDIC' or 'STRIPE'.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :reference_prefix
sig { params(reference_prefix: T.nilable(T.nilable(String))).void }
def initialize(reference_prefix: nil); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::BacsDebit::MandateOptions))
}
attr_accessor :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
sig {
params(mandate_options: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::BacsDebit::MandateOptions), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), target_date: T.nilable(String)).void
}
def initialize(mandate_options: nil, setup_future_usage: nil, target_date: nil); end
end
class Bancontact < Stripe::RequestParams
# Preferred language of the Bancontact authorization page that the customer is redirected to.
sig { returns(T.nilable(String)) }
attr_accessor :preferred_language
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(preferred_language: T.nilable(String), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(preferred_language: nil, setup_future_usage: nil); end
end
class Billie < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
sig { params(capture_method: T.nilable(T.nilable(String))).void }
def initialize(capture_method: nil); end
end
class Blik < Stripe::RequestParams
# The 6-digit BLIK code that a customer has generated using their banking application. Can only be set on confirmation.
sig { returns(T.nilable(String)) }
attr_accessor :code
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :setup_future_usage
sig {
params(code: T.nilable(String), setup_future_usage: T.nilable(T.nilable(String))).void
}
def initialize(code: nil, setup_future_usage: nil); end
end
class Boleto < Stripe::RequestParams
# The number of calendar days before a Boleto voucher expires. For example, if you create a Boleto voucher on Monday and you set expires_after_days to 2, the Boleto invoice will expire on Wednesday at 23:59 America/Sao_Paulo time.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_after_days
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(expires_after_days: T.nilable(Integer), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(expires_after_days: nil, setup_future_usage: nil); end
end
class Card < Stripe::RequestParams
class Installments < Stripe::RequestParams
class Plan < Stripe::RequestParams
# For `fixed_count` installment plans, this is required. It represents the number of installment payments your customer will make to their credit card.
sig { returns(T.nilable(Integer)) }
attr_accessor :count
# For `fixed_count` installment plans, this is required. It represents the interval between installment payments your customer will make to their credit card.
# One of `month`.
sig { returns(T.nilable(String)) }
attr_accessor :interval
# Type of installment plan, one of `fixed_count`.
sig { returns(String) }
attr_accessor :type
sig {
params(count: T.nilable(Integer), interval: T.nilable(String), type: String).void
}
def initialize(count: nil, interval: nil, type: nil); end
end
# Setting to true enables installments for this PaymentIntent.
# This will cause the response to contain a list of available installment plans.
# Setting to false will prevent any selected plan from applying to a charge.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :enabled
# The selected installment plan to use for this payment attempt.
# This parameter can only be provided during confirmation.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Card::Installments::Plan))))
}
attr_accessor :plan
sig {
params(enabled: T.nilable(T::Boolean), plan: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Card::Installments::Plan)))).void
}
def initialize(enabled: nil, plan: nil); end
end
class MandateOptions < Stripe::RequestParams
# Amount to be charged for future payments.
sig { returns(Integer) }
attr_accessor :amount
# One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.
sig { returns(String) }
attr_accessor :amount_type
# A description of the mandate or subscription that is meant to be displayed to the customer.
sig { returns(T.nilable(String)) }
attr_accessor :description
# End date of the mandate or subscription. If not provided, the mandate will be active until canceled. If provided, end date should be after start date.
sig { returns(T.nilable(Integer)) }
attr_accessor :end_date
# Specifies payment frequency. One of `day`, `week`, `month`, `year`, or `sporadic`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals between payments. For example, `interval=month` and `interval_count=3` indicates one payment every three months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks). This parameter is optional when `interval=sporadic`.
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_count
# Unique identifier for the mandate or subscription.
sig { returns(String) }
attr_accessor :reference
# Start date of the mandate or subscription. Start date should not be lesser than yesterday.
sig { returns(Integer) }
attr_accessor :start_date
# Specifies the type of mandates supported. Possible values are `india`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :supported_types
sig {
params(amount: Integer, amount_type: String, description: T.nilable(String), end_date: T.nilable(Integer), interval: String, interval_count: T.nilable(Integer), reference: String, start_date: Integer, supported_types: T.nilable(T::Array[String])).void
}
def initialize(
amount: nil,
amount_type: nil,
description: nil,
end_date: nil,
interval: nil,
interval_count: nil,
reference: nil,
start_date: nil,
supported_types: nil
); end
end
class StatementDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Please pass in an address that is within your Stripe user account country
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Card::StatementDetails::Address))
}
attr_accessor :address
# Phone number (e.g., a toll-free number that customers can call)
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(address: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Card::StatementDetails::Address), phone: T.nilable(String)).void
}
def initialize(address: nil, phone: nil); end
end
class ThreeDSecure < Stripe::RequestParams
class NetworkOptions < Stripe::RequestParams
class CartesBancaires < Stripe::RequestParams
# The cryptogram calculation algorithm used by the card Issuer's ACS
# to calculate the Authentication cryptogram. Also known as `cavvAlgorithm`.
# messageExtension: CB-AVALGO
sig { returns(String) }
attr_accessor :cb_avalgo
# The exemption indicator returned from Cartes Bancaires in the ARes.
# message extension: CB-EXEMPTION; string (4 characters)
# This is a 3 byte bitmap (low significant byte first and most significant
# bit first) that has been Base64 encoded
sig { returns(T.nilable(String)) }
attr_accessor :cb_exemption
# The risk score returned from Cartes Bancaires in the ARes.
# message extension: CB-SCORE; numeric value 0-99
sig { returns(T.nilable(Integer)) }
attr_accessor :cb_score
sig {
params(cb_avalgo: String, cb_exemption: T.nilable(String), cb_score: T.nilable(Integer)).void
}
def initialize(cb_avalgo: nil, cb_exemption: nil, cb_score: nil); end
end
# Cartes Bancaires-specific 3DS fields.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions::CartesBancaires))
}
attr_accessor :cartes_bancaires
sig {
params(cartes_bancaires: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions::CartesBancaires)).void
}
def initialize(cartes_bancaires: nil); end
end
# The `transStatus` returned from the card Issuer’s ACS in the ARes.
sig { returns(T.nilable(String)) }
attr_accessor :ares_trans_status
# The cryptogram, also known as the "authentication value" (AAV, CAVV or
# AEVV). This value is 20 bytes, base64-encoded into a 28-character string.
# (Most 3D Secure providers will return the base64-encoded version, which
# is what you should specify here.)
sig { returns(String) }
attr_accessor :cryptogram
# The Electronic Commerce Indicator (ECI) is returned by your 3D Secure
# provider and indicates what degree of authentication was performed.
sig { returns(T.nilable(String)) }
attr_accessor :electronic_commerce_indicator
# The exemption requested via 3DS and accepted by the issuer at authentication time.
sig { returns(T.nilable(String)) }
attr_accessor :exemption_indicator
# Network specific 3DS fields. Network specific arguments require an
# explicit card brand choice. The parameter `payment_method_options.card.network``
# must be populated accordingly
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions))
}
attr_accessor :network_options
# The challenge indicator (`threeDSRequestorChallengeInd`) which was requested in the
# AReq sent to the card Issuer's ACS. A string containing 2 digits from 01-99.
sig { returns(T.nilable(String)) }
attr_accessor :requestor_challenge_indicator
# For 3D Secure 1, the XID. For 3D Secure 2, the Directory Server
# Transaction ID (dsTransID).
sig { returns(String) }
attr_accessor :transaction_id
# The version of 3D Secure that was performed.
sig { returns(String) }
attr_accessor :version
sig {
params(ares_trans_status: T.nilable(String), cryptogram: String, electronic_commerce_indicator: T.nilable(String), exemption_indicator: T.nilable(String), network_options: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions), requestor_challenge_indicator: T.nilable(String), transaction_id: String, version: String).void
}
def initialize(
ares_trans_status: nil,
cryptogram: nil,
electronic_commerce_indicator: nil,
exemption_indicator: nil,
network_options: nil,
requestor_challenge_indicator: nil,
transaction_id: nil,
version: nil
); end
end
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# A single-use `cvc_update` Token that represents a card CVC value. When provided, the CVC value will be verified during the card payment attempt. This parameter can only be provided during confirmation.
sig { returns(T.nilable(String)) }
attr_accessor :cvc_token
# Installment configuration for payments attempted on this PaymentIntent (Mexico Only).
#
# For more information, see the [installments integration guide](https://stripe.com/docs/payments/installments).
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Card::Installments))
}
attr_accessor :installments
# Configuration options for setting up an eMandate for cards issued in India.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Card::MandateOptions))
}
attr_accessor :mandate_options
# When specified, this parameter indicates that a transaction will be marked
# as MOTO (Mail Order Telephone Order) and thus out of scope for SCA. This
# parameter can only be provided during confirmation.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :moto
# Selected network to process this PaymentIntent on. Depends on the available networks of the card attached to the PaymentIntent. Can be only set confirm-time.
sig { returns(T.nilable(String)) }
attr_accessor :network
# Request ability to [decrement the authorization](https://stripe.com/docs/payments/decremental-authorization) for this PaymentIntent.
sig { returns(T.nilable(String)) }
attr_accessor :request_decremental_authorization
# Request ability to [capture beyond the standard authorization validity window](https://stripe.com/docs/payments/extended-authorization) for this PaymentIntent.
sig { returns(T.nilable(String)) }
attr_accessor :request_extended_authorization
# Request ability to [increment the authorization](https://stripe.com/docs/payments/incremental-authorization) for this PaymentIntent.
sig { returns(T.nilable(String)) }
attr_accessor :request_incremental_authorization
# Request ability to make [multiple captures](https://stripe.com/docs/payments/multicapture) for this PaymentIntent.
sig { returns(T.nilable(String)) }
attr_accessor :request_multicapture
# Request ability to [overcapture](https://stripe.com/docs/payments/overcapture) for this PaymentIntent.
sig { returns(T.nilable(String)) }
attr_accessor :request_overcapture
# Request partial authorization on this PaymentIntent.
sig { returns(T.nilable(String)) }
attr_accessor :request_partial_authorization
# We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. If not provided, this value defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
sig { returns(T.nilable(String)) }
attr_accessor :request_three_d_secure
# When enabled, using a card that is attached to a customer will require the CVC to be provided again (i.e. using the cvc_token parameter).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :require_cvc_recollection
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Provides information about a card payment that customers see on their statements. Concatenated with the Kana prefix (shortened Kana descriptor) or Kana statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 22 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 22 characters.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :statement_descriptor_suffix_kana
# Provides information about a card payment that customers see on their statements. Concatenated with the Kanji prefix (shortened Kanji descriptor) or Kanji statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 17 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 17 characters.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :statement_descriptor_suffix_kanji
# Statement details for this payment intent. You can use this to override the merchant details shown on your customers' statements.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Card::StatementDetails))))
}
attr_accessor :statement_details
# If 3D Secure authentication was performed with a third-party provider,
# the authentication details to use for this payment.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Card::ThreeDSecure))
}
attr_accessor :three_d_secure
sig {
params(capture_method: T.nilable(T.nilable(String)), cvc_token: T.nilable(String), installments: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Card::Installments), mandate_options: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Card::MandateOptions), moto: T.nilable(T::Boolean), network: T.nilable(String), request_decremental_authorization: T.nilable(String), request_extended_authorization: T.nilable(String), request_incremental_authorization: T.nilable(String), request_multicapture: T.nilable(String), request_overcapture: T.nilable(String), request_partial_authorization: T.nilable(String), request_three_d_secure: T.nilable(String), require_cvc_recollection: T.nilable(T::Boolean), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), statement_descriptor_suffix_kana: T.nilable(T.nilable(String)), statement_descriptor_suffix_kanji: T.nilable(T.nilable(String)), statement_details: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Card::StatementDetails))), three_d_secure: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Card::ThreeDSecure)).void
}
def initialize(
capture_method: nil,
cvc_token: nil,
installments: nil,
mandate_options: nil,
moto: nil,
network: nil,
request_decremental_authorization: nil,
request_extended_authorization: nil,
request_incremental_authorization: nil,
request_multicapture: nil,
request_overcapture: nil,
request_partial_authorization: nil,
request_three_d_secure: nil,
require_cvc_recollection: nil,
setup_future_usage: nil,
statement_descriptor_suffix_kana: nil,
statement_descriptor_suffix_kanji: nil,
statement_details: nil,
three_d_secure: nil
); end
end
class CardPresent < Stripe::RequestParams
class Routing < Stripe::RequestParams
# Routing requested priority
sig { returns(T.nilable(String)) }
attr_accessor :requested_priority
sig { params(requested_priority: T.nilable(String)).void }
def initialize(requested_priority: nil); end
end
# Request ability to capture this payment beyond the standard [authorization validity window](https://stripe.com/docs/terminal/features/extended-authorizations#authorization-validity)
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :request_extended_authorization
# Request ability to [increment](https://stripe.com/docs/terminal/features/incremental-authorizations) this PaymentIntent if the combination of MCC and card brand is eligible. Check [incremental_authorization_supported](https://stripe.com/docs/api/charges/object#charge_object-payment_method_details-card_present-incremental_authorization_supported) in the [Confirm](https://stripe.com/docs/api/payment_intents/confirm) response to verify support.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :request_incremental_authorization_support
# Network routing priority on co-branded EMV cards supporting domestic debit and international card schemes.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::CardPresent::Routing))
}
attr_accessor :routing
sig {
params(request_extended_authorization: T.nilable(T::Boolean), request_incremental_authorization_support: T.nilable(T::Boolean), routing: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::CardPresent::Routing)).void
}
def initialize(
request_extended_authorization: nil,
request_incremental_authorization_support: nil,
routing: nil
); end
end
class Cashapp < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class CustomerBalance < Stripe::RequestParams
class BankTransfer < Stripe::RequestParams
class EuBankTransfer < Stripe::RequestParams
# The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
sig { returns(String) }
attr_accessor :country
sig { params(country: String).void }
def initialize(country: nil); end
end
# Configuration for the eu_bank_transfer funding type.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::CustomerBalance::BankTransfer::EuBankTransfer))
}
attr_accessor :eu_bank_transfer
# List of address types that should be returned in the financial_addresses response. If not specified, all valid types will be returned.
#
# Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :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`, `mx_bank_transfer`, or `us_bank_transfer`.
sig { returns(String) }
attr_accessor :type
sig {
params(eu_bank_transfer: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::CustomerBalance::BankTransfer::EuBankTransfer), requested_address_types: T.nilable(T::Array[String]), type: String).void
}
def initialize(eu_bank_transfer: nil, requested_address_types: nil, type: nil); end
end
# Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::CustomerBalance::BankTransfer))
}
attr_accessor :bank_transfer
# The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
sig { returns(T.nilable(String)) }
attr_accessor :funding_type
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(bank_transfer: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::CustomerBalance::BankTransfer), funding_type: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(bank_transfer: nil, funding_type: nil, setup_future_usage: nil); end
end
class Eps < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Fpx < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Giropay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Gopay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Grabpay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class IdBankTransfer < Stripe::RequestParams
# The UNIX timestamp until which the virtual bank account is valid. Permitted range is from 5 minutes from now until 31 days from now. If unset, it defaults to 3 days from now.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_after
# The UNIX timestamp until which the virtual bank account is valid. Permitted range is from now until 30 days from now. If unset, it defaults to 1 days from now.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_at
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(expires_after: T.nilable(Integer), expires_at: T.nilable(Integer), setup_future_usage: T.nilable(String)).void
}
def initialize(expires_after: nil, expires_at: nil, setup_future_usage: nil); end
end
class Ideal < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void }
def initialize(setup_future_usage: nil); end
end
class InteracPresent < Stripe::RequestParams; end
class KakaoPay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class Klarna < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Preferred language of the Klarna authorization page that the customer is redirected to
sig { returns(T.nilable(String)) }
attr_accessor :preferred_locale
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), preferred_locale: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(capture_method: nil, preferred_locale: nil, setup_future_usage: nil); end
end
class Konbini < Stripe::RequestParams
# An optional 10 to 11 digit numeric-only string determining the confirmation code at applicable convenience stores. Must not consist of only zeroes and could be rejected in case of insufficient uniqueness. We recommend to use the customer's phone number.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :confirmation_number
# The number of calendar days (between 1 and 60) after which Konbini payment instructions will expire. For example, if a PaymentIntent is confirmed with Konbini and `expires_after_days` set to 2 on Monday JST, the instructions will expire on Wednesday 23:59:59 JST. Defaults to 3 days.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :expires_after_days
# The timestamp at which the Konbini payment instructions will expire. Only one of `expires_after_days` or `expires_at` may be set.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :expires_at
# A product descriptor of up to 22 characters, which will appear to customers at the convenience store.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :product_description
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(confirmation_number: T.nilable(T.nilable(String)), expires_after_days: T.nilable(T.nilable(T.any(String, Integer))), expires_at: T.nilable(T.nilable(T.any(String, Integer))), product_description: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(String)).void
}
def initialize(
confirmation_number: nil,
expires_after_days: nil,
expires_at: nil,
product_description: nil,
setup_future_usage: nil
); end
end
class KrCard < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class Link < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# [Deprecated] This is a legacy parameter that no longer has any function.
sig { returns(T.nilable(String)) }
attr_accessor :persistent_token
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), persistent_token: T.nilable(String), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(capture_method: nil, persistent_token: nil, setup_future_usage: nil); end
end
class MbWay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Mobilepay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(String)).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class Multibanco < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class NaverPay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class NzBankAccount < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
sig {
params(setup_future_usage: T.nilable(T.nilable(T.any(String, String))), target_date: T.nilable(String)).void
}
def initialize(setup_future_usage: nil, target_date: nil); end
end
class Oxxo < Stripe::RequestParams
# The number of calendar days before an OXXO voucher expires. For example, if you create an OXXO voucher on Monday and you set expires_after_days to 2, the OXXO invoice will expire on Wednesday at 23:59 America/Mexico_City time.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_after_days
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(expires_after_days: T.nilable(Integer), setup_future_usage: T.nilable(String)).void
}
def initialize(expires_after_days: nil, setup_future_usage: nil); end
end
class P24 < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
# Confirm that the payer has accepted the P24 terms and conditions.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :tos_shown_and_accepted
sig {
params(setup_future_usage: T.nilable(String), tos_shown_and_accepted: T.nilable(T::Boolean)).void
}
def initialize(setup_future_usage: nil, tos_shown_and_accepted: nil); end
end
class PayByBank < Stripe::RequestParams; end
class Payco < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
sig { params(capture_method: T.nilable(T.nilable(String))).void }
def initialize(capture_method: nil); end
end
class Paynow < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Paypal < Stripe::RequestParams
class LineItem < Stripe::RequestParams
class Tax < Stripe::RequestParams
# The tax for a single unit of the line item in minor units. Cannot be a negative number.
sig { returns(Integer) }
attr_accessor :amount
# The tax behavior for the line item.
sig { returns(String) }
attr_accessor :behavior
sig { params(amount: Integer, behavior: String).void }
def initialize(amount: nil, behavior: nil); end
end
# Type of the line item.
sig { returns(T.nilable(String)) }
attr_accessor :category
# Description of the line item.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Descriptive name of the line item.
sig { returns(String) }
attr_accessor :name
# Quantity of the line item. Must be a positive number.
sig { returns(Integer) }
attr_accessor :quantity
# Client facing stock keeping unit, article number or similar.
sig { returns(T.nilable(String)) }
attr_accessor :sku
# The Stripe account ID of the connected account that sells the item.
sig { returns(T.nilable(String)) }
attr_accessor :sold_by
# The tax information for the line item.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Paypal::LineItem::Tax))
}
attr_accessor :tax
# Price for a single unit of the line item in minor units. Cannot be a negative number.
sig { returns(Integer) }
attr_accessor :unit_amount
sig {
params(category: T.nilable(String), description: T.nilable(String), name: String, quantity: Integer, sku: T.nilable(String), sold_by: T.nilable(String), tax: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Paypal::LineItem::Tax), unit_amount: Integer).void
}
def initialize(
category: nil,
description: nil,
name: nil,
quantity: nil,
sku: nil,
sold_by: nil,
tax: nil,
unit_amount: nil
); end
end
# Controls when the funds will be captured from the customer's account.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# The line items purchased by the customer.
sig {
returns(T.nilable(T::Array[::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Paypal::LineItem]))
}
attr_accessor :line_items
# [Preferred locale](https://stripe.com/docs/payments/paypal/supported-locales) of the PayPal checkout page that the customer is redirected to.
sig { returns(T.nilable(String)) }
attr_accessor :preferred_locale
# A reference of the PayPal transaction visible to customer which is mapped to PayPal's invoice ID. This must be a globally unique ID if you have configured in your PayPal settings to block multiple payments per invoice ID.
sig { returns(T.nilable(String)) }
attr_accessor :reference
# A reference of the PayPal transaction visible to customer which is mapped to PayPal's invoice ID. This must be a globally unique ID if you have configured in your PayPal settings to block multiple payments per invoice ID.
sig { returns(T.nilable(String)) }
attr_accessor :reference_id
# The risk correlation ID for an on-session payment using a saved PayPal payment method.
sig { returns(T.nilable(String)) }
attr_accessor :risk_correlation_id
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# The Stripe connected account IDs of the sellers on the platform for this transaction (optional). Only allowed when [separate charges and transfers](https://stripe.com/docs/connect/separate-charges-and-transfers) are used.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :subsellers
sig {
params(capture_method: T.nilable(T.nilable(String)), line_items: T.nilable(T::Array[::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Paypal::LineItem]), preferred_locale: T.nilable(String), reference: T.nilable(String), reference_id: T.nilable(String), risk_correlation_id: T.nilable(String), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), subsellers: T.nilable(T::Array[String])).void
}
def initialize(
capture_method: nil,
line_items: nil,
preferred_locale: nil,
reference: nil,
reference_id: nil,
risk_correlation_id: nil,
setup_future_usage: nil,
subsellers: nil
); end
end
class Payto < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Amount that will be collected. It is required when `amount_type` is `fixed`.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# The type of amount that will be collected. The amount charged must be exact or up to the value of `amount` param for `fixed` or `maximum` type respectively.
sig { returns(T.nilable(String)) }
attr_accessor :amount_type
# Date, in YYYY-MM-DD format, after which payments will not be collected. Defaults to no end date.
sig { returns(T.nilable(String)) }
attr_accessor :end_date
# The periodicity at which payments will be collected.
sig { returns(T.nilable(String)) }
attr_accessor :payment_schedule
# The number of payments that will be made during a payment period. Defaults to 1 except for when `payment_schedule` is `adhoc`. In that case, it defaults to no limit.
sig { returns(T.nilable(Integer)) }
attr_accessor :payments_per_period
# The purpose for which payments are made. Defaults to retail.
sig { returns(T.nilable(String)) }
attr_accessor :purpose
sig {
params(amount: T.nilable(Integer), amount_type: T.nilable(String), end_date: T.nilable(String), payment_schedule: T.nilable(String), payments_per_period: T.nilable(Integer), purpose: T.nilable(String)).void
}
def initialize(
amount: nil,
amount_type: nil,
end_date: nil,
payment_schedule: nil,
payments_per_period: nil,
purpose: nil
); end
end
# Additional fields for Mandate creation. Only `purpose` field is configurable for PayTo PaymentIntent with `setup_future_usage=none`. Other fields are only applicable to PayTo PaymentIntent with `setup_future_usage=off_session`
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Payto::MandateOptions))
}
attr_accessor :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(mandate_options: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Payto::MandateOptions), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(mandate_options: nil, setup_future_usage: nil); end
end
class Pix < Stripe::RequestParams
# The number of seconds (between 10 and 1209600) after which Pix payment will expire. Defaults to 86400 seconds.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_after_seconds
# The timestamp at which the Pix expires (between 10 and 1209600 seconds in the future). Defaults to 1 day in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_at
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(expires_after_seconds: T.nilable(Integer), expires_at: T.nilable(Integer), setup_future_usage: T.nilable(String)).void
}
def initialize(expires_after_seconds: nil, expires_at: nil, setup_future_usage: nil); end
end
class Promptpay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Qris < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Rechnung < Stripe::RequestParams; end
class RevolutPay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class SamsungPay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
sig { params(capture_method: T.nilable(T.nilable(String))).void }
def initialize(capture_method: nil); end
end
class Satispay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
sig { params(capture_method: T.nilable(T.nilable(String))).void }
def initialize(capture_method: nil); end
end
class SepaDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'STRIPE'.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :reference_prefix
sig { params(reference_prefix: T.nilable(T.nilable(String))).void }
def initialize(reference_prefix: nil); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::SepaDebit::MandateOptions))
}
attr_accessor :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
sig {
params(mandate_options: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::SepaDebit::MandateOptions), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), target_date: T.nilable(String)).void
}
def initialize(mandate_options: nil, setup_future_usage: nil, target_date: nil); end
end
class Shopeepay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Sofort < Stripe::RequestParams
# Language shown to the payer on redirect.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :preferred_language
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(preferred_language: T.nilable(T.nilable(T.any(String, String))), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(preferred_language: nil, setup_future_usage: nil); end
end
class StripeBalance < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void }
def initialize(setup_future_usage: nil); end
end
class Swish < Stripe::RequestParams
# A reference for this payment to be displayed in the Swish app.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :reference
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(reference: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(String)).void
}
def initialize(reference: nil, setup_future_usage: nil); end
end
class Twint < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class UsBankAccount < Stripe::RequestParams
class FinancialConnections < Stripe::RequestParams
class Filters < Stripe::RequestParams
# The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :account_subcategories
# ID of the institution to use to filter for selectable accounts.
sig { returns(T.nilable(String)) }
attr_accessor :institution
sig {
params(account_subcategories: T.nilable(T::Array[String]), institution: T.nilable(String)).void
}
def initialize(account_subcategories: nil, institution: nil); end
end
class ManualEntry < Stripe::RequestParams
# Settings for configuring manual entry of account details.
sig { returns(String) }
attr_accessor :mode
sig { params(mode: String).void }
def initialize(mode: nil); end
end
# Provide filters for the linked accounts that the customer can select for the payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::Filters))
}
attr_accessor :filters
# Customize manual entry behavior
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::ManualEntry))
}
attr_accessor :manual_entry
# The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :permissions
# List of data features that you would like to retrieve upon account creation.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :prefetch
# For webview integrations only. Upon completing OAuth login in the native browser, the user will be redirected to this URL to return to your app.
sig { returns(T.nilable(String)) }
attr_accessor :return_url
sig {
params(filters: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::Filters), manual_entry: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::ManualEntry), permissions: T.nilable(T::Array[String]), prefetch: T.nilable(T::Array[String]), return_url: T.nilable(String)).void
}
def initialize(
filters: nil,
manual_entry: nil,
permissions: nil,
prefetch: nil,
return_url: nil
); end
end
class MandateOptions < Stripe::RequestParams
# The method used to collect offline mandate customer acceptance.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :collection_method
sig { params(collection_method: T.nilable(T.nilable(String))).void }
def initialize(collection_method: nil); end
end
class Networks < Stripe::RequestParams
# Triggers validations to run across the selected networks
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Array[String])).void }
def initialize(requested: nil); end
end
# Additional fields for Financial Connections Session creation
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections))
}
attr_accessor :financial_connections
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::UsBankAccount::MandateOptions))
}
attr_accessor :mandate_options
# Additional fields for network related functions
sig {
returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::UsBankAccount::Networks))
}
attr_accessor :networks
# Preferred transaction settlement speed
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :preferred_settlement_speed
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
# Bank account verification method.
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(financial_connections: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections), mandate_options: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::UsBankAccount::MandateOptions), networks: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::UsBankAccount::Networks), preferred_settlement_speed: T.nilable(T.nilable(T.any(String, String))), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), target_date: T.nilable(String), verification_method: T.nilable(String)).void
}
def initialize(
financial_connections: nil,
mandate_options: nil,
networks: nil,
preferred_settlement_speed: nil,
setup_future_usage: nil,
target_date: nil,
verification_method: nil
); end
end
class WechatPay < Stripe::RequestParams
# The app ID registered with WeChat Pay. Only required when client is ios or android.
sig { returns(T.nilable(String)) }
attr_accessor :app_id
# The client type that the end customer will pay from
sig { returns(T.nilable(String)) }
attr_accessor :client
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(app_id: T.nilable(String), client: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(app_id: nil, client: nil, setup_future_usage: nil); end
end
class Zip < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
# If this is a `acss_debit` PaymentMethod, this sub-hash contains details about the ACSS Debit payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::AcssDebit))))
}
attr_accessor :acss_debit
# If this is an `affirm` PaymentMethod, this sub-hash contains details about the Affirm payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Affirm))))
}
attr_accessor :affirm
# If this is a `afterpay_clearpay` PaymentMethod, this sub-hash contains details about the Afterpay Clearpay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::AfterpayClearpay))))
}
attr_accessor :afterpay_clearpay
# If this is a `alipay` PaymentMethod, this sub-hash contains details about the Alipay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Alipay))))
}
attr_accessor :alipay
# If this is a `alma` PaymentMethod, this sub-hash contains details about the Alma payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Alma))))
}
attr_accessor :alma
# If this is a `amazon_pay` PaymentMethod, this sub-hash contains details about the Amazon Pay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::AmazonPay))))
}
attr_accessor :amazon_pay
# If this is a `au_becs_debit` PaymentMethod, this sub-hash contains details about the AU BECS Direct Debit payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::AuBecsDebit))))
}
attr_accessor :au_becs_debit
# If this is a `bacs_debit` PaymentMethod, this sub-hash contains details about the BACS Debit payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::BacsDebit))))
}
attr_accessor :bacs_debit
# If this is a `bancontact` PaymentMethod, this sub-hash contains details about the Bancontact payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Bancontact))))
}
attr_accessor :bancontact
# If this is a `billie` PaymentMethod, this sub-hash contains details about the Billie payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Billie))))
}
attr_accessor :billie
# If this is a `blik` PaymentMethod, this sub-hash contains details about the BLIK payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Blik))))
}
attr_accessor :blik
# If this is a `boleto` PaymentMethod, this sub-hash contains details about the Boleto payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Boleto))))
}
attr_accessor :boleto
# Configuration for any card payments attempted on this PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Card))))
}
attr_accessor :card
# If this is a `card_present` PaymentMethod, this sub-hash contains details about the Card Present payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::CardPresent))))
}
attr_accessor :card_present
# If this is a `cashapp` PaymentMethod, this sub-hash contains details about the Cash App Pay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Cashapp))))
}
attr_accessor :cashapp
# If this is a `customer balance` PaymentMethod, this sub-hash contains details about the customer balance payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::CustomerBalance))))
}
attr_accessor :customer_balance
# If this is a `eps` PaymentMethod, this sub-hash contains details about the EPS payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Eps))))
}
attr_accessor :eps
# If this is a `fpx` PaymentMethod, this sub-hash contains details about the FPX payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Fpx))))
}
attr_accessor :fpx
# If this is a `giropay` PaymentMethod, this sub-hash contains details about the Giropay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Giropay))))
}
attr_accessor :giropay
# If this is a `gopay` PaymentMethod, this sub-hash contains details about the Gopay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Gopay))))
}
attr_accessor :gopay
# If this is a `grabpay` PaymentMethod, this sub-hash contains details about the Grabpay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Grabpay))))
}
attr_accessor :grabpay
# If this is a `id_bank_transfer` PaymentMethod, this sub-hash contains details about the Indonesia Bank Transfer payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::IdBankTransfer))))
}
attr_accessor :id_bank_transfer
# If this is a `ideal` PaymentMethod, this sub-hash contains details about the Ideal payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Ideal))))
}
attr_accessor :ideal
# If this is a `interac_present` PaymentMethod, this sub-hash contains details about the Card Present payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::InteracPresent))))
}
attr_accessor :interac_present
# If this is a `kakao_pay` PaymentMethod, this sub-hash contains details about the Kakao Pay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::KakaoPay))))
}
attr_accessor :kakao_pay
# If this is a `klarna` PaymentMethod, this sub-hash contains details about the Klarna payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Klarna))))
}
attr_accessor :klarna
# If this is a `konbini` PaymentMethod, this sub-hash contains details about the Konbini payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Konbini))))
}
attr_accessor :konbini
# If this is a `kr_card` PaymentMethod, this sub-hash contains details about the KR Card payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::KrCard))))
}
attr_accessor :kr_card
# If this is a `link` PaymentMethod, this sub-hash contains details about the Link payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Link))))
}
attr_accessor :link
# If this is a `mb_way` PaymentMethod, this sub-hash contains details about the MB WAY payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::MbWay))))
}
attr_accessor :mb_way
# If this is a `MobilePay` PaymentMethod, this sub-hash contains details about the MobilePay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Mobilepay))))
}
attr_accessor :mobilepay
# If this is a `multibanco` PaymentMethod, this sub-hash contains details about the Multibanco payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Multibanco))))
}
attr_accessor :multibanco
# If this is a `naver_pay` PaymentMethod, this sub-hash contains details about the Naver Pay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::NaverPay))))
}
attr_accessor :naver_pay
# If this is a `nz_bank_account` PaymentMethod, this sub-hash contains details about the NZ BECS Direct Debit payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::NzBankAccount))))
}
attr_accessor :nz_bank_account
# If this is a `oxxo` PaymentMethod, this sub-hash contains details about the OXXO payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Oxxo))))
}
attr_accessor :oxxo
# If this is a `p24` PaymentMethod, this sub-hash contains details about the Przelewy24 payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::P24))))
}
attr_accessor :p24
# If this is a `pay_by_bank` PaymentMethod, this sub-hash contains details about the PayByBank payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::PayByBank))))
}
attr_accessor :pay_by_bank
# If this is a `payco` PaymentMethod, this sub-hash contains details about the PAYCO payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Payco))))
}
attr_accessor :payco
# If this is a `paynow` PaymentMethod, this sub-hash contains details about the PayNow payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Paynow))))
}
attr_accessor :paynow
# If this is a `paypal` PaymentMethod, this sub-hash contains details about the PayPal payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Paypal))))
}
attr_accessor :paypal
# If this is a `payto` PaymentMethod, this sub-hash contains details about the PayTo payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Payto))))
}
attr_accessor :payto
# If this is a `pix` PaymentMethod, this sub-hash contains details about the Pix payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Pix))))
}
attr_accessor :pix
# If this is a `promptpay` PaymentMethod, this sub-hash contains details about the PromptPay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Promptpay))))
}
attr_accessor :promptpay
# If this is a `qris` PaymentMethod, this sub-hash contains details about the QRIS payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Qris))))
}
attr_accessor :qris
# If this is a `rechnung` PaymentMethod, this sub-hash contains details about the Rechnung payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Rechnung))))
}
attr_accessor :rechnung
# If this is a `revolut_pay` PaymentMethod, this sub-hash contains details about the Revolut Pay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::RevolutPay))))
}
attr_accessor :revolut_pay
# If this is a `samsung_pay` PaymentMethod, this sub-hash contains details about the Samsung Pay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::SamsungPay))))
}
attr_accessor :samsung_pay
# If this is a `satispay` PaymentMethod, this sub-hash contains details about the Satispay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Satispay))))
}
attr_accessor :satispay
# If this is a `sepa_debit` PaymentIntent, this sub-hash contains details about the SEPA Debit payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::SepaDebit))))
}
attr_accessor :sepa_debit
# If this is a `shopeepay` PaymentMethod, this sub-hash contains details about the ShopeePay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Shopeepay))))
}
attr_accessor :shopeepay
# If this is a `sofort` PaymentMethod, this sub-hash contains details about the SOFORT payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Sofort))))
}
attr_accessor :sofort
# If this is a `stripe_balance` PaymentMethod, this sub-hash contains details about the Stripe Balance payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::StripeBalance))))
}
attr_accessor :stripe_balance
# If this is a `Swish` PaymentMethod, this sub-hash contains details about the Swish payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Swish))))
}
attr_accessor :swish
# If this is a `twint` PaymentMethod, this sub-hash contains details about the TWINT payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Twint))))
}
attr_accessor :twint
# If this is a `us_bank_account` PaymentMethod, this sub-hash contains details about the US bank account payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::UsBankAccount))))
}
attr_accessor :us_bank_account
# If this is a `wechat_pay` PaymentMethod, this sub-hash contains details about the WeChat Pay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::WechatPay))))
}
attr_accessor :wechat_pay
# If this is a `zip` PaymentMethod, this sub-hash contains details about the Zip payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Zip))))
}
attr_accessor :zip
sig {
params(acss_debit: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::AcssDebit))), affirm: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Affirm))), afterpay_clearpay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::AfterpayClearpay))), alipay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Alipay))), alma: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Alma))), amazon_pay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::AmazonPay))), au_becs_debit: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::AuBecsDebit))), bacs_debit: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::BacsDebit))), bancontact: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Bancontact))), billie: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Billie))), blik: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Blik))), boleto: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Boleto))), card: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Card))), card_present: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::CardPresent))), cashapp: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Cashapp))), customer_balance: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::CustomerBalance))), eps: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Eps))), fpx: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Fpx))), giropay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Giropay))), gopay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Gopay))), grabpay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Grabpay))), id_bank_transfer: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::IdBankTransfer))), ideal: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Ideal))), interac_present: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::InteracPresent))), kakao_pay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::KakaoPay))), klarna: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Klarna))), konbini: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Konbini))), kr_card: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::KrCard))), link: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Link))), mb_way: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::MbWay))), mobilepay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Mobilepay))), multibanco: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Multibanco))), naver_pay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::NaverPay))), nz_bank_account: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::NzBankAccount))), oxxo: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Oxxo))), p24: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::P24))), pay_by_bank: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::PayByBank))), payco: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Payco))), paynow: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Paynow))), paypal: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Paypal))), payto: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Payto))), pix: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Pix))), promptpay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Promptpay))), qris: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Qris))), rechnung: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Rechnung))), revolut_pay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::RevolutPay))), samsung_pay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::SamsungPay))), satispay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Satispay))), sepa_debit: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::SepaDebit))), shopeepay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Shopeepay))), sofort: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Sofort))), stripe_balance: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::StripeBalance))), swish: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Swish))), twint: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Twint))), us_bank_account: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::UsBankAccount))), wechat_pay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::WechatPay))), zip: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions::Zip)))).void
}
def initialize(
acss_debit: nil,
affirm: nil,
afterpay_clearpay: nil,
alipay: nil,
alma: nil,
amazon_pay: nil,
au_becs_debit: nil,
bacs_debit: nil,
bancontact: nil,
billie: nil,
blik: nil,
boleto: nil,
card: nil,
card_present: nil,
cashapp: nil,
customer_balance: nil,
eps: nil,
fpx: nil,
giropay: nil,
gopay: nil,
grabpay: nil,
id_bank_transfer: nil,
ideal: nil,
interac_present: nil,
kakao_pay: nil,
klarna: nil,
konbini: nil,
kr_card: nil,
link: nil,
mb_way: nil,
mobilepay: nil,
multibanco: nil,
naver_pay: nil,
nz_bank_account: nil,
oxxo: nil,
p24: nil,
pay_by_bank: nil,
payco: nil,
paynow: nil,
paypal: nil,
payto: nil,
pix: nil,
promptpay: nil,
qris: nil,
rechnung: nil,
revolut_pay: nil,
samsung_pay: nil,
satispay: nil,
sepa_debit: nil,
shopeepay: nil,
sofort: nil,
stripe_balance: nil,
swish: nil,
twint: nil,
us_bank_account: nil,
wechat_pay: nil,
zip: nil
); end
end
class RadarOptions < Stripe::RequestParams
# A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
sig { returns(T.nilable(String)) }
attr_accessor :session
sig { params(session: T.nilable(String)).void }
def initialize(session: nil); end
end
class Shipping < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Shipping address.
sig { returns(::Stripe::PaymentIntent::CreateParams::Shipping::Address) }
attr_accessor :address
# The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
sig { returns(T.nilable(String)) }
attr_accessor :carrier
# Recipient name.
sig { returns(String) }
attr_accessor :name
# Recipient phone (including extension).
sig { returns(T.nilable(String)) }
attr_accessor :phone
# The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
sig { returns(T.nilable(String)) }
attr_accessor :tracking_number
sig {
params(address: ::Stripe::PaymentIntent::CreateParams::Shipping::Address, carrier: T.nilable(String), name: String, phone: T.nilable(String), tracking_number: T.nilable(String)).void
}
def initialize(address: nil, carrier: nil, name: nil, phone: nil, tracking_number: nil); end
end
class TransferData < Stripe::RequestParams
# The amount that will be transferred automatically when a charge succeeds.
# The amount is capped at the total transaction amount and if no amount is set,
# the full amount is transferred.
#
# If you intend to collect a fee and you need a more robust reporting experience, using
# [application_fee_amount](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-application_fee_amount)
# might be a better fit for your integration.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# If specified, successful charges will be attributed to the destination
# account for tax reporting, and the funds from charges will be transferred
# to the destination account. The ID of the resulting transfer will be
# returned on the successful charge's `transfer` field.
sig { returns(String) }
attr_accessor :destination
sig { params(amount: T.nilable(Integer), destination: String).void }
def initialize(amount: nil, destination: nil); end
end
# Amount intended to be collected by this PaymentIntent. A positive integer representing how much to charge in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is $0.50 US or [equivalent in charge currency](https://stripe.com/docs/currencies#minimum-and-maximum-charge-amounts). The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99).
sig { returns(Integer) }
attr_accessor :amount
# The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. The amount of the application fee collected will be capped at the total amount captured. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
sig { returns(T.nilable(Integer)) }
attr_accessor :application_fee_amount
# When you enable this parameter, this PaymentIntent accepts payment methods that you enable in the Dashboard and that are compatible with this PaymentIntent's other parameters.
sig { returns(T.nilable(::Stripe::PaymentIntent::CreateParams::AutomaticPaymentMethods)) }
attr_accessor :automatic_payment_methods
# Controls when the funds will be captured from the customer's account.
sig { returns(T.nilable(String)) }
attr_accessor :capture_method
# Set to `true` to attempt to [confirm this PaymentIntent](https://stripe.com/docs/api/payment_intents/confirm) immediately. This parameter defaults to `false`. When creating and confirming a PaymentIntent at the same time, you can also provide the parameters available in the [Confirm API](https://stripe.com/docs/api/payment_intents/confirm).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :confirm
# Describes whether we can confirm this PaymentIntent automatically, or if it requires customer action to confirm the payment.
sig { returns(T.nilable(String)) }
attr_accessor :confirmation_method
# ID of the ConfirmationToken used to confirm this PaymentIntent.
#
# If the provided ConfirmationToken contains properties that are also being provided in this request, such as `payment_method`, then the values in this request will take precedence.
sig { returns(T.nilable(String)) }
attr_accessor :confirmation_token
# 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).
sig { returns(String) }
attr_accessor :currency
# ID of the Customer this PaymentIntent belongs to, if one exists.
#
# Payment methods attached to other Customers cannot be used with this PaymentIntent.
#
# If [setup_future_usage](https://stripe.com/docs/api#payment_intent_object-setup_future_usage) is set and this PaymentIntent's payment method is not `card_present`, then the payment method attaches to the Customer after the PaymentIntent has been confirmed and any required actions from the user are complete. If the payment method is `card_present` and isn't a digital wallet, then a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card is created and attached to the Customer instead.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# ID of the Account this PaymentIntent belongs to, if one exists.
#
# Payment methods attached to other Accounts cannot be used with this PaymentIntent.
#
# If [setup_future_usage](https://stripe.com/docs/api#payment_intent_object-setup_future_usage) is set and this PaymentIntent's payment method is not `card_present`, then the payment method attaches to the Account after the PaymentIntent has been confirmed and any required actions from the user are complete. If the payment method is `card_present` and isn't a digital wallet, then a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card is created and attached to the Account instead.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Set to `true` to fail the payment attempt if the PaymentIntent transitions into `requires_action`. Use this parameter for simpler integrations that don't handle customer actions, such as [saving cards without authentication](https://stripe.com/docs/payments/save-card-without-authentication). This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-confirm).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :error_on_requires_action
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The FX rate in the quote is validated and used to convert the presentment amount to the settlement amount.
sig { returns(T.nilable(String)) }
attr_accessor :fx_quote
# Automations to be run during the PaymentIntent lifecycle
sig { returns(T.nilable(::Stripe::PaymentIntent::CreateParams::Hooks)) }
attr_accessor :hooks
# ID of the mandate that's used for this payment. This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-confirm).
sig { returns(T.nilable(String)) }
attr_accessor :mandate
# This hash contains details about the Mandate to create. This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-confirm).
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::MandateData))))
}
attr_accessor :mandate_data
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Set to `true` to indicate that the customer isn't in your checkout flow during this payment attempt and can't authenticate. Use this parameter in scenarios where you collect card details and [charge them later](https://stripe.com/docs/payments/cards/charging-saved-cards). This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-confirm).
sig { returns(T.nilable(T.any(T::Boolean, String))) }
attr_accessor :off_session
# The Stripe account ID that these funds are intended for. Learn more about the [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
sig { returns(T.nilable(String)) }
attr_accessor :on_behalf_of
# Provides industry-specific information about the charge.
sig { returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails)) }
attr_accessor :payment_details
# ID of the payment method (a PaymentMethod, Card, or [compatible Source](https://stripe.com/docs/payments/payment-methods#compatibility) object) to attach to this PaymentIntent.
#
# If you don't provide the `payment_method` parameter or the `source` parameter with `confirm=true`, `source` automatically populates with `customer.default_source` to improve migration for users of the Charges API. We recommend that you explicitly provide the `payment_method` moving forward.
# If the payment method is attached to a Customer, you must also provide the ID of that Customer as the [customer](https://stripe.com/docs/api#create_payment_intent-customer) parameter of this PaymentIntent.
# end
sig { returns(T.nilable(String)) }
attr_accessor :payment_method
# The ID of the [payment method configuration](https://stripe.com/docs/api/payment_method_configurations) to use with this PaymentIntent.
sig { returns(T.nilable(String)) }
attr_accessor :payment_method_configuration
# If provided, this hash will be used to create a PaymentMethod. The new PaymentMethod will appear
# in the [payment_method](https://stripe.com/docs/api/payment_intents/object#payment_intent_object-payment_method)
# property on the PaymentIntent.
sig { returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData)) }
attr_accessor :payment_method_data
# Payment method-specific configuration for this PaymentIntent.
sig { returns(T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions)) }
attr_accessor :payment_method_options
# The list of payment method types (for example, a card) that this PaymentIntent can use. If you don't provide this, Stripe will dynamically show relevant payment methods from your [payment method settings](https://dashboard.stripe.com/settings/payment_methods).
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :payment_method_types
# Options to configure Radar. Learn more about [Radar Sessions](https://stripe.com/docs/radar/radar-session).
sig { returns(T.nilable(::Stripe::PaymentIntent::CreateParams::RadarOptions)) }
attr_accessor :radar_options
# Email address to send the receipt to. If you specify `receipt_email` for a payment in live mode, you send a receipt regardless of your [email settings](https://dashboard.stripe.com/account/emails).
sig { returns(T.nilable(String)) }
attr_accessor :receipt_email
# The URL to redirect your customer back to after they authenticate or cancel their payment on the payment method's app or site. If you'd prefer to redirect to a mobile application, you can alternatively supply an application URI scheme. This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-confirm).
sig { returns(T.nilable(String)) }
attr_accessor :return_url
# Indicates whether confirmation for this PaymentIntent using a secret key is `required` or `optional`.
sig { returns(T.nilable(String)) }
attr_accessor :secret_key_confirmation
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
# Shipping information for this PaymentIntent.
sig { returns(T.nilable(::Stripe::PaymentIntent::CreateParams::Shipping)) }
attr_accessor :shipping
# Text that appears on the customer's statement as the statement descriptor for a non-card charge. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
#
# Setting this value for a card charge returns an error. For card charges, set the [statement_descriptor_suffix](https://docs.stripe.com/get-started/account/statement-descriptors#dynamic) instead.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
# Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor_suffix
# The parameters that you can use to automatically create a Transfer.
# Learn more about the [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
sig { returns(T.nilable(::Stripe::PaymentIntent::CreateParams::TransferData)) }
attr_accessor :transfer_data
# A string that identifies the resulting payment as part of a group. Learn more about the [use case for connected accounts](https://stripe.com/docs/connect/separate-charges-and-transfers).
sig { returns(T.nilable(String)) }
attr_accessor :transfer_group
# Set to `true` when confirming server-side and using Stripe.js, iOS, or Android client-side SDKs to handle the next actions.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :use_stripe_sdk
sig {
params(amount: Integer, application_fee_amount: T.nilable(Integer), automatic_payment_methods: T.nilable(::Stripe::PaymentIntent::CreateParams::AutomaticPaymentMethods), capture_method: T.nilable(String), confirm: T.nilable(T::Boolean), confirmation_method: T.nilable(String), confirmation_token: T.nilable(String), currency: String, customer: T.nilable(String), customer_account: T.nilable(String), description: T.nilable(String), error_on_requires_action: T.nilable(T::Boolean), expand: T.nilable(T::Array[String]), fx_quote: T.nilable(String), hooks: T.nilable(::Stripe::PaymentIntent::CreateParams::Hooks), mandate: T.nilable(String), mandate_data: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CreateParams::MandateData))), metadata: T.nilable(T::Hash[String, String]), off_session: T.nilable(T.any(T::Boolean, String)), on_behalf_of: T.nilable(String), payment_details: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentDetails), payment_method: T.nilable(String), payment_method_configuration: T.nilable(String), payment_method_data: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodData), payment_method_options: T.nilable(::Stripe::PaymentIntent::CreateParams::PaymentMethodOptions), payment_method_types: T.nilable(T::Array[String]), radar_options: T.nilable(::Stripe::PaymentIntent::CreateParams::RadarOptions), receipt_email: T.nilable(String), return_url: T.nilable(String), secret_key_confirmation: T.nilable(String), setup_future_usage: T.nilable(String), shipping: T.nilable(::Stripe::PaymentIntent::CreateParams::Shipping), statement_descriptor: T.nilable(String), statement_descriptor_suffix: T.nilable(String), transfer_data: T.nilable(::Stripe::PaymentIntent::CreateParams::TransferData), transfer_group: T.nilable(String), use_stripe_sdk: T.nilable(T::Boolean)).void
}
def initialize(
amount: nil,
application_fee_amount: nil,
automatic_payment_methods: nil,
capture_method: nil,
confirm: nil,
confirmation_method: nil,
confirmation_token: nil,
currency: nil,
customer: nil,
customer_account: nil,
description: nil,
error_on_requires_action: nil,
expand: nil,
fx_quote: nil,
hooks: nil,
mandate: nil,
mandate_data: nil,
metadata: nil,
off_session: nil,
on_behalf_of: nil,
payment_details: nil,
payment_method: nil,
payment_method_configuration: nil,
payment_method_data: nil,
payment_method_options: nil,
payment_method_types: nil,
radar_options: nil,
receipt_email: nil,
return_url: nil,
secret_key_confirmation: nil,
setup_future_usage: nil,
shipping: nil,
statement_descriptor: nil,
statement_descriptor_suffix: nil,
transfer_data: nil,
transfer_group: nil,
use_stripe_sdk: nil
); end
end
class UpdateParams < Stripe::RequestParams
class Hooks < Stripe::RequestParams
class Inputs < Stripe::RequestParams
class Tax < Stripe::RequestParams
# The [TaxCalculation](https://stripe.com/docs/api/tax/calculations) id
sig { returns(T.nilable(String)) }
attr_accessor :calculation
sig { params(calculation: T.nilable(String)).void }
def initialize(calculation: nil); end
end
# Tax arguments for automations
sig { returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::Hooks::Inputs::Tax)) }
attr_accessor :tax
sig {
params(tax: T.nilable(::Stripe::PaymentIntent::UpdateParams::Hooks::Inputs::Tax)).void
}
def initialize(tax: nil); end
end
# Arguments passed in automations
sig { returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::Hooks::Inputs)) }
attr_accessor :inputs
sig { params(inputs: T.nilable(::Stripe::PaymentIntent::UpdateParams::Hooks::Inputs)).void }
def initialize(inputs: nil); end
end
class MandateData < Stripe::RequestParams
class CustomerAcceptance < Stripe::RequestParams
class Online < Stripe::RequestParams
# The IP address from which the Mandate was accepted by the customer.
sig { returns(T.nilable(String)) }
attr_accessor :ip_address
# The user agent of the browser from which the Mandate was accepted by the customer.
sig { returns(T.nilable(String)) }
attr_accessor :user_agent
sig { params(ip_address: T.nilable(String), user_agent: T.nilable(String)).void }
def initialize(ip_address: nil, user_agent: nil); end
end
# If this is a Mandate accepted online, this hash contains details about the online acceptance.
sig {
returns(::Stripe::PaymentIntent::UpdateParams::MandateData::CustomerAcceptance::Online)
}
attr_accessor :online
# The type of customer acceptance information included with the Mandate.
sig { returns(String) }
attr_accessor :type
sig {
params(online: ::Stripe::PaymentIntent::UpdateParams::MandateData::CustomerAcceptance::Online, type: String).void
}
def initialize(online: nil, type: nil); end
end
# This hash contains details about the customer acceptance of the Mandate.
sig { returns(::Stripe::PaymentIntent::UpdateParams::MandateData::CustomerAcceptance) }
attr_accessor :customer_acceptance
sig {
params(customer_acceptance: ::Stripe::PaymentIntent::UpdateParams::MandateData::CustomerAcceptance).void
}
def initialize(customer_acceptance: nil); end
end
class PaymentDetails < Stripe::RequestParams
class CarRental < Stripe::RequestParams
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::CarRental::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::CarRental::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
class Distance < Stripe::RequestParams
# Distance traveled.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# Unit of measurement for the distance traveled. One of `miles` or `kilometers`.
sig { returns(T.nilable(String)) }
attr_accessor :unit
sig { params(amount: T.nilable(Integer), unit: T.nilable(String)).void }
def initialize(amount: nil, unit: nil); end
end
class Driver < Stripe::RequestParams
# Driver's identification number.
sig { returns(T.nilable(String)) }
attr_accessor :driver_identification_number
# Driver's tax number.
sig { returns(T.nilable(String)) }
attr_accessor :driver_tax_number
# Full name of the person or entity on the car reservation.
sig { returns(String) }
attr_accessor :name
sig {
params(driver_identification_number: T.nilable(String), driver_tax_number: T.nilable(String), name: String).void
}
def initialize(
driver_identification_number: nil,
driver_tax_number: nil,
name: nil
); end
end
class PickupAddress < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class ReturnAddress < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::CarRental::Affiliate))
}
attr_accessor :affiliate
# The booking number associated with the car rental.
sig { returns(String) }
attr_accessor :booking_number
# Class code of the car.
sig { returns(T.nilable(String)) }
attr_accessor :car_class_code
# Make of the car.
sig { returns(T.nilable(String)) }
attr_accessor :car_make
# Model of the car.
sig { returns(T.nilable(String)) }
attr_accessor :car_model
# The name of the rental car company.
sig { returns(T.nilable(String)) }
attr_accessor :company
# The customer service phone number of the car rental company.
sig { returns(T.nilable(String)) }
attr_accessor :customer_service_phone_number
# Number of days the car is being rented.
sig { returns(Integer) }
attr_accessor :days_rented
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::CarRental::Delivery))
}
attr_accessor :delivery
# The details of the distance traveled during the rental period.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::CarRental::Distance))
}
attr_accessor :distance
# The details of the passengers in the travel reservation
sig {
returns(T.nilable(T::Array[::Stripe::PaymentIntent::UpdateParams::PaymentDetails::CarRental::Driver]))
}
attr_accessor :drivers
# List of additional charges being billed.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :extra_charges
# Indicates if the customer did not keep nor cancel their booking.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :no_show
# Car pick-up address.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::CarRental::PickupAddress))
}
attr_accessor :pickup_address
# Car pick-up time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :pickup_at
# Name of the pickup location.
sig { returns(T.nilable(String)) }
attr_accessor :pickup_location_name
# Rental rate.
sig { returns(T.nilable(Integer)) }
attr_accessor :rate_amount
# The frequency at which the rate amount is applied. One of `day`, `week` or `month`
sig { returns(T.nilable(String)) }
attr_accessor :rate_interval
# The name of the person or entity renting the car.
sig { returns(T.nilable(String)) }
attr_accessor :renter_name
# Car return address.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::CarRental::ReturnAddress))
}
attr_accessor :return_address
# Car return time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :return_at
# Name of the return location.
sig { returns(T.nilable(String)) }
attr_accessor :return_location_name
# Indicates whether the goods or services are tax-exempt or tax is not collected.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :tax_exempt
# The vehicle identification number.
sig { returns(T.nilable(String)) }
attr_accessor :vehicle_identification_number
sig {
params(affiliate: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::CarRental::Affiliate), booking_number: String, car_class_code: T.nilable(String), car_make: T.nilable(String), car_model: T.nilable(String), company: T.nilable(String), customer_service_phone_number: T.nilable(String), days_rented: Integer, delivery: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::CarRental::Delivery), distance: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::CarRental::Distance), drivers: T.nilable(T::Array[::Stripe::PaymentIntent::UpdateParams::PaymentDetails::CarRental::Driver]), extra_charges: T.nilable(T::Array[String]), no_show: T.nilable(T::Boolean), pickup_address: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::CarRental::PickupAddress), pickup_at: Integer, pickup_location_name: T.nilable(String), rate_amount: T.nilable(Integer), rate_interval: T.nilable(String), renter_name: T.nilable(String), return_address: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::CarRental::ReturnAddress), return_at: Integer, return_location_name: T.nilable(String), tax_exempt: T.nilable(T::Boolean), vehicle_identification_number: T.nilable(String)).void
}
def initialize(
affiliate: nil,
booking_number: nil,
car_class_code: nil,
car_make: nil,
car_model: nil,
company: nil,
customer_service_phone_number: nil,
days_rented: nil,
delivery: nil,
distance: nil,
drivers: nil,
extra_charges: nil,
no_show: nil,
pickup_address: nil,
pickup_at: nil,
pickup_location_name: nil,
rate_amount: nil,
rate_interval: nil,
renter_name: nil,
return_address: nil,
return_at: nil,
return_location_name: nil,
tax_exempt: nil,
vehicle_identification_number: nil
); end
end
class EventDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::EventDetails::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::EventDetails::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
# Indicates if the tickets are digitally checked when entering the venue.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :access_controlled_venue
# The event location's address.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::EventDetails::Address))
}
attr_accessor :address
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::EventDetails::Affiliate))
}
attr_accessor :affiliate
# The name of the company
sig { returns(T.nilable(String)) }
attr_accessor :company
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::EventDetails::Delivery))
}
attr_accessor :delivery
# Event end time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :ends_at
# Type of the event entertainment (concert, sports event etc)
sig { returns(T.nilable(String)) }
attr_accessor :genre
# The name of the event.
sig { returns(String) }
attr_accessor :name
# Event start time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :starts_at
sig {
params(access_controlled_venue: T.nilable(T::Boolean), address: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::EventDetails::Address), affiliate: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::EventDetails::Affiliate), company: T.nilable(String), delivery: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::EventDetails::Delivery), ends_at: T.nilable(Integer), genre: T.nilable(String), name: String, starts_at: T.nilable(Integer)).void
}
def initialize(
access_controlled_venue: nil,
address: nil,
affiliate: nil,
company: nil,
delivery: nil,
ends_at: nil,
genre: nil,
name: nil,
starts_at: nil
); end
end
class Flight < Stripe::RequestParams
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::Flight::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::Flight::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
class Passenger < Stripe::RequestParams
# Full name of the person or entity on the flight reservation.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Segment < Stripe::RequestParams
# The flight segment amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# The International Air Transport Association (IATA) airport code for the arrival airport.
sig { returns(T.nilable(String)) }
attr_accessor :arrival_airport
# The arrival time for the flight segment. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :arrives_at
# The International Air Transport Association (IATA) carrier code of the carrier operating the flight segment.
sig { returns(T.nilable(String)) }
attr_accessor :carrier
# The departure time for the flight segment. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :departs_at
# The International Air Transport Association (IATA) airport code for the departure airport.
sig { returns(T.nilable(String)) }
attr_accessor :departure_airport
# The flight number associated with the segment
sig { returns(T.nilable(String)) }
attr_accessor :flight_number
# The fare class for the segment.
sig { returns(T.nilable(String)) }
attr_accessor :service_class
sig {
params(amount: T.nilable(Integer), arrival_airport: T.nilable(String), arrives_at: T.nilable(Integer), carrier: T.nilable(String), departs_at: Integer, departure_airport: T.nilable(String), flight_number: T.nilable(String), service_class: T.nilable(String)).void
}
def initialize(
amount: nil,
arrival_airport: nil,
arrives_at: nil,
carrier: nil,
departs_at: nil,
departure_airport: nil,
flight_number: nil,
service_class: nil
); end
end
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::Flight::Affiliate))
}
attr_accessor :affiliate
# The agency number (i.e. International Air Transport Association (IATA) agency number) of the travel agency that made the booking.
sig { returns(T.nilable(String)) }
attr_accessor :agency_number
# The International Air Transport Association (IATA) carrier code of the carrier that issued the ticket.
sig { returns(T.nilable(String)) }
attr_accessor :carrier
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::Flight::Delivery))
}
attr_accessor :delivery
# The name of the person or entity on the reservation.
sig { returns(T.nilable(String)) }
attr_accessor :passenger_name
# The details of the passengers in the travel reservation.
sig {
returns(T.nilable(T::Array[::Stripe::PaymentIntent::UpdateParams::PaymentDetails::Flight::Passenger]))
}
attr_accessor :passengers
# The individual flight segments associated with the trip.
sig {
returns(T::Array[::Stripe::PaymentIntent::UpdateParams::PaymentDetails::Flight::Segment])
}
attr_accessor :segments
# The ticket number associated with the travel reservation.
sig { returns(T.nilable(String)) }
attr_accessor :ticket_number
sig {
params(affiliate: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::Flight::Affiliate), agency_number: T.nilable(String), carrier: T.nilable(String), delivery: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::Flight::Delivery), passenger_name: T.nilable(String), passengers: T.nilable(T::Array[::Stripe::PaymentIntent::UpdateParams::PaymentDetails::Flight::Passenger]), segments: T::Array[::Stripe::PaymentIntent::UpdateParams::PaymentDetails::Flight::Segment], ticket_number: T.nilable(String)).void
}
def initialize(
affiliate: nil,
agency_number: nil,
carrier: nil,
delivery: nil,
passenger_name: nil,
passengers: nil,
segments: nil,
ticket_number: nil
); end
end
class Lodging < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::Lodging::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::Lodging::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
class Passenger < Stripe::RequestParams
# Full name of the person or entity on the lodging reservation.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
# The lodging location's address.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::Lodging::Address))
}
attr_accessor :address
# The number of adults on the booking
sig { returns(T.nilable(Integer)) }
attr_accessor :adults
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::Lodging::Affiliate))
}
attr_accessor :affiliate
# The booking number associated with the lodging reservation.
sig { returns(T.nilable(String)) }
attr_accessor :booking_number
# The lodging category
sig { returns(T.nilable(String)) }
attr_accessor :category
# Lodging check-in time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :checkin_at
# Lodging check-out time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :checkout_at
# The customer service phone number of the lodging company.
sig { returns(T.nilable(String)) }
attr_accessor :customer_service_phone_number
# The daily lodging room rate.
sig { returns(T.nilable(Integer)) }
attr_accessor :daily_room_rate_amount
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::Lodging::Delivery))
}
attr_accessor :delivery
# List of additional charges being billed.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :extra_charges
# Indicates whether the lodging location is compliant with the Fire Safety Act.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :fire_safety_act_compliance
# The name of the lodging location.
sig { returns(T.nilable(String)) }
attr_accessor :name
# Indicates if the customer did not keep their booking while failing to cancel the reservation.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :no_show
# The number of rooms on the booking
sig { returns(T.nilable(Integer)) }
attr_accessor :number_of_rooms
# The details of the passengers in the travel reservation
sig {
returns(T.nilable(T::Array[::Stripe::PaymentIntent::UpdateParams::PaymentDetails::Lodging::Passenger]))
}
attr_accessor :passengers
# The phone number of the lodging location.
sig { returns(T.nilable(String)) }
attr_accessor :property_phone_number
# The room class for this purchase.
sig { returns(T.nilable(String)) }
attr_accessor :room_class
# The number of room nights
sig { returns(T.nilable(Integer)) }
attr_accessor :room_nights
# The total tax amount associating with the room reservation.
sig { returns(T.nilable(Integer)) }
attr_accessor :total_room_tax_amount
# The total tax amount
sig { returns(T.nilable(Integer)) }
attr_accessor :total_tax_amount
sig {
params(address: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::Lodging::Address), adults: T.nilable(Integer), affiliate: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::Lodging::Affiliate), booking_number: T.nilable(String), category: T.nilable(String), checkin_at: Integer, checkout_at: Integer, customer_service_phone_number: T.nilable(String), daily_room_rate_amount: T.nilable(Integer), delivery: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::Lodging::Delivery), extra_charges: T.nilable(T::Array[String]), fire_safety_act_compliance: T.nilable(T::Boolean), name: T.nilable(String), no_show: T.nilable(T::Boolean), number_of_rooms: T.nilable(Integer), passengers: T.nilable(T::Array[::Stripe::PaymentIntent::UpdateParams::PaymentDetails::Lodging::Passenger]), property_phone_number: T.nilable(String), room_class: T.nilable(String), room_nights: T.nilable(Integer), total_room_tax_amount: T.nilable(Integer), total_tax_amount: T.nilable(Integer)).void
}
def initialize(
address: nil,
adults: nil,
affiliate: nil,
booking_number: nil,
category: nil,
checkin_at: nil,
checkout_at: nil,
customer_service_phone_number: nil,
daily_room_rate_amount: nil,
delivery: nil,
extra_charges: nil,
fire_safety_act_compliance: nil,
name: nil,
no_show: nil,
number_of_rooms: nil,
passengers: nil,
property_phone_number: nil,
room_class: nil,
room_nights: nil,
total_room_tax_amount: nil,
total_tax_amount: nil
); end
end
class Subscription < Stripe::RequestParams
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class BillingInterval < Stripe::RequestParams
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :count
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
sig { params(count: Integer, interval: String).void }
def initialize(count: nil, interval: nil); end
end
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::Subscription::Affiliate))
}
attr_accessor :affiliate
# Info whether the subscription will be auto renewed upon expiry.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :auto_renewal
# Subscription billing details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::Subscription::BillingInterval))
}
attr_accessor :billing_interval
# Subscription end time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :ends_at
# Name of the product on subscription. e.g. Apple Music Subscription
sig { returns(String) }
attr_accessor :name
# Subscription start time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :starts_at
sig {
params(affiliate: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::Subscription::Affiliate), auto_renewal: T.nilable(T::Boolean), billing_interval: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::Subscription::BillingInterval), ends_at: T.nilable(Integer), name: String, starts_at: T.nilable(Integer)).void
}
def initialize(
affiliate: nil,
auto_renewal: nil,
billing_interval: nil,
ends_at: nil,
name: nil,
starts_at: nil
); end
end
# Car rental details for this PaymentIntent.
sig { returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::CarRental)) }
attr_accessor :car_rental
# Some customers might be required by their company or organization to provide this information. If so, provide this value. Otherwise you can ignore this field.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :customer_reference
# Event details for this PaymentIntent
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::EventDetails))
}
attr_accessor :event_details
# Flight reservation details for this PaymentIntent
sig { returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::Flight)) }
attr_accessor :flight
# Lodging reservation details for this PaymentIntent
sig { returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::Lodging)) }
attr_accessor :lodging
# A unique value assigned by the business to identify the transaction.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :order_reference
# Subscription details for this PaymentIntent
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::Subscription))
}
attr_accessor :subscription
sig {
params(car_rental: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::CarRental), customer_reference: T.nilable(T.nilable(String)), event_details: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::EventDetails), flight: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::Flight), lodging: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::Lodging), order_reference: T.nilable(T.nilable(String)), subscription: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentDetails::Subscription)).void
}
def initialize(
car_rental: nil,
customer_reference: nil,
event_details: nil,
flight: nil,
lodging: nil,
order_reference: nil,
subscription: nil
); end
end
class PaymentMethodData < Stripe::RequestParams
class AcssDebit < Stripe::RequestParams
# Customer's bank account number.
sig { returns(String) }
attr_accessor :account_number
# Institution number of the customer's bank.
sig { returns(String) }
attr_accessor :institution_number
# Transit number of the customer's bank.
sig { returns(String) }
attr_accessor :transit_number
sig {
params(account_number: String, institution_number: String, transit_number: String).void
}
def initialize(account_number: nil, institution_number: nil, transit_number: nil); end
end
class Affirm < Stripe::RequestParams; end
class AfterpayClearpay < Stripe::RequestParams; end
class Alipay < Stripe::RequestParams; end
class Alma < Stripe::RequestParams; end
class AmazonPay < Stripe::RequestParams; end
class AuBecsDebit < Stripe::RequestParams
# The account number for the bank account.
sig { returns(String) }
attr_accessor :account_number
# Bank-State-Branch number of the bank account.
sig { returns(String) }
attr_accessor :bsb_number
sig { params(account_number: String, bsb_number: String).void }
def initialize(account_number: nil, bsb_number: nil); end
end
class BacsDebit < Stripe::RequestParams
# Account number of the bank account that the funds will be debited from.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Sort code of the bank account. (e.g., `10-20-30`)
sig { returns(T.nilable(String)) }
attr_accessor :sort_code
sig { params(account_number: T.nilable(String), sort_code: T.nilable(String)).void }
def initialize(account_number: nil, sort_code: nil); end
end
class Bancontact < Stripe::RequestParams; end
class Billie < Stripe::RequestParams; end
class BillingDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Billing address.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::BillingDetails::Address))))
}
attr_accessor :address
# Email address.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :email
# Full name.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :name
# Billing phone number (including extension).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :phone
# Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
sig { returns(T.nilable(String)) }
attr_accessor :tax_id
sig {
params(address: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::BillingDetails::Address))), email: T.nilable(T.nilable(String)), name: T.nilable(T.nilable(String)), phone: T.nilable(T.nilable(String)), tax_id: T.nilable(String)).void
}
def initialize(address: nil, email: nil, name: nil, phone: nil, tax_id: nil); end
end
class Blik < Stripe::RequestParams; end
class Boleto < Stripe::RequestParams
# The tax ID of the customer (CPF for individual consumers or CNPJ for businesses consumers)
sig { returns(String) }
attr_accessor :tax_id
sig { params(tax_id: String).void }
def initialize(tax_id: nil); end
end
class Cashapp < Stripe::RequestParams; end
class CustomerBalance < Stripe::RequestParams; end
class Eps < Stripe::RequestParams
# The customer's bank.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class Fpx < Stripe::RequestParams
# Account holder type for FPX transaction
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_type
# The customer's bank.
sig { returns(String) }
attr_accessor :bank
sig { params(account_holder_type: T.nilable(String), bank: String).void }
def initialize(account_holder_type: nil, bank: nil); end
end
class Giropay < Stripe::RequestParams; end
class Gopay < Stripe::RequestParams; end
class Grabpay < Stripe::RequestParams; end
class IdBankTransfer < Stripe::RequestParams
# Bank where the account is held.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class Ideal < Stripe::RequestParams
# The customer's bank. Only use this parameter for existing customers. Don't use it for new customers.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class InteracPresent < Stripe::RequestParams; end
class KakaoPay < Stripe::RequestParams; end
class Klarna < Stripe::RequestParams
class Dob < Stripe::RequestParams
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
# Customer's date of birth
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Klarna::Dob))
}
attr_accessor :dob
sig {
params(dob: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Klarna::Dob)).void
}
def initialize(dob: nil); end
end
class Konbini < Stripe::RequestParams; end
class KrCard < Stripe::RequestParams; end
class Link < Stripe::RequestParams; end
class MbWay < Stripe::RequestParams; end
class Mobilepay < Stripe::RequestParams; end
class Multibanco < Stripe::RequestParams; end
class NaverPay < Stripe::RequestParams
# Whether to use Naver Pay points or a card to fund this transaction. If not provided, this defaults to `card`.
sig { returns(T.nilable(String)) }
attr_accessor :funding
sig { params(funding: T.nilable(String)).void }
def initialize(funding: nil); end
end
class NzBankAccount < Stripe::RequestParams
# The name on the bank account. Only required if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod’s billing details.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_name
# The account number for the bank account.
sig { returns(String) }
attr_accessor :account_number
# The numeric code for the bank account's bank.
sig { returns(String) }
attr_accessor :bank_code
# The numeric code for the bank account's bank branch.
sig { returns(String) }
attr_accessor :branch_code
# Attribute for param field reference
sig { returns(T.nilable(String)) }
attr_accessor :reference
# The suffix of the bank account number.
sig { returns(String) }
attr_accessor :suffix
sig {
params(account_holder_name: T.nilable(String), account_number: String, bank_code: String, branch_code: String, reference: T.nilable(String), suffix: String).void
}
def initialize(
account_holder_name: nil,
account_number: nil,
bank_code: nil,
branch_code: nil,
reference: nil,
suffix: nil
); end
end
class Oxxo < Stripe::RequestParams; end
class P24 < Stripe::RequestParams
# The customer's bank.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class PayByBank < Stripe::RequestParams; end
class Payco < Stripe::RequestParams; end
class Paynow < Stripe::RequestParams; end
class Paypal < Stripe::RequestParams; end
class Payto < Stripe::RequestParams
# The account number for the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Bank-State-Branch number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :bsb_number
# The PayID alias for the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :pay_id
sig {
params(account_number: T.nilable(String), bsb_number: T.nilable(String), pay_id: T.nilable(String)).void
}
def initialize(account_number: nil, bsb_number: nil, pay_id: nil); end
end
class Pix < Stripe::RequestParams; end
class Promptpay < Stripe::RequestParams; end
class Qris < Stripe::RequestParams; end
class RadarOptions < Stripe::RequestParams
# A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
sig { returns(T.nilable(String)) }
attr_accessor :session
sig { params(session: T.nilable(String)).void }
def initialize(session: nil); end
end
class Rechnung < Stripe::RequestParams
class Dob < Stripe::RequestParams
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
# Customer's date of birth
sig { returns(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Rechnung::Dob) }
attr_accessor :dob
sig {
params(dob: ::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Rechnung::Dob).void
}
def initialize(dob: nil); end
end
class RevolutPay < Stripe::RequestParams; end
class SamsungPay < Stripe::RequestParams; end
class Satispay < Stripe::RequestParams; end
class SepaDebit < Stripe::RequestParams
# IBAN of the bank account.
sig { returns(String) }
attr_accessor :iban
sig { params(iban: String).void }
def initialize(iban: nil); end
end
class Shopeepay < Stripe::RequestParams; end
class Sofort < Stripe::RequestParams
# Two-letter ISO code representing the country the bank account is located in.
sig { returns(String) }
attr_accessor :country
sig { params(country: String).void }
def initialize(country: nil); end
end
class StripeBalance < Stripe::RequestParams
# The connected account ID whose Stripe balance to use as the source of payment
sig { returns(T.nilable(String)) }
attr_accessor :account
# The [source_type](https://docs.stripe.com/api/balance/balance_object#balance_object-available-source_types) of the balance
sig { returns(T.nilable(String)) }
attr_accessor :source_type
sig { params(account: T.nilable(String), source_type: T.nilable(String)).void }
def initialize(account: nil, source_type: nil); end
end
class Swish < Stripe::RequestParams; end
class Twint < Stripe::RequestParams; end
class UsBankAccount < Stripe::RequestParams
# Account holder type: individual or company.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_type
# Account number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Account type: checkings or savings. Defaults to checking if omitted.
sig { returns(T.nilable(String)) }
attr_accessor :account_type
# The ID of a Financial Connections Account to use as a payment method.
sig { returns(T.nilable(String)) }
attr_accessor :financial_connections_account
# Routing number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :routing_number
sig {
params(account_holder_type: T.nilable(String), account_number: T.nilable(String), account_type: T.nilable(String), financial_connections_account: T.nilable(String), routing_number: T.nilable(String)).void
}
def initialize(
account_holder_type: nil,
account_number: nil,
account_type: nil,
financial_connections_account: nil,
routing_number: nil
); end
end
class WechatPay < Stripe::RequestParams; end
class Zip < Stripe::RequestParams; end
# If this is an `acss_debit` PaymentMethod, this hash contains details about the ACSS Debit payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::AcssDebit))
}
attr_accessor :acss_debit
# If this is an `affirm` PaymentMethod, this hash contains details about the Affirm payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Affirm)) }
attr_accessor :affirm
# If this is an `AfterpayClearpay` PaymentMethod, this hash contains details about the AfterpayClearpay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::AfterpayClearpay))
}
attr_accessor :afterpay_clearpay
# If this is an `Alipay` PaymentMethod, this hash contains details about the Alipay payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Alipay)) }
attr_accessor :alipay
# This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :allow_redisplay
# If this is a Alma PaymentMethod, this hash contains details about the Alma payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Alma)) }
attr_accessor :alma
# If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::AmazonPay))
}
attr_accessor :amazon_pay
# If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::AuBecsDebit))
}
attr_accessor :au_becs_debit
# If this is a `bacs_debit` PaymentMethod, this hash contains details about the Bacs Direct Debit bank account.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::BacsDebit))
}
attr_accessor :bacs_debit
# If this is a `bancontact` PaymentMethod, this hash contains details about the Bancontact payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Bancontact))
}
attr_accessor :bancontact
# If this is a `billie` PaymentMethod, this hash contains details about the Billie payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Billie)) }
attr_accessor :billie
# Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::BillingDetails))
}
attr_accessor :billing_details
# If this is a `blik` PaymentMethod, this hash contains details about the BLIK payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Blik)) }
attr_accessor :blik
# If this is a `boleto` PaymentMethod, this hash contains details about the Boleto payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Boleto)) }
attr_accessor :boleto
# If this is a `cashapp` PaymentMethod, this hash contains details about the Cash App Pay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Cashapp))
}
attr_accessor :cashapp
# If this is a `customer_balance` PaymentMethod, this hash contains details about the CustomerBalance payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::CustomerBalance))
}
attr_accessor :customer_balance
# If this is an `eps` PaymentMethod, this hash contains details about the EPS payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Eps)) }
attr_accessor :eps
# If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Fpx)) }
attr_accessor :fpx
# If this is a `giropay` PaymentMethod, this hash contains details about the Giropay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Giropay))
}
attr_accessor :giropay
# If this is a Gopay PaymentMethod, this hash contains details about the Gopay payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Gopay)) }
attr_accessor :gopay
# If this is a `grabpay` PaymentMethod, this hash contains details about the GrabPay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Grabpay))
}
attr_accessor :grabpay
# If this is an `IdBankTransfer` PaymentMethod, this hash contains details about the IdBankTransfer payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::IdBankTransfer))
}
attr_accessor :id_bank_transfer
# If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Ideal)) }
attr_accessor :ideal
# If this is an `interac_present` PaymentMethod, this hash contains details about the Interac Present payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::InteracPresent))
}
attr_accessor :interac_present
# If this is a `kakao_pay` PaymentMethod, this hash contains details about the Kakao Pay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::KakaoPay))
}
attr_accessor :kakao_pay
# If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Klarna)) }
attr_accessor :klarna
# If this is a `konbini` PaymentMethod, this hash contains details about the Konbini payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Konbini))
}
attr_accessor :konbini
# If this is a `kr_card` PaymentMethod, this hash contains details about the Korean Card payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::KrCard)) }
attr_accessor :kr_card
# If this is an `Link` PaymentMethod, this hash contains details about the Link payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Link)) }
attr_accessor :link
# If this is a MB WAY PaymentMethod, this hash contains details about the MB WAY payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::MbWay)) }
attr_accessor :mb_way
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# If this is a `mobilepay` PaymentMethod, this hash contains details about the MobilePay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Mobilepay))
}
attr_accessor :mobilepay
# If this is a `multibanco` PaymentMethod, this hash contains details about the Multibanco payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Multibanco))
}
attr_accessor :multibanco
# If this is a `naver_pay` PaymentMethod, this hash contains details about the Naver Pay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::NaverPay))
}
attr_accessor :naver_pay
# If this is an nz_bank_account PaymentMethod, this hash contains details about the nz_bank_account payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::NzBankAccount))
}
attr_accessor :nz_bank_account
# If this is an `oxxo` PaymentMethod, this hash contains details about the OXXO payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Oxxo)) }
attr_accessor :oxxo
# If this is a `p24` PaymentMethod, this hash contains details about the P24 payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::P24)) }
attr_accessor :p24
# If this is a `pay_by_bank` PaymentMethod, this hash contains details about the PayByBank payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::PayByBank))
}
attr_accessor :pay_by_bank
# If this is a `payco` PaymentMethod, this hash contains details about the PAYCO payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Payco)) }
attr_accessor :payco
# If this is a `paynow` PaymentMethod, this hash contains details about the PayNow payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Paynow)) }
attr_accessor :paynow
# If this is a `paypal` PaymentMethod, this hash contains details about the PayPal payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Paypal)) }
attr_accessor :paypal
# If this is a `payto` PaymentMethod, this hash contains details about the PayTo payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Payto)) }
attr_accessor :payto
# If this is a `pix` PaymentMethod, this hash contains details about the Pix payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Pix)) }
attr_accessor :pix
# If this is a `promptpay` PaymentMethod, this hash contains details about the PromptPay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Promptpay))
}
attr_accessor :promptpay
# If this is a `qris` PaymentMethod, this hash contains details about the QRIS payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Qris)) }
attr_accessor :qris
# Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::RadarOptions))
}
attr_accessor :radar_options
# If this is a `rechnung` PaymentMethod, this hash contains details about the Rechnung payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Rechnung))
}
attr_accessor :rechnung
# If this is a `revolut_pay` PaymentMethod, this hash contains details about the Revolut Pay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::RevolutPay))
}
attr_accessor :revolut_pay
# If this is a `samsung_pay` PaymentMethod, this hash contains details about the SamsungPay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::SamsungPay))
}
attr_accessor :samsung_pay
# If this is a `satispay` PaymentMethod, this hash contains details about the Satispay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Satispay))
}
attr_accessor :satispay
# If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::SepaDebit))
}
attr_accessor :sepa_debit
# If this is a Shopeepay PaymentMethod, this hash contains details about the Shopeepay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Shopeepay))
}
attr_accessor :shopeepay
# If this is a `sofort` PaymentMethod, this hash contains details about the SOFORT payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Sofort)) }
attr_accessor :sofort
# This hash contains details about the Stripe balance payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::StripeBalance))
}
attr_accessor :stripe_balance
# If this is a `swish` PaymentMethod, this hash contains details about the Swish payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Swish)) }
attr_accessor :swish
# If this is a TWINT PaymentMethod, this hash contains details about the TWINT payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Twint)) }
attr_accessor :twint
# The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
sig { returns(String) }
attr_accessor :type
# If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::UsBankAccount))
}
attr_accessor :us_bank_account
# If this is an `wechat_pay` PaymentMethod, this hash contains details about the wechat_pay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::WechatPay))
}
attr_accessor :wechat_pay
# If this is a `zip` PaymentMethod, this hash contains details about the Zip payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Zip)) }
attr_accessor :zip
sig {
params(acss_debit: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::AcssDebit), affirm: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Affirm), afterpay_clearpay: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::AfterpayClearpay), alipay: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Alipay), allow_redisplay: T.nilable(String), alma: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Alma), amazon_pay: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::AmazonPay), au_becs_debit: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::AuBecsDebit), bacs_debit: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::BacsDebit), bancontact: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Bancontact), billie: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Billie), billing_details: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::BillingDetails), blik: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Blik), boleto: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Boleto), cashapp: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Cashapp), customer_balance: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::CustomerBalance), eps: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Eps), fpx: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Fpx), giropay: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Giropay), gopay: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Gopay), grabpay: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Grabpay), id_bank_transfer: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::IdBankTransfer), ideal: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Ideal), interac_present: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::InteracPresent), kakao_pay: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::KakaoPay), klarna: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Klarna), konbini: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Konbini), kr_card: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::KrCard), link: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Link), mb_way: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::MbWay), metadata: T.nilable(T::Hash[String, String]), mobilepay: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Mobilepay), multibanco: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Multibanco), naver_pay: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::NaverPay), nz_bank_account: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::NzBankAccount), oxxo: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Oxxo), p24: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::P24), pay_by_bank: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::PayByBank), payco: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Payco), paynow: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Paynow), paypal: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Paypal), payto: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Payto), pix: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Pix), promptpay: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Promptpay), qris: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Qris), radar_options: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::RadarOptions), rechnung: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Rechnung), revolut_pay: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::RevolutPay), samsung_pay: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::SamsungPay), satispay: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Satispay), sepa_debit: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::SepaDebit), shopeepay: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Shopeepay), sofort: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Sofort), stripe_balance: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::StripeBalance), swish: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Swish), twint: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Twint), type: String, us_bank_account: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::UsBankAccount), wechat_pay: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::WechatPay), zip: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData::Zip)).void
}
def initialize(
acss_debit: nil,
affirm: nil,
afterpay_clearpay: nil,
alipay: nil,
allow_redisplay: nil,
alma: nil,
amazon_pay: nil,
au_becs_debit: nil,
bacs_debit: nil,
bancontact: nil,
billie: nil,
billing_details: nil,
blik: nil,
boleto: nil,
cashapp: nil,
customer_balance: nil,
eps: nil,
fpx: nil,
giropay: nil,
gopay: nil,
grabpay: nil,
id_bank_transfer: nil,
ideal: nil,
interac_present: nil,
kakao_pay: nil,
klarna: nil,
konbini: nil,
kr_card: nil,
link: nil,
mb_way: nil,
metadata: nil,
mobilepay: nil,
multibanco: nil,
naver_pay: nil,
nz_bank_account: nil,
oxxo: nil,
p24: nil,
pay_by_bank: nil,
payco: nil,
paynow: nil,
paypal: nil,
payto: nil,
pix: nil,
promptpay: nil,
qris: nil,
radar_options: nil,
rechnung: nil,
revolut_pay: nil,
samsung_pay: nil,
satispay: nil,
sepa_debit: nil,
shopeepay: nil,
sofort: nil,
stripe_balance: nil,
swish: nil,
twint: nil,
type: nil,
us_bank_account: nil,
wechat_pay: nil,
zip: nil
); end
end
class PaymentMethodOptions < Stripe::RequestParams
class AcssDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# A URL for custom mandate text to render during confirmation step.
# The URL will be rendered with additional GET parameters `payment_intent` and `payment_intent_client_secret` when confirming a Payment Intent,
# or `setup_intent` and `setup_intent_client_secret` when confirming a Setup Intent.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :custom_mandate_url
# Description of the mandate interval. Only required if 'payment_schedule' parameter is 'interval' or 'combined'.
sig { returns(T.nilable(String)) }
attr_accessor :interval_description
# Payment schedule for the mandate.
sig { returns(T.nilable(String)) }
attr_accessor :payment_schedule
# Transaction type of the mandate.
sig { returns(T.nilable(String)) }
attr_accessor :transaction_type
sig {
params(custom_mandate_url: T.nilable(T.nilable(String)), interval_description: T.nilable(String), payment_schedule: T.nilable(String), transaction_type: T.nilable(String)).void
}
def initialize(
custom_mandate_url: nil,
interval_description: nil,
payment_schedule: nil,
transaction_type: nil
); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::AcssDebit::MandateOptions))
}
attr_accessor :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
# Bank account verification method.
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(mandate_options: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::AcssDebit::MandateOptions), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), target_date: T.nilable(String), verification_method: T.nilable(String)).void
}
def initialize(
mandate_options: nil,
setup_future_usage: nil,
target_date: nil,
verification_method: nil
); end
end
class Affirm < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Preferred language of the Affirm authorization page that the customer is redirected to.
sig { returns(T.nilable(String)) }
attr_accessor :preferred_locale
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), preferred_locale: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(capture_method: nil, preferred_locale: nil, setup_future_usage: nil); end
end
class AfterpayClearpay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# An internal identifier or reference that this payment corresponds to. You must limit the identifier to 128 characters, and it can only contain letters, numbers, underscores, backslashes, and dashes.
# This field differs from the statement descriptor and item name.
sig { returns(T.nilable(String)) }
attr_accessor :reference
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), reference: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(capture_method: nil, reference: nil, setup_future_usage: nil); end
end
class Alipay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void }
def initialize(setup_future_usage: nil); end
end
class Alma < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
sig { params(capture_method: T.nilable(T.nilable(String))).void }
def initialize(capture_method: nil); end
end
class AmazonPay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class AuBecsDebit < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
sig {
params(setup_future_usage: T.nilable(T.nilable(T.any(String, String))), target_date: T.nilable(String)).void
}
def initialize(setup_future_usage: nil, target_date: nil); end
end
class BacsDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'DDIC' or 'STRIPE'.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :reference_prefix
sig { params(reference_prefix: T.nilable(T.nilable(String))).void }
def initialize(reference_prefix: nil); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::BacsDebit::MandateOptions))
}
attr_accessor :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
sig {
params(mandate_options: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::BacsDebit::MandateOptions), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), target_date: T.nilable(String)).void
}
def initialize(mandate_options: nil, setup_future_usage: nil, target_date: nil); end
end
class Bancontact < Stripe::RequestParams
# Preferred language of the Bancontact authorization page that the customer is redirected to.
sig { returns(T.nilable(String)) }
attr_accessor :preferred_language
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(preferred_language: T.nilable(String), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(preferred_language: nil, setup_future_usage: nil); end
end
class Billie < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
sig { params(capture_method: T.nilable(T.nilable(String))).void }
def initialize(capture_method: nil); end
end
class Blik < Stripe::RequestParams
# The 6-digit BLIK code that a customer has generated using their banking application. Can only be set on confirmation.
sig { returns(T.nilable(String)) }
attr_accessor :code
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :setup_future_usage
sig {
params(code: T.nilable(String), setup_future_usage: T.nilable(T.nilable(String))).void
}
def initialize(code: nil, setup_future_usage: nil); end
end
class Boleto < Stripe::RequestParams
# The number of calendar days before a Boleto voucher expires. For example, if you create a Boleto voucher on Monday and you set expires_after_days to 2, the Boleto invoice will expire on Wednesday at 23:59 America/Sao_Paulo time.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_after_days
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(expires_after_days: T.nilable(Integer), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(expires_after_days: nil, setup_future_usage: nil); end
end
class Card < Stripe::RequestParams
class Installments < Stripe::RequestParams
class Plan < Stripe::RequestParams
# For `fixed_count` installment plans, this is required. It represents the number of installment payments your customer will make to their credit card.
sig { returns(T.nilable(Integer)) }
attr_accessor :count
# For `fixed_count` installment plans, this is required. It represents the interval between installment payments your customer will make to their credit card.
# One of `month`.
sig { returns(T.nilable(String)) }
attr_accessor :interval
# Type of installment plan, one of `fixed_count`.
sig { returns(String) }
attr_accessor :type
sig {
params(count: T.nilable(Integer), interval: T.nilable(String), type: String).void
}
def initialize(count: nil, interval: nil, type: nil); end
end
# Setting to true enables installments for this PaymentIntent.
# This will cause the response to contain a list of available installment plans.
# Setting to false will prevent any selected plan from applying to a charge.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :enabled
# The selected installment plan to use for this payment attempt.
# This parameter can only be provided during confirmation.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Card::Installments::Plan))))
}
attr_accessor :plan
sig {
params(enabled: T.nilable(T::Boolean), plan: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Card::Installments::Plan)))).void
}
def initialize(enabled: nil, plan: nil); end
end
class MandateOptions < Stripe::RequestParams
# Amount to be charged for future payments.
sig { returns(Integer) }
attr_accessor :amount
# One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.
sig { returns(String) }
attr_accessor :amount_type
# A description of the mandate or subscription that is meant to be displayed to the customer.
sig { returns(T.nilable(String)) }
attr_accessor :description
# End date of the mandate or subscription. If not provided, the mandate will be active until canceled. If provided, end date should be after start date.
sig { returns(T.nilable(Integer)) }
attr_accessor :end_date
# Specifies payment frequency. One of `day`, `week`, `month`, `year`, or `sporadic`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals between payments. For example, `interval=month` and `interval_count=3` indicates one payment every three months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks). This parameter is optional when `interval=sporadic`.
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_count
# Unique identifier for the mandate or subscription.
sig { returns(String) }
attr_accessor :reference
# Start date of the mandate or subscription. Start date should not be lesser than yesterday.
sig { returns(Integer) }
attr_accessor :start_date
# Specifies the type of mandates supported. Possible values are `india`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :supported_types
sig {
params(amount: Integer, amount_type: String, description: T.nilable(String), end_date: T.nilable(Integer), interval: String, interval_count: T.nilable(Integer), reference: String, start_date: Integer, supported_types: T.nilable(T::Array[String])).void
}
def initialize(
amount: nil,
amount_type: nil,
description: nil,
end_date: nil,
interval: nil,
interval_count: nil,
reference: nil,
start_date: nil,
supported_types: nil
); end
end
class StatementDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Please pass in an address that is within your Stripe user account country
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Card::StatementDetails::Address))
}
attr_accessor :address
# Phone number (e.g., a toll-free number that customers can call)
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(address: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Card::StatementDetails::Address), phone: T.nilable(String)).void
}
def initialize(address: nil, phone: nil); end
end
class ThreeDSecure < Stripe::RequestParams
class NetworkOptions < Stripe::RequestParams
class CartesBancaires < Stripe::RequestParams
# The cryptogram calculation algorithm used by the card Issuer's ACS
# to calculate the Authentication cryptogram. Also known as `cavvAlgorithm`.
# messageExtension: CB-AVALGO
sig { returns(String) }
attr_accessor :cb_avalgo
# The exemption indicator returned from Cartes Bancaires in the ARes.
# message extension: CB-EXEMPTION; string (4 characters)
# This is a 3 byte bitmap (low significant byte first and most significant
# bit first) that has been Base64 encoded
sig { returns(T.nilable(String)) }
attr_accessor :cb_exemption
# The risk score returned from Cartes Bancaires in the ARes.
# message extension: CB-SCORE; numeric value 0-99
sig { returns(T.nilable(Integer)) }
attr_accessor :cb_score
sig {
params(cb_avalgo: String, cb_exemption: T.nilable(String), cb_score: T.nilable(Integer)).void
}
def initialize(cb_avalgo: nil, cb_exemption: nil, cb_score: nil); end
end
# Cartes Bancaires-specific 3DS fields.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions::CartesBancaires))
}
attr_accessor :cartes_bancaires
sig {
params(cartes_bancaires: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions::CartesBancaires)).void
}
def initialize(cartes_bancaires: nil); end
end
# The `transStatus` returned from the card Issuer’s ACS in the ARes.
sig { returns(T.nilable(String)) }
attr_accessor :ares_trans_status
# The cryptogram, also known as the "authentication value" (AAV, CAVV or
# AEVV). This value is 20 bytes, base64-encoded into a 28-character string.
# (Most 3D Secure providers will return the base64-encoded version, which
# is what you should specify here.)
sig { returns(String) }
attr_accessor :cryptogram
# The Electronic Commerce Indicator (ECI) is returned by your 3D Secure
# provider and indicates what degree of authentication was performed.
sig { returns(T.nilable(String)) }
attr_accessor :electronic_commerce_indicator
# The exemption requested via 3DS and accepted by the issuer at authentication time.
sig { returns(T.nilable(String)) }
attr_accessor :exemption_indicator
# Network specific 3DS fields. Network specific arguments require an
# explicit card brand choice. The parameter `payment_method_options.card.network``
# must be populated accordingly
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions))
}
attr_accessor :network_options
# The challenge indicator (`threeDSRequestorChallengeInd`) which was requested in the
# AReq sent to the card Issuer's ACS. A string containing 2 digits from 01-99.
sig { returns(T.nilable(String)) }
attr_accessor :requestor_challenge_indicator
# For 3D Secure 1, the XID. For 3D Secure 2, the Directory Server
# Transaction ID (dsTransID).
sig { returns(String) }
attr_accessor :transaction_id
# The version of 3D Secure that was performed.
sig { returns(String) }
attr_accessor :version
sig {
params(ares_trans_status: T.nilable(String), cryptogram: String, electronic_commerce_indicator: T.nilable(String), exemption_indicator: T.nilable(String), network_options: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions), requestor_challenge_indicator: T.nilable(String), transaction_id: String, version: String).void
}
def initialize(
ares_trans_status: nil,
cryptogram: nil,
electronic_commerce_indicator: nil,
exemption_indicator: nil,
network_options: nil,
requestor_challenge_indicator: nil,
transaction_id: nil,
version: nil
); end
end
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# A single-use `cvc_update` Token that represents a card CVC value. When provided, the CVC value will be verified during the card payment attempt. This parameter can only be provided during confirmation.
sig { returns(T.nilable(String)) }
attr_accessor :cvc_token
# Installment configuration for payments attempted on this PaymentIntent (Mexico Only).
#
# For more information, see the [installments integration guide](https://stripe.com/docs/payments/installments).
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Card::Installments))
}
attr_accessor :installments
# Configuration options for setting up an eMandate for cards issued in India.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Card::MandateOptions))
}
attr_accessor :mandate_options
# When specified, this parameter indicates that a transaction will be marked
# as MOTO (Mail Order Telephone Order) and thus out of scope for SCA. This
# parameter can only be provided during confirmation.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :moto
# Selected network to process this PaymentIntent on. Depends on the available networks of the card attached to the PaymentIntent. Can be only set confirm-time.
sig { returns(T.nilable(String)) }
attr_accessor :network
# Request ability to [decrement the authorization](https://stripe.com/docs/payments/decremental-authorization) for this PaymentIntent.
sig { returns(T.nilable(String)) }
attr_accessor :request_decremental_authorization
# Request ability to [capture beyond the standard authorization validity window](https://stripe.com/docs/payments/extended-authorization) for this PaymentIntent.
sig { returns(T.nilable(String)) }
attr_accessor :request_extended_authorization
# Request ability to [increment the authorization](https://stripe.com/docs/payments/incremental-authorization) for this PaymentIntent.
sig { returns(T.nilable(String)) }
attr_accessor :request_incremental_authorization
# Request ability to make [multiple captures](https://stripe.com/docs/payments/multicapture) for this PaymentIntent.
sig { returns(T.nilable(String)) }
attr_accessor :request_multicapture
# Request ability to [overcapture](https://stripe.com/docs/payments/overcapture) for this PaymentIntent.
sig { returns(T.nilable(String)) }
attr_accessor :request_overcapture
# Request partial authorization on this PaymentIntent.
sig { returns(T.nilable(String)) }
attr_accessor :request_partial_authorization
# We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. If not provided, this value defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
sig { returns(T.nilable(String)) }
attr_accessor :request_three_d_secure
# When enabled, using a card that is attached to a customer will require the CVC to be provided again (i.e. using the cvc_token parameter).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :require_cvc_recollection
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Provides information about a card payment that customers see on their statements. Concatenated with the Kana prefix (shortened Kana descriptor) or Kana statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 22 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 22 characters.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :statement_descriptor_suffix_kana
# Provides information about a card payment that customers see on their statements. Concatenated with the Kanji prefix (shortened Kanji descriptor) or Kanji statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 17 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 17 characters.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :statement_descriptor_suffix_kanji
# Statement details for this payment intent. You can use this to override the merchant details shown on your customers' statements.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Card::StatementDetails))))
}
attr_accessor :statement_details
# If 3D Secure authentication was performed with a third-party provider,
# the authentication details to use for this payment.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Card::ThreeDSecure))
}
attr_accessor :three_d_secure
sig {
params(capture_method: T.nilable(T.nilable(String)), cvc_token: T.nilable(String), installments: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Card::Installments), mandate_options: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Card::MandateOptions), moto: T.nilable(T::Boolean), network: T.nilable(String), request_decremental_authorization: T.nilable(String), request_extended_authorization: T.nilable(String), request_incremental_authorization: T.nilable(String), request_multicapture: T.nilable(String), request_overcapture: T.nilable(String), request_partial_authorization: T.nilable(String), request_three_d_secure: T.nilable(String), require_cvc_recollection: T.nilable(T::Boolean), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), statement_descriptor_suffix_kana: T.nilable(T.nilable(String)), statement_descriptor_suffix_kanji: T.nilable(T.nilable(String)), statement_details: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Card::StatementDetails))), three_d_secure: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Card::ThreeDSecure)).void
}
def initialize(
capture_method: nil,
cvc_token: nil,
installments: nil,
mandate_options: nil,
moto: nil,
network: nil,
request_decremental_authorization: nil,
request_extended_authorization: nil,
request_incremental_authorization: nil,
request_multicapture: nil,
request_overcapture: nil,
request_partial_authorization: nil,
request_three_d_secure: nil,
require_cvc_recollection: nil,
setup_future_usage: nil,
statement_descriptor_suffix_kana: nil,
statement_descriptor_suffix_kanji: nil,
statement_details: nil,
three_d_secure: nil
); end
end
class CardPresent < Stripe::RequestParams
class Routing < Stripe::RequestParams
# Routing requested priority
sig { returns(T.nilable(String)) }
attr_accessor :requested_priority
sig { params(requested_priority: T.nilable(String)).void }
def initialize(requested_priority: nil); end
end
# Request ability to capture this payment beyond the standard [authorization validity window](https://stripe.com/docs/terminal/features/extended-authorizations#authorization-validity)
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :request_extended_authorization
# Request ability to [increment](https://stripe.com/docs/terminal/features/incremental-authorizations) this PaymentIntent if the combination of MCC and card brand is eligible. Check [incremental_authorization_supported](https://stripe.com/docs/api/charges/object#charge_object-payment_method_details-card_present-incremental_authorization_supported) in the [Confirm](https://stripe.com/docs/api/payment_intents/confirm) response to verify support.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :request_incremental_authorization_support
# Network routing priority on co-branded EMV cards supporting domestic debit and international card schemes.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::CardPresent::Routing))
}
attr_accessor :routing
sig {
params(request_extended_authorization: T.nilable(T::Boolean), request_incremental_authorization_support: T.nilable(T::Boolean), routing: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::CardPresent::Routing)).void
}
def initialize(
request_extended_authorization: nil,
request_incremental_authorization_support: nil,
routing: nil
); end
end
class Cashapp < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class CustomerBalance < Stripe::RequestParams
class BankTransfer < Stripe::RequestParams
class EuBankTransfer < Stripe::RequestParams
# The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
sig { returns(String) }
attr_accessor :country
sig { params(country: String).void }
def initialize(country: nil); end
end
# Configuration for the eu_bank_transfer funding type.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::CustomerBalance::BankTransfer::EuBankTransfer))
}
attr_accessor :eu_bank_transfer
# List of address types that should be returned in the financial_addresses response. If not specified, all valid types will be returned.
#
# Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :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`, `mx_bank_transfer`, or `us_bank_transfer`.
sig { returns(String) }
attr_accessor :type
sig {
params(eu_bank_transfer: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::CustomerBalance::BankTransfer::EuBankTransfer), requested_address_types: T.nilable(T::Array[String]), type: String).void
}
def initialize(eu_bank_transfer: nil, requested_address_types: nil, type: nil); end
end
# Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::CustomerBalance::BankTransfer))
}
attr_accessor :bank_transfer
# The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
sig { returns(T.nilable(String)) }
attr_accessor :funding_type
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(bank_transfer: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::CustomerBalance::BankTransfer), funding_type: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(bank_transfer: nil, funding_type: nil, setup_future_usage: nil); end
end
class Eps < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Fpx < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Giropay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Gopay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Grabpay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class IdBankTransfer < Stripe::RequestParams
# The UNIX timestamp until which the virtual bank account is valid. Permitted range is from 5 minutes from now until 31 days from now. If unset, it defaults to 3 days from now.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_after
# The UNIX timestamp until which the virtual bank account is valid. Permitted range is from now until 30 days from now. If unset, it defaults to 1 days from now.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_at
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(expires_after: T.nilable(Integer), expires_at: T.nilable(Integer), setup_future_usage: T.nilable(String)).void
}
def initialize(expires_after: nil, expires_at: nil, setup_future_usage: nil); end
end
class Ideal < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void }
def initialize(setup_future_usage: nil); end
end
class InteracPresent < Stripe::RequestParams; end
class KakaoPay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class Klarna < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Preferred language of the Klarna authorization page that the customer is redirected to
sig { returns(T.nilable(String)) }
attr_accessor :preferred_locale
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), preferred_locale: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(capture_method: nil, preferred_locale: nil, setup_future_usage: nil); end
end
class Konbini < Stripe::RequestParams
# An optional 10 to 11 digit numeric-only string determining the confirmation code at applicable convenience stores. Must not consist of only zeroes and could be rejected in case of insufficient uniqueness. We recommend to use the customer's phone number.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :confirmation_number
# The number of calendar days (between 1 and 60) after which Konbini payment instructions will expire. For example, if a PaymentIntent is confirmed with Konbini and `expires_after_days` set to 2 on Monday JST, the instructions will expire on Wednesday 23:59:59 JST. Defaults to 3 days.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :expires_after_days
# The timestamp at which the Konbini payment instructions will expire. Only one of `expires_after_days` or `expires_at` may be set.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :expires_at
# A product descriptor of up to 22 characters, which will appear to customers at the convenience store.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :product_description
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(confirmation_number: T.nilable(T.nilable(String)), expires_after_days: T.nilable(T.nilable(T.any(String, Integer))), expires_at: T.nilable(T.nilable(T.any(String, Integer))), product_description: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(String)).void
}
def initialize(
confirmation_number: nil,
expires_after_days: nil,
expires_at: nil,
product_description: nil,
setup_future_usage: nil
); end
end
class KrCard < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class Link < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# [Deprecated] This is a legacy parameter that no longer has any function.
sig { returns(T.nilable(String)) }
attr_accessor :persistent_token
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), persistent_token: T.nilable(String), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(capture_method: nil, persistent_token: nil, setup_future_usage: nil); end
end
class MbWay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Mobilepay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(String)).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class Multibanco < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class NaverPay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class NzBankAccount < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
sig {
params(setup_future_usage: T.nilable(T.nilable(T.any(String, String))), target_date: T.nilable(String)).void
}
def initialize(setup_future_usage: nil, target_date: nil); end
end
class Oxxo < Stripe::RequestParams
# The number of calendar days before an OXXO voucher expires. For example, if you create an OXXO voucher on Monday and you set expires_after_days to 2, the OXXO invoice will expire on Wednesday at 23:59 America/Mexico_City time.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_after_days
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(expires_after_days: T.nilable(Integer), setup_future_usage: T.nilable(String)).void
}
def initialize(expires_after_days: nil, setup_future_usage: nil); end
end
class P24 < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
# Confirm that the payer has accepted the P24 terms and conditions.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :tos_shown_and_accepted
sig {
params(setup_future_usage: T.nilable(String), tos_shown_and_accepted: T.nilable(T::Boolean)).void
}
def initialize(setup_future_usage: nil, tos_shown_and_accepted: nil); end
end
class PayByBank < Stripe::RequestParams; end
class Payco < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
sig { params(capture_method: T.nilable(T.nilable(String))).void }
def initialize(capture_method: nil); end
end
class Paynow < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Paypal < Stripe::RequestParams
class LineItem < Stripe::RequestParams
class Tax < Stripe::RequestParams
# The tax for a single unit of the line item in minor units. Cannot be a negative number.
sig { returns(Integer) }
attr_accessor :amount
# The tax behavior for the line item.
sig { returns(String) }
attr_accessor :behavior
sig { params(amount: Integer, behavior: String).void }
def initialize(amount: nil, behavior: nil); end
end
# Type of the line item.
sig { returns(T.nilable(String)) }
attr_accessor :category
# Description of the line item.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Descriptive name of the line item.
sig { returns(String) }
attr_accessor :name
# Quantity of the line item. Must be a positive number.
sig { returns(Integer) }
attr_accessor :quantity
# Client facing stock keeping unit, article number or similar.
sig { returns(T.nilable(String)) }
attr_accessor :sku
# The Stripe account ID of the connected account that sells the item.
sig { returns(T.nilable(String)) }
attr_accessor :sold_by
# The tax information for the line item.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Paypal::LineItem::Tax))
}
attr_accessor :tax
# Price for a single unit of the line item in minor units. Cannot be a negative number.
sig { returns(Integer) }
attr_accessor :unit_amount
sig {
params(category: T.nilable(String), description: T.nilable(String), name: String, quantity: Integer, sku: T.nilable(String), sold_by: T.nilable(String), tax: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Paypal::LineItem::Tax), unit_amount: Integer).void
}
def initialize(
category: nil,
description: nil,
name: nil,
quantity: nil,
sku: nil,
sold_by: nil,
tax: nil,
unit_amount: nil
); end
end
# Controls when the funds will be captured from the customer's account.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# The line items purchased by the customer.
sig {
returns(T.nilable(T::Array[::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Paypal::LineItem]))
}
attr_accessor :line_items
# [Preferred locale](https://stripe.com/docs/payments/paypal/supported-locales) of the PayPal checkout page that the customer is redirected to.
sig { returns(T.nilable(String)) }
attr_accessor :preferred_locale
# A reference of the PayPal transaction visible to customer which is mapped to PayPal's invoice ID. This must be a globally unique ID if you have configured in your PayPal settings to block multiple payments per invoice ID.
sig { returns(T.nilable(String)) }
attr_accessor :reference
# A reference of the PayPal transaction visible to customer which is mapped to PayPal's invoice ID. This must be a globally unique ID if you have configured in your PayPal settings to block multiple payments per invoice ID.
sig { returns(T.nilable(String)) }
attr_accessor :reference_id
# The risk correlation ID for an on-session payment using a saved PayPal payment method.
sig { returns(T.nilable(String)) }
attr_accessor :risk_correlation_id
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# The Stripe connected account IDs of the sellers on the platform for this transaction (optional). Only allowed when [separate charges and transfers](https://stripe.com/docs/connect/separate-charges-and-transfers) are used.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :subsellers
sig {
params(capture_method: T.nilable(T.nilable(String)), line_items: T.nilable(T::Array[::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Paypal::LineItem]), preferred_locale: T.nilable(String), reference: T.nilable(String), reference_id: T.nilable(String), risk_correlation_id: T.nilable(String), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), subsellers: T.nilable(T::Array[String])).void
}
def initialize(
capture_method: nil,
line_items: nil,
preferred_locale: nil,
reference: nil,
reference_id: nil,
risk_correlation_id: nil,
setup_future_usage: nil,
subsellers: nil
); end
end
class Payto < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Amount that will be collected. It is required when `amount_type` is `fixed`.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# The type of amount that will be collected. The amount charged must be exact or up to the value of `amount` param for `fixed` or `maximum` type respectively.
sig { returns(T.nilable(String)) }
attr_accessor :amount_type
# Date, in YYYY-MM-DD format, after which payments will not be collected. Defaults to no end date.
sig { returns(T.nilable(String)) }
attr_accessor :end_date
# The periodicity at which payments will be collected.
sig { returns(T.nilable(String)) }
attr_accessor :payment_schedule
# The number of payments that will be made during a payment period. Defaults to 1 except for when `payment_schedule` is `adhoc`. In that case, it defaults to no limit.
sig { returns(T.nilable(Integer)) }
attr_accessor :payments_per_period
# The purpose for which payments are made. Defaults to retail.
sig { returns(T.nilable(String)) }
attr_accessor :purpose
sig {
params(amount: T.nilable(Integer), amount_type: T.nilable(String), end_date: T.nilable(String), payment_schedule: T.nilable(String), payments_per_period: T.nilable(Integer), purpose: T.nilable(String)).void
}
def initialize(
amount: nil,
amount_type: nil,
end_date: nil,
payment_schedule: nil,
payments_per_period: nil,
purpose: nil
); end
end
# Additional fields for Mandate creation. Only `purpose` field is configurable for PayTo PaymentIntent with `setup_future_usage=none`. Other fields are only applicable to PayTo PaymentIntent with `setup_future_usage=off_session`
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Payto::MandateOptions))
}
attr_accessor :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(mandate_options: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Payto::MandateOptions), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(mandate_options: nil, setup_future_usage: nil); end
end
class Pix < Stripe::RequestParams
# The number of seconds (between 10 and 1209600) after which Pix payment will expire. Defaults to 86400 seconds.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_after_seconds
# The timestamp at which the Pix expires (between 10 and 1209600 seconds in the future). Defaults to 1 day in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_at
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(expires_after_seconds: T.nilable(Integer), expires_at: T.nilable(Integer), setup_future_usage: T.nilable(String)).void
}
def initialize(expires_after_seconds: nil, expires_at: nil, setup_future_usage: nil); end
end
class Promptpay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Qris < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Rechnung < Stripe::RequestParams; end
class RevolutPay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class SamsungPay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
sig { params(capture_method: T.nilable(T.nilable(String))).void }
def initialize(capture_method: nil); end
end
class Satispay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
sig { params(capture_method: T.nilable(T.nilable(String))).void }
def initialize(capture_method: nil); end
end
class SepaDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'STRIPE'.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :reference_prefix
sig { params(reference_prefix: T.nilable(T.nilable(String))).void }
def initialize(reference_prefix: nil); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::SepaDebit::MandateOptions))
}
attr_accessor :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
sig {
params(mandate_options: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::SepaDebit::MandateOptions), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), target_date: T.nilable(String)).void
}
def initialize(mandate_options: nil, setup_future_usage: nil, target_date: nil); end
end
class Shopeepay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Sofort < Stripe::RequestParams
# Language shown to the payer on redirect.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :preferred_language
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(preferred_language: T.nilable(T.nilable(T.any(String, String))), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(preferred_language: nil, setup_future_usage: nil); end
end
class StripeBalance < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void }
def initialize(setup_future_usage: nil); end
end
class Swish < Stripe::RequestParams
# A reference for this payment to be displayed in the Swish app.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :reference
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(reference: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(String)).void
}
def initialize(reference: nil, setup_future_usage: nil); end
end
class Twint < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class UsBankAccount < Stripe::RequestParams
class FinancialConnections < Stripe::RequestParams
class Filters < Stripe::RequestParams
# The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :account_subcategories
# ID of the institution to use to filter for selectable accounts.
sig { returns(T.nilable(String)) }
attr_accessor :institution
sig {
params(account_subcategories: T.nilable(T::Array[String]), institution: T.nilable(String)).void
}
def initialize(account_subcategories: nil, institution: nil); end
end
class ManualEntry < Stripe::RequestParams
# Settings for configuring manual entry of account details.
sig { returns(String) }
attr_accessor :mode
sig { params(mode: String).void }
def initialize(mode: nil); end
end
# Provide filters for the linked accounts that the customer can select for the payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::Filters))
}
attr_accessor :filters
# Customize manual entry behavior
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::ManualEntry))
}
attr_accessor :manual_entry
# The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :permissions
# List of data features that you would like to retrieve upon account creation.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :prefetch
# For webview integrations only. Upon completing OAuth login in the native browser, the user will be redirected to this URL to return to your app.
sig { returns(T.nilable(String)) }
attr_accessor :return_url
sig {
params(filters: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::Filters), manual_entry: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::ManualEntry), permissions: T.nilable(T::Array[String]), prefetch: T.nilable(T::Array[String]), return_url: T.nilable(String)).void
}
def initialize(
filters: nil,
manual_entry: nil,
permissions: nil,
prefetch: nil,
return_url: nil
); end
end
class MandateOptions < Stripe::RequestParams
# The method used to collect offline mandate customer acceptance.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :collection_method
sig { params(collection_method: T.nilable(T.nilable(String))).void }
def initialize(collection_method: nil); end
end
class Networks < Stripe::RequestParams
# Triggers validations to run across the selected networks
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Array[String])).void }
def initialize(requested: nil); end
end
# Additional fields for Financial Connections Session creation
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections))
}
attr_accessor :financial_connections
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::UsBankAccount::MandateOptions))
}
attr_accessor :mandate_options
# Additional fields for network related functions
sig {
returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::UsBankAccount::Networks))
}
attr_accessor :networks
# Preferred transaction settlement speed
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :preferred_settlement_speed
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
# Bank account verification method.
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(financial_connections: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections), mandate_options: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::UsBankAccount::MandateOptions), networks: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::UsBankAccount::Networks), preferred_settlement_speed: T.nilable(T.nilable(T.any(String, String))), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), target_date: T.nilable(String), verification_method: T.nilable(String)).void
}
def initialize(
financial_connections: nil,
mandate_options: nil,
networks: nil,
preferred_settlement_speed: nil,
setup_future_usage: nil,
target_date: nil,
verification_method: nil
); end
end
class WechatPay < Stripe::RequestParams
# The app ID registered with WeChat Pay. Only required when client is ios or android.
sig { returns(T.nilable(String)) }
attr_accessor :app_id
# The client type that the end customer will pay from
sig { returns(T.nilable(String)) }
attr_accessor :client
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(app_id: T.nilable(String), client: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(app_id: nil, client: nil, setup_future_usage: nil); end
end
class Zip < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
# If this is a `acss_debit` PaymentMethod, this sub-hash contains details about the ACSS Debit payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::AcssDebit))))
}
attr_accessor :acss_debit
# If this is an `affirm` PaymentMethod, this sub-hash contains details about the Affirm payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Affirm))))
}
attr_accessor :affirm
# If this is a `afterpay_clearpay` PaymentMethod, this sub-hash contains details about the Afterpay Clearpay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::AfterpayClearpay))))
}
attr_accessor :afterpay_clearpay
# If this is a `alipay` PaymentMethod, this sub-hash contains details about the Alipay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Alipay))))
}
attr_accessor :alipay
# If this is a `alma` PaymentMethod, this sub-hash contains details about the Alma payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Alma))))
}
attr_accessor :alma
# If this is a `amazon_pay` PaymentMethod, this sub-hash contains details about the Amazon Pay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::AmazonPay))))
}
attr_accessor :amazon_pay
# If this is a `au_becs_debit` PaymentMethod, this sub-hash contains details about the AU BECS Direct Debit payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::AuBecsDebit))))
}
attr_accessor :au_becs_debit
# If this is a `bacs_debit` PaymentMethod, this sub-hash contains details about the BACS Debit payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::BacsDebit))))
}
attr_accessor :bacs_debit
# If this is a `bancontact` PaymentMethod, this sub-hash contains details about the Bancontact payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Bancontact))))
}
attr_accessor :bancontact
# If this is a `billie` PaymentMethod, this sub-hash contains details about the Billie payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Billie))))
}
attr_accessor :billie
# If this is a `blik` PaymentMethod, this sub-hash contains details about the BLIK payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Blik))))
}
attr_accessor :blik
# If this is a `boleto` PaymentMethod, this sub-hash contains details about the Boleto payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Boleto))))
}
attr_accessor :boleto
# Configuration for any card payments attempted on this PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Card))))
}
attr_accessor :card
# If this is a `card_present` PaymentMethod, this sub-hash contains details about the Card Present payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::CardPresent))))
}
attr_accessor :card_present
# If this is a `cashapp` PaymentMethod, this sub-hash contains details about the Cash App Pay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Cashapp))))
}
attr_accessor :cashapp
# If this is a `customer balance` PaymentMethod, this sub-hash contains details about the customer balance payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::CustomerBalance))))
}
attr_accessor :customer_balance
# If this is a `eps` PaymentMethod, this sub-hash contains details about the EPS payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Eps))))
}
attr_accessor :eps
# If this is a `fpx` PaymentMethod, this sub-hash contains details about the FPX payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Fpx))))
}
attr_accessor :fpx
# If this is a `giropay` PaymentMethod, this sub-hash contains details about the Giropay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Giropay))))
}
attr_accessor :giropay
# If this is a `gopay` PaymentMethod, this sub-hash contains details about the Gopay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Gopay))))
}
attr_accessor :gopay
# If this is a `grabpay` PaymentMethod, this sub-hash contains details about the Grabpay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Grabpay))))
}
attr_accessor :grabpay
# If this is a `id_bank_transfer` PaymentMethod, this sub-hash contains details about the Indonesia Bank Transfer payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::IdBankTransfer))))
}
attr_accessor :id_bank_transfer
# If this is a `ideal` PaymentMethod, this sub-hash contains details about the Ideal payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Ideal))))
}
attr_accessor :ideal
# If this is a `interac_present` PaymentMethod, this sub-hash contains details about the Card Present payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::InteracPresent))))
}
attr_accessor :interac_present
# If this is a `kakao_pay` PaymentMethod, this sub-hash contains details about the Kakao Pay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::KakaoPay))))
}
attr_accessor :kakao_pay
# If this is a `klarna` PaymentMethod, this sub-hash contains details about the Klarna payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Klarna))))
}
attr_accessor :klarna
# If this is a `konbini` PaymentMethod, this sub-hash contains details about the Konbini payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Konbini))))
}
attr_accessor :konbini
# If this is a `kr_card` PaymentMethod, this sub-hash contains details about the KR Card payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::KrCard))))
}
attr_accessor :kr_card
# If this is a `link` PaymentMethod, this sub-hash contains details about the Link payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Link))))
}
attr_accessor :link
# If this is a `mb_way` PaymentMethod, this sub-hash contains details about the MB WAY payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::MbWay))))
}
attr_accessor :mb_way
# If this is a `MobilePay` PaymentMethod, this sub-hash contains details about the MobilePay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Mobilepay))))
}
attr_accessor :mobilepay
# If this is a `multibanco` PaymentMethod, this sub-hash contains details about the Multibanco payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Multibanco))))
}
attr_accessor :multibanco
# If this is a `naver_pay` PaymentMethod, this sub-hash contains details about the Naver Pay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::NaverPay))))
}
attr_accessor :naver_pay
# If this is a `nz_bank_account` PaymentMethod, this sub-hash contains details about the NZ BECS Direct Debit payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::NzBankAccount))))
}
attr_accessor :nz_bank_account
# If this is a `oxxo` PaymentMethod, this sub-hash contains details about the OXXO payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Oxxo))))
}
attr_accessor :oxxo
# If this is a `p24` PaymentMethod, this sub-hash contains details about the Przelewy24 payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::P24))))
}
attr_accessor :p24
# If this is a `pay_by_bank` PaymentMethod, this sub-hash contains details about the PayByBank payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::PayByBank))))
}
attr_accessor :pay_by_bank
# If this is a `payco` PaymentMethod, this sub-hash contains details about the PAYCO payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Payco))))
}
attr_accessor :payco
# If this is a `paynow` PaymentMethod, this sub-hash contains details about the PayNow payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Paynow))))
}
attr_accessor :paynow
# If this is a `paypal` PaymentMethod, this sub-hash contains details about the PayPal payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Paypal))))
}
attr_accessor :paypal
# If this is a `payto` PaymentMethod, this sub-hash contains details about the PayTo payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Payto))))
}
attr_accessor :payto
# If this is a `pix` PaymentMethod, this sub-hash contains details about the Pix payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Pix))))
}
attr_accessor :pix
# If this is a `promptpay` PaymentMethod, this sub-hash contains details about the PromptPay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Promptpay))))
}
attr_accessor :promptpay
# If this is a `qris` PaymentMethod, this sub-hash contains details about the QRIS payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Qris))))
}
attr_accessor :qris
# If this is a `rechnung` PaymentMethod, this sub-hash contains details about the Rechnung payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Rechnung))))
}
attr_accessor :rechnung
# If this is a `revolut_pay` PaymentMethod, this sub-hash contains details about the Revolut Pay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::RevolutPay))))
}
attr_accessor :revolut_pay
# If this is a `samsung_pay` PaymentMethod, this sub-hash contains details about the Samsung Pay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::SamsungPay))))
}
attr_accessor :samsung_pay
# If this is a `satispay` PaymentMethod, this sub-hash contains details about the Satispay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Satispay))))
}
attr_accessor :satispay
# If this is a `sepa_debit` PaymentIntent, this sub-hash contains details about the SEPA Debit payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::SepaDebit))))
}
attr_accessor :sepa_debit
# If this is a `shopeepay` PaymentMethod, this sub-hash contains details about the ShopeePay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Shopeepay))))
}
attr_accessor :shopeepay
# If this is a `sofort` PaymentMethod, this sub-hash contains details about the SOFORT payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Sofort))))
}
attr_accessor :sofort
# If this is a `stripe_balance` PaymentMethod, this sub-hash contains details about the Stripe Balance payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::StripeBalance))))
}
attr_accessor :stripe_balance
# If this is a `Swish` PaymentMethod, this sub-hash contains details about the Swish payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Swish))))
}
attr_accessor :swish
# If this is a `twint` PaymentMethod, this sub-hash contains details about the TWINT payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Twint))))
}
attr_accessor :twint
# If this is a `us_bank_account` PaymentMethod, this sub-hash contains details about the US bank account payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::UsBankAccount))))
}
attr_accessor :us_bank_account
# If this is a `wechat_pay` PaymentMethod, this sub-hash contains details about the WeChat Pay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::WechatPay))))
}
attr_accessor :wechat_pay
# If this is a `zip` PaymentMethod, this sub-hash contains details about the Zip payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Zip))))
}
attr_accessor :zip
sig {
params(acss_debit: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::AcssDebit))), affirm: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Affirm))), afterpay_clearpay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::AfterpayClearpay))), alipay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Alipay))), alma: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Alma))), amazon_pay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::AmazonPay))), au_becs_debit: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::AuBecsDebit))), bacs_debit: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::BacsDebit))), bancontact: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Bancontact))), billie: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Billie))), blik: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Blik))), boleto: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Boleto))), card: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Card))), card_present: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::CardPresent))), cashapp: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Cashapp))), customer_balance: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::CustomerBalance))), eps: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Eps))), fpx: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Fpx))), giropay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Giropay))), gopay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Gopay))), grabpay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Grabpay))), id_bank_transfer: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::IdBankTransfer))), ideal: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Ideal))), interac_present: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::InteracPresent))), kakao_pay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::KakaoPay))), klarna: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Klarna))), konbini: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Konbini))), kr_card: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::KrCard))), link: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Link))), mb_way: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::MbWay))), mobilepay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Mobilepay))), multibanco: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Multibanco))), naver_pay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::NaverPay))), nz_bank_account: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::NzBankAccount))), oxxo: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Oxxo))), p24: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::P24))), pay_by_bank: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::PayByBank))), payco: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Payco))), paynow: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Paynow))), paypal: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Paypal))), payto: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Payto))), pix: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Pix))), promptpay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Promptpay))), qris: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Qris))), rechnung: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Rechnung))), revolut_pay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::RevolutPay))), samsung_pay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::SamsungPay))), satispay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Satispay))), sepa_debit: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::SepaDebit))), shopeepay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Shopeepay))), sofort: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Sofort))), stripe_balance: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::StripeBalance))), swish: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Swish))), twint: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Twint))), us_bank_account: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::UsBankAccount))), wechat_pay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::WechatPay))), zip: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions::Zip)))).void
}
def initialize(
acss_debit: nil,
affirm: nil,
afterpay_clearpay: nil,
alipay: nil,
alma: nil,
amazon_pay: nil,
au_becs_debit: nil,
bacs_debit: nil,
bancontact: nil,
billie: nil,
blik: nil,
boleto: nil,
card: nil,
card_present: nil,
cashapp: nil,
customer_balance: nil,
eps: nil,
fpx: nil,
giropay: nil,
gopay: nil,
grabpay: nil,
id_bank_transfer: nil,
ideal: nil,
interac_present: nil,
kakao_pay: nil,
klarna: nil,
konbini: nil,
kr_card: nil,
link: nil,
mb_way: nil,
mobilepay: nil,
multibanco: nil,
naver_pay: nil,
nz_bank_account: nil,
oxxo: nil,
p24: nil,
pay_by_bank: nil,
payco: nil,
paynow: nil,
paypal: nil,
payto: nil,
pix: nil,
promptpay: nil,
qris: nil,
rechnung: nil,
revolut_pay: nil,
samsung_pay: nil,
satispay: nil,
sepa_debit: nil,
shopeepay: nil,
sofort: nil,
stripe_balance: nil,
swish: nil,
twint: nil,
us_bank_account: nil,
wechat_pay: nil,
zip: nil
); end
end
class Shipping < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Shipping address.
sig { returns(::Stripe::PaymentIntent::UpdateParams::Shipping::Address) }
attr_accessor :address
# The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
sig { returns(T.nilable(String)) }
attr_accessor :carrier
# Recipient name.
sig { returns(String) }
attr_accessor :name
# Recipient phone (including extension).
sig { returns(T.nilable(String)) }
attr_accessor :phone
# The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
sig { returns(T.nilable(String)) }
attr_accessor :tracking_number
sig {
params(address: ::Stripe::PaymentIntent::UpdateParams::Shipping::Address, carrier: T.nilable(String), name: String, phone: T.nilable(String), tracking_number: T.nilable(String)).void
}
def initialize(address: nil, carrier: nil, name: nil, phone: nil, tracking_number: nil); end
end
class TransferData < Stripe::RequestParams
# The amount that will be transferred automatically when a charge succeeds.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
sig { params(amount: T.nilable(Integer)).void }
def initialize(amount: nil); end
end
# Amount intended to be collected by this PaymentIntent. A positive integer representing how much to charge in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is $0.50 US or [equivalent in charge currency](https://stripe.com/docs/currencies#minimum-and-maximum-charge-amounts). The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99).
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. The amount of the application fee collected will be capped at the total amount captured. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :application_fee_amount
# Controls when the funds will be captured from the customer's account.
sig { returns(T.nilable(String)) }
attr_accessor :capture_method
# 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).
sig { returns(T.nilable(String)) }
attr_accessor :currency
# ID of the Customer this PaymentIntent belongs to, if one exists.
#
# Payment methods attached to other Customers cannot be used with this PaymentIntent.
#
# If [setup_future_usage](https://stripe.com/docs/api#payment_intent_object-setup_future_usage) is set and this PaymentIntent's payment method is not `card_present`, then the payment method attaches to the Customer after the PaymentIntent has been confirmed and any required actions from the user are complete. If the payment method is `card_present` and isn't a digital wallet, then a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card is created and attached to the Customer instead.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# ID of the Account this PaymentIntent belongs to, if one exists.
#
# Payment methods attached to other Accounts cannot be used with this PaymentIntent.
#
# If [setup_future_usage](https://stripe.com/docs/api#payment_intent_object-setup_future_usage) is set and this PaymentIntent's payment method is not `card_present`, then the payment method attaches to the Account after the PaymentIntent has been confirmed and any required actions from the user are complete. If the payment method is `card_present` and isn't a digital wallet, then a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card is created and attached to the Account instead.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The FX rate in the quote is validated and used to convert the presentment amount to the settlement amount.
sig { returns(T.nilable(String)) }
attr_accessor :fx_quote
# Automations to be run during the PaymentIntent lifecycle
sig { returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::Hooks)) }
attr_accessor :hooks
# This hash contains details about the Mandate to create.
sig { returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::MandateData)) }
attr_accessor :mandate_data
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Provides industry-specific information about the charge.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentDetails))))
}
attr_accessor :payment_details
# Attribute for param field payment_method
sig { returns(T.nilable(String)) }
attr_accessor :payment_method
# The ID of the [payment method configuration](https://stripe.com/docs/api/payment_method_configurations) to use with this PaymentIntent.
sig { returns(T.nilable(String)) }
attr_accessor :payment_method_configuration
# If provided, this hash will be used to create a PaymentMethod. The new PaymentMethod will appear
# in the [payment_method](https://stripe.com/docs/api/payment_intents/object#payment_intent_object-payment_method)
# property on the PaymentIntent.
sig { returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData)) }
attr_accessor :payment_method_data
# Payment-method-specific configuration for this PaymentIntent.
sig { returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions)) }
attr_accessor :payment_method_options
# The list of payment method types (for example, card) that this PaymentIntent can use. Use `automatic_payment_methods` to manage payment methods from the [Stripe Dashboard](https://dashboard.stripe.com/settings/payment_methods).
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :payment_method_types
# Email address that the receipt for the resulting payment will be sent to. If `receipt_email` is specified for a payment in live mode, a receipt will be sent regardless of your [email settings](https://dashboard.stripe.com/account/emails).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :receipt_email
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Shipping information for this PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::Shipping))))
}
attr_accessor :shipping
# Text that appears on the customer's statement as the statement descriptor for a non-card charge. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
#
# Setting this value for a card charge returns an error. For card charges, set the [statement_descriptor_suffix](https://docs.stripe.com/get-started/account/statement-descriptors#dynamic) instead.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
# Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor_suffix
# Use this parameter to automatically create a Transfer when the payment succeeds. Learn more about the [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
sig { returns(T.nilable(::Stripe::PaymentIntent::UpdateParams::TransferData)) }
attr_accessor :transfer_data
# A string that identifies the resulting payment as part of a group. You can only provide `transfer_group` if it hasn't been set. Learn more about the [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
sig { returns(T.nilable(String)) }
attr_accessor :transfer_group
sig {
params(amount: T.nilable(Integer), application_fee_amount: T.nilable(T.nilable(T.any(String, Integer))), capture_method: T.nilable(String), currency: T.nilable(String), customer: T.nilable(String), customer_account: T.nilable(String), description: T.nilable(String), expand: T.nilable(T::Array[String]), fx_quote: T.nilable(String), hooks: T.nilable(::Stripe::PaymentIntent::UpdateParams::Hooks), mandate_data: T.nilable(::Stripe::PaymentIntent::UpdateParams::MandateData), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), payment_details: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::PaymentDetails))), payment_method: T.nilable(String), payment_method_configuration: T.nilable(String), payment_method_data: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodData), payment_method_options: T.nilable(::Stripe::PaymentIntent::UpdateParams::PaymentMethodOptions), payment_method_types: T.nilable(T::Array[String]), receipt_email: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), shipping: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::UpdateParams::Shipping))), statement_descriptor: T.nilable(String), statement_descriptor_suffix: T.nilable(String), transfer_data: T.nilable(::Stripe::PaymentIntent::UpdateParams::TransferData), transfer_group: T.nilable(String)).void
}
def initialize(
amount: nil,
application_fee_amount: nil,
capture_method: nil,
currency: nil,
customer: nil,
customer_account: nil,
description: nil,
expand: nil,
fx_quote: nil,
hooks: nil,
mandate_data: nil,
metadata: nil,
payment_details: nil,
payment_method: nil,
payment_method_configuration: nil,
payment_method_data: nil,
payment_method_options: nil,
payment_method_types: nil,
receipt_email: nil,
setup_future_usage: nil,
shipping: nil,
statement_descriptor: nil,
statement_descriptor_suffix: nil,
transfer_data: nil,
transfer_group: nil
); end
end
class SearchParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for pagination across multiple pages of results. Don't include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.
sig { returns(T.nilable(String)) }
attr_accessor :page
# The search query string. See [search query language](https://stripe.com/docs/search#search-query-language) and the list of supported [query fields for payment intents](https://stripe.com/docs/search#query-fields-for-payment-intents).
sig { returns(String) }
attr_accessor :query
sig {
params(expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), page: T.nilable(String), query: String).void
}
def initialize(expand: nil, limit: nil, page: nil, query: nil); end
end
class ApplyCustomerBalanceParams < Stripe::RequestParams
# Amount that you intend to apply to this PaymentIntent from the customer’s cash balance. If the PaymentIntent was created by an Invoice, the full amount of the PaymentIntent is applied regardless of this parameter.
#
# A positive integer representing how much to charge in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (for example, 100 cents to charge 1 USD or 100 to charge 100 JPY, a zero-decimal currency). The maximum amount is the amount of the PaymentIntent.
#
# When you omit the amount, it defaults to the remaining amount requested on the PaymentIntent.
sig { returns(T.nilable(Integer)) }
attr_accessor :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).
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig {
params(amount: T.nilable(Integer), currency: T.nilable(String), expand: T.nilable(T::Array[String])).void
}
def initialize(amount: nil, currency: nil, expand: nil); end
end
class CancelParams < Stripe::RequestParams
# Reason for canceling this PaymentIntent. Possible values are: `duplicate`, `fraudulent`, `requested_by_customer`, or `abandoned`
sig { returns(T.nilable(String)) }
attr_accessor :cancellation_reason
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig {
params(cancellation_reason: T.nilable(String), expand: T.nilable(T::Array[String])).void
}
def initialize(cancellation_reason: nil, expand: nil); end
end
class CaptureParams < Stripe::RequestParams
class Hooks < Stripe::RequestParams
class Inputs < Stripe::RequestParams
class Tax < Stripe::RequestParams
# The [TaxCalculation](https://stripe.com/docs/api/tax/calculations) id
sig { returns(T.nilable(String)) }
attr_accessor :calculation
sig { params(calculation: T.nilable(String)).void }
def initialize(calculation: nil); end
end
# Tax arguments for automations
sig { returns(T.nilable(::Stripe::PaymentIntent::CaptureParams::Hooks::Inputs::Tax)) }
attr_accessor :tax
sig {
params(tax: T.nilable(::Stripe::PaymentIntent::CaptureParams::Hooks::Inputs::Tax)).void
}
def initialize(tax: nil); end
end
# Arguments passed in automations
sig { returns(T.nilable(::Stripe::PaymentIntent::CaptureParams::Hooks::Inputs)) }
attr_accessor :inputs
sig {
params(inputs: T.nilable(::Stripe::PaymentIntent::CaptureParams::Hooks::Inputs)).void
}
def initialize(inputs: nil); end
end
class PaymentDetails < Stripe::RequestParams
class CarRental < Stripe::RequestParams
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::CarRental::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::CarRental::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
class Distance < Stripe::RequestParams
# Distance traveled.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# Unit of measurement for the distance traveled. One of `miles` or `kilometers`.
sig { returns(T.nilable(String)) }
attr_accessor :unit
sig { params(amount: T.nilable(Integer), unit: T.nilable(String)).void }
def initialize(amount: nil, unit: nil); end
end
class Driver < Stripe::RequestParams
# Driver's identification number.
sig { returns(T.nilable(String)) }
attr_accessor :driver_identification_number
# Driver's tax number.
sig { returns(T.nilable(String)) }
attr_accessor :driver_tax_number
# Full name of the person or entity on the car reservation.
sig { returns(String) }
attr_accessor :name
sig {
params(driver_identification_number: T.nilable(String), driver_tax_number: T.nilable(String), name: String).void
}
def initialize(
driver_identification_number: nil,
driver_tax_number: nil,
name: nil
); end
end
class PickupAddress < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class ReturnAddress < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::CarRental::Affiliate))
}
attr_accessor :affiliate
# The booking number associated with the car rental.
sig { returns(String) }
attr_accessor :booking_number
# Class code of the car.
sig { returns(T.nilable(String)) }
attr_accessor :car_class_code
# Make of the car.
sig { returns(T.nilable(String)) }
attr_accessor :car_make
# Model of the car.
sig { returns(T.nilable(String)) }
attr_accessor :car_model
# The name of the rental car company.
sig { returns(T.nilable(String)) }
attr_accessor :company
# The customer service phone number of the car rental company.
sig { returns(T.nilable(String)) }
attr_accessor :customer_service_phone_number
# Number of days the car is being rented.
sig { returns(Integer) }
attr_accessor :days_rented
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::CarRental::Delivery))
}
attr_accessor :delivery
# The details of the distance traveled during the rental period.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::CarRental::Distance))
}
attr_accessor :distance
# The details of the passengers in the travel reservation
sig {
returns(T.nilable(T::Array[::Stripe::PaymentIntent::CaptureParams::PaymentDetails::CarRental::Driver]))
}
attr_accessor :drivers
# List of additional charges being billed.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :extra_charges
# Indicates if the customer did not keep nor cancel their booking.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :no_show
# Car pick-up address.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::CarRental::PickupAddress))
}
attr_accessor :pickup_address
# Car pick-up time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :pickup_at
# Name of the pickup location.
sig { returns(T.nilable(String)) }
attr_accessor :pickup_location_name
# Rental rate.
sig { returns(T.nilable(Integer)) }
attr_accessor :rate_amount
# The frequency at which the rate amount is applied. One of `day`, `week` or `month`
sig { returns(T.nilable(String)) }
attr_accessor :rate_interval
# The name of the person or entity renting the car.
sig { returns(T.nilable(String)) }
attr_accessor :renter_name
# Car return address.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::CarRental::ReturnAddress))
}
attr_accessor :return_address
# Car return time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :return_at
# Name of the return location.
sig { returns(T.nilable(String)) }
attr_accessor :return_location_name
# Indicates whether the goods or services are tax-exempt or tax is not collected.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :tax_exempt
# The vehicle identification number.
sig { returns(T.nilable(String)) }
attr_accessor :vehicle_identification_number
sig {
params(affiliate: T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::CarRental::Affiliate), booking_number: String, car_class_code: T.nilable(String), car_make: T.nilable(String), car_model: T.nilable(String), company: T.nilable(String), customer_service_phone_number: T.nilable(String), days_rented: Integer, delivery: T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::CarRental::Delivery), distance: T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::CarRental::Distance), drivers: T.nilable(T::Array[::Stripe::PaymentIntent::CaptureParams::PaymentDetails::CarRental::Driver]), extra_charges: T.nilable(T::Array[String]), no_show: T.nilable(T::Boolean), pickup_address: T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::CarRental::PickupAddress), pickup_at: Integer, pickup_location_name: T.nilable(String), rate_amount: T.nilable(Integer), rate_interval: T.nilable(String), renter_name: T.nilable(String), return_address: T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::CarRental::ReturnAddress), return_at: Integer, return_location_name: T.nilable(String), tax_exempt: T.nilable(T::Boolean), vehicle_identification_number: T.nilable(String)).void
}
def initialize(
affiliate: nil,
booking_number: nil,
car_class_code: nil,
car_make: nil,
car_model: nil,
company: nil,
customer_service_phone_number: nil,
days_rented: nil,
delivery: nil,
distance: nil,
drivers: nil,
extra_charges: nil,
no_show: nil,
pickup_address: nil,
pickup_at: nil,
pickup_location_name: nil,
rate_amount: nil,
rate_interval: nil,
renter_name: nil,
return_address: nil,
return_at: nil,
return_location_name: nil,
tax_exempt: nil,
vehicle_identification_number: nil
); end
end
class EventDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::EventDetails::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::EventDetails::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
# Indicates if the tickets are digitally checked when entering the venue.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :access_controlled_venue
# The event location's address.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::EventDetails::Address))
}
attr_accessor :address
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::EventDetails::Affiliate))
}
attr_accessor :affiliate
# The name of the company
sig { returns(T.nilable(String)) }
attr_accessor :company
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::EventDetails::Delivery))
}
attr_accessor :delivery
# Event end time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :ends_at
# Type of the event entertainment (concert, sports event etc)
sig { returns(T.nilable(String)) }
attr_accessor :genre
# The name of the event.
sig { returns(String) }
attr_accessor :name
# Event start time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :starts_at
sig {
params(access_controlled_venue: T.nilable(T::Boolean), address: T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::EventDetails::Address), affiliate: T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::EventDetails::Affiliate), company: T.nilable(String), delivery: T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::EventDetails::Delivery), ends_at: T.nilable(Integer), genre: T.nilable(String), name: String, starts_at: T.nilable(Integer)).void
}
def initialize(
access_controlled_venue: nil,
address: nil,
affiliate: nil,
company: nil,
delivery: nil,
ends_at: nil,
genre: nil,
name: nil,
starts_at: nil
); end
end
class Flight < Stripe::RequestParams
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::Flight::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::Flight::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
class Passenger < Stripe::RequestParams
# Full name of the person or entity on the flight reservation.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Segment < Stripe::RequestParams
# The flight segment amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# The International Air Transport Association (IATA) airport code for the arrival airport.
sig { returns(T.nilable(String)) }
attr_accessor :arrival_airport
# The arrival time for the flight segment. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :arrives_at
# The International Air Transport Association (IATA) carrier code of the carrier operating the flight segment.
sig { returns(T.nilable(String)) }
attr_accessor :carrier
# The departure time for the flight segment. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :departs_at
# The International Air Transport Association (IATA) airport code for the departure airport.
sig { returns(T.nilable(String)) }
attr_accessor :departure_airport
# The flight number associated with the segment
sig { returns(T.nilable(String)) }
attr_accessor :flight_number
# The fare class for the segment.
sig { returns(T.nilable(String)) }
attr_accessor :service_class
sig {
params(amount: T.nilable(Integer), arrival_airport: T.nilable(String), arrives_at: T.nilable(Integer), carrier: T.nilable(String), departs_at: Integer, departure_airport: T.nilable(String), flight_number: T.nilable(String), service_class: T.nilable(String)).void
}
def initialize(
amount: nil,
arrival_airport: nil,
arrives_at: nil,
carrier: nil,
departs_at: nil,
departure_airport: nil,
flight_number: nil,
service_class: nil
); end
end
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::Flight::Affiliate))
}
attr_accessor :affiliate
# The agency number (i.e. International Air Transport Association (IATA) agency number) of the travel agency that made the booking.
sig { returns(T.nilable(String)) }
attr_accessor :agency_number
# The International Air Transport Association (IATA) carrier code of the carrier that issued the ticket.
sig { returns(T.nilable(String)) }
attr_accessor :carrier
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::Flight::Delivery))
}
attr_accessor :delivery
# The name of the person or entity on the reservation.
sig { returns(T.nilable(String)) }
attr_accessor :passenger_name
# The details of the passengers in the travel reservation.
sig {
returns(T.nilable(T::Array[::Stripe::PaymentIntent::CaptureParams::PaymentDetails::Flight::Passenger]))
}
attr_accessor :passengers
# The individual flight segments associated with the trip.
sig {
returns(T::Array[::Stripe::PaymentIntent::CaptureParams::PaymentDetails::Flight::Segment])
}
attr_accessor :segments
# The ticket number associated with the travel reservation.
sig { returns(T.nilable(String)) }
attr_accessor :ticket_number
sig {
params(affiliate: T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::Flight::Affiliate), agency_number: T.nilable(String), carrier: T.nilable(String), delivery: T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::Flight::Delivery), passenger_name: T.nilable(String), passengers: T.nilable(T::Array[::Stripe::PaymentIntent::CaptureParams::PaymentDetails::Flight::Passenger]), segments: T::Array[::Stripe::PaymentIntent::CaptureParams::PaymentDetails::Flight::Segment], ticket_number: T.nilable(String)).void
}
def initialize(
affiliate: nil,
agency_number: nil,
carrier: nil,
delivery: nil,
passenger_name: nil,
passengers: nil,
segments: nil,
ticket_number: nil
); end
end
class Lodging < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::Lodging::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::Lodging::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
class Passenger < Stripe::RequestParams
# Full name of the person or entity on the lodging reservation.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
# The lodging location's address.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::Lodging::Address))
}
attr_accessor :address
# The number of adults on the booking
sig { returns(T.nilable(Integer)) }
attr_accessor :adults
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::Lodging::Affiliate))
}
attr_accessor :affiliate
# The booking number associated with the lodging reservation.
sig { returns(T.nilable(String)) }
attr_accessor :booking_number
# The lodging category
sig { returns(T.nilable(String)) }
attr_accessor :category
# Lodging check-in time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :checkin_at
# Lodging check-out time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :checkout_at
# The customer service phone number of the lodging company.
sig { returns(T.nilable(String)) }
attr_accessor :customer_service_phone_number
# The daily lodging room rate.
sig { returns(T.nilable(Integer)) }
attr_accessor :daily_room_rate_amount
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::Lodging::Delivery))
}
attr_accessor :delivery
# List of additional charges being billed.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :extra_charges
# Indicates whether the lodging location is compliant with the Fire Safety Act.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :fire_safety_act_compliance
# The name of the lodging location.
sig { returns(T.nilable(String)) }
attr_accessor :name
# Indicates if the customer did not keep their booking while failing to cancel the reservation.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :no_show
# The number of rooms on the booking
sig { returns(T.nilable(Integer)) }
attr_accessor :number_of_rooms
# The details of the passengers in the travel reservation
sig {
returns(T.nilable(T::Array[::Stripe::PaymentIntent::CaptureParams::PaymentDetails::Lodging::Passenger]))
}
attr_accessor :passengers
# The phone number of the lodging location.
sig { returns(T.nilable(String)) }
attr_accessor :property_phone_number
# The room class for this purchase.
sig { returns(T.nilable(String)) }
attr_accessor :room_class
# The number of room nights
sig { returns(T.nilable(Integer)) }
attr_accessor :room_nights
# The total tax amount associating with the room reservation.
sig { returns(T.nilable(Integer)) }
attr_accessor :total_room_tax_amount
# The total tax amount
sig { returns(T.nilable(Integer)) }
attr_accessor :total_tax_amount
sig {
params(address: T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::Lodging::Address), adults: T.nilable(Integer), affiliate: T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::Lodging::Affiliate), booking_number: T.nilable(String), category: T.nilable(String), checkin_at: Integer, checkout_at: Integer, customer_service_phone_number: T.nilable(String), daily_room_rate_amount: T.nilable(Integer), delivery: T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::Lodging::Delivery), extra_charges: T.nilable(T::Array[String]), fire_safety_act_compliance: T.nilable(T::Boolean), name: T.nilable(String), no_show: T.nilable(T::Boolean), number_of_rooms: T.nilable(Integer), passengers: T.nilable(T::Array[::Stripe::PaymentIntent::CaptureParams::PaymentDetails::Lodging::Passenger]), property_phone_number: T.nilable(String), room_class: T.nilable(String), room_nights: T.nilable(Integer), total_room_tax_amount: T.nilable(Integer), total_tax_amount: T.nilable(Integer)).void
}
def initialize(
address: nil,
adults: nil,
affiliate: nil,
booking_number: nil,
category: nil,
checkin_at: nil,
checkout_at: nil,
customer_service_phone_number: nil,
daily_room_rate_amount: nil,
delivery: nil,
extra_charges: nil,
fire_safety_act_compliance: nil,
name: nil,
no_show: nil,
number_of_rooms: nil,
passengers: nil,
property_phone_number: nil,
room_class: nil,
room_nights: nil,
total_room_tax_amount: nil,
total_tax_amount: nil
); end
end
class Subscription < Stripe::RequestParams
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class BillingInterval < Stripe::RequestParams
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :count
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
sig { params(count: Integer, interval: String).void }
def initialize(count: nil, interval: nil); end
end
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::Subscription::Affiliate))
}
attr_accessor :affiliate
# Info whether the subscription will be auto renewed upon expiry.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :auto_renewal
# Subscription billing details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::Subscription::BillingInterval))
}
attr_accessor :billing_interval
# Subscription end time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :ends_at
# Name of the product on subscription. e.g. Apple Music Subscription
sig { returns(String) }
attr_accessor :name
# Subscription start time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :starts_at
sig {
params(affiliate: T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::Subscription::Affiliate), auto_renewal: T.nilable(T::Boolean), billing_interval: T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::Subscription::BillingInterval), ends_at: T.nilable(Integer), name: String, starts_at: T.nilable(Integer)).void
}
def initialize(
affiliate: nil,
auto_renewal: nil,
billing_interval: nil,
ends_at: nil,
name: nil,
starts_at: nil
); end
end
# Car rental details for this PaymentIntent.
sig {
returns(T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::CarRental))
}
attr_accessor :car_rental
# Some customers might be required by their company or organization to provide this information. If so, provide this value. Otherwise you can ignore this field.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :customer_reference
# Event details for this PaymentIntent
sig {
returns(T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::EventDetails))
}
attr_accessor :event_details
# Flight reservation details for this PaymentIntent
sig { returns(T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::Flight)) }
attr_accessor :flight
# Lodging reservation details for this PaymentIntent
sig { returns(T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::Lodging)) }
attr_accessor :lodging
# A unique value assigned by the business to identify the transaction.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :order_reference
# Subscription details for this PaymentIntent
sig {
returns(T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::Subscription))
}
attr_accessor :subscription
sig {
params(car_rental: T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::CarRental), customer_reference: T.nilable(T.nilable(String)), event_details: T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::EventDetails), flight: T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::Flight), lodging: T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::Lodging), order_reference: T.nilable(T.nilable(String)), subscription: T.nilable(::Stripe::PaymentIntent::CaptureParams::PaymentDetails::Subscription)).void
}
def initialize(
car_rental: nil,
customer_reference: nil,
event_details: nil,
flight: nil,
lodging: nil,
order_reference: nil,
subscription: nil
); end
end
class TransferData < Stripe::RequestParams
# The amount that will be transferred automatically when a charge succeeds.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
sig { params(amount: T.nilable(Integer)).void }
def initialize(amount: nil); end
end
# The amount to capture from the PaymentIntent, which must be less than or equal to the original amount. Defaults to the full `amount_capturable` if it's not provided.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount_to_capture
# The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. The amount of the application fee collected will be capped at the total amount captured. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
sig { returns(T.nilable(Integer)) }
attr_accessor :application_fee_amount
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Defaults to `true`. When capturing a PaymentIntent, setting `final_capture` to `false` notifies Stripe to not release the remaining uncaptured funds to make sure that they're captured in future requests. You can only use this setting when [multicapture](https://stripe.com/docs/payments/multicapture) is available for PaymentIntents.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :final_capture
# Automations to be run during the PaymentIntent lifecycle
sig { returns(T.nilable(::Stripe::PaymentIntent::CaptureParams::Hooks)) }
attr_accessor :hooks
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Provides industry-specific information about the charge.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CaptureParams::PaymentDetails))))
}
attr_accessor :payment_details
# Text that appears on the customer's statement as the statement descriptor for a non-card charge. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
#
# Setting this value for a card charge returns an error. For card charges, set the [statement_descriptor_suffix](https://docs.stripe.com/get-started/account/statement-descriptors#dynamic) instead.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
# Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor_suffix
# The parameters that you can use to automatically create a transfer after the payment
# is captured. Learn more about the [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
sig { returns(T.nilable(::Stripe::PaymentIntent::CaptureParams::TransferData)) }
attr_accessor :transfer_data
sig {
params(amount_to_capture: T.nilable(Integer), application_fee_amount: T.nilable(Integer), expand: T.nilable(T::Array[String]), final_capture: T.nilable(T::Boolean), hooks: T.nilable(::Stripe::PaymentIntent::CaptureParams::Hooks), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), payment_details: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::CaptureParams::PaymentDetails))), statement_descriptor: T.nilable(String), statement_descriptor_suffix: T.nilable(String), transfer_data: T.nilable(::Stripe::PaymentIntent::CaptureParams::TransferData)).void
}
def initialize(
amount_to_capture: nil,
application_fee_amount: nil,
expand: nil,
final_capture: nil,
hooks: nil,
metadata: nil,
payment_details: nil,
statement_descriptor: nil,
statement_descriptor_suffix: nil,
transfer_data: nil
); end
end
class ConfirmParams < Stripe::RequestParams
class Hooks < Stripe::RequestParams
class Inputs < Stripe::RequestParams
class Tax < Stripe::RequestParams
# The [TaxCalculation](https://stripe.com/docs/api/tax/calculations) id
sig { returns(T.nilable(String)) }
attr_accessor :calculation
sig { params(calculation: T.nilable(String)).void }
def initialize(calculation: nil); end
end
# Tax arguments for automations
sig { returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::Hooks::Inputs::Tax)) }
attr_accessor :tax
sig {
params(tax: T.nilable(::Stripe::PaymentIntent::ConfirmParams::Hooks::Inputs::Tax)).void
}
def initialize(tax: nil); end
end
# Arguments passed in automations
sig { returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::Hooks::Inputs)) }
attr_accessor :inputs
sig {
params(inputs: T.nilable(::Stripe::PaymentIntent::ConfirmParams::Hooks::Inputs)).void
}
def initialize(inputs: nil); end
end
class MandateData < Stripe::RequestParams
class CustomerAcceptance < Stripe::RequestParams
class Offline < Stripe::RequestParams; end
class Online < Stripe::RequestParams
# The IP address from which the Mandate was accepted by the customer.
sig { returns(T.nilable(String)) }
attr_accessor :ip_address
# The user agent of the browser from which the Mandate was accepted by the customer.
sig { returns(T.nilable(String)) }
attr_accessor :user_agent
sig { params(ip_address: T.nilable(String), user_agent: T.nilable(String)).void }
def initialize(ip_address: nil, user_agent: nil); end
end
# The time at which the customer accepted the Mandate.
sig { returns(T.nilable(Integer)) }
attr_accessor :accepted_at
# If this is a Mandate accepted offline, this hash contains details about the offline acceptance.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::MandateData::CustomerAcceptance::Offline))
}
attr_accessor :offline
# If this is a Mandate accepted online, this hash contains details about the online acceptance.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::MandateData::CustomerAcceptance::Online))
}
attr_accessor :online
# The type of customer acceptance information included with the Mandate. One of `online` or `offline`.
sig { returns(String) }
attr_accessor :type
sig {
params(accepted_at: T.nilable(Integer), offline: T.nilable(::Stripe::PaymentIntent::ConfirmParams::MandateData::CustomerAcceptance::Offline), online: T.nilable(::Stripe::PaymentIntent::ConfirmParams::MandateData::CustomerAcceptance::Online), type: String).void
}
def initialize(accepted_at: nil, offline: nil, online: nil, type: nil); end
end
# This hash contains details about the customer acceptance of the Mandate.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::MandateData::CustomerAcceptance))
}
attr_accessor :customer_acceptance
sig {
params(customer_acceptance: T.nilable(::Stripe::PaymentIntent::ConfirmParams::MandateData::CustomerAcceptance)).void
}
def initialize(customer_acceptance: nil); end
end
class PaymentDetails < Stripe::RequestParams
class CarRental < Stripe::RequestParams
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::CarRental::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::CarRental::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
class Distance < Stripe::RequestParams
# Distance traveled.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# Unit of measurement for the distance traveled. One of `miles` or `kilometers`.
sig { returns(T.nilable(String)) }
attr_accessor :unit
sig { params(amount: T.nilable(Integer), unit: T.nilable(String)).void }
def initialize(amount: nil, unit: nil); end
end
class Driver < Stripe::RequestParams
# Driver's identification number.
sig { returns(T.nilable(String)) }
attr_accessor :driver_identification_number
# Driver's tax number.
sig { returns(T.nilable(String)) }
attr_accessor :driver_tax_number
# Full name of the person or entity on the car reservation.
sig { returns(String) }
attr_accessor :name
sig {
params(driver_identification_number: T.nilable(String), driver_tax_number: T.nilable(String), name: String).void
}
def initialize(
driver_identification_number: nil,
driver_tax_number: nil,
name: nil
); end
end
class PickupAddress < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class ReturnAddress < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::CarRental::Affiliate))
}
attr_accessor :affiliate
# The booking number associated with the car rental.
sig { returns(String) }
attr_accessor :booking_number
# Class code of the car.
sig { returns(T.nilable(String)) }
attr_accessor :car_class_code
# Make of the car.
sig { returns(T.nilable(String)) }
attr_accessor :car_make
# Model of the car.
sig { returns(T.nilable(String)) }
attr_accessor :car_model
# The name of the rental car company.
sig { returns(T.nilable(String)) }
attr_accessor :company
# The customer service phone number of the car rental company.
sig { returns(T.nilable(String)) }
attr_accessor :customer_service_phone_number
# Number of days the car is being rented.
sig { returns(Integer) }
attr_accessor :days_rented
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::CarRental::Delivery))
}
attr_accessor :delivery
# The details of the distance traveled during the rental period.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::CarRental::Distance))
}
attr_accessor :distance
# The details of the passengers in the travel reservation
sig {
returns(T.nilable(T::Array[::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::CarRental::Driver]))
}
attr_accessor :drivers
# List of additional charges being billed.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :extra_charges
# Indicates if the customer did not keep nor cancel their booking.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :no_show
# Car pick-up address.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::CarRental::PickupAddress))
}
attr_accessor :pickup_address
# Car pick-up time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :pickup_at
# Name of the pickup location.
sig { returns(T.nilable(String)) }
attr_accessor :pickup_location_name
# Rental rate.
sig { returns(T.nilable(Integer)) }
attr_accessor :rate_amount
# The frequency at which the rate amount is applied. One of `day`, `week` or `month`
sig { returns(T.nilable(String)) }
attr_accessor :rate_interval
# The name of the person or entity renting the car.
sig { returns(T.nilable(String)) }
attr_accessor :renter_name
# Car return address.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::CarRental::ReturnAddress))
}
attr_accessor :return_address
# Car return time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :return_at
# Name of the return location.
sig { returns(T.nilable(String)) }
attr_accessor :return_location_name
# Indicates whether the goods or services are tax-exempt or tax is not collected.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :tax_exempt
# The vehicle identification number.
sig { returns(T.nilable(String)) }
attr_accessor :vehicle_identification_number
sig {
params(affiliate: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::CarRental::Affiliate), booking_number: String, car_class_code: T.nilable(String), car_make: T.nilable(String), car_model: T.nilable(String), company: T.nilable(String), customer_service_phone_number: T.nilable(String), days_rented: Integer, delivery: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::CarRental::Delivery), distance: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::CarRental::Distance), drivers: T.nilable(T::Array[::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::CarRental::Driver]), extra_charges: T.nilable(T::Array[String]), no_show: T.nilable(T::Boolean), pickup_address: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::CarRental::PickupAddress), pickup_at: Integer, pickup_location_name: T.nilable(String), rate_amount: T.nilable(Integer), rate_interval: T.nilable(String), renter_name: T.nilable(String), return_address: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::CarRental::ReturnAddress), return_at: Integer, return_location_name: T.nilable(String), tax_exempt: T.nilable(T::Boolean), vehicle_identification_number: T.nilable(String)).void
}
def initialize(
affiliate: nil,
booking_number: nil,
car_class_code: nil,
car_make: nil,
car_model: nil,
company: nil,
customer_service_phone_number: nil,
days_rented: nil,
delivery: nil,
distance: nil,
drivers: nil,
extra_charges: nil,
no_show: nil,
pickup_address: nil,
pickup_at: nil,
pickup_location_name: nil,
rate_amount: nil,
rate_interval: nil,
renter_name: nil,
return_address: nil,
return_at: nil,
return_location_name: nil,
tax_exempt: nil,
vehicle_identification_number: nil
); end
end
class EventDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::EventDetails::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::EventDetails::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
# Indicates if the tickets are digitally checked when entering the venue.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :access_controlled_venue
# The event location's address.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::EventDetails::Address))
}
attr_accessor :address
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::EventDetails::Affiliate))
}
attr_accessor :affiliate
# The name of the company
sig { returns(T.nilable(String)) }
attr_accessor :company
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::EventDetails::Delivery))
}
attr_accessor :delivery
# Event end time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :ends_at
# Type of the event entertainment (concert, sports event etc)
sig { returns(T.nilable(String)) }
attr_accessor :genre
# The name of the event.
sig { returns(String) }
attr_accessor :name
# Event start time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :starts_at
sig {
params(access_controlled_venue: T.nilable(T::Boolean), address: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::EventDetails::Address), affiliate: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::EventDetails::Affiliate), company: T.nilable(String), delivery: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::EventDetails::Delivery), ends_at: T.nilable(Integer), genre: T.nilable(String), name: String, starts_at: T.nilable(Integer)).void
}
def initialize(
access_controlled_venue: nil,
address: nil,
affiliate: nil,
company: nil,
delivery: nil,
ends_at: nil,
genre: nil,
name: nil,
starts_at: nil
); end
end
class Flight < Stripe::RequestParams
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::Flight::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::Flight::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
class Passenger < Stripe::RequestParams
# Full name of the person or entity on the flight reservation.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Segment < Stripe::RequestParams
# The flight segment amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# The International Air Transport Association (IATA) airport code for the arrival airport.
sig { returns(T.nilable(String)) }
attr_accessor :arrival_airport
# The arrival time for the flight segment. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :arrives_at
# The International Air Transport Association (IATA) carrier code of the carrier operating the flight segment.
sig { returns(T.nilable(String)) }
attr_accessor :carrier
# The departure time for the flight segment. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :departs_at
# The International Air Transport Association (IATA) airport code for the departure airport.
sig { returns(T.nilable(String)) }
attr_accessor :departure_airport
# The flight number associated with the segment
sig { returns(T.nilable(String)) }
attr_accessor :flight_number
# The fare class for the segment.
sig { returns(T.nilable(String)) }
attr_accessor :service_class
sig {
params(amount: T.nilable(Integer), arrival_airport: T.nilable(String), arrives_at: T.nilable(Integer), carrier: T.nilable(String), departs_at: Integer, departure_airport: T.nilable(String), flight_number: T.nilable(String), service_class: T.nilable(String)).void
}
def initialize(
amount: nil,
arrival_airport: nil,
arrives_at: nil,
carrier: nil,
departs_at: nil,
departure_airport: nil,
flight_number: nil,
service_class: nil
); end
end
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::Flight::Affiliate))
}
attr_accessor :affiliate
# The agency number (i.e. International Air Transport Association (IATA) agency number) of the travel agency that made the booking.
sig { returns(T.nilable(String)) }
attr_accessor :agency_number
# The International Air Transport Association (IATA) carrier code of the carrier that issued the ticket.
sig { returns(T.nilable(String)) }
attr_accessor :carrier
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::Flight::Delivery))
}
attr_accessor :delivery
# The name of the person or entity on the reservation.
sig { returns(T.nilable(String)) }
attr_accessor :passenger_name
# The details of the passengers in the travel reservation.
sig {
returns(T.nilable(T::Array[::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::Flight::Passenger]))
}
attr_accessor :passengers
# The individual flight segments associated with the trip.
sig {
returns(T::Array[::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::Flight::Segment])
}
attr_accessor :segments
# The ticket number associated with the travel reservation.
sig { returns(T.nilable(String)) }
attr_accessor :ticket_number
sig {
params(affiliate: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::Flight::Affiliate), agency_number: T.nilable(String), carrier: T.nilable(String), delivery: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::Flight::Delivery), passenger_name: T.nilable(String), passengers: T.nilable(T::Array[::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::Flight::Passenger]), segments: T::Array[::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::Flight::Segment], ticket_number: T.nilable(String)).void
}
def initialize(
affiliate: nil,
agency_number: nil,
carrier: nil,
delivery: nil,
passenger_name: nil,
passengers: nil,
segments: nil,
ticket_number: nil
); end
end
class Lodging < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::Lodging::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::Lodging::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
class Passenger < Stripe::RequestParams
# Full name of the person or entity on the lodging reservation.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
# The lodging location's address.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::Lodging::Address))
}
attr_accessor :address
# The number of adults on the booking
sig { returns(T.nilable(Integer)) }
attr_accessor :adults
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::Lodging::Affiliate))
}
attr_accessor :affiliate
# The booking number associated with the lodging reservation.
sig { returns(T.nilable(String)) }
attr_accessor :booking_number
# The lodging category
sig { returns(T.nilable(String)) }
attr_accessor :category
# Lodging check-in time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :checkin_at
# Lodging check-out time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :checkout_at
# The customer service phone number of the lodging company.
sig { returns(T.nilable(String)) }
attr_accessor :customer_service_phone_number
# The daily lodging room rate.
sig { returns(T.nilable(Integer)) }
attr_accessor :daily_room_rate_amount
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::Lodging::Delivery))
}
attr_accessor :delivery
# List of additional charges being billed.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :extra_charges
# Indicates whether the lodging location is compliant with the Fire Safety Act.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :fire_safety_act_compliance
# The name of the lodging location.
sig { returns(T.nilable(String)) }
attr_accessor :name
# Indicates if the customer did not keep their booking while failing to cancel the reservation.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :no_show
# The number of rooms on the booking
sig { returns(T.nilable(Integer)) }
attr_accessor :number_of_rooms
# The details of the passengers in the travel reservation
sig {
returns(T.nilable(T::Array[::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::Lodging::Passenger]))
}
attr_accessor :passengers
# The phone number of the lodging location.
sig { returns(T.nilable(String)) }
attr_accessor :property_phone_number
# The room class for this purchase.
sig { returns(T.nilable(String)) }
attr_accessor :room_class
# The number of room nights
sig { returns(T.nilable(Integer)) }
attr_accessor :room_nights
# The total tax amount associating with the room reservation.
sig { returns(T.nilable(Integer)) }
attr_accessor :total_room_tax_amount
# The total tax amount
sig { returns(T.nilable(Integer)) }
attr_accessor :total_tax_amount
sig {
params(address: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::Lodging::Address), adults: T.nilable(Integer), affiliate: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::Lodging::Affiliate), booking_number: T.nilable(String), category: T.nilable(String), checkin_at: Integer, checkout_at: Integer, customer_service_phone_number: T.nilable(String), daily_room_rate_amount: T.nilable(Integer), delivery: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::Lodging::Delivery), extra_charges: T.nilable(T::Array[String]), fire_safety_act_compliance: T.nilable(T::Boolean), name: T.nilable(String), no_show: T.nilable(T::Boolean), number_of_rooms: T.nilable(Integer), passengers: T.nilable(T::Array[::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::Lodging::Passenger]), property_phone_number: T.nilable(String), room_class: T.nilable(String), room_nights: T.nilable(Integer), total_room_tax_amount: T.nilable(Integer), total_tax_amount: T.nilable(Integer)).void
}
def initialize(
address: nil,
adults: nil,
affiliate: nil,
booking_number: nil,
category: nil,
checkin_at: nil,
checkout_at: nil,
customer_service_phone_number: nil,
daily_room_rate_amount: nil,
delivery: nil,
extra_charges: nil,
fire_safety_act_compliance: nil,
name: nil,
no_show: nil,
number_of_rooms: nil,
passengers: nil,
property_phone_number: nil,
room_class: nil,
room_nights: nil,
total_room_tax_amount: nil,
total_tax_amount: nil
); end
end
class Subscription < Stripe::RequestParams
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class BillingInterval < Stripe::RequestParams
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :count
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
sig { params(count: Integer, interval: String).void }
def initialize(count: nil, interval: nil); end
end
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::Subscription::Affiliate))
}
attr_accessor :affiliate
# Info whether the subscription will be auto renewed upon expiry.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :auto_renewal
# Subscription billing details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::Subscription::BillingInterval))
}
attr_accessor :billing_interval
# Subscription end time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :ends_at
# Name of the product on subscription. e.g. Apple Music Subscription
sig { returns(String) }
attr_accessor :name
# Subscription start time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :starts_at
sig {
params(affiliate: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::Subscription::Affiliate), auto_renewal: T.nilable(T::Boolean), billing_interval: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::Subscription::BillingInterval), ends_at: T.nilable(Integer), name: String, starts_at: T.nilable(Integer)).void
}
def initialize(
affiliate: nil,
auto_renewal: nil,
billing_interval: nil,
ends_at: nil,
name: nil,
starts_at: nil
); end
end
# Car rental details for this PaymentIntent.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::CarRental))
}
attr_accessor :car_rental
# Some customers might be required by their company or organization to provide this information. If so, provide this value. Otherwise you can ignore this field.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :customer_reference
# Event details for this PaymentIntent
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::EventDetails))
}
attr_accessor :event_details
# Flight reservation details for this PaymentIntent
sig { returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::Flight)) }
attr_accessor :flight
# Lodging reservation details for this PaymentIntent
sig { returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::Lodging)) }
attr_accessor :lodging
# A unique value assigned by the business to identify the transaction.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :order_reference
# Subscription details for this PaymentIntent
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::Subscription))
}
attr_accessor :subscription
sig {
params(car_rental: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::CarRental), customer_reference: T.nilable(T.nilable(String)), event_details: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::EventDetails), flight: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::Flight), lodging: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::Lodging), order_reference: T.nilable(T.nilable(String)), subscription: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentDetails::Subscription)).void
}
def initialize(
car_rental: nil,
customer_reference: nil,
event_details: nil,
flight: nil,
lodging: nil,
order_reference: nil,
subscription: nil
); end
end
class PaymentMethodData < Stripe::RequestParams
class AcssDebit < Stripe::RequestParams
# Customer's bank account number.
sig { returns(String) }
attr_accessor :account_number
# Institution number of the customer's bank.
sig { returns(String) }
attr_accessor :institution_number
# Transit number of the customer's bank.
sig { returns(String) }
attr_accessor :transit_number
sig {
params(account_number: String, institution_number: String, transit_number: String).void
}
def initialize(account_number: nil, institution_number: nil, transit_number: nil); end
end
class Affirm < Stripe::RequestParams; end
class AfterpayClearpay < Stripe::RequestParams; end
class Alipay < Stripe::RequestParams; end
class Alma < Stripe::RequestParams; end
class AmazonPay < Stripe::RequestParams; end
class AuBecsDebit < Stripe::RequestParams
# The account number for the bank account.
sig { returns(String) }
attr_accessor :account_number
# Bank-State-Branch number of the bank account.
sig { returns(String) }
attr_accessor :bsb_number
sig { params(account_number: String, bsb_number: String).void }
def initialize(account_number: nil, bsb_number: nil); end
end
class BacsDebit < Stripe::RequestParams
# Account number of the bank account that the funds will be debited from.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Sort code of the bank account. (e.g., `10-20-30`)
sig { returns(T.nilable(String)) }
attr_accessor :sort_code
sig { params(account_number: T.nilable(String), sort_code: T.nilable(String)).void }
def initialize(account_number: nil, sort_code: nil); end
end
class Bancontact < Stripe::RequestParams; end
class Billie < Stripe::RequestParams; end
class BillingDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Billing address.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::BillingDetails::Address))))
}
attr_accessor :address
# Email address.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :email
# Full name.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :name
# Billing phone number (including extension).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :phone
# Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
sig { returns(T.nilable(String)) }
attr_accessor :tax_id
sig {
params(address: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::BillingDetails::Address))), email: T.nilable(T.nilable(String)), name: T.nilable(T.nilable(String)), phone: T.nilable(T.nilable(String)), tax_id: T.nilable(String)).void
}
def initialize(address: nil, email: nil, name: nil, phone: nil, tax_id: nil); end
end
class Blik < Stripe::RequestParams; end
class Boleto < Stripe::RequestParams
# The tax ID of the customer (CPF for individual consumers or CNPJ for businesses consumers)
sig { returns(String) }
attr_accessor :tax_id
sig { params(tax_id: String).void }
def initialize(tax_id: nil); end
end
class Cashapp < Stripe::RequestParams; end
class CustomerBalance < Stripe::RequestParams; end
class Eps < Stripe::RequestParams
# The customer's bank.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class Fpx < Stripe::RequestParams
# Account holder type for FPX transaction
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_type
# The customer's bank.
sig { returns(String) }
attr_accessor :bank
sig { params(account_holder_type: T.nilable(String), bank: String).void }
def initialize(account_holder_type: nil, bank: nil); end
end
class Giropay < Stripe::RequestParams; end
class Gopay < Stripe::RequestParams; end
class Grabpay < Stripe::RequestParams; end
class IdBankTransfer < Stripe::RequestParams
# Bank where the account is held.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class Ideal < Stripe::RequestParams
# The customer's bank. Only use this parameter for existing customers. Don't use it for new customers.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class InteracPresent < Stripe::RequestParams; end
class KakaoPay < Stripe::RequestParams; end
class Klarna < Stripe::RequestParams
class Dob < Stripe::RequestParams
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
# Customer's date of birth
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Klarna::Dob))
}
attr_accessor :dob
sig {
params(dob: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Klarna::Dob)).void
}
def initialize(dob: nil); end
end
class Konbini < Stripe::RequestParams; end
class KrCard < Stripe::RequestParams; end
class Link < Stripe::RequestParams; end
class MbWay < Stripe::RequestParams; end
class Mobilepay < Stripe::RequestParams; end
class Multibanco < Stripe::RequestParams; end
class NaverPay < Stripe::RequestParams
# Whether to use Naver Pay points or a card to fund this transaction. If not provided, this defaults to `card`.
sig { returns(T.nilable(String)) }
attr_accessor :funding
sig { params(funding: T.nilable(String)).void }
def initialize(funding: nil); end
end
class NzBankAccount < Stripe::RequestParams
# The name on the bank account. Only required if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod’s billing details.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_name
# The account number for the bank account.
sig { returns(String) }
attr_accessor :account_number
# The numeric code for the bank account's bank.
sig { returns(String) }
attr_accessor :bank_code
# The numeric code for the bank account's bank branch.
sig { returns(String) }
attr_accessor :branch_code
# Attribute for param field reference
sig { returns(T.nilable(String)) }
attr_accessor :reference
# The suffix of the bank account number.
sig { returns(String) }
attr_accessor :suffix
sig {
params(account_holder_name: T.nilable(String), account_number: String, bank_code: String, branch_code: String, reference: T.nilable(String), suffix: String).void
}
def initialize(
account_holder_name: nil,
account_number: nil,
bank_code: nil,
branch_code: nil,
reference: nil,
suffix: nil
); end
end
class Oxxo < Stripe::RequestParams; end
class P24 < Stripe::RequestParams
# The customer's bank.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class PayByBank < Stripe::RequestParams; end
class Payco < Stripe::RequestParams; end
class Paynow < Stripe::RequestParams; end
class Paypal < Stripe::RequestParams; end
class Payto < Stripe::RequestParams
# The account number for the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Bank-State-Branch number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :bsb_number
# The PayID alias for the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :pay_id
sig {
params(account_number: T.nilable(String), bsb_number: T.nilable(String), pay_id: T.nilable(String)).void
}
def initialize(account_number: nil, bsb_number: nil, pay_id: nil); end
end
class Pix < Stripe::RequestParams; end
class Promptpay < Stripe::RequestParams; end
class Qris < Stripe::RequestParams; end
class RadarOptions < Stripe::RequestParams
# A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
sig { returns(T.nilable(String)) }
attr_accessor :session
sig { params(session: T.nilable(String)).void }
def initialize(session: nil); end
end
class Rechnung < Stripe::RequestParams
class Dob < Stripe::RequestParams
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
# Customer's date of birth
sig { returns(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Rechnung::Dob) }
attr_accessor :dob
sig {
params(dob: ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Rechnung::Dob).void
}
def initialize(dob: nil); end
end
class RevolutPay < Stripe::RequestParams; end
class SamsungPay < Stripe::RequestParams; end
class Satispay < Stripe::RequestParams; end
class SepaDebit < Stripe::RequestParams
# IBAN of the bank account.
sig { returns(String) }
attr_accessor :iban
sig { params(iban: String).void }
def initialize(iban: nil); end
end
class Shopeepay < Stripe::RequestParams; end
class Sofort < Stripe::RequestParams
# Two-letter ISO code representing the country the bank account is located in.
sig { returns(String) }
attr_accessor :country
sig { params(country: String).void }
def initialize(country: nil); end
end
class StripeBalance < Stripe::RequestParams
# The connected account ID whose Stripe balance to use as the source of payment
sig { returns(T.nilable(String)) }
attr_accessor :account
# The [source_type](https://docs.stripe.com/api/balance/balance_object#balance_object-available-source_types) of the balance
sig { returns(T.nilable(String)) }
attr_accessor :source_type
sig { params(account: T.nilable(String), source_type: T.nilable(String)).void }
def initialize(account: nil, source_type: nil); end
end
class Swish < Stripe::RequestParams; end
class Twint < Stripe::RequestParams; end
class UsBankAccount < Stripe::RequestParams
# Account holder type: individual or company.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_type
# Account number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Account type: checkings or savings. Defaults to checking if omitted.
sig { returns(T.nilable(String)) }
attr_accessor :account_type
# The ID of a Financial Connections Account to use as a payment method.
sig { returns(T.nilable(String)) }
attr_accessor :financial_connections_account
# Routing number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :routing_number
sig {
params(account_holder_type: T.nilable(String), account_number: T.nilable(String), account_type: T.nilable(String), financial_connections_account: T.nilable(String), routing_number: T.nilable(String)).void
}
def initialize(
account_holder_type: nil,
account_number: nil,
account_type: nil,
financial_connections_account: nil,
routing_number: nil
); end
end
class WechatPay < Stripe::RequestParams; end
class Zip < Stripe::RequestParams; end
# If this is an `acss_debit` PaymentMethod, this hash contains details about the ACSS Debit payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::AcssDebit))
}
attr_accessor :acss_debit
# If this is an `affirm` PaymentMethod, this hash contains details about the Affirm payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Affirm))
}
attr_accessor :affirm
# If this is an `AfterpayClearpay` PaymentMethod, this hash contains details about the AfterpayClearpay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::AfterpayClearpay))
}
attr_accessor :afterpay_clearpay
# If this is an `Alipay` PaymentMethod, this hash contains details about the Alipay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Alipay))
}
attr_accessor :alipay
# This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :allow_redisplay
# If this is a Alma PaymentMethod, this hash contains details about the Alma payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Alma)) }
attr_accessor :alma
# If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::AmazonPay))
}
attr_accessor :amazon_pay
# If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::AuBecsDebit))
}
attr_accessor :au_becs_debit
# If this is a `bacs_debit` PaymentMethod, this hash contains details about the Bacs Direct Debit bank account.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::BacsDebit))
}
attr_accessor :bacs_debit
# If this is a `bancontact` PaymentMethod, this hash contains details about the Bancontact payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Bancontact))
}
attr_accessor :bancontact
# If this is a `billie` PaymentMethod, this hash contains details about the Billie payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Billie))
}
attr_accessor :billie
# Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::BillingDetails))
}
attr_accessor :billing_details
# If this is a `blik` PaymentMethod, this hash contains details about the BLIK payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Blik)) }
attr_accessor :blik
# If this is a `boleto` PaymentMethod, this hash contains details about the Boleto payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Boleto))
}
attr_accessor :boleto
# If this is a `cashapp` PaymentMethod, this hash contains details about the Cash App Pay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Cashapp))
}
attr_accessor :cashapp
# If this is a `customer_balance` PaymentMethod, this hash contains details about the CustomerBalance payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::CustomerBalance))
}
attr_accessor :customer_balance
# If this is an `eps` PaymentMethod, this hash contains details about the EPS payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Eps)) }
attr_accessor :eps
# If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Fpx)) }
attr_accessor :fpx
# If this is a `giropay` PaymentMethod, this hash contains details about the Giropay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Giropay))
}
attr_accessor :giropay
# If this is a Gopay PaymentMethod, this hash contains details about the Gopay payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Gopay)) }
attr_accessor :gopay
# If this is a `grabpay` PaymentMethod, this hash contains details about the GrabPay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Grabpay))
}
attr_accessor :grabpay
# If this is an `IdBankTransfer` PaymentMethod, this hash contains details about the IdBankTransfer payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::IdBankTransfer))
}
attr_accessor :id_bank_transfer
# If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Ideal)) }
attr_accessor :ideal
# If this is an `interac_present` PaymentMethod, this hash contains details about the Interac Present payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::InteracPresent))
}
attr_accessor :interac_present
# If this is a `kakao_pay` PaymentMethod, this hash contains details about the Kakao Pay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::KakaoPay))
}
attr_accessor :kakao_pay
# If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Klarna))
}
attr_accessor :klarna
# If this is a `konbini` PaymentMethod, this hash contains details about the Konbini payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Konbini))
}
attr_accessor :konbini
# If this is a `kr_card` PaymentMethod, this hash contains details about the Korean Card payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::KrCard))
}
attr_accessor :kr_card
# If this is an `Link` PaymentMethod, this hash contains details about the Link payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Link)) }
attr_accessor :link
# If this is a MB WAY PaymentMethod, this hash contains details about the MB WAY payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::MbWay)) }
attr_accessor :mb_way
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# If this is a `mobilepay` PaymentMethod, this hash contains details about the MobilePay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Mobilepay))
}
attr_accessor :mobilepay
# If this is a `multibanco` PaymentMethod, this hash contains details about the Multibanco payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Multibanco))
}
attr_accessor :multibanco
# If this is a `naver_pay` PaymentMethod, this hash contains details about the Naver Pay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::NaverPay))
}
attr_accessor :naver_pay
# If this is an nz_bank_account PaymentMethod, this hash contains details about the nz_bank_account payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::NzBankAccount))
}
attr_accessor :nz_bank_account
# If this is an `oxxo` PaymentMethod, this hash contains details about the OXXO payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Oxxo)) }
attr_accessor :oxxo
# If this is a `p24` PaymentMethod, this hash contains details about the P24 payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::P24)) }
attr_accessor :p24
# If this is a `pay_by_bank` PaymentMethod, this hash contains details about the PayByBank payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::PayByBank))
}
attr_accessor :pay_by_bank
# If this is a `payco` PaymentMethod, this hash contains details about the PAYCO payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Payco)) }
attr_accessor :payco
# If this is a `paynow` PaymentMethod, this hash contains details about the PayNow payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Paynow))
}
attr_accessor :paynow
# If this is a `paypal` PaymentMethod, this hash contains details about the PayPal payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Paypal))
}
attr_accessor :paypal
# If this is a `payto` PaymentMethod, this hash contains details about the PayTo payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Payto)) }
attr_accessor :payto
# If this is a `pix` PaymentMethod, this hash contains details about the Pix payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Pix)) }
attr_accessor :pix
# If this is a `promptpay` PaymentMethod, this hash contains details about the PromptPay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Promptpay))
}
attr_accessor :promptpay
# If this is a `qris` PaymentMethod, this hash contains details about the QRIS payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Qris)) }
attr_accessor :qris
# Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::RadarOptions))
}
attr_accessor :radar_options
# If this is a `rechnung` PaymentMethod, this hash contains details about the Rechnung payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Rechnung))
}
attr_accessor :rechnung
# If this is a `revolut_pay` PaymentMethod, this hash contains details about the Revolut Pay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::RevolutPay))
}
attr_accessor :revolut_pay
# If this is a `samsung_pay` PaymentMethod, this hash contains details about the SamsungPay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::SamsungPay))
}
attr_accessor :samsung_pay
# If this is a `satispay` PaymentMethod, this hash contains details about the Satispay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Satispay))
}
attr_accessor :satispay
# If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::SepaDebit))
}
attr_accessor :sepa_debit
# If this is a Shopeepay PaymentMethod, this hash contains details about the Shopeepay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Shopeepay))
}
attr_accessor :shopeepay
# If this is a `sofort` PaymentMethod, this hash contains details about the SOFORT payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Sofort))
}
attr_accessor :sofort
# This hash contains details about the Stripe balance payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::StripeBalance))
}
attr_accessor :stripe_balance
# If this is a `swish` PaymentMethod, this hash contains details about the Swish payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Swish)) }
attr_accessor :swish
# If this is a TWINT PaymentMethod, this hash contains details about the TWINT payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Twint)) }
attr_accessor :twint
# The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
sig { returns(String) }
attr_accessor :type
# If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::UsBankAccount))
}
attr_accessor :us_bank_account
# If this is an `wechat_pay` PaymentMethod, this hash contains details about the wechat_pay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::WechatPay))
}
attr_accessor :wechat_pay
# If this is a `zip` PaymentMethod, this hash contains details about the Zip payment method.
sig { returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Zip)) }
attr_accessor :zip
sig {
params(acss_debit: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::AcssDebit), affirm: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Affirm), afterpay_clearpay: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::AfterpayClearpay), alipay: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Alipay), allow_redisplay: T.nilable(String), alma: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Alma), amazon_pay: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::AmazonPay), au_becs_debit: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::AuBecsDebit), bacs_debit: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::BacsDebit), bancontact: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Bancontact), billie: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Billie), billing_details: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::BillingDetails), blik: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Blik), boleto: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Boleto), cashapp: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Cashapp), customer_balance: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::CustomerBalance), eps: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Eps), fpx: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Fpx), giropay: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Giropay), gopay: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Gopay), grabpay: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Grabpay), id_bank_transfer: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::IdBankTransfer), ideal: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Ideal), interac_present: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::InteracPresent), kakao_pay: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::KakaoPay), klarna: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Klarna), konbini: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Konbini), kr_card: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::KrCard), link: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Link), mb_way: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::MbWay), metadata: T.nilable(T::Hash[String, String]), mobilepay: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Mobilepay), multibanco: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Multibanco), naver_pay: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::NaverPay), nz_bank_account: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::NzBankAccount), oxxo: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Oxxo), p24: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::P24), pay_by_bank: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::PayByBank), payco: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Payco), paynow: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Paynow), paypal: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Paypal), payto: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Payto), pix: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Pix), promptpay: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Promptpay), qris: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Qris), radar_options: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::RadarOptions), rechnung: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Rechnung), revolut_pay: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::RevolutPay), samsung_pay: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::SamsungPay), satispay: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Satispay), sepa_debit: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::SepaDebit), shopeepay: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Shopeepay), sofort: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Sofort), stripe_balance: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::StripeBalance), swish: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Swish), twint: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Twint), type: String, us_bank_account: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::UsBankAccount), wechat_pay: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::WechatPay), zip: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData::Zip)).void
}
def initialize(
acss_debit: nil,
affirm: nil,
afterpay_clearpay: nil,
alipay: nil,
allow_redisplay: nil,
alma: nil,
amazon_pay: nil,
au_becs_debit: nil,
bacs_debit: nil,
bancontact: nil,
billie: nil,
billing_details: nil,
blik: nil,
boleto: nil,
cashapp: nil,
customer_balance: nil,
eps: nil,
fpx: nil,
giropay: nil,
gopay: nil,
grabpay: nil,
id_bank_transfer: nil,
ideal: nil,
interac_present: nil,
kakao_pay: nil,
klarna: nil,
konbini: nil,
kr_card: nil,
link: nil,
mb_way: nil,
metadata: nil,
mobilepay: nil,
multibanco: nil,
naver_pay: nil,
nz_bank_account: nil,
oxxo: nil,
p24: nil,
pay_by_bank: nil,
payco: nil,
paynow: nil,
paypal: nil,
payto: nil,
pix: nil,
promptpay: nil,
qris: nil,
radar_options: nil,
rechnung: nil,
revolut_pay: nil,
samsung_pay: nil,
satispay: nil,
sepa_debit: nil,
shopeepay: nil,
sofort: nil,
stripe_balance: nil,
swish: nil,
twint: nil,
type: nil,
us_bank_account: nil,
wechat_pay: nil,
zip: nil
); end
end
class PaymentMethodOptions < Stripe::RequestParams
class AcssDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# A URL for custom mandate text to render during confirmation step.
# The URL will be rendered with additional GET parameters `payment_intent` and `payment_intent_client_secret` when confirming a Payment Intent,
# or `setup_intent` and `setup_intent_client_secret` when confirming a Setup Intent.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :custom_mandate_url
# Description of the mandate interval. Only required if 'payment_schedule' parameter is 'interval' or 'combined'.
sig { returns(T.nilable(String)) }
attr_accessor :interval_description
# Payment schedule for the mandate.
sig { returns(T.nilable(String)) }
attr_accessor :payment_schedule
# Transaction type of the mandate.
sig { returns(T.nilable(String)) }
attr_accessor :transaction_type
sig {
params(custom_mandate_url: T.nilable(T.nilable(String)), interval_description: T.nilable(String), payment_schedule: T.nilable(String), transaction_type: T.nilable(String)).void
}
def initialize(
custom_mandate_url: nil,
interval_description: nil,
payment_schedule: nil,
transaction_type: nil
); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::AcssDebit::MandateOptions))
}
attr_accessor :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
# Bank account verification method.
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(mandate_options: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::AcssDebit::MandateOptions), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), target_date: T.nilable(String), verification_method: T.nilable(String)).void
}
def initialize(
mandate_options: nil,
setup_future_usage: nil,
target_date: nil,
verification_method: nil
); end
end
class Affirm < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Preferred language of the Affirm authorization page that the customer is redirected to.
sig { returns(T.nilable(String)) }
attr_accessor :preferred_locale
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), preferred_locale: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(capture_method: nil, preferred_locale: nil, setup_future_usage: nil); end
end
class AfterpayClearpay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# An internal identifier or reference that this payment corresponds to. You must limit the identifier to 128 characters, and it can only contain letters, numbers, underscores, backslashes, and dashes.
# This field differs from the statement descriptor and item name.
sig { returns(T.nilable(String)) }
attr_accessor :reference
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), reference: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(capture_method: nil, reference: nil, setup_future_usage: nil); end
end
class Alipay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void }
def initialize(setup_future_usage: nil); end
end
class Alma < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
sig { params(capture_method: T.nilable(T.nilable(String))).void }
def initialize(capture_method: nil); end
end
class AmazonPay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class AuBecsDebit < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
sig {
params(setup_future_usage: T.nilable(T.nilable(T.any(String, String))), target_date: T.nilable(String)).void
}
def initialize(setup_future_usage: nil, target_date: nil); end
end
class BacsDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'DDIC' or 'STRIPE'.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :reference_prefix
sig { params(reference_prefix: T.nilable(T.nilable(String))).void }
def initialize(reference_prefix: nil); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::BacsDebit::MandateOptions))
}
attr_accessor :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
sig {
params(mandate_options: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::BacsDebit::MandateOptions), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), target_date: T.nilable(String)).void
}
def initialize(mandate_options: nil, setup_future_usage: nil, target_date: nil); end
end
class Bancontact < Stripe::RequestParams
# Preferred language of the Bancontact authorization page that the customer is redirected to.
sig { returns(T.nilable(String)) }
attr_accessor :preferred_language
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(preferred_language: T.nilable(String), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(preferred_language: nil, setup_future_usage: nil); end
end
class Billie < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
sig { params(capture_method: T.nilable(T.nilable(String))).void }
def initialize(capture_method: nil); end
end
class Blik < Stripe::RequestParams
# The 6-digit BLIK code that a customer has generated using their banking application. Can only be set on confirmation.
sig { returns(T.nilable(String)) }
attr_accessor :code
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :setup_future_usage
sig {
params(code: T.nilable(String), setup_future_usage: T.nilable(T.nilable(String))).void
}
def initialize(code: nil, setup_future_usage: nil); end
end
class Boleto < Stripe::RequestParams
# The number of calendar days before a Boleto voucher expires. For example, if you create a Boleto voucher on Monday and you set expires_after_days to 2, the Boleto invoice will expire on Wednesday at 23:59 America/Sao_Paulo time.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_after_days
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(expires_after_days: T.nilable(Integer), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(expires_after_days: nil, setup_future_usage: nil); end
end
class Card < Stripe::RequestParams
class Installments < Stripe::RequestParams
class Plan < Stripe::RequestParams
# For `fixed_count` installment plans, this is required. It represents the number of installment payments your customer will make to their credit card.
sig { returns(T.nilable(Integer)) }
attr_accessor :count
# For `fixed_count` installment plans, this is required. It represents the interval between installment payments your customer will make to their credit card.
# One of `month`.
sig { returns(T.nilable(String)) }
attr_accessor :interval
# Type of installment plan, one of `fixed_count`.
sig { returns(String) }
attr_accessor :type
sig {
params(count: T.nilable(Integer), interval: T.nilable(String), type: String).void
}
def initialize(count: nil, interval: nil, type: nil); end
end
# Setting to true enables installments for this PaymentIntent.
# This will cause the response to contain a list of available installment plans.
# Setting to false will prevent any selected plan from applying to a charge.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :enabled
# The selected installment plan to use for this payment attempt.
# This parameter can only be provided during confirmation.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Card::Installments::Plan))))
}
attr_accessor :plan
sig {
params(enabled: T.nilable(T::Boolean), plan: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Card::Installments::Plan)))).void
}
def initialize(enabled: nil, plan: nil); end
end
class MandateOptions < Stripe::RequestParams
# Amount to be charged for future payments.
sig { returns(Integer) }
attr_accessor :amount
# One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.
sig { returns(String) }
attr_accessor :amount_type
# A description of the mandate or subscription that is meant to be displayed to the customer.
sig { returns(T.nilable(String)) }
attr_accessor :description
# End date of the mandate or subscription. If not provided, the mandate will be active until canceled. If provided, end date should be after start date.
sig { returns(T.nilable(Integer)) }
attr_accessor :end_date
# Specifies payment frequency. One of `day`, `week`, `month`, `year`, or `sporadic`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals between payments. For example, `interval=month` and `interval_count=3` indicates one payment every three months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks). This parameter is optional when `interval=sporadic`.
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_count
# Unique identifier for the mandate or subscription.
sig { returns(String) }
attr_accessor :reference
# Start date of the mandate or subscription. Start date should not be lesser than yesterday.
sig { returns(Integer) }
attr_accessor :start_date
# Specifies the type of mandates supported. Possible values are `india`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :supported_types
sig {
params(amount: Integer, amount_type: String, description: T.nilable(String), end_date: T.nilable(Integer), interval: String, interval_count: T.nilable(Integer), reference: String, start_date: Integer, supported_types: T.nilable(T::Array[String])).void
}
def initialize(
amount: nil,
amount_type: nil,
description: nil,
end_date: nil,
interval: nil,
interval_count: nil,
reference: nil,
start_date: nil,
supported_types: nil
); end
end
class StatementDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Please pass in an address that is within your Stripe user account country
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Card::StatementDetails::Address))
}
attr_accessor :address
# Phone number (e.g., a toll-free number that customers can call)
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(address: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Card::StatementDetails::Address), phone: T.nilable(String)).void
}
def initialize(address: nil, phone: nil); end
end
class ThreeDSecure < Stripe::RequestParams
class NetworkOptions < Stripe::RequestParams
class CartesBancaires < Stripe::RequestParams
# The cryptogram calculation algorithm used by the card Issuer's ACS
# to calculate the Authentication cryptogram. Also known as `cavvAlgorithm`.
# messageExtension: CB-AVALGO
sig { returns(String) }
attr_accessor :cb_avalgo
# The exemption indicator returned from Cartes Bancaires in the ARes.
# message extension: CB-EXEMPTION; string (4 characters)
# This is a 3 byte bitmap (low significant byte first and most significant
# bit first) that has been Base64 encoded
sig { returns(T.nilable(String)) }
attr_accessor :cb_exemption
# The risk score returned from Cartes Bancaires in the ARes.
# message extension: CB-SCORE; numeric value 0-99
sig { returns(T.nilable(Integer)) }
attr_accessor :cb_score
sig {
params(cb_avalgo: String, cb_exemption: T.nilable(String), cb_score: T.nilable(Integer)).void
}
def initialize(cb_avalgo: nil, cb_exemption: nil, cb_score: nil); end
end
# Cartes Bancaires-specific 3DS fields.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions::CartesBancaires))
}
attr_accessor :cartes_bancaires
sig {
params(cartes_bancaires: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions::CartesBancaires)).void
}
def initialize(cartes_bancaires: nil); end
end
# The `transStatus` returned from the card Issuer’s ACS in the ARes.
sig { returns(T.nilable(String)) }
attr_accessor :ares_trans_status
# The cryptogram, also known as the "authentication value" (AAV, CAVV or
# AEVV). This value is 20 bytes, base64-encoded into a 28-character string.
# (Most 3D Secure providers will return the base64-encoded version, which
# is what you should specify here.)
sig { returns(String) }
attr_accessor :cryptogram
# The Electronic Commerce Indicator (ECI) is returned by your 3D Secure
# provider and indicates what degree of authentication was performed.
sig { returns(T.nilable(String)) }
attr_accessor :electronic_commerce_indicator
# The exemption requested via 3DS and accepted by the issuer at authentication time.
sig { returns(T.nilable(String)) }
attr_accessor :exemption_indicator
# Network specific 3DS fields. Network specific arguments require an
# explicit card brand choice. The parameter `payment_method_options.card.network``
# must be populated accordingly
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions))
}
attr_accessor :network_options
# The challenge indicator (`threeDSRequestorChallengeInd`) which was requested in the
# AReq sent to the card Issuer's ACS. A string containing 2 digits from 01-99.
sig { returns(T.nilable(String)) }
attr_accessor :requestor_challenge_indicator
# For 3D Secure 1, the XID. For 3D Secure 2, the Directory Server
# Transaction ID (dsTransID).
sig { returns(String) }
attr_accessor :transaction_id
# The version of 3D Secure that was performed.
sig { returns(String) }
attr_accessor :version
sig {
params(ares_trans_status: T.nilable(String), cryptogram: String, electronic_commerce_indicator: T.nilable(String), exemption_indicator: T.nilable(String), network_options: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions), requestor_challenge_indicator: T.nilable(String), transaction_id: String, version: String).void
}
def initialize(
ares_trans_status: nil,
cryptogram: nil,
electronic_commerce_indicator: nil,
exemption_indicator: nil,
network_options: nil,
requestor_challenge_indicator: nil,
transaction_id: nil,
version: nil
); end
end
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# A single-use `cvc_update` Token that represents a card CVC value. When provided, the CVC value will be verified during the card payment attempt. This parameter can only be provided during confirmation.
sig { returns(T.nilable(String)) }
attr_accessor :cvc_token
# Installment configuration for payments attempted on this PaymentIntent (Mexico Only).
#
# For more information, see the [installments integration guide](https://stripe.com/docs/payments/installments).
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Card::Installments))
}
attr_accessor :installments
# Configuration options for setting up an eMandate for cards issued in India.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Card::MandateOptions))
}
attr_accessor :mandate_options
# When specified, this parameter indicates that a transaction will be marked
# as MOTO (Mail Order Telephone Order) and thus out of scope for SCA. This
# parameter can only be provided during confirmation.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :moto
# Selected network to process this PaymentIntent on. Depends on the available networks of the card attached to the PaymentIntent. Can be only set confirm-time.
sig { returns(T.nilable(String)) }
attr_accessor :network
# Request ability to [decrement the authorization](https://stripe.com/docs/payments/decremental-authorization) for this PaymentIntent.
sig { returns(T.nilable(String)) }
attr_accessor :request_decremental_authorization
# Request ability to [capture beyond the standard authorization validity window](https://stripe.com/docs/payments/extended-authorization) for this PaymentIntent.
sig { returns(T.nilable(String)) }
attr_accessor :request_extended_authorization
# Request ability to [increment the authorization](https://stripe.com/docs/payments/incremental-authorization) for this PaymentIntent.
sig { returns(T.nilable(String)) }
attr_accessor :request_incremental_authorization
# Request ability to make [multiple captures](https://stripe.com/docs/payments/multicapture) for this PaymentIntent.
sig { returns(T.nilable(String)) }
attr_accessor :request_multicapture
# Request ability to [overcapture](https://stripe.com/docs/payments/overcapture) for this PaymentIntent.
sig { returns(T.nilable(String)) }
attr_accessor :request_overcapture
# Request partial authorization on this PaymentIntent.
sig { returns(T.nilable(String)) }
attr_accessor :request_partial_authorization
# We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. If not provided, this value defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
sig { returns(T.nilable(String)) }
attr_accessor :request_three_d_secure
# When enabled, using a card that is attached to a customer will require the CVC to be provided again (i.e. using the cvc_token parameter).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :require_cvc_recollection
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Provides information about a card payment that customers see on their statements. Concatenated with the Kana prefix (shortened Kana descriptor) or Kana statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 22 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 22 characters.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :statement_descriptor_suffix_kana
# Provides information about a card payment that customers see on their statements. Concatenated with the Kanji prefix (shortened Kanji descriptor) or Kanji statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 17 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 17 characters.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :statement_descriptor_suffix_kanji
# Statement details for this payment intent. You can use this to override the merchant details shown on your customers' statements.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Card::StatementDetails))))
}
attr_accessor :statement_details
# If 3D Secure authentication was performed with a third-party provider,
# the authentication details to use for this payment.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Card::ThreeDSecure))
}
attr_accessor :three_d_secure
sig {
params(capture_method: T.nilable(T.nilable(String)), cvc_token: T.nilable(String), installments: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Card::Installments), mandate_options: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Card::MandateOptions), moto: T.nilable(T::Boolean), network: T.nilable(String), request_decremental_authorization: T.nilable(String), request_extended_authorization: T.nilable(String), request_incremental_authorization: T.nilable(String), request_multicapture: T.nilable(String), request_overcapture: T.nilable(String), request_partial_authorization: T.nilable(String), request_three_d_secure: T.nilable(String), require_cvc_recollection: T.nilable(T::Boolean), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), statement_descriptor_suffix_kana: T.nilable(T.nilable(String)), statement_descriptor_suffix_kanji: T.nilable(T.nilable(String)), statement_details: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Card::StatementDetails))), three_d_secure: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Card::ThreeDSecure)).void
}
def initialize(
capture_method: nil,
cvc_token: nil,
installments: nil,
mandate_options: nil,
moto: nil,
network: nil,
request_decremental_authorization: nil,
request_extended_authorization: nil,
request_incremental_authorization: nil,
request_multicapture: nil,
request_overcapture: nil,
request_partial_authorization: nil,
request_three_d_secure: nil,
require_cvc_recollection: nil,
setup_future_usage: nil,
statement_descriptor_suffix_kana: nil,
statement_descriptor_suffix_kanji: nil,
statement_details: nil,
three_d_secure: nil
); end
end
class CardPresent < Stripe::RequestParams
class Routing < Stripe::RequestParams
# Routing requested priority
sig { returns(T.nilable(String)) }
attr_accessor :requested_priority
sig { params(requested_priority: T.nilable(String)).void }
def initialize(requested_priority: nil); end
end
# Request ability to capture this payment beyond the standard [authorization validity window](https://stripe.com/docs/terminal/features/extended-authorizations#authorization-validity)
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :request_extended_authorization
# Request ability to [increment](https://stripe.com/docs/terminal/features/incremental-authorizations) this PaymentIntent if the combination of MCC and card brand is eligible. Check [incremental_authorization_supported](https://stripe.com/docs/api/charges/object#charge_object-payment_method_details-card_present-incremental_authorization_supported) in the [Confirm](https://stripe.com/docs/api/payment_intents/confirm) response to verify support.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :request_incremental_authorization_support
# Network routing priority on co-branded EMV cards supporting domestic debit and international card schemes.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::CardPresent::Routing))
}
attr_accessor :routing
sig {
params(request_extended_authorization: T.nilable(T::Boolean), request_incremental_authorization_support: T.nilable(T::Boolean), routing: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::CardPresent::Routing)).void
}
def initialize(
request_extended_authorization: nil,
request_incremental_authorization_support: nil,
routing: nil
); end
end
class Cashapp < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class CustomerBalance < Stripe::RequestParams
class BankTransfer < Stripe::RequestParams
class EuBankTransfer < Stripe::RequestParams
# The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
sig { returns(String) }
attr_accessor :country
sig { params(country: String).void }
def initialize(country: nil); end
end
# Configuration for the eu_bank_transfer funding type.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::CustomerBalance::BankTransfer::EuBankTransfer))
}
attr_accessor :eu_bank_transfer
# List of address types that should be returned in the financial_addresses response. If not specified, all valid types will be returned.
#
# Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :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`, `mx_bank_transfer`, or `us_bank_transfer`.
sig { returns(String) }
attr_accessor :type
sig {
params(eu_bank_transfer: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::CustomerBalance::BankTransfer::EuBankTransfer), requested_address_types: T.nilable(T::Array[String]), type: String).void
}
def initialize(eu_bank_transfer: nil, requested_address_types: nil, type: nil); end
end
# Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::CustomerBalance::BankTransfer))
}
attr_accessor :bank_transfer
# The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
sig { returns(T.nilable(String)) }
attr_accessor :funding_type
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(bank_transfer: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::CustomerBalance::BankTransfer), funding_type: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(bank_transfer: nil, funding_type: nil, setup_future_usage: nil); end
end
class Eps < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Fpx < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Giropay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Gopay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Grabpay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class IdBankTransfer < Stripe::RequestParams
# The UNIX timestamp until which the virtual bank account is valid. Permitted range is from 5 minutes from now until 31 days from now. If unset, it defaults to 3 days from now.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_after
# The UNIX timestamp until which the virtual bank account is valid. Permitted range is from now until 30 days from now. If unset, it defaults to 1 days from now.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_at
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(expires_after: T.nilable(Integer), expires_at: T.nilable(Integer), setup_future_usage: T.nilable(String)).void
}
def initialize(expires_after: nil, expires_at: nil, setup_future_usage: nil); end
end
class Ideal < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void }
def initialize(setup_future_usage: nil); end
end
class InteracPresent < Stripe::RequestParams; end
class KakaoPay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class Klarna < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Preferred language of the Klarna authorization page that the customer is redirected to
sig { returns(T.nilable(String)) }
attr_accessor :preferred_locale
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), preferred_locale: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(capture_method: nil, preferred_locale: nil, setup_future_usage: nil); end
end
class Konbini < Stripe::RequestParams
# An optional 10 to 11 digit numeric-only string determining the confirmation code at applicable convenience stores. Must not consist of only zeroes and could be rejected in case of insufficient uniqueness. We recommend to use the customer's phone number.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :confirmation_number
# The number of calendar days (between 1 and 60) after which Konbini payment instructions will expire. For example, if a PaymentIntent is confirmed with Konbini and `expires_after_days` set to 2 on Monday JST, the instructions will expire on Wednesday 23:59:59 JST. Defaults to 3 days.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :expires_after_days
# The timestamp at which the Konbini payment instructions will expire. Only one of `expires_after_days` or `expires_at` may be set.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :expires_at
# A product descriptor of up to 22 characters, which will appear to customers at the convenience store.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :product_description
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(confirmation_number: T.nilable(T.nilable(String)), expires_after_days: T.nilable(T.nilable(T.any(String, Integer))), expires_at: T.nilable(T.nilable(T.any(String, Integer))), product_description: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(String)).void
}
def initialize(
confirmation_number: nil,
expires_after_days: nil,
expires_at: nil,
product_description: nil,
setup_future_usage: nil
); end
end
class KrCard < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class Link < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# [Deprecated] This is a legacy parameter that no longer has any function.
sig { returns(T.nilable(String)) }
attr_accessor :persistent_token
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), persistent_token: T.nilable(String), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(capture_method: nil, persistent_token: nil, setup_future_usage: nil); end
end
class MbWay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Mobilepay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(String)).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class Multibanco < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class NaverPay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class NzBankAccount < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
sig {
params(setup_future_usage: T.nilable(T.nilable(T.any(String, String))), target_date: T.nilable(String)).void
}
def initialize(setup_future_usage: nil, target_date: nil); end
end
class Oxxo < Stripe::RequestParams
# The number of calendar days before an OXXO voucher expires. For example, if you create an OXXO voucher on Monday and you set expires_after_days to 2, the OXXO invoice will expire on Wednesday at 23:59 America/Mexico_City time.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_after_days
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(expires_after_days: T.nilable(Integer), setup_future_usage: T.nilable(String)).void
}
def initialize(expires_after_days: nil, setup_future_usage: nil); end
end
class P24 < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
# Confirm that the payer has accepted the P24 terms and conditions.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :tos_shown_and_accepted
sig {
params(setup_future_usage: T.nilable(String), tos_shown_and_accepted: T.nilable(T::Boolean)).void
}
def initialize(setup_future_usage: nil, tos_shown_and_accepted: nil); end
end
class PayByBank < Stripe::RequestParams; end
class Payco < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
sig { params(capture_method: T.nilable(T.nilable(String))).void }
def initialize(capture_method: nil); end
end
class Paynow < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Paypal < Stripe::RequestParams
class LineItem < Stripe::RequestParams
class Tax < Stripe::RequestParams
# The tax for a single unit of the line item in minor units. Cannot be a negative number.
sig { returns(Integer) }
attr_accessor :amount
# The tax behavior for the line item.
sig { returns(String) }
attr_accessor :behavior
sig { params(amount: Integer, behavior: String).void }
def initialize(amount: nil, behavior: nil); end
end
# Type of the line item.
sig { returns(T.nilable(String)) }
attr_accessor :category
# Description of the line item.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Descriptive name of the line item.
sig { returns(String) }
attr_accessor :name
# Quantity of the line item. Must be a positive number.
sig { returns(Integer) }
attr_accessor :quantity
# Client facing stock keeping unit, article number or similar.
sig { returns(T.nilable(String)) }
attr_accessor :sku
# The Stripe account ID of the connected account that sells the item.
sig { returns(T.nilable(String)) }
attr_accessor :sold_by
# The tax information for the line item.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Paypal::LineItem::Tax))
}
attr_accessor :tax
# Price for a single unit of the line item in minor units. Cannot be a negative number.
sig { returns(Integer) }
attr_accessor :unit_amount
sig {
params(category: T.nilable(String), description: T.nilable(String), name: String, quantity: Integer, sku: T.nilable(String), sold_by: T.nilable(String), tax: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Paypal::LineItem::Tax), unit_amount: Integer).void
}
def initialize(
category: nil,
description: nil,
name: nil,
quantity: nil,
sku: nil,
sold_by: nil,
tax: nil,
unit_amount: nil
); end
end
# Controls when the funds will be captured from the customer's account.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# The line items purchased by the customer.
sig {
returns(T.nilable(T::Array[::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Paypal::LineItem]))
}
attr_accessor :line_items
# [Preferred locale](https://stripe.com/docs/payments/paypal/supported-locales) of the PayPal checkout page that the customer is redirected to.
sig { returns(T.nilable(String)) }
attr_accessor :preferred_locale
# A reference of the PayPal transaction visible to customer which is mapped to PayPal's invoice ID. This must be a globally unique ID if you have configured in your PayPal settings to block multiple payments per invoice ID.
sig { returns(T.nilable(String)) }
attr_accessor :reference
# A reference of the PayPal transaction visible to customer which is mapped to PayPal's invoice ID. This must be a globally unique ID if you have configured in your PayPal settings to block multiple payments per invoice ID.
sig { returns(T.nilable(String)) }
attr_accessor :reference_id
# The risk correlation ID for an on-session payment using a saved PayPal payment method.
sig { returns(T.nilable(String)) }
attr_accessor :risk_correlation_id
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# The Stripe connected account IDs of the sellers on the platform for this transaction (optional). Only allowed when [separate charges and transfers](https://stripe.com/docs/connect/separate-charges-and-transfers) are used.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :subsellers
sig {
params(capture_method: T.nilable(T.nilable(String)), line_items: T.nilable(T::Array[::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Paypal::LineItem]), preferred_locale: T.nilable(String), reference: T.nilable(String), reference_id: T.nilable(String), risk_correlation_id: T.nilable(String), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), subsellers: T.nilable(T::Array[String])).void
}
def initialize(
capture_method: nil,
line_items: nil,
preferred_locale: nil,
reference: nil,
reference_id: nil,
risk_correlation_id: nil,
setup_future_usage: nil,
subsellers: nil
); end
end
class Payto < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Amount that will be collected. It is required when `amount_type` is `fixed`.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# The type of amount that will be collected. The amount charged must be exact or up to the value of `amount` param for `fixed` or `maximum` type respectively.
sig { returns(T.nilable(String)) }
attr_accessor :amount_type
# Date, in YYYY-MM-DD format, after which payments will not be collected. Defaults to no end date.
sig { returns(T.nilable(String)) }
attr_accessor :end_date
# The periodicity at which payments will be collected.
sig { returns(T.nilable(String)) }
attr_accessor :payment_schedule
# The number of payments that will be made during a payment period. Defaults to 1 except for when `payment_schedule` is `adhoc`. In that case, it defaults to no limit.
sig { returns(T.nilable(Integer)) }
attr_accessor :payments_per_period
# The purpose for which payments are made. Defaults to retail.
sig { returns(T.nilable(String)) }
attr_accessor :purpose
sig {
params(amount: T.nilable(Integer), amount_type: T.nilable(String), end_date: T.nilable(String), payment_schedule: T.nilable(String), payments_per_period: T.nilable(Integer), purpose: T.nilable(String)).void
}
def initialize(
amount: nil,
amount_type: nil,
end_date: nil,
payment_schedule: nil,
payments_per_period: nil,
purpose: nil
); end
end
# Additional fields for Mandate creation. Only `purpose` field is configurable for PayTo PaymentIntent with `setup_future_usage=none`. Other fields are only applicable to PayTo PaymentIntent with `setup_future_usage=off_session`
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Payto::MandateOptions))
}
attr_accessor :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(mandate_options: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Payto::MandateOptions), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(mandate_options: nil, setup_future_usage: nil); end
end
class Pix < Stripe::RequestParams
# The number of seconds (between 10 and 1209600) after which Pix payment will expire. Defaults to 86400 seconds.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_after_seconds
# The timestamp at which the Pix expires (between 10 and 1209600 seconds in the future). Defaults to 1 day in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_at
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(expires_after_seconds: T.nilable(Integer), expires_at: T.nilable(Integer), setup_future_usage: T.nilable(String)).void
}
def initialize(expires_after_seconds: nil, expires_at: nil, setup_future_usage: nil); end
end
class Promptpay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Qris < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Rechnung < Stripe::RequestParams; end
class RevolutPay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class SamsungPay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
sig { params(capture_method: T.nilable(T.nilable(String))).void }
def initialize(capture_method: nil); end
end
class Satispay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
sig { params(capture_method: T.nilable(T.nilable(String))).void }
def initialize(capture_method: nil); end
end
class SepaDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'STRIPE'.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :reference_prefix
sig { params(reference_prefix: T.nilable(T.nilable(String))).void }
def initialize(reference_prefix: nil); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::SepaDebit::MandateOptions))
}
attr_accessor :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
sig {
params(mandate_options: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::SepaDebit::MandateOptions), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), target_date: T.nilable(String)).void
}
def initialize(mandate_options: nil, setup_future_usage: nil, target_date: nil); end
end
class Shopeepay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Sofort < Stripe::RequestParams
# Language shown to the payer on redirect.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :preferred_language
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(preferred_language: T.nilable(T.nilable(T.any(String, String))), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(preferred_language: nil, setup_future_usage: nil); end
end
class StripeBalance < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void }
def initialize(setup_future_usage: nil); end
end
class Swish < Stripe::RequestParams
# A reference for this payment to be displayed in the Swish app.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :reference
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(reference: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(String)).void
}
def initialize(reference: nil, setup_future_usage: nil); end
end
class Twint < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class UsBankAccount < Stripe::RequestParams
class FinancialConnections < Stripe::RequestParams
class Filters < Stripe::RequestParams
# The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :account_subcategories
# ID of the institution to use to filter for selectable accounts.
sig { returns(T.nilable(String)) }
attr_accessor :institution
sig {
params(account_subcategories: T.nilable(T::Array[String]), institution: T.nilable(String)).void
}
def initialize(account_subcategories: nil, institution: nil); end
end
class ManualEntry < Stripe::RequestParams
# Settings for configuring manual entry of account details.
sig { returns(String) }
attr_accessor :mode
sig { params(mode: String).void }
def initialize(mode: nil); end
end
# Provide filters for the linked accounts that the customer can select for the payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::Filters))
}
attr_accessor :filters
# Customize manual entry behavior
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::ManualEntry))
}
attr_accessor :manual_entry
# The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :permissions
# List of data features that you would like to retrieve upon account creation.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :prefetch
# For webview integrations only. Upon completing OAuth login in the native browser, the user will be redirected to this URL to return to your app.
sig { returns(T.nilable(String)) }
attr_accessor :return_url
sig {
params(filters: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::Filters), manual_entry: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::ManualEntry), permissions: T.nilable(T::Array[String]), prefetch: T.nilable(T::Array[String]), return_url: T.nilable(String)).void
}
def initialize(
filters: nil,
manual_entry: nil,
permissions: nil,
prefetch: nil,
return_url: nil
); end
end
class MandateOptions < Stripe::RequestParams
# The method used to collect offline mandate customer acceptance.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :collection_method
sig { params(collection_method: T.nilable(T.nilable(String))).void }
def initialize(collection_method: nil); end
end
class Networks < Stripe::RequestParams
# Triggers validations to run across the selected networks
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Array[String])).void }
def initialize(requested: nil); end
end
# Additional fields for Financial Connections Session creation
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::UsBankAccount::FinancialConnections))
}
attr_accessor :financial_connections
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::UsBankAccount::MandateOptions))
}
attr_accessor :mandate_options
# Additional fields for network related functions
sig {
returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::UsBankAccount::Networks))
}
attr_accessor :networks
# Preferred transaction settlement speed
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :preferred_settlement_speed
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
# Bank account verification method.
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(financial_connections: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::UsBankAccount::FinancialConnections), mandate_options: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::UsBankAccount::MandateOptions), networks: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::UsBankAccount::Networks), preferred_settlement_speed: T.nilable(T.nilable(T.any(String, String))), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), target_date: T.nilable(String), verification_method: T.nilable(String)).void
}
def initialize(
financial_connections: nil,
mandate_options: nil,
networks: nil,
preferred_settlement_speed: nil,
setup_future_usage: nil,
target_date: nil,
verification_method: nil
); end
end
class WechatPay < Stripe::RequestParams
# The app ID registered with WeChat Pay. Only required when client is ios or android.
sig { returns(T.nilable(String)) }
attr_accessor :app_id
# The client type that the end customer will pay from
sig { returns(T.nilable(String)) }
attr_accessor :client
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(app_id: T.nilable(String), client: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(app_id: nil, client: nil, setup_future_usage: nil); end
end
class Zip < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
# If this is a `acss_debit` PaymentMethod, this sub-hash contains details about the ACSS Debit payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::AcssDebit))))
}
attr_accessor :acss_debit
# If this is an `affirm` PaymentMethod, this sub-hash contains details about the Affirm payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Affirm))))
}
attr_accessor :affirm
# If this is a `afterpay_clearpay` PaymentMethod, this sub-hash contains details about the Afterpay Clearpay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::AfterpayClearpay))))
}
attr_accessor :afterpay_clearpay
# If this is a `alipay` PaymentMethod, this sub-hash contains details about the Alipay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Alipay))))
}
attr_accessor :alipay
# If this is a `alma` PaymentMethod, this sub-hash contains details about the Alma payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Alma))))
}
attr_accessor :alma
# If this is a `amazon_pay` PaymentMethod, this sub-hash contains details about the Amazon Pay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::AmazonPay))))
}
attr_accessor :amazon_pay
# If this is a `au_becs_debit` PaymentMethod, this sub-hash contains details about the AU BECS Direct Debit payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::AuBecsDebit))))
}
attr_accessor :au_becs_debit
# If this is a `bacs_debit` PaymentMethod, this sub-hash contains details about the BACS Debit payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::BacsDebit))))
}
attr_accessor :bacs_debit
# If this is a `bancontact` PaymentMethod, this sub-hash contains details about the Bancontact payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Bancontact))))
}
attr_accessor :bancontact
# If this is a `billie` PaymentMethod, this sub-hash contains details about the Billie payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Billie))))
}
attr_accessor :billie
# If this is a `blik` PaymentMethod, this sub-hash contains details about the BLIK payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Blik))))
}
attr_accessor :blik
# If this is a `boleto` PaymentMethod, this sub-hash contains details about the Boleto payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Boleto))))
}
attr_accessor :boleto
# Configuration for any card payments attempted on this PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Card))))
}
attr_accessor :card
# If this is a `card_present` PaymentMethod, this sub-hash contains details about the Card Present payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::CardPresent))))
}
attr_accessor :card_present
# If this is a `cashapp` PaymentMethod, this sub-hash contains details about the Cash App Pay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Cashapp))))
}
attr_accessor :cashapp
# If this is a `customer balance` PaymentMethod, this sub-hash contains details about the customer balance payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::CustomerBalance))))
}
attr_accessor :customer_balance
# If this is a `eps` PaymentMethod, this sub-hash contains details about the EPS payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Eps))))
}
attr_accessor :eps
# If this is a `fpx` PaymentMethod, this sub-hash contains details about the FPX payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Fpx))))
}
attr_accessor :fpx
# If this is a `giropay` PaymentMethod, this sub-hash contains details about the Giropay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Giropay))))
}
attr_accessor :giropay
# If this is a `gopay` PaymentMethod, this sub-hash contains details about the Gopay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Gopay))))
}
attr_accessor :gopay
# If this is a `grabpay` PaymentMethod, this sub-hash contains details about the Grabpay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Grabpay))))
}
attr_accessor :grabpay
# If this is a `id_bank_transfer` PaymentMethod, this sub-hash contains details about the Indonesia Bank Transfer payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::IdBankTransfer))))
}
attr_accessor :id_bank_transfer
# If this is a `ideal` PaymentMethod, this sub-hash contains details about the Ideal payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Ideal))))
}
attr_accessor :ideal
# If this is a `interac_present` PaymentMethod, this sub-hash contains details about the Card Present payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::InteracPresent))))
}
attr_accessor :interac_present
# If this is a `kakao_pay` PaymentMethod, this sub-hash contains details about the Kakao Pay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::KakaoPay))))
}
attr_accessor :kakao_pay
# If this is a `klarna` PaymentMethod, this sub-hash contains details about the Klarna payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Klarna))))
}
attr_accessor :klarna
# If this is a `konbini` PaymentMethod, this sub-hash contains details about the Konbini payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Konbini))))
}
attr_accessor :konbini
# If this is a `kr_card` PaymentMethod, this sub-hash contains details about the KR Card payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::KrCard))))
}
attr_accessor :kr_card
# If this is a `link` PaymentMethod, this sub-hash contains details about the Link payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Link))))
}
attr_accessor :link
# If this is a `mb_way` PaymentMethod, this sub-hash contains details about the MB WAY payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::MbWay))))
}
attr_accessor :mb_way
# If this is a `MobilePay` PaymentMethod, this sub-hash contains details about the MobilePay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Mobilepay))))
}
attr_accessor :mobilepay
# If this is a `multibanco` PaymentMethod, this sub-hash contains details about the Multibanco payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Multibanco))))
}
attr_accessor :multibanco
# If this is a `naver_pay` PaymentMethod, this sub-hash contains details about the Naver Pay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::NaverPay))))
}
attr_accessor :naver_pay
# If this is a `nz_bank_account` PaymentMethod, this sub-hash contains details about the NZ BECS Direct Debit payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::NzBankAccount))))
}
attr_accessor :nz_bank_account
# If this is a `oxxo` PaymentMethod, this sub-hash contains details about the OXXO payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Oxxo))))
}
attr_accessor :oxxo
# If this is a `p24` PaymentMethod, this sub-hash contains details about the Przelewy24 payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::P24))))
}
attr_accessor :p24
# If this is a `pay_by_bank` PaymentMethod, this sub-hash contains details about the PayByBank payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::PayByBank))))
}
attr_accessor :pay_by_bank
# If this is a `payco` PaymentMethod, this sub-hash contains details about the PAYCO payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Payco))))
}
attr_accessor :payco
# If this is a `paynow` PaymentMethod, this sub-hash contains details about the PayNow payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Paynow))))
}
attr_accessor :paynow
# If this is a `paypal` PaymentMethod, this sub-hash contains details about the PayPal payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Paypal))))
}
attr_accessor :paypal
# If this is a `payto` PaymentMethod, this sub-hash contains details about the PayTo payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Payto))))
}
attr_accessor :payto
# If this is a `pix` PaymentMethod, this sub-hash contains details about the Pix payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Pix))))
}
attr_accessor :pix
# If this is a `promptpay` PaymentMethod, this sub-hash contains details about the PromptPay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Promptpay))))
}
attr_accessor :promptpay
# If this is a `qris` PaymentMethod, this sub-hash contains details about the QRIS payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Qris))))
}
attr_accessor :qris
# If this is a `rechnung` PaymentMethod, this sub-hash contains details about the Rechnung payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Rechnung))))
}
attr_accessor :rechnung
# If this is a `revolut_pay` PaymentMethod, this sub-hash contains details about the Revolut Pay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::RevolutPay))))
}
attr_accessor :revolut_pay
# If this is a `samsung_pay` PaymentMethod, this sub-hash contains details about the Samsung Pay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::SamsungPay))))
}
attr_accessor :samsung_pay
# If this is a `satispay` PaymentMethod, this sub-hash contains details about the Satispay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Satispay))))
}
attr_accessor :satispay
# If this is a `sepa_debit` PaymentIntent, this sub-hash contains details about the SEPA Debit payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::SepaDebit))))
}
attr_accessor :sepa_debit
# If this is a `shopeepay` PaymentMethod, this sub-hash contains details about the ShopeePay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Shopeepay))))
}
attr_accessor :shopeepay
# If this is a `sofort` PaymentMethod, this sub-hash contains details about the SOFORT payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Sofort))))
}
attr_accessor :sofort
# If this is a `stripe_balance` PaymentMethod, this sub-hash contains details about the Stripe Balance payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::StripeBalance))))
}
attr_accessor :stripe_balance
# If this is a `Swish` PaymentMethod, this sub-hash contains details about the Swish payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Swish))))
}
attr_accessor :swish
# If this is a `twint` PaymentMethod, this sub-hash contains details about the TWINT payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Twint))))
}
attr_accessor :twint
# If this is a `us_bank_account` PaymentMethod, this sub-hash contains details about the US bank account payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::UsBankAccount))))
}
attr_accessor :us_bank_account
# If this is a `wechat_pay` PaymentMethod, this sub-hash contains details about the WeChat Pay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::WechatPay))))
}
attr_accessor :wechat_pay
# If this is a `zip` PaymentMethod, this sub-hash contains details about the Zip payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Zip))))
}
attr_accessor :zip
sig {
params(acss_debit: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::AcssDebit))), affirm: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Affirm))), afterpay_clearpay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::AfterpayClearpay))), alipay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Alipay))), alma: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Alma))), amazon_pay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::AmazonPay))), au_becs_debit: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::AuBecsDebit))), bacs_debit: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::BacsDebit))), bancontact: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Bancontact))), billie: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Billie))), blik: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Blik))), boleto: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Boleto))), card: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Card))), card_present: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::CardPresent))), cashapp: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Cashapp))), customer_balance: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::CustomerBalance))), eps: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Eps))), fpx: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Fpx))), giropay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Giropay))), gopay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Gopay))), grabpay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Grabpay))), id_bank_transfer: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::IdBankTransfer))), ideal: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Ideal))), interac_present: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::InteracPresent))), kakao_pay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::KakaoPay))), klarna: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Klarna))), konbini: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Konbini))), kr_card: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::KrCard))), link: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Link))), mb_way: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::MbWay))), mobilepay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Mobilepay))), multibanco: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Multibanco))), naver_pay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::NaverPay))), nz_bank_account: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::NzBankAccount))), oxxo: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Oxxo))), p24: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::P24))), pay_by_bank: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::PayByBank))), payco: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Payco))), paynow: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Paynow))), paypal: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Paypal))), payto: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Payto))), pix: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Pix))), promptpay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Promptpay))), qris: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Qris))), rechnung: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Rechnung))), revolut_pay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::RevolutPay))), samsung_pay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::SamsungPay))), satispay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Satispay))), sepa_debit: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::SepaDebit))), shopeepay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Shopeepay))), sofort: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Sofort))), stripe_balance: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::StripeBalance))), swish: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Swish))), twint: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Twint))), us_bank_account: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::UsBankAccount))), wechat_pay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::WechatPay))), zip: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions::Zip)))).void
}
def initialize(
acss_debit: nil,
affirm: nil,
afterpay_clearpay: nil,
alipay: nil,
alma: nil,
amazon_pay: nil,
au_becs_debit: nil,
bacs_debit: nil,
bancontact: nil,
billie: nil,
blik: nil,
boleto: nil,
card: nil,
card_present: nil,
cashapp: nil,
customer_balance: nil,
eps: nil,
fpx: nil,
giropay: nil,
gopay: nil,
grabpay: nil,
id_bank_transfer: nil,
ideal: nil,
interac_present: nil,
kakao_pay: nil,
klarna: nil,
konbini: nil,
kr_card: nil,
link: nil,
mb_way: nil,
mobilepay: nil,
multibanco: nil,
naver_pay: nil,
nz_bank_account: nil,
oxxo: nil,
p24: nil,
pay_by_bank: nil,
payco: nil,
paynow: nil,
paypal: nil,
payto: nil,
pix: nil,
promptpay: nil,
qris: nil,
rechnung: nil,
revolut_pay: nil,
samsung_pay: nil,
satispay: nil,
sepa_debit: nil,
shopeepay: nil,
sofort: nil,
stripe_balance: nil,
swish: nil,
twint: nil,
us_bank_account: nil,
wechat_pay: nil,
zip: nil
); end
end
class RadarOptions < Stripe::RequestParams
# A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
sig { returns(T.nilable(String)) }
attr_accessor :session
sig { params(session: T.nilable(String)).void }
def initialize(session: nil); end
end
class Shipping < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Shipping address.
sig { returns(::Stripe::PaymentIntent::ConfirmParams::Shipping::Address) }
attr_accessor :address
# The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
sig { returns(T.nilable(String)) }
attr_accessor :carrier
# Recipient name.
sig { returns(String) }
attr_accessor :name
# Recipient phone (including extension).
sig { returns(T.nilable(String)) }
attr_accessor :phone
# The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
sig { returns(T.nilable(String)) }
attr_accessor :tracking_number
sig {
params(address: ::Stripe::PaymentIntent::ConfirmParams::Shipping::Address, carrier: T.nilable(String), name: String, phone: T.nilable(String), tracking_number: T.nilable(String)).void
}
def initialize(address: nil, carrier: nil, name: nil, phone: nil, tracking_number: nil); end
end
# The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. The amount of the application fee collected will be capped at the total amount captured. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :application_fee_amount
# Controls when the funds will be captured from the customer's account.
sig { returns(T.nilable(String)) }
attr_accessor :capture_method
# ID of the ConfirmationToken used to confirm this PaymentIntent.
#
# If the provided ConfirmationToken contains properties that are also being provided in this request, such as `payment_method`, then the values in this request will take precedence.
sig { returns(T.nilable(String)) }
attr_accessor :confirmation_token
# Set to `true` to fail the payment attempt if the PaymentIntent transitions into `requires_action`. This parameter is intended for simpler integrations that do not handle customer actions, like [saving cards without authentication](https://stripe.com/docs/payments/save-card-without-authentication).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :error_on_requires_action
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The FX rate in the quote is validated and used to convert the presentment amount to the settlement amount.
sig { returns(T.nilable(String)) }
attr_accessor :fx_quote
# Automations to be run during the PaymentIntent lifecycle
sig { returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::Hooks)) }
attr_accessor :hooks
# ID of the mandate that's used for this payment.
sig { returns(T.nilable(String)) }
attr_accessor :mandate
# Attribute for param field mandate_data
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::MandateData))))
}
attr_accessor :mandate_data
# Set to `true` to indicate that the customer isn't in your checkout flow during this payment attempt and can't authenticate. Use this parameter in scenarios where you collect card details and [charge them later](https://stripe.com/docs/payments/cards/charging-saved-cards).
sig { returns(T.nilable(T.any(T::Boolean, String))) }
attr_accessor :off_session
# Provides industry-specific information about the charge.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentDetails))))
}
attr_accessor :payment_details
# ID of the payment method (a PaymentMethod, Card, or [compatible Source](https://stripe.com/docs/payments/payment-methods/transitioning#compatibility) object) to attach to this PaymentIntent.
# If the payment method is attached to a Customer, it must match the [customer](https://stripe.com/docs/api#create_payment_intent-customer) that is set on this PaymentIntent.
sig { returns(T.nilable(String)) }
attr_accessor :payment_method
# If provided, this hash will be used to create a PaymentMethod. The new PaymentMethod will appear
# in the [payment_method](https://stripe.com/docs/api/payment_intents/object#payment_intent_object-payment_method)
# property on the PaymentIntent.
sig { returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData)) }
attr_accessor :payment_method_data
# Payment method-specific configuration for this PaymentIntent.
sig { returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions)) }
attr_accessor :payment_method_options
# The list of payment method types (for example, a card) that this PaymentIntent can use. Use `automatic_payment_methods` to manage payment methods from the [Stripe Dashboard](https://dashboard.stripe.com/settings/payment_methods).
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :payment_method_types
# Options to configure Radar. Learn more about [Radar Sessions](https://stripe.com/docs/radar/radar-session).
sig { returns(T.nilable(::Stripe::PaymentIntent::ConfirmParams::RadarOptions)) }
attr_accessor :radar_options
# Email address that the receipt for the resulting payment will be sent to. If `receipt_email` is specified for a payment in live mode, a receipt will be sent regardless of your [email settings](https://dashboard.stripe.com/account/emails).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :receipt_email
# The URL to redirect your customer back to after they authenticate or cancel their payment on the payment method's app or site.
# If you'd prefer to redirect to a mobile application, you can alternatively supply an application URI scheme.
# This parameter is only used for cards and other redirect-based payment methods.
sig { returns(T.nilable(String)) }
attr_accessor :return_url
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Shipping information for this PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::Shipping))))
}
attr_accessor :shipping
# Set to `true` when confirming server-side and using Stripe.js, iOS, or Android client-side SDKs to handle the next actions.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :use_stripe_sdk
sig {
params(application_fee_amount: T.nilable(T.nilable(T.any(String, Integer))), capture_method: T.nilable(String), confirmation_token: T.nilable(String), error_on_requires_action: T.nilable(T::Boolean), expand: T.nilable(T::Array[String]), fx_quote: T.nilable(String), hooks: T.nilable(::Stripe::PaymentIntent::ConfirmParams::Hooks), mandate: T.nilable(String), mandate_data: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::MandateData))), off_session: T.nilable(T.any(T::Boolean, String)), payment_details: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::PaymentDetails))), payment_method: T.nilable(String), payment_method_data: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodData), payment_method_options: T.nilable(::Stripe::PaymentIntent::ConfirmParams::PaymentMethodOptions), payment_method_types: T.nilable(T::Array[String]), radar_options: T.nilable(::Stripe::PaymentIntent::ConfirmParams::RadarOptions), receipt_email: T.nilable(T.nilable(String)), return_url: T.nilable(String), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), shipping: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntent::ConfirmParams::Shipping))), use_stripe_sdk: T.nilable(T::Boolean)).void
}
def initialize(
application_fee_amount: nil,
capture_method: nil,
confirmation_token: nil,
error_on_requires_action: nil,
expand: nil,
fx_quote: nil,
hooks: nil,
mandate: nil,
mandate_data: nil,
off_session: nil,
payment_details: nil,
payment_method: nil,
payment_method_data: nil,
payment_method_options: nil,
payment_method_types: nil,
radar_options: nil,
receipt_email: nil,
return_url: nil,
setup_future_usage: nil,
shipping: nil,
use_stripe_sdk: nil
); end
end
class DecrementAuthorizationParams < Stripe::RequestParams
class Hooks < Stripe::RequestParams
class Inputs < Stripe::RequestParams
class Tax < Stripe::RequestParams
# The [TaxCalculation](https://stripe.com/docs/api/tax/calculations) id
sig { returns(T.nilable(String)) }
attr_accessor :calculation
sig { params(calculation: T.nilable(String)).void }
def initialize(calculation: nil); end
end
# Tax arguments for automations
sig {
returns(T.nilable(::Stripe::PaymentIntent::DecrementAuthorizationParams::Hooks::Inputs::Tax))
}
attr_accessor :tax
sig {
params(tax: T.nilable(::Stripe::PaymentIntent::DecrementAuthorizationParams::Hooks::Inputs::Tax)).void
}
def initialize(tax: nil); end
end
# Arguments passed in automations
sig {
returns(T.nilable(::Stripe::PaymentIntent::DecrementAuthorizationParams::Hooks::Inputs))
}
attr_accessor :inputs
sig {
params(inputs: T.nilable(::Stripe::PaymentIntent::DecrementAuthorizationParams::Hooks::Inputs)).void
}
def initialize(inputs: nil); end
end
class TransferData < Stripe::RequestParams
# The amount that will be transferred automatically when a charge succeeds.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
sig { params(amount: T.nilable(Integer)).void }
def initialize(amount: nil); end
end
# The updated total amount that you intend to collect from the cardholder. This amount must be smaller than the currently authorized amount and greater than the already captured amount.
sig { returns(Integer) }
attr_accessor :amount
# The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. The amount of the application fee collected will be capped at the total amount captured. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
sig { returns(T.nilable(Integer)) }
attr_accessor :application_fee_amount
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Automations to be run during the PaymentIntent lifecycle
sig { returns(T.nilable(::Stripe::PaymentIntent::DecrementAuthorizationParams::Hooks)) }
attr_accessor :hooks
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The parameters used to automatically create a transfer after the payment is captured.
# Learn more about the [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
sig {
returns(T.nilable(::Stripe::PaymentIntent::DecrementAuthorizationParams::TransferData))
}
attr_accessor :transfer_data
sig {
params(amount: Integer, application_fee_amount: T.nilable(Integer), description: T.nilable(String), expand: T.nilable(T::Array[String]), hooks: T.nilable(::Stripe::PaymentIntent::DecrementAuthorizationParams::Hooks), metadata: T.nilable(T::Hash[String, String]), transfer_data: T.nilable(::Stripe::PaymentIntent::DecrementAuthorizationParams::TransferData)).void
}
def initialize(
amount: nil,
application_fee_amount: nil,
description: nil,
expand: nil,
hooks: nil,
metadata: nil,
transfer_data: nil
); end
end
class IncrementAuthorizationParams < Stripe::RequestParams
class Hooks < Stripe::RequestParams
class Inputs < Stripe::RequestParams
class Tax < Stripe::RequestParams
# The [TaxCalculation](https://stripe.com/docs/api/tax/calculations) id
sig { returns(T.nilable(String)) }
attr_accessor :calculation
sig { params(calculation: T.nilable(String)).void }
def initialize(calculation: nil); end
end
# Tax arguments for automations
sig {
returns(T.nilable(::Stripe::PaymentIntent::IncrementAuthorizationParams::Hooks::Inputs::Tax))
}
attr_accessor :tax
sig {
params(tax: T.nilable(::Stripe::PaymentIntent::IncrementAuthorizationParams::Hooks::Inputs::Tax)).void
}
def initialize(tax: nil); end
end
# Arguments passed in automations
sig {
returns(T.nilable(::Stripe::PaymentIntent::IncrementAuthorizationParams::Hooks::Inputs))
}
attr_accessor :inputs
sig {
params(inputs: T.nilable(::Stripe::PaymentIntent::IncrementAuthorizationParams::Hooks::Inputs)).void
}
def initialize(inputs: nil); end
end
class PaymentMethodOptions < Stripe::RequestParams
class Card < Stripe::RequestParams
# Request partial authorization on this PaymentIntent.
sig { returns(T.nilable(String)) }
attr_accessor :request_partial_authorization
sig { params(request_partial_authorization: T.nilable(String)).void }
def initialize(request_partial_authorization: nil); end
end
# Configuration for any card payments attempted on this PaymentIntent.
sig {
returns(T.nilable(::Stripe::PaymentIntent::IncrementAuthorizationParams::PaymentMethodOptions::Card))
}
attr_accessor :card
sig {
params(card: T.nilable(::Stripe::PaymentIntent::IncrementAuthorizationParams::PaymentMethodOptions::Card)).void
}
def initialize(card: nil); end
end
class TransferData < Stripe::RequestParams
# The amount that will be transferred automatically when a charge succeeds.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
sig { params(amount: T.nilable(Integer)).void }
def initialize(amount: nil); end
end
# The updated total amount that you intend to collect from the cardholder. This amount must be greater than the currently authorized amount.
sig { returns(Integer) }
attr_accessor :amount
# The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. The amount of the application fee collected will be capped at the total amount captured. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
sig { returns(T.nilable(Integer)) }
attr_accessor :application_fee_amount
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Automations to be run during the PaymentIntent lifecycle
sig { returns(T.nilable(::Stripe::PaymentIntent::IncrementAuthorizationParams::Hooks)) }
attr_accessor :hooks
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Payment method-specific configuration for this PaymentIntent.
sig {
returns(T.nilable(::Stripe::PaymentIntent::IncrementAuthorizationParams::PaymentMethodOptions))
}
attr_accessor :payment_method_options
# Text that appears on the customer's statement as the statement descriptor for a non-card or card charge. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
# The parameters used to automatically create a transfer after the payment is captured.
# Learn more about the [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
sig {
returns(T.nilable(::Stripe::PaymentIntent::IncrementAuthorizationParams::TransferData))
}
attr_accessor :transfer_data
sig {
params(amount: Integer, application_fee_amount: T.nilable(Integer), description: T.nilable(String), expand: T.nilable(T::Array[String]), hooks: T.nilable(::Stripe::PaymentIntent::IncrementAuthorizationParams::Hooks), metadata: T.nilable(T::Hash[String, String]), payment_method_options: T.nilable(::Stripe::PaymentIntent::IncrementAuthorizationParams::PaymentMethodOptions), statement_descriptor: T.nilable(String), transfer_data: T.nilable(::Stripe::PaymentIntent::IncrementAuthorizationParams::TransferData)).void
}
def initialize(
amount: nil,
application_fee_amount: nil,
description: nil,
expand: nil,
hooks: nil,
metadata: nil,
payment_method_options: nil,
statement_descriptor: nil,
transfer_data: nil
); end
end
class VerifyMicrodepositsParams < Stripe::RequestParams
# Two positive integers, in *cents*, equal to the values of the microdeposits sent to the bank account.
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :amounts
# A six-character code starting with SM present in the microdeposit sent to the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :descriptor_code
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig {
params(amounts: T.nilable(T::Array[Integer]), descriptor_code: T.nilable(String), expand: T.nilable(T::Array[String])).void
}
def initialize(amounts: nil, descriptor_code: nil, expand: nil); end
end
class TriggerActionParams < Stripe::RequestParams
class ScanQrCode < Stripe::RequestParams
# Whether the QR Code scan's payment should succeed or fail.
sig { returns(T.nilable(String)) }
attr_accessor :result
sig { params(result: T.nilable(String)).void }
def initialize(result: nil); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# True to simulate success, false to simulate failure.
sig { returns(T.nilable(::Stripe::PaymentIntent::TriggerActionParams::ScanQrCode)) }
attr_accessor :scan_qr_code
# The type of action to be simulated.
sig { returns(String) }
attr_accessor :type
sig {
params(expand: T.nilable(T::Array[String]), scan_qr_code: T.nilable(::Stripe::PaymentIntent::TriggerActionParams::ScanQrCode), type: String).void
}
def initialize(expand: nil, scan_qr_code: nil, type: nil); end
end
# Manually reconcile the remaining amount for a customer_balance PaymentIntent.
sig {
params(params: T.any(::Stripe::PaymentIntent::ApplyCustomerBalanceParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentIntent)
}
def apply_customer_balance(params = {}, opts = {}); end
# Manually reconcile the remaining amount for a customer_balance PaymentIntent.
sig {
params(intent: String, params: T.any(::Stripe::PaymentIntent::ApplyCustomerBalanceParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentIntent)
}
def self.apply_customer_balance(intent, params = {}, opts = {}); end
# You can cancel a PaymentIntent object when it's in one of these statuses: requires_payment_method, requires_capture, requires_confirmation, requires_action or, [in rare cases](https://docs.stripe.com/docs/payments/intents), processing.
#
# After it's canceled, no additional charges are made by the PaymentIntent and any operations on the PaymentIntent fail with an error. For PaymentIntents with a status of requires_capture, the remaining amount_capturable is automatically refunded.
#
# You can't cancel the PaymentIntent for a Checkout Session. [Expire the Checkout Session](https://docs.stripe.com/docs/api/checkout/sessions/expire) instead.
sig {
params(params: T.any(::Stripe::PaymentIntent::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentIntent)
}
def cancel(params = {}, opts = {}); end
# You can cancel a PaymentIntent object when it's in one of these statuses: requires_payment_method, requires_capture, requires_confirmation, requires_action or, [in rare cases](https://docs.stripe.com/docs/payments/intents), processing.
#
# After it's canceled, no additional charges are made by the PaymentIntent and any operations on the PaymentIntent fail with an error. For PaymentIntents with a status of requires_capture, the remaining amount_capturable is automatically refunded.
#
# You can't cancel the PaymentIntent for a Checkout Session. [Expire the Checkout Session](https://docs.stripe.com/docs/api/checkout/sessions/expire) instead.
sig {
params(intent: String, params: T.any(::Stripe::PaymentIntent::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentIntent)
}
def self.cancel(intent, params = {}, opts = {}); end
# Capture the funds of an existing uncaptured PaymentIntent when its status is requires_capture.
#
# Uncaptured PaymentIntents are cancelled a set number of days (7 by default) after their creation.
#
# Learn more about [separate authorization and capture](https://docs.stripe.com/docs/payments/capture-later).
sig {
params(params: T.any(::Stripe::PaymentIntent::CaptureParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentIntent)
}
def capture(params = {}, opts = {}); end
# Capture the funds of an existing uncaptured PaymentIntent when its status is requires_capture.
#
# Uncaptured PaymentIntents are cancelled a set number of days (7 by default) after their creation.
#
# Learn more about [separate authorization and capture](https://docs.stripe.com/docs/payments/capture-later).
sig {
params(intent: String, params: T.any(::Stripe::PaymentIntent::CaptureParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentIntent)
}
def self.capture(intent, params = {}, opts = {}); end
# Confirm that your customer intends to pay with current or provided
# payment method. Upon confirmation, the PaymentIntent will attempt to initiate
# a payment.
# If the selected payment method requires additional authentication steps, the
# PaymentIntent will transition to the requires_action status and
# suggest additional actions via next_action. If payment fails,
# the PaymentIntent transitions to the requires_payment_method status or the
# canceled status if the confirmation limit is reached. If
# payment succeeds, the PaymentIntent will transition to the succeeded
# status (or requires_capture, if capture_method is set to manual).
# If the confirmation_method is automatic, payment may be attempted
# using our [client SDKs](https://docs.stripe.com/docs/stripe-js/reference#stripe-handle-card-payment)
# and the PaymentIntent's [client_secret](https://docs.stripe.com/api#payment_intent_object-client_secret).
# After next_actions are handled by the client, no additional
# confirmation is required to complete the payment.
# If the confirmation_method is manual, all payment attempts must be
# initiated using a secret key.
# If any actions are required for the payment, the PaymentIntent will
# return to the requires_confirmation state
# after those actions are completed. Your server needs to then
# explicitly re-confirm the PaymentIntent to initiate the next payment
# attempt.
# There is a variable upper limit on how many times a PaymentIntent can be confirmed.
# After this limit is reached, any further calls to this endpoint will
# transition the PaymentIntent to the canceled state.
sig {
params(params: T.any(::Stripe::PaymentIntent::ConfirmParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentIntent)
}
def confirm(params = {}, opts = {}); end
# Confirm that your customer intends to pay with current or provided
# payment method. Upon confirmation, the PaymentIntent will attempt to initiate
# a payment.
# If the selected payment method requires additional authentication steps, the
# PaymentIntent will transition to the requires_action status and
# suggest additional actions via next_action. If payment fails,
# the PaymentIntent transitions to the requires_payment_method status or the
# canceled status if the confirmation limit is reached. If
# payment succeeds, the PaymentIntent will transition to the succeeded
# status (or requires_capture, if capture_method is set to manual).
# If the confirmation_method is automatic, payment may be attempted
# using our [client SDKs](https://docs.stripe.com/docs/stripe-js/reference#stripe-handle-card-payment)
# and the PaymentIntent's [client_secret](https://docs.stripe.com/api#payment_intent_object-client_secret).
# After next_actions are handled by the client, no additional
# confirmation is required to complete the payment.
# If the confirmation_method is manual, all payment attempts must be
# initiated using a secret key.
# If any actions are required for the payment, the PaymentIntent will
# return to the requires_confirmation state
# after those actions are completed. Your server needs to then
# explicitly re-confirm the PaymentIntent to initiate the next payment
# attempt.
# There is a variable upper limit on how many times a PaymentIntent can be confirmed.
# After this limit is reached, any further calls to this endpoint will
# transition the PaymentIntent to the canceled state.
sig {
params(intent: String, params: T.any(::Stripe::PaymentIntent::ConfirmParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentIntent)
}
def self.confirm(intent, params = {}, opts = {}); end
# Creates a PaymentIntent object.
#
# After the PaymentIntent is created, attach a payment method and [confirm](https://docs.stripe.com/docs/api/payment_intents/confirm)
# to continue the payment. Learn more about the available payment flows
# with the Payment Intents API.
#
# When you use confirm=true during creation, it's equivalent to creating
# and confirming the PaymentIntent in the same call. You can use any parameters
# available in the [confirm API](https://docs.stripe.com/docs/api/payment_intents/confirm) when you supply
# confirm=true.
sig {
params(params: T.any(::Stripe::PaymentIntent::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentIntent)
}
def self.create(params = {}, opts = {}); end
# Perform a decremental authorization on an eligible
# [PaymentIntent](https://docs.stripe.com/docs/api/payment_intents/object). To be eligible, the
# PaymentIntent's status must be requires_capture and
# [decremental_authorization.status](https://docs.stripe.com/docs/api/charges/object#charge_object-payment_method_details-card-decremental_authorization)
# must be available.
#
# Decremental authorizations decrease the authorized amount on your customer's card
# to the new, lower amount provided. A single PaymentIntent can call this endpoint multiple times to further decrease the authorized amount.
#
# After decrement, the PaymentIntent object
# returns with the updated
# [amount](https://docs.stripe.com/docs/api/payment_intents/object#payment_intent_object-amount).
# The PaymentIntent will now be capturable up to the new authorized amount.
#
# Each PaymentIntent can have a maximum of 10 decremental or incremental authorization attempts, including declines.
# After it's fully captured, a PaymentIntent can no longer be decremented.
sig {
params(params: T.any(::Stripe::PaymentIntent::DecrementAuthorizationParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentIntent)
}
def decrement_authorization(params = {}, opts = {}); end
# Perform a decremental authorization on an eligible
# [PaymentIntent](https://docs.stripe.com/docs/api/payment_intents/object). To be eligible, the
# PaymentIntent's status must be requires_capture and
# [decremental_authorization.status](https://docs.stripe.com/docs/api/charges/object#charge_object-payment_method_details-card-decremental_authorization)
# must be available.
#
# Decremental authorizations decrease the authorized amount on your customer's card
# to the new, lower amount provided. A single PaymentIntent can call this endpoint multiple times to further decrease the authorized amount.
#
# After decrement, the PaymentIntent object
# returns with the updated
# [amount](https://docs.stripe.com/docs/api/payment_intents/object#payment_intent_object-amount).
# The PaymentIntent will now be capturable up to the new authorized amount.
#
# Each PaymentIntent can have a maximum of 10 decremental or incremental authorization attempts, including declines.
# After it's fully captured, a PaymentIntent can no longer be decremented.
sig {
params(intent: String, params: T.any(::Stripe::PaymentIntent::DecrementAuthorizationParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentIntent)
}
def self.decrement_authorization(intent, params = {}, opts = {}); end
# Perform an incremental authorization on an eligible
# [PaymentIntent](https://docs.stripe.com/docs/api/payment_intents/object). To be eligible, the
# PaymentIntent's status must be requires_capture and
# [incremental_authorization_supported](https://docs.stripe.com/docs/api/charges/object#charge_object-payment_method_details-card_present-incremental_authorization_supported)
# must be true.
#
# Incremental authorizations attempt to increase the authorized amount on
# your customer's card to the new, higher amount provided. Similar to the
# initial authorization, incremental authorizations can be declined. A
# single PaymentIntent can call this endpoint multiple times to further
# increase the authorized amount.
#
# If the incremental authorization succeeds, the PaymentIntent object
# returns with the updated
# [amount](https://docs.stripe.com/docs/api/payment_intents/object#payment_intent_object-amount).
# If the incremental authorization fails, a
# [card_declined](https://docs.stripe.com/docs/error-codes#card-declined) error returns, and no other
# fields on the PaymentIntent or Charge update. The PaymentIntent
# object remains capturable for the previously authorized amount.
#
# Each PaymentIntent can have a maximum of 10 incremental authorization attempts, including declines.
# After it's captured, a PaymentIntent can no longer be incremented.
#
# Learn more about [incremental authorizations](https://docs.stripe.com/docs/terminal/features/incremental-authorizations).
sig {
params(params: T.any(::Stripe::PaymentIntent::IncrementAuthorizationParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentIntent)
}
def increment_authorization(params = {}, opts = {}); end
# Perform an incremental authorization on an eligible
# [PaymentIntent](https://docs.stripe.com/docs/api/payment_intents/object). To be eligible, the
# PaymentIntent's status must be requires_capture and
# [incremental_authorization_supported](https://docs.stripe.com/docs/api/charges/object#charge_object-payment_method_details-card_present-incremental_authorization_supported)
# must be true.
#
# Incremental authorizations attempt to increase the authorized amount on
# your customer's card to the new, higher amount provided. Similar to the
# initial authorization, incremental authorizations can be declined. A
# single PaymentIntent can call this endpoint multiple times to further
# increase the authorized amount.
#
# If the incremental authorization succeeds, the PaymentIntent object
# returns with the updated
# [amount](https://docs.stripe.com/docs/api/payment_intents/object#payment_intent_object-amount).
# If the incremental authorization fails, a
# [card_declined](https://docs.stripe.com/docs/error-codes#card-declined) error returns, and no other
# fields on the PaymentIntent or Charge update. The PaymentIntent
# object remains capturable for the previously authorized amount.
#
# Each PaymentIntent can have a maximum of 10 incremental authorization attempts, including declines.
# After it's captured, a PaymentIntent can no longer be incremented.
#
# Learn more about [incremental authorizations](https://docs.stripe.com/docs/terminal/features/incremental-authorizations).
sig {
params(intent: String, params: T.any(::Stripe::PaymentIntent::IncrementAuthorizationParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentIntent)
}
def self.increment_authorization(intent, params = {}, opts = {}); end
# Returns a list of PaymentIntents.
sig {
params(params: T.any(::Stripe::PaymentIntent::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
sig {
params(params: T.any(::Stripe::PaymentIntent::SearchParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SearchResultObject)
}
def self.search(params = {}, opts = {}); end
sig {
params(params: T.any(::Stripe::PaymentIntent::SearchParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped, blk: T.untyped).returns(Stripe::SearchResultObject)
}
def self.search_auto_paging_each(params = {}, opts = {}, &blk); end
# Trigger an external action on a PaymentIntent.
sig {
params(params: T.any(::Stripe::PaymentIntent::TriggerActionParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentIntent)
}
def trigger_action(params = {}, opts = {}); end
# Trigger an external action on a PaymentIntent.
sig {
params(intent: String, params: T.any(::Stripe::PaymentIntent::TriggerActionParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentIntent)
}
def self.trigger_action(intent, params = {}, opts = {}); end
# Updates properties on a PaymentIntent object without confirming.
#
# Depending on which properties you update, you might need to confirm the
# PaymentIntent again. For example, updating the payment_method
# always requires you to confirm the PaymentIntent again. If you prefer to
# update and confirm at the same time, we recommend updating properties through
# the [confirm API](https://docs.stripe.com/docs/api/payment_intents/confirm) instead.
sig {
params(intent: String, params: T.any(::Stripe::PaymentIntent::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentIntent)
}
def self.update(intent, params = {}, opts = {}); end
# Verifies microdeposits on a PaymentIntent object.
sig {
params(params: T.any(::Stripe::PaymentIntent::VerifyMicrodepositsParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentIntent)
}
def verify_microdeposits(params = {}, opts = {}); end
# Verifies microdeposits on a PaymentIntent object.
sig {
params(intent: String, params: T.any(::Stripe::PaymentIntent::VerifyMicrodepositsParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentIntent)
}
def self.verify_microdeposits(intent, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class PaymentIntentAmountDetailsLineItem < APIResource
class PaymentMethodOptions < Stripe::StripeObject
class Card < Stripe::StripeObject
# Attribute for field commodity_code
sig { returns(T.nilable(String)) }
attr_reader :commodity_code
end
class CardPresent < Stripe::StripeObject
# Attribute for field commodity_code
sig { returns(T.nilable(String)) }
attr_reader :commodity_code
end
class Klarna < Stripe::StripeObject
# Attribute for field image_url
sig { returns(T.nilable(String)) }
attr_reader :image_url
# Attribute for field product_url
sig { returns(T.nilable(String)) }
attr_reader :product_url
end
class Paypal < Stripe::StripeObject
# Type of the line item.
sig { returns(String) }
attr_reader :category
# Description of the line item.
sig { returns(String) }
attr_reader :description
# The Stripe account ID of the connected account that sells the item. This is only needed when using [Separate Charges and Transfers](https://docs.stripe.com/connect/separate-charges-and-transfers).
sig { returns(String) }
attr_reader :sold_by
end
# Attribute for field card
sig { returns(Card) }
attr_reader :card
# Attribute for field card_present
sig { returns(CardPresent) }
attr_reader :card_present
# Attribute for field klarna
sig { returns(Klarna) }
attr_reader :klarna
# Attribute for field paypal
sig { returns(Paypal) }
attr_reader :paypal
end
class Tax < Stripe::StripeObject
# Total portion of the amount that is for tax.
sig { returns(Integer) }
attr_reader :total_tax_amount
end
# The amount an item was discounted for. Positive integer.
sig { returns(T.nilable(Integer)) }
attr_reader :discount_amount
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Payment method-specific information for line items.
sig { returns(T.nilable(PaymentMethodOptions)) }
attr_reader :payment_method_options
# Unique identifier of the product. At most 12 characters long.
sig { returns(T.nilable(String)) }
attr_reader :product_code
# Name of the product. At most 100 characters long.
sig { returns(String) }
attr_reader :product_name
# Number of items of the product. Positive integer.
sig { returns(Integer) }
attr_reader :quantity
# Contains information about the tax on the item.
sig { returns(T.nilable(Tax)) }
attr_reader :tax
# Cost of the product. Non-negative integer.
sig { returns(Integer) }
attr_reader :unit_cost
# A unit of measure for the line item, such as gallons, feet, meters, etc.
sig { returns(T.nilable(String)) }
attr_reader :unit_of_measure
end
end
# typed: true
module Stripe
# A payment link is a shareable URL that will take your customers to a hosted payment page. A payment link can be shared and used multiple times.
#
# When a customer opens a payment link it will open a new [checkout session](https://stripe.com/docs/api/checkout/sessions) to render the payment page. You can use [checkout session events](https://stripe.com/docs/api/events/types#event_types-checkout.session.completed) to track payments through payment links.
#
# Related guide: [Payment Links API](https://stripe.com/docs/payment-links)
class PaymentLink < APIResource
class AfterCompletion < Stripe::StripeObject
class HostedConfirmation < Stripe::StripeObject
# The custom message that is displayed to the customer after the purchase is complete.
sig { returns(T.nilable(String)) }
attr_reader :custom_message
end
class Redirect < Stripe::StripeObject
# The URL the customer will be redirected to after the purchase is complete.
sig { returns(String) }
attr_reader :url
end
# Attribute for field hosted_confirmation
sig { returns(HostedConfirmation) }
attr_reader :hosted_confirmation
# Attribute for field redirect
sig { returns(Redirect) }
attr_reader :redirect
# The specified behavior after the purchase is complete.
sig { returns(String) }
attr_reader :type
end
class AutomaticTax < Stripe::StripeObject
class Liability < Stripe::StripeObject
# The connected account being referenced when `type` is `account`.
sig { returns(T.any(String, Stripe::Account)) }
attr_reader :account
# Type of the account referenced.
sig { returns(String) }
attr_reader :type
end
# If `true`, tax will be calculated automatically using the customer's location.
sig { returns(T::Boolean) }
attr_reader :enabled
# The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
sig { returns(T.nilable(Liability)) }
attr_reader :liability
end
class ConsentCollection < Stripe::StripeObject
class PaymentMethodReuseAgreement < Stripe::StripeObject
# Determines the position and visibility of the payment method reuse agreement in the UI. When set to `auto`, Stripe's defaults will be used.
#
# When set to `hidden`, the payment method reuse agreement text will always be hidden in the UI.
sig { returns(String) }
attr_reader :position
end
# Settings related to the payment method reuse text shown in the Checkout UI.
sig { returns(T.nilable(PaymentMethodReuseAgreement)) }
attr_reader :payment_method_reuse_agreement
# If set to `auto`, enables the collection of customer consent for promotional communications.
sig { returns(T.nilable(String)) }
attr_reader :promotions
# If set to `required`, it requires cutomers to accept the terms of service before being able to pay. If set to `none`, customers won't be shown a checkbox to accept the terms of service.
sig { returns(T.nilable(String)) }
attr_reader :terms_of_service
end
class CustomField < Stripe::StripeObject
class Dropdown < Stripe::StripeObject
class Option < Stripe::StripeObject
# The label for the option, displayed to the customer. Up to 100 characters.
sig { returns(String) }
attr_reader :label
# The value for this option, not displayed to the customer, used by your integration to reconcile the option selected by the customer. Must be unique to this option, alphanumeric, and up to 100 characters.
sig { returns(String) }
attr_reader :value
end
# The value that will pre-fill on the payment page.
sig { returns(T.nilable(String)) }
attr_reader :default_value
# The options available for the customer to select. Up to 200 options allowed.
sig { returns(T::Array[Option]) }
attr_reader :options
end
class Label < Stripe::StripeObject
# Custom text for the label, displayed to the customer. Up to 50 characters.
sig { returns(T.nilable(String)) }
attr_reader :custom
# The type of the label.
sig { returns(String) }
attr_reader :type
end
class Numeric < Stripe::StripeObject
# The value that will pre-fill the field on the payment page.
sig { returns(T.nilable(String)) }
attr_reader :default_value
# The maximum character length constraint for the customer's input.
sig { returns(T.nilable(Integer)) }
attr_reader :maximum_length
# The minimum character length requirement for the customer's input.
sig { returns(T.nilable(Integer)) }
attr_reader :minimum_length
end
class Text < Stripe::StripeObject
# The value that will pre-fill the field on the payment page.
sig { returns(T.nilable(String)) }
attr_reader :default_value
# The maximum character length constraint for the customer's input.
sig { returns(T.nilable(Integer)) }
attr_reader :maximum_length
# The minimum character length requirement for the customer's input.
sig { returns(T.nilable(Integer)) }
attr_reader :minimum_length
end
# Attribute for field dropdown
sig { returns(Dropdown) }
attr_reader :dropdown
# String of your choice that your integration can use to reconcile this field. Must be unique to this field, alphanumeric, and up to 200 characters.
sig { returns(String) }
attr_reader :key
# Attribute for field label
sig { returns(Label) }
attr_reader :label
# Attribute for field numeric
sig { returns(Numeric) }
attr_reader :numeric
# Whether the customer is required to complete the field before completing the Checkout Session. Defaults to `false`.
sig { returns(T::Boolean) }
attr_reader :optional
# Attribute for field text
sig { returns(Text) }
attr_reader :text
# The type of the field.
sig { returns(String) }
attr_reader :type
end
class CustomText < Stripe::StripeObject
class AfterSubmit < Stripe::StripeObject
# Text may be up to 1200 characters in length.
sig { returns(String) }
attr_reader :message
end
class ShippingAddress < Stripe::StripeObject
# Text may be up to 1200 characters in length.
sig { returns(String) }
attr_reader :message
end
class Submit < Stripe::StripeObject
# Text may be up to 1200 characters in length.
sig { returns(String) }
attr_reader :message
end
class TermsOfServiceAcceptance < Stripe::StripeObject
# Text may be up to 1200 characters in length.
sig { returns(String) }
attr_reader :message
end
# Custom text that should be displayed after the payment confirmation button.
sig { returns(T.nilable(AfterSubmit)) }
attr_reader :after_submit
# Custom text that should be displayed alongside shipping address collection.
sig { returns(T.nilable(ShippingAddress)) }
attr_reader :shipping_address
# Custom text that should be displayed alongside the payment confirmation button.
sig { returns(T.nilable(Submit)) }
attr_reader :submit
# Custom text that should be displayed in place of the default terms of service agreement text.
sig { returns(T.nilable(TermsOfServiceAcceptance)) }
attr_reader :terms_of_service_acceptance
end
class InvoiceCreation < Stripe::StripeObject
class InvoiceData < Stripe::StripeObject
class CustomField < Stripe::StripeObject
# The name of the custom field.
sig { returns(String) }
attr_reader :name
# The value of the custom field.
sig { returns(String) }
attr_reader :value
end
class Issuer < Stripe::StripeObject
# The connected account being referenced when `type` is `account`.
sig { returns(T.any(String, Stripe::Account)) }
attr_reader :account
# Type of the account referenced.
sig { returns(String) }
attr_reader :type
end
class RenderingOptions < Stripe::StripeObject
# How line-item prices and amounts will be displayed with respect to tax on invoice PDFs.
sig { returns(T.nilable(String)) }
attr_reader :amount_tax_display
end
# The account tax IDs associated with the invoice.
sig { returns(T.nilable(T::Array[T.any(String, Stripe::TaxId)])) }
attr_reader :account_tax_ids
# A list of up to 4 custom fields to be displayed on the invoice.
sig { returns(T.nilable(T::Array[CustomField])) }
attr_reader :custom_fields
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_reader :description
# Footer to be displayed on the invoice.
sig { returns(T.nilable(String)) }
attr_reader :footer
# The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
sig { returns(T.nilable(Issuer)) }
attr_reader :issuer
# 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.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# Options for invoice PDF rendering.
sig { returns(T.nilable(RenderingOptions)) }
attr_reader :rendering_options
end
# Enable creating an invoice on successful payment.
sig { returns(T::Boolean) }
attr_reader :enabled
# Configuration for the invoice. Default invoice values will be used if unspecified.
sig { returns(T.nilable(InvoiceData)) }
attr_reader :invoice_data
end
class OptionalItem < Stripe::StripeObject
class AdjustableQuantity < Stripe::StripeObject
# Set to true if the quantity can be adjusted to any non-negative integer.
sig { returns(T::Boolean) }
attr_reader :enabled
# The maximum quantity of this item the customer can purchase. By default this value is 99.
sig { returns(T.nilable(Integer)) }
attr_reader :maximum
# The minimum quantity of this item the customer must purchase, if they choose to purchase it. Because this item is optional, the customer will always be able to remove it from their order, even if the `minimum` configured here is greater than 0. By default this value is 0.
sig { returns(T.nilable(Integer)) }
attr_reader :minimum
end
# Attribute for field adjustable_quantity
sig { returns(T.nilable(AdjustableQuantity)) }
attr_reader :adjustable_quantity
# Attribute for field price
sig { returns(String) }
attr_reader :price
# Attribute for field quantity
sig { returns(Integer) }
attr_reader :quantity
end
class PaymentIntentData < Stripe::StripeObject
# Indicates when the funds will be captured from the customer's account.
sig { returns(T.nilable(String)) }
attr_reader :capture_method
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_reader :description
# Set of [key-value pairs](https://stripe.com/docs/api/metadata) that will set metadata on [Payment Intents](https://stripe.com/docs/api/payment_intents) generated from this payment link.
sig { returns(T::Hash[String, String]) }
attr_reader :metadata
# Indicates that you intend to make future payments with the payment method collected during checkout.
sig { returns(T.nilable(String)) }
attr_reader :setup_future_usage
# For a non-card payment, information about the charge that appears on the customer's statement when this payment succeeds in creating a charge.
sig { returns(T.nilable(String)) }
attr_reader :statement_descriptor
# For a card payment, information about the charge that appears on the customer's statement when this payment succeeds in creating a charge. Concatenated with the account's statement descriptor prefix to form the complete statement descriptor.
sig { returns(T.nilable(String)) }
attr_reader :statement_descriptor_suffix
# A string that identifies the resulting payment as part of a group. See the PaymentIntents [use case for connected accounts](https://stripe.com/docs/connect/separate-charges-and-transfers) for details.
sig { returns(T.nilable(String)) }
attr_reader :transfer_group
end
class PhoneNumberCollection < Stripe::StripeObject
# If `true`, a phone number will be collected during checkout.
sig { returns(T::Boolean) }
attr_reader :enabled
end
class Restrictions < Stripe::StripeObject
class CompletedSessions < Stripe::StripeObject
# The current number of checkout sessions that have been completed on the payment link which count towards the `completed_sessions` restriction to be met.
sig { returns(Integer) }
attr_reader :count
# The maximum number of checkout sessions that can be completed for the `completed_sessions` restriction to be met.
sig { returns(Integer) }
attr_reader :limit
end
# Attribute for field completed_sessions
sig { returns(CompletedSessions) }
attr_reader :completed_sessions
end
class ShippingAddressCollection < Stripe::StripeObject
# An array of two-letter ISO country codes representing which countries Checkout should provide as options for shipping locations. Unsupported country codes: `AS, CX, CC, CU, HM, IR, KP, MH, FM, NF, MP, PW, SD, SY, UM, VI`.
sig { returns(T::Array[String]) }
attr_reader :allowed_countries
end
class ShippingOption < Stripe::StripeObject
# A non-negative integer in cents representing how much to charge.
sig { returns(Integer) }
attr_reader :shipping_amount
# The ID of the Shipping Rate to use for this shipping option.
sig { returns(T.any(String, Stripe::ShippingRate)) }
attr_reader :shipping_rate
end
class SubscriptionData < Stripe::StripeObject
class InvoiceSettings < Stripe::StripeObject
class Issuer < Stripe::StripeObject
# The connected account being referenced when `type` is `account`.
sig { returns(T.any(String, Stripe::Account)) }
attr_reader :account
# Type of the account referenced.
sig { returns(String) }
attr_reader :type
end
# Attribute for field issuer
sig { returns(Issuer) }
attr_reader :issuer
end
class TrialSettings < Stripe::StripeObject
class EndBehavior < Stripe::StripeObject
# Indicates how the subscription should change when the trial ends if the user did not provide a payment method.
sig { returns(String) }
attr_reader :missing_payment_method
end
# Defines how a subscription behaves when a free trial ends.
sig { returns(EndBehavior) }
attr_reader :end_behavior
end
# The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
sig { returns(T.nilable(String)) }
attr_reader :description
# Attribute for field invoice_settings
sig { returns(InvoiceSettings) }
attr_reader :invoice_settings
# Set of [key-value pairs](https://stripe.com/docs/api/metadata) that will set metadata on [Subscriptions](https://stripe.com/docs/api/subscriptions) generated from this payment link.
sig { returns(T::Hash[String, String]) }
attr_reader :metadata
# Integer representing the number of trial period days before the customer is charged for the first time.
sig { returns(T.nilable(Integer)) }
attr_reader :trial_period_days
# Settings related to subscription trials.
sig { returns(T.nilable(TrialSettings)) }
attr_reader :trial_settings
end
class TaxIdCollection < Stripe::StripeObject
# Indicates whether tax ID collection is enabled for the session.
sig { returns(T::Boolean) }
attr_reader :enabled
# Attribute for field required
sig { returns(String) }
attr_reader :required
end
class TransferData < Stripe::StripeObject
# The amount in cents (or local equivalent) that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
sig { returns(T.nilable(Integer)) }
attr_reader :amount
# The connected account receiving the transfer.
sig { returns(T.any(String, Stripe::Account)) }
attr_reader :destination
end
# Whether the payment link's `url` is active. If `false`, customers visiting the URL will be shown a page saying that the link has been deactivated.
sig { returns(T::Boolean) }
attr_reader :active
# Attribute for field after_completion
sig { returns(AfterCompletion) }
attr_reader :after_completion
# Whether user redeemable promotion codes are enabled.
sig { returns(T::Boolean) }
attr_reader :allow_promotion_codes
# The ID of the Connect application that created the Payment Link.
sig { returns(T.nilable(T.any(String, Stripe::Application))) }
attr_reader :application
# The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account.
sig { returns(T.nilable(Integer)) }
attr_reader :application_fee_amount
# This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account.
sig { returns(T.nilable(Float)) }
attr_reader :application_fee_percent
# Attribute for field automatic_tax
sig { returns(AutomaticTax) }
attr_reader :automatic_tax
# Configuration for collecting the customer's billing address. Defaults to `auto`.
sig { returns(String) }
attr_reader :billing_address_collection
# When set, provides configuration to gather active consent from customers.
sig { returns(T.nilable(ConsentCollection)) }
attr_reader :consent_collection
# 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).
sig { returns(String) }
attr_reader :currency
# Collect additional information from your customer using custom fields. Up to 3 fields are supported.
sig { returns(T::Array[CustomField]) }
attr_reader :custom_fields
# Attribute for field custom_text
sig { returns(CustomText) }
attr_reader :custom_text
# Configuration for Customer creation during checkout.
sig { returns(String) }
attr_reader :customer_creation
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# The custom message to be displayed to a customer when a payment link is no longer active.
sig { returns(T.nilable(String)) }
attr_reader :inactive_message
# Configuration for creating invoice for payment mode payment links.
sig { returns(T.nilable(InvoiceCreation)) }
attr_reader :invoice_creation
# The line items representing what is being sold.
sig { returns(Stripe::ListObject) }
attr_reader :line_items
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# 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.
sig { returns(T::Hash[String, String]) }
attr_reader :metadata
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The account on behalf of which to charge. See the [Connect documentation](https://support.stripe.com/questions/sending-invoices-on-behalf-of-connected-accounts) for details.
sig { returns(T.nilable(T.any(String, Stripe::Account))) }
attr_reader :on_behalf_of
# The optional items presented to the customer at checkout.
sig { returns(T.nilable(T::Array[OptionalItem])) }
attr_reader :optional_items
# Indicates the parameters to be passed to PaymentIntent creation during checkout.
sig { returns(T.nilable(PaymentIntentData)) }
attr_reader :payment_intent_data
# Configuration for collecting a payment method during checkout. Defaults to `always`.
sig { returns(String) }
attr_reader :payment_method_collection
# The list of payment method types that customers can use. When `null`, Stripe will dynamically show relevant payment methods you've enabled in your [payment method settings](https://dashboard.stripe.com/settings/payment_methods).
sig { returns(T.nilable(T::Array[String])) }
attr_reader :payment_method_types
# Attribute for field phone_number_collection
sig { returns(PhoneNumberCollection) }
attr_reader :phone_number_collection
# Settings that restrict the usage of a payment link.
sig { returns(T.nilable(Restrictions)) }
attr_reader :restrictions
# Configuration for collecting the customer's shipping address.
sig { returns(T.nilable(ShippingAddressCollection)) }
attr_reader :shipping_address_collection
# The shipping rate options applied to the session.
sig { returns(T::Array[ShippingOption]) }
attr_reader :shipping_options
# Indicates the type of transaction being performed which customizes relevant text on the page, such as the submit button.
sig { returns(String) }
attr_reader :submit_type
# When creating a subscription, the specified configuration data will be used. There must be at least one line item with a recurring price to use `subscription_data`.
sig { returns(T.nilable(SubscriptionData)) }
attr_reader :subscription_data
# Attribute for field tax_id_collection
sig { returns(TaxIdCollection) }
attr_reader :tax_id_collection
# The account (if any) the payments will be attributed to for tax reporting, and where funds from each payment will be transferred to.
sig { returns(T.nilable(TransferData)) }
attr_reader :transfer_data
# The public URL that can be shared with customers.
sig { returns(String) }
attr_reader :url
class ListParams < Stripe::RequestParams
# Only return payment links that are active or inactive (e.g., pass `false` to list all inactive payment links).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(active: T.nilable(T::Boolean), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
active: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class AfterCompletion < Stripe::RequestParams
class HostedConfirmation < Stripe::RequestParams
# A custom message to display to the customer after the purchase is complete.
sig { returns(T.nilable(String)) }
attr_accessor :custom_message
sig { params(custom_message: T.nilable(String)).void }
def initialize(custom_message: nil); end
end
class Redirect < Stripe::RequestParams
# The URL the customer will be redirected to after the purchase is complete. You can embed `{CHECKOUT_SESSION_ID}` into the URL to have the `id` of the completed [checkout session](https://stripe.com/docs/api/checkout/sessions/object#checkout_session_object-id) included.
sig { returns(String) }
attr_accessor :url
sig { params(url: String).void }
def initialize(url: nil); end
end
# Configuration when `type=hosted_confirmation`.
sig {
returns(T.nilable(::Stripe::PaymentLink::CreateParams::AfterCompletion::HostedConfirmation))
}
attr_accessor :hosted_confirmation
# Configuration when `type=redirect`.
sig { returns(T.nilable(::Stripe::PaymentLink::CreateParams::AfterCompletion::Redirect)) }
attr_accessor :redirect
# The specified behavior after the purchase is complete. Either `redirect` or `hosted_confirmation`.
sig { returns(String) }
attr_accessor :type
sig {
params(hosted_confirmation: T.nilable(::Stripe::PaymentLink::CreateParams::AfterCompletion::HostedConfirmation), redirect: T.nilable(::Stripe::PaymentLink::CreateParams::AfterCompletion::Redirect), type: String).void
}
def initialize(hosted_confirmation: nil, redirect: nil, type: nil); end
end
class AutomaticTax < Stripe::RequestParams
class Liability < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# Set to `true` to [calculate tax automatically](https://docs.stripe.com/tax) using the customer's location.
#
# Enabling this parameter causes the payment link to collect any billing address information necessary for tax calculation.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
sig { returns(T.nilable(::Stripe::PaymentLink::CreateParams::AutomaticTax::Liability)) }
attr_accessor :liability
sig {
params(enabled: T::Boolean, liability: T.nilable(::Stripe::PaymentLink::CreateParams::AutomaticTax::Liability)).void
}
def initialize(enabled: nil, liability: nil); end
end
class ConsentCollection < Stripe::RequestParams
class PaymentMethodReuseAgreement < Stripe::RequestParams
# Determines the position and visibility of the payment method reuse agreement in the UI. When set to `auto`, Stripe's
# defaults will be used. When set to `hidden`, the payment method reuse agreement text will always be hidden in the UI.
sig { returns(String) }
attr_accessor :position
sig { params(position: String).void }
def initialize(position: nil); end
end
# Determines the display of payment method reuse agreement text in the UI. If set to `hidden`, it will hide legal text related to the reuse of a payment method.
sig {
returns(T.nilable(::Stripe::PaymentLink::CreateParams::ConsentCollection::PaymentMethodReuseAgreement))
}
attr_accessor :payment_method_reuse_agreement
# If set to `auto`, enables the collection of customer consent for promotional communications. The Checkout
# Session will determine whether to display an option to opt into promotional communication
# from the merchant depending on the customer's locale. Only available to US merchants.
sig { returns(T.nilable(String)) }
attr_accessor :promotions
# If set to `required`, it requires customers to check a terms of service checkbox before being able to pay.
# There must be a valid terms of service URL set in your [Dashboard settings](https://dashboard.stripe.com/settings/public).
sig { returns(T.nilable(String)) }
attr_accessor :terms_of_service
sig {
params(payment_method_reuse_agreement: T.nilable(::Stripe::PaymentLink::CreateParams::ConsentCollection::PaymentMethodReuseAgreement), promotions: T.nilable(String), terms_of_service: T.nilable(String)).void
}
def initialize(
payment_method_reuse_agreement: nil,
promotions: nil,
terms_of_service: nil
); end
end
class CustomField < Stripe::RequestParams
class Dropdown < Stripe::RequestParams
class Option < Stripe::RequestParams
# The label for the option, displayed to the customer. Up to 100 characters.
sig { returns(String) }
attr_accessor :label
# The value for this option, not displayed to the customer, used by your integration to reconcile the option selected by the customer. Must be unique to this option, alphanumeric, and up to 100 characters.
sig { returns(String) }
attr_accessor :value
sig { params(label: String, value: String).void }
def initialize(label: nil, value: nil); end
end
# The value that will pre-fill the field on the payment page.Must match a `value` in the `options` array.
sig { returns(T.nilable(String)) }
attr_accessor :default_value
# The options available for the customer to select. Up to 200 options allowed.
sig {
returns(T::Array[::Stripe::PaymentLink::CreateParams::CustomField::Dropdown::Option])
}
attr_accessor :options
sig {
params(default_value: T.nilable(String), options: T::Array[::Stripe::PaymentLink::CreateParams::CustomField::Dropdown::Option]).void
}
def initialize(default_value: nil, options: nil); end
end
class Label < Stripe::RequestParams
# Custom text for the label, displayed to the customer. Up to 50 characters.
sig { returns(String) }
attr_accessor :custom
# The type of the label.
sig { returns(String) }
attr_accessor :type
sig { params(custom: String, type: String).void }
def initialize(custom: nil, type: nil); end
end
class Numeric < Stripe::RequestParams
# The value that will pre-fill the field on the payment page.
sig { returns(T.nilable(String)) }
attr_accessor :default_value
# The maximum character length constraint for the customer's input.
sig { returns(T.nilable(Integer)) }
attr_accessor :maximum_length
# The minimum character length requirement for the customer's input.
sig { returns(T.nilable(Integer)) }
attr_accessor :minimum_length
sig {
params(default_value: T.nilable(String), maximum_length: T.nilable(Integer), minimum_length: T.nilable(Integer)).void
}
def initialize(default_value: nil, maximum_length: nil, minimum_length: nil); end
end
class Text < Stripe::RequestParams
# The value that will pre-fill the field on the payment page.
sig { returns(T.nilable(String)) }
attr_accessor :default_value
# The maximum character length constraint for the customer's input.
sig { returns(T.nilable(Integer)) }
attr_accessor :maximum_length
# The minimum character length requirement for the customer's input.
sig { returns(T.nilable(Integer)) }
attr_accessor :minimum_length
sig {
params(default_value: T.nilable(String), maximum_length: T.nilable(Integer), minimum_length: T.nilable(Integer)).void
}
def initialize(default_value: nil, maximum_length: nil, minimum_length: nil); end
end
# Configuration for `type=dropdown` fields.
sig { returns(T.nilable(::Stripe::PaymentLink::CreateParams::CustomField::Dropdown)) }
attr_accessor :dropdown
# String of your choice that your integration can use to reconcile this field. Must be unique to this field, alphanumeric, and up to 200 characters.
sig { returns(String) }
attr_accessor :key
# The label for the field, displayed to the customer.
sig { returns(::Stripe::PaymentLink::CreateParams::CustomField::Label) }
attr_accessor :label
# Configuration for `type=numeric` fields.
sig { returns(T.nilable(::Stripe::PaymentLink::CreateParams::CustomField::Numeric)) }
attr_accessor :numeric
# Whether the customer is required to complete the field before completing the Checkout Session. Defaults to `false`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :optional
# Configuration for `type=text` fields.
sig { returns(T.nilable(::Stripe::PaymentLink::CreateParams::CustomField::Text)) }
attr_accessor :text
# The type of the field.
sig { returns(String) }
attr_accessor :type
sig {
params(dropdown: T.nilable(::Stripe::PaymentLink::CreateParams::CustomField::Dropdown), key: String, label: ::Stripe::PaymentLink::CreateParams::CustomField::Label, numeric: T.nilable(::Stripe::PaymentLink::CreateParams::CustomField::Numeric), optional: T.nilable(T::Boolean), text: T.nilable(::Stripe::PaymentLink::CreateParams::CustomField::Text), type: String).void
}
def initialize(
dropdown: nil,
key: nil,
label: nil,
numeric: nil,
optional: nil,
text: nil,
type: nil
); end
end
class CustomText < Stripe::RequestParams
class AfterSubmit < Stripe::RequestParams
# Text may be up to 1200 characters in length.
sig { returns(String) }
attr_accessor :message
sig { params(message: String).void }
def initialize(message: nil); end
end
class ShippingAddress < Stripe::RequestParams
# Text may be up to 1200 characters in length.
sig { returns(String) }
attr_accessor :message
sig { params(message: String).void }
def initialize(message: nil); end
end
class Submit < Stripe::RequestParams
# Text may be up to 1200 characters in length.
sig { returns(String) }
attr_accessor :message
sig { params(message: String).void }
def initialize(message: nil); end
end
class TermsOfServiceAcceptance < Stripe::RequestParams
# Text may be up to 1200 characters in length.
sig { returns(String) }
attr_accessor :message
sig { params(message: String).void }
def initialize(message: nil); end
end
# Custom text that should be displayed after the payment confirmation button.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLink::CreateParams::CustomText::AfterSubmit))))
}
attr_accessor :after_submit
# Custom text that should be displayed alongside shipping address collection.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLink::CreateParams::CustomText::ShippingAddress))))
}
attr_accessor :shipping_address
# Custom text that should be displayed alongside the payment confirmation button.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLink::CreateParams::CustomText::Submit))))
}
attr_accessor :submit
# Custom text that should be displayed in place of the default terms of service agreement text.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLink::CreateParams::CustomText::TermsOfServiceAcceptance))))
}
attr_accessor :terms_of_service_acceptance
sig {
params(after_submit: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLink::CreateParams::CustomText::AfterSubmit))), shipping_address: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLink::CreateParams::CustomText::ShippingAddress))), submit: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLink::CreateParams::CustomText::Submit))), terms_of_service_acceptance: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLink::CreateParams::CustomText::TermsOfServiceAcceptance)))).void
}
def initialize(
after_submit: nil,
shipping_address: nil,
submit: nil,
terms_of_service_acceptance: nil
); end
end
class InvoiceCreation < Stripe::RequestParams
class InvoiceData < Stripe::RequestParams
class CustomField < Stripe::RequestParams
# The name of the custom field. This may be up to 40 characters.
sig { returns(String) }
attr_accessor :name
# The value of the custom field. This may be up to 140 characters.
sig { returns(String) }
attr_accessor :value
sig { params(name: String, value: String).void }
def initialize(name: nil, value: nil); end
end
class Issuer < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
class RenderingOptions < Stripe::RequestParams
# How line-item prices and amounts will be displayed with respect to tax on invoice PDFs. One of `exclude_tax` or `include_inclusive_tax`. `include_inclusive_tax` will include inclusive tax (and exclude exclusive tax) in invoice PDF amounts. `exclude_tax` will exclude all tax (inclusive and exclusive alike) from invoice PDF amounts.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :amount_tax_display
sig { params(amount_tax_display: T.nilable(T.nilable(T.any(String, String)))).void }
def initialize(amount_tax_display: nil); end
end
# The account tax IDs associated with the invoice.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :account_tax_ids
# Default custom fields to be displayed on invoices for this customer.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::PaymentLink::CreateParams::InvoiceCreation::InvoiceData::CustomField]))))
}
attr_accessor :custom_fields
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Default footer to be displayed on invoices for this customer.
sig { returns(T.nilable(String)) }
attr_accessor :footer
# The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
sig {
returns(T.nilable(::Stripe::PaymentLink::CreateParams::InvoiceCreation::InvoiceData::Issuer))
}
attr_accessor :issuer
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Default options for invoice PDF rendering for this customer.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLink::CreateParams::InvoiceCreation::InvoiceData::RenderingOptions))))
}
attr_accessor :rendering_options
sig {
params(account_tax_ids: T.nilable(T.nilable(T.any(String, T::Array[String]))), custom_fields: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::PaymentLink::CreateParams::InvoiceCreation::InvoiceData::CustomField]))), description: T.nilable(String), footer: T.nilable(String), issuer: T.nilable(::Stripe::PaymentLink::CreateParams::InvoiceCreation::InvoiceData::Issuer), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), rendering_options: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLink::CreateParams::InvoiceCreation::InvoiceData::RenderingOptions)))).void
}
def initialize(
account_tax_ids: nil,
custom_fields: nil,
description: nil,
footer: nil,
issuer: nil,
metadata: nil,
rendering_options: nil
); end
end
# Whether the feature is enabled
sig { returns(T::Boolean) }
attr_accessor :enabled
# Invoice PDF configuration.
sig {
returns(T.nilable(::Stripe::PaymentLink::CreateParams::InvoiceCreation::InvoiceData))
}
attr_accessor :invoice_data
sig {
params(enabled: T::Boolean, invoice_data: T.nilable(::Stripe::PaymentLink::CreateParams::InvoiceCreation::InvoiceData)).void
}
def initialize(enabled: nil, invoice_data: nil); end
end
class LineItem < Stripe::RequestParams
class AdjustableQuantity < Stripe::RequestParams
# Set to true if the quantity can be adjusted to any non-negative Integer.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The maximum quantity the customer can purchase. By default this value is 99. You can specify a value up to 999.
sig { returns(T.nilable(Integer)) }
attr_accessor :maximum
# The minimum quantity the customer can purchase. By default this value is 0. If there is only one item in the cart then that item's quantity cannot go down to 0.
sig { returns(T.nilable(Integer)) }
attr_accessor :minimum
sig {
params(enabled: T::Boolean, maximum: T.nilable(Integer), minimum: T.nilable(Integer)).void
}
def initialize(enabled: nil, maximum: nil, minimum: nil); end
end
# When set, provides configuration for this item’s quantity to be adjusted by the customer during checkout.
sig {
returns(T.nilable(::Stripe::PaymentLink::CreateParams::LineItem::AdjustableQuantity))
}
attr_accessor :adjustable_quantity
# The ID of the [Price](https://stripe.com/docs/api/prices) or [Plan](https://stripe.com/docs/api/plans) object.
sig { returns(String) }
attr_accessor :price
# The quantity of the line item being purchased.
sig { returns(Integer) }
attr_accessor :quantity
sig {
params(adjustable_quantity: T.nilable(::Stripe::PaymentLink::CreateParams::LineItem::AdjustableQuantity), price: String, quantity: Integer).void
}
def initialize(adjustable_quantity: nil, price: nil, quantity: nil); end
end
class OptionalItem < Stripe::RequestParams
class AdjustableQuantity < Stripe::RequestParams
# Set to true if the quantity can be adjusted to any non-negative integer.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The maximum quantity of this item the customer can purchase. By default this value is 99.
sig { returns(T.nilable(Integer)) }
attr_accessor :maximum
# The minimum quantity of this item the customer must purchase, if they choose to purchase it. Because this item is optional, the customer will always be able to remove it from their order, even if the `minimum` configured here is greater than 0. By default this value is 0.
sig { returns(T.nilable(Integer)) }
attr_accessor :minimum
sig {
params(enabled: T::Boolean, maximum: T.nilable(Integer), minimum: T.nilable(Integer)).void
}
def initialize(enabled: nil, maximum: nil, minimum: nil); end
end
# When set, provides configuration for the customer to adjust the quantity of the line item created when a customer chooses to add this optional item to their order.
sig {
returns(T.nilable(::Stripe::PaymentLink::CreateParams::OptionalItem::AdjustableQuantity))
}
attr_accessor :adjustable_quantity
# The ID of the [Price](https://stripe.com/docs/api/prices) or [Plan](https://stripe.com/docs/api/plans) object.
sig { returns(String) }
attr_accessor :price
# The initial quantity of the line item created when a customer chooses to add this optional item to their order.
sig { returns(Integer) }
attr_accessor :quantity
sig {
params(adjustable_quantity: T.nilable(::Stripe::PaymentLink::CreateParams::OptionalItem::AdjustableQuantity), price: String, quantity: Integer).void
}
def initialize(adjustable_quantity: nil, price: nil, quantity: nil); end
end
class PaymentIntentData < Stripe::RequestParams
# Controls when the funds will be captured from the customer's account.
sig { returns(T.nilable(String)) }
attr_accessor :capture_method
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Set of [key-value pairs](https://stripe.com/docs/api/metadata) that will declaratively set metadata on [Payment Intents](https://stripe.com/docs/api/payment_intents) generated from this payment link. Unlike object-level metadata, this field is declarative. Updates will clear prior values.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Indicates that you intend to [make future payments](https://stripe.com/docs/payments/payment-intents#future-usage) with the payment method collected by this Checkout Session.
#
# When setting this to `on_session`, Checkout will show a notice to the customer that their payment details will be saved.
#
# When setting this to `off_session`, Checkout will show a notice to the customer that their payment details will be saved and used for future payments.
#
# If a Customer has been provided or Checkout creates a new Customer,Checkout will attach the payment method to the Customer.
#
# If Checkout does not create a Customer, the payment method is not attached to a Customer. To reuse the payment method, you can retrieve it from the Checkout Session's PaymentIntent.
#
# When processing card payments, Checkout also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as SCA.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
# Text that appears on the customer's statement as the statement descriptor for a non-card charge. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
#
# Setting this value for a card charge returns an error. For card charges, set the [statement_descriptor_suffix](https://docs.stripe.com/get-started/account/statement-descriptors#dynamic) instead.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
# Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor_suffix
# A string that identifies the resulting payment as part of a group. See the PaymentIntents [use case for connected accounts](https://stripe.com/docs/connect/separate-charges-and-transfers) for details.
sig { returns(T.nilable(String)) }
attr_accessor :transfer_group
sig {
params(capture_method: T.nilable(String), description: T.nilable(String), metadata: T.nilable(T::Hash[String, String]), setup_future_usage: T.nilable(String), statement_descriptor: T.nilable(String), statement_descriptor_suffix: T.nilable(String), transfer_group: T.nilable(String)).void
}
def initialize(
capture_method: nil,
description: nil,
metadata: nil,
setup_future_usage: nil,
statement_descriptor: nil,
statement_descriptor_suffix: nil,
transfer_group: nil
); end
end
class PhoneNumberCollection < Stripe::RequestParams
# Set to `true` to enable phone number collection.
sig { returns(T::Boolean) }
attr_accessor :enabled
sig { params(enabled: T::Boolean).void }
def initialize(enabled: nil); end
end
class Restrictions < Stripe::RequestParams
class CompletedSessions < Stripe::RequestParams
# The maximum number of checkout sessions that can be completed for the `completed_sessions` restriction to be met.
sig { returns(Integer) }
attr_accessor :limit
sig { params(limit: Integer).void }
def initialize(limit: nil); end
end
# Configuration for the `completed_sessions` restriction type.
sig { returns(::Stripe::PaymentLink::CreateParams::Restrictions::CompletedSessions) }
attr_accessor :completed_sessions
sig {
params(completed_sessions: ::Stripe::PaymentLink::CreateParams::Restrictions::CompletedSessions).void
}
def initialize(completed_sessions: nil); end
end
class ShippingAddressCollection < Stripe::RequestParams
# An array of two-letter ISO country codes representing which countries Checkout should provide as options for
# shipping locations.
sig { returns(T::Array[String]) }
attr_accessor :allowed_countries
sig { params(allowed_countries: T::Array[String]).void }
def initialize(allowed_countries: nil); end
end
class ShippingOption < Stripe::RequestParams
# The ID of the Shipping Rate to use for this shipping option.
sig { returns(T.nilable(String)) }
attr_accessor :shipping_rate
sig { params(shipping_rate: T.nilable(String)).void }
def initialize(shipping_rate: nil); end
end
class SubscriptionData < Stripe::RequestParams
class InvoiceSettings < Stripe::RequestParams
class Issuer < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
sig {
returns(T.nilable(::Stripe::PaymentLink::CreateParams::SubscriptionData::InvoiceSettings::Issuer))
}
attr_accessor :issuer
sig {
params(issuer: T.nilable(::Stripe::PaymentLink::CreateParams::SubscriptionData::InvoiceSettings::Issuer)).void
}
def initialize(issuer: nil); end
end
class TrialSettings < Stripe::RequestParams
class EndBehavior < Stripe::RequestParams
# Indicates how the subscription should change when the trial ends if the user did not provide a payment method.
sig { returns(String) }
attr_accessor :missing_payment_method
sig { params(missing_payment_method: String).void }
def initialize(missing_payment_method: nil); end
end
# Defines how the subscription should behave when the user's free trial ends.
sig {
returns(::Stripe::PaymentLink::CreateParams::SubscriptionData::TrialSettings::EndBehavior)
}
attr_accessor :end_behavior
sig {
params(end_behavior: ::Stripe::PaymentLink::CreateParams::SubscriptionData::TrialSettings::EndBehavior).void
}
def initialize(end_behavior: nil); end
end
# The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
sig { returns(T.nilable(String)) }
attr_accessor :description
# All invoices will be billed using the specified settings.
sig {
returns(T.nilable(::Stripe::PaymentLink::CreateParams::SubscriptionData::InvoiceSettings))
}
attr_accessor :invoice_settings
# Set of [key-value pairs](https://stripe.com/docs/api/metadata) that will declaratively set metadata on [Subscriptions](https://stripe.com/docs/api/subscriptions) generated from this payment link. Unlike object-level metadata, this field is declarative. Updates will clear prior values.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Integer representing the number of trial period days before the customer is charged for the first time. Has to be at least 1.
sig { returns(T.nilable(Integer)) }
attr_accessor :trial_period_days
# Settings related to subscription trials.
sig {
returns(T.nilable(::Stripe::PaymentLink::CreateParams::SubscriptionData::TrialSettings))
}
attr_accessor :trial_settings
sig {
params(description: T.nilable(String), invoice_settings: T.nilable(::Stripe::PaymentLink::CreateParams::SubscriptionData::InvoiceSettings), metadata: T.nilable(T::Hash[String, String]), trial_period_days: T.nilable(Integer), trial_settings: T.nilable(::Stripe::PaymentLink::CreateParams::SubscriptionData::TrialSettings)).void
}
def initialize(
description: nil,
invoice_settings: nil,
metadata: nil,
trial_period_days: nil,
trial_settings: nil
); end
end
class TaxIdCollection < Stripe::RequestParams
# Enable tax ID collection during checkout. Defaults to `false`.
sig { returns(T::Boolean) }
attr_accessor :enabled
# Describes whether a tax ID is required during checkout. Defaults to `never`.
sig { returns(T.nilable(String)) }
attr_accessor :required
sig { params(enabled: T::Boolean, required: T.nilable(String)).void }
def initialize(enabled: nil, required: nil); end
end
class TransferData < Stripe::RequestParams
# The amount that will be transferred automatically when a charge succeeds.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# If specified, successful charges will be attributed to the destination
# account for tax reporting, and the funds from charges will be transferred
# to the destination account. The ID of the resulting transfer will be
# returned on the successful charge's `transfer` field.
sig { returns(String) }
attr_accessor :destination
sig { params(amount: T.nilable(Integer), destination: String).void }
def initialize(amount: nil, destination: nil); end
end
# Behavior after the purchase is complete.
sig { returns(T.nilable(::Stripe::PaymentLink::CreateParams::AfterCompletion)) }
attr_accessor :after_completion
# Enables user redeemable promotion codes.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :allow_promotion_codes
# The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. Can only be applied when there are no line items with recurring prices.
sig { returns(T.nilable(Integer)) }
attr_accessor :application_fee_amount
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. There must be at least 1 line item with a recurring price to use this field.
sig { returns(T.nilable(Float)) }
attr_accessor :application_fee_percent
# Configuration for automatic tax collection.
sig { returns(T.nilable(::Stripe::PaymentLink::CreateParams::AutomaticTax)) }
attr_accessor :automatic_tax
# Configuration for collecting the customer's billing address. Defaults to `auto`.
sig { returns(T.nilable(String)) }
attr_accessor :billing_address_collection
# Configure fields to gather active consent from customers.
sig { returns(T.nilable(::Stripe::PaymentLink::CreateParams::ConsentCollection)) }
attr_accessor :consent_collection
# 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) and supported by each line item's price.
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Collect additional information from your customer using custom fields. Up to 3 fields are supported.
sig { returns(T.nilable(T::Array[::Stripe::PaymentLink::CreateParams::CustomField])) }
attr_accessor :custom_fields
# Display additional text for your customers using custom text.
sig { returns(T.nilable(::Stripe::PaymentLink::CreateParams::CustomText)) }
attr_accessor :custom_text
# Configures whether [checkout sessions](https://stripe.com/docs/api/checkout/sessions) created by this payment link create a [Customer](https://stripe.com/docs/api/customers).
sig { returns(T.nilable(String)) }
attr_accessor :customer_creation
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The custom message to be displayed to a customer when a payment link is no longer active.
sig { returns(T.nilable(String)) }
attr_accessor :inactive_message
# Generate a post-purchase Invoice for one-time payments.
sig { returns(T.nilable(::Stripe::PaymentLink::CreateParams::InvoiceCreation)) }
attr_accessor :invoice_creation
# The line items representing what is being sold. Each line item represents an item being sold. Up to 20 line items are supported.
sig { returns(T::Array[::Stripe::PaymentLink::CreateParams::LineItem]) }
attr_accessor :line_items
# 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 associated with this Payment Link will automatically be copied to [checkout sessions](https://stripe.com/docs/api/checkout/sessions) created by this payment link.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The account on behalf of which to charge.
sig { returns(T.nilable(String)) }
attr_accessor :on_behalf_of
# A list of optional items the customer can add to their order at checkout. Use this parameter to pass one-time or recurring [Prices](https://stripe.com/docs/api/prices).
# There is a maximum of 10 optional items allowed on a payment link, and the existing limits on the number of line items allowed on a payment link apply to the combined number of line items and optional items.
# There is a maximum of 20 combined line items and optional items.
sig { returns(T.nilable(T::Array[::Stripe::PaymentLink::CreateParams::OptionalItem])) }
attr_accessor :optional_items
# A subset of parameters to be passed to PaymentIntent creation for Checkout Sessions in `payment` mode.
sig { returns(T.nilable(::Stripe::PaymentLink::CreateParams::PaymentIntentData)) }
attr_accessor :payment_intent_data
# Specify whether Checkout should collect a payment method. When set to `if_required`, Checkout will not collect a payment method when the total due for the session is 0.This may occur if the Checkout Session includes a free trial or a discount.
#
# Can only be set in `subscription` mode. Defaults to `always`.
#
# If you'd like information on how to collect a payment method outside of Checkout, read the guide on [configuring subscriptions with a free trial](https://stripe.com/docs/payments/checkout/free-trials).
sig { returns(T.nilable(String)) }
attr_accessor :payment_method_collection
# The list of payment method types that customers can use. If no value is passed, Stripe will dynamically show relevant payment methods from your [payment method settings](https://dashboard.stripe.com/settings/payment_methods) (20+ payment methods [supported](https://stripe.com/docs/payments/payment-methods/integration-options#payment-method-product-support)).
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :payment_method_types
# Controls phone number collection settings during checkout.
#
# We recommend that you review your privacy policy and check with your legal contacts.
sig { returns(T.nilable(::Stripe::PaymentLink::CreateParams::PhoneNumberCollection)) }
attr_accessor :phone_number_collection
# Settings that restrict the usage of a payment link.
sig { returns(T.nilable(::Stripe::PaymentLink::CreateParams::Restrictions)) }
attr_accessor :restrictions
# Configuration for collecting the customer's shipping address.
sig { returns(T.nilable(::Stripe::PaymentLink::CreateParams::ShippingAddressCollection)) }
attr_accessor :shipping_address_collection
# The shipping rate options to apply to [checkout sessions](https://stripe.com/docs/api/checkout/sessions) created by this payment link.
sig { returns(T.nilable(T::Array[::Stripe::PaymentLink::CreateParams::ShippingOption])) }
attr_accessor :shipping_options
# Describes the type of transaction being performed in order to customize relevant text on the page, such as the submit button. Changing this value will also affect the hostname in the [url](https://stripe.com/docs/api/payment_links/payment_links/object#url) property (example: `donate.stripe.com`).
sig { returns(T.nilable(String)) }
attr_accessor :submit_type
# When creating a subscription, the specified configuration data will be used. There must be at least one line item with a recurring price to use `subscription_data`.
sig { returns(T.nilable(::Stripe::PaymentLink::CreateParams::SubscriptionData)) }
attr_accessor :subscription_data
# Controls tax ID collection during checkout.
sig { returns(T.nilable(::Stripe::PaymentLink::CreateParams::TaxIdCollection)) }
attr_accessor :tax_id_collection
# The account (if any) the payments will be attributed to for tax reporting, and where funds from each payment will be transferred to.
sig { returns(T.nilable(::Stripe::PaymentLink::CreateParams::TransferData)) }
attr_accessor :transfer_data
sig {
params(after_completion: T.nilable(::Stripe::PaymentLink::CreateParams::AfterCompletion), allow_promotion_codes: T.nilable(T::Boolean), application_fee_amount: T.nilable(Integer), application_fee_percent: T.nilable(Float), automatic_tax: T.nilable(::Stripe::PaymentLink::CreateParams::AutomaticTax), billing_address_collection: T.nilable(String), consent_collection: T.nilable(::Stripe::PaymentLink::CreateParams::ConsentCollection), currency: T.nilable(String), custom_fields: T.nilable(T::Array[::Stripe::PaymentLink::CreateParams::CustomField]), custom_text: T.nilable(::Stripe::PaymentLink::CreateParams::CustomText), customer_creation: T.nilable(String), expand: T.nilable(T::Array[String]), inactive_message: T.nilable(String), invoice_creation: T.nilable(::Stripe::PaymentLink::CreateParams::InvoiceCreation), line_items: T::Array[::Stripe::PaymentLink::CreateParams::LineItem], metadata: T.nilable(T::Hash[String, String]), on_behalf_of: T.nilable(String), optional_items: T.nilable(T::Array[::Stripe::PaymentLink::CreateParams::OptionalItem]), payment_intent_data: T.nilable(::Stripe::PaymentLink::CreateParams::PaymentIntentData), payment_method_collection: T.nilable(String), payment_method_types: T.nilable(T::Array[String]), phone_number_collection: T.nilable(::Stripe::PaymentLink::CreateParams::PhoneNumberCollection), restrictions: T.nilable(::Stripe::PaymentLink::CreateParams::Restrictions), shipping_address_collection: T.nilable(::Stripe::PaymentLink::CreateParams::ShippingAddressCollection), shipping_options: T.nilable(T::Array[::Stripe::PaymentLink::CreateParams::ShippingOption]), submit_type: T.nilable(String), subscription_data: T.nilable(::Stripe::PaymentLink::CreateParams::SubscriptionData), tax_id_collection: T.nilable(::Stripe::PaymentLink::CreateParams::TaxIdCollection), transfer_data: T.nilable(::Stripe::PaymentLink::CreateParams::TransferData)).void
}
def initialize(
after_completion: nil,
allow_promotion_codes: nil,
application_fee_amount: nil,
application_fee_percent: nil,
automatic_tax: nil,
billing_address_collection: nil,
consent_collection: nil,
currency: nil,
custom_fields: nil,
custom_text: nil,
customer_creation: nil,
expand: nil,
inactive_message: nil,
invoice_creation: nil,
line_items: nil,
metadata: nil,
on_behalf_of: nil,
optional_items: nil,
payment_intent_data: nil,
payment_method_collection: nil,
payment_method_types: nil,
phone_number_collection: nil,
restrictions: nil,
shipping_address_collection: nil,
shipping_options: nil,
submit_type: nil,
subscription_data: nil,
tax_id_collection: nil,
transfer_data: nil
); end
end
class UpdateParams < Stripe::RequestParams
class AfterCompletion < Stripe::RequestParams
class HostedConfirmation < Stripe::RequestParams
# A custom message to display to the customer after the purchase is complete.
sig { returns(T.nilable(String)) }
attr_accessor :custom_message
sig { params(custom_message: T.nilable(String)).void }
def initialize(custom_message: nil); end
end
class Redirect < Stripe::RequestParams
# The URL the customer will be redirected to after the purchase is complete. You can embed `{CHECKOUT_SESSION_ID}` into the URL to have the `id` of the completed [checkout session](https://stripe.com/docs/api/checkout/sessions/object#checkout_session_object-id) included.
sig { returns(String) }
attr_accessor :url
sig { params(url: String).void }
def initialize(url: nil); end
end
# Configuration when `type=hosted_confirmation`.
sig {
returns(T.nilable(::Stripe::PaymentLink::UpdateParams::AfterCompletion::HostedConfirmation))
}
attr_accessor :hosted_confirmation
# Configuration when `type=redirect`.
sig { returns(T.nilable(::Stripe::PaymentLink::UpdateParams::AfterCompletion::Redirect)) }
attr_accessor :redirect
# The specified behavior after the purchase is complete. Either `redirect` or `hosted_confirmation`.
sig { returns(String) }
attr_accessor :type
sig {
params(hosted_confirmation: T.nilable(::Stripe::PaymentLink::UpdateParams::AfterCompletion::HostedConfirmation), redirect: T.nilable(::Stripe::PaymentLink::UpdateParams::AfterCompletion::Redirect), type: String).void
}
def initialize(hosted_confirmation: nil, redirect: nil, type: nil); end
end
class AutomaticTax < Stripe::RequestParams
class Liability < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# Set to `true` to [calculate tax automatically](https://docs.stripe.com/tax) using the customer's location.
#
# Enabling this parameter causes the payment link to collect any billing address information necessary for tax calculation.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
sig { returns(T.nilable(::Stripe::PaymentLink::UpdateParams::AutomaticTax::Liability)) }
attr_accessor :liability
sig {
params(enabled: T::Boolean, liability: T.nilable(::Stripe::PaymentLink::UpdateParams::AutomaticTax::Liability)).void
}
def initialize(enabled: nil, liability: nil); end
end
class CustomField < Stripe::RequestParams
class Dropdown < Stripe::RequestParams
class Option < Stripe::RequestParams
# The label for the option, displayed to the customer. Up to 100 characters.
sig { returns(String) }
attr_accessor :label
# The value for this option, not displayed to the customer, used by your integration to reconcile the option selected by the customer. Must be unique to this option, alphanumeric, and up to 100 characters.
sig { returns(String) }
attr_accessor :value
sig { params(label: String, value: String).void }
def initialize(label: nil, value: nil); end
end
# The value that will pre-fill the field on the payment page.Must match a `value` in the `options` array.
sig { returns(T.nilable(String)) }
attr_accessor :default_value
# The options available for the customer to select. Up to 200 options allowed.
sig {
returns(T::Array[::Stripe::PaymentLink::UpdateParams::CustomField::Dropdown::Option])
}
attr_accessor :options
sig {
params(default_value: T.nilable(String), options: T::Array[::Stripe::PaymentLink::UpdateParams::CustomField::Dropdown::Option]).void
}
def initialize(default_value: nil, options: nil); end
end
class Label < Stripe::RequestParams
# Custom text for the label, displayed to the customer. Up to 50 characters.
sig { returns(String) }
attr_accessor :custom
# The type of the label.
sig { returns(String) }
attr_accessor :type
sig { params(custom: String, type: String).void }
def initialize(custom: nil, type: nil); end
end
class Numeric < Stripe::RequestParams
# The value that will pre-fill the field on the payment page.
sig { returns(T.nilable(String)) }
attr_accessor :default_value
# The maximum character length constraint for the customer's input.
sig { returns(T.nilable(Integer)) }
attr_accessor :maximum_length
# The minimum character length requirement for the customer's input.
sig { returns(T.nilable(Integer)) }
attr_accessor :minimum_length
sig {
params(default_value: T.nilable(String), maximum_length: T.nilable(Integer), minimum_length: T.nilable(Integer)).void
}
def initialize(default_value: nil, maximum_length: nil, minimum_length: nil); end
end
class Text < Stripe::RequestParams
# The value that will pre-fill the field on the payment page.
sig { returns(T.nilable(String)) }
attr_accessor :default_value
# The maximum character length constraint for the customer's input.
sig { returns(T.nilable(Integer)) }
attr_accessor :maximum_length
# The minimum character length requirement for the customer's input.
sig { returns(T.nilable(Integer)) }
attr_accessor :minimum_length
sig {
params(default_value: T.nilable(String), maximum_length: T.nilable(Integer), minimum_length: T.nilable(Integer)).void
}
def initialize(default_value: nil, maximum_length: nil, minimum_length: nil); end
end
# Configuration for `type=dropdown` fields.
sig { returns(T.nilable(::Stripe::PaymentLink::UpdateParams::CustomField::Dropdown)) }
attr_accessor :dropdown
# String of your choice that your integration can use to reconcile this field. Must be unique to this field, alphanumeric, and up to 200 characters.
sig { returns(String) }
attr_accessor :key
# The label for the field, displayed to the customer.
sig { returns(::Stripe::PaymentLink::UpdateParams::CustomField::Label) }
attr_accessor :label
# Configuration for `type=numeric` fields.
sig { returns(T.nilable(::Stripe::PaymentLink::UpdateParams::CustomField::Numeric)) }
attr_accessor :numeric
# Whether the customer is required to complete the field before completing the Checkout Session. Defaults to `false`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :optional
# Configuration for `type=text` fields.
sig { returns(T.nilable(::Stripe::PaymentLink::UpdateParams::CustomField::Text)) }
attr_accessor :text
# The type of the field.
sig { returns(String) }
attr_accessor :type
sig {
params(dropdown: T.nilable(::Stripe::PaymentLink::UpdateParams::CustomField::Dropdown), key: String, label: ::Stripe::PaymentLink::UpdateParams::CustomField::Label, numeric: T.nilable(::Stripe::PaymentLink::UpdateParams::CustomField::Numeric), optional: T.nilable(T::Boolean), text: T.nilable(::Stripe::PaymentLink::UpdateParams::CustomField::Text), type: String).void
}
def initialize(
dropdown: nil,
key: nil,
label: nil,
numeric: nil,
optional: nil,
text: nil,
type: nil
); end
end
class CustomText < Stripe::RequestParams
class AfterSubmit < Stripe::RequestParams
# Text may be up to 1200 characters in length.
sig { returns(String) }
attr_accessor :message
sig { params(message: String).void }
def initialize(message: nil); end
end
class ShippingAddress < Stripe::RequestParams
# Text may be up to 1200 characters in length.
sig { returns(String) }
attr_accessor :message
sig { params(message: String).void }
def initialize(message: nil); end
end
class Submit < Stripe::RequestParams
# Text may be up to 1200 characters in length.
sig { returns(String) }
attr_accessor :message
sig { params(message: String).void }
def initialize(message: nil); end
end
class TermsOfServiceAcceptance < Stripe::RequestParams
# Text may be up to 1200 characters in length.
sig { returns(String) }
attr_accessor :message
sig { params(message: String).void }
def initialize(message: nil); end
end
# Custom text that should be displayed after the payment confirmation button.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLink::UpdateParams::CustomText::AfterSubmit))))
}
attr_accessor :after_submit
# Custom text that should be displayed alongside shipping address collection.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLink::UpdateParams::CustomText::ShippingAddress))))
}
attr_accessor :shipping_address
# Custom text that should be displayed alongside the payment confirmation button.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLink::UpdateParams::CustomText::Submit))))
}
attr_accessor :submit
# Custom text that should be displayed in place of the default terms of service agreement text.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLink::UpdateParams::CustomText::TermsOfServiceAcceptance))))
}
attr_accessor :terms_of_service_acceptance
sig {
params(after_submit: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLink::UpdateParams::CustomText::AfterSubmit))), shipping_address: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLink::UpdateParams::CustomText::ShippingAddress))), submit: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLink::UpdateParams::CustomText::Submit))), terms_of_service_acceptance: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLink::UpdateParams::CustomText::TermsOfServiceAcceptance)))).void
}
def initialize(
after_submit: nil,
shipping_address: nil,
submit: nil,
terms_of_service_acceptance: nil
); end
end
class InvoiceCreation < Stripe::RequestParams
class InvoiceData < Stripe::RequestParams
class CustomField < Stripe::RequestParams
# The name of the custom field. This may be up to 40 characters.
sig { returns(String) }
attr_accessor :name
# The value of the custom field. This may be up to 140 characters.
sig { returns(String) }
attr_accessor :value
sig { params(name: String, value: String).void }
def initialize(name: nil, value: nil); end
end
class Issuer < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
class RenderingOptions < Stripe::RequestParams
# How line-item prices and amounts will be displayed with respect to tax on invoice PDFs. One of `exclude_tax` or `include_inclusive_tax`. `include_inclusive_tax` will include inclusive tax (and exclude exclusive tax) in invoice PDF amounts. `exclude_tax` will exclude all tax (inclusive and exclusive alike) from invoice PDF amounts.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :amount_tax_display
sig { params(amount_tax_display: T.nilable(T.nilable(T.any(String, String)))).void }
def initialize(amount_tax_display: nil); end
end
# The account tax IDs associated with the invoice.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :account_tax_ids
# Default custom fields to be displayed on invoices for this customer.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::PaymentLink::UpdateParams::InvoiceCreation::InvoiceData::CustomField]))))
}
attr_accessor :custom_fields
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Default footer to be displayed on invoices for this customer.
sig { returns(T.nilable(String)) }
attr_accessor :footer
# The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
sig {
returns(T.nilable(::Stripe::PaymentLink::UpdateParams::InvoiceCreation::InvoiceData::Issuer))
}
attr_accessor :issuer
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Default options for invoice PDF rendering for this customer.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLink::UpdateParams::InvoiceCreation::InvoiceData::RenderingOptions))))
}
attr_accessor :rendering_options
sig {
params(account_tax_ids: T.nilable(T.nilable(T.any(String, T::Array[String]))), custom_fields: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::PaymentLink::UpdateParams::InvoiceCreation::InvoiceData::CustomField]))), description: T.nilable(String), footer: T.nilable(String), issuer: T.nilable(::Stripe::PaymentLink::UpdateParams::InvoiceCreation::InvoiceData::Issuer), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), rendering_options: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLink::UpdateParams::InvoiceCreation::InvoiceData::RenderingOptions)))).void
}
def initialize(
account_tax_ids: nil,
custom_fields: nil,
description: nil,
footer: nil,
issuer: nil,
metadata: nil,
rendering_options: nil
); end
end
# Whether the feature is enabled
sig { returns(T::Boolean) }
attr_accessor :enabled
# Invoice PDF configuration.
sig {
returns(T.nilable(::Stripe::PaymentLink::UpdateParams::InvoiceCreation::InvoiceData))
}
attr_accessor :invoice_data
sig {
params(enabled: T::Boolean, invoice_data: T.nilable(::Stripe::PaymentLink::UpdateParams::InvoiceCreation::InvoiceData)).void
}
def initialize(enabled: nil, invoice_data: nil); end
end
class LineItem < Stripe::RequestParams
class AdjustableQuantity < Stripe::RequestParams
# Set to true if the quantity can be adjusted to any non-negative Integer.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The maximum quantity the customer can purchase. By default this value is 99. You can specify a value up to 999.
sig { returns(T.nilable(Integer)) }
attr_accessor :maximum
# The minimum quantity the customer can purchase. By default this value is 0. If there is only one item in the cart then that item's quantity cannot go down to 0.
sig { returns(T.nilable(Integer)) }
attr_accessor :minimum
sig {
params(enabled: T::Boolean, maximum: T.nilable(Integer), minimum: T.nilable(Integer)).void
}
def initialize(enabled: nil, maximum: nil, minimum: nil); end
end
# When set, provides configuration for this item’s quantity to be adjusted by the customer during checkout.
sig {
returns(T.nilable(::Stripe::PaymentLink::UpdateParams::LineItem::AdjustableQuantity))
}
attr_accessor :adjustable_quantity
# The ID of an existing line item on the payment link.
sig { returns(String) }
attr_accessor :id
# The quantity of the line item being purchased.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
sig {
params(adjustable_quantity: T.nilable(::Stripe::PaymentLink::UpdateParams::LineItem::AdjustableQuantity), id: String, quantity: T.nilable(Integer)).void
}
def initialize(adjustable_quantity: nil, id: nil, quantity: nil); end
end
class PaymentIntentData < Stripe::RequestParams
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :description
# Set of [key-value pairs](https://stripe.com/docs/api/metadata) that will declaratively set metadata on [Payment Intents](https://stripe.com/docs/api/payment_intents) generated from this payment link. Unlike object-level metadata, this field is declarative. Updates will clear prior values.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Text that appears on the customer's statement as the statement descriptor for a non-card charge. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
#
# Setting this value for a card charge returns an error. For card charges, set the [statement_descriptor_suffix](https://docs.stripe.com/get-started/account/statement-descriptors#dynamic) instead.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :statement_descriptor
# Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :statement_descriptor_suffix
# A string that identifies the resulting payment as part of a group. See the PaymentIntents [use case for connected accounts](https://stripe.com/docs/connect/separate-charges-and-transfers) for details.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :transfer_group
sig {
params(description: T.nilable(T.nilable(String)), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), statement_descriptor: T.nilable(T.nilable(String)), statement_descriptor_suffix: T.nilable(T.nilable(String)), transfer_group: T.nilable(T.nilable(String))).void
}
def initialize(
description: nil,
metadata: nil,
statement_descriptor: nil,
statement_descriptor_suffix: nil,
transfer_group: nil
); end
end
class PhoneNumberCollection < Stripe::RequestParams
# Set to `true` to enable phone number collection.
sig { returns(T::Boolean) }
attr_accessor :enabled
sig { params(enabled: T::Boolean).void }
def initialize(enabled: nil); end
end
class Restrictions < Stripe::RequestParams
class CompletedSessions < Stripe::RequestParams
# The maximum number of checkout sessions that can be completed for the `completed_sessions` restriction to be met.
sig { returns(Integer) }
attr_accessor :limit
sig { params(limit: Integer).void }
def initialize(limit: nil); end
end
# Configuration for the `completed_sessions` restriction type.
sig { returns(::Stripe::PaymentLink::UpdateParams::Restrictions::CompletedSessions) }
attr_accessor :completed_sessions
sig {
params(completed_sessions: ::Stripe::PaymentLink::UpdateParams::Restrictions::CompletedSessions).void
}
def initialize(completed_sessions: nil); end
end
class ShippingAddressCollection < Stripe::RequestParams
# An array of two-letter ISO country codes representing which countries Checkout should provide as options for
# shipping locations.
sig { returns(T::Array[String]) }
attr_accessor :allowed_countries
sig { params(allowed_countries: T::Array[String]).void }
def initialize(allowed_countries: nil); end
end
class SubscriptionData < Stripe::RequestParams
class InvoiceSettings < Stripe::RequestParams
class Issuer < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
sig {
returns(T.nilable(::Stripe::PaymentLink::UpdateParams::SubscriptionData::InvoiceSettings::Issuer))
}
attr_accessor :issuer
sig {
params(issuer: T.nilable(::Stripe::PaymentLink::UpdateParams::SubscriptionData::InvoiceSettings::Issuer)).void
}
def initialize(issuer: nil); end
end
class TrialSettings < Stripe::RequestParams
class EndBehavior < Stripe::RequestParams
# Indicates how the subscription should change when the trial ends if the user did not provide a payment method.
sig { returns(String) }
attr_accessor :missing_payment_method
sig { params(missing_payment_method: String).void }
def initialize(missing_payment_method: nil); end
end
# Defines how the subscription should behave when the user's free trial ends.
sig {
returns(::Stripe::PaymentLink::UpdateParams::SubscriptionData::TrialSettings::EndBehavior)
}
attr_accessor :end_behavior
sig {
params(end_behavior: ::Stripe::PaymentLink::UpdateParams::SubscriptionData::TrialSettings::EndBehavior).void
}
def initialize(end_behavior: nil); end
end
# All invoices will be billed using the specified settings.
sig {
returns(T.nilable(::Stripe::PaymentLink::UpdateParams::SubscriptionData::InvoiceSettings))
}
attr_accessor :invoice_settings
# Set of [key-value pairs](https://stripe.com/docs/api/metadata) that will declaratively set metadata on [Subscriptions](https://stripe.com/docs/api/subscriptions) generated from this payment link. Unlike object-level metadata, this field is declarative. Updates will clear prior values.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Integer representing the number of trial period days before the customer is charged for the first time. Has to be at least 1.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :trial_period_days
# Settings related to subscription trials.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLink::UpdateParams::SubscriptionData::TrialSettings))))
}
attr_accessor :trial_settings
sig {
params(invoice_settings: T.nilable(::Stripe::PaymentLink::UpdateParams::SubscriptionData::InvoiceSettings), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), trial_period_days: T.nilable(T.nilable(T.any(String, Integer))), trial_settings: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLink::UpdateParams::SubscriptionData::TrialSettings)))).void
}
def initialize(
invoice_settings: nil,
metadata: nil,
trial_period_days: nil,
trial_settings: nil
); end
end
class TaxIdCollection < Stripe::RequestParams
# Enable tax ID collection during checkout. Defaults to `false`.
sig { returns(T::Boolean) }
attr_accessor :enabled
# Describes whether a tax ID is required during checkout. Defaults to `never`.
sig { returns(T.nilable(String)) }
attr_accessor :required
sig { params(enabled: T::Boolean, required: T.nilable(String)).void }
def initialize(enabled: nil, required: nil); end
end
# Whether the payment link's `url` is active. If `false`, customers visiting the URL will be shown a page saying that the link has been deactivated.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# Behavior after the purchase is complete.
sig { returns(T.nilable(::Stripe::PaymentLink::UpdateParams::AfterCompletion)) }
attr_accessor :after_completion
# Enables user redeemable promotion codes.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :allow_promotion_codes
# Configuration for automatic tax collection.
sig { returns(T.nilable(::Stripe::PaymentLink::UpdateParams::AutomaticTax)) }
attr_accessor :automatic_tax
# Configuration for collecting the customer's billing address. Defaults to `auto`.
sig { returns(T.nilable(String)) }
attr_accessor :billing_address_collection
# Collect additional information from your customer using custom fields. Up to 3 fields are supported.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::PaymentLink::UpdateParams::CustomField]))))
}
attr_accessor :custom_fields
# Display additional text for your customers using custom text.
sig { returns(T.nilable(::Stripe::PaymentLink::UpdateParams::CustomText)) }
attr_accessor :custom_text
# Configures whether [checkout sessions](https://stripe.com/docs/api/checkout/sessions) created by this payment link create a [Customer](https://stripe.com/docs/api/customers).
sig { returns(T.nilable(String)) }
attr_accessor :customer_creation
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The custom message to be displayed to a customer when a payment link is no longer active.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :inactive_message
# Generate a post-purchase Invoice for one-time payments.
sig { returns(T.nilable(::Stripe::PaymentLink::UpdateParams::InvoiceCreation)) }
attr_accessor :invoice_creation
# The line items representing what is being sold. Each line item represents an item being sold. Up to 20 line items are supported.
sig { returns(T.nilable(T::Array[::Stripe::PaymentLink::UpdateParams::LineItem])) }
attr_accessor :line_items
# 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 associated with this Payment Link will automatically be copied to [checkout sessions](https://stripe.com/docs/api/checkout/sessions) created by this payment link.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# A subset of parameters to be passed to PaymentIntent creation for Checkout Sessions in `payment` mode.
sig { returns(T.nilable(::Stripe::PaymentLink::UpdateParams::PaymentIntentData)) }
attr_accessor :payment_intent_data
# Specify whether Checkout should collect a payment method. When set to `if_required`, Checkout will not collect a payment method when the total due for the session is 0.This may occur if the Checkout Session includes a free trial or a discount.
#
# Can only be set in `subscription` mode. Defaults to `always`.
#
# If you'd like information on how to collect a payment method outside of Checkout, read the guide on [configuring subscriptions with a free trial](https://stripe.com/docs/payments/checkout/free-trials).
sig { returns(T.nilable(String)) }
attr_accessor :payment_method_collection
# The list of payment method types that customers can use. Pass an empty string to enable dynamic payment methods that use your [payment method settings](https://dashboard.stripe.com/settings/payment_methods).
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :payment_method_types
# Controls phone number collection settings during checkout.
#
# We recommend that you review your privacy policy and check with your legal contacts.
sig { returns(T.nilable(::Stripe::PaymentLink::UpdateParams::PhoneNumberCollection)) }
attr_accessor :phone_number_collection
# Settings that restrict the usage of a payment link.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLink::UpdateParams::Restrictions))))
}
attr_accessor :restrictions
# Configuration for collecting the customer's shipping address.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLink::UpdateParams::ShippingAddressCollection))))
}
attr_accessor :shipping_address_collection
# Describes the type of transaction being performed in order to customize relevant text on the page, such as the submit button. Changing this value will also affect the hostname in the [url](https://stripe.com/docs/api/payment_links/payment_links/object#url) property (example: `donate.stripe.com`).
sig { returns(T.nilable(String)) }
attr_accessor :submit_type
# When creating a subscription, the specified configuration data will be used. There must be at least one line item with a recurring price to use `subscription_data`.
sig { returns(T.nilable(::Stripe::PaymentLink::UpdateParams::SubscriptionData)) }
attr_accessor :subscription_data
# Controls tax ID collection during checkout.
sig { returns(T.nilable(::Stripe::PaymentLink::UpdateParams::TaxIdCollection)) }
attr_accessor :tax_id_collection
sig {
params(active: T.nilable(T::Boolean), after_completion: T.nilable(::Stripe::PaymentLink::UpdateParams::AfterCompletion), allow_promotion_codes: T.nilable(T::Boolean), automatic_tax: T.nilable(::Stripe::PaymentLink::UpdateParams::AutomaticTax), billing_address_collection: T.nilable(String), custom_fields: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::PaymentLink::UpdateParams::CustomField]))), custom_text: T.nilable(::Stripe::PaymentLink::UpdateParams::CustomText), customer_creation: T.nilable(String), expand: T.nilable(T::Array[String]), inactive_message: T.nilable(T.nilable(String)), invoice_creation: T.nilable(::Stripe::PaymentLink::UpdateParams::InvoiceCreation), line_items: T.nilable(T::Array[::Stripe::PaymentLink::UpdateParams::LineItem]), metadata: T.nilable(T::Hash[String, String]), payment_intent_data: T.nilable(::Stripe::PaymentLink::UpdateParams::PaymentIntentData), payment_method_collection: T.nilable(String), payment_method_types: T.nilable(T.nilable(T.any(String, T::Array[String]))), phone_number_collection: T.nilable(::Stripe::PaymentLink::UpdateParams::PhoneNumberCollection), restrictions: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLink::UpdateParams::Restrictions))), shipping_address_collection: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLink::UpdateParams::ShippingAddressCollection))), submit_type: T.nilable(String), subscription_data: T.nilable(::Stripe::PaymentLink::UpdateParams::SubscriptionData), tax_id_collection: T.nilable(::Stripe::PaymentLink::UpdateParams::TaxIdCollection)).void
}
def initialize(
active: nil,
after_completion: nil,
allow_promotion_codes: nil,
automatic_tax: nil,
billing_address_collection: nil,
custom_fields: nil,
custom_text: nil,
customer_creation: nil,
expand: nil,
inactive_message: nil,
invoice_creation: nil,
line_items: nil,
metadata: nil,
payment_intent_data: nil,
payment_method_collection: nil,
payment_method_types: nil,
phone_number_collection: nil,
restrictions: nil,
shipping_address_collection: nil,
submit_type: nil,
subscription_data: nil,
tax_id_collection: nil
); end
end
class ListLineItemsParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
# Creates a payment link.
sig {
params(params: T.any(::Stripe::PaymentLink::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentLink)
}
def self.create(params = {}, opts = {}); end
# Returns a list of your payment links.
sig {
params(params: T.any(::Stripe::PaymentLink::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# When retrieving a payment link, there is an includable line_items property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items.
sig {
params(params: T.any(::Stripe::PaymentLink::ListLineItemsParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list_line_items(params = {}, opts = {}); end
# When retrieving a payment link, there is an includable line_items property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items.
sig {
params(payment_link: String, params: T.any(::Stripe::PaymentLink::ListLineItemsParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list_line_items(payment_link, params = {}, opts = {}); end
# Updates a payment link.
sig {
params(payment_link: String, params: T.any(::Stripe::PaymentLink::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentLink)
}
def self.update(payment_link, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
# PaymentMethod objects represent your customer's payment instruments.
# You can use them with [PaymentIntents](https://stripe.com/docs/payments/payment-intents) to collect payments or save them to
# Customer objects to store instrument details for future payments.
#
# Related guides: [Payment Methods](https://stripe.com/docs/payments/payment-methods) and [More Payment Scenarios](https://stripe.com/docs/payments/more-payment-scenarios).
class PaymentMethod < APIResource
class AcssDebit < Stripe::StripeObject
# Account number of the bank account.
sig { returns(T.nilable(String)) }
attr_reader :account_number
# Name of the bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Institution number of the bank account.
sig { returns(T.nilable(String)) }
attr_reader :institution_number
# Last four digits of the bank account number.
sig { returns(T.nilable(String)) }
attr_reader :last4
# Transit number of the bank account.
sig { returns(T.nilable(String)) }
attr_reader :transit_number
end
class Affirm < Stripe::StripeObject; end
class AfterpayClearpay < Stripe::StripeObject; end
class Alipay < Stripe::StripeObject; end
class Alma < Stripe::StripeObject; end
class AmazonPay < Stripe::StripeObject; end
class AuBecsDebit < Stripe::StripeObject
# Six-digit number identifying bank and branch associated with this bank account.
sig { returns(T.nilable(String)) }
attr_reader :bsb_number
# Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Last four digits of the bank account number.
sig { returns(T.nilable(String)) }
attr_reader :last4
end
class BacsDebit < Stripe::StripeObject
# Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Last four digits of the bank account number.
sig { returns(T.nilable(String)) }
attr_reader :last4
# Sort code of the bank account. (e.g., `10-20-30`)
sig { returns(T.nilable(String)) }
attr_reader :sort_code
end
class Bancontact < Stripe::StripeObject; end
class Billie < Stripe::StripeObject; end
class BillingDetails < Stripe::StripeObject
class Address < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Billing address.
sig { returns(T.nilable(Address)) }
attr_reader :address
# Email address.
sig { returns(T.nilable(String)) }
attr_reader :email
# Full name.
sig { returns(T.nilable(String)) }
attr_reader :name
# Billing phone number (including extension).
sig { returns(T.nilable(String)) }
attr_reader :phone
# Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
sig { returns(T.nilable(String)) }
attr_reader :tax_id
end
class Blik < Stripe::StripeObject; end
class Boleto < Stripe::StripeObject
# Uniquely identifies the customer tax id (CNPJ or CPF)
sig { returns(String) }
attr_reader :tax_id
end
class Card < Stripe::StripeObject
class Checks < Stripe::StripeObject
# If a address line1 was provided, results of the check, one of `pass`, `fail`, `unavailable`, or `unchecked`.
sig { returns(T.nilable(String)) }
attr_reader :address_line1_check
# If a address postal code was provided, results of the check, one of `pass`, `fail`, `unavailable`, or `unchecked`.
sig { returns(T.nilable(String)) }
attr_reader :address_postal_code_check
# If a CVC was provided, results of the check, one of `pass`, `fail`, `unavailable`, or `unchecked`.
sig { returns(T.nilable(String)) }
attr_reader :cvc_check
end
class GeneratedFrom < Stripe::StripeObject
class PaymentMethodDetails < Stripe::StripeObject
class CardPresent < Stripe::StripeObject
class Offline < Stripe::StripeObject
# Time at which the payment was collected while offline
sig { returns(T.nilable(Integer)) }
attr_reader :stored_at
# The method used to process this payment method offline. Only deferred is allowed.
sig { returns(T.nilable(String)) }
attr_reader :type
end
class Receipt < Stripe::StripeObject
# The type of account being debited or credited
sig { returns(String) }
attr_reader :account_type
# EMV tag 9F26, cryptogram generated by the integrated circuit chip.
sig { returns(T.nilable(String)) }
attr_reader :application_cryptogram
# Mnenomic of the Application Identifier.
sig { returns(T.nilable(String)) }
attr_reader :application_preferred_name
# Identifier for this transaction.
sig { returns(T.nilable(String)) }
attr_reader :authorization_code
# EMV tag 8A. A code returned by the card issuer.
sig { returns(T.nilable(String)) }
attr_reader :authorization_response_code
# Describes the method used by the cardholder to verify ownership of the card. One of the following: `approval`, `failure`, `none`, `offline_pin`, `offline_pin_and_signature`, `online_pin`, or `signature`.
sig { returns(T.nilable(String)) }
attr_reader :cardholder_verification_method
# EMV tag 84. Similar to the application identifier stored on the integrated circuit chip.
sig { returns(T.nilable(String)) }
attr_reader :dedicated_file_name
# The outcome of a series of EMV functions performed by the card reader.
sig { returns(T.nilable(String)) }
attr_reader :terminal_verification_results
# An indication of various EMV functions performed during the transaction.
sig { returns(T.nilable(String)) }
attr_reader :transaction_status_information
end
class Wallet < Stripe::StripeObject
# The type of mobile wallet, one of `apple_pay`, `google_pay`, `samsung_pay`, or `unknown`.
sig { returns(String) }
attr_reader :type
end
# The authorized amount
sig { returns(T.nilable(Integer)) }
attr_reader :amount_authorized
# Card brand. Can be `amex`, `diners`, `discover`, `eftpos_au`, `jcb`, `link`, `mastercard`, `unionpay`, `visa`, or `unknown`.
sig { returns(T.nilable(String)) }
attr_reader :brand
# The [product code](https://stripe.com/docs/card-product-codes) that identifies the specific program or product associated with a card.
sig { returns(T.nilable(String)) }
attr_reader :brand_product
# When using manual capture, a future timestamp after which the charge will be automatically refunded if uncaptured.
sig { returns(Integer) }
attr_reader :capture_before
# The cardholder name as read from the card, in [ISO 7813](https://en.wikipedia.org/wiki/ISO/IEC_7813) format. May include alphanumeric characters, special characters and first/last name separator (`/`). In some cases, the cardholder name may not be available depending on how the issuer has configured the card. Cardholder name is typically not available on swipe or contactless payments, such as those made with Apple Pay and Google Pay.
sig { returns(T.nilable(String)) }
attr_reader :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.
sig { returns(T.nilable(String)) }
attr_reader :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.)
sig { returns(T.nilable(String)) }
attr_reader :description
# Authorization response cryptogram.
sig { returns(T.nilable(String)) }
attr_reader :emv_auth_data
# Two-digit number representing the card's expiration month.
sig { returns(Integer) }
attr_reader :exp_month
# Four-digit number representing the card's expiration year.
sig { returns(Integer) }
attr_reader :exp_year
# Uniquely identifies this particular card number. You can use this attribute to check whether two customers who’ve signed up with you are using the same card number, for example. For payment methods that tokenize card information (Apple Pay, Google Pay), the tokenized number might be provided instead of the underlying card number.
#
# *As of May 1, 2021, card fingerprint in India for Connect changed to allow two fingerprints for the same card---one for India and one for the rest of the world.*
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Card funding type. Can be `credit`, `debit`, `prepaid`, or `unknown`.
sig { returns(T.nilable(String)) }
attr_reader :funding
# ID of a card PaymentMethod generated from the card_present PaymentMethod that may be attached to a Customer for future transactions. Only present if it was possible to generate a card PaymentMethod.
sig { returns(T.nilable(String)) }
attr_reader :generated_card
# Issuer identification number of the card. (For internal use only and not typically available in standard API requests.)
sig { returns(T.nilable(String)) }
attr_reader :iin
# Whether this [PaymentIntent](https://stripe.com/docs/api/payment_intents) is eligible for incremental authorizations. Request support using [request_incremental_authorization_support](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-payment_method_options-card_present-request_incremental_authorization_support).
sig { returns(T::Boolean) }
attr_reader :incremental_authorization_supported
# The name of the card's issuing bank. (For internal use only and not typically available in standard API requests.)
sig { returns(T.nilable(String)) }
attr_reader :issuer
# The last four digits of the card.
sig { returns(T.nilable(String)) }
attr_reader :last4
# Identifies which network this charge was processed on. Can be `amex`, `cartes_bancaires`, `diners`, `discover`, `eftpos_au`, `interac`, `jcb`, `link`, `mastercard`, `unionpay`, `visa`, or `unknown`.
sig { returns(T.nilable(String)) }
attr_reader :network
# This is used by the financial networks to identify a transaction. Visa calls this the Transaction ID, Mastercard calls this the Trace ID, and American Express calls this the Acquirer Reference Data. This value will be present if it is returned by the financial network in the authorization response, and null otherwise.
sig { returns(T.nilable(String)) }
attr_reader :network_transaction_id
# Details about payments collected offline.
sig { returns(T.nilable(Offline)) }
attr_reader :offline
# Defines whether the authorized amount can be over-captured or not
sig { returns(T::Boolean) }
attr_reader :overcapture_supported
# EMV tag 5F2D. Preferred languages specified by the integrated circuit chip.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :preferred_locales
# How card details were read in this transaction.
sig { returns(T.nilable(String)) }
attr_reader :read_method
# A collection of fields required to be displayed on receipts. Only required for EMV transactions.
sig { returns(T.nilable(Receipt)) }
attr_reader :receipt
# Attribute for field wallet
sig { returns(Wallet) }
attr_reader :wallet
end
# Attribute for field card_present
sig { returns(CardPresent) }
attr_reader :card_present
# The type of payment method transaction-specific details from the transaction that generated this `card` payment method. Always `card_present`.
sig { returns(String) }
attr_reader :type
end
# The charge that created this object.
sig { returns(T.nilable(String)) }
attr_reader :charge
# Transaction-specific details of the payment method used in the payment.
sig { returns(T.nilable(PaymentMethodDetails)) }
attr_reader :payment_method_details
# The ID of the SetupAttempt that generated this PaymentMethod, if any.
sig { returns(T.nilable(T.any(String, Stripe::SetupAttempt))) }
attr_reader :setup_attempt
end
class Networks < Stripe::StripeObject
# All networks available for selection via [payment_method_options.card.network](/api/payment_intents/confirm#confirm_payment_intent-payment_method_options-card-network).
sig { returns(T::Array[String]) }
attr_reader :available
# The preferred network for co-branded cards. Can be `cartes_bancaires`, `mastercard`, `visa` or `invalid_preference` if requested network is not valid for the card.
sig { returns(T.nilable(String)) }
attr_reader :preferred
end
class ThreeDSecureUsage < Stripe::StripeObject
# Whether 3D Secure is supported on this card.
sig { returns(T::Boolean) }
attr_reader :supported
end
class Wallet < Stripe::StripeObject
class AmexExpressCheckout < Stripe::StripeObject; end
class ApplePay < Stripe::StripeObject; end
class GooglePay < Stripe::StripeObject; end
class Link < Stripe::StripeObject; end
class Masterpass < Stripe::StripeObject
class BillingAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
class ShippingAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Owner's verified billing address. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(BillingAddress)) }
attr_reader :billing_address
# Owner's verified email. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(String)) }
attr_reader :email
# Owner's verified full name. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(String)) }
attr_reader :name
# Owner's verified shipping address. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(ShippingAddress)) }
attr_reader :shipping_address
end
class SamsungPay < Stripe::StripeObject; end
class VisaCheckout < Stripe::StripeObject
class BillingAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
class ShippingAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Owner's verified billing address. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(BillingAddress)) }
attr_reader :billing_address
# Owner's verified email. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(String)) }
attr_reader :email
# Owner's verified full name. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(String)) }
attr_reader :name
# Owner's verified shipping address. Values are verified or provided by the wallet directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(ShippingAddress)) }
attr_reader :shipping_address
end
# Attribute for field amex_express_checkout
sig { returns(AmexExpressCheckout) }
attr_reader :amex_express_checkout
# Attribute for field apple_pay
sig { returns(ApplePay) }
attr_reader :apple_pay
# (For tokenized numbers only.) The last four digits of the device account number.
sig { returns(T.nilable(String)) }
attr_reader :dynamic_last4
# Attribute for field google_pay
sig { returns(GooglePay) }
attr_reader :google_pay
# Attribute for field link
sig { returns(Link) }
attr_reader :link
# Attribute for field masterpass
sig { returns(Masterpass) }
attr_reader :masterpass
# Attribute for field samsung_pay
sig { returns(SamsungPay) }
attr_reader :samsung_pay
# The type of the card wallet, one of `amex_express_checkout`, `apple_pay`, `google_pay`, `masterpass`, `samsung_pay`, `visa_checkout`, or `link`. An additional hash is included on the Wallet subhash with a name matching this value. It contains additional information specific to the card wallet type.
sig { returns(String) }
attr_reader :type
# Attribute for field visa_checkout
sig { returns(VisaCheckout) }
attr_reader :visa_checkout
end
# Card brand. Can be `amex`, `diners`, `discover`, `eftpos_au`, `jcb`, `link`, `mastercard`, `unionpay`, `visa`, or `unknown`.
sig { returns(String) }
attr_reader :brand
# Checks on Card address and CVC if provided.
sig { returns(T.nilable(Checks)) }
attr_reader :checks
# 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.
sig { returns(T.nilable(String)) }
attr_reader :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.)
sig { returns(T.nilable(String)) }
attr_reader :description
# The brand to use when displaying the card, this accounts for customer's brand choice on dual-branded cards. Can be `american_express`, `cartes_bancaires`, `diners_club`, `discover`, `eftpos_australia`, `interac`, `jcb`, `mastercard`, `union_pay`, `visa`, or `other` and may contain more values in the future.
sig { returns(T.nilable(String)) }
attr_reader :display_brand
# Two-digit number representing the card's expiration month.
sig { returns(Integer) }
attr_reader :exp_month
# Four-digit number representing the card's expiration year.
sig { returns(Integer) }
attr_reader :exp_year
# Uniquely identifies this particular card number. You can use this attribute to check whether two customers who’ve signed up with you are using the same card number, for example. For payment methods that tokenize card information (Apple Pay, Google Pay), the tokenized number might be provided instead of the underlying card number.
#
# *As of May 1, 2021, card fingerprint in India for Connect changed to allow two fingerprints for the same card---one for India and one for the rest of the world.*
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Card funding type. Can be `credit`, `debit`, `prepaid`, or `unknown`.
sig { returns(String) }
attr_reader :funding
# Details of the original PaymentMethod that created this object.
sig { returns(T.nilable(GeneratedFrom)) }
attr_reader :generated_from
# Issuer identification number of the card. (For internal use only and not typically available in standard API requests.)
sig { returns(T.nilable(String)) }
attr_reader :iin
# The name of the card's issuing bank. (For internal use only and not typically available in standard API requests.)
sig { returns(T.nilable(String)) }
attr_reader :issuer
# The last four digits of the card.
sig { returns(String) }
attr_reader :last4
# Contains information about card networks that can be used to process the payment.
sig { returns(T.nilable(Networks)) }
attr_reader :networks
# Status of a card based on the card issuer.
sig { returns(T.nilable(String)) }
attr_reader :regulated_status
# Contains details on how this Card may be used for 3D Secure authentication.
sig { returns(T.nilable(ThreeDSecureUsage)) }
attr_reader :three_d_secure_usage
# If this Card is part of a card wallet, this contains the details of the card wallet.
sig { returns(T.nilable(Wallet)) }
attr_reader :wallet
end
class CardPresent < Stripe::StripeObject
class Networks < Stripe::StripeObject
# All networks available for selection via [payment_method_options.card.network](/api/payment_intents/confirm#confirm_payment_intent-payment_method_options-card-network).
sig { returns(T::Array[String]) }
attr_reader :available
# The preferred network for the card.
sig { returns(T.nilable(String)) }
attr_reader :preferred
end
class Offline < Stripe::StripeObject
# Time at which the payment was collected while offline
sig { returns(T.nilable(Integer)) }
attr_reader :stored_at
# The method used to process this payment method offline. Only deferred is allowed.
sig { returns(T.nilable(String)) }
attr_reader :type
end
class Wallet < Stripe::StripeObject
# The type of mobile wallet, one of `apple_pay`, `google_pay`, `samsung_pay`, or `unknown`.
sig { returns(String) }
attr_reader :type
end
# Card brand. Can be `amex`, `diners`, `discover`, `eftpos_au`, `jcb`, `link`, `mastercard`, `unionpay`, `visa`, or `unknown`.
sig { returns(T.nilable(String)) }
attr_reader :brand
# The [product code](https://stripe.com/docs/card-product-codes) that identifies the specific program or product associated with a card.
sig { returns(T.nilable(String)) }
attr_reader :brand_product
# The cardholder name as read from the card, in [ISO 7813](https://en.wikipedia.org/wiki/ISO/IEC_7813) format. May include alphanumeric characters, special characters and first/last name separator (`/`). In some cases, the cardholder name may not be available depending on how the issuer has configured the card. Cardholder name is typically not available on swipe or contactless payments, such as those made with Apple Pay and Google Pay.
sig { returns(T.nilable(String)) }
attr_reader :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.
sig { returns(T.nilable(String)) }
attr_reader :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.)
sig { returns(T.nilable(String)) }
attr_reader :description
# Two-digit number representing the card's expiration month.
sig { returns(Integer) }
attr_reader :exp_month
# Four-digit number representing the card's expiration year.
sig { returns(Integer) }
attr_reader :exp_year
# Uniquely identifies this particular card number. You can use this attribute to check whether two customers who’ve signed up with you are using the same card number, for example. For payment methods that tokenize card information (Apple Pay, Google Pay), the tokenized number might be provided instead of the underlying card number.
#
# *As of May 1, 2021, card fingerprint in India for Connect changed to allow two fingerprints for the same card---one for India and one for the rest of the world.*
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Card funding type. Can be `credit`, `debit`, `prepaid`, or `unknown`.
sig { returns(T.nilable(String)) }
attr_reader :funding
# Issuer identification number of the card. (For internal use only and not typically available in standard API requests.)
sig { returns(T.nilable(String)) }
attr_reader :iin
# The name of the card's issuing bank. (For internal use only and not typically available in standard API requests.)
sig { returns(T.nilable(String)) }
attr_reader :issuer
# The last four digits of the card.
sig { returns(T.nilable(String)) }
attr_reader :last4
# Contains information about card networks that can be used to process the payment.
sig { returns(T.nilable(Networks)) }
attr_reader :networks
# Details about payment methods collected offline.
sig { returns(T.nilable(Offline)) }
attr_reader :offline
# EMV tag 5F2D. Preferred languages specified by the integrated circuit chip.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :preferred_locales
# How card details were read in this transaction.
sig { returns(T.nilable(String)) }
attr_reader :read_method
# Attribute for field wallet
sig { returns(Wallet) }
attr_reader :wallet
end
class Cashapp < Stripe::StripeObject
# A unique and immutable identifier assigned by Cash App to every buyer.
sig { returns(T.nilable(String)) }
attr_reader :buyer_id
# A public identifier for buyers using Cash App.
sig { returns(T.nilable(String)) }
attr_reader :cashtag
end
class CustomerBalance < Stripe::StripeObject; end
class Eps < Stripe::StripeObject
# The customer's bank. Should be one of `arzte_und_apotheker_bank`, `austrian_anadi_bank_ag`, `bank_austria`, `bankhaus_carl_spangler`, `bankhaus_schelhammer_und_schattera_ag`, `bawag_psk_ag`, `bks_bank_ag`, `brull_kallmus_bank_ag`, `btv_vier_lander_bank`, `capital_bank_grawe_gruppe_ag`, `deutsche_bank_ag`, `dolomitenbank`, `easybank_ag`, `erste_bank_und_sparkassen`, `hypo_alpeadriabank_international_ag`, `hypo_noe_lb_fur_niederosterreich_u_wien`, `hypo_oberosterreich_salzburg_steiermark`, `hypo_tirol_bank_ag`, `hypo_vorarlberg_bank_ag`, `hypo_bank_burgenland_aktiengesellschaft`, `marchfelder_bank`, `oberbank_ag`, `raiffeisen_bankengruppe_osterreich`, `schoellerbank_ag`, `sparda_bank_wien`, `volksbank_gruppe`, `volkskreditbank_ag`, or `vr_bank_braunau`.
sig { returns(T.nilable(String)) }
attr_reader :bank
end
class Fpx < Stripe::StripeObject
# Account holder type, if provided. Can be one of `individual` or `company`.
sig { returns(T.nilable(String)) }
attr_reader :account_holder_type
# The customer's bank, if provided. Can be one of `affin_bank`, `agrobank`, `alliance_bank`, `ambank`, `bank_islam`, `bank_muamalat`, `bank_rakyat`, `bsn`, `cimb`, `hong_leong_bank`, `hsbc`, `kfh`, `maybank2u`, `ocbc`, `public_bank`, `rhb`, `standard_chartered`, `uob`, `deutsche_bank`, `maybank2e`, `pb_enterprise`, or `bank_of_china`.
sig { returns(String) }
attr_reader :bank
end
class Giropay < Stripe::StripeObject; end
class Gopay < Stripe::StripeObject; end
class Grabpay < Stripe::StripeObject; end
class IdBankTransfer < Stripe::StripeObject
# Attribute for field bank
sig { returns(T.nilable(String)) }
attr_reader :bank
# Attribute for field bank_code
sig { returns(T.nilable(String)) }
attr_reader :bank_code
# Attribute for field bank_name
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# Attribute for field display_name
sig { returns(T.nilable(String)) }
attr_reader :display_name
end
class Ideal < Stripe::StripeObject
# The customer's bank, if provided. Can be one of `abn_amro`, `asn_bank`, `bunq`, `handelsbanken`, `ing`, `knab`, `moneyou`, `n26`, `nn`, `rabobank`, `regiobank`, `revolut`, `sns_bank`, `triodos_bank`, `van_lanschot`, or `yoursafe`.
sig { returns(T.nilable(String)) }
attr_reader :bank
# The Bank Identifier Code of the customer's bank, if the bank was provided.
sig { returns(T.nilable(String)) }
attr_reader :bic
end
class InteracPresent < Stripe::StripeObject
class Networks < Stripe::StripeObject
# All networks available for selection via [payment_method_options.card.network](/api/payment_intents/confirm#confirm_payment_intent-payment_method_options-card-network).
sig { returns(T::Array[String]) }
attr_reader :available
# The preferred network for the card.
sig { returns(T.nilable(String)) }
attr_reader :preferred
end
# Card brand. Can be `interac`, `mastercard` or `visa`.
sig { returns(T.nilable(String)) }
attr_reader :brand
# The cardholder name as read from the card, in [ISO 7813](https://en.wikipedia.org/wiki/ISO/IEC_7813) format. May include alphanumeric characters, special characters and first/last name separator (`/`). In some cases, the cardholder name may not be available depending on how the issuer has configured the card. Cardholder name is typically not available on swipe or contactless payments, such as those made with Apple Pay and Google Pay.
sig { returns(T.nilable(String)) }
attr_reader :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.
sig { returns(T.nilable(String)) }
attr_reader :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.)
sig { returns(T.nilable(String)) }
attr_reader :description
# Two-digit number representing the card's expiration month.
sig { returns(Integer) }
attr_reader :exp_month
# Four-digit number representing the card's expiration year.
sig { returns(Integer) }
attr_reader :exp_year
# Uniquely identifies this particular card number. You can use this attribute to check whether two customers who’ve signed up with you are using the same card number, for example. For payment methods that tokenize card information (Apple Pay, Google Pay), the tokenized number might be provided instead of the underlying card number.
#
# *As of May 1, 2021, card fingerprint in India for Connect changed to allow two fingerprints for the same card---one for India and one for the rest of the world.*
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Card funding type. Can be `credit`, `debit`, `prepaid`, or `unknown`.
sig { returns(T.nilable(String)) }
attr_reader :funding
# Issuer identification number of the card. (For internal use only and not typically available in standard API requests.)
sig { returns(T.nilable(String)) }
attr_reader :iin
# The name of the card's issuing bank. (For internal use only and not typically available in standard API requests.)
sig { returns(T.nilable(String)) }
attr_reader :issuer
# The last four digits of the card.
sig { returns(T.nilable(String)) }
attr_reader :last4
# Contains information about card networks that can be used to process the payment.
sig { returns(T.nilable(Networks)) }
attr_reader :networks
# EMV tag 5F2D. Preferred languages specified by the integrated circuit chip.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :preferred_locales
# How card details were read in this transaction.
sig { returns(T.nilable(String)) }
attr_reader :read_method
end
class KakaoPay < Stripe::StripeObject; end
class Klarna < Stripe::StripeObject
class Dob < Stripe::StripeObject
# The day of birth, between 1 and 31.
sig { returns(T.nilable(Integer)) }
attr_reader :day
# The month of birth, between 1 and 12.
sig { returns(T.nilable(Integer)) }
attr_reader :month
# The four-digit year of birth.
sig { returns(T.nilable(Integer)) }
attr_reader :year
end
# The customer's date of birth, if provided.
sig { returns(T.nilable(Dob)) }
attr_reader :dob
end
class Konbini < Stripe::StripeObject; end
class KrCard < Stripe::StripeObject
# The local credit or debit card brand.
sig { returns(T.nilable(String)) }
attr_reader :brand
# The last four digits of the card. This may not be present for American Express cards.
sig { returns(T.nilable(String)) }
attr_reader :last4
end
class Link < Stripe::StripeObject
# Account owner's email address.
sig { returns(T.nilable(String)) }
attr_reader :email
# [Deprecated] This is a legacy parameter that no longer has any function.
sig { returns(String) }
attr_reader :persistent_token
end
class MbWay < Stripe::StripeObject; end
class Mobilepay < Stripe::StripeObject; end
class Multibanco < Stripe::StripeObject; end
class NaverPay < Stripe::StripeObject
# Uniquely identifies this particular Naver Pay account. You can use this attribute to check whether two Naver Pay accounts are the same.
sig { returns(T.nilable(String)) }
attr_reader :buyer_id
# Whether to fund this transaction with Naver Pay points or a card.
sig { returns(String) }
attr_reader :funding
end
class NzBankAccount < Stripe::StripeObject
# The name on the bank account. Only present if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod’s billing details.
sig { returns(T.nilable(String)) }
attr_reader :account_holder_name
# The numeric code for the bank account's bank.
sig { returns(String) }
attr_reader :bank_code
# The name of the bank.
sig { returns(String) }
attr_reader :bank_name
# The numeric code for the bank account's bank branch.
sig { returns(String) }
attr_reader :branch_code
# Last four digits of the bank account number.
sig { returns(String) }
attr_reader :last4
# The suffix of the bank account number.
sig { returns(T.nilable(String)) }
attr_reader :suffix
end
class Oxxo < Stripe::StripeObject; end
class P24 < Stripe::StripeObject
# The customer's bank, if provided.
sig { returns(T.nilable(String)) }
attr_reader :bank
end
class PayByBank < Stripe::StripeObject; end
class Payco < Stripe::StripeObject; end
class Paynow < Stripe::StripeObject; end
class Paypal < Stripe::StripeObject
# Two-letter ISO code representing the buyer's country. Values are provided by PayPal directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(String)) }
attr_reader :country
# Uniquely identifies this particular PayPal account. You can use this attribute to check whether two PayPal accounts are the same.
sig { returns(T.nilable(String)) }
attr_reader :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.
sig { returns(T.nilable(String)) }
attr_reader :payer_email
# PayPal account PayerID. This identifier uniquely identifies the PayPal customer.
sig { returns(T.nilable(String)) }
attr_reader :payer_id
# Owner's verified email. Values are verified or provided by PayPal directly
# (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(String)) }
attr_reader :verified_email
end
class Payto < Stripe::StripeObject
# Bank-State-Branch number of the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bsb_number
# Last four digits of the bank account number.
sig { returns(T.nilable(String)) }
attr_reader :last4
# The PayID alias for the bank account.
sig { returns(T.nilable(String)) }
attr_reader :pay_id
end
class Pix < Stripe::StripeObject; end
class Promptpay < Stripe::StripeObject; end
class Qris < Stripe::StripeObject; end
class RadarOptions < Stripe::StripeObject
# A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
sig { returns(String) }
attr_reader :session
end
class Rechnung < Stripe::StripeObject
class Dob < Stripe::StripeObject
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_reader :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_reader :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_reader :year
end
# Attribute for field dob
sig { returns(Dob) }
attr_reader :dob
end
class RevolutPay < Stripe::StripeObject; end
class SamsungPay < Stripe::StripeObject; end
class Satispay < Stripe::StripeObject; end
class SepaDebit < Stripe::StripeObject
class GeneratedFrom < Stripe::StripeObject
# The ID of the Charge that generated this PaymentMethod, if any.
sig { returns(T.nilable(T.any(String, Stripe::Charge))) }
attr_reader :charge
# The ID of the SetupAttempt that generated this PaymentMethod, if any.
sig { returns(T.nilable(T.any(String, Stripe::SetupAttempt))) }
attr_reader :setup_attempt
end
# Bank code of bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_code
# Branch code of bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :branch_code
# Two-letter ISO code representing the country the bank account is located in.
sig { returns(T.nilable(String)) }
attr_reader :country
# Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Information about the object that generated this PaymentMethod.
sig { returns(T.nilable(GeneratedFrom)) }
attr_reader :generated_from
# Last four characters of the IBAN.
sig { returns(T.nilable(String)) }
attr_reader :last4
end
class Shopeepay < Stripe::StripeObject; end
class Sofort < Stripe::StripeObject
# Two-letter ISO code representing the country the bank account is located in.
sig { returns(T.nilable(String)) }
attr_reader :country
end
class StripeBalance < Stripe::StripeObject
# The connected account ID whose Stripe balance to use as the source of payment
sig { returns(T.nilable(String)) }
attr_reader :account
# The [source_type](https://docs.stripe.com/api/balance/balance_object#balance_object-available-source_types) of the balance
sig { returns(String) }
attr_reader :source_type
end
class Swish < Stripe::StripeObject; end
class Twint < Stripe::StripeObject; end
class UsBankAccount < Stripe::StripeObject
class Networks < Stripe::StripeObject
# The preferred network.
sig { returns(T.nilable(String)) }
attr_reader :preferred
# All supported networks.
sig { returns(T::Array[String]) }
attr_reader :supported
end
class StatusDetails < Stripe::StripeObject
class Blocked < Stripe::StripeObject
# The ACH network code that resulted in this block.
sig { returns(T.nilable(String)) }
attr_reader :network_code
# The reason why this PaymentMethod's fingerprint has been blocked
sig { returns(T.nilable(String)) }
attr_reader :reason
end
# Attribute for field blocked
sig { returns(Blocked) }
attr_reader :blocked
end
# Account holder type: individual or company.
sig { returns(T.nilable(String)) }
attr_reader :account_holder_type
# Account number of the bank account.
sig { returns(T.nilable(String)) }
attr_reader :account_number
# Account type: checkings or savings. Defaults to checking if omitted.
sig { returns(T.nilable(String)) }
attr_reader :account_type
# The name of the bank.
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# The ID of the Financial Connections Account used to create the payment method.
sig { returns(T.nilable(String)) }
attr_reader :financial_connections_account
# Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Last four digits of the bank account number.
sig { returns(T.nilable(String)) }
attr_reader :last4
# Contains information about US bank account networks that can be used.
sig { returns(T.nilable(Networks)) }
attr_reader :networks
# Routing number of the bank account.
sig { returns(T.nilable(String)) }
attr_reader :routing_number
# Contains information about the future reusability of this PaymentMethod.
sig { returns(T.nilable(StatusDetails)) }
attr_reader :status_details
end
class WechatPay < Stripe::StripeObject; end
class Zip < Stripe::StripeObject; end
# Attribute for field acss_debit
sig { returns(AcssDebit) }
attr_reader :acss_debit
# Attribute for field affirm
sig { returns(Affirm) }
attr_reader :affirm
# Attribute for field afterpay_clearpay
sig { returns(AfterpayClearpay) }
attr_reader :afterpay_clearpay
# Attribute for field alipay
sig { returns(Alipay) }
attr_reader :alipay
# This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to “unspecified”.
sig { returns(String) }
attr_reader :allow_redisplay
# Attribute for field alma
sig { returns(Alma) }
attr_reader :alma
# Attribute for field amazon_pay
sig { returns(AmazonPay) }
attr_reader :amazon_pay
# Attribute for field au_becs_debit
sig { returns(AuBecsDebit) }
attr_reader :au_becs_debit
# Attribute for field bacs_debit
sig { returns(BacsDebit) }
attr_reader :bacs_debit
# Attribute for field bancontact
sig { returns(Bancontact) }
attr_reader :bancontact
# Attribute for field billie
sig { returns(Billie) }
attr_reader :billie
# Attribute for field billing_details
sig { returns(BillingDetails) }
attr_reader :billing_details
# Attribute for field blik
sig { returns(Blik) }
attr_reader :blik
# Attribute for field boleto
sig { returns(Boleto) }
attr_reader :boleto
# Attribute for field card
sig { returns(Card) }
attr_reader :card
# Attribute for field card_present
sig { returns(CardPresent) }
attr_reader :card_present
# Attribute for field cashapp
sig { returns(Cashapp) }
attr_reader :cashapp
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# The ID of the Customer to which this PaymentMethod is saved. This will not be set when the PaymentMethod has not been saved to a Customer.
sig { returns(T.nilable(T.any(String, Stripe::Customer))) }
attr_reader :customer
# Attribute for field customer_account
sig { returns(T.nilable(String)) }
attr_reader :customer_account
# Attribute for field customer_balance
sig { returns(CustomerBalance) }
attr_reader :customer_balance
# Attribute for field eps
sig { returns(Eps) }
attr_reader :eps
# Attribute for field fpx
sig { returns(Fpx) }
attr_reader :fpx
# Attribute for field giropay
sig { returns(Giropay) }
attr_reader :giropay
# Attribute for field gopay
sig { returns(Gopay) }
attr_reader :gopay
# Attribute for field grabpay
sig { returns(Grabpay) }
attr_reader :grabpay
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Attribute for field id_bank_transfer
sig { returns(IdBankTransfer) }
attr_reader :id_bank_transfer
# Attribute for field ideal
sig { returns(Ideal) }
attr_reader :ideal
# Attribute for field interac_present
sig { returns(InteracPresent) }
attr_reader :interac_present
# Attribute for field kakao_pay
sig { returns(KakaoPay) }
attr_reader :kakao_pay
# Attribute for field klarna
sig { returns(Klarna) }
attr_reader :klarna
# Attribute for field konbini
sig { returns(Konbini) }
attr_reader :konbini
# Attribute for field kr_card
sig { returns(KrCard) }
attr_reader :kr_card
# Attribute for field link
sig { returns(Link) }
attr_reader :link
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# Attribute for field mb_way
sig { returns(MbWay) }
attr_reader :mb_way
# 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.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# Attribute for field mobilepay
sig { returns(Mobilepay) }
attr_reader :mobilepay
# Attribute for field multibanco
sig { returns(Multibanco) }
attr_reader :multibanco
# Attribute for field naver_pay
sig { returns(NaverPay) }
attr_reader :naver_pay
# Attribute for field nz_bank_account
sig { returns(NzBankAccount) }
attr_reader :nz_bank_account
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Attribute for field oxxo
sig { returns(Oxxo) }
attr_reader :oxxo
# Attribute for field p24
sig { returns(P24) }
attr_reader :p24
# Attribute for field pay_by_bank
sig { returns(PayByBank) }
attr_reader :pay_by_bank
# Attribute for field payco
sig { returns(Payco) }
attr_reader :payco
# Attribute for field paynow
sig { returns(Paynow) }
attr_reader :paynow
# Attribute for field paypal
sig { returns(Paypal) }
attr_reader :paypal
# Attribute for field payto
sig { returns(Payto) }
attr_reader :payto
# Attribute for field pix
sig { returns(Pix) }
attr_reader :pix
# Attribute for field promptpay
sig { returns(Promptpay) }
attr_reader :promptpay
# Attribute for field qris
sig { returns(Qris) }
attr_reader :qris
# Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
sig { returns(RadarOptions) }
attr_reader :radar_options
# Attribute for field rechnung
sig { returns(Rechnung) }
attr_reader :rechnung
# Attribute for field revolut_pay
sig { returns(RevolutPay) }
attr_reader :revolut_pay
# Attribute for field samsung_pay
sig { returns(SamsungPay) }
attr_reader :samsung_pay
# Attribute for field satispay
sig { returns(Satispay) }
attr_reader :satispay
# Attribute for field sepa_debit
sig { returns(SepaDebit) }
attr_reader :sepa_debit
# Attribute for field shopeepay
sig { returns(Shopeepay) }
attr_reader :shopeepay
# Attribute for field sofort
sig { returns(Sofort) }
attr_reader :sofort
# Attribute for field stripe_balance
sig { returns(StripeBalance) }
attr_reader :stripe_balance
# Attribute for field swish
sig { returns(Swish) }
attr_reader :swish
# Attribute for field twint
sig { returns(Twint) }
attr_reader :twint
# The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
sig { returns(String) }
attr_reader :type
# Attribute for field us_bank_account
sig { returns(UsBankAccount) }
attr_reader :us_bank_account
# Attribute for field wechat_pay
sig { returns(WechatPay) }
attr_reader :wechat_pay
# Attribute for field zip
sig { returns(Zip) }
attr_reader :zip
class ListParams < Stripe::RequestParams
# The ID of the customer whose PaymentMethods will be retrieved.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# An optional filter on the list, based on the object `type` field. Without the filter, the list includes all current and future payment method types. If your integration expects only one type of payment method in the response, make sure to provide a type value in the request.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(customer: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String), type: T.nilable(String)).void
}
def initialize(
customer: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil,
type: nil
); end
end
class CreateParams < Stripe::RequestParams
class AcssDebit < Stripe::RequestParams
# Customer's bank account number.
sig { returns(String) }
attr_accessor :account_number
# Institution number of the customer's bank.
sig { returns(String) }
attr_accessor :institution_number
# Transit number of the customer's bank.
sig { returns(String) }
attr_accessor :transit_number
sig {
params(account_number: String, institution_number: String, transit_number: String).void
}
def initialize(account_number: nil, institution_number: nil, transit_number: nil); end
end
class Affirm < Stripe::RequestParams; end
class AfterpayClearpay < Stripe::RequestParams; end
class Alipay < Stripe::RequestParams; end
class Alma < Stripe::RequestParams; end
class AmazonPay < Stripe::RequestParams; end
class AuBecsDebit < Stripe::RequestParams
# The account number for the bank account.
sig { returns(String) }
attr_accessor :account_number
# Bank-State-Branch number of the bank account.
sig { returns(String) }
attr_accessor :bsb_number
sig { params(account_number: String, bsb_number: String).void }
def initialize(account_number: nil, bsb_number: nil); end
end
class BacsDebit < Stripe::RequestParams
# Account number of the bank account that the funds will be debited from.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Sort code of the bank account. (e.g., `10-20-30`)
sig { returns(T.nilable(String)) }
attr_accessor :sort_code
sig { params(account_number: T.nilable(String), sort_code: T.nilable(String)).void }
def initialize(account_number: nil, sort_code: nil); end
end
class Bancontact < Stripe::RequestParams; end
class Billie < Stripe::RequestParams; end
class BillingDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Billing address.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentMethod::CreateParams::BillingDetails::Address))))
}
attr_accessor :address
# Email address.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :email
# Full name.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :name
# Billing phone number (including extension).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :phone
# Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
sig { returns(T.nilable(String)) }
attr_accessor :tax_id
sig {
params(address: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentMethod::CreateParams::BillingDetails::Address))), email: T.nilable(T.nilable(String)), name: T.nilable(T.nilable(String)), phone: T.nilable(T.nilable(String)), tax_id: T.nilable(String)).void
}
def initialize(address: nil, email: nil, name: nil, phone: nil, tax_id: nil); end
end
class Blik < Stripe::RequestParams; end
class Boleto < Stripe::RequestParams
# The tax ID of the customer (CPF for individual consumers or CNPJ for businesses consumers)
sig { returns(String) }
attr_accessor :tax_id
sig { params(tax_id: String).void }
def initialize(tax_id: nil); end
end
class Card < Stripe::RequestParams
class Networks < Stripe::RequestParams
# The customer's preferred card network for co-branded cards. Supports `cartes_bancaires`, `mastercard`, or `visa`. Selection of a network that does not apply to the card will be stored as `invalid_preference` on the card.
sig { returns(T.nilable(String)) }
attr_accessor :preferred
sig { params(preferred: T.nilable(String)).void }
def initialize(preferred: nil); end
end
# The card's CVC. It is highly recommended to always include this value.
sig { returns(T.nilable(String)) }
attr_accessor :cvc
# Two-digit number representing the card's expiration month.
sig { returns(T.nilable(Integer)) }
attr_accessor :exp_month
# Four-digit number representing the card's expiration year.
sig { returns(T.nilable(Integer)) }
attr_accessor :exp_year
# Contains information about card networks used to process the payment.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::Card::Networks)) }
attr_accessor :networks
# The card number, as a string without any separators.
sig { returns(T.nilable(String)) }
attr_accessor :number
# For backwards compatibility, you can alternatively provide a Stripe token (e.g., for Apple Pay, Amex Express Checkout, or legacy Checkout) into the card hash with format card: {token: "tok_visa"}.
sig { returns(T.nilable(String)) }
attr_accessor :token
sig {
params(cvc: T.nilable(String), exp_month: T.nilable(Integer), exp_year: T.nilable(Integer), networks: T.nilable(::Stripe::PaymentMethod::CreateParams::Card::Networks), number: T.nilable(String), token: T.nilable(String)).void
}
def initialize(
cvc: nil,
exp_month: nil,
exp_year: nil,
networks: nil,
number: nil,
token: nil
); end
end
class Cashapp < Stripe::RequestParams; end
class CustomerBalance < Stripe::RequestParams; end
class Eps < Stripe::RequestParams
# The customer's bank.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class Fpx < Stripe::RequestParams
# Account holder type for FPX transaction
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_type
# The customer's bank.
sig { returns(String) }
attr_accessor :bank
sig { params(account_holder_type: T.nilable(String), bank: String).void }
def initialize(account_holder_type: nil, bank: nil); end
end
class Giropay < Stripe::RequestParams; end
class Gopay < Stripe::RequestParams; end
class Grabpay < Stripe::RequestParams; end
class IdBankTransfer < Stripe::RequestParams
# Bank where the account is held.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class Ideal < Stripe::RequestParams
# The customer's bank. Only use this parameter for existing customers. Don't use it for new customers.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class InteracPresent < Stripe::RequestParams; end
class KakaoPay < Stripe::RequestParams; end
class Klarna < Stripe::RequestParams
class Dob < Stripe::RequestParams
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
# Customer's date of birth
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::Klarna::Dob)) }
attr_accessor :dob
sig { params(dob: T.nilable(::Stripe::PaymentMethod::CreateParams::Klarna::Dob)).void }
def initialize(dob: nil); end
end
class Konbini < Stripe::RequestParams; end
class KrCard < Stripe::RequestParams; end
class Link < Stripe::RequestParams; end
class MbWay < Stripe::RequestParams; end
class Mobilepay < Stripe::RequestParams; end
class Multibanco < Stripe::RequestParams; end
class NaverPay < Stripe::RequestParams
# Whether to use Naver Pay points or a card to fund this transaction. If not provided, this defaults to `card`.
sig { returns(T.nilable(String)) }
attr_accessor :funding
sig { params(funding: T.nilable(String)).void }
def initialize(funding: nil); end
end
class NzBankAccount < Stripe::RequestParams
# The name on the bank account. Only required if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod’s billing details.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_name
# The account number for the bank account.
sig { returns(String) }
attr_accessor :account_number
# The numeric code for the bank account's bank.
sig { returns(String) }
attr_accessor :bank_code
# The numeric code for the bank account's bank branch.
sig { returns(String) }
attr_accessor :branch_code
# Attribute for param field reference
sig { returns(T.nilable(String)) }
attr_accessor :reference
# The suffix of the bank account number.
sig { returns(String) }
attr_accessor :suffix
sig {
params(account_holder_name: T.nilable(String), account_number: String, bank_code: String, branch_code: String, reference: T.nilable(String), suffix: String).void
}
def initialize(
account_holder_name: nil,
account_number: nil,
bank_code: nil,
branch_code: nil,
reference: nil,
suffix: nil
); end
end
class Oxxo < Stripe::RequestParams; end
class P24 < Stripe::RequestParams
# The customer's bank.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class PayByBank < Stripe::RequestParams; end
class Payco < Stripe::RequestParams; end
class Paynow < Stripe::RequestParams; end
class Paypal < Stripe::RequestParams; end
class Payto < Stripe::RequestParams
# The account number for the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Bank-State-Branch number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :bsb_number
# The PayID alias for the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :pay_id
sig {
params(account_number: T.nilable(String), bsb_number: T.nilable(String), pay_id: T.nilable(String)).void
}
def initialize(account_number: nil, bsb_number: nil, pay_id: nil); end
end
class Pix < Stripe::RequestParams; end
class Promptpay < Stripe::RequestParams; end
class Qris < Stripe::RequestParams; end
class RadarOptions < Stripe::RequestParams
# A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
sig { returns(T.nilable(String)) }
attr_accessor :session
sig { params(session: T.nilable(String)).void }
def initialize(session: nil); end
end
class Rechnung < Stripe::RequestParams
class Dob < Stripe::RequestParams
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
# Customer's date of birth
sig { returns(::Stripe::PaymentMethod::CreateParams::Rechnung::Dob) }
attr_accessor :dob
sig { params(dob: ::Stripe::PaymentMethod::CreateParams::Rechnung::Dob).void }
def initialize(dob: nil); end
end
class RevolutPay < Stripe::RequestParams; end
class SamsungPay < Stripe::RequestParams; end
class Satispay < Stripe::RequestParams; end
class SepaDebit < Stripe::RequestParams
# IBAN of the bank account.
sig { returns(String) }
attr_accessor :iban
sig { params(iban: String).void }
def initialize(iban: nil); end
end
class Shopeepay < Stripe::RequestParams; end
class Sofort < Stripe::RequestParams
# Two-letter ISO code representing the country the bank account is located in.
sig { returns(String) }
attr_accessor :country
sig { params(country: String).void }
def initialize(country: nil); end
end
class StripeBalance < Stripe::RequestParams
# The connected account ID whose Stripe balance to use as the source of payment
sig { returns(T.nilable(String)) }
attr_accessor :account
# The [source_type](https://docs.stripe.com/api/balance/balance_object#balance_object-available-source_types) of the balance
sig { returns(T.nilable(String)) }
attr_accessor :source_type
sig { params(account: T.nilable(String), source_type: T.nilable(String)).void }
def initialize(account: nil, source_type: nil); end
end
class Swish < Stripe::RequestParams; end
class Twint < Stripe::RequestParams; end
class UsBankAccount < Stripe::RequestParams
# Account holder type: individual or company.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_type
# Account number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Account type: checkings or savings. Defaults to checking if omitted.
sig { returns(T.nilable(String)) }
attr_accessor :account_type
# The ID of a Financial Connections Account to use as a payment method.
sig { returns(T.nilable(String)) }
attr_accessor :financial_connections_account
# Routing number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :routing_number
sig {
params(account_holder_type: T.nilable(String), account_number: T.nilable(String), account_type: T.nilable(String), financial_connections_account: T.nilable(String), routing_number: T.nilable(String)).void
}
def initialize(
account_holder_type: nil,
account_number: nil,
account_type: nil,
financial_connections_account: nil,
routing_number: nil
); end
end
class WechatPay < Stripe::RequestParams; end
class Zip < Stripe::RequestParams; end
# If this is an `acss_debit` PaymentMethod, this hash contains details about the ACSS Debit payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::AcssDebit)) }
attr_accessor :acss_debit
# If this is an `affirm` PaymentMethod, this hash contains details about the Affirm payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::Affirm)) }
attr_accessor :affirm
# If this is an `AfterpayClearpay` PaymentMethod, this hash contains details about the AfterpayClearpay payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::AfterpayClearpay)) }
attr_accessor :afterpay_clearpay
# If this is an `Alipay` PaymentMethod, this hash contains details about the Alipay payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::Alipay)) }
attr_accessor :alipay
# This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :allow_redisplay
# If this is a Alma PaymentMethod, this hash contains details about the Alma payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::Alma)) }
attr_accessor :alma
# If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::AmazonPay)) }
attr_accessor :amazon_pay
# If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::AuBecsDebit)) }
attr_accessor :au_becs_debit
# If this is a `bacs_debit` PaymentMethod, this hash contains details about the Bacs Direct Debit bank account.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::BacsDebit)) }
attr_accessor :bacs_debit
# If this is a `bancontact` PaymentMethod, this hash contains details about the Bancontact payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::Bancontact)) }
attr_accessor :bancontact
# If this is a `billie` PaymentMethod, this hash contains details about the Billie payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::Billie)) }
attr_accessor :billie
# Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::BillingDetails)) }
attr_accessor :billing_details
# If this is a `blik` PaymentMethod, this hash contains details about the BLIK payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::Blik)) }
attr_accessor :blik
# If this is a `boleto` PaymentMethod, this hash contains details about the Boleto payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::Boleto)) }
attr_accessor :boleto
# If this is a `card` PaymentMethod, this hash contains the user's card details. For backwards compatibility, you can alternatively provide a Stripe token (e.g., for Apple Pay, Amex Express Checkout, or legacy Checkout) into the card hash with format `card: {token: "tok_visa"}`. When providing a card number, you must meet the requirements for [PCI compliance](https://stripe.com/docs/security#validating-pci-compliance). We strongly recommend using Stripe.js instead of interacting with this API directly.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::Card)) }
attr_accessor :card
# If this is a `cashapp` PaymentMethod, this hash contains details about the Cash App Pay payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::Cashapp)) }
attr_accessor :cashapp
# The `Customer` to whom the original PaymentMethod is attached.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# If this is a `customer_balance` PaymentMethod, this hash contains details about the CustomerBalance payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::CustomerBalance)) }
attr_accessor :customer_balance
# If this is an `eps` PaymentMethod, this hash contains details about the EPS payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::Eps)) }
attr_accessor :eps
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::Fpx)) }
attr_accessor :fpx
# If this is a `giropay` PaymentMethod, this hash contains details about the Giropay payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::Giropay)) }
attr_accessor :giropay
# If this is a Gopay PaymentMethod, this hash contains details about the Gopay payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::Gopay)) }
attr_accessor :gopay
# If this is a `grabpay` PaymentMethod, this hash contains details about the GrabPay payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::Grabpay)) }
attr_accessor :grabpay
# If this is an `IdBankTransfer` PaymentMethod, this hash contains details about the IdBankTransfer payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::IdBankTransfer)) }
attr_accessor :id_bank_transfer
# If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::Ideal)) }
attr_accessor :ideal
# If this is an `interac_present` PaymentMethod, this hash contains details about the Interac Present payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::InteracPresent)) }
attr_accessor :interac_present
# If this is a `kakao_pay` PaymentMethod, this hash contains details about the Kakao Pay payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::KakaoPay)) }
attr_accessor :kakao_pay
# If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::Klarna)) }
attr_accessor :klarna
# If this is a `konbini` PaymentMethod, this hash contains details about the Konbini payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::Konbini)) }
attr_accessor :konbini
# If this is a `kr_card` PaymentMethod, this hash contains details about the Korean Card payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::KrCard)) }
attr_accessor :kr_card
# If this is an `Link` PaymentMethod, this hash contains details about the Link payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::Link)) }
attr_accessor :link
# If this is a MB WAY PaymentMethod, this hash contains details about the MB WAY payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::MbWay)) }
attr_accessor :mb_way
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# If this is a `mobilepay` PaymentMethod, this hash contains details about the MobilePay payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::Mobilepay)) }
attr_accessor :mobilepay
# If this is a `multibanco` PaymentMethod, this hash contains details about the Multibanco payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::Multibanco)) }
attr_accessor :multibanco
# If this is a `naver_pay` PaymentMethod, this hash contains details about the Naver Pay payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::NaverPay)) }
attr_accessor :naver_pay
# If this is an nz_bank_account PaymentMethod, this hash contains details about the nz_bank_account payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::NzBankAccount)) }
attr_accessor :nz_bank_account
# If this is an `oxxo` PaymentMethod, this hash contains details about the OXXO payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::Oxxo)) }
attr_accessor :oxxo
# If this is a `p24` PaymentMethod, this hash contains details about the P24 payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::P24)) }
attr_accessor :p24
# If this is a `pay_by_bank` PaymentMethod, this hash contains details about the PayByBank payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::PayByBank)) }
attr_accessor :pay_by_bank
# If this is a `payco` PaymentMethod, this hash contains details about the PAYCO payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::Payco)) }
attr_accessor :payco
# The PaymentMethod to share.
sig { returns(T.nilable(String)) }
attr_accessor :payment_method
# If this is a `paynow` PaymentMethod, this hash contains details about the PayNow payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::Paynow)) }
attr_accessor :paynow
# If this is a `paypal` PaymentMethod, this hash contains details about the PayPal payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::Paypal)) }
attr_accessor :paypal
# If this is a `payto` PaymentMethod, this hash contains details about the PayTo payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::Payto)) }
attr_accessor :payto
# If this is a `pix` PaymentMethod, this hash contains details about the Pix payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::Pix)) }
attr_accessor :pix
# If this is a `promptpay` PaymentMethod, this hash contains details about the PromptPay payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::Promptpay)) }
attr_accessor :promptpay
# If this is a `qris` PaymentMethod, this hash contains details about the QRIS payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::Qris)) }
attr_accessor :qris
# Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::RadarOptions)) }
attr_accessor :radar_options
# If this is a `rechnung` PaymentMethod, this hash contains details about the Rechnung payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::Rechnung)) }
attr_accessor :rechnung
# If this is a `revolut_pay` PaymentMethod, this hash contains details about the Revolut Pay payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::RevolutPay)) }
attr_accessor :revolut_pay
# If this is a `samsung_pay` PaymentMethod, this hash contains details about the SamsungPay payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::SamsungPay)) }
attr_accessor :samsung_pay
# If this is a `satispay` PaymentMethod, this hash contains details about the Satispay payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::Satispay)) }
attr_accessor :satispay
# If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::SepaDebit)) }
attr_accessor :sepa_debit
# If this is a Shopeepay PaymentMethod, this hash contains details about the Shopeepay payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::Shopeepay)) }
attr_accessor :shopeepay
# If this is a `sofort` PaymentMethod, this hash contains details about the SOFORT payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::Sofort)) }
attr_accessor :sofort
# This hash contains details about the Stripe balance payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::StripeBalance)) }
attr_accessor :stripe_balance
# If this is a `swish` PaymentMethod, this hash contains details about the Swish payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::Swish)) }
attr_accessor :swish
# If this is a TWINT PaymentMethod, this hash contains details about the TWINT payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::Twint)) }
attr_accessor :twint
# The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
sig { returns(T.nilable(String)) }
attr_accessor :type
# If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::UsBankAccount)) }
attr_accessor :us_bank_account
# If this is an `wechat_pay` PaymentMethod, this hash contains details about the wechat_pay payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::WechatPay)) }
attr_accessor :wechat_pay
# If this is a `zip` PaymentMethod, this hash contains details about the Zip payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::CreateParams::Zip)) }
attr_accessor :zip
sig {
params(acss_debit: T.nilable(::Stripe::PaymentMethod::CreateParams::AcssDebit), affirm: T.nilable(::Stripe::PaymentMethod::CreateParams::Affirm), afterpay_clearpay: T.nilable(::Stripe::PaymentMethod::CreateParams::AfterpayClearpay), alipay: T.nilable(::Stripe::PaymentMethod::CreateParams::Alipay), allow_redisplay: T.nilable(String), alma: T.nilable(::Stripe::PaymentMethod::CreateParams::Alma), amazon_pay: T.nilable(::Stripe::PaymentMethod::CreateParams::AmazonPay), au_becs_debit: T.nilable(::Stripe::PaymentMethod::CreateParams::AuBecsDebit), bacs_debit: T.nilable(::Stripe::PaymentMethod::CreateParams::BacsDebit), bancontact: T.nilable(::Stripe::PaymentMethod::CreateParams::Bancontact), billie: T.nilable(::Stripe::PaymentMethod::CreateParams::Billie), billing_details: T.nilable(::Stripe::PaymentMethod::CreateParams::BillingDetails), blik: T.nilable(::Stripe::PaymentMethod::CreateParams::Blik), boleto: T.nilable(::Stripe::PaymentMethod::CreateParams::Boleto), card: T.nilable(::Stripe::PaymentMethod::CreateParams::Card), cashapp: T.nilable(::Stripe::PaymentMethod::CreateParams::Cashapp), customer: T.nilable(String), customer_balance: T.nilable(::Stripe::PaymentMethod::CreateParams::CustomerBalance), eps: T.nilable(::Stripe::PaymentMethod::CreateParams::Eps), expand: T.nilable(T::Array[String]), fpx: T.nilable(::Stripe::PaymentMethod::CreateParams::Fpx), giropay: T.nilable(::Stripe::PaymentMethod::CreateParams::Giropay), gopay: T.nilable(::Stripe::PaymentMethod::CreateParams::Gopay), grabpay: T.nilable(::Stripe::PaymentMethod::CreateParams::Grabpay), id_bank_transfer: T.nilable(::Stripe::PaymentMethod::CreateParams::IdBankTransfer), ideal: T.nilable(::Stripe::PaymentMethod::CreateParams::Ideal), interac_present: T.nilable(::Stripe::PaymentMethod::CreateParams::InteracPresent), kakao_pay: T.nilable(::Stripe::PaymentMethod::CreateParams::KakaoPay), klarna: T.nilable(::Stripe::PaymentMethod::CreateParams::Klarna), konbini: T.nilable(::Stripe::PaymentMethod::CreateParams::Konbini), kr_card: T.nilable(::Stripe::PaymentMethod::CreateParams::KrCard), link: T.nilable(::Stripe::PaymentMethod::CreateParams::Link), mb_way: T.nilable(::Stripe::PaymentMethod::CreateParams::MbWay), metadata: T.nilable(T::Hash[String, String]), mobilepay: T.nilable(::Stripe::PaymentMethod::CreateParams::Mobilepay), multibanco: T.nilable(::Stripe::PaymentMethod::CreateParams::Multibanco), naver_pay: T.nilable(::Stripe::PaymentMethod::CreateParams::NaverPay), nz_bank_account: T.nilable(::Stripe::PaymentMethod::CreateParams::NzBankAccount), oxxo: T.nilable(::Stripe::PaymentMethod::CreateParams::Oxxo), p24: T.nilable(::Stripe::PaymentMethod::CreateParams::P24), pay_by_bank: T.nilable(::Stripe::PaymentMethod::CreateParams::PayByBank), payco: T.nilable(::Stripe::PaymentMethod::CreateParams::Payco), payment_method: T.nilable(String), paynow: T.nilable(::Stripe::PaymentMethod::CreateParams::Paynow), paypal: T.nilable(::Stripe::PaymentMethod::CreateParams::Paypal), payto: T.nilable(::Stripe::PaymentMethod::CreateParams::Payto), pix: T.nilable(::Stripe::PaymentMethod::CreateParams::Pix), promptpay: T.nilable(::Stripe::PaymentMethod::CreateParams::Promptpay), qris: T.nilable(::Stripe::PaymentMethod::CreateParams::Qris), radar_options: T.nilable(::Stripe::PaymentMethod::CreateParams::RadarOptions), rechnung: T.nilable(::Stripe::PaymentMethod::CreateParams::Rechnung), revolut_pay: T.nilable(::Stripe::PaymentMethod::CreateParams::RevolutPay), samsung_pay: T.nilable(::Stripe::PaymentMethod::CreateParams::SamsungPay), satispay: T.nilable(::Stripe::PaymentMethod::CreateParams::Satispay), sepa_debit: T.nilable(::Stripe::PaymentMethod::CreateParams::SepaDebit), shopeepay: T.nilable(::Stripe::PaymentMethod::CreateParams::Shopeepay), sofort: T.nilable(::Stripe::PaymentMethod::CreateParams::Sofort), stripe_balance: T.nilable(::Stripe::PaymentMethod::CreateParams::StripeBalance), swish: T.nilable(::Stripe::PaymentMethod::CreateParams::Swish), twint: T.nilable(::Stripe::PaymentMethod::CreateParams::Twint), type: T.nilable(String), us_bank_account: T.nilable(::Stripe::PaymentMethod::CreateParams::UsBankAccount), wechat_pay: T.nilable(::Stripe::PaymentMethod::CreateParams::WechatPay), zip: T.nilable(::Stripe::PaymentMethod::CreateParams::Zip)).void
}
def initialize(
acss_debit: nil,
affirm: nil,
afterpay_clearpay: nil,
alipay: nil,
allow_redisplay: nil,
alma: nil,
amazon_pay: nil,
au_becs_debit: nil,
bacs_debit: nil,
bancontact: nil,
billie: nil,
billing_details: nil,
blik: nil,
boleto: nil,
card: nil,
cashapp: nil,
customer: nil,
customer_balance: nil,
eps: nil,
expand: nil,
fpx: nil,
giropay: nil,
gopay: nil,
grabpay: nil,
id_bank_transfer: nil,
ideal: nil,
interac_present: nil,
kakao_pay: nil,
klarna: nil,
konbini: nil,
kr_card: nil,
link: nil,
mb_way: nil,
metadata: nil,
mobilepay: nil,
multibanco: nil,
naver_pay: nil,
nz_bank_account: nil,
oxxo: nil,
p24: nil,
pay_by_bank: nil,
payco: nil,
payment_method: nil,
paynow: nil,
paypal: nil,
payto: nil,
pix: nil,
promptpay: nil,
qris: nil,
radar_options: nil,
rechnung: nil,
revolut_pay: nil,
samsung_pay: nil,
satispay: nil,
sepa_debit: nil,
shopeepay: nil,
sofort: nil,
stripe_balance: nil,
swish: nil,
twint: nil,
type: nil,
us_bank_account: nil,
wechat_pay: nil,
zip: nil
); end
end
class UpdateParams < Stripe::RequestParams
class BillingDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Billing address.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentMethod::UpdateParams::BillingDetails::Address))))
}
attr_accessor :address
# Email address.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :email
# Full name.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :name
# Billing phone number (including extension).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :phone
# Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
sig { returns(T.nilable(String)) }
attr_accessor :tax_id
sig {
params(address: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentMethod::UpdateParams::BillingDetails::Address))), email: T.nilable(T.nilable(String)), name: T.nilable(T.nilable(String)), phone: T.nilable(T.nilable(String)), tax_id: T.nilable(String)).void
}
def initialize(address: nil, email: nil, name: nil, phone: nil, tax_id: nil); end
end
class Card < Stripe::RequestParams
class Networks < Stripe::RequestParams
# The customer's preferred card network for co-branded cards. Supports `cartes_bancaires`, `mastercard`, or `visa`. Selection of a network that does not apply to the card will be stored as `invalid_preference` on the card.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :preferred
sig { params(preferred: T.nilable(T.nilable(T.any(String, String)))).void }
def initialize(preferred: nil); end
end
# Two-digit number representing the card's expiration month.
sig { returns(T.nilable(Integer)) }
attr_accessor :exp_month
# Four-digit number representing the card's expiration year.
sig { returns(T.nilable(Integer)) }
attr_accessor :exp_year
# Contains information about card networks used to process the payment.
sig { returns(T.nilable(::Stripe::PaymentMethod::UpdateParams::Card::Networks)) }
attr_accessor :networks
sig {
params(exp_month: T.nilable(Integer), exp_year: T.nilable(Integer), networks: T.nilable(::Stripe::PaymentMethod::UpdateParams::Card::Networks)).void
}
def initialize(exp_month: nil, exp_year: nil, networks: nil); end
end
class Link < Stripe::RequestParams; end
class PayByBank < Stripe::RequestParams; end
class Payto < Stripe::RequestParams
# The account number for the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Bank-State-Branch number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :bsb_number
# The PayID alias for the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :pay_id
sig {
params(account_number: T.nilable(String), bsb_number: T.nilable(String), pay_id: T.nilable(String)).void
}
def initialize(account_number: nil, bsb_number: nil, pay_id: nil); end
end
class UsBankAccount < Stripe::RequestParams
# Bank account holder type.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_type
# Bank account type.
sig { returns(T.nilable(String)) }
attr_accessor :account_type
sig { params(account_holder_type: T.nilable(String), account_type: T.nilable(String)).void }
def initialize(account_holder_type: nil, account_type: nil); end
end
# This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :allow_redisplay
# Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
sig { returns(T.nilable(::Stripe::PaymentMethod::UpdateParams::BillingDetails)) }
attr_accessor :billing_details
# If this is a `card` PaymentMethod, this hash contains the user's card details.
sig { returns(T.nilable(::Stripe::PaymentMethod::UpdateParams::Card)) }
attr_accessor :card
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# If this is an `Link` PaymentMethod, this hash contains details about the Link payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::UpdateParams::Link)) }
attr_accessor :link
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# If this is a `pay_by_bank` PaymentMethod, this hash contains details about the PayByBank payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::UpdateParams::PayByBank)) }
attr_accessor :pay_by_bank
# If this is a `payto` PaymentMethod, this hash contains details about the PayTo payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::UpdateParams::Payto)) }
attr_accessor :payto
# If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
sig { returns(T.nilable(::Stripe::PaymentMethod::UpdateParams::UsBankAccount)) }
attr_accessor :us_bank_account
sig {
params(allow_redisplay: T.nilable(String), billing_details: T.nilable(::Stripe::PaymentMethod::UpdateParams::BillingDetails), card: T.nilable(::Stripe::PaymentMethod::UpdateParams::Card), expand: T.nilable(T::Array[String]), link: T.nilable(::Stripe::PaymentMethod::UpdateParams::Link), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), pay_by_bank: T.nilable(::Stripe::PaymentMethod::UpdateParams::PayByBank), payto: T.nilable(::Stripe::PaymentMethod::UpdateParams::Payto), us_bank_account: T.nilable(::Stripe::PaymentMethod::UpdateParams::UsBankAccount)).void
}
def initialize(
allow_redisplay: nil,
billing_details: nil,
card: nil,
expand: nil,
link: nil,
metadata: nil,
pay_by_bank: nil,
payto: nil,
us_bank_account: nil
); end
end
class AttachParams < Stripe::RequestParams
# The ID of the customer to which to attach the PaymentMethod.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# The ID of the account to which to attach the PaymentMethod.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig {
params(customer: T.nilable(String), customer_account: T.nilable(String), expand: T.nilable(T::Array[String])).void
}
def initialize(customer: nil, customer_account: nil, expand: nil); end
end
class DetachParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Attaches a PaymentMethod object to a Customer.
#
# To attach a new PaymentMethod to a customer for future payments, we recommend you use a [SetupIntent](https://docs.stripe.com/docs/api/setup_intents)
# or a PaymentIntent with [setup_future_usage](https://docs.stripe.com/docs/api/payment_intents/create#create_payment_intent-setup_future_usage).
# These approaches will perform any necessary steps to set up the PaymentMethod for future payments. Using the /v1/payment_methods/:id/attach
# endpoint without first using a SetupIntent or PaymentIntent with setup_future_usage does not optimize the PaymentMethod for
# future use, which makes later declines and payment friction more likely.
# See [Optimizing cards for future payments](https://docs.stripe.com/docs/payments/payment-intents#future-usage) for more information about setting up
# future payments.
#
# To use this PaymentMethod as the default for invoice or subscription payments,
# set [invoice_settings.default_payment_method](https://docs.stripe.com/docs/api/customers/update#update_customer-invoice_settings-default_payment_method),
# on the Customer to the PaymentMethod's ID.
sig {
params(params: T.any(::Stripe::PaymentMethod::AttachParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentMethod)
}
def attach(params = {}, opts = {}); end
# Attaches a PaymentMethod object to a Customer.
#
# To attach a new PaymentMethod to a customer for future payments, we recommend you use a [SetupIntent](https://docs.stripe.com/docs/api/setup_intents)
# or a PaymentIntent with [setup_future_usage](https://docs.stripe.com/docs/api/payment_intents/create#create_payment_intent-setup_future_usage).
# These approaches will perform any necessary steps to set up the PaymentMethod for future payments. Using the /v1/payment_methods/:id/attach
# endpoint without first using a SetupIntent or PaymentIntent with setup_future_usage does not optimize the PaymentMethod for
# future use, which makes later declines and payment friction more likely.
# See [Optimizing cards for future payments](https://docs.stripe.com/docs/payments/payment-intents#future-usage) for more information about setting up
# future payments.
#
# To use this PaymentMethod as the default for invoice or subscription payments,
# set [invoice_settings.default_payment_method](https://docs.stripe.com/docs/api/customers/update#update_customer-invoice_settings-default_payment_method),
# on the Customer to the PaymentMethod's ID.
sig {
params(payment_method: String, params: T.any(::Stripe::PaymentMethod::AttachParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentMethod)
}
def self.attach(payment_method, params = {}, opts = {}); end
# Creates a PaymentMethod object. Read the [Stripe.js reference](https://docs.stripe.com/docs/stripe-js/reference#stripe-create-payment-method) to learn how to create PaymentMethods via Stripe.js.
#
# Instead of creating a PaymentMethod directly, we recommend using the [PaymentIntents API to accept a payment immediately or the SetupIntent](https://docs.stripe.com/docs/payments/accept-a-payment) API to collect payment method details ahead of a future payment.
sig {
params(params: T.any(::Stripe::PaymentMethod::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentMethod)
}
def self.create(params = {}, opts = {}); end
# Detaches a PaymentMethod object from a Customer. After a PaymentMethod is detached, it can no longer be used for a payment or re-attached to a Customer.
sig {
params(params: T.any(::Stripe::PaymentMethod::DetachParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentMethod)
}
def detach(params = {}, opts = {}); end
# Detaches a PaymentMethod object from a Customer. After a PaymentMethod is detached, it can no longer be used for a payment or re-attached to a Customer.
sig {
params(payment_method: String, params: T.any(::Stripe::PaymentMethod::DetachParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentMethod)
}
def self.detach(payment_method, params = {}, opts = {}); end
# Returns a list of PaymentMethods for Treasury flows. If you want to list the PaymentMethods attached to a Customer for payments, you should use the [List a Customer's PaymentMethods](https://docs.stripe.com/docs/api/payment_methods/customer_list) API instead.
sig {
params(params: T.any(::Stripe::PaymentMethod::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Updates a PaymentMethod object. A PaymentMethod must be attached a customer to be updated.
sig {
params(payment_method: String, params: T.any(::Stripe::PaymentMethod::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentMethod)
}
def self.update(payment_method, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
# PaymentMethodConfigurations control which payment methods are displayed to your customers when you don't explicitly specify payment method types. You can have multiple configurations with different sets of payment methods for different scenarios.
#
# There are two types of PaymentMethodConfigurations. Which is used depends on the [charge type](https://stripe.com/docs/connect/charges):
#
# **Direct** configurations apply to payments created on your account, including Connect destination charges, Connect separate charges and transfers, and payments not involving Connect.
#
# **Child** configurations apply to payments created on your connected accounts using direct charges, and charges with the on_behalf_of parameter.
#
# Child configurations have a `parent` that sets default values and controls which settings connected accounts may override. You can specify a parent ID at payment time, and Stripe will automatically resolve the connected account's associated child configuration. Parent configurations are [managed in the dashboard](https://dashboard.stripe.com/settings/payment_methods/connected_accounts) and are not available in this API.
#
# Related guides:
# - [Payment Method Configurations API](https://stripe.com/docs/connect/payment-method-configurations)
# - [Multiple configurations on dynamic payment methods](https://stripe.com/docs/payments/multiple-payment-method-configs)
# - [Multiple configurations for your Connect accounts](https://stripe.com/docs/connect/multiple-payment-method-configurations)
class PaymentMethodConfiguration < APIResource
class AcssDebit < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class Affirm < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class AfterpayClearpay < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class Alipay < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class Alma < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class AmazonPay < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class ApplePay < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class AuBecsDebit < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class BacsDebit < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class Bancontact < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class Billie < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class Blik < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class Boleto < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class Card < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class CartesBancaires < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class Cashapp < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class CustomerBalance < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class Eps < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class Fpx < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class Giropay < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class GooglePay < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class Gopay < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class Grabpay < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class IdBankTransfer < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class Ideal < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class Jcb < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class KakaoPay < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class Klarna < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class Konbini < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class KrCard < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class Link < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class Mobilepay < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class Multibanco < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class NaverPay < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class NzBankAccount < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class Oxxo < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class P24 < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class PayByBank < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class Payco < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class Paynow < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class Paypal < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class Payto < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class Pix < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class Promptpay < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class Qris < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class RevolutPay < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class SamsungPay < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class Satispay < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class SepaDebit < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class Shopeepay < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class Sofort < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class Swish < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class Twint < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class UsBankAccount < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class WechatPay < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
class Zip < Stripe::StripeObject
class DisplayPreference < Stripe::StripeObject
# For child configs, whether or not the account's preference will be observed. If `false`, the parent configuration's default is used.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :overridable
# The account's display preference.
sig { returns(String) }
attr_reader :preference
# The effective display preference value.
sig { returns(String) }
attr_reader :value
end
# Whether this payment method may be offered at checkout. True if `display_preference` is `on` and the payment method's capability is active.
sig { returns(T::Boolean) }
attr_reader :available
# Attribute for field display_preference
sig { returns(DisplayPreference) }
attr_reader :display_preference
end
# Attribute for field acss_debit
sig { returns(AcssDebit) }
attr_reader :acss_debit
# Whether the configuration can be used for new payments.
sig { returns(T::Boolean) }
attr_reader :active
# Attribute for field affirm
sig { returns(Affirm) }
attr_reader :affirm
# Attribute for field afterpay_clearpay
sig { returns(AfterpayClearpay) }
attr_reader :afterpay_clearpay
# Attribute for field alipay
sig { returns(Alipay) }
attr_reader :alipay
# Attribute for field alma
sig { returns(Alma) }
attr_reader :alma
# Attribute for field amazon_pay
sig { returns(AmazonPay) }
attr_reader :amazon_pay
# Attribute for field apple_pay
sig { returns(ApplePay) }
attr_reader :apple_pay
# For child configs, the Connect application associated with the configuration.
sig { returns(T.nilable(String)) }
attr_reader :application
# Attribute for field au_becs_debit
sig { returns(AuBecsDebit) }
attr_reader :au_becs_debit
# Attribute for field bacs_debit
sig { returns(BacsDebit) }
attr_reader :bacs_debit
# Attribute for field bancontact
sig { returns(Bancontact) }
attr_reader :bancontact
# Attribute for field billie
sig { returns(Billie) }
attr_reader :billie
# Attribute for field blik
sig { returns(Blik) }
attr_reader :blik
# Attribute for field boleto
sig { returns(Boleto) }
attr_reader :boleto
# Attribute for field card
sig { returns(Card) }
attr_reader :card
# Attribute for field cartes_bancaires
sig { returns(CartesBancaires) }
attr_reader :cartes_bancaires
# Attribute for field cashapp
sig { returns(Cashapp) }
attr_reader :cashapp
# Attribute for field customer_balance
sig { returns(CustomerBalance) }
attr_reader :customer_balance
# Attribute for field eps
sig { returns(Eps) }
attr_reader :eps
# Attribute for field fpx
sig { returns(Fpx) }
attr_reader :fpx
# Attribute for field giropay
sig { returns(Giropay) }
attr_reader :giropay
# Attribute for field google_pay
sig { returns(GooglePay) }
attr_reader :google_pay
# Attribute for field gopay
sig { returns(Gopay) }
attr_reader :gopay
# Attribute for field grabpay
sig { returns(Grabpay) }
attr_reader :grabpay
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Attribute for field id_bank_transfer
sig { returns(IdBankTransfer) }
attr_reader :id_bank_transfer
# Attribute for field ideal
sig { returns(Ideal) }
attr_reader :ideal
# The default configuration is used whenever a payment method configuration is not specified.
sig { returns(T::Boolean) }
attr_reader :is_default
# Attribute for field jcb
sig { returns(Jcb) }
attr_reader :jcb
# Attribute for field kakao_pay
sig { returns(KakaoPay) }
attr_reader :kakao_pay
# Attribute for field klarna
sig { returns(Klarna) }
attr_reader :klarna
# Attribute for field konbini
sig { returns(Konbini) }
attr_reader :konbini
# Attribute for field kr_card
sig { returns(KrCard) }
attr_reader :kr_card
# Attribute for field link
sig { returns(Link) }
attr_reader :link
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# Attribute for field mobilepay
sig { returns(Mobilepay) }
attr_reader :mobilepay
# Attribute for field multibanco
sig { returns(Multibanco) }
attr_reader :multibanco
# The configuration's name.
sig { returns(String) }
attr_reader :name
# Attribute for field naver_pay
sig { returns(NaverPay) }
attr_reader :naver_pay
# Attribute for field nz_bank_account
sig { returns(NzBankAccount) }
attr_reader :nz_bank_account
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Attribute for field oxxo
sig { returns(Oxxo) }
attr_reader :oxxo
# Attribute for field p24
sig { returns(P24) }
attr_reader :p24
# For child configs, the configuration's parent configuration.
sig { returns(T.nilable(String)) }
attr_reader :parent
# Attribute for field pay_by_bank
sig { returns(PayByBank) }
attr_reader :pay_by_bank
# Attribute for field payco
sig { returns(Payco) }
attr_reader :payco
# Attribute for field paynow
sig { returns(Paynow) }
attr_reader :paynow
# Attribute for field paypal
sig { returns(Paypal) }
attr_reader :paypal
# Attribute for field payto
sig { returns(Payto) }
attr_reader :payto
# Attribute for field pix
sig { returns(Pix) }
attr_reader :pix
# Attribute for field promptpay
sig { returns(Promptpay) }
attr_reader :promptpay
# Attribute for field qris
sig { returns(Qris) }
attr_reader :qris
# Attribute for field revolut_pay
sig { returns(RevolutPay) }
attr_reader :revolut_pay
# Attribute for field samsung_pay
sig { returns(SamsungPay) }
attr_reader :samsung_pay
# Attribute for field satispay
sig { returns(Satispay) }
attr_reader :satispay
# Attribute for field sepa_debit
sig { returns(SepaDebit) }
attr_reader :sepa_debit
# Attribute for field shopeepay
sig { returns(Shopeepay) }
attr_reader :shopeepay
# Attribute for field sofort
sig { returns(Sofort) }
attr_reader :sofort
# Attribute for field swish
sig { returns(Swish) }
attr_reader :swish
# Attribute for field twint
sig { returns(Twint) }
attr_reader :twint
# Attribute for field us_bank_account
sig { returns(UsBankAccount) }
attr_reader :us_bank_account
# Attribute for field wechat_pay
sig { returns(WechatPay) }
attr_reader :wechat_pay
# Attribute for field zip
sig { returns(Zip) }
attr_reader :zip
class ListParams < Stripe::RequestParams
# The Connect application to filter by.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :application
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(application: T.nilable(T.nilable(String)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
application: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class AcssDebit < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::AcssDebit::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::AcssDebit::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Affirm < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Affirm::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Affirm::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class AfterpayClearpay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::AfterpayClearpay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::AfterpayClearpay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Alipay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Alipay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Alipay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Alma < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Alma::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Alma::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class AmazonPay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::AmazonPay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::AmazonPay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class ApplePay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::ApplePay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::ApplePay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class ApplePayLater < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::ApplePayLater::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::ApplePayLater::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class AuBecsDebit < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::AuBecsDebit::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::AuBecsDebit::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class BacsDebit < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::BacsDebit::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::BacsDebit::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Bancontact < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Bancontact::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Bancontact::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Billie < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Billie::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Billie::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Blik < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Blik::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Blik::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Boleto < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Boleto::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Boleto::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Card < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Card::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Card::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class CartesBancaires < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::CartesBancaires::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::CartesBancaires::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Cashapp < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Cashapp::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Cashapp::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class CustomerBalance < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::CustomerBalance::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::CustomerBalance::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Eps < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Eps::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Eps::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Fpx < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Fpx::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Fpx::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Giropay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Giropay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Giropay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class GooglePay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::GooglePay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::GooglePay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Gopay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Gopay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Gopay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Grabpay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Grabpay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Grabpay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class IdBankTransfer < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::IdBankTransfer::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::IdBankTransfer::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Ideal < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Ideal::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Ideal::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Jcb < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Jcb::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Jcb::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class KakaoPay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::KakaoPay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::KakaoPay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Klarna < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Klarna::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Klarna::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Konbini < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Konbini::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Konbini::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class KrCard < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::KrCard::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::KrCard::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Link < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Link::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Link::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Mobilepay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Mobilepay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Mobilepay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Multibanco < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Multibanco::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Multibanco::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class NaverPay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::NaverPay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::NaverPay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class NzBankAccount < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::NzBankAccount::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::NzBankAccount::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Oxxo < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Oxxo::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Oxxo::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class P24 < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::P24::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::P24::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class PayByBank < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::PayByBank::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::PayByBank::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Payco < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Payco::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Payco::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Paynow < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Paynow::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Paynow::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Paypal < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Paypal::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Paypal::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Payto < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Payto::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Payto::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Pix < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Pix::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Pix::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Promptpay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Promptpay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Promptpay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Qris < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Qris::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Qris::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class RevolutPay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::RevolutPay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::RevolutPay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class SamsungPay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::SamsungPay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::SamsungPay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Satispay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Satispay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Satispay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class SepaDebit < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::SepaDebit::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::SepaDebit::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Shopeepay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Shopeepay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Shopeepay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Sofort < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Sofort::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Sofort::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Swish < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Swish::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Swish::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Twint < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Twint::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Twint::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class UsBankAccount < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::UsBankAccount::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::UsBankAccount::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class WechatPay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::WechatPay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::WechatPay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Zip < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Zip::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Zip::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
# Canadian pre-authorized debit payments, check this [page](https://stripe.com/docs/payments/acss-debit) for more details like country availability.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::AcssDebit)) }
attr_accessor :acss_debit
# [Affirm](https://www.affirm.com/) gives your customers a way to split purchases over a series of payments. Depending on the purchase, they can pay with four interest-free payments (Split Pay) or pay over a longer term (Installments), which might include interest. Check this [page](https://stripe.com/docs/payments/affirm) for more details like country availability.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Affirm)) }
attr_accessor :affirm
# Afterpay gives your customers a way to pay for purchases in installments, check this [page](https://stripe.com/docs/payments/afterpay-clearpay) for more details like country availability. Afterpay is particularly popular among businesses selling fashion, beauty, and sports products.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::AfterpayClearpay))
}
attr_accessor :afterpay_clearpay
# Alipay is a digital wallet in China that has more than a billion active users worldwide. Alipay users can pay on the web or on a mobile device using login credentials or their Alipay app. Alipay has a low dispute rate and reduces fraud by authenticating payments using the customer's login credentials. Check this [page](https://stripe.com/docs/payments/alipay) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Alipay)) }
attr_accessor :alipay
# Alma is a Buy Now, Pay Later payment method that offers customers the ability to pay in 2, 3, or 4 installments.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Alma)) }
attr_accessor :alma
# Amazon Pay is a wallet payment method that lets your customers check out the same way as on Amazon.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::AmazonPay)) }
attr_accessor :amazon_pay
# Stripe users can accept [Apple Pay](https://stripe.com/payments/apple-pay) in iOS applications in iOS 9 and later, and on the web in Safari starting with iOS 10 or macOS Sierra. There are no additional fees to process Apple Pay payments, and the [pricing](https://stripe.com/pricing) is the same as other card transactions. Check this [page](https://stripe.com/docs/apple-pay) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::ApplePay)) }
attr_accessor :apple_pay
# Apple Pay Later, a payment method for customers to buy now and pay later, gives your customers a way to split purchases into four installments across six weeks.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::ApplePayLater)) }
attr_accessor :apple_pay_later
# Stripe users in Australia can accept Bulk Electronic Clearing System (BECS) direct debit payments from customers with an Australian bank account. Check this [page](https://stripe.com/docs/payments/au-becs-debit) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::AuBecsDebit)) }
attr_accessor :au_becs_debit
# Stripe users in the UK can accept Bacs Direct Debit payments from customers with a UK bank account, check this [page](https://stripe.com/docs/payments/payment-methods/bacs-debit) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::BacsDebit)) }
attr_accessor :bacs_debit
# Bancontact is the most popular online payment method in Belgium, with over 15 million cards in circulation. [Customers](https://stripe.com/docs/api/customers) use a Bancontact card or mobile app linked to a Belgian bank account to make online payments that are secure, guaranteed, and confirmed immediately. Check this [page](https://stripe.com/docs/payments/bancontact) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Bancontact)) }
attr_accessor :bancontact
# Billie is a [single-use](https://docs.stripe.com/payments/payment-methods#usage) payment method that offers businesses Pay by Invoice where they offer payment terms ranging from 7-120 days. Customers are redirected from your website or app, authorize the payment with Billie, then return to your website or app. You get [immediate notification](/payments/payment-methods#payment-notification) of whether the payment succeeded or failed.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Billie)) }
attr_accessor :billie
# BLIK is a [single use](https://stripe.com/docs/payments/payment-methods#usage) payment method that requires customers to authenticate their payments. When customers want to pay online using BLIK, they request a six-digit code from their banking application and enter it into the payment collection form. Check this [page](https://stripe.com/docs/payments/blik) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Blik)) }
attr_accessor :blik
# Boleto is an official (regulated by the Central Bank of Brazil) payment method in Brazil. Check this [page](https://stripe.com/docs/payments/boleto) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Boleto)) }
attr_accessor :boleto
# Cards are a popular way for consumers and businesses to pay online or in person. Stripe supports global and local card networks.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Card)) }
attr_accessor :card
# Cartes Bancaires is France's local card network. More than 95% of these cards are co-branded with either Visa or Mastercard, meaning you can process these cards over either Cartes Bancaires or the Visa or Mastercard networks. Check this [page](https://stripe.com/docs/payments/cartes-bancaires) for more details.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::CartesBancaires))
}
attr_accessor :cartes_bancaires
# Cash App is a popular consumer app in the US that allows customers to bank, invest, send, and receive money using their digital wallet. Check this [page](https://stripe.com/docs/payments/cash-app-pay) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Cashapp)) }
attr_accessor :cashapp
# Uses a customer’s [cash balance](https://stripe.com/docs/payments/customer-balance) for the payment. The cash balance can be funded via a bank transfer. Check this [page](https://stripe.com/docs/payments/bank-transfers) for more details.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::CustomerBalance))
}
attr_accessor :customer_balance
# EPS is an Austria-based payment method that allows customers to complete transactions online using their bank credentials. EPS is supported by all Austrian banks and is accepted by over 80% of Austrian online retailers. Check this [page](https://stripe.com/docs/payments/eps) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Eps)) }
attr_accessor :eps
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Financial Process Exchange (FPX) is a Malaysia-based payment method that allows customers to complete transactions online using their bank credentials. Bank Negara Malaysia (BNM), the Central Bank of Malaysia, and eleven other major Malaysian financial institutions are members of the PayNet Group, which owns and operates FPX. It is one of the most popular online payment methods in Malaysia, with nearly 90 million transactions in 2018 according to BNM. Check this [page](https://stripe.com/docs/payments/fpx) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Fpx)) }
attr_accessor :fpx
# giropay is a German payment method based on online banking, introduced in 2006. It allows customers to complete transactions online using their online banking environment, with funds debited from their bank account. Depending on their bank, customers confirm payments on giropay using a second factor of authentication or a PIN. giropay accounts for 10% of online checkouts in Germany. Check this [page](https://stripe.com/docs/payments/giropay) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Giropay)) }
attr_accessor :giropay
# Google Pay allows customers to make payments in your app or website using any credit or debit card saved to their Google Account, including those from Google Play, YouTube, Chrome, or an Android device. Use the Google Pay API to request any credit or debit card stored in your customer's Google account. Check this [page](https://stripe.com/docs/google-pay) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::GooglePay)) }
attr_accessor :google_pay
# GoPay is a [single use](https://stripe.com/docs/payments/payment-methods#usage) digital wallet payment method popular in Indonesia. When paying with GoPay, customers authenticate and approve payments using the Gojek app. Desktop checkout is performed by scanning a QR code. When checking out on mobile, customers are redirected to the Gojek app to confirm payment.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Gopay)) }
attr_accessor :gopay
# GrabPay is a payment method developed by [Grab](https://www.grab.com/sg/consumer/finance/pay/). GrabPay is a digital wallet - customers maintain a balance in their wallets that they pay out with. Check this [page](https://stripe.com/docs/payments/grabpay) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Grabpay)) }
attr_accessor :grabpay
# Stripe users in Indonesia can receive bank transfers from customers in Indonesia. Bank transfers are a popular B2C and B2B payment method in Indonesia.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::IdBankTransfer)) }
attr_accessor :id_bank_transfer
# iDEAL is a Netherlands-based payment method that allows customers to complete transactions online using their bank credentials. All major Dutch banks are members of Currence, the scheme that operates iDEAL, making it the most popular online payment method in the Netherlands with a share of online transactions close to 55%. Check this [page](https://stripe.com/docs/payments/ideal) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Ideal)) }
attr_accessor :ideal
# JCB is a credit card company based in Japan. JCB is currently available in Japan to businesses approved by JCB, and available to all businesses in Australia, Canada, Hong Kong, Japan, New Zealand, Singapore, Switzerland, United Kingdom, United States, and all countries in the European Economic Area except Iceland. Check this [page](https://support.stripe.com/questions/accepting-japan-credit-bureau-%28jcb%29-payments) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Jcb)) }
attr_accessor :jcb
# Kakao Pay is a popular local wallet available in South Korea.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::KakaoPay)) }
attr_accessor :kakao_pay
# Klarna gives customers a range of [payment options](https://stripe.com/docs/payments/klarna#payment-options) during checkout. Available payment options vary depending on the customer's billing address and the transaction amount. These payment options make it convenient for customers to purchase items in all price ranges. Check this [page](https://stripe.com/docs/payments/klarna) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Klarna)) }
attr_accessor :klarna
# Konbini allows customers in Japan to pay for bills and online purchases at convenience stores with cash. Check this [page](https://stripe.com/docs/payments/konbini) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Konbini)) }
attr_accessor :konbini
# Korean cards let users pay using locally issued cards from South Korea.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::KrCard)) }
attr_accessor :kr_card
# [Link](https://stripe.com/docs/payments/link) is a payment method network. With Link, users save their payment details once, then reuse that information to pay with one click for any business on the network.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Link)) }
attr_accessor :link
# MobilePay is a [single-use](https://stripe.com/docs/payments/payment-methods#usage) card wallet payment method used in Denmark and Finland. It allows customers to [authenticate and approve](https://stripe.com/docs/payments/payment-methods#customer-actions) payments using the MobilePay app. Check this [page](https://stripe.com/docs/payments/mobilepay) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Mobilepay)) }
attr_accessor :mobilepay
# Stripe users in Europe and the United States can accept Multibanco payments from customers in Portugal using [Sources](https://stripe.com/docs/sources)—a single integration path for creating payments using any supported method.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Multibanco)) }
attr_accessor :multibanco
# Configuration name.
sig { returns(T.nilable(String)) }
attr_accessor :name
# Naver Pay is a popular local wallet available in South Korea.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::NaverPay)) }
attr_accessor :naver_pay
# Stripe users in New Zealand can accept Bulk Electronic Clearing System (BECS) direct debit payments from customers with a New Zeland bank account. Check this [page](https://stripe.com/docs/payments/nz-bank-account) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::NzBankAccount)) }
attr_accessor :nz_bank_account
# OXXO is a Mexican chain of convenience stores with thousands of locations across Latin America and represents nearly 20% of online transactions in Mexico. OXXO allows customers to pay bills and online purchases in-store with cash. Check this [page](https://stripe.com/docs/payments/oxxo) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Oxxo)) }
attr_accessor :oxxo
# Przelewy24 is a Poland-based payment method aggregator that allows customers to complete transactions online using bank transfers and other methods. Bank transfers account for 30% of online payments in Poland and Przelewy24 provides a way for customers to pay with over 165 banks. Check this [page](https://stripe.com/docs/payments/p24) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::P24)) }
attr_accessor :p24
# Configuration's parent configuration. Specify to create a child configuration.
sig { returns(T.nilable(String)) }
attr_accessor :parent
# Pay by bank is a redirect payment method backed by bank transfers. A customer is redirected to their bank to authorize a bank transfer for a given amount. This removes a lot of the error risks inherent in waiting for the customer to initiate a transfer themselves, and is less expensive than card payments.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::PayByBank)) }
attr_accessor :pay_by_bank
# PAYCO is a [single-use](https://docs.stripe.com/payments/payment-methods#usage local wallet available in South Korea.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Payco)) }
attr_accessor :payco
# PayNow is a Singapore-based payment method that allows customers to make a payment using their preferred app from participating banks and participating non-bank financial institutions. Check this [page](https://stripe.com/docs/payments/paynow) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Paynow)) }
attr_accessor :paynow
# PayPal, a digital wallet popular with customers in Europe, allows your customers worldwide to pay using their PayPal account. Check this [page](https://stripe.com/docs/payments/paypal) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Paypal)) }
attr_accessor :paypal
# PayTo is a [real-time](https://docs.stripe.com/payments/real-time) payment method that enables customers in Australia to pay by providing their bank account details. Customers must accept a mandate authorizing you to debit their account. Check this [page](https://docs.stripe.com/payments/payto) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Payto)) }
attr_accessor :payto
# Pix is a payment method popular in Brazil. When paying with Pix, customers authenticate and approve payments by scanning a QR code in their preferred banking app. Check this [page](https://docs.stripe.com/payments/pix) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Pix)) }
attr_accessor :pix
# PromptPay is a Thailand-based payment method that allows customers to make a payment using their preferred app from participating banks. Check this [page](https://stripe.com/docs/payments/promptpay) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Promptpay)) }
attr_accessor :promptpay
# QRIS is a [real-time](https://docs.stripe.com/payments/real-time) payment method popular in Indonesia. When paying with QRIS, customers authenticate and approve payments by scanning a QR code in their preferred digital wallet app.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Qris)) }
attr_accessor :qris
# Revolut Pay, developed by Revolut, a global finance app, is a digital wallet payment method. Revolut Pay uses the customer’s stored balance or cards to fund the payment, and offers the option for non-Revolut customers to save their details after their first purchase.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::RevolutPay)) }
attr_accessor :revolut_pay
# Samsung Pay is a [single-use](https://docs.stripe.com/payments/payment-methods#usage local wallet available in South Korea.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::SamsungPay)) }
attr_accessor :samsung_pay
# Satispay is a [single-use](https://docs.stripe.com/payments/payment-methods#usage) payment method where customers are required to [authenticate](/payments/payment-methods#customer-actions) their payment. Customers pay by being redirected from your website or app, authorizing the payment with Satispay, then returning to your website or app. You get [immediate notification](/payments/payment-methods#payment-notification) of whether the payment succeeded or failed.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Satispay)) }
attr_accessor :satispay
# The [Single Euro Payments Area (SEPA)](https://en.wikipedia.org/wiki/Single_Euro_Payments_Area) is an initiative of the European Union to simplify payments within and across member countries. SEPA established and enforced banking standards to allow for the direct debiting of every EUR-denominated bank account within the SEPA region, check this [page](https://stripe.com/docs/payments/sepa-debit) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::SepaDebit)) }
attr_accessor :sepa_debit
# ShopeePay is a [single use](https://stripe.com/docs/payments/payment-methods#usage) digital wallet payment method popular in Indonesia. When paying with GoPay, customers authenticate and approve payments using the Shopee app. Desktop checkout is performed by scanning a QR code. When checking out on mobile, customers are redirected to the Shopee app to confirm payment.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Shopeepay)) }
attr_accessor :shopeepay
# Stripe users in Europe and the United States can use the [Payment Intents API](https://stripe.com/docs/payments/payment-intents)—a single integration path for creating payments using any supported method—to accept [Sofort](https://www.sofort.com/) payments from customers. Check this [page](https://stripe.com/docs/payments/sofort) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Sofort)) }
attr_accessor :sofort
# Swish is a [real-time](https://stripe.com/docs/payments/real-time) payment method popular in Sweden. It allows customers to [authenticate and approve](https://stripe.com/docs/payments/payment-methods#customer-actions) payments using the Swish mobile app and the Swedish BankID mobile app. Check this [page](https://stripe.com/docs/payments/swish) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Swish)) }
attr_accessor :swish
# Twint is a payment method popular in Switzerland. It allows customers to pay using their mobile phone. Check this [page](https://docs.stripe.com/payments/twint) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Twint)) }
attr_accessor :twint
# Stripe users in the United States can accept ACH direct debit payments from customers with a US bank account using the Automated Clearing House (ACH) payments system operated by Nacha. Check this [page](https://stripe.com/docs/payments/ach-direct-debit) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::UsBankAccount)) }
attr_accessor :us_bank_account
# WeChat, owned by Tencent, is China's leading mobile app with over 1 billion monthly active users. Chinese consumers can use WeChat Pay to pay for goods and services inside of businesses' apps and websites. WeChat Pay users buy most frequently in gaming, e-commerce, travel, online education, and food/nutrition. Check this [page](https://stripe.com/docs/payments/wechat-pay) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::WechatPay)) }
attr_accessor :wechat_pay
# Zip gives your customers a way to split purchases over a series of payments. Check this [page](https://stripe.com/docs/payments/zip) for more details like country availability.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Zip)) }
attr_accessor :zip
sig {
params(acss_debit: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::AcssDebit), affirm: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Affirm), afterpay_clearpay: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::AfterpayClearpay), alipay: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Alipay), alma: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Alma), amazon_pay: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::AmazonPay), apple_pay: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::ApplePay), apple_pay_later: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::ApplePayLater), au_becs_debit: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::AuBecsDebit), bacs_debit: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::BacsDebit), bancontact: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Bancontact), billie: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Billie), blik: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Blik), boleto: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Boleto), card: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Card), cartes_bancaires: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::CartesBancaires), cashapp: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Cashapp), customer_balance: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::CustomerBalance), eps: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Eps), expand: T.nilable(T::Array[String]), fpx: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Fpx), giropay: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Giropay), google_pay: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::GooglePay), gopay: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Gopay), grabpay: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Grabpay), id_bank_transfer: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::IdBankTransfer), ideal: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Ideal), jcb: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Jcb), kakao_pay: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::KakaoPay), klarna: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Klarna), konbini: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Konbini), kr_card: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::KrCard), link: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Link), mobilepay: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Mobilepay), multibanco: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Multibanco), name: T.nilable(String), naver_pay: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::NaverPay), nz_bank_account: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::NzBankAccount), oxxo: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Oxxo), p24: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::P24), parent: T.nilable(String), pay_by_bank: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::PayByBank), payco: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Payco), paynow: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Paynow), paypal: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Paypal), payto: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Payto), pix: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Pix), promptpay: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Promptpay), qris: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Qris), revolut_pay: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::RevolutPay), samsung_pay: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::SamsungPay), satispay: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Satispay), sepa_debit: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::SepaDebit), shopeepay: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Shopeepay), sofort: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Sofort), swish: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Swish), twint: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Twint), us_bank_account: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::UsBankAccount), wechat_pay: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::WechatPay), zip: T.nilable(::Stripe::PaymentMethodConfiguration::CreateParams::Zip)).void
}
def initialize(
acss_debit: nil,
affirm: nil,
afterpay_clearpay: nil,
alipay: nil,
alma: nil,
amazon_pay: nil,
apple_pay: nil,
apple_pay_later: nil,
au_becs_debit: nil,
bacs_debit: nil,
bancontact: nil,
billie: nil,
blik: nil,
boleto: nil,
card: nil,
cartes_bancaires: nil,
cashapp: nil,
customer_balance: nil,
eps: nil,
expand: nil,
fpx: nil,
giropay: nil,
google_pay: nil,
gopay: nil,
grabpay: nil,
id_bank_transfer: nil,
ideal: nil,
jcb: nil,
kakao_pay: nil,
klarna: nil,
konbini: nil,
kr_card: nil,
link: nil,
mobilepay: nil,
multibanco: nil,
name: nil,
naver_pay: nil,
nz_bank_account: nil,
oxxo: nil,
p24: nil,
parent: nil,
pay_by_bank: nil,
payco: nil,
paynow: nil,
paypal: nil,
payto: nil,
pix: nil,
promptpay: nil,
qris: nil,
revolut_pay: nil,
samsung_pay: nil,
satispay: nil,
sepa_debit: nil,
shopeepay: nil,
sofort: nil,
swish: nil,
twint: nil,
us_bank_account: nil,
wechat_pay: nil,
zip: nil
); end
end
class UpdateParams < Stripe::RequestParams
class AcssDebit < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::AcssDebit::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::AcssDebit::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Affirm < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Affirm::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Affirm::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class AfterpayClearpay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::AfterpayClearpay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::AfterpayClearpay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Alipay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Alipay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Alipay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Alma < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Alma::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Alma::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class AmazonPay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::AmazonPay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::AmazonPay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class ApplePay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::ApplePay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::ApplePay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class ApplePayLater < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::ApplePayLater::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::ApplePayLater::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class AuBecsDebit < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::AuBecsDebit::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::AuBecsDebit::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class BacsDebit < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::BacsDebit::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::BacsDebit::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Bancontact < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Bancontact::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Bancontact::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Billie < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Billie::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Billie::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Blik < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Blik::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Blik::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Boleto < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Boleto::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Boleto::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Card < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Card::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Card::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class CartesBancaires < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::CartesBancaires::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::CartesBancaires::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Cashapp < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Cashapp::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Cashapp::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class CustomerBalance < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::CustomerBalance::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::CustomerBalance::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Eps < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Eps::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Eps::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Fpx < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Fpx::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Fpx::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Giropay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Giropay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Giropay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class GooglePay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::GooglePay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::GooglePay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Gopay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Gopay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Gopay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Grabpay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Grabpay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Grabpay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class IdBankTransfer < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::IdBankTransfer::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::IdBankTransfer::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Ideal < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Ideal::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Ideal::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Jcb < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Jcb::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Jcb::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class KakaoPay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::KakaoPay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::KakaoPay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Klarna < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Klarna::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Klarna::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Konbini < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Konbini::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Konbini::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class KrCard < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::KrCard::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::KrCard::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Link < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Link::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Link::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Mobilepay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Mobilepay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Mobilepay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Multibanco < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Multibanco::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Multibanco::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class NaverPay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::NaverPay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::NaverPay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class NzBankAccount < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::NzBankAccount::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::NzBankAccount::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Oxxo < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Oxxo::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Oxxo::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class P24 < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::P24::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::P24::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class PayByBank < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::PayByBank::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::PayByBank::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Payco < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Payco::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Payco::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Paynow < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Paynow::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Paynow::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Paypal < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Paypal::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Paypal::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Payto < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Payto::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Payto::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Pix < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Pix::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Pix::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Promptpay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Promptpay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Promptpay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Qris < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Qris::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Qris::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class RevolutPay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::RevolutPay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::RevolutPay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class SamsungPay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::SamsungPay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::SamsungPay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Satispay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Satispay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Satispay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class SepaDebit < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::SepaDebit::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::SepaDebit::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Shopeepay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Shopeepay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Shopeepay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Sofort < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Sofort::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Sofort::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Swish < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Swish::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Swish::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Twint < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Twint::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Twint::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class UsBankAccount < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::UsBankAccount::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::UsBankAccount::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class WechatPay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::WechatPay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::WechatPay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Zip < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Zip::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Zip::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
# Canadian pre-authorized debit payments, check this [page](https://stripe.com/docs/payments/acss-debit) for more details like country availability.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::AcssDebit)) }
attr_accessor :acss_debit
# Whether the configuration can be used for new payments.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# [Affirm](https://www.affirm.com/) gives your customers a way to split purchases over a series of payments. Depending on the purchase, they can pay with four interest-free payments (Split Pay) or pay over a longer term (Installments), which might include interest. Check this [page](https://stripe.com/docs/payments/affirm) for more details like country availability.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Affirm)) }
attr_accessor :affirm
# Afterpay gives your customers a way to pay for purchases in installments, check this [page](https://stripe.com/docs/payments/afterpay-clearpay) for more details like country availability. Afterpay is particularly popular among businesses selling fashion, beauty, and sports products.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::AfterpayClearpay))
}
attr_accessor :afterpay_clearpay
# Alipay is a digital wallet in China that has more than a billion active users worldwide. Alipay users can pay on the web or on a mobile device using login credentials or their Alipay app. Alipay has a low dispute rate and reduces fraud by authenticating payments using the customer's login credentials. Check this [page](https://stripe.com/docs/payments/alipay) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Alipay)) }
attr_accessor :alipay
# Alma is a Buy Now, Pay Later payment method that offers customers the ability to pay in 2, 3, or 4 installments.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Alma)) }
attr_accessor :alma
# Amazon Pay is a wallet payment method that lets your customers check out the same way as on Amazon.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::AmazonPay)) }
attr_accessor :amazon_pay
# Stripe users can accept [Apple Pay](https://stripe.com/payments/apple-pay) in iOS applications in iOS 9 and later, and on the web in Safari starting with iOS 10 or macOS Sierra. There are no additional fees to process Apple Pay payments, and the [pricing](https://stripe.com/pricing) is the same as other card transactions. Check this [page](https://stripe.com/docs/apple-pay) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::ApplePay)) }
attr_accessor :apple_pay
# Apple Pay Later, a payment method for customers to buy now and pay later, gives your customers a way to split purchases into four installments across six weeks.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::ApplePayLater)) }
attr_accessor :apple_pay_later
# Stripe users in Australia can accept Bulk Electronic Clearing System (BECS) direct debit payments from customers with an Australian bank account. Check this [page](https://stripe.com/docs/payments/au-becs-debit) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::AuBecsDebit)) }
attr_accessor :au_becs_debit
# Stripe users in the UK can accept Bacs Direct Debit payments from customers with a UK bank account, check this [page](https://stripe.com/docs/payments/payment-methods/bacs-debit) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::BacsDebit)) }
attr_accessor :bacs_debit
# Bancontact is the most popular online payment method in Belgium, with over 15 million cards in circulation. [Customers](https://stripe.com/docs/api/customers) use a Bancontact card or mobile app linked to a Belgian bank account to make online payments that are secure, guaranteed, and confirmed immediately. Check this [page](https://stripe.com/docs/payments/bancontact) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Bancontact)) }
attr_accessor :bancontact
# Billie is a [single-use](https://docs.stripe.com/payments/payment-methods#usage) payment method that offers businesses Pay by Invoice where they offer payment terms ranging from 7-120 days. Customers are redirected from your website or app, authorize the payment with Billie, then return to your website or app. You get [immediate notification](/payments/payment-methods#payment-notification) of whether the payment succeeded or failed.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Billie)) }
attr_accessor :billie
# BLIK is a [single use](https://stripe.com/docs/payments/payment-methods#usage) payment method that requires customers to authenticate their payments. When customers want to pay online using BLIK, they request a six-digit code from their banking application and enter it into the payment collection form. Check this [page](https://stripe.com/docs/payments/blik) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Blik)) }
attr_accessor :blik
# Boleto is an official (regulated by the Central Bank of Brazil) payment method in Brazil. Check this [page](https://stripe.com/docs/payments/boleto) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Boleto)) }
attr_accessor :boleto
# Cards are a popular way for consumers and businesses to pay online or in person. Stripe supports global and local card networks.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Card)) }
attr_accessor :card
# Cartes Bancaires is France's local card network. More than 95% of these cards are co-branded with either Visa or Mastercard, meaning you can process these cards over either Cartes Bancaires or the Visa or Mastercard networks. Check this [page](https://stripe.com/docs/payments/cartes-bancaires) for more details.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::CartesBancaires))
}
attr_accessor :cartes_bancaires
# Cash App is a popular consumer app in the US that allows customers to bank, invest, send, and receive money using their digital wallet. Check this [page](https://stripe.com/docs/payments/cash-app-pay) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Cashapp)) }
attr_accessor :cashapp
# Uses a customer’s [cash balance](https://stripe.com/docs/payments/customer-balance) for the payment. The cash balance can be funded via a bank transfer. Check this [page](https://stripe.com/docs/payments/bank-transfers) for more details.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::CustomerBalance))
}
attr_accessor :customer_balance
# EPS is an Austria-based payment method that allows customers to complete transactions online using their bank credentials. EPS is supported by all Austrian banks and is accepted by over 80% of Austrian online retailers. Check this [page](https://stripe.com/docs/payments/eps) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Eps)) }
attr_accessor :eps
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Financial Process Exchange (FPX) is a Malaysia-based payment method that allows customers to complete transactions online using their bank credentials. Bank Negara Malaysia (BNM), the Central Bank of Malaysia, and eleven other major Malaysian financial institutions are members of the PayNet Group, which owns and operates FPX. It is one of the most popular online payment methods in Malaysia, with nearly 90 million transactions in 2018 according to BNM. Check this [page](https://stripe.com/docs/payments/fpx) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Fpx)) }
attr_accessor :fpx
# giropay is a German payment method based on online banking, introduced in 2006. It allows customers to complete transactions online using their online banking environment, with funds debited from their bank account. Depending on their bank, customers confirm payments on giropay using a second factor of authentication or a PIN. giropay accounts for 10% of online checkouts in Germany. Check this [page](https://stripe.com/docs/payments/giropay) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Giropay)) }
attr_accessor :giropay
# Google Pay allows customers to make payments in your app or website using any credit or debit card saved to their Google Account, including those from Google Play, YouTube, Chrome, or an Android device. Use the Google Pay API to request any credit or debit card stored in your customer's Google account. Check this [page](https://stripe.com/docs/google-pay) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::GooglePay)) }
attr_accessor :google_pay
# GoPay is a [single use](https://stripe.com/docs/payments/payment-methods#usage) digital wallet payment method popular in Indonesia. When paying with GoPay, customers authenticate and approve payments using the Gojek app. Desktop checkout is performed by scanning a QR code. When checking out on mobile, customers are redirected to the Gojek app to confirm payment.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Gopay)) }
attr_accessor :gopay
# GrabPay is a payment method developed by [Grab](https://www.grab.com/sg/consumer/finance/pay/). GrabPay is a digital wallet - customers maintain a balance in their wallets that they pay out with. Check this [page](https://stripe.com/docs/payments/grabpay) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Grabpay)) }
attr_accessor :grabpay
# Stripe users in Indonesia can receive bank transfers from customers in Indonesia. Bank transfers are a popular B2C and B2B payment method in Indonesia.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::IdBankTransfer)) }
attr_accessor :id_bank_transfer
# iDEAL is a Netherlands-based payment method that allows customers to complete transactions online using their bank credentials. All major Dutch banks are members of Currence, the scheme that operates iDEAL, making it the most popular online payment method in the Netherlands with a share of online transactions close to 55%. Check this [page](https://stripe.com/docs/payments/ideal) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Ideal)) }
attr_accessor :ideal
# JCB is a credit card company based in Japan. JCB is currently available in Japan to businesses approved by JCB, and available to all businesses in Australia, Canada, Hong Kong, Japan, New Zealand, Singapore, Switzerland, United Kingdom, United States, and all countries in the European Economic Area except Iceland. Check this [page](https://support.stripe.com/questions/accepting-japan-credit-bureau-%28jcb%29-payments) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Jcb)) }
attr_accessor :jcb
# Kakao Pay is a popular local wallet available in South Korea.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::KakaoPay)) }
attr_accessor :kakao_pay
# Klarna gives customers a range of [payment options](https://stripe.com/docs/payments/klarna#payment-options) during checkout. Available payment options vary depending on the customer's billing address and the transaction amount. These payment options make it convenient for customers to purchase items in all price ranges. Check this [page](https://stripe.com/docs/payments/klarna) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Klarna)) }
attr_accessor :klarna
# Konbini allows customers in Japan to pay for bills and online purchases at convenience stores with cash. Check this [page](https://stripe.com/docs/payments/konbini) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Konbini)) }
attr_accessor :konbini
# Korean cards let users pay using locally issued cards from South Korea.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::KrCard)) }
attr_accessor :kr_card
# [Link](https://stripe.com/docs/payments/link) is a payment method network. With Link, users save their payment details once, then reuse that information to pay with one click for any business on the network.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Link)) }
attr_accessor :link
# MobilePay is a [single-use](https://stripe.com/docs/payments/payment-methods#usage) card wallet payment method used in Denmark and Finland. It allows customers to [authenticate and approve](https://stripe.com/docs/payments/payment-methods#customer-actions) payments using the MobilePay app. Check this [page](https://stripe.com/docs/payments/mobilepay) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Mobilepay)) }
attr_accessor :mobilepay
# Stripe users in Europe and the United States can accept Multibanco payments from customers in Portugal using [Sources](https://stripe.com/docs/sources)—a single integration path for creating payments using any supported method.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Multibanco)) }
attr_accessor :multibanco
# Configuration name.
sig { returns(T.nilable(String)) }
attr_accessor :name
# Naver Pay is a popular local wallet available in South Korea.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::NaverPay)) }
attr_accessor :naver_pay
# Stripe users in New Zealand can accept Bulk Electronic Clearing System (BECS) direct debit payments from customers with a New Zeland bank account. Check this [page](https://stripe.com/docs/payments/nz-bank-account) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::NzBankAccount)) }
attr_accessor :nz_bank_account
# OXXO is a Mexican chain of convenience stores with thousands of locations across Latin America and represents nearly 20% of online transactions in Mexico. OXXO allows customers to pay bills and online purchases in-store with cash. Check this [page](https://stripe.com/docs/payments/oxxo) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Oxxo)) }
attr_accessor :oxxo
# Przelewy24 is a Poland-based payment method aggregator that allows customers to complete transactions online using bank transfers and other methods. Bank transfers account for 30% of online payments in Poland and Przelewy24 provides a way for customers to pay with over 165 banks. Check this [page](https://stripe.com/docs/payments/p24) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::P24)) }
attr_accessor :p24
# Pay by bank is a redirect payment method backed by bank transfers. A customer is redirected to their bank to authorize a bank transfer for a given amount. This removes a lot of the error risks inherent in waiting for the customer to initiate a transfer themselves, and is less expensive than card payments.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::PayByBank)) }
attr_accessor :pay_by_bank
# PAYCO is a [single-use](https://docs.stripe.com/payments/payment-methods#usage local wallet available in South Korea.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Payco)) }
attr_accessor :payco
# PayNow is a Singapore-based payment method that allows customers to make a payment using their preferred app from participating banks and participating non-bank financial institutions. Check this [page](https://stripe.com/docs/payments/paynow) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Paynow)) }
attr_accessor :paynow
# PayPal, a digital wallet popular with customers in Europe, allows your customers worldwide to pay using their PayPal account. Check this [page](https://stripe.com/docs/payments/paypal) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Paypal)) }
attr_accessor :paypal
# PayTo is a [real-time](https://docs.stripe.com/payments/real-time) payment method that enables customers in Australia to pay by providing their bank account details. Customers must accept a mandate authorizing you to debit their account. Check this [page](https://docs.stripe.com/payments/payto) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Payto)) }
attr_accessor :payto
# Pix is a payment method popular in Brazil. When paying with Pix, customers authenticate and approve payments by scanning a QR code in their preferred banking app. Check this [page](https://docs.stripe.com/payments/pix) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Pix)) }
attr_accessor :pix
# PromptPay is a Thailand-based payment method that allows customers to make a payment using their preferred app from participating banks. Check this [page](https://stripe.com/docs/payments/promptpay) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Promptpay)) }
attr_accessor :promptpay
# QRIS is a [real-time](https://docs.stripe.com/payments/real-time) payment method popular in Indonesia. When paying with QRIS, customers authenticate and approve payments by scanning a QR code in their preferred digital wallet app.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Qris)) }
attr_accessor :qris
# Revolut Pay, developed by Revolut, a global finance app, is a digital wallet payment method. Revolut Pay uses the customer’s stored balance or cards to fund the payment, and offers the option for non-Revolut customers to save their details after their first purchase.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::RevolutPay)) }
attr_accessor :revolut_pay
# Samsung Pay is a [single-use](https://docs.stripe.com/payments/payment-methods#usage local wallet available in South Korea.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::SamsungPay)) }
attr_accessor :samsung_pay
# Satispay is a [single-use](https://docs.stripe.com/payments/payment-methods#usage) payment method where customers are required to [authenticate](/payments/payment-methods#customer-actions) their payment. Customers pay by being redirected from your website or app, authorizing the payment with Satispay, then returning to your website or app. You get [immediate notification](/payments/payment-methods#payment-notification) of whether the payment succeeded or failed.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Satispay)) }
attr_accessor :satispay
# The [Single Euro Payments Area (SEPA)](https://en.wikipedia.org/wiki/Single_Euro_Payments_Area) is an initiative of the European Union to simplify payments within and across member countries. SEPA established and enforced banking standards to allow for the direct debiting of every EUR-denominated bank account within the SEPA region, check this [page](https://stripe.com/docs/payments/sepa-debit) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::SepaDebit)) }
attr_accessor :sepa_debit
# ShopeePay is a [single use](https://stripe.com/docs/payments/payment-methods#usage) digital wallet payment method popular in Indonesia. When paying with GoPay, customers authenticate and approve payments using the Shopee app. Desktop checkout is performed by scanning a QR code. When checking out on mobile, customers are redirected to the Shopee app to confirm payment.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Shopeepay)) }
attr_accessor :shopeepay
# Stripe users in Europe and the United States can use the [Payment Intents API](https://stripe.com/docs/payments/payment-intents)—a single integration path for creating payments using any supported method—to accept [Sofort](https://www.sofort.com/) payments from customers. Check this [page](https://stripe.com/docs/payments/sofort) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Sofort)) }
attr_accessor :sofort
# Swish is a [real-time](https://stripe.com/docs/payments/real-time) payment method popular in Sweden. It allows customers to [authenticate and approve](https://stripe.com/docs/payments/payment-methods#customer-actions) payments using the Swish mobile app and the Swedish BankID mobile app. Check this [page](https://stripe.com/docs/payments/swish) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Swish)) }
attr_accessor :swish
# Twint is a payment method popular in Switzerland. It allows customers to pay using their mobile phone. Check this [page](https://docs.stripe.com/payments/twint) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Twint)) }
attr_accessor :twint
# Stripe users in the United States can accept ACH direct debit payments from customers with a US bank account using the Automated Clearing House (ACH) payments system operated by Nacha. Check this [page](https://stripe.com/docs/payments/ach-direct-debit) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::UsBankAccount)) }
attr_accessor :us_bank_account
# WeChat, owned by Tencent, is China's leading mobile app with over 1 billion monthly active users. Chinese consumers can use WeChat Pay to pay for goods and services inside of businesses' apps and websites. WeChat Pay users buy most frequently in gaming, e-commerce, travel, online education, and food/nutrition. Check this [page](https://stripe.com/docs/payments/wechat-pay) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::WechatPay)) }
attr_accessor :wechat_pay
# Zip gives your customers a way to split purchases over a series of payments. Check this [page](https://stripe.com/docs/payments/zip) for more details like country availability.
sig { returns(T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Zip)) }
attr_accessor :zip
sig {
params(acss_debit: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::AcssDebit), active: T.nilable(T::Boolean), affirm: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Affirm), afterpay_clearpay: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::AfterpayClearpay), alipay: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Alipay), alma: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Alma), amazon_pay: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::AmazonPay), apple_pay: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::ApplePay), apple_pay_later: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::ApplePayLater), au_becs_debit: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::AuBecsDebit), bacs_debit: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::BacsDebit), bancontact: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Bancontact), billie: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Billie), blik: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Blik), boleto: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Boleto), card: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Card), cartes_bancaires: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::CartesBancaires), cashapp: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Cashapp), customer_balance: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::CustomerBalance), eps: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Eps), expand: T.nilable(T::Array[String]), fpx: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Fpx), giropay: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Giropay), google_pay: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::GooglePay), gopay: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Gopay), grabpay: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Grabpay), id_bank_transfer: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::IdBankTransfer), ideal: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Ideal), jcb: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Jcb), kakao_pay: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::KakaoPay), klarna: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Klarna), konbini: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Konbini), kr_card: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::KrCard), link: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Link), mobilepay: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Mobilepay), multibanco: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Multibanco), name: T.nilable(String), naver_pay: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::NaverPay), nz_bank_account: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::NzBankAccount), oxxo: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Oxxo), p24: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::P24), pay_by_bank: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::PayByBank), payco: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Payco), paynow: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Paynow), paypal: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Paypal), payto: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Payto), pix: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Pix), promptpay: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Promptpay), qris: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Qris), revolut_pay: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::RevolutPay), samsung_pay: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::SamsungPay), satispay: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Satispay), sepa_debit: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::SepaDebit), shopeepay: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Shopeepay), sofort: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Sofort), swish: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Swish), twint: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Twint), us_bank_account: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::UsBankAccount), wechat_pay: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::WechatPay), zip: T.nilable(::Stripe::PaymentMethodConfiguration::UpdateParams::Zip)).void
}
def initialize(
acss_debit: nil,
active: nil,
affirm: nil,
afterpay_clearpay: nil,
alipay: nil,
alma: nil,
amazon_pay: nil,
apple_pay: nil,
apple_pay_later: nil,
au_becs_debit: nil,
bacs_debit: nil,
bancontact: nil,
billie: nil,
blik: nil,
boleto: nil,
card: nil,
cartes_bancaires: nil,
cashapp: nil,
customer_balance: nil,
eps: nil,
expand: nil,
fpx: nil,
giropay: nil,
google_pay: nil,
gopay: nil,
grabpay: nil,
id_bank_transfer: nil,
ideal: nil,
jcb: nil,
kakao_pay: nil,
klarna: nil,
konbini: nil,
kr_card: nil,
link: nil,
mobilepay: nil,
multibanco: nil,
name: nil,
naver_pay: nil,
nz_bank_account: nil,
oxxo: nil,
p24: nil,
pay_by_bank: nil,
payco: nil,
paynow: nil,
paypal: nil,
payto: nil,
pix: nil,
promptpay: nil,
qris: nil,
revolut_pay: nil,
samsung_pay: nil,
satispay: nil,
sepa_debit: nil,
shopeepay: nil,
sofort: nil,
swish: nil,
twint: nil,
us_bank_account: nil,
wechat_pay: nil,
zip: nil
); end
end
# Creates a payment method configuration
sig {
params(params: T.any(::Stripe::PaymentMethodConfiguration::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentMethodConfiguration)
}
def self.create(params = {}, opts = {}); end
# List payment method configurations
sig {
params(params: T.any(::Stripe::PaymentMethodConfiguration::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Update payment method configuration
sig {
params(configuration: String, params: T.any(::Stripe::PaymentMethodConfiguration::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentMethodConfiguration)
}
def self.update(configuration, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
# A payment method domain represents a web domain that you have registered with Stripe.
# Stripe Elements use registered payment method domains to control where certain payment methods are shown.
#
# Related guide: [Payment method domains](https://stripe.com/docs/payments/payment-methods/pmd-registration).
class PaymentMethodDomain < APIResource
class AmazonPay < Stripe::StripeObject
class StatusDetails < Stripe::StripeObject
# The error message associated with the status of the payment method on the domain.
sig { returns(String) }
attr_reader :error_message
end
# The status of the payment method on the domain.
sig { returns(String) }
attr_reader :status
# Contains additional details about the status of a payment method for a specific payment method domain.
sig { returns(StatusDetails) }
attr_reader :status_details
end
class ApplePay < Stripe::StripeObject
class StatusDetails < Stripe::StripeObject
# The error message associated with the status of the payment method on the domain.
sig { returns(String) }
attr_reader :error_message
end
# The status of the payment method on the domain.
sig { returns(String) }
attr_reader :status
# Contains additional details about the status of a payment method for a specific payment method domain.
sig { returns(StatusDetails) }
attr_reader :status_details
end
class GooglePay < Stripe::StripeObject
class StatusDetails < Stripe::StripeObject
# The error message associated with the status of the payment method on the domain.
sig { returns(String) }
attr_reader :error_message
end
# The status of the payment method on the domain.
sig { returns(String) }
attr_reader :status
# Contains additional details about the status of a payment method for a specific payment method domain.
sig { returns(StatusDetails) }
attr_reader :status_details
end
class Klarna < Stripe::StripeObject
class StatusDetails < Stripe::StripeObject
# The error message associated with the status of the payment method on the domain.
sig { returns(String) }
attr_reader :error_message
end
# The status of the payment method on the domain.
sig { returns(String) }
attr_reader :status
# Contains additional details about the status of a payment method for a specific payment method domain.
sig { returns(StatusDetails) }
attr_reader :status_details
end
class Link < Stripe::StripeObject
class StatusDetails < Stripe::StripeObject
# The error message associated with the status of the payment method on the domain.
sig { returns(String) }
attr_reader :error_message
end
# The status of the payment method on the domain.
sig { returns(String) }
attr_reader :status
# Contains additional details about the status of a payment method for a specific payment method domain.
sig { returns(StatusDetails) }
attr_reader :status_details
end
class Paypal < Stripe::StripeObject
class StatusDetails < Stripe::StripeObject
# The error message associated with the status of the payment method on the domain.
sig { returns(String) }
attr_reader :error_message
end
# The status of the payment method on the domain.
sig { returns(String) }
attr_reader :status
# Contains additional details about the status of a payment method for a specific payment method domain.
sig { returns(StatusDetails) }
attr_reader :status_details
end
# Indicates the status of a specific payment method on a payment method domain.
sig { returns(AmazonPay) }
attr_reader :amazon_pay
# Indicates the status of a specific payment method on a payment method domain.
sig { returns(ApplePay) }
attr_reader :apple_pay
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# The domain name that this payment method domain object represents.
sig { returns(String) }
attr_reader :domain_name
# Whether this payment method domain is enabled. If the domain is not enabled, payment methods that require a payment method domain will not appear in Elements.
sig { returns(T::Boolean) }
attr_reader :enabled
# Indicates the status of a specific payment method on a payment method domain.
sig { returns(GooglePay) }
attr_reader :google_pay
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Indicates the status of a specific payment method on a payment method domain.
sig { returns(Klarna) }
attr_reader :klarna
# Indicates the status of a specific payment method on a payment method domain.
sig { returns(Link) }
attr_reader :link
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Indicates the status of a specific payment method on a payment method domain.
sig { returns(Paypal) }
attr_reader :paypal
class ListParams < Stripe::RequestParams
# The domain name that this payment method domain object represents.
sig { returns(T.nilable(String)) }
attr_accessor :domain_name
# Whether this payment method domain is enabled. If the domain is not enabled, payment methods will not appear in Elements or Embedded Checkout
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :enabled
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(domain_name: T.nilable(String), enabled: T.nilable(T::Boolean), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
domain_name: nil,
enabled: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
# The domain name that this payment method domain object represents.
sig { returns(String) }
attr_accessor :domain_name
# Whether this payment method domain is enabled. If the domain is not enabled, payment methods that require a payment method domain will not appear in Elements or Embedded Checkout.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :enabled
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig {
params(domain_name: String, enabled: T.nilable(T::Boolean), expand: T.nilable(T::Array[String])).void
}
def initialize(domain_name: nil, enabled: nil, expand: nil); end
end
class UpdateParams < Stripe::RequestParams
# Whether this payment method domain is enabled. If the domain is not enabled, payment methods that require a payment method domain will not appear in Elements or Embedded Checkout.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :enabled
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(enabled: T.nilable(T::Boolean), expand: T.nilable(T::Array[String])).void }
def initialize(enabled: nil, expand: nil); end
end
class ValidateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Creates a payment method domain.
sig {
params(params: T.any(::Stripe::PaymentMethodDomain::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentMethodDomain)
}
def self.create(params = {}, opts = {}); end
# Lists the details of existing payment method domains.
sig {
params(params: T.any(::Stripe::PaymentMethodDomain::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Updates an existing payment method domain.
sig {
params(payment_method_domain: String, params: T.any(::Stripe::PaymentMethodDomain::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentMethodDomain)
}
def self.update(payment_method_domain, params = {}, opts = {}); end
# Some payment methods might require additional steps to register a domain. If the requirements weren't satisfied when the domain was created, the payment method will be inactive on the domain.
# The payment method doesn't appear in Elements or Embedded Checkout for this domain until it is active.
#
# To activate a payment method on an existing payment method domain, complete the required registration steps specific to the payment method, and then validate the payment method domain with this endpoint.
#
# Related guides: [Payment method domains](https://docs.stripe.com/docs/payments/payment-methods/pmd-registration).
sig {
params(params: T.any(::Stripe::PaymentMethodDomain::ValidateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentMethodDomain)
}
def validate(params = {}, opts = {}); end
# Some payment methods might require additional steps to register a domain. If the requirements weren't satisfied when the domain was created, the payment method will be inactive on the domain.
# The payment method doesn't appear in Elements or Embedded Checkout for this domain until it is active.
#
# To activate a payment method on an existing payment method domain, complete the required registration steps specific to the payment method, and then validate the payment method domain with this endpoint.
#
# Related guides: [Payment method domains](https://docs.stripe.com/docs/payments/payment-methods/pmd-registration).
sig {
params(payment_method_domain: String, params: T.any(::Stripe::PaymentMethodDomain::ValidateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentMethodDomain)
}
def self.validate(payment_method_domain, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
# A Payment Record is a resource that allows you to represent payments that occur on- or off-Stripe.
# For example, you can create a Payment Record to model a payment made on a different payment processor,
# in order to mark an Invoice as paid and a Subscription as active. Payment Records consist of one or
# more Payment Attempt Records, which represent individual attempts made on a payment network.
class PaymentRecord < APIResource
class AmountCanceled < Stripe::StripeObject
# 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).
sig { returns(String) }
attr_reader :currency
# A positive integer representing the amount in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) for example, 100 cents for 1 USD or 100 for 100 JPY, a zero-decimal currency.
sig { returns(Integer) }
attr_reader :value
end
class AmountFailed < Stripe::StripeObject
# 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).
sig { returns(String) }
attr_reader :currency
# A positive integer representing the amount in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) for example, 100 cents for 1 USD or 100 for 100 JPY, a zero-decimal currency.
sig { returns(Integer) }
attr_reader :value
end
class AmountGuaranteed < Stripe::StripeObject
# 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).
sig { returns(String) }
attr_reader :currency
# A positive integer representing the amount in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) for example, 100 cents for 1 USD or 100 for 100 JPY, a zero-decimal currency.
sig { returns(Integer) }
attr_reader :value
end
class AmountRequested < Stripe::StripeObject
# 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).
sig { returns(String) }
attr_reader :currency
# A positive integer representing the amount in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) for example, 100 cents for 1 USD or 100 for 100 JPY, a zero-decimal currency.
sig { returns(Integer) }
attr_reader :value
end
class CustomerDetails < Stripe::StripeObject
# ID of the Stripe Customer associated with this payment.
sig { returns(T.nilable(String)) }
attr_reader :customer
# The customer's email address.
sig { returns(T.nilable(String)) }
attr_reader :email
# The customer's name.
sig { returns(T.nilable(String)) }
attr_reader :name
# The customer's phone number.
sig { returns(T.nilable(String)) }
attr_reader :phone
end
class PaymentMethodDetails < Stripe::StripeObject
class AchCreditTransfer < Stripe::StripeObject
# Account number to transfer funds to.
sig { returns(T.nilable(String)) }
attr_reader :account_number
# Name of the bank associated with the routing number.
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# Routing transit number for the bank account to transfer funds to.
sig { returns(T.nilable(String)) }
attr_reader :routing_number
# SWIFT code of the bank associated with the routing number.
sig { returns(T.nilable(String)) }
attr_reader :swift_code
end
class AchDebit < Stripe::StripeObject
# Type of entity that holds the account. This can be either `individual` or `company`.
sig { returns(T.nilable(String)) }
attr_reader :account_holder_type
# Name of the bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# Two-letter ISO code representing the country the bank account is located in.
sig { returns(T.nilable(String)) }
attr_reader :country
# Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Last four digits of the bank account number.
sig { returns(T.nilable(String)) }
attr_reader :last4
# Routing transit number of the bank account.
sig { returns(T.nilable(String)) }
attr_reader :routing_number
end
class AcssDebit < Stripe::StripeObject
# Name of the bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Institution number of the bank account
sig { returns(T.nilable(String)) }
attr_reader :institution_number
# Last four digits of the bank account number.
sig { returns(T.nilable(String)) }
attr_reader :last4
# ID of the mandate used to make this payment.
sig { returns(String) }
attr_reader :mandate
# Transit number of the bank account.
sig { returns(T.nilable(String)) }
attr_reader :transit_number
end
class Affirm < Stripe::StripeObject
# ID of the [location](https://stripe.com/docs/api/terminal/locations) that this transaction's reader is assigned to.
sig { returns(String) }
attr_reader :location
# ID of the [reader](https://stripe.com/docs/api/terminal/readers) this transaction was made on.
sig { returns(String) }
attr_reader :reader
# The Affirm transaction ID associated with this payment.
sig { returns(T.nilable(String)) }
attr_reader :transaction_id
end
class AfterpayClearpay < Stripe::StripeObject
# The Afterpay order ID associated with this payment intent.
sig { returns(T.nilable(String)) }
attr_reader :order_id
# Order identifier shown to the merchant in Afterpay’s online portal.
sig { returns(T.nilable(String)) }
attr_reader :reference
end
class Alipay < Stripe::StripeObject
# Uniquely identifies this particular Alipay account. You can use this attribute to check whether two Alipay accounts are the same.
sig { returns(String) }
attr_reader :buyer_id
# Uniquely identifies this particular Alipay account. You can use this attribute to check whether two Alipay accounts are the same.
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Transaction ID of this particular Alipay transaction.
sig { returns(T.nilable(String)) }
attr_reader :transaction_id
end
class Alma < Stripe::StripeObject; end
class AmazonPay < Stripe::StripeObject
class Funding < Stripe::StripeObject
class Card < Stripe::StripeObject
# Card brand. Can be `amex`, `diners`, `discover`, `eftpos_au`, `jcb`, `link`, `mastercard`, `unionpay`, `visa`, or `unknown`.
sig { returns(T.nilable(String)) }
attr_reader :brand
# The [product code](https://stripe.com/docs/card-product-codes) that identifies the specific program or product associated with a card. (For internal use only and not typically available in standard API requests.)
sig { returns(T.nilable(String)) }
attr_reader :brand_product
# 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.
sig { returns(T.nilable(String)) }
attr_reader :country
# Two-digit number representing the card's expiration month.
sig { returns(T.nilable(Integer)) }
attr_reader :exp_month
# Four-digit number representing the card's expiration year.
sig { returns(T.nilable(Integer)) }
attr_reader :exp_year
# Card funding type. Can be `credit`, `debit`, `prepaid`, or `unknown`.
sig { returns(T.nilable(String)) }
attr_reader :funding
# The last four digits of the card.
sig { returns(T.nilable(String)) }
attr_reader :last4
end
# Attribute for field card
sig { returns(Card) }
attr_reader :card
# funding type of the underlying payment method.
sig { returns(T.nilable(String)) }
attr_reader :type
end
# Attribute for field funding
sig { returns(Funding) }
attr_reader :funding
end
class AuBecsDebit < Stripe::StripeObject
# Bank-State-Branch number of the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bsb_number
# Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Last four digits of the bank account number.
sig { returns(T.nilable(String)) }
attr_reader :last4
# ID of the mandate used to make this payment.
sig { returns(String) }
attr_reader :mandate
end
class BacsDebit < Stripe::StripeObject
# Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Last four digits of the bank account number.
sig { returns(T.nilable(String)) }
attr_reader :last4
# ID of the mandate used to make this payment.
sig { returns(T.nilable(String)) }
attr_reader :mandate
# Sort code of the bank account. (e.g., `10-20-30`)
sig { returns(T.nilable(String)) }
attr_reader :sort_code
end
class Bancontact < Stripe::StripeObject
# Bank code of bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_code
# Name of the bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# Bank Identifier Code of the bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bic
# The ID of the SEPA Direct Debit PaymentMethod which was generated by this Charge.
sig { returns(T.nilable(T.any(String, Stripe::PaymentMethod))) }
attr_reader :generated_sepa_debit
# The mandate for the SEPA Direct Debit PaymentMethod which was generated by this Charge.
sig { returns(T.nilable(T.any(String, Stripe::Mandate))) }
attr_reader :generated_sepa_debit_mandate
# Last four characters of the IBAN.
sig { returns(T.nilable(String)) }
attr_reader :iban_last4
# Preferred language of the Bancontact authorization page that the customer is redirected to.
# Can be one of `en`, `de`, `fr`, or `nl`
sig { returns(T.nilable(String)) }
attr_reader :preferred_language
# Owner's verified full name. Values are verified or provided by Bancontact directly
# (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(String)) }
attr_reader :verified_name
end
class Billie < Stripe::StripeObject; end
class BillingDetails < Stripe::StripeObject
class Address < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# A representation of a physical address.
sig { returns(Address) }
attr_reader :address
# The billing email associated with the method of payment.
sig { returns(T.nilable(String)) }
attr_reader :email
# The billing name associated with the method of payment.
sig { returns(T.nilable(String)) }
attr_reader :name
# The billing phone number associated with the method of payment.
sig { returns(T.nilable(String)) }
attr_reader :phone
end
class Blik < Stripe::StripeObject
# A unique and immutable identifier assigned by BLIK to every buyer.
sig { returns(T.nilable(String)) }
attr_reader :buyer_id
end
class Boleto < Stripe::StripeObject
# The tax ID of the customer (CPF for individuals consumers or CNPJ for businesses consumers)
sig { returns(String) }
attr_reader :tax_id
end
class Card < Stripe::StripeObject
class Checks < Stripe::StripeObject
# Attribute for field address_line1_check
sig { returns(T.nilable(String)) }
attr_reader :address_line1_check
# Attribute for field address_postal_code_check
sig { returns(T.nilable(String)) }
attr_reader :address_postal_code_check
# Attribute for field cvc_check
sig { returns(T.nilable(String)) }
attr_reader :cvc_check
end
class NetworkToken < Stripe::StripeObject
# Attribute for field used
sig { returns(T::Boolean) }
attr_reader :used
end
class ThreeDSecure < Stripe::StripeObject
# Attribute for field authentication_flow
sig { returns(T.nilable(String)) }
attr_reader :authentication_flow
# Attribute for field result
sig { returns(T.nilable(String)) }
attr_reader :result
# Attribute for field result_reason
sig { returns(T.nilable(String)) }
attr_reader :result_reason
# Attribute for field version
sig { returns(T.nilable(String)) }
attr_reader :version
end
# Card brand. Can be `amex`, `diners`, `discover`, `eftpos_au`, `jcb`, `link`, `mastercard`, `unionpay`, `visa`, or `unknown`.
sig { returns(String) }
attr_reader :brand
# When using manual capture, a future timestamp at which the charge will be automatically refunded if uncaptured.
sig { returns(Integer) }
attr_reader :capture_before
# Check results by Card networks on Card address and CVC at time of payment.
sig { returns(T.nilable(Checks)) }
attr_reader :checks
# 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.
sig { returns(T.nilable(String)) }
attr_reader :country
# Two-digit number representing the card's expiration month.
sig { returns(Integer) }
attr_reader :exp_month
# Four-digit number representing the card's expiration year.
sig { returns(Integer) }
attr_reader :exp_year
# Uniquely identifies this particular card number. You can use this attribute to check whether two customers who’ve signed up with you are using the same card number, for example. For payment methods that tokenize card information (Apple Pay, Google Pay), the tokenized number might be provided instead of the underlying card number.
#
# *As of May 1, 2021, card fingerprint in India for Connect changed to allow two fingerprints for the same card---one for India and one for the rest of the world.*
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Card funding type. Can be `credit`, `debit`, `prepaid`, or `unknown`.
sig { returns(String) }
attr_reader :funding
# The last four digits of the card.
sig { returns(String) }
attr_reader :last4
# True if this payment was marked as MOTO and out of scope for SCA.
sig { returns(T::Boolean) }
attr_reader :moto
# Identifies which network this charge was processed on. Can be `amex`, `cartes_bancaires`, `diners`, `discover`, `eftpos_au`, `interac`, `jcb`, `link`, `mastercard`, `unionpay`, `visa`, or `unknown`.
sig { returns(T.nilable(String)) }
attr_reader :network
# If this card has network token credentials, this contains the details of the network token credentials.
sig { returns(T.nilable(NetworkToken)) }
attr_reader :network_token
# This is used by the financial networks to identify a transaction. Visa calls this the Transaction ID, Mastercard calls this the Trace ID, and American Express calls this the Acquirer Reference Data. This value will be present if it is returned by the financial network in the authorization response, and null otherwise.
sig { returns(T.nilable(String)) }
attr_reader :network_transaction_id
# Populated if this transaction used 3D Secure authentication.
sig { returns(T.nilable(ThreeDSecure)) }
attr_reader :three_d_secure
end
class CardPresent < Stripe::StripeObject
class Offline < Stripe::StripeObject
# Time at which the payment was collected while offline
sig { returns(T.nilable(Integer)) }
attr_reader :stored_at
# The method used to process this payment method offline. Only deferred is allowed.
sig { returns(T.nilable(String)) }
attr_reader :type
end
class Receipt < Stripe::StripeObject
# The type of account being debited or credited
sig { returns(String) }
attr_reader :account_type
# EMV tag 9F26, cryptogram generated by the integrated circuit chip.
sig { returns(T.nilable(String)) }
attr_reader :application_cryptogram
# Mnenomic of the Application Identifier.
sig { returns(T.nilable(String)) }
attr_reader :application_preferred_name
# Identifier for this transaction.
sig { returns(T.nilable(String)) }
attr_reader :authorization_code
# EMV tag 8A. A code returned by the card issuer.
sig { returns(T.nilable(String)) }
attr_reader :authorization_response_code
# Describes the method used by the cardholder to verify ownership of the card. One of the following: `approval`, `failure`, `none`, `offline_pin`, `offline_pin_and_signature`, `online_pin`, or `signature`.
sig { returns(T.nilable(String)) }
attr_reader :cardholder_verification_method
# EMV tag 84. Similar to the application identifier stored on the integrated circuit chip.
sig { returns(T.nilable(String)) }
attr_reader :dedicated_file_name
# The outcome of a series of EMV functions performed by the card reader.
sig { returns(T.nilable(String)) }
attr_reader :terminal_verification_results
# An indication of various EMV functions performed during the transaction.
sig { returns(T.nilable(String)) }
attr_reader :transaction_status_information
end
class Wallet < Stripe::StripeObject
# The type of mobile wallet, one of `apple_pay`, `google_pay`, `samsung_pay`, or `unknown`.
sig { returns(String) }
attr_reader :type
end
# The authorized amount
sig { returns(T.nilable(Integer)) }
attr_reader :amount_authorized
# Card brand. Can be `amex`, `diners`, `discover`, `eftpos_au`, `jcb`, `link`, `mastercard`, `unionpay`, `visa`, or `unknown`.
sig { returns(T.nilable(String)) }
attr_reader :brand
# The [product code](https://stripe.com/docs/card-product-codes) that identifies the specific program or product associated with a card.
sig { returns(T.nilable(String)) }
attr_reader :brand_product
# When using manual capture, a future timestamp after which the charge will be automatically refunded if uncaptured.
sig { returns(Integer) }
attr_reader :capture_before
# The cardholder name as read from the card, in [ISO 7813](https://en.wikipedia.org/wiki/ISO/IEC_7813) format. May include alphanumeric characters, special characters and first/last name separator (`/`). In some cases, the cardholder name may not be available depending on how the issuer has configured the card. Cardholder name is typically not available on swipe or contactless payments, such as those made with Apple Pay and Google Pay.
sig { returns(T.nilable(String)) }
attr_reader :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.
sig { returns(T.nilable(String)) }
attr_reader :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.)
sig { returns(T.nilable(String)) }
attr_reader :description
# Authorization response cryptogram.
sig { returns(T.nilable(String)) }
attr_reader :emv_auth_data
# Two-digit number representing the card's expiration month.
sig { returns(Integer) }
attr_reader :exp_month
# Four-digit number representing the card's expiration year.
sig { returns(Integer) }
attr_reader :exp_year
# Uniquely identifies this particular card number. You can use this attribute to check whether two customers who’ve signed up with you are using the same card number, for example. For payment methods that tokenize card information (Apple Pay, Google Pay), the tokenized number might be provided instead of the underlying card number.
#
# *As of May 1, 2021, card fingerprint in India for Connect changed to allow two fingerprints for the same card---one for India and one for the rest of the world.*
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Card funding type. Can be `credit`, `debit`, `prepaid`, or `unknown`.
sig { returns(T.nilable(String)) }
attr_reader :funding
# ID of a card PaymentMethod generated from the card_present PaymentMethod that may be attached to a Customer for future transactions. Only present if it was possible to generate a card PaymentMethod.
sig { returns(T.nilable(String)) }
attr_reader :generated_card
# Issuer identification number of the card. (For internal use only and not typically available in standard API requests.)
sig { returns(T.nilable(String)) }
attr_reader :iin
# Whether this [PaymentIntent](https://stripe.com/docs/api/payment_intents) is eligible for incremental authorizations. Request support using [request_incremental_authorization_support](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-payment_method_options-card_present-request_incremental_authorization_support).
sig { returns(T::Boolean) }
attr_reader :incremental_authorization_supported
# The name of the card's issuing bank. (For internal use only and not typically available in standard API requests.)
sig { returns(T.nilable(String)) }
attr_reader :issuer
# The last four digits of the card.
sig { returns(T.nilable(String)) }
attr_reader :last4
# Identifies which network this charge was processed on. Can be `amex`, `cartes_bancaires`, `diners`, `discover`, `eftpos_au`, `interac`, `jcb`, `link`, `mastercard`, `unionpay`, `visa`, or `unknown`.
sig { returns(T.nilable(String)) }
attr_reader :network
# This is used by the financial networks to identify a transaction. Visa calls this the Transaction ID, Mastercard calls this the Trace ID, and American Express calls this the Acquirer Reference Data. This value will be present if it is returned by the financial network in the authorization response, and null otherwise.
sig { returns(T.nilable(String)) }
attr_reader :network_transaction_id
# Details about payments collected offline.
sig { returns(T.nilable(Offline)) }
attr_reader :offline
# Defines whether the authorized amount can be over-captured or not
sig { returns(T::Boolean) }
attr_reader :overcapture_supported
# EMV tag 5F2D. Preferred languages specified by the integrated circuit chip.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :preferred_locales
# How card details were read in this transaction.
sig { returns(T.nilable(String)) }
attr_reader :read_method
# A collection of fields required to be displayed on receipts. Only required for EMV transactions.
sig { returns(T.nilable(Receipt)) }
attr_reader :receipt
# Attribute for field wallet
sig { returns(Wallet) }
attr_reader :wallet
end
class Cashapp < Stripe::StripeObject
# A unique and immutable identifier assigned by Cash App to every buyer.
sig { returns(T.nilable(String)) }
attr_reader :buyer_id
# A public identifier for buyers using Cash App.
sig { returns(T.nilable(String)) }
attr_reader :cashtag
end
class Custom < Stripe::StripeObject
# Display name for the custom (user-defined) payment method type used to make this payment.
sig { returns(String) }
attr_reader :display_name
# The custom payment method type associated with this payment.
sig { returns(T.nilable(String)) }
attr_reader :type
end
class CustomerBalance < Stripe::StripeObject; end
class Eps < Stripe::StripeObject
# The customer's bank. Should be one of `arzte_und_apotheker_bank`, `austrian_anadi_bank_ag`, `bank_austria`, `bankhaus_carl_spangler`, `bankhaus_schelhammer_und_schattera_ag`, `bawag_psk_ag`, `bks_bank_ag`, `brull_kallmus_bank_ag`, `btv_vier_lander_bank`, `capital_bank_grawe_gruppe_ag`, `deutsche_bank_ag`, `dolomitenbank`, `easybank_ag`, `erste_bank_und_sparkassen`, `hypo_alpeadriabank_international_ag`, `hypo_noe_lb_fur_niederosterreich_u_wien`, `hypo_oberosterreich_salzburg_steiermark`, `hypo_tirol_bank_ag`, `hypo_vorarlberg_bank_ag`, `hypo_bank_burgenland_aktiengesellschaft`, `marchfelder_bank`, `oberbank_ag`, `raiffeisen_bankengruppe_osterreich`, `schoellerbank_ag`, `sparda_bank_wien`, `volksbank_gruppe`, `volkskreditbank_ag`, or `vr_bank_braunau`.
sig { returns(T.nilable(String)) }
attr_reader :bank
# Owner's verified full name. Values are verified or provided by EPS directly
# (if supported) at the time of authorization or settlement. They cannot be set or mutated.
# EPS rarely provides this information so the attribute is usually empty.
sig { returns(T.nilable(String)) }
attr_reader :verified_name
end
class Fpx < Stripe::StripeObject
# Account holder type, if provided. Can be one of `individual` or `company`.
sig { returns(T.nilable(String)) }
attr_reader :account_holder_type
# The customer's bank. Can be one of `affin_bank`, `agrobank`, `alliance_bank`, `ambank`, `bank_islam`, `bank_muamalat`, `bank_rakyat`, `bsn`, `cimb`, `hong_leong_bank`, `hsbc`, `kfh`, `maybank2u`, `ocbc`, `public_bank`, `rhb`, `standard_chartered`, `uob`, `deutsche_bank`, `maybank2e`, `pb_enterprise`, or `bank_of_china`.
sig { returns(String) }
attr_reader :bank
# Unique transaction id generated by FPX for every request from the merchant
sig { returns(T.nilable(String)) }
attr_reader :transaction_id
end
class Giropay < Stripe::StripeObject
# Bank code of bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_code
# Name of the bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# Bank Identifier Code of the bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bic
# Owner's verified full name. Values are verified or provided by Giropay directly
# (if supported) at the time of authorization or settlement. They cannot be set or mutated.
# Giropay rarely provides this information so the attribute is usually empty.
sig { returns(T.nilable(String)) }
attr_reader :verified_name
end
class Gopay < Stripe::StripeObject; end
class Grabpay < Stripe::StripeObject
# Unique transaction id generated by GrabPay
sig { returns(T.nilable(String)) }
attr_reader :transaction_id
end
class IdBankTransfer < Stripe::StripeObject
# Account number of the bank account to transfer funds to.
sig { returns(String) }
attr_reader :account_number
# Bank where the account is located.
sig { returns(String) }
attr_reader :bank
# Local bank code of the bank.
sig { returns(String) }
attr_reader :bank_code
# Name of the bank associated with the bank account.
sig { returns(String) }
attr_reader :bank_name
# Merchant name and billing details name, for the customer to check for the correct merchant when performing the bank transfer.
sig { returns(String) }
attr_reader :display_name
end
class Ideal < Stripe::StripeObject
# The customer's bank. Can be one of `abn_amro`, `asn_bank`, `bunq`, `handelsbanken`, `ing`, `knab`, `moneyou`, `n26`, `nn`, `rabobank`, `regiobank`, `revolut`, `sns_bank`, `triodos_bank`, `van_lanschot`, or `yoursafe`.
sig { returns(T.nilable(String)) }
attr_reader :bank
# The Bank Identifier Code of the customer's bank.
sig { returns(T.nilable(String)) }
attr_reader :bic
# The ID of the SEPA Direct Debit PaymentMethod which was generated by this Charge.
sig { returns(T.nilable(T.any(String, Stripe::PaymentMethod))) }
attr_reader :generated_sepa_debit
# The mandate for the SEPA Direct Debit PaymentMethod which was generated by this Charge.
sig { returns(T.nilable(T.any(String, Stripe::Mandate))) }
attr_reader :generated_sepa_debit_mandate
# Last four characters of the IBAN.
sig { returns(T.nilable(String)) }
attr_reader :iban_last4
# Owner's verified full name. Values are verified or provided by iDEAL directly
# (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(String)) }
attr_reader :verified_name
end
class InteracPresent < Stripe::StripeObject
class Receipt < Stripe::StripeObject
# The type of account being debited or credited
sig { returns(String) }
attr_reader :account_type
# EMV tag 9F26, cryptogram generated by the integrated circuit chip.
sig { returns(T.nilable(String)) }
attr_reader :application_cryptogram
# Mnenomic of the Application Identifier.
sig { returns(T.nilable(String)) }
attr_reader :application_preferred_name
# Identifier for this transaction.
sig { returns(T.nilable(String)) }
attr_reader :authorization_code
# EMV tag 8A. A code returned by the card issuer.
sig { returns(T.nilable(String)) }
attr_reader :authorization_response_code
# Describes the method used by the cardholder to verify ownership of the card. One of the following: `approval`, `failure`, `none`, `offline_pin`, `offline_pin_and_signature`, `online_pin`, or `signature`.
sig { returns(T.nilable(String)) }
attr_reader :cardholder_verification_method
# EMV tag 84. Similar to the application identifier stored on the integrated circuit chip.
sig { returns(T.nilable(String)) }
attr_reader :dedicated_file_name
# The outcome of a series of EMV functions performed by the card reader.
sig { returns(T.nilable(String)) }
attr_reader :terminal_verification_results
# An indication of various EMV functions performed during the transaction.
sig { returns(T.nilable(String)) }
attr_reader :transaction_status_information
end
# Card brand. Can be `interac`, `mastercard` or `visa`.
sig { returns(T.nilable(String)) }
attr_reader :brand
# The cardholder name as read from the card, in [ISO 7813](https://en.wikipedia.org/wiki/ISO/IEC_7813) format. May include alphanumeric characters, special characters and first/last name separator (`/`). In some cases, the cardholder name may not be available depending on how the issuer has configured the card. Cardholder name is typically not available on swipe or contactless payments, such as those made with Apple Pay and Google Pay.
sig { returns(T.nilable(String)) }
attr_reader :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.
sig { returns(T.nilable(String)) }
attr_reader :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.)
sig { returns(T.nilable(String)) }
attr_reader :description
# Authorization response cryptogram.
sig { returns(T.nilable(String)) }
attr_reader :emv_auth_data
# Two-digit number representing the card's expiration month.
sig { returns(Integer) }
attr_reader :exp_month
# Four-digit number representing the card's expiration year.
sig { returns(Integer) }
attr_reader :exp_year
# Uniquely identifies this particular card number. You can use this attribute to check whether two customers who’ve signed up with you are using the same card number, for example. For payment methods that tokenize card information (Apple Pay, Google Pay), the tokenized number might be provided instead of the underlying card number.
#
# *As of May 1, 2021, card fingerprint in India for Connect changed to allow two fingerprints for the same card---one for India and one for the rest of the world.*
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Card funding type. Can be `credit`, `debit`, `prepaid`, or `unknown`.
sig { returns(T.nilable(String)) }
attr_reader :funding
# ID of a card PaymentMethod generated from the card_present PaymentMethod that may be attached to a Customer for future transactions. Only present if it was possible to generate a card PaymentMethod.
sig { returns(T.nilable(String)) }
attr_reader :generated_card
# Issuer identification number of the card. (For internal use only and not typically available in standard API requests.)
sig { returns(T.nilable(String)) }
attr_reader :iin
# The name of the card's issuing bank. (For internal use only and not typically available in standard API requests.)
sig { returns(T.nilable(String)) }
attr_reader :issuer
# The last four digits of the card.
sig { returns(T.nilable(String)) }
attr_reader :last4
# Identifies which network this charge was processed on. Can be `amex`, `cartes_bancaires`, `diners`, `discover`, `eftpos_au`, `interac`, `jcb`, `link`, `mastercard`, `unionpay`, `visa`, or `unknown`.
sig { returns(T.nilable(String)) }
attr_reader :network
# This is used by the financial networks to identify a transaction. Visa calls this the Transaction ID, Mastercard calls this the Trace ID, and American Express calls this the Acquirer Reference Data. This value will be present if it is returned by the financial network in the authorization response, and null otherwise.
sig { returns(T.nilable(String)) }
attr_reader :network_transaction_id
# EMV tag 5F2D. Preferred languages specified by the integrated circuit chip.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :preferred_locales
# How card details were read in this transaction.
sig { returns(T.nilable(String)) }
attr_reader :read_method
# A collection of fields required to be displayed on receipts. Only required for EMV transactions.
sig { returns(T.nilable(Receipt)) }
attr_reader :receipt
end
class KakaoPay < Stripe::StripeObject
# A unique identifier for the buyer as determined by the local payment processor.
sig { returns(T.nilable(String)) }
attr_reader :buyer_id
end
class Klarna < Stripe::StripeObject
class PayerDetails < Stripe::StripeObject
class Address < Stripe::StripeObject
# The payer address country
sig { returns(T.nilable(String)) }
attr_reader :country
end
# The payer's address
sig { returns(T.nilable(Address)) }
attr_reader :address
end
# The payer details for this transaction.
sig { returns(T.nilable(PayerDetails)) }
attr_reader :payer_details
# The Klarna payment method used for this transaction.
# Can be one of `pay_later`, `pay_now`, `pay_with_financing`, or `pay_in_installments`
sig { returns(T.nilable(String)) }
attr_reader :payment_method_category
# Preferred language of the Klarna authorization page that the customer is redirected to.
# Can be one of `de-AT`, `en-AT`, `nl-BE`, `fr-BE`, `en-BE`, `de-DE`, `en-DE`, `da-DK`, `en-DK`, `es-ES`, `en-ES`, `fi-FI`, `sv-FI`, `en-FI`, `en-GB`, `en-IE`, `it-IT`, `en-IT`, `nl-NL`, `en-NL`, `nb-NO`, `en-NO`, `sv-SE`, `en-SE`, `en-US`, `es-US`, `fr-FR`, `en-FR`, `cs-CZ`, `en-CZ`, `ro-RO`, `en-RO`, `el-GR`, `en-GR`, `en-AU`, `en-NZ`, `en-CA`, `fr-CA`, `pl-PL`, `en-PL`, `pt-PT`, `en-PT`, `de-CH`, `fr-CH`, `it-CH`, or `en-CH`
sig { returns(T.nilable(String)) }
attr_reader :preferred_locale
end
class Konbini < Stripe::StripeObject
class Store < Stripe::StripeObject
# The name of the convenience store chain where the payment was completed.
sig { returns(T.nilable(String)) }
attr_reader :chain
end
# If the payment succeeded, this contains the details of the convenience store where the payment was completed.
sig { returns(T.nilable(Store)) }
attr_reader :store
end
class KrCard < Stripe::StripeObject
# The local credit or debit card brand.
sig { returns(T.nilable(String)) }
attr_reader :brand
# A unique identifier for the buyer as determined by the local payment processor.
sig { returns(T.nilable(String)) }
attr_reader :buyer_id
# The last four digits of the card. This may not be present for American Express cards.
sig { returns(T.nilable(String)) }
attr_reader :last4
end
class Link < Stripe::StripeObject
# Two-letter ISO code representing the funding source country beneath the Link payment.
# You could use this attribute to get a sense of international fees.
sig { returns(T.nilable(String)) }
attr_reader :country
end
class MbWay < Stripe::StripeObject; end
class Mobilepay < Stripe::StripeObject
class Card < Stripe::StripeObject
# Brand of the card used in the transaction
sig { returns(T.nilable(String)) }
attr_reader :brand
# Two-letter ISO code representing the country of the card
sig { returns(T.nilable(String)) }
attr_reader :country
# Two digit number representing the card's expiration month
sig { returns(T.nilable(Integer)) }
attr_reader :exp_month
# Two digit number representing the card's expiration year
sig { returns(T.nilable(Integer)) }
attr_reader :exp_year
# The last 4 digits of the card
sig { returns(T.nilable(String)) }
attr_reader :last4
end
# Internal card details
sig { returns(T.nilable(Card)) }
attr_reader :card
end
class Multibanco < Stripe::StripeObject
# Entity number associated with this Multibanco payment.
sig { returns(T.nilable(String)) }
attr_reader :entity
# Reference number associated with this Multibanco payment.
sig { returns(T.nilable(String)) }
attr_reader :reference
end
class NaverPay < Stripe::StripeObject
# A unique identifier for the buyer as determined by the local payment processor.
sig { returns(T.nilable(String)) }
attr_reader :buyer_id
end
class NzBankAccount < Stripe::StripeObject
# The name on the bank account. Only present if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod’s billing details.
sig { returns(T.nilable(String)) }
attr_reader :account_holder_name
# The numeric code for the bank account's bank.
sig { returns(String) }
attr_reader :bank_code
# The name of the bank.
sig { returns(String) }
attr_reader :bank_name
# The numeric code for the bank account's bank branch.
sig { returns(String) }
attr_reader :branch_code
# Last four digits of the bank account number.
sig { returns(String) }
attr_reader :last4
# The suffix of the bank account number.
sig { returns(T.nilable(String)) }
attr_reader :suffix
end
class Oxxo < Stripe::StripeObject
# OXXO reference number
sig { returns(T.nilable(String)) }
attr_reader :number
end
class P24 < Stripe::StripeObject
# The customer's bank. Can be one of `ing`, `citi_handlowy`, `tmobile_usbugi_bankowe`, `plus_bank`, `etransfer_pocztowy24`, `banki_spbdzielcze`, `bank_nowy_bfg_sa`, `getin_bank`, `velobank`, `blik`, `noble_pay`, `ideabank`, `envelobank`, `santander_przelew24`, `nest_przelew`, `mbank_mtransfer`, `inteligo`, `pbac_z_ipko`, `bnp_paribas`, `credit_agricole`, `toyota_bank`, `bank_pekao_sa`, `volkswagen_bank`, `bank_millennium`, `alior_bank`, or `boz`.
sig { returns(T.nilable(String)) }
attr_reader :bank
# Unique reference for this Przelewy24 payment.
sig { returns(T.nilable(String)) }
attr_reader :reference
# Owner's verified full name. Values are verified or provided by Przelewy24 directly
# (if supported) at the time of authorization or settlement. They cannot be set or mutated.
# Przelewy24 rarely provides this information so the attribute is usually empty.
sig { returns(T.nilable(String)) }
attr_reader :verified_name
end
class PayByBank < Stripe::StripeObject; end
class Payco < Stripe::StripeObject
# A unique identifier for the buyer as determined by the local payment processor.
sig { returns(T.nilable(String)) }
attr_reader :buyer_id
end
class Paynow < Stripe::StripeObject
# Reference number associated with this PayNow payment
sig { returns(T.nilable(String)) }
attr_reader :reference
end
class Paypal < Stripe::StripeObject
class SellerProtection < Stripe::StripeObject
# An array of conditions that are covered for the transaction, if applicable.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :dispute_categories
# Indicates whether the transaction is eligible for PayPal's seller protection.
sig { returns(String) }
attr_reader :status
end
class Shipping < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
class VerifiedAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Two-letter ISO code representing the buyer's country. Values are provided by PayPal directly (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(String)) }
attr_reader :country
# Owner's email. Values are provided by PayPal directly
# (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(String)) }
attr_reader :payer_email
# PayPal account PayerID. This identifier uniquely identifies the PayPal customer.
sig { returns(T.nilable(String)) }
attr_reader :payer_id
# Owner's full name. Values provided by PayPal directly
# (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(String)) }
attr_reader :payer_name
# The level of protection offered as defined by PayPal Seller Protection for Merchants, for this transaction.
sig { returns(T.nilable(SellerProtection)) }
attr_reader :seller_protection
# The shipping address for the customer, as supplied by the merchant at the point of payment
# execution. This shipping address will not be updated if the merchant updates the shipping
# address on the PaymentIntent after the PaymentIntent was successfully confirmed.
sig { returns(T.nilable(Shipping)) }
attr_reader :shipping
# A unique ID generated by PayPal for this transaction.
sig { returns(T.nilable(String)) }
attr_reader :transaction_id
# The shipping address for the customer, as supplied by the merchant at the point of payment
# execution. This shipping address will not be updated if the merchant updates the shipping
# address on the PaymentIntent after the PaymentIntent was successfully confirmed.
sig { returns(T.nilable(VerifiedAddress)) }
attr_reader :verified_address
# Owner's verified email. Values are verified or provided by PayPal directly
# (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(String)) }
attr_reader :verified_email
# Owner's verified full name. Values are verified or provided by PayPal directly
# (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(String)) }
attr_reader :verified_name
end
class Payto < Stripe::StripeObject
# Bank-State-Branch number of the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bsb_number
# Last four digits of the bank account number.
sig { returns(T.nilable(String)) }
attr_reader :last4
# ID of the mandate used to make this payment.
sig { returns(String) }
attr_reader :mandate
# The PayID alias for the bank account.
sig { returns(T.nilable(String)) }
attr_reader :pay_id
end
class Pix < Stripe::StripeObject
# Unique transaction id generated by BCB
sig { returns(T.nilable(String)) }
attr_reader :bank_transaction_id
end
class Promptpay < Stripe::StripeObject
# Bill reference generated by PromptPay
sig { returns(T.nilable(String)) }
attr_reader :reference
end
class Qris < Stripe::StripeObject; end
class Rechnung < Stripe::StripeObject; end
class RevolutPay < Stripe::StripeObject
class Funding < Stripe::StripeObject
class Card < Stripe::StripeObject
# Card brand. Can be `amex`, `diners`, `discover`, `eftpos_au`, `jcb`, `link`, `mastercard`, `unionpay`, `visa`, or `unknown`.
sig { returns(T.nilable(String)) }
attr_reader :brand
# The [product code](https://stripe.com/docs/card-product-codes) that identifies the specific program or product associated with a card. (For internal use only and not typically available in standard API requests.)
sig { returns(T.nilable(String)) }
attr_reader :brand_product
# 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.
sig { returns(T.nilable(String)) }
attr_reader :country
# Two-digit number representing the card's expiration month.
sig { returns(T.nilable(Integer)) }
attr_reader :exp_month
# Four-digit number representing the card's expiration year.
sig { returns(T.nilable(Integer)) }
attr_reader :exp_year
# Card funding type. Can be `credit`, `debit`, `prepaid`, or `unknown`.
sig { returns(T.nilable(String)) }
attr_reader :funding
# The last four digits of the card.
sig { returns(T.nilable(String)) }
attr_reader :last4
end
# Attribute for field card
sig { returns(Card) }
attr_reader :card
# funding type of the underlying payment method.
sig { returns(T.nilable(String)) }
attr_reader :type
end
# Attribute for field funding
sig { returns(Funding) }
attr_reader :funding
end
class SamsungPay < Stripe::StripeObject
# A unique identifier for the buyer as determined by the local payment processor.
sig { returns(T.nilable(String)) }
attr_reader :buyer_id
end
class Satispay < Stripe::StripeObject; end
class SepaCreditTransfer < Stripe::StripeObject
# Name of the bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# Bank Identifier Code of the bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bic
# IBAN of the bank account to transfer funds to.
sig { returns(T.nilable(String)) }
attr_reader :iban
end
class SepaDebit < Stripe::StripeObject
# Bank code of bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_code
# Branch code of bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :branch_code
# Two-letter ISO code representing the country the bank account is located in.
sig { returns(T.nilable(String)) }
attr_reader :country
# Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Last four characters of the IBAN.
sig { returns(T.nilable(String)) }
attr_reader :last4
# Find the ID of the mandate used for this payment under the [payment_method_details.sepa_debit.mandate](https://stripe.com/docs/api/charges/object#charge_object-payment_method_details-sepa_debit-mandate) property on the Charge. Use this mandate ID to [retrieve the Mandate](https://stripe.com/docs/api/mandates/retrieve).
sig { returns(T.nilable(String)) }
attr_reader :mandate
end
class Shopeepay < Stripe::StripeObject; end
class Sofort < Stripe::StripeObject
# Bank code of bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_code
# Name of the bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# Bank Identifier Code of the bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bic
# Two-letter ISO code representing the country the bank account is located in.
sig { returns(T.nilable(String)) }
attr_reader :country
# The ID of the SEPA Direct Debit PaymentMethod which was generated by this Charge.
sig { returns(T.nilable(T.any(String, Stripe::PaymentMethod))) }
attr_reader :generated_sepa_debit
# The mandate for the SEPA Direct Debit PaymentMethod which was generated by this Charge.
sig { returns(T.nilable(T.any(String, Stripe::Mandate))) }
attr_reader :generated_sepa_debit_mandate
# Last four characters of the IBAN.
sig { returns(T.nilable(String)) }
attr_reader :iban_last4
# Preferred language of the SOFORT authorization page that the customer is redirected to.
# Can be one of `de`, `en`, `es`, `fr`, `it`, `nl`, or `pl`
sig { returns(T.nilable(String)) }
attr_reader :preferred_language
# Owner's verified full name. Values are verified or provided by SOFORT directly
# (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(String)) }
attr_reader :verified_name
end
class StripeAccount < Stripe::StripeObject; end
class StripeBalance < Stripe::StripeObject
# The connected account ID whose Stripe balance to use as the source of payment
sig { returns(T.nilable(String)) }
attr_reader :account
# The [source_type](https://docs.stripe.com/api/balance/balance_object#balance_object-available-source_types) of the balance
sig { returns(String) }
attr_reader :source_type
end
class Swish < Stripe::StripeObject
# Uniquely identifies the payer's Swish account. You can use this attribute to check whether two Swish transactions were paid for by the same payer
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Payer bank reference number for the payment
sig { returns(T.nilable(String)) }
attr_reader :payment_reference
# The last four digits of the Swish account phone number
sig { returns(T.nilable(String)) }
attr_reader :verified_phone_last4
end
class Twint < Stripe::StripeObject; end
class UsBankAccount < Stripe::StripeObject
# Account holder type: individual or company.
sig { returns(T.nilable(String)) }
attr_reader :account_holder_type
# Account type: checkings or savings. Defaults to checking if omitted.
sig { returns(T.nilable(String)) }
attr_reader :account_type
# Name of the bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Last four digits of the bank account number.
sig { returns(T.nilable(String)) }
attr_reader :last4
# ID of the mandate used to make this payment.
sig { returns(T.any(String, Stripe::Mandate)) }
attr_reader :mandate
# Reference number to locate ACH payments with customer's bank.
sig { returns(T.nilable(String)) }
attr_reader :payment_reference
# Routing number of the bank account.
sig { returns(T.nilable(String)) }
attr_reader :routing_number
end
class Wechat < Stripe::StripeObject; end
class WechatPay < Stripe::StripeObject
# Uniquely identifies this particular WeChat Pay account. You can use this attribute to check whether two WeChat accounts are the same.
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# ID of the [location](https://stripe.com/docs/api/terminal/locations) that this transaction's reader is assigned to.
sig { returns(String) }
attr_reader :location
# ID of the [reader](https://stripe.com/docs/api/terminal/readers) this transaction was made on.
sig { returns(String) }
attr_reader :reader
# Transaction ID of this particular WeChat Pay transaction.
sig { returns(T.nilable(String)) }
attr_reader :transaction_id
end
class Zip < Stripe::StripeObject; end
# Attribute for field ach_credit_transfer
sig { returns(AchCreditTransfer) }
attr_reader :ach_credit_transfer
# Attribute for field ach_debit
sig { returns(AchDebit) }
attr_reader :ach_debit
# Attribute for field acss_debit
sig { returns(AcssDebit) }
attr_reader :acss_debit
# Attribute for field affirm
sig { returns(Affirm) }
attr_reader :affirm
# Attribute for field afterpay_clearpay
sig { returns(AfterpayClearpay) }
attr_reader :afterpay_clearpay
# Attribute for field alipay
sig { returns(Alipay) }
attr_reader :alipay
# Attribute for field alma
sig { returns(Alma) }
attr_reader :alma
# Attribute for field amazon_pay
sig { returns(AmazonPay) }
attr_reader :amazon_pay
# Attribute for field au_becs_debit
sig { returns(AuBecsDebit) }
attr_reader :au_becs_debit
# Attribute for field bacs_debit
sig { returns(BacsDebit) }
attr_reader :bacs_debit
# Attribute for field bancontact
sig { returns(Bancontact) }
attr_reader :bancontact
# Attribute for field billie
sig { returns(Billie) }
attr_reader :billie
# The billing details associated with the method of payment.
sig { returns(T.nilable(BillingDetails)) }
attr_reader :billing_details
# Attribute for field blik
sig { returns(Blik) }
attr_reader :blik
# Attribute for field boleto
sig { returns(Boleto) }
attr_reader :boleto
# Details of the card used for this payment attempt.
sig { returns(Card) }
attr_reader :card
# Attribute for field card_present
sig { returns(CardPresent) }
attr_reader :card_present
# Attribute for field cashapp
sig { returns(Cashapp) }
attr_reader :cashapp
# Custom Payment Methods represent Payment Method types not modeled directly in
# the Stripe API. This resource consists of details about the custom payment method
# used for this payment attempt.
sig { returns(Custom) }
attr_reader :custom
# Attribute for field customer_balance
sig { returns(CustomerBalance) }
attr_reader :customer_balance
# Attribute for field eps
sig { returns(Eps) }
attr_reader :eps
# Attribute for field fpx
sig { returns(Fpx) }
attr_reader :fpx
# Attribute for field giropay
sig { returns(Giropay) }
attr_reader :giropay
# Attribute for field gopay
sig { returns(Gopay) }
attr_reader :gopay
# Attribute for field grabpay
sig { returns(Grabpay) }
attr_reader :grabpay
# Attribute for field id_bank_transfer
sig { returns(IdBankTransfer) }
attr_reader :id_bank_transfer
# Attribute for field ideal
sig { returns(Ideal) }
attr_reader :ideal
# Attribute for field interac_present
sig { returns(InteracPresent) }
attr_reader :interac_present
# Attribute for field kakao_pay
sig { returns(KakaoPay) }
attr_reader :kakao_pay
# Attribute for field klarna
sig { returns(Klarna) }
attr_reader :klarna
# Attribute for field konbini
sig { returns(Konbini) }
attr_reader :konbini
# Attribute for field kr_card
sig { returns(KrCard) }
attr_reader :kr_card
# Attribute for field link
sig { returns(Link) }
attr_reader :link
# Attribute for field mb_way
sig { returns(MbWay) }
attr_reader :mb_way
# Attribute for field mobilepay
sig { returns(Mobilepay) }
attr_reader :mobilepay
# Attribute for field multibanco
sig { returns(Multibanco) }
attr_reader :multibanco
# Attribute for field naver_pay
sig { returns(NaverPay) }
attr_reader :naver_pay
# Attribute for field nz_bank_account
sig { returns(NzBankAccount) }
attr_reader :nz_bank_account
# Attribute for field oxxo
sig { returns(Oxxo) }
attr_reader :oxxo
# Attribute for field p24
sig { returns(P24) }
attr_reader :p24
# Attribute for field pay_by_bank
sig { returns(PayByBank) }
attr_reader :pay_by_bank
# Attribute for field payco
sig { returns(Payco) }
attr_reader :payco
# ID of the Stripe PaymentMethod used to make this payment.
sig { returns(T.nilable(String)) }
attr_reader :payment_method
# Attribute for field paynow
sig { returns(Paynow) }
attr_reader :paynow
# Attribute for field paypal
sig { returns(Paypal) }
attr_reader :paypal
# Attribute for field payto
sig { returns(Payto) }
attr_reader :payto
# Attribute for field pix
sig { returns(Pix) }
attr_reader :pix
# Attribute for field promptpay
sig { returns(Promptpay) }
attr_reader :promptpay
# Attribute for field qris
sig { returns(Qris) }
attr_reader :qris
# Attribute for field rechnung
sig { returns(Rechnung) }
attr_reader :rechnung
# Attribute for field revolut_pay
sig { returns(RevolutPay) }
attr_reader :revolut_pay
# Attribute for field samsung_pay
sig { returns(SamsungPay) }
attr_reader :samsung_pay
# Attribute for field satispay
sig { returns(Satispay) }
attr_reader :satispay
# Attribute for field sepa_credit_transfer
sig { returns(SepaCreditTransfer) }
attr_reader :sepa_credit_transfer
# Attribute for field sepa_debit
sig { returns(SepaDebit) }
attr_reader :sepa_debit
# Attribute for field shopeepay
sig { returns(Shopeepay) }
attr_reader :shopeepay
# Attribute for field sofort
sig { returns(Sofort) }
attr_reader :sofort
# Attribute for field stripe_account
sig { returns(StripeAccount) }
attr_reader :stripe_account
# Attribute for field stripe_balance
sig { returns(StripeBalance) }
attr_reader :stripe_balance
# Attribute for field swish
sig { returns(Swish) }
attr_reader :swish
# Attribute for field twint
sig { returns(Twint) }
attr_reader :twint
# The type of transaction-specific details of the payment method used in the payment. See [PaymentMethod.type](https://stripe.com/docs/api/payment_methods/object#payment_method_object-type) for the full list of possible types.
# An additional hash is included on `payment_method_details` with a name matching this value.
# It contains information specific to the payment method.
sig { returns(String) }
attr_reader :type
# Attribute for field us_bank_account
sig { returns(UsBankAccount) }
attr_reader :us_bank_account
# Attribute for field wechat
sig { returns(Wechat) }
attr_reader :wechat
# Attribute for field wechat_pay
sig { returns(WechatPay) }
attr_reader :wechat_pay
# Attribute for field zip
sig { returns(Zip) }
attr_reader :zip
end
class ShippingDetails < Stripe::StripeObject
class Address < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# A representation of a physical address.
sig { returns(Address) }
attr_reader :address
# The shipping recipient's name.
sig { returns(T.nilable(String)) }
attr_reader :name
# The shipping recipient's phone number.
sig { returns(T.nilable(String)) }
attr_reader :phone
end
# A representation of an amount of money, consisting of an amount and a currency.
sig { returns(AmountCanceled) }
attr_reader :amount_canceled
# A representation of an amount of money, consisting of an amount and a currency.
sig { returns(AmountFailed) }
attr_reader :amount_failed
# A representation of an amount of money, consisting of an amount and a currency.
sig { returns(AmountGuaranteed) }
attr_reader :amount_guaranteed
# A representation of an amount of money, consisting of an amount and a currency.
sig { returns(AmountRequested) }
attr_reader :amount_requested
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# Customer information for this payment.
sig { returns(T.nilable(CustomerDetails)) }
attr_reader :customer_details
# Indicates whether the customer was present in your checkout flow during this payment.
sig { returns(T.nilable(String)) }
attr_reader :customer_presence
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_reader :description
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# ID of the latest Payment Attempt Record attached to this Payment Record.
sig { returns(T.nilable(String)) }
attr_reader :latest_payment_attempt_record
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# 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.
sig { returns(T::Hash[String, String]) }
attr_reader :metadata
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Information about the Payment Method debited for this payment.
sig { returns(T.nilable(PaymentMethodDetails)) }
attr_reader :payment_method_details
# An opaque string for manual reconciliation of this payment, for example a check number or a payment processor ID.
sig { returns(T.nilable(String)) }
attr_reader :payment_reference
# Shipping information for this payment.
sig { returns(T.nilable(ShippingDetails)) }
attr_reader :shipping_details
class ReportPaymentAttemptParams < Stripe::RequestParams
class Failed < Stripe::RequestParams
# When the reported payment failed. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :failed_at
sig { params(failed_at: Integer).void }
def initialize(failed_at: nil); end
end
class Guaranteed < Stripe::RequestParams
# When the reported payment was guaranteed. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :guaranteed_at
sig { params(guaranteed_at: Integer).void }
def initialize(guaranteed_at: nil); end
end
class PaymentMethodDetails < Stripe::RequestParams
class BillingDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# The billing address associated with the method of payment.
sig {
returns(T.nilable(::Stripe::PaymentRecord::ReportPaymentAttemptParams::PaymentMethodDetails::BillingDetails::Address))
}
attr_accessor :address
# The billing email associated with the method of payment.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The billing name associated with the method of payment.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The billing phone number associated with the method of payment.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(address: T.nilable(::Stripe::PaymentRecord::ReportPaymentAttemptParams::PaymentMethodDetails::BillingDetails::Address), email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(address: nil, email: nil, name: nil, phone: nil); end
end
class Custom < Stripe::RequestParams
# Display name for the custom (user-defined) payment method type used to make this payment.
sig { returns(T.nilable(String)) }
attr_accessor :display_name
# The custom payment method type associated with this payment.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig { params(display_name: T.nilable(String), type: T.nilable(String)).void }
def initialize(display_name: nil, type: nil); end
end
# The billing details associated with the method of payment.
sig {
returns(T.nilable(::Stripe::PaymentRecord::ReportPaymentAttemptParams::PaymentMethodDetails::BillingDetails))
}
attr_accessor :billing_details
# Information about the custom (user-defined) payment method used to make this payment.
sig {
returns(T.nilable(::Stripe::PaymentRecord::ReportPaymentAttemptParams::PaymentMethodDetails::Custom))
}
attr_accessor :custom
# ID of the Stripe Payment Method used to make this payment.
sig { returns(T.nilable(String)) }
attr_accessor :payment_method
# The type of the payment method details. An additional hash is included on the payment_method_details with a name matching this value. It contains additional information specific to the type.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(billing_details: T.nilable(::Stripe::PaymentRecord::ReportPaymentAttemptParams::PaymentMethodDetails::BillingDetails), custom: T.nilable(::Stripe::PaymentRecord::ReportPaymentAttemptParams::PaymentMethodDetails::Custom), payment_method: T.nilable(String), type: T.nilable(String)).void
}
def initialize(billing_details: nil, custom: nil, payment_method: nil, type: nil); end
end
class ShippingDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# The physical shipping address.
sig {
returns(T.nilable(::Stripe::PaymentRecord::ReportPaymentAttemptParams::ShippingDetails::Address))
}
attr_accessor :address
# The shipping recipient's name.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The shipping recipient's phone number.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(address: T.nilable(::Stripe::PaymentRecord::ReportPaymentAttemptParams::ShippingDetails::Address), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(address: nil, name: nil, phone: nil); end
end
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Information about the payment attempt failure.
sig { returns(T.nilable(::Stripe::PaymentRecord::ReportPaymentAttemptParams::Failed)) }
attr_accessor :failed
# Information about the payment attempt guarantee.
sig { returns(T.nilable(::Stripe::PaymentRecord::ReportPaymentAttemptParams::Guaranteed)) }
attr_accessor :guaranteed
# When the reported payment was initiated. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :initiated_at
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# The outcome of the reported payment.
sig { returns(T.nilable(String)) }
attr_accessor :outcome
# Information about the Payment Method debited for this payment.
sig {
returns(T.nilable(::Stripe::PaymentRecord::ReportPaymentAttemptParams::PaymentMethodDetails))
}
attr_accessor :payment_method_details
# Shipping information for this payment.
sig {
returns(T.nilable(::Stripe::PaymentRecord::ReportPaymentAttemptParams::ShippingDetails))
}
attr_accessor :shipping_details
sig {
params(description: T.nilable(String), expand: T.nilable(T::Array[String]), failed: T.nilable(::Stripe::PaymentRecord::ReportPaymentAttemptParams::Failed), guaranteed: T.nilable(::Stripe::PaymentRecord::ReportPaymentAttemptParams::Guaranteed), initiated_at: Integer, metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), outcome: T.nilable(String), payment_method_details: T.nilable(::Stripe::PaymentRecord::ReportPaymentAttemptParams::PaymentMethodDetails), shipping_details: T.nilable(::Stripe::PaymentRecord::ReportPaymentAttemptParams::ShippingDetails)).void
}
def initialize(
description: nil,
expand: nil,
failed: nil,
guaranteed: nil,
initiated_at: nil,
metadata: nil,
outcome: nil,
payment_method_details: nil,
shipping_details: nil
); end
end
class ReportPaymentAttemptCanceledParams < Stripe::RequestParams
# When the reported payment was canceled. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :canceled_at
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Attribute for param field metadata
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
sig {
params(canceled_at: Integer, expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String])))).void
}
def initialize(canceled_at: nil, expand: nil, metadata: nil); end
end
class ReportPaymentAttemptFailedParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# When the reported payment failed. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :failed_at
# Attribute for param field metadata
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
sig {
params(expand: T.nilable(T::Array[String]), failed_at: Integer, metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String])))).void
}
def initialize(expand: nil, failed_at: nil, metadata: nil); end
end
class ReportPaymentAttemptGuaranteedParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# When the reported payment was guaranteed. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :guaranteed_at
# Attribute for param field metadata
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
sig {
params(expand: T.nilable(T::Array[String]), guaranteed_at: Integer, metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String])))).void
}
def initialize(expand: nil, guaranteed_at: nil, metadata: nil); end
end
class ReportPaymentParams < Stripe::RequestParams
class AmountRequested < Stripe::RequestParams
# 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).
sig { returns(String) }
attr_accessor :currency
# A positive integer representing the amount in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) for example, 100 cents for 1 USD or 100 for 100 JPY, a zero-decimal currency.
sig { returns(Integer) }
attr_accessor :value
sig { params(currency: String, value: Integer).void }
def initialize(currency: nil, value: nil); end
end
class CustomerDetails < Stripe::RequestParams
# The customer who made the payment.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# The customer's phone number.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The customer's name.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The customer's phone number.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(customer: T.nilable(String), email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(customer: nil, email: nil, name: nil, phone: nil); end
end
class Failed < Stripe::RequestParams
# When the reported payment failed. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :failed_at
sig { params(failed_at: Integer).void }
def initialize(failed_at: nil); end
end
class Guaranteed < Stripe::RequestParams
# When the reported payment was guaranteed. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :guaranteed_at
sig { params(guaranteed_at: Integer).void }
def initialize(guaranteed_at: nil); end
end
class PaymentMethodDetails < Stripe::RequestParams
class BillingDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# The billing address associated with the method of payment.
sig {
returns(T.nilable(::Stripe::PaymentRecord::ReportPaymentParams::PaymentMethodDetails::BillingDetails::Address))
}
attr_accessor :address
# The billing email associated with the method of payment.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The billing name associated with the method of payment.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The billing phone number associated with the method of payment.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(address: T.nilable(::Stripe::PaymentRecord::ReportPaymentParams::PaymentMethodDetails::BillingDetails::Address), email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(address: nil, email: nil, name: nil, phone: nil); end
end
class Custom < Stripe::RequestParams
# Display name for the custom (user-defined) payment method type used to make this payment.
sig { returns(T.nilable(String)) }
attr_accessor :display_name
# The custom payment method type associated with this payment.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig { params(display_name: T.nilable(String), type: T.nilable(String)).void }
def initialize(display_name: nil, type: nil); end
end
# The billing details associated with the method of payment.
sig {
returns(T.nilable(::Stripe::PaymentRecord::ReportPaymentParams::PaymentMethodDetails::BillingDetails))
}
attr_accessor :billing_details
# Information about the custom (user-defined) payment method used to make this payment.
sig {
returns(T.nilable(::Stripe::PaymentRecord::ReportPaymentParams::PaymentMethodDetails::Custom))
}
attr_accessor :custom
# ID of the Stripe Payment Method used to make this payment.
sig { returns(T.nilable(String)) }
attr_accessor :payment_method
# The type of the payment method details. An additional hash is included on the payment_method_details with a name matching this value. It contains additional information specific to the type.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(billing_details: T.nilable(::Stripe::PaymentRecord::ReportPaymentParams::PaymentMethodDetails::BillingDetails), custom: T.nilable(::Stripe::PaymentRecord::ReportPaymentParams::PaymentMethodDetails::Custom), payment_method: T.nilable(String), type: T.nilable(String)).void
}
def initialize(billing_details: nil, custom: nil, payment_method: nil, type: nil); end
end
class ShippingDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# The physical shipping address.
sig {
returns(T.nilable(::Stripe::PaymentRecord::ReportPaymentParams::ShippingDetails::Address))
}
attr_accessor :address
# The shipping recipient's name.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The shipping recipient's phone number.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(address: T.nilable(::Stripe::PaymentRecord::ReportPaymentParams::ShippingDetails::Address), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(address: nil, name: nil, phone: nil); end
end
# The amount you initially requested for this payment.
sig { returns(::Stripe::PaymentRecord::ReportPaymentParams::AmountRequested) }
attr_accessor :amount_requested
# Customer information for this payment.
sig { returns(T.nilable(::Stripe::PaymentRecord::ReportPaymentParams::CustomerDetails)) }
attr_accessor :customer_details
# Indicates whether the customer was present in your checkout flow during this payment.
sig { returns(T.nilable(String)) }
attr_accessor :customer_presence
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Information about the payment attempt failure.
sig { returns(T.nilable(::Stripe::PaymentRecord::ReportPaymentParams::Failed)) }
attr_accessor :failed
# Information about the payment attempt guarantee.
sig { returns(T.nilable(::Stripe::PaymentRecord::ReportPaymentParams::Guaranteed)) }
attr_accessor :guaranteed
# When the reported payment was initiated. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :initiated_at
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# The outcome of the reported payment.
sig { returns(T.nilable(String)) }
attr_accessor :outcome
# Information about the Payment Method debited for this payment.
sig { returns(::Stripe::PaymentRecord::ReportPaymentParams::PaymentMethodDetails) }
attr_accessor :payment_method_details
# An opaque string for manual reconciliation of this payment, for example a check number or a payment processor ID.
sig { returns(T.nilable(String)) }
attr_accessor :payment_reference
# Shipping information for this payment.
sig { returns(T.nilable(::Stripe::PaymentRecord::ReportPaymentParams::ShippingDetails)) }
attr_accessor :shipping_details
sig {
params(amount_requested: ::Stripe::PaymentRecord::ReportPaymentParams::AmountRequested, customer_details: T.nilable(::Stripe::PaymentRecord::ReportPaymentParams::CustomerDetails), customer_presence: T.nilable(String), description: T.nilable(String), expand: T.nilable(T::Array[String]), failed: T.nilable(::Stripe::PaymentRecord::ReportPaymentParams::Failed), guaranteed: T.nilable(::Stripe::PaymentRecord::ReportPaymentParams::Guaranteed), initiated_at: Integer, metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), outcome: T.nilable(String), payment_method_details: ::Stripe::PaymentRecord::ReportPaymentParams::PaymentMethodDetails, payment_reference: T.nilable(String), shipping_details: T.nilable(::Stripe::PaymentRecord::ReportPaymentParams::ShippingDetails)).void
}
def initialize(
amount_requested: nil,
customer_details: nil,
customer_presence: nil,
description: nil,
expand: nil,
failed: nil,
guaranteed: nil,
initiated_at: nil,
metadata: nil,
outcome: nil,
payment_method_details: nil,
payment_reference: nil,
shipping_details: nil
); end
end
# Report a new Payment Record. You may report a Payment Record as it is
# initialized and later report updates through the other report_* methods, or report Payment
# Records in a terminal state directly, through this method.
sig {
params(params: T.any(::Stripe::PaymentRecord::ReportPaymentParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentRecord)
}
def self.report_payment(params = {}, opts = {}); end
# Report a new payment attempt on the specified Payment Record. A new payment
# attempt can only be specified if all other payment attempts are canceled or failed.
sig {
params(params: T.any(::Stripe::PaymentRecord::ReportPaymentAttemptParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentRecord)
}
def report_payment_attempt(params = {}, opts = {}); end
# Report a new payment attempt on the specified Payment Record. A new payment
# attempt can only be specified if all other payment attempts are canceled or failed.
sig {
params(id: String, params: T.any(::Stripe::PaymentRecord::ReportPaymentAttemptParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentRecord)
}
def self.report_payment_attempt(id, params = {}, opts = {}); end
# Report that the most recent payment attempt on the specified Payment Record
# was canceled.
sig {
params(params: T.any(::Stripe::PaymentRecord::ReportPaymentAttemptCanceledParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentRecord)
}
def report_payment_attempt_canceled(params = {}, opts = {}); end
# Report that the most recent payment attempt on the specified Payment Record
# was canceled.
sig {
params(id: String, params: T.any(::Stripe::PaymentRecord::ReportPaymentAttemptCanceledParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentRecord)
}
def self.report_payment_attempt_canceled(id, params = {}, opts = {}); end
# Report that the most recent payment attempt on the specified Payment Record
# failed or errored.
sig {
params(params: T.any(::Stripe::PaymentRecord::ReportPaymentAttemptFailedParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentRecord)
}
def report_payment_attempt_failed(params = {}, opts = {}); end
# Report that the most recent payment attempt on the specified Payment Record
# failed or errored.
sig {
params(id: String, params: T.any(::Stripe::PaymentRecord::ReportPaymentAttemptFailedParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentRecord)
}
def self.report_payment_attempt_failed(id, params = {}, opts = {}); end
# Report that the most recent payment attempt on the specified Payment Record
# was guaranteed.
sig {
params(params: T.any(::Stripe::PaymentRecord::ReportPaymentAttemptGuaranteedParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentRecord)
}
def report_payment_attempt_guaranteed(params = {}, opts = {}); end
# Report that the most recent payment attempt on the specified Payment Record
# was guaranteed.
sig {
params(id: String, params: T.any(::Stripe::PaymentRecord::ReportPaymentAttemptGuaranteedParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentRecord)
}
def self.report_payment_attempt_guaranteed(id, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
# A `Payout` object is created when you receive funds from Stripe, or when you
# initiate a payout to either a bank account or debit card of a [connected
# Stripe account](https://docs.stripe.com/docs/connect/bank-debit-card-payouts). You can retrieve individual payouts,
# and list all payouts. Payouts are made on [varying
# schedules](https://docs.stripe.com/docs/connect/manage-payout-schedule), depending on your country and
# industry.
#
# Related guide: [Receiving payouts](https://stripe.com/docs/payouts)
class Payout < APIResource
class TraceId < Stripe::StripeObject
# Possible values are `pending`, `supported`, and `unsupported`. When `payout.status` is `pending` or `in_transit`, this will be `pending`. When the payout transitions to `paid`, `failed`, or `canceled`, this status will become `supported` or `unsupported` shortly after in most cases. In some cases, this may appear as `pending` for up to 10 days after `arrival_date` until transitioning to `supported` or `unsupported`.
sig { returns(String) }
attr_reader :status
# The trace ID value if `trace_id.status` is `supported`, otherwise `nil`.
sig { returns(T.nilable(String)) }
attr_reader :value
end
# The amount (in cents (or local equivalent)) that transfers to your bank account or debit card.
sig { returns(Integer) }
attr_reader :amount
# The application fee (if any) for the payout. [See the Connect documentation](https://stripe.com/docs/connect/instant-payouts#monetization-and-fees) for details.
sig { returns(T.nilable(T.any(String, Stripe::ApplicationFee))) }
attr_reader :application_fee
# The amount of the application fee (if any) requested for the payout. [See the Connect documentation](https://stripe.com/docs/connect/instant-payouts#monetization-and-fees) for details.
sig { returns(T.nilable(Integer)) }
attr_reader :application_fee_amount
# Date that you can expect the payout to arrive in the bank. This factors in delays to account for weekends or bank holidays.
sig { returns(Integer) }
attr_reader :arrival_date
# Returns `true` if the payout is created by an [automated payout schedule](https://stripe.com/docs/payouts#payout-schedule) and `false` if it's [requested manually](https://stripe.com/docs/payouts#manual-payouts).
sig { returns(T::Boolean) }
attr_reader :automatic
# ID of the balance transaction that describes the impact of this payout on your account balance.
sig { returns(T.nilable(T.any(String, Stripe::BalanceTransaction))) }
attr_reader :balance_transaction
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# 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).
sig { returns(String) }
attr_reader :currency
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_reader :description
# ID of the bank account or card the payout is sent to.
sig { returns(T.nilable(T.any(String, T.any(Stripe::BankAccount, Stripe::Card)))) }
attr_reader :destination
# If the payout fails or cancels, this is the ID of the balance transaction that reverses the initial balance transaction and returns the funds from the failed payout back in your balance.
sig { returns(T.nilable(T.any(String, Stripe::BalanceTransaction))) }
attr_reader :failure_balance_transaction
# Error code that provides a reason for a payout failure, if available. View our [list of failure codes](https://stripe.com/docs/api#payout_failures).
sig { returns(T.nilable(String)) }
attr_reader :failure_code
# Message that provides the reason for a payout failure, if available.
sig { returns(T.nilable(String)) }
attr_reader :failure_message
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# 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.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# The method used to send this payout, which can be `standard` or `instant`. `instant` is supported for payouts to debit cards and bank accounts in certain countries. Learn more about [bank support for Instant Payouts](https://stripe.com/docs/payouts/instant-payouts-banks).
sig { returns(String) }
attr_reader :method
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# If the payout reverses another, this is the ID of the original payout.
sig { returns(T.nilable(T.any(String, Stripe::Payout))) }
attr_reader :original_payout
# ID of the v2 FinancialAccount the funds are sent to.
sig { returns(T.nilable(String)) }
attr_reader :payout_method
# If `completed`, you can use the [Balance Transactions API](https://stripe.com/docs/api/balance_transactions/list#balance_transaction_list-payout) to list all balance transactions that are paid out in this payout.
sig { returns(String) }
attr_reader :reconciliation_status
# If the payout reverses, this is the ID of the payout that reverses this payout.
sig { returns(T.nilable(T.any(String, Stripe::Payout))) }
attr_reader :reversed_by
# The source balance this payout came from, which can be one of the following: `card`, `fpx`, or `bank_account`.
sig { returns(String) }
attr_reader :source_type
# Extra information about a payout that displays on the user's bank statement.
sig { returns(T.nilable(String)) }
attr_reader :statement_descriptor
# Current status of the payout: `paid`, `pending`, `in_transit`, `canceled` or `failed`. A payout is `pending` until it's submitted to the bank, when it becomes `in_transit`. The status changes to `paid` if the transaction succeeds, or to `failed` or `canceled` (within 5 business days). Some payouts that fail might initially show as `paid`, then change to `failed`.
sig { returns(String) }
attr_reader :status
# A value that generates from the beneficiary's bank that allows users to track payouts with their bank. Banks might call this a "reference number" or something similar.
sig { returns(T.nilable(TraceId)) }
attr_reader :trace_id
# Can be `bank_account` or `card`.
sig { returns(String) }
attr_reader :type
class ListParams < Stripe::RequestParams
class ArrivalDate < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return payouts that are expected to arrive during the given date interval.
sig { returns(T.nilable(T.any(::Stripe::Payout::ListParams::ArrivalDate, Integer))) }
attr_accessor :arrival_date
# Only return payouts that were created during the given date interval.
sig { returns(T.nilable(T.any(::Stripe::Payout::ListParams::Created, Integer))) }
attr_accessor :created
# The ID of an external account - only return payouts sent to this external account.
sig { returns(T.nilable(String)) }
attr_accessor :destination
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return payouts that have the given status: `pending`, `paid`, `failed`, or `canceled`.
sig { returns(T.nilable(String)) }
attr_accessor :status
sig {
params(arrival_date: T.nilable(T.any(::Stripe::Payout::ListParams::ArrivalDate, Integer)), created: T.nilable(T.any(::Stripe::Payout::ListParams::Created, Integer)), destination: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String), status: T.nilable(String)).void
}
def initialize(
arrival_date: nil,
created: nil,
destination: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil,
status: nil
); end
end
class CreateParams < Stripe::RequestParams
# A positive integer in cents representing how much to payout.
sig { returns(Integer) }
attr_accessor :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).
sig { returns(String) }
attr_accessor :currency
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# The ID of a bank account or a card to send the payout to. If you don't provide a destination, we use the default external account for the specified currency.
sig { returns(T.nilable(String)) }
attr_accessor :destination
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The method used to send this payout, which is `standard` or `instant`. We support `instant` for payouts to debit cards and bank accounts in certain countries. Learn more about [bank support for Instant Payouts](https://stripe.com/docs/payouts/instant-payouts-banks).
sig { returns(T.nilable(String)) }
attr_accessor :method
# The ID of a v2 FinancialAccount to send funds to.
sig { returns(T.nilable(String)) }
attr_accessor :payout_method
# The balance type of your Stripe balance to draw this payout from. Balances for different payment sources are kept separately. You can find the amounts with the Balances API. One of `bank_account`, `card`, or `fpx`.
sig { returns(T.nilable(String)) }
attr_accessor :source_type
# A string that displays on the recipient's bank or card statement (up to 22 characters). A `statement_descriptor` that's longer than 22 characters return an error. Most banks truncate this information and display it inconsistently. Some banks might not display it at all.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
sig {
params(amount: Integer, currency: String, description: T.nilable(String), destination: T.nilable(String), expand: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), method: T.nilable(String), payout_method: T.nilable(String), source_type: T.nilable(String), statement_descriptor: T.nilable(String)).void
}
def initialize(
amount: nil,
currency: nil,
description: nil,
destination: nil,
expand: nil,
metadata: nil,
method: nil,
payout_method: nil,
source_type: nil,
statement_descriptor: nil
); end
end
class UpdateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
sig {
params(expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String])))).void
}
def initialize(expand: nil, metadata: nil); end
end
class CancelParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class ReverseParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
sig {
params(expand: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String])).void
}
def initialize(expand: nil, metadata: nil); end
end
# You can cancel a previously created payout if its status is pending. Stripe refunds the funds to your available balance. You can't cancel automatic Stripe payouts.
sig {
params(params: T.any(::Stripe::Payout::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Payout)
}
def cancel(params = {}, opts = {}); end
# You can cancel a previously created payout if its status is pending. Stripe refunds the funds to your available balance. You can't cancel automatic Stripe payouts.
sig {
params(payout: String, params: T.any(::Stripe::Payout::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Payout)
}
def self.cancel(payout, params = {}, opts = {}); end
# To send funds to your own bank account, create a new payout object. Your [Stripe balance](https://docs.stripe.com/api#balance) must cover the payout amount. If it doesn't, you receive an “Insufficient Funds” error.
#
# If your API key is in test mode, money won't actually be sent, though every other action occurs as if you're in live mode.
#
# If you create a manual payout on a Stripe account that uses multiple payment source types, you need to specify the source type balance that the payout draws from. The [balance object](https://docs.stripe.com/api#balance_object) details available and pending amounts by source type.
sig {
params(params: T.any(::Stripe::Payout::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Payout)
}
def self.create(params = {}, opts = {}); end
# Returns a list of existing payouts sent to third-party bank accounts or payouts that Stripe sent to you. The payouts return in sorted order, with the most recently created payouts appearing first.
sig {
params(params: T.any(::Stripe::Payout::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Reverses a payout by debiting the destination bank account. At this time, you can only reverse payouts for connected accounts to US bank accounts. If the payout is manual and in the pending status, use /v1/payouts/:id/cancel instead.
#
# By requesting a reversal through /v1/payouts/:id/reverse, you confirm that the authorized signatory of the selected bank account authorizes the debit on the bank account and that no other authorization is required.
sig {
params(params: T.any(::Stripe::Payout::ReverseParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Payout)
}
def reverse(params = {}, opts = {}); end
# Reverses a payout by debiting the destination bank account. At this time, you can only reverse payouts for connected accounts to US bank accounts. If the payout is manual and in the pending status, use /v1/payouts/:id/cancel instead.
#
# By requesting a reversal through /v1/payouts/:id/reverse, you confirm that the authorized signatory of the selected bank account authorizes the debit on the bank account and that no other authorization is required.
sig {
params(payout: String, params: T.any(::Stripe::Payout::ReverseParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Payout)
}
def self.reverse(payout, params = {}, opts = {}); end
# Updates the specified payout by setting the values of the parameters you pass. We don't change parameters that you don't provide. This request only accepts the metadata as arguments.
sig {
params(payout: String, params: T.any(::Stripe::Payout::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Payout)
}
def self.update(payout, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
# This is an object representing a person associated with a Stripe account.
#
# A platform can only access a subset of data in a person for an account where [account.controller.requirement_collection](https://docs.stripe.com/api/accounts/object#account_object-controller-requirement_collection) is `stripe`, which includes Standard and Express accounts, after creating an Account Link or Account Session to start Connect onboarding.
#
# See the [Standard onboarding](https://docs.stripe.com/connect/standard-accounts) or [Express onboarding](https://docs.stripe.com/connect/express-accounts) documentation for information about prefilling information and account onboarding steps. Learn more about [handling identity verification with the API](https://docs.stripe.com/connect/handling-api-verification#person-information).
class Person < APIResource
class AdditionalTosAcceptances < Stripe::StripeObject
class Account < Stripe::StripeObject
# The Unix timestamp marking when the legal guardian accepted the service agreement.
sig { returns(T.nilable(Integer)) }
attr_reader :date
# The IP address from which the legal guardian accepted the service agreement.
sig { returns(T.nilable(String)) }
attr_reader :ip
# The user agent of the browser from which the legal guardian accepted the service agreement.
sig { returns(T.nilable(String)) }
attr_reader :user_agent
end
# Details on the legal guardian's acceptance of the main Stripe service agreement.
sig { returns(T.nilable(Account)) }
attr_reader :account
end
class Address < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
class AddressKana < Stripe::StripeObject
# City/Ward.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Block/Building number.
sig { returns(T.nilable(String)) }
attr_reader :line1
# Building details.
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# Prefecture.
sig { returns(T.nilable(String)) }
attr_reader :state
# Town/cho-me.
sig { returns(T.nilable(String)) }
attr_reader :town
end
class AddressKanji < Stripe::StripeObject
# City/Ward.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Block/Building number.
sig { returns(T.nilable(String)) }
attr_reader :line1
# Building details.
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# Prefecture.
sig { returns(T.nilable(String)) }
attr_reader :state
# Town/cho-me.
sig { returns(T.nilable(String)) }
attr_reader :town
end
class Dob < Stripe::StripeObject
# The day of birth, between 1 and 31.
sig { returns(T.nilable(Integer)) }
attr_reader :day
# The month of birth, between 1 and 12.
sig { returns(T.nilable(Integer)) }
attr_reader :month
# The four-digit year of birth.
sig { returns(T.nilable(Integer)) }
attr_reader :year
end
class FutureRequirements < Stripe::StripeObject
class Alternative < Stripe::StripeObject
# Fields that can be provided to satisfy all fields in `original_fields_due`.
sig { returns(T::Array[String]) }
attr_reader :alternative_fields_due
# Fields that are due and can be satisfied by providing all fields in `alternative_fields_due`.
sig { returns(T::Array[String]) }
attr_reader :original_fields_due
end
class Error < Stripe::StripeObject
# The code for the type of error.
sig { returns(String) }
attr_reader :code
# An informative message that indicates the error type and provides additional details about the error.
sig { returns(String) }
attr_reader :reason
# The specific user onboarding requirement field (in the requirements hash) that needs to be resolved.
sig { returns(String) }
attr_reader :requirement
end
# Fields that are due and can be satisfied by providing the corresponding alternative fields instead.
sig { returns(T.nilable(T::Array[Alternative])) }
attr_reader :alternatives
# Fields that need to be collected to keep the person's account enabled. If not collected by the account's `future_requirements[current_deadline]`, these fields will transition to the main `requirements` hash, and may immediately become `past_due`, but the account may also be given a grace period depending on the account's enablement state prior to transition.
sig { returns(T::Array[String]) }
attr_reader :currently_due
# Fields that are `currently_due` and need to be collected again because validation or verification failed.
sig { returns(T::Array[Error]) }
attr_reader :errors
# Fields you must collect when all thresholds are reached. As they become required, they appear in `currently_due` as well, and the account's `future_requirements[current_deadline]` becomes set.
sig { returns(T::Array[String]) }
attr_reader :eventually_due
# Fields that weren't collected by the account's `requirements.current_deadline`. These fields need to be collected to enable the person's account. New fields will never appear here; `future_requirements.past_due` will always be a subset of `requirements.past_due`.
sig { returns(T::Array[String]) }
attr_reader :past_due
# Fields that might become required depending on the results of verification or review. It's an empty array unless an asynchronous verification is pending. If verification fails, these fields move to `eventually_due` or `currently_due`. Fields might appear in `eventually_due` or `currently_due` and in `pending_verification` if verification fails but another verification is still pending.
sig { returns(T::Array[String]) }
attr_reader :pending_verification
end
class RegisteredAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
class Relationship < Stripe::StripeObject
# Whether the person is the authorizer of the account's representative.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :authorizer
# Whether the person is a director of the account's legal entity. Directors are typically members of the governing board of the company, or responsible for ensuring the company meets its regulatory obligations.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :director
# Whether the person has significant responsibility to control, manage, or direct the organization.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :executive
# Whether the person is the legal guardian of the account's representative.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :legal_guardian
# Whether the person is an owner of the account’s legal entity.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :owner
# The percent owned by the person of the account's legal entity.
sig { returns(T.nilable(Float)) }
attr_reader :percent_ownership
# Whether the person is authorized as the primary representative of the account. This is the person nominated by the business to provide information about themselves, and general information about the account. There can only be one representative at any given time. At the time the account is created, this person should be set to the person responsible for opening the account.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :representative
# The person's title (e.g., CEO, Support Engineer).
sig { returns(T.nilable(String)) }
attr_reader :title
end
class Requirements < Stripe::StripeObject
class Alternative < Stripe::StripeObject
# Fields that can be provided to satisfy all fields in `original_fields_due`.
sig { returns(T::Array[String]) }
attr_reader :alternative_fields_due
# Fields that are due and can be satisfied by providing all fields in `alternative_fields_due`.
sig { returns(T::Array[String]) }
attr_reader :original_fields_due
end
class Error < Stripe::StripeObject
# The code for the type of error.
sig { returns(String) }
attr_reader :code
# An informative message that indicates the error type and provides additional details about the error.
sig { returns(String) }
attr_reader :reason
# The specific user onboarding requirement field (in the requirements hash) that needs to be resolved.
sig { returns(String) }
attr_reader :requirement
end
# Fields that are due and can be satisfied by providing the corresponding alternative fields instead.
sig { returns(T.nilable(T::Array[Alternative])) }
attr_reader :alternatives
# Fields that need to be collected to keep the person's account enabled. If not collected by the account's `current_deadline`, these fields appear in `past_due` as well, and the account is disabled.
sig { returns(T::Array[String]) }
attr_reader :currently_due
# Fields that are `currently_due` and need to be collected again because validation or verification failed.
sig { returns(T::Array[Error]) }
attr_reader :errors
# Fields you must collect when all thresholds are reached. As they become required, they appear in `currently_due` as well, and the account's `current_deadline` becomes set.
sig { returns(T::Array[String]) }
attr_reader :eventually_due
# Fields that weren't collected by the account's `current_deadline`. These fields need to be collected to enable the person's account.
sig { returns(T::Array[String]) }
attr_reader :past_due
# Fields that might become required depending on the results of verification or review. It's an empty array unless an asynchronous verification is pending. If verification fails, these fields move to `eventually_due`, `currently_due`, or `past_due`. Fields might appear in `eventually_due`, `currently_due`, or `past_due` and in `pending_verification` if verification fails but another verification is still pending.
sig { returns(T::Array[String]) }
attr_reader :pending_verification
end
class UsCfpbData < Stripe::StripeObject
class EthnicityDetails < Stripe::StripeObject
# The persons ethnicity
sig { returns(T.nilable(T::Array[String])) }
attr_reader :ethnicity
# Please specify your origin, when other is selected.
sig { returns(T.nilable(String)) }
attr_reader :ethnicity_other
end
class RaceDetails < Stripe::StripeObject
# The persons race.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :race
# Please specify your race, when other is selected.
sig { returns(T.nilable(String)) }
attr_reader :race_other
end
# The persons ethnicity details
sig { returns(T.nilable(EthnicityDetails)) }
attr_reader :ethnicity_details
# The persons race details
sig { returns(T.nilable(RaceDetails)) }
attr_reader :race_details
# The persons self-identified gender
sig { returns(T.nilable(String)) }
attr_reader :self_identified_gender
end
class Verification < Stripe::StripeObject
class AdditionalDocument < Stripe::StripeObject
# The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`.
sig { returns(T.nilable(T.any(String, Stripe::File))) }
attr_reader :back
# A user-displayable string describing the verification state of this document. For example, if a document is uploaded and the picture is too fuzzy, this may say "Identity document is too unclear to read".
sig { returns(T.nilable(String)) }
attr_reader :details
# One of `document_corrupt`, `document_country_not_supported`, `document_expired`, `document_failed_copy`, `document_failed_other`, `document_failed_test_mode`, `document_fraudulent`, `document_failed_greyscale`, `document_incomplete`, `document_invalid`, `document_manipulated`, `document_missing_back`, `document_missing_front`, `document_not_readable`, `document_not_uploaded`, `document_photo_mismatch`, `document_too_large`, or `document_type_not_supported`. A machine-readable code specifying the verification state for this document.
sig { returns(T.nilable(String)) }
attr_reader :details_code
# The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`.
sig { returns(T.nilable(T.any(String, Stripe::File))) }
attr_reader :front
end
class Document < Stripe::StripeObject
# The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`.
sig { returns(T.nilable(T.any(String, Stripe::File))) }
attr_reader :back
# A user-displayable string describing the verification state of this document. For example, if a document is uploaded and the picture is too fuzzy, this may say "Identity document is too unclear to read".
sig { returns(T.nilable(String)) }
attr_reader :details
# One of `document_corrupt`, `document_country_not_supported`, `document_expired`, `document_failed_copy`, `document_failed_other`, `document_failed_test_mode`, `document_fraudulent`, `document_failed_greyscale`, `document_incomplete`, `document_invalid`, `document_manipulated`, `document_missing_back`, `document_missing_front`, `document_not_readable`, `document_not_uploaded`, `document_photo_mismatch`, `document_too_large`, or `document_type_not_supported`. A machine-readable code specifying the verification state for this document.
sig { returns(T.nilable(String)) }
attr_reader :details_code
# The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`.
sig { returns(T.nilable(T.any(String, Stripe::File))) }
attr_reader :front
end
# A document showing address, either a passport, local ID card, or utility bill from a well-known utility company.
sig { returns(T.nilable(AdditionalDocument)) }
attr_reader :additional_document
# A user-displayable string describing the verification state for the person. For example, this may say "Provided identity information could not be verified".
sig { returns(T.nilable(String)) }
attr_reader :details
# One of `document_address_mismatch`, `document_dob_mismatch`, `document_duplicate_type`, `document_id_number_mismatch`, `document_name_mismatch`, `document_nationality_mismatch`, `failed_keyed_identity`, or `failed_other`. A machine-readable code specifying the verification state for the person.
sig { returns(T.nilable(String)) }
attr_reader :details_code
# Attribute for field document
sig { returns(Document) }
attr_reader :document
# The state of verification for the person. Possible values are `unverified`, `pending`, or `verified`. Please refer [guide](https://stripe.com/docs/connect/handling-api-verification) to handle verification updates.
sig { returns(String) }
attr_reader :status
end
# The account the person is associated with.
sig { returns(String) }
attr_reader :account
# Attribute for field additional_tos_acceptances
sig { returns(AdditionalTosAcceptances) }
attr_reader :additional_tos_acceptances
# Attribute for field address
sig { returns(Address) }
attr_reader :address
# The Kana variation of the person's address (Japan only).
sig { returns(T.nilable(AddressKana)) }
attr_reader :address_kana
# The Kanji variation of the person's address (Japan only).
sig { returns(T.nilable(AddressKanji)) }
attr_reader :address_kanji
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# Attribute for field dob
sig { returns(Dob) }
attr_reader :dob
# The person's email address. Also available for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `stripe`.
sig { returns(T.nilable(String)) }
attr_reader :email
# The person's first name. Also available for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `stripe`.
sig { returns(T.nilable(String)) }
attr_reader :first_name
# The Kana variation of the person's first name (Japan only). Also available for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `stripe`.
sig { returns(T.nilable(String)) }
attr_reader :first_name_kana
# The Kanji variation of the person's first name (Japan only). Also available for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `stripe`.
sig { returns(T.nilable(String)) }
attr_reader :first_name_kanji
# A list of alternate names or aliases that the person is known by. Also available for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `stripe`.
sig { returns(T::Array[String]) }
attr_reader :full_name_aliases
# Information about the [upcoming new requirements for this person](https://stripe.com/docs/connect/custom-accounts/future-requirements), including what information needs to be collected, and by when.
sig { returns(T.nilable(FutureRequirements)) }
attr_reader :future_requirements
# The person's gender.
sig { returns(T.nilable(String)) }
attr_reader :gender
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Whether the person's `id_number` was provided. True if either the full ID number was provided or if only the required part of the ID number was provided (ex. last four of an individual's SSN for the US indicated by `ssn_last_4_provided`).
sig { returns(T::Boolean) }
attr_reader :id_number_provided
# Whether the person's `id_number_secondary` was provided.
sig { returns(T::Boolean) }
attr_reader :id_number_secondary_provided
# The person's last name. Also available for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `stripe`.
sig { returns(T.nilable(String)) }
attr_reader :last_name
# The Kana variation of the person's last name (Japan only). Also available for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `stripe`.
sig { returns(T.nilable(String)) }
attr_reader :last_name_kana
# The Kanji variation of the person's last name (Japan only). Also available for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `stripe`.
sig { returns(T.nilable(String)) }
attr_reader :last_name_kanji
# The person's maiden name.
sig { returns(T.nilable(String)) }
attr_reader :maiden_name
# 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.
sig { returns(T::Hash[String, String]) }
attr_reader :metadata
# The country where the person is a national.
sig { returns(T.nilable(String)) }
attr_reader :nationality
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The person's phone number.
sig { returns(T.nilable(String)) }
attr_reader :phone
# Indicates if the person or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction.
sig { returns(String) }
attr_reader :political_exposure
# Attribute for field registered_address
sig { returns(RegisteredAddress) }
attr_reader :registered_address
# Attribute for field relationship
sig { returns(Relationship) }
attr_reader :relationship
# Information about the requirements for this person, including what information needs to be collected, and by when.
sig { returns(T.nilable(Requirements)) }
attr_reader :requirements
# Whether the last four digits of the person's Social Security number have been provided (U.S. only).
sig { returns(T::Boolean) }
attr_reader :ssn_last_4_provided
# Demographic data related to the person.
sig { returns(T.nilable(UsCfpbData)) }
attr_reader :us_cfpb_data
# Attribute for field verification
sig { returns(Verification) }
attr_reader :verification
# Always true for a deleted object
sig { returns(T::Boolean) }
attr_reader :deleted
end
end
# typed: true
module Stripe
# You can now model subscriptions more flexibly using the [Prices API](https://stripe.com/docs/api#prices). It replaces the Plans API and is backwards compatible to simplify your migration.
#
# Plans define the base price, currency, and billing cycle for recurring purchases of products.
# [Products](https://stripe.com/docs/api#products) help you track inventory or provisioning, and plans help you track pricing. Different physical goods or levels of service should be represented by products, and pricing options should be represented by plans. This approach lets you change prices without having to change your provisioning scheme.
#
# For example, you might have a single "gold" product that has plans for $10/month, $100/year, €9/month, and €90/year.
#
# Related guides: [Set up a subscription](https://stripe.com/docs/billing/subscriptions/set-up-subscription) and more about [products and prices](https://stripe.com/docs/products-prices/overview).
class Plan < APIResource
class Tier < Stripe::StripeObject
# Price for the entire tier.
sig { returns(T.nilable(Integer)) }
attr_reader :flat_amount
# Same as `flat_amount`, but contains a decimal value with at most 12 decimal places.
sig { returns(T.nilable(String)) }
attr_reader :flat_amount_decimal
# Per unit price for units relevant to the tier.
sig { returns(T.nilable(Integer)) }
attr_reader :unit_amount
# Same as `unit_amount`, but contains a decimal value with at most 12 decimal places.
sig { returns(T.nilable(String)) }
attr_reader :unit_amount_decimal
# Up to and including to this quantity will be contained in the tier.
sig { returns(T.nilable(Integer)) }
attr_reader :up_to
end
class TransformUsage < Stripe::StripeObject
# Divide usage by this number.
sig { returns(Integer) }
attr_reader :divide_by
# After division, either round the result `up` or `down`.
sig { returns(String) }
attr_reader :round
end
# Whether the plan can be used for new purchases.
sig { returns(T::Boolean) }
attr_reader :active
# The unit amount in cents (or local equivalent) to be charged, represented as a whole integer if possible. Only set if `billing_scheme=per_unit`.
sig { returns(T.nilable(Integer)) }
attr_reader :amount
# The unit amount in cents (or local equivalent) to be charged, represented as a decimal string with at most 12 decimal places. Only set if `billing_scheme=per_unit`.
sig { returns(T.nilable(String)) }
attr_reader :amount_decimal
# Describes how to compute the price per period. Either `per_unit` or `tiered`. `per_unit` indicates that the fixed amount (specified in `amount`) will be charged per unit in `quantity` (for plans with `usage_type=licensed`), or per unit of total usage (for plans with `usage_type=metered`). `tiered` indicates that the unit pricing will be computed using a tiering strategy as defined using the `tiers` and `tiers_mode` attributes.
sig { returns(String) }
attr_reader :billing_scheme
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# 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).
sig { returns(String) }
attr_reader :currency
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# The frequency at which a subscription is billed. One of `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_reader :interval
# The number of intervals (specified in the `interval` attribute) between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months.
sig { returns(Integer) }
attr_reader :interval_count
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# 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.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# The meter tracking the usage of a metered price
sig { returns(T.nilable(String)) }
attr_reader :meter
# A brief description of the plan, hidden from customers.
sig { returns(T.nilable(String)) }
attr_reader :nickname
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The product whose pricing this plan determines.
sig { returns(T.nilable(T.any(String, Stripe::Product))) }
attr_reader :product
# Each element represents a pricing tier. This parameter requires `billing_scheme` to be set to `tiered`. See also the documentation for `billing_scheme`.
sig { returns(T::Array[Tier]) }
attr_reader :tiers
# Defines if the tiering price should be `graduated` or `volume` based. In `volume`-based tiering, the maximum quantity within a period determines the per unit price. In `graduated` tiering, pricing can change as the quantity grows.
sig { returns(T.nilable(String)) }
attr_reader :tiers_mode
# Apply a transformation to the reported usage or set quantity before computing the amount billed. Cannot be combined with `tiers`.
sig { returns(T.nilable(TransformUsage)) }
attr_reader :transform_usage
# Default number of trial days when subscribing a customer to this plan using [`trial_from_plan=true`](https://stripe.com/docs/api#create_subscription-trial_from_plan).
sig { returns(T.nilable(Integer)) }
attr_reader :trial_period_days
# Configures how the quantity per period should be determined. Can be either `metered` or `licensed`. `licensed` automatically bills the `quantity` set when adding it to a subscription. `metered` aggregates the total usage based on usage records. Defaults to `licensed`.
sig { returns(String) }
attr_reader :usage_type
# Always true for a deleted object
sig { returns(T::Boolean) }
attr_reader :deleted
class DeleteParams < Stripe::RequestParams; end
class UpdateParams < Stripe::RequestParams
# Whether the plan is currently available for new subscriptions.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# A brief description of the plan, hidden from customers.
sig { returns(T.nilable(String)) }
attr_accessor :nickname
# The product the plan belongs to. This cannot be changed once it has been used in a subscription or subscription schedule.
sig { returns(T.nilable(String)) }
attr_accessor :product
# Default number of trial days when subscribing a customer to this plan using [`trial_from_plan=true`](https://stripe.com/docs/api#create_subscription-trial_from_plan).
sig { returns(T.nilable(Integer)) }
attr_accessor :trial_period_days
sig {
params(active: T.nilable(T::Boolean), expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), nickname: T.nilable(String), product: T.nilable(String), trial_period_days: T.nilable(Integer)).void
}
def initialize(
active: nil,
expand: nil,
metadata: nil,
nickname: nil,
product: nil,
trial_period_days: nil
); end
end
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return plans that are active or inactive (e.g., pass `false` to list all inactive plans).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.
sig { returns(T.nilable(T.any(::Stripe::Plan::ListParams::Created, Integer))) }
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Only return plans for the given product.
sig { returns(T.nilable(String)) }
attr_accessor :product
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(active: T.nilable(T::Boolean), created: T.nilable(T.any(::Stripe::Plan::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), product: T.nilable(String), starting_after: T.nilable(String)).void
}
def initialize(
active: nil,
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
product: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class Product < Stripe::RequestParams
# Whether the product is currently available for purchase. Defaults to `true`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# The identifier for the product. Must be unique. If not provided, an identifier will be randomly generated.
sig { returns(T.nilable(String)) }
attr_accessor :id
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The product's name, meant to be displayable to the customer.
sig { returns(String) }
attr_accessor :name
# An arbitrary string to be displayed on your customer's credit card or bank statement. While most banks display this information consistently, some may display it incorrectly or not at all.
#
# This may be up to 22 characters. The statement description may not include `<`, `>`, `\`, `"`, `'` characters, and will appear on your customer's statement in capital letters. Non-ASCII characters are automatically stripped.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
sig { returns(T.nilable(String)) }
attr_accessor :tax_code
# A label that represents units of this product. When set, this will be included in customers' receipts, invoices, Checkout, and the customer portal.
sig { returns(T.nilable(String)) }
attr_accessor :unit_label
sig {
params(active: T.nilable(T::Boolean), id: T.nilable(String), metadata: T.nilable(T::Hash[String, String]), name: String, statement_descriptor: T.nilable(String), tax_code: T.nilable(String), unit_label: T.nilable(String)).void
}
def initialize(
active: nil,
id: nil,
metadata: nil,
name: nil,
statement_descriptor: nil,
tax_code: nil,
unit_label: nil
); end
end
class Tier < Stripe::RequestParams
# The flat billing amount for an entire tier, regardless of the number of units in the tier.
sig { returns(T.nilable(Integer)) }
attr_accessor :flat_amount
# Same as `flat_amount`, but accepts a decimal value representing an integer in the minor units of the currency. Only one of `flat_amount` and `flat_amount_decimal` can be set.
sig { returns(T.nilable(String)) }
attr_accessor :flat_amount_decimal
# The per unit billing amount for each individual unit for which this tier applies.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
# Specifies the upper bound of this tier. The lower bound of a tier is the upper bound of the previous tier adding one. Use `inf` to define a fallback tier.
sig { returns(T.any(String, Integer)) }
attr_accessor :up_to
sig {
params(flat_amount: T.nilable(Integer), flat_amount_decimal: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String), up_to: T.any(String, Integer)).void
}
def initialize(
flat_amount: nil,
flat_amount_decimal: nil,
unit_amount: nil,
unit_amount_decimal: nil,
up_to: nil
); end
end
class TransformUsage < Stripe::RequestParams
# Divide usage by this number.
sig { returns(Integer) }
attr_accessor :divide_by
# After division, either round the result `up` or `down`.
sig { returns(String) }
attr_accessor :round
sig { params(divide_by: Integer, round: String).void }
def initialize(divide_by: nil, round: nil); end
end
# Whether the plan is currently available for new subscriptions. Defaults to `true`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# A positive integer in cents (or local equivalent) (or 0 for a free plan) representing how much to charge on a recurring basis.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# Same as `amount`, but accepts a decimal value with at most 12 decimal places. Only one of `amount` and `amount_decimal` can be set.
sig { returns(T.nilable(String)) }
attr_accessor :amount_decimal
# Describes how to compute the price per period. Either `per_unit` or `tiered`. `per_unit` indicates that the fixed amount (specified in `amount`) will be charged per unit in `quantity` (for plans with `usage_type=licensed`), or per unit of total usage (for plans with `usage_type=metered`). `tiered` indicates that the unit pricing will be computed using a tiering strategy as defined using the `tiers` and `tiers_mode` attributes.
sig { returns(T.nilable(String)) }
attr_accessor :billing_scheme
# 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).
sig { returns(String) }
attr_accessor :currency
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# An identifier randomly generated by Stripe. Used to identify this plan when subscribing a customer. You can optionally override this ID, but the ID must be unique across all plans in your Stripe account. You can, however, use the same plan ID in both live and test modes.
sig { returns(T.nilable(String)) }
attr_accessor :id
# Specifies billing frequency. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_count
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# The meter tracking the usage of a metered price
sig { returns(T.nilable(String)) }
attr_accessor :meter
# A brief description of the plan, hidden from customers.
sig { returns(T.nilable(String)) }
attr_accessor :nickname
# Attribute for param field product
sig { returns(T.nilable(T.any(::Stripe::Plan::CreateParams::Product, String))) }
attr_accessor :product
# Each element represents a pricing tier. This parameter requires `billing_scheme` to be set to `tiered`. See also the documentation for `billing_scheme`.
sig { returns(T.nilable(T::Array[::Stripe::Plan::CreateParams::Tier])) }
attr_accessor :tiers
# Defines if the tiering price should be `graduated` or `volume` based. In `volume`-based tiering, the maximum quantity within a period determines the per unit price, in `graduated` tiering pricing can successively change as the quantity grows.
sig { returns(T.nilable(String)) }
attr_accessor :tiers_mode
# Apply a transformation to the reported usage or set quantity before computing the billed price. Cannot be combined with `tiers`.
sig { returns(T.nilable(::Stripe::Plan::CreateParams::TransformUsage)) }
attr_accessor :transform_usage
# Default number of trial days when subscribing a customer to this plan using [`trial_from_plan=true`](https://stripe.com/docs/api#create_subscription-trial_from_plan).
sig { returns(T.nilable(Integer)) }
attr_accessor :trial_period_days
# Configures how the quantity per period should be determined. Can be either `metered` or `licensed`. `licensed` automatically bills the `quantity` set when adding it to a subscription. `metered` aggregates the total usage based on usage records. Defaults to `licensed`.
sig { returns(T.nilable(String)) }
attr_accessor :usage_type
sig {
params(active: T.nilable(T::Boolean), amount: T.nilable(Integer), amount_decimal: T.nilable(String), billing_scheme: T.nilable(String), currency: String, expand: T.nilable(T::Array[String]), id: T.nilable(String), interval: String, interval_count: T.nilable(Integer), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), meter: T.nilable(String), nickname: T.nilable(String), product: T.nilable(T.any(::Stripe::Plan::CreateParams::Product, String)), tiers: T.nilable(T::Array[::Stripe::Plan::CreateParams::Tier]), tiers_mode: T.nilable(String), transform_usage: T.nilable(::Stripe::Plan::CreateParams::TransformUsage), trial_period_days: T.nilable(Integer), usage_type: T.nilable(String)).void
}
def initialize(
active: nil,
amount: nil,
amount_decimal: nil,
billing_scheme: nil,
currency: nil,
expand: nil,
id: nil,
interval: nil,
interval_count: nil,
metadata: nil,
meter: nil,
nickname: nil,
product: nil,
tiers: nil,
tiers_mode: nil,
transform_usage: nil,
trial_period_days: nil,
usage_type: nil
); end
end
# You can now model subscriptions more flexibly using the [Prices API](https://docs.stripe.com/api#prices). It replaces the Plans API and is backwards compatible to simplify your migration.
sig {
params(params: T.any(::Stripe::Plan::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Plan)
}
def self.create(params = {}, opts = {}); end
# Deleting plans means new subscribers can't be added. Existing subscribers aren't affected.
sig {
params(plan: String, params: T.any(::Stripe::Plan::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Plan)
}
def self.delete(plan, params = {}, opts = {}); end
# Deleting plans means new subscribers can't be added. Existing subscribers aren't affected.
sig {
params(params: T.any(::Stripe::Plan::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Plan)
}
def delete(params = {}, opts = {}); end
# Returns a list of your plans.
sig {
params(params: T.any(::Stripe::Plan::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Updates the specified plan by setting the values of the parameters passed. Any parameters not provided are left unchanged. By design, you cannot change a plan's ID, amount, currency, or billing cycle.
sig {
params(plan: String, params: T.any(::Stripe::Plan::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Plan)
}
def self.update(plan, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
# Prices define the unit cost, currency, and (optional) billing cycle for both recurring and one-time purchases of products.
# [Products](https://stripe.com/docs/api#products) help you track inventory or provisioning, and prices help you track payment terms. Different physical goods or levels of service should be represented by products, and pricing options should be represented by prices. This approach lets you change prices without having to change your provisioning scheme.
#
# For example, you might have a single "gold" product that has prices for $10/month, $100/year, and €9 once.
#
# Related guides: [Set up a subscription](https://stripe.com/docs/billing/subscriptions/set-up-subscription), [create an invoice](https://stripe.com/docs/billing/invoices/create), and more about [products and prices](https://stripe.com/docs/products-prices/overview).
class Price < APIResource
class CurrencyOptions < Stripe::StripeObject
class CustomUnitAmount < Stripe::StripeObject
# The maximum unit amount the customer can specify for this item.
sig { returns(T.nilable(Integer)) }
attr_reader :maximum
# The minimum unit amount the customer can specify for this item. Must be at least the minimum charge amount.
sig { returns(T.nilable(Integer)) }
attr_reader :minimum
# The starting unit amount which can be updated by the customer.
sig { returns(T.nilable(Integer)) }
attr_reader :preset
end
class Tier < Stripe::StripeObject
# Price for the entire tier.
sig { returns(T.nilable(Integer)) }
attr_reader :flat_amount
# Same as `flat_amount`, but contains a decimal value with at most 12 decimal places.
sig { returns(T.nilable(String)) }
attr_reader :flat_amount_decimal
# Per unit price for units relevant to the tier.
sig { returns(T.nilable(Integer)) }
attr_reader :unit_amount
# Same as `unit_amount`, but contains a decimal value with at most 12 decimal places.
sig { returns(T.nilable(String)) }
attr_reader :unit_amount_decimal
# Up to and including to this quantity will be contained in the tier.
sig { returns(T.nilable(Integer)) }
attr_reader :up_to
end
# When set, provides configuration for the amount to be adjusted by the customer during Checkout Sessions and Payment Links.
sig { returns(T.nilable(CustomUnitAmount)) }
attr_reader :custom_unit_amount
# 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.
sig { returns(T.nilable(String)) }
attr_reader :tax_behavior
# Each element represents a pricing tier. This parameter requires `billing_scheme` to be set to `tiered`. See also the documentation for `billing_scheme`.
sig { returns(T::Array[Tier]) }
attr_reader :tiers
# The unit amount in cents (or local equivalent) to be charged, represented as a whole integer if possible. Only set if `billing_scheme=per_unit`.
sig { returns(T.nilable(Integer)) }
attr_reader :unit_amount
# The unit amount in cents (or local equivalent) to be charged, represented as a decimal string with at most 12 decimal places. Only set if `billing_scheme=per_unit`.
sig { returns(T.nilable(String)) }
attr_reader :unit_amount_decimal
end
class CustomUnitAmount < Stripe::StripeObject
# The maximum unit amount the customer can specify for this item.
sig { returns(T.nilable(Integer)) }
attr_reader :maximum
# The minimum unit amount the customer can specify for this item. Must be at least the minimum charge amount.
sig { returns(T.nilable(Integer)) }
attr_reader :minimum
# The starting unit amount which can be updated by the customer.
sig { returns(T.nilable(Integer)) }
attr_reader :preset
end
class MigrateTo < Stripe::StripeObject
# The behavior controlling at what point in the subscription lifecycle to migrate the price
sig { returns(String) }
attr_reader :behavior
# The unix timestamp after at which subscriptions will start to migrate to the new price.
sig { returns(Integer) }
attr_reader :effective_after
# The id of the price being migrated to
sig { returns(String) }
attr_reader :price
end
class Recurring < Stripe::StripeObject
# The frequency at which a subscription is billed. One of `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_reader :interval
# The number of intervals (specified in the `interval` attribute) between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months.
sig { returns(Integer) }
attr_reader :interval_count
# The meter tracking the usage of a metered price
sig { returns(T.nilable(String)) }
attr_reader :meter
# Default number of trial days when subscribing a customer to this price using [`trial_from_plan=true`](https://stripe.com/docs/api#create_subscription-trial_from_plan).
sig { returns(T.nilable(Integer)) }
attr_reader :trial_period_days
# Configures how the quantity per period should be determined. Can be either `metered` or `licensed`. `licensed` automatically bills the `quantity` set when adding it to a subscription. `metered` aggregates the total usage based on usage records. Defaults to `licensed`.
sig { returns(String) }
attr_reader :usage_type
end
class Tier < Stripe::StripeObject
# Price for the entire tier.
sig { returns(T.nilable(Integer)) }
attr_reader :flat_amount
# Same as `flat_amount`, but contains a decimal value with at most 12 decimal places.
sig { returns(T.nilable(String)) }
attr_reader :flat_amount_decimal
# Per unit price for units relevant to the tier.
sig { returns(T.nilable(Integer)) }
attr_reader :unit_amount
# Same as `unit_amount`, but contains a decimal value with at most 12 decimal places.
sig { returns(T.nilable(String)) }
attr_reader :unit_amount_decimal
# Up to and including to this quantity will be contained in the tier.
sig { returns(T.nilable(Integer)) }
attr_reader :up_to
end
class TransformQuantity < Stripe::StripeObject
# Divide usage by this number.
sig { returns(Integer) }
attr_reader :divide_by
# After division, either round the result `up` or `down`.
sig { returns(String) }
attr_reader :round
end
# Whether the price can be used for new purchases.
sig { returns(T::Boolean) }
attr_reader :active
# Describes how to compute the price per period. Either `per_unit` or `tiered`. `per_unit` indicates that the fixed amount (specified in `unit_amount` or `unit_amount_decimal`) will be charged per unit in `quantity` (for prices with `usage_type=licensed`), or per unit of total usage (for prices with `usage_type=metered`). `tiered` indicates that the unit pricing will be computed using a tiering strategy as defined using the `tiers` and `tiers_mode` attributes.
sig { returns(String) }
attr_reader :billing_scheme
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# 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).
sig { returns(String) }
attr_reader :currency
# Prices defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
sig { returns(T::Hash[String, CurrencyOptions]) }
attr_reader :currency_options
# When set, provides configuration for the amount to be adjusted by the customer during Checkout Sessions and Payment Links.
sig { returns(T.nilable(CustomUnitAmount)) }
attr_reader :custom_unit_amount
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# A lookup key used to retrieve prices dynamically from a static string. This may be up to 200 characters.
sig { returns(T.nilable(String)) }
attr_reader :lookup_key
# 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.
sig { returns(T::Hash[String, String]) }
attr_reader :metadata
# Subscriptions using this price will be migrated to use the new referenced price.
sig { returns(T.nilable(MigrateTo)) }
attr_reader :migrate_to
# A brief description of the price, hidden from customers.
sig { returns(T.nilable(String)) }
attr_reader :nickname
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The ID of the product this price is associated with.
sig { returns(T.any(String, Stripe::Product)) }
attr_reader :product
# The recurring components of a price such as `interval` and `usage_type`.
sig { returns(T.nilable(Recurring)) }
attr_reader :recurring
# 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.
sig { returns(T.nilable(String)) }
attr_reader :tax_behavior
# Each element represents a pricing tier. This parameter requires `billing_scheme` to be set to `tiered`. See also the documentation for `billing_scheme`.
sig { returns(T::Array[Tier]) }
attr_reader :tiers
# Defines if the tiering price should be `graduated` or `volume` based. In `volume`-based tiering, the maximum quantity within a period determines the per unit price. In `graduated` tiering, pricing can change as the quantity grows.
sig { returns(T.nilable(String)) }
attr_reader :tiers_mode
# Apply a transformation to the reported usage or set quantity before computing the amount billed. Cannot be combined with `tiers`.
sig { returns(T.nilable(TransformQuantity)) }
attr_reader :transform_quantity
# One of `one_time` or `recurring` depending on whether the price is for a one-time purchase or a recurring (subscription) purchase.
sig { returns(String) }
attr_reader :type
# The unit amount in cents (or local equivalent) to be charged, represented as a whole integer if possible. Only set if `billing_scheme=per_unit`.
sig { returns(T.nilable(Integer)) }
attr_reader :unit_amount
# The unit amount in cents (or local equivalent) to be charged, represented as a decimal string with at most 12 decimal places. Only set if `billing_scheme=per_unit`.
sig { returns(T.nilable(String)) }
attr_reader :unit_amount_decimal
# Always true for a deleted object
sig { returns(T::Boolean) }
attr_reader :deleted
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
class Recurring < Stripe::RequestParams
# Filter by billing frequency. Either `day`, `week`, `month` or `year`.
sig { returns(T.nilable(String)) }
attr_accessor :interval
# Filter by the price's meter.
sig { returns(T.nilable(String)) }
attr_accessor :meter
# Filter by the usage type for this price. Can be either `metered` or `licensed`.
sig { returns(T.nilable(String)) }
attr_accessor :usage_type
sig {
params(interval: T.nilable(String), meter: T.nilable(String), usage_type: T.nilable(String)).void
}
def initialize(interval: nil, meter: nil, usage_type: nil); end
end
# Only return prices that are active or inactive (e.g., pass `false` to list all inactive prices).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.
sig { returns(T.nilable(T.any(::Stripe::Price::ListParams::Created, Integer))) }
attr_accessor :created
# Only return prices for the given currency.
sig { returns(T.nilable(String)) }
attr_accessor :currency
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Only return the price with these lookup_keys, if any exist. You can specify up to 10 lookup_keys.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :lookup_keys
# Only return prices for the given product.
sig { returns(T.nilable(String)) }
attr_accessor :product
# Only return prices with these recurring fields.
sig { returns(T.nilable(::Stripe::Price::ListParams::Recurring)) }
attr_accessor :recurring
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return prices of type `recurring` or `one_time`.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(active: T.nilable(T::Boolean), created: T.nilable(T.any(::Stripe::Price::ListParams::Created, Integer)), currency: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), lookup_keys: T.nilable(T::Array[String]), product: T.nilable(String), recurring: T.nilable(::Stripe::Price::ListParams::Recurring), starting_after: T.nilable(String), type: T.nilable(String)).void
}
def initialize(
active: nil,
created: nil,
currency: nil,
ending_before: nil,
expand: nil,
limit: nil,
lookup_keys: nil,
product: nil,
recurring: nil,
starting_after: nil,
type: nil
); end
end
class CreateParams < Stripe::RequestParams
class CurrencyOptions < Stripe::RequestParams
class CustomUnitAmount < Stripe::RequestParams
# Pass in `true` to enable `custom_unit_amount`, otherwise omit `custom_unit_amount`.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The maximum unit amount the customer can specify for this item.
sig { returns(T.nilable(Integer)) }
attr_accessor :maximum
# The minimum unit amount the customer can specify for this item. Must be at least the minimum charge amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :minimum
# The starting unit amount which can be updated by the customer.
sig { returns(T.nilable(Integer)) }
attr_accessor :preset
sig {
params(enabled: T::Boolean, maximum: T.nilable(Integer), minimum: T.nilable(Integer), preset: T.nilable(Integer)).void
}
def initialize(enabled: nil, maximum: nil, minimum: nil, preset: nil); end
end
class Tier < Stripe::RequestParams
# The flat billing amount for an entire tier, regardless of the number of units in the tier.
sig { returns(T.nilable(Integer)) }
attr_accessor :flat_amount
# Same as `flat_amount`, but accepts a decimal value representing an integer in the minor units of the currency. Only one of `flat_amount` and `flat_amount_decimal` can be set.
sig { returns(T.nilable(String)) }
attr_accessor :flat_amount_decimal
# The per unit billing amount for each individual unit for which this tier applies.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
# Specifies the upper bound of this tier. The lower bound of a tier is the upper bound of the previous tier adding one. Use `inf` to define a fallback tier.
sig { returns(T.any(String, Integer)) }
attr_accessor :up_to
sig {
params(flat_amount: T.nilable(Integer), flat_amount_decimal: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String), up_to: T.any(String, Integer)).void
}
def initialize(
flat_amount: nil,
flat_amount_decimal: nil,
unit_amount: nil,
unit_amount_decimal: nil,
up_to: nil
); end
end
# When set, provides configuration for the amount to be adjusted by the customer during Checkout Sessions and Payment Links.
sig { returns(T.nilable(::Stripe::Price::CreateParams::CurrencyOptions::CustomUnitAmount)) }
attr_accessor :custom_unit_amount
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# Each element represents a pricing tier. This parameter requires `billing_scheme` to be set to `tiered`. See also the documentation for `billing_scheme`.
sig { returns(T.nilable(T::Array[::Stripe::Price::CreateParams::CurrencyOptions::Tier])) }
attr_accessor :tiers
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(custom_unit_amount: T.nilable(::Stripe::Price::CreateParams::CurrencyOptions::CustomUnitAmount), tax_behavior: T.nilable(String), tiers: T.nilable(T::Array[::Stripe::Price::CreateParams::CurrencyOptions::Tier]), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
custom_unit_amount: nil,
tax_behavior: nil,
tiers: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
class CustomUnitAmount < Stripe::RequestParams
# Pass in `true` to enable `custom_unit_amount`, otherwise omit `custom_unit_amount`.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The maximum unit amount the customer can specify for this item.
sig { returns(T.nilable(Integer)) }
attr_accessor :maximum
# The minimum unit amount the customer can specify for this item. Must be at least the minimum charge amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :minimum
# The starting unit amount which can be updated by the customer.
sig { returns(T.nilable(Integer)) }
attr_accessor :preset
sig {
params(enabled: T::Boolean, maximum: T.nilable(Integer), minimum: T.nilable(Integer), preset: T.nilable(Integer)).void
}
def initialize(enabled: nil, maximum: nil, minimum: nil, preset: nil); end
end
class ProductData < Stripe::RequestParams
# Whether the product is currently available for purchase. Defaults to `true`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# The identifier for the product. Must be unique. If not provided, an identifier will be randomly generated.
sig { returns(T.nilable(String)) }
attr_accessor :id
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The product's name, meant to be displayable to the customer.
sig { returns(String) }
attr_accessor :name
# An arbitrary string to be displayed on your customer's credit card or bank statement. While most banks display this information consistently, some may display it incorrectly or not at all.
#
# This may be up to 22 characters. The statement description may not include `<`, `>`, `\`, `"`, `'` characters, and will appear on your customer's statement in capital letters. Non-ASCII characters are automatically stripped.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
sig { returns(T.nilable(String)) }
attr_accessor :tax_code
# A label that represents units of this product. When set, this will be included in customers' receipts, invoices, Checkout, and the customer portal.
sig { returns(T.nilable(String)) }
attr_accessor :unit_label
sig {
params(active: T.nilable(T::Boolean), id: T.nilable(String), metadata: T.nilable(T::Hash[String, String]), name: String, statement_descriptor: T.nilable(String), tax_code: T.nilable(String), unit_label: T.nilable(String)).void
}
def initialize(
active: nil,
id: nil,
metadata: nil,
name: nil,
statement_descriptor: nil,
tax_code: nil,
unit_label: nil
); end
end
class Recurring < Stripe::RequestParams
# Specifies billing frequency. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_count
# The meter tracking the usage of a metered price
sig { returns(T.nilable(String)) }
attr_accessor :meter
# Default number of trial days when subscribing a customer to this price using [`trial_from_plan=true`](https://stripe.com/docs/api#create_subscription-trial_from_plan).
sig { returns(T.nilable(Integer)) }
attr_accessor :trial_period_days
# Configures how the quantity per period should be determined. Can be either `metered` or `licensed`. `licensed` automatically bills the `quantity` set when adding it to a subscription. `metered` aggregates the total usage based on usage records. Defaults to `licensed`.
sig { returns(T.nilable(String)) }
attr_accessor :usage_type
sig {
params(interval: String, interval_count: T.nilable(Integer), meter: T.nilable(String), trial_period_days: T.nilable(Integer), usage_type: T.nilable(String)).void
}
def initialize(
interval: nil,
interval_count: nil,
meter: nil,
trial_period_days: nil,
usage_type: nil
); end
end
class Tier < Stripe::RequestParams
# The flat billing amount for an entire tier, regardless of the number of units in the tier.
sig { returns(T.nilable(Integer)) }
attr_accessor :flat_amount
# Same as `flat_amount`, but accepts a decimal value representing an integer in the minor units of the currency. Only one of `flat_amount` and `flat_amount_decimal` can be set.
sig { returns(T.nilable(String)) }
attr_accessor :flat_amount_decimal
# The per unit billing amount for each individual unit for which this tier applies.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
# Specifies the upper bound of this tier. The lower bound of a tier is the upper bound of the previous tier adding one. Use `inf` to define a fallback tier.
sig { returns(T.any(String, Integer)) }
attr_accessor :up_to
sig {
params(flat_amount: T.nilable(Integer), flat_amount_decimal: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String), up_to: T.any(String, Integer)).void
}
def initialize(
flat_amount: nil,
flat_amount_decimal: nil,
unit_amount: nil,
unit_amount_decimal: nil,
up_to: nil
); end
end
class TransformQuantity < Stripe::RequestParams
# Divide usage by this number.
sig { returns(Integer) }
attr_accessor :divide_by
# After division, either round the result `up` or `down`.
sig { returns(String) }
attr_accessor :round
sig { params(divide_by: Integer, round: String).void }
def initialize(divide_by: nil, round: nil); end
end
# Whether the price can be used for new purchases. Defaults to `true`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# Describes how to compute the price per period. Either `per_unit` or `tiered`. `per_unit` indicates that the fixed amount (specified in `unit_amount` or `unit_amount_decimal`) will be charged per unit in `quantity` (for prices with `usage_type=licensed`), or per unit of total usage (for prices with `usage_type=metered`). `tiered` indicates that the unit pricing will be computed using a tiering strategy as defined using the `tiers` and `tiers_mode` attributes.
sig { returns(T.nilable(String)) }
attr_accessor :billing_scheme
# 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).
sig { returns(String) }
attr_accessor :currency
# Prices defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
sig { returns(T.nilable(T::Hash[String, ::Stripe::Price::CreateParams::CurrencyOptions])) }
attr_accessor :currency_options
# When set, provides configuration for the amount to be adjusted by the customer during Checkout Sessions and Payment Links.
sig { returns(T.nilable(::Stripe::Price::CreateParams::CustomUnitAmount)) }
attr_accessor :custom_unit_amount
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A lookup key used to retrieve prices dynamically from a static string. This may be up to 200 characters.
sig { returns(T.nilable(String)) }
attr_accessor :lookup_key
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# A brief description of the price, hidden from customers.
sig { returns(T.nilable(String)) }
attr_accessor :nickname
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
sig { returns(T.nilable(String)) }
attr_accessor :product
# These fields can be used to create a new product that this price will belong to.
sig { returns(T.nilable(::Stripe::Price::CreateParams::ProductData)) }
attr_accessor :product_data
# The recurring components of a price such as `interval` and `usage_type`.
sig { returns(T.nilable(::Stripe::Price::CreateParams::Recurring)) }
attr_accessor :recurring
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# Each element represents a pricing tier. This parameter requires `billing_scheme` to be set to `tiered`. See also the documentation for `billing_scheme`.
sig { returns(T.nilable(T::Array[::Stripe::Price::CreateParams::Tier])) }
attr_accessor :tiers
# Defines if the tiering price should be `graduated` or `volume` based. In `volume`-based tiering, the maximum quantity within a period determines the per unit price, in `graduated` tiering pricing can successively change as the quantity grows.
sig { returns(T.nilable(String)) }
attr_accessor :tiers_mode
# If set to true, will atomically remove the lookup key from the existing price, and assign it to this price.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :transfer_lookup_key
# Apply a transformation to the reported usage or set quantity before computing the billed price. Cannot be combined with `tiers`.
sig { returns(T.nilable(::Stripe::Price::CreateParams::TransformQuantity)) }
attr_accessor :transform_quantity
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge. One of `unit_amount`, `unit_amount_decimal`, or `custom_unit_amount` is required, unless `billing_scheme=tiered`.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(active: T.nilable(T::Boolean), billing_scheme: T.nilable(String), currency: String, currency_options: T.nilable(T::Hash[String, ::Stripe::Price::CreateParams::CurrencyOptions]), custom_unit_amount: T.nilable(::Stripe::Price::CreateParams::CustomUnitAmount), expand: T.nilable(T::Array[String]), lookup_key: T.nilable(String), metadata: T.nilable(T::Hash[String, String]), nickname: T.nilable(String), product: T.nilable(String), product_data: T.nilable(::Stripe::Price::CreateParams::ProductData), recurring: T.nilable(::Stripe::Price::CreateParams::Recurring), tax_behavior: T.nilable(String), tiers: T.nilable(T::Array[::Stripe::Price::CreateParams::Tier]), tiers_mode: T.nilable(String), transfer_lookup_key: T.nilable(T::Boolean), transform_quantity: T.nilable(::Stripe::Price::CreateParams::TransformQuantity), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
active: nil,
billing_scheme: nil,
currency: nil,
currency_options: nil,
custom_unit_amount: nil,
expand: nil,
lookup_key: nil,
metadata: nil,
nickname: nil,
product: nil,
product_data: nil,
recurring: nil,
tax_behavior: nil,
tiers: nil,
tiers_mode: nil,
transfer_lookup_key: nil,
transform_quantity: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
class UpdateParams < Stripe::RequestParams
class CurrencyOptions < Stripe::RequestParams
class CustomUnitAmount < Stripe::RequestParams
# Pass in `true` to enable `custom_unit_amount`, otherwise omit `custom_unit_amount`.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The maximum unit amount the customer can specify for this item.
sig { returns(T.nilable(Integer)) }
attr_accessor :maximum
# The minimum unit amount the customer can specify for this item. Must be at least the minimum charge amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :minimum
# The starting unit amount which can be updated by the customer.
sig { returns(T.nilable(Integer)) }
attr_accessor :preset
sig {
params(enabled: T::Boolean, maximum: T.nilable(Integer), minimum: T.nilable(Integer), preset: T.nilable(Integer)).void
}
def initialize(enabled: nil, maximum: nil, minimum: nil, preset: nil); end
end
class Tier < Stripe::RequestParams
# The flat billing amount for an entire tier, regardless of the number of units in the tier.
sig { returns(T.nilable(Integer)) }
attr_accessor :flat_amount
# Same as `flat_amount`, but accepts a decimal value representing an integer in the minor units of the currency. Only one of `flat_amount` and `flat_amount_decimal` can be set.
sig { returns(T.nilable(String)) }
attr_accessor :flat_amount_decimal
# The per unit billing amount for each individual unit for which this tier applies.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
# Specifies the upper bound of this tier. The lower bound of a tier is the upper bound of the previous tier adding one. Use `inf` to define a fallback tier.
sig { returns(T.any(String, Integer)) }
attr_accessor :up_to
sig {
params(flat_amount: T.nilable(Integer), flat_amount_decimal: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String), up_to: T.any(String, Integer)).void
}
def initialize(
flat_amount: nil,
flat_amount_decimal: nil,
unit_amount: nil,
unit_amount_decimal: nil,
up_to: nil
); end
end
# When set, provides configuration for the amount to be adjusted by the customer during Checkout Sessions and Payment Links.
sig { returns(T.nilable(::Stripe::Price::UpdateParams::CurrencyOptions::CustomUnitAmount)) }
attr_accessor :custom_unit_amount
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# Each element represents a pricing tier. This parameter requires `billing_scheme` to be set to `tiered`. See also the documentation for `billing_scheme`.
sig { returns(T.nilable(T::Array[::Stripe::Price::UpdateParams::CurrencyOptions::Tier])) }
attr_accessor :tiers
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(custom_unit_amount: T.nilable(::Stripe::Price::UpdateParams::CurrencyOptions::CustomUnitAmount), tax_behavior: T.nilable(String), tiers: T.nilable(T::Array[::Stripe::Price::UpdateParams::CurrencyOptions::Tier]), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
custom_unit_amount: nil,
tax_behavior: nil,
tiers: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
class MigrateTo < Stripe::RequestParams
# The behavior controlling the point in the subscription lifecycle after which to migrate the price. Currently must be `at_cycle_end`.
sig { returns(String) }
attr_accessor :behavior
# The time after which subscriptions should start using the new price.
sig { returns(T.nilable(Integer)) }
attr_accessor :effective_after
# The ID of the price object.
sig { returns(String) }
attr_accessor :price
sig { params(behavior: String, effective_after: T.nilable(Integer), price: String).void }
def initialize(behavior: nil, effective_after: nil, price: nil); end
end
# Whether the price can be used for new purchases. Defaults to `true`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# Prices defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
sig {
returns(T.nilable(T.nilable(T.any(String, T::Hash[String, ::Stripe::Price::UpdateParams::CurrencyOptions]))))
}
attr_accessor :currency_options
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A lookup key used to retrieve prices dynamically from a static string. This may be up to 200 characters.
sig { returns(T.nilable(String)) }
attr_accessor :lookup_key
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# If specified, subscriptions using this price will be updated to use the new referenced price.
sig { returns(T.nilable(T.nilable(T.any(String, ::Stripe::Price::UpdateParams::MigrateTo)))) }
attr_accessor :migrate_to
# A brief description of the price, hidden from customers.
sig { returns(T.nilable(String)) }
attr_accessor :nickname
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# If set to true, will atomically remove the lookup key from the existing price, and assign it to this price.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :transfer_lookup_key
sig {
params(active: T.nilable(T::Boolean), currency_options: T.nilable(T.nilable(T.any(String, T::Hash[String, ::Stripe::Price::UpdateParams::CurrencyOptions]))), expand: T.nilable(T::Array[String]), lookup_key: T.nilable(String), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), migrate_to: T.nilable(T.nilable(T.any(String, ::Stripe::Price::UpdateParams::MigrateTo))), nickname: T.nilable(String), tax_behavior: T.nilable(String), transfer_lookup_key: T.nilable(T::Boolean)).void
}
def initialize(
active: nil,
currency_options: nil,
expand: nil,
lookup_key: nil,
metadata: nil,
migrate_to: nil,
nickname: nil,
tax_behavior: nil,
transfer_lookup_key: nil
); end
end
class SearchParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for pagination across multiple pages of results. Don't include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.
sig { returns(T.nilable(String)) }
attr_accessor :page
# The search query string. See [search query language](https://stripe.com/docs/search#search-query-language) and the list of supported [query fields for prices](https://stripe.com/docs/search#query-fields-for-prices).
sig { returns(String) }
attr_accessor :query
sig {
params(expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), page: T.nilable(String), query: String).void
}
def initialize(expand: nil, limit: nil, page: nil, query: nil); end
end
# Creates a new [Price for an existing Product](https://docs.stripe.com/api/prices). The Price can be recurring or one-time.
sig {
params(params: T.any(::Stripe::Price::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Price)
}
def self.create(params = {}, opts = {}); end
# Returns a list of your active prices, excluding [inline prices](https://docs.stripe.com/docs/products-prices/pricing-models#inline-pricing). For the list of inactive prices, set active to false.
sig {
params(params: T.any(::Stripe::Price::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
sig {
params(params: T.any(::Stripe::Price::SearchParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SearchResultObject)
}
def self.search(params = {}, opts = {}); end
sig {
params(params: T.any(::Stripe::Price::SearchParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped, blk: T.untyped).returns(Stripe::SearchResultObject)
}
def self.search_auto_paging_each(params = {}, opts = {}, &blk); end
# Updates the specified price by setting the values of the parameters passed. Any parameters not provided are left unchanged.
sig {
params(price: String, params: T.any(::Stripe::Price::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Price)
}
def self.update(price, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
module Privacy
# The Redaction Job object redacts Stripe objects. You can use it
# to coordinate the removal of personal information from selected
# objects, making them permanently inaccessible in the Stripe Dashboard
# and API.
class RedactionJob < APIResource
class Objects < Stripe::StripeObject
# Charge object identifiers usually starting with `ch_`
sig { returns(T.nilable(T::Array[String])) }
attr_reader :charges
# CheckoutSession object identifiers starting with `cs_`
sig { returns(T.nilable(T::Array[String])) }
attr_reader :checkout_sessions
# Customer object identifiers starting with `cus_`
sig { returns(T.nilable(T::Array[String])) }
attr_reader :customers
# Identity VerificationSessions object identifiers starting with `vs_`
sig { returns(T.nilable(T::Array[String])) }
attr_reader :identity_verification_sessions
# Invoice object identifiers starting with `in_`
sig { returns(T.nilable(T::Array[String])) }
attr_reader :invoices
# Issuing Cardholder object identifiers starting with `ich_`
sig { returns(T.nilable(T::Array[String])) }
attr_reader :issuing_cardholders
# PaymentIntent object identifiers starting with `pi_`
sig { returns(T.nilable(T::Array[String])) }
attr_reader :payment_intents
# Fraud ValueListItem object identifiers starting with `rsli_`
sig { returns(T.nilable(T::Array[String])) }
attr_reader :radar_value_list_items
# SetupIntent object identifiers starting with `seti_`
sig { returns(T.nilable(T::Array[String])) }
attr_reader :setup_intents
end
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The objects to redact in this job.
sig { returns(T.nilable(Objects)) }
attr_reader :objects
# The status of the job.
sig { returns(String) }
attr_reader :status
# Validation behavior determines how a job validates objects for redaction eligibility. Default is `error`.
sig { returns(T.nilable(String)) }
attr_reader :validation_behavior
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Attribute for param field status
sig { returns(T.nilable(String)) }
attr_accessor :status
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String), status: T.nilable(String)).void
}
def initialize(
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil,
status: nil
); end
end
class CreateParams < Stripe::RequestParams
class Objects < Stripe::RequestParams
# Attribute for param field charges
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :charges
# Attribute for param field checkout_sessions
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :checkout_sessions
# Attribute for param field customers
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :customers
# Attribute for param field identity_verification_sessions
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :identity_verification_sessions
# Attribute for param field invoices
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :invoices
# Attribute for param field issuing_cardholders
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :issuing_cardholders
# Attribute for param field issuing_cards
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :issuing_cards
# Attribute for param field payment_intents
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :payment_intents
# Attribute for param field radar_value_list_items
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :radar_value_list_items
# Attribute for param field setup_intents
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :setup_intents
sig {
params(charges: T.nilable(T::Array[String]), checkout_sessions: T.nilable(T::Array[String]), customers: T.nilable(T::Array[String]), identity_verification_sessions: T.nilable(T::Array[String]), invoices: T.nilable(T::Array[String]), issuing_cardholders: T.nilable(T::Array[String]), issuing_cards: T.nilable(T::Array[String]), payment_intents: T.nilable(T::Array[String]), radar_value_list_items: T.nilable(T::Array[String]), setup_intents: T.nilable(T::Array[String])).void
}
def initialize(
charges: nil,
checkout_sessions: nil,
customers: nil,
identity_verification_sessions: nil,
invoices: nil,
issuing_cardholders: nil,
issuing_cards: nil,
payment_intents: nil,
radar_value_list_items: nil,
setup_intents: nil
); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The objects to redact. These root objects and their related ones will be validated for redaction.
sig { returns(::Stripe::Privacy::RedactionJob::CreateParams::Objects) }
attr_accessor :objects
# Determines the validation behavior of the job. Default is `error`.
sig { returns(T.nilable(String)) }
attr_accessor :validation_behavior
sig {
params(expand: T.nilable(T::Array[String]), objects: ::Stripe::Privacy::RedactionJob::CreateParams::Objects, validation_behavior: T.nilable(String)).void
}
def initialize(expand: nil, objects: nil, validation_behavior: nil); end
end
class UpdateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Determines the validation behavior of the job. Default is `error`.
sig { returns(T.nilable(String)) }
attr_accessor :validation_behavior
sig {
params(expand: T.nilable(T::Array[String]), validation_behavior: T.nilable(String)).void
}
def initialize(expand: nil, validation_behavior: nil); end
end
class CancelParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class RunParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class ValidateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# You can cancel a redaction job when it's in one of these statuses: ready, failed.
#
# Canceling the redaction job will abandon its attempt to redact the configured objects. A canceled job cannot be used again.
sig {
params(params: T.any(::Stripe::Privacy::RedactionJob::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Privacy::RedactionJob)
}
def cancel(params = {}, opts = {}); end
# You can cancel a redaction job when it's in one of these statuses: ready, failed.
#
# Canceling the redaction job will abandon its attempt to redact the configured objects. A canceled job cannot be used again.
sig {
params(job: String, params: T.any(::Stripe::Privacy::RedactionJob::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Privacy::RedactionJob)
}
def self.cancel(job, params = {}, opts = {}); end
# Creates a redaction job. When a job is created, it will start to validate.
sig {
params(params: T.any(::Stripe::Privacy::RedactionJob::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Privacy::RedactionJob)
}
def self.create(params = {}, opts = {}); end
# Returns a list of redaction jobs.
sig {
params(params: T.any(::Stripe::Privacy::RedactionJob::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Run a redaction job in a ready status.
#
# When you run a job, the configured objects will be redacted asynchronously. This action is irreversible and cannot be canceled once started.
#
# The status of the job will move to redacting. Once all of the objects are redacted, the status will become succeeded. If the job's validation_behavior is set to fix, the automatic fixes will be applied to objects at this step.
sig {
params(params: T.any(::Stripe::Privacy::RedactionJob::RunParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Privacy::RedactionJob)
}
def run(params = {}, opts = {}); end
# Run a redaction job in a ready status.
#
# When you run a job, the configured objects will be redacted asynchronously. This action is irreversible and cannot be canceled once started.
#
# The status of the job will move to redacting. Once all of the objects are redacted, the status will become succeeded. If the job's validation_behavior is set to fix, the automatic fixes will be applied to objects at this step.
sig {
params(job: String, params: T.any(::Stripe::Privacy::RedactionJob::RunParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Privacy::RedactionJob)
}
def self.run(job, params = {}, opts = {}); end
# Updates the properties of a redaction job without running or canceling the job.
#
# If the job to update is in a failed status, it will not automatically start to validate. Once you applied all of the changes, use the validate API to start validation again.
sig {
params(job: String, params: T.any(::Stripe::Privacy::RedactionJob::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Privacy::RedactionJob)
}
def self.update(job, params = {}, opts = {}); end
# Validate a redaction job when it is in a failed status.
#
# When a job is created, it automatically begins to validate on the configured objects' eligibility for redaction. Use this to validate the job again after its validation errors are resolved or the job's validation_behavior is changed.
#
# The status of the job will move to validating. Once all of the objects are validated, the status of the job will become ready. If there are any validation errors preventing the job from running, the status will become failed.
sig {
params(params: T.any(::Stripe::Privacy::RedactionJob::ValidateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Privacy::RedactionJob)
}
def validate(params = {}, opts = {}); end
# Validate a redaction job when it is in a failed status.
#
# When a job is created, it automatically begins to validate on the configured objects' eligibility for redaction. Use this to validate the job again after its validation errors are resolved or the job's validation_behavior is changed.
#
# The status of the job will move to validating. Once all of the objects are validated, the status of the job will become ready. If there are any validation errors preventing the job from running, the status will become failed.
sig {
params(job: String, params: T.any(::Stripe::Privacy::RedactionJob::ValidateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Privacy::RedactionJob)
}
def self.validate(job, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Privacy
# The Redaction Job validation error object contains information about
# errors that affect the ability to redact a specific object in a
# redaction job.
class RedactionJobValidationError < APIResource
class ErroringObject < Stripe::StripeObject
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Erroring object type
sig { returns(String) }
attr_reader :object_type
end
# A code indicating the reason for the error.
sig { returns(String) }
attr_reader :code
# If the error is related to a specific object, this field includes the object's identifier and object type.
sig { returns(T.nilable(ErroringObject)) }
attr_reader :erroring_object
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# A human-readable message providing more details about the error.
sig { returns(String) }
attr_reader :message
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
end
end
end
# typed: true
module Stripe
# Products describe the specific goods or services you offer to your customers.
# For example, you might offer a Standard and Premium version of your goods or service; each version would be a separate Product.
# They can be used in conjunction with [Prices](https://stripe.com/docs/api#prices) to configure pricing in Payment Links, Checkout, and Subscriptions.
#
# Related guides: [Set up a subscription](https://stripe.com/docs/billing/subscriptions/set-up-subscription),
# [share a Payment Link](https://stripe.com/docs/payment-links),
# [accept payments with Checkout](https://stripe.com/docs/payments/accept-a-payment#create-product-prices-upfront),
# and more about [Products and Prices](https://stripe.com/docs/products-prices/overview)
class Product < APIResource
class MarketingFeature < Stripe::StripeObject
# The marketing feature name. Up to 80 characters long.
sig { returns(String) }
attr_reader :name
end
class PackageDimensions < Stripe::StripeObject
# Height, in inches.
sig { returns(Float) }
attr_reader :height
# Length, in inches.
sig { returns(Float) }
attr_reader :length
# Weight, in ounces.
sig { returns(Float) }
attr_reader :weight
# Width, in inches.
sig { returns(Float) }
attr_reader :width
end
# Whether the product is currently available for purchase.
sig { returns(T::Boolean) }
attr_reader :active
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# The ID of the [Price](https://stripe.com/docs/api/prices) object that is the default price for this product.
sig { returns(T.nilable(T.any(String, Stripe::Price))) }
attr_reader :default_price
# The product's description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes.
sig { returns(T.nilable(String)) }
attr_reader :description
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# A list of up to 8 URLs of images for this product, meant to be displayable to the customer.
sig { returns(T::Array[String]) }
attr_reader :images
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# A list of up to 15 marketing features for this product. These are displayed in [pricing tables](https://stripe.com/docs/payments/checkout/pricing-table).
sig { returns(T::Array[MarketingFeature]) }
attr_reader :marketing_features
# 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.
sig { returns(T::Hash[String, String]) }
attr_reader :metadata
# The product's name, meant to be displayable to the customer.
sig { returns(String) }
attr_reader :name
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The dimensions of this product for shipping purposes.
sig { returns(T.nilable(PackageDimensions)) }
attr_reader :package_dimensions
# Whether this product is shipped (i.e., physical goods).
sig { returns(T.nilable(T::Boolean)) }
attr_reader :shippable
# Extra information about a product which will appear on your customer's credit card statement. In the case that multiple products are billed at once, the first statement descriptor will be used. Only used for subscription payments.
sig { returns(T.nilable(String)) }
attr_reader :statement_descriptor
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
sig { returns(T.nilable(T.any(String, Stripe::TaxCode))) }
attr_reader :tax_code
# The type of the product. The product is either of type `good`, which is eligible for use with Orders and SKUs, or `service`, which is eligible for use with Subscriptions and Plans.
sig { returns(String) }
attr_reader :type
# A label that represents units of this product. When set, this will be included in customers' receipts, invoices, Checkout, and the customer portal.
sig { returns(T.nilable(String)) }
attr_reader :unit_label
# Time at which the object was last updated. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :updated
# A URL of a publicly-accessible webpage for this product.
sig { returns(T.nilable(String)) }
attr_reader :url
# Always true for a deleted object
sig { returns(T::Boolean) }
attr_reader :deleted
class DeleteParams < Stripe::RequestParams; end
class UpdateParams < Stripe::RequestParams
class MarketingFeature < Stripe::RequestParams
# The marketing feature name. Up to 80 characters long.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class PackageDimensions < Stripe::RequestParams
# Height, in inches. Maximum precision is 2 decimal places.
sig { returns(Float) }
attr_accessor :height
# Length, in inches. Maximum precision is 2 decimal places.
sig { returns(Float) }
attr_accessor :length
# Weight, in ounces. Maximum precision is 2 decimal places.
sig { returns(Float) }
attr_accessor :weight
# Width, in inches. Maximum precision is 2 decimal places.
sig { returns(Float) }
attr_accessor :width
sig { params(height: Float, length: Float, weight: Float, width: Float).void }
def initialize(height: nil, length: nil, weight: nil, width: nil); end
end
# Whether the product is available for purchase.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# The ID of the [Price](https://stripe.com/docs/api/prices) object that is the default price for this product.
sig { returns(T.nilable(String)) }
attr_accessor :default_price
# The product's description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :description
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A list of up to 8 URLs of images for this product, meant to be displayable to the customer.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :images
# A list of up to 15 marketing features for this product. These are displayed in [pricing tables](https://stripe.com/docs/payments/checkout/pricing-table).
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Product::UpdateParams::MarketingFeature]))))
}
attr_accessor :marketing_features
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# The product's name, meant to be displayable to the customer.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The dimensions of this product for shipping purposes.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Product::UpdateParams::PackageDimensions))))
}
attr_accessor :package_dimensions
# Whether this product is shipped (i.e., physical goods).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :shippable
# An arbitrary string to be displayed on your customer's credit card or bank statement. While most banks display this information consistently, some may display it incorrectly or not at all.
#
# This may be up to 22 characters. The statement description may not include `<`, `>`, `\`, `"`, `'` characters, and will appear on your customer's statement in capital letters. Non-ASCII characters are automatically stripped.
# It must contain at least one letter. May only be set if `type=service`. Only used for subscription payments.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :tax_code
# A label that represents units of this product. When set, this will be included in customers' receipts, invoices, Checkout, and the customer portal. May only be set if `type=service`.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :unit_label
# A URL of a publicly-accessible webpage for this product.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :url
sig {
params(active: T.nilable(T::Boolean), default_price: T.nilable(String), description: T.nilable(T.nilable(String)), expand: T.nilable(T::Array[String]), images: T.nilable(T.nilable(T.any(String, T::Array[String]))), marketing_features: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Product::UpdateParams::MarketingFeature]))), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), name: T.nilable(String), package_dimensions: T.nilable(T.nilable(T.any(String, ::Stripe::Product::UpdateParams::PackageDimensions))), shippable: T.nilable(T::Boolean), statement_descriptor: T.nilable(String), tax_code: T.nilable(T.nilable(String)), unit_label: T.nilable(T.nilable(String)), url: T.nilable(T.nilable(String))).void
}
def initialize(
active: nil,
default_price: nil,
description: nil,
expand: nil,
images: nil,
marketing_features: nil,
metadata: nil,
name: nil,
package_dimensions: nil,
shippable: nil,
statement_descriptor: nil,
tax_code: nil,
unit_label: nil,
url: nil
); end
end
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return products that are active or inactive (e.g., pass `false` to list all inactive products).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# Only return products that were created during the given date interval.
sig { returns(T.nilable(T.any(::Stripe::Product::ListParams::Created, Integer))) }
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Only return products with the given IDs. Cannot be used with [starting_after](https://stripe.com/docs/api#list_products-starting_after) or [ending_before](https://stripe.com/docs/api#list_products-ending_before).
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :ids
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Only return products that can be shipped (i.e., physical, not digital products).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :shippable
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return products of this type.
sig { returns(T.nilable(String)) }
attr_accessor :type
# Only return products with the given url.
sig { returns(T.nilable(String)) }
attr_accessor :url
sig {
params(active: T.nilable(T::Boolean), created: T.nilable(T.any(::Stripe::Product::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), ids: T.nilable(T::Array[String]), limit: T.nilable(Integer), shippable: T.nilable(T::Boolean), starting_after: T.nilable(String), type: T.nilable(String), url: T.nilable(String)).void
}
def initialize(
active: nil,
created: nil,
ending_before: nil,
expand: nil,
ids: nil,
limit: nil,
shippable: nil,
starting_after: nil,
type: nil,
url: nil
); end
end
class CreateParams < Stripe::RequestParams
class DefaultPriceData < Stripe::RequestParams
class CurrencyOptions < Stripe::RequestParams
class CustomUnitAmount < Stripe::RequestParams
# Pass in `true` to enable `custom_unit_amount`, otherwise omit `custom_unit_amount`.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The maximum unit amount the customer can specify for this item.
sig { returns(T.nilable(Integer)) }
attr_accessor :maximum
# The minimum unit amount the customer can specify for this item. Must be at least the minimum charge amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :minimum
# The starting unit amount which can be updated by the customer.
sig { returns(T.nilable(Integer)) }
attr_accessor :preset
sig {
params(enabled: T::Boolean, maximum: T.nilable(Integer), minimum: T.nilable(Integer), preset: T.nilable(Integer)).void
}
def initialize(enabled: nil, maximum: nil, minimum: nil, preset: nil); end
end
class Tier < Stripe::RequestParams
# The flat billing amount for an entire tier, regardless of the number of units in the tier.
sig { returns(T.nilable(Integer)) }
attr_accessor :flat_amount
# Same as `flat_amount`, but accepts a decimal value representing an integer in the minor units of the currency. Only one of `flat_amount` and `flat_amount_decimal` can be set.
sig { returns(T.nilable(String)) }
attr_accessor :flat_amount_decimal
# The per unit billing amount for each individual unit for which this tier applies.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
# Specifies the upper bound of this tier. The lower bound of a tier is the upper bound of the previous tier adding one. Use `inf` to define a fallback tier.
sig { returns(T.any(String, Integer)) }
attr_accessor :up_to
sig {
params(flat_amount: T.nilable(Integer), flat_amount_decimal: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String), up_to: T.any(String, Integer)).void
}
def initialize(
flat_amount: nil,
flat_amount_decimal: nil,
unit_amount: nil,
unit_amount_decimal: nil,
up_to: nil
); end
end
# When set, provides configuration for the amount to be adjusted by the customer during Checkout Sessions and Payment Links.
sig {
returns(T.nilable(::Stripe::Product::CreateParams::DefaultPriceData::CurrencyOptions::CustomUnitAmount))
}
attr_accessor :custom_unit_amount
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# Each element represents a pricing tier. This parameter requires `billing_scheme` to be set to `tiered`. See also the documentation for `billing_scheme`.
sig {
returns(T.nilable(T::Array[::Stripe::Product::CreateParams::DefaultPriceData::CurrencyOptions::Tier]))
}
attr_accessor :tiers
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(custom_unit_amount: T.nilable(::Stripe::Product::CreateParams::DefaultPriceData::CurrencyOptions::CustomUnitAmount), tax_behavior: T.nilable(String), tiers: T.nilable(T::Array[::Stripe::Product::CreateParams::DefaultPriceData::CurrencyOptions::Tier]), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
custom_unit_amount: nil,
tax_behavior: nil,
tiers: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
class CustomUnitAmount < Stripe::RequestParams
# Pass in `true` to enable `custom_unit_amount`, otherwise omit `custom_unit_amount`.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The maximum unit amount the customer can specify for this item.
sig { returns(T.nilable(Integer)) }
attr_accessor :maximum
# The minimum unit amount the customer can specify for this item. Must be at least the minimum charge amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :minimum
# The starting unit amount which can be updated by the customer.
sig { returns(T.nilable(Integer)) }
attr_accessor :preset
sig {
params(enabled: T::Boolean, maximum: T.nilable(Integer), minimum: T.nilable(Integer), preset: T.nilable(Integer)).void
}
def initialize(enabled: nil, maximum: nil, minimum: nil, preset: nil); end
end
class Recurring < Stripe::RequestParams
# Specifies billing frequency. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: T.nilable(Integer)).void }
def initialize(interval: nil, interval_count: nil); end
end
# 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).
sig { returns(String) }
attr_accessor :currency
# Prices defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
sig {
returns(T.nilable(T::Hash[String, ::Stripe::Product::CreateParams::DefaultPriceData::CurrencyOptions]))
}
attr_accessor :currency_options
# When set, provides configuration for the amount to be adjusted by the customer during Checkout Sessions and Payment Links.
sig {
returns(T.nilable(::Stripe::Product::CreateParams::DefaultPriceData::CustomUnitAmount))
}
attr_accessor :custom_unit_amount
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The recurring components of a price such as `interval` and `interval_count`.
sig { returns(T.nilable(::Stripe::Product::CreateParams::DefaultPriceData::Recurring)) }
attr_accessor :recurring
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge. One of `unit_amount`, `unit_amount_decimal`, or `custom_unit_amount` is required.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, currency_options: T.nilable(T::Hash[String, ::Stripe::Product::CreateParams::DefaultPriceData::CurrencyOptions]), custom_unit_amount: T.nilable(::Stripe::Product::CreateParams::DefaultPriceData::CustomUnitAmount), metadata: T.nilable(T::Hash[String, String]), recurring: T.nilable(::Stripe::Product::CreateParams::DefaultPriceData::Recurring), tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
currency_options: nil,
custom_unit_amount: nil,
metadata: nil,
recurring: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
class MarketingFeature < Stripe::RequestParams
# The marketing feature name. Up to 80 characters long.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class PackageDimensions < Stripe::RequestParams
# Height, in inches. Maximum precision is 2 decimal places.
sig { returns(Float) }
attr_accessor :height
# Length, in inches. Maximum precision is 2 decimal places.
sig { returns(Float) }
attr_accessor :length
# Weight, in ounces. Maximum precision is 2 decimal places.
sig { returns(Float) }
attr_accessor :weight
# Width, in inches. Maximum precision is 2 decimal places.
sig { returns(Float) }
attr_accessor :width
sig { params(height: Float, length: Float, weight: Float, width: Float).void }
def initialize(height: nil, length: nil, weight: nil, width: nil); end
end
# Whether the product is currently available for purchase. Defaults to `true`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object. This Price will be set as the default price for this product.
sig { returns(T.nilable(::Stripe::Product::CreateParams::DefaultPriceData)) }
attr_accessor :default_price_data
# The product's description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# An identifier will be randomly generated by Stripe. You can optionally override this ID, but the ID must be unique across all products in your Stripe account.
sig { returns(T.nilable(String)) }
attr_accessor :id
# A list of up to 8 URLs of images for this product, meant to be displayable to the customer.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :images
# A list of up to 15 marketing features for this product. These are displayed in [pricing tables](https://stripe.com/docs/payments/checkout/pricing-table).
sig { returns(T.nilable(T::Array[::Stripe::Product::CreateParams::MarketingFeature])) }
attr_accessor :marketing_features
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The product's name, meant to be displayable to the customer.
sig { returns(String) }
attr_accessor :name
# The dimensions of this product for shipping purposes.
sig { returns(T.nilable(::Stripe::Product::CreateParams::PackageDimensions)) }
attr_accessor :package_dimensions
# Whether this product is shipped (i.e., physical goods).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :shippable
# An arbitrary string to be displayed on your customer's credit card or bank statement. While most banks display this information consistently, some may display it incorrectly or not at all.
#
# This may be up to 22 characters. The statement description may not include `<`, `>`, `\`, `"`, `'` characters, and will appear on your customer's statement in capital letters. Non-ASCII characters are automatically stripped.
# It must contain at least one letter. Only used for subscription payments.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
sig { returns(T.nilable(String)) }
attr_accessor :tax_code
# The type of the product. Defaults to `service` if not explicitly specified, enabling use of this product with Subscriptions and Plans. Set this parameter to `good` to use this product with Orders and SKUs. On API versions before `2018-02-05`, this field defaults to `good` for compatibility reasons.
sig { returns(T.nilable(String)) }
attr_accessor :type
# A label that represents units of this product. When set, this will be included in customers' receipts, invoices, Checkout, and the customer portal.
sig { returns(T.nilable(String)) }
attr_accessor :unit_label
# A URL of a publicly-accessible webpage for this product.
sig { returns(T.nilable(String)) }
attr_accessor :url
sig {
params(active: T.nilable(T::Boolean), default_price_data: T.nilable(::Stripe::Product::CreateParams::DefaultPriceData), description: T.nilable(String), expand: T.nilable(T::Array[String]), id: T.nilable(String), images: T.nilable(T::Array[String]), marketing_features: T.nilable(T::Array[::Stripe::Product::CreateParams::MarketingFeature]), metadata: T.nilable(T::Hash[String, String]), name: String, package_dimensions: T.nilable(::Stripe::Product::CreateParams::PackageDimensions), shippable: T.nilable(T::Boolean), statement_descriptor: T.nilable(String), tax_code: T.nilable(String), type: T.nilable(String), unit_label: T.nilable(String), url: T.nilable(String)).void
}
def initialize(
active: nil,
default_price_data: nil,
description: nil,
expand: nil,
id: nil,
images: nil,
marketing_features: nil,
metadata: nil,
name: nil,
package_dimensions: nil,
shippable: nil,
statement_descriptor: nil,
tax_code: nil,
type: nil,
unit_label: nil,
url: nil
); end
end
class SearchParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for pagination across multiple pages of results. Don't include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.
sig { returns(T.nilable(String)) }
attr_accessor :page
# The search query string. See [search query language](https://stripe.com/docs/search#search-query-language) and the list of supported [query fields for products](https://stripe.com/docs/search#query-fields-for-products).
sig { returns(String) }
attr_accessor :query
sig {
params(expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), page: T.nilable(String), query: String).void
}
def initialize(expand: nil, limit: nil, page: nil, query: nil); end
end
# Creates a new product object.
sig {
params(params: T.any(::Stripe::Product::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Product)
}
def self.create(params = {}, opts = {}); end
# Delete a product. Deleting a product is only possible if it has no prices associated with it. Additionally, deleting a product with type=good is only possible if it has no SKUs associated with it.
sig {
params(id: String, params: T.any(::Stripe::Product::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Product)
}
def self.delete(id, params = {}, opts = {}); end
# Delete a product. Deleting a product is only possible if it has no prices associated with it. Additionally, deleting a product with type=good is only possible if it has no SKUs associated with it.
sig {
params(params: T.any(::Stripe::Product::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Product)
}
def delete(params = {}, opts = {}); end
# Returns a list of your products. The products are returned sorted by creation date, with the most recently created products appearing first.
sig {
params(params: T.any(::Stripe::Product::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
sig {
params(params: T.any(::Stripe::Product::SearchParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SearchResultObject)
}
def self.search(params = {}, opts = {}); end
sig {
params(params: T.any(::Stripe::Product::SearchParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped, blk: T.untyped).returns(Stripe::SearchResultObject)
}
def self.search_auto_paging_each(params = {}, opts = {}, &blk); end
# Updates the specific product by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
sig {
params(id: String, params: T.any(::Stripe::Product::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Product)
}
def self.update(id, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
# A product_feature represents an attachment between a feature and a product.
# When a product is purchased that has a feature attached, Stripe will create an entitlement to the feature for the purchasing customer.
class ProductFeature < APIResource
# A feature represents a monetizable ability or functionality in your system.
# Features can be assigned to products, and when those products are purchased, Stripe will create an entitlement to the feature for the purchasing customer.
sig { returns(Stripe::Entitlements::Feature) }
attr_reader :entitlement_feature
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Always true for a deleted object
sig { returns(T::Boolean) }
attr_reader :deleted
end
end
# typed: true
module Stripe
# A Promotion Code represents a customer-redeemable code for a [coupon](https://stripe.com/docs/api#coupons). It can be used to
# create multiple codes for a single coupon.
class PromotionCode < APIResource
class Restrictions < Stripe::StripeObject
class CurrencyOptions < Stripe::StripeObject
# Minimum amount required to redeem this Promotion Code into a Coupon (e.g., a purchase must be $100 or more to work).
sig { returns(Integer) }
attr_reader :minimum_amount
end
# Promotion code restrictions defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
sig { returns(T::Hash[String, CurrencyOptions]) }
attr_reader :currency_options
# A Boolean indicating if the Promotion Code should only be redeemed for Customers without any successful payments or invoices
sig { returns(T::Boolean) }
attr_reader :first_time_transaction
# Minimum amount required to redeem this Promotion Code into a Coupon (e.g., a purchase must be $100 or more to work).
sig { returns(T.nilable(Integer)) }
attr_reader :minimum_amount
# Three-letter [ISO code](https://stripe.com/docs/currencies) for minimum_amount
sig { returns(T.nilable(String)) }
attr_reader :minimum_amount_currency
end
# Whether the promotion code is currently active. A promotion code is only active if the coupon is also valid.
sig { returns(T::Boolean) }
attr_reader :active
# The customer-facing code. Regardless of case, this code must be unique across all active promotion codes for each customer. Valid characters are lower case letters (a-z), upper case letters (A-Z), and digits (0-9).
sig { returns(String) }
attr_reader :code
# A coupon contains information about a percent-off or amount-off discount you
# might want to apply to a customer. Coupons may be applied to [subscriptions](https://stripe.com/docs/api#subscriptions), [invoices](https://stripe.com/docs/api#invoices),
# [checkout sessions](https://stripe.com/docs/api/checkout/sessions), [quotes](https://stripe.com/docs/api#quotes), and more. Coupons do not work with conventional one-off [charges](https://stripe.com/docs/api#create_charge) or [payment intents](https://stripe.com/docs/api/payment_intents).
sig { returns(Stripe::Coupon) }
attr_reader :coupon
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# The customer that this promotion code can be used by.
sig { returns(T.nilable(T.any(String, Stripe::Customer))) }
attr_reader :customer
# The account that this promotion code can be used by.
sig { returns(T.nilable(String)) }
attr_reader :customer_account
# Date at which the promotion code can no longer be redeemed.
sig { returns(T.nilable(Integer)) }
attr_reader :expires_at
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# Maximum number of times this promotion code can be redeemed.
sig { returns(T.nilable(Integer)) }
attr_reader :max_redemptions
# 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.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Attribute for field restrictions
sig { returns(Restrictions) }
attr_reader :restrictions
# Number of times this promotion code has been used.
sig { returns(Integer) }
attr_reader :times_redeemed
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Filter promotion codes by whether they are active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# Only return promotion codes that have this case-insensitive code.
sig { returns(T.nilable(String)) }
attr_accessor :code
# Only return promotion codes for this coupon.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.
sig { returns(T.nilable(T.any(::Stripe::PromotionCode::ListParams::Created, Integer))) }
attr_accessor :created
# Only return promotion codes that are restricted to this customer.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# Only return promotion codes that are restricted to this account.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(active: T.nilable(T::Boolean), code: T.nilable(String), coupon: T.nilable(String), created: T.nilable(T.any(::Stripe::PromotionCode::ListParams::Created, Integer)), customer: T.nilable(String), customer_account: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
active: nil,
code: nil,
coupon: nil,
created: nil,
customer: nil,
customer_account: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class Restrictions < Stripe::RequestParams
class CurrencyOptions < Stripe::RequestParams
# Minimum amount required to redeem this Promotion Code into a Coupon (e.g., a purchase must be $100 or more to work).
sig { returns(T.nilable(Integer)) }
attr_accessor :minimum_amount
sig { params(minimum_amount: T.nilable(Integer)).void }
def initialize(minimum_amount: nil); end
end
# Promotion codes defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
sig {
returns(T.nilable(T::Hash[String, ::Stripe::PromotionCode::CreateParams::Restrictions::CurrencyOptions]))
}
attr_accessor :currency_options
# A Boolean indicating if the Promotion Code should only be redeemed for Customers without any successful payments or invoices
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :first_time_transaction
# Minimum amount required to redeem this Promotion Code into a Coupon (e.g., a purchase must be $100 or more to work).
sig { returns(T.nilable(Integer)) }
attr_accessor :minimum_amount
# Three-letter [ISO code](https://stripe.com/docs/currencies) for minimum_amount
sig { returns(T.nilable(String)) }
attr_accessor :minimum_amount_currency
sig {
params(currency_options: T.nilable(T::Hash[String, ::Stripe::PromotionCode::CreateParams::Restrictions::CurrencyOptions]), first_time_transaction: T.nilable(T::Boolean), minimum_amount: T.nilable(Integer), minimum_amount_currency: T.nilable(String)).void
}
def initialize(
currency_options: nil,
first_time_transaction: nil,
minimum_amount: nil,
minimum_amount_currency: nil
); end
end
# Whether the promotion code is currently active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# The customer-facing code. Regardless of case, this code must be unique across all active promotion codes for a specific customer. Valid characters are lower case letters (a-z), upper case letters (A-Z), and digits (0-9).
#
# If left blank, we will generate one automatically.
sig { returns(T.nilable(String)) }
attr_accessor :code
# The coupon for this promotion code.
sig { returns(String) }
attr_accessor :coupon
# The customer that this promotion code can be used by. If not set, the promotion code can be used by all customers.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# The account that this promotion code can be used by. If not set, the promotion code can be used by all accounts.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The timestamp at which this promotion code will expire. If the coupon has specified a `redeems_by`, then this value cannot be after the coupon's `redeems_by`.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_at
# A positive integer specifying the number of times the promotion code can be redeemed. If the coupon has specified a `max_redemptions`, then this value cannot be greater than the coupon's `max_redemptions`.
sig { returns(T.nilable(Integer)) }
attr_accessor :max_redemptions
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Settings that restrict the redemption of the promotion code.
sig { returns(T.nilable(::Stripe::PromotionCode::CreateParams::Restrictions)) }
attr_accessor :restrictions
sig {
params(active: T.nilable(T::Boolean), code: T.nilable(String), coupon: String, customer: T.nilable(String), customer_account: T.nilable(String), expand: T.nilable(T::Array[String]), expires_at: T.nilable(Integer), max_redemptions: T.nilable(Integer), metadata: T.nilable(T::Hash[String, String]), restrictions: T.nilable(::Stripe::PromotionCode::CreateParams::Restrictions)).void
}
def initialize(
active: nil,
code: nil,
coupon: nil,
customer: nil,
customer_account: nil,
expand: nil,
expires_at: nil,
max_redemptions: nil,
metadata: nil,
restrictions: nil
); end
end
class UpdateParams < Stripe::RequestParams
class Restrictions < Stripe::RequestParams
class CurrencyOptions < Stripe::RequestParams
# Minimum amount required to redeem this Promotion Code into a Coupon (e.g., a purchase must be $100 or more to work).
sig { returns(T.nilable(Integer)) }
attr_accessor :minimum_amount
sig { params(minimum_amount: T.nilable(Integer)).void }
def initialize(minimum_amount: nil); end
end
# Promotion codes defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
sig {
returns(T.nilable(T::Hash[String, ::Stripe::PromotionCode::UpdateParams::Restrictions::CurrencyOptions]))
}
attr_accessor :currency_options
sig {
params(currency_options: T.nilable(T::Hash[String, ::Stripe::PromotionCode::UpdateParams::Restrictions::CurrencyOptions])).void
}
def initialize(currency_options: nil); end
end
# Whether the promotion code is currently active. A promotion code can only be reactivated when the coupon is still valid and the promotion code is otherwise redeemable.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Settings that restrict the redemption of the promotion code.
sig { returns(T.nilable(::Stripe::PromotionCode::UpdateParams::Restrictions)) }
attr_accessor :restrictions
sig {
params(active: T.nilable(T::Boolean), expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), restrictions: T.nilable(::Stripe::PromotionCode::UpdateParams::Restrictions)).void
}
def initialize(active: nil, expand: nil, metadata: nil, restrictions: nil); end
end
# A promotion code points to a coupon. You can optionally restrict the code to a specific customer, redemption limit, and expiration date.
sig {
params(params: T.any(::Stripe::PromotionCode::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PromotionCode)
}
def self.create(params = {}, opts = {}); end
# Returns a list of your promotion codes.
sig {
params(params: T.any(::Stripe::PromotionCode::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Updates the specified promotion code by setting the values of the parameters passed. Most fields are, by design, not editable.
sig {
params(promotion_code: String, params: T.any(::Stripe::PromotionCode::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PromotionCode)
}
def self.update(promotion_code, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
# A Quote is a way to model prices that you'd like to provide to a customer.
# Once accepted, it will automatically create an invoice, subscription or subscription schedule.
class Quote < APIResource
class AutomaticTax < Stripe::StripeObject
class Liability < Stripe::StripeObject
# The connected account being referenced when `type` is `account`.
sig { returns(T.any(String, Stripe::Account)) }
attr_reader :account
# Type of the account referenced.
sig { returns(String) }
attr_reader :type
end
# Automatically calculate taxes
sig { returns(T::Boolean) }
attr_reader :enabled
# The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
sig { returns(T.nilable(Liability)) }
attr_reader :liability
# The tax provider powering automatic tax.
sig { returns(T.nilable(String)) }
attr_reader :provider
# The status of the most recent automated tax calculation for this quote.
sig { returns(T.nilable(String)) }
attr_reader :status
end
class Computed < Stripe::StripeObject
class LastReestimationDetails < Stripe::StripeObject
class Failed < Stripe::StripeObject
# The failure `code` is more granular than the `reason` provided and may correspond to a Stripe error code. For automation errors, this field is one of: `reverse_api_failure`, `reverse_api_deadline_exceeeded`, or `reverse_api_response_validation_error`, which are Stripe error codes and map to the error `message` field.
sig { returns(T.nilable(String)) }
attr_reader :failure_code
# Information derived from the `failure_code` or a freeform message that explains the error as a human-readable English string. For example, "margin ID is not a valid ID".
sig { returns(T.nilable(String)) }
attr_reader :message
# The reason the reestimation failed.
sig { returns(String) }
attr_reader :reason
end
# When `status` is `failed`, provides details about the quote reestimation failure.
sig { returns(T.nilable(Failed)) }
attr_reader :failed
# Latest status of the reestimation.
sig { returns(String) }
attr_reader :status
end
class Recurring < Stripe::StripeObject
class TotalDetails < Stripe::StripeObject
class Breakdown < Stripe::StripeObject
class Discount < Stripe::StripeObject
# The amount discounted.
sig { returns(Integer) }
attr_reader :amount
# A discount represents the actual application of a [coupon](https://stripe.com/docs/api#coupons) or [promotion code](https://stripe.com/docs/api#promotion_codes).
# It contains information about when the discount began, when it will end, and what it is applied to.
#
# Related guide: [Applying discounts to subscriptions](https://stripe.com/docs/billing/subscriptions/discounts)
sig { returns(Stripe::Discount) }
attr_reader :discount
end
class Tax < Stripe::StripeObject
# Amount of tax applied for this rate.
sig { returns(Integer) }
attr_reader :amount
# Tax rates can be applied to [invoices](/invoicing/taxes/tax-rates), [subscriptions](/billing/taxes/tax-rates) and [Checkout Sessions](/payments/checkout/use-manual-tax-rates) to collect tax.
#
# Related guide: [Tax rates](/billing/taxes/tax-rates)
sig { returns(Stripe::TaxRate) }
attr_reader :rate
# 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.
sig { returns(T.nilable(String)) }
attr_reader :taxability_reason
# The amount on which tax is calculated, in cents (or local equivalent).
sig { returns(T.nilable(Integer)) }
attr_reader :taxable_amount
end
# The aggregated discounts.
sig { returns(T::Array[Discount]) }
attr_reader :discounts
# The aggregated tax amounts by rate.
sig { returns(T::Array[Tax]) }
attr_reader :taxes
end
# This is the sum of all the discounts.
sig { returns(Integer) }
attr_reader :amount_discount
# This is the sum of all the shipping amounts.
sig { returns(T.nilable(Integer)) }
attr_reader :amount_shipping
# This is the sum of all the tax amounts.
sig { returns(Integer) }
attr_reader :amount_tax
# Attribute for field breakdown
sig { returns(Breakdown) }
attr_reader :breakdown
end
# Total before any discounts or taxes are applied.
sig { returns(Integer) }
attr_reader :amount_subtotal
# Total after discounts and taxes are applied.
sig { returns(Integer) }
attr_reader :amount_total
# The frequency at which a subscription is billed. One of `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_reader :interval
# The number of intervals (specified in the `interval` attribute) between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months.
sig { returns(Integer) }
attr_reader :interval_count
# Attribute for field total_details
sig { returns(TotalDetails) }
attr_reader :total_details
end
class Upfront < Stripe::StripeObject
class TotalDetails < Stripe::StripeObject
class Breakdown < Stripe::StripeObject
class Discount < Stripe::StripeObject
# The amount discounted.
sig { returns(Integer) }
attr_reader :amount
# A discount represents the actual application of a [coupon](https://stripe.com/docs/api#coupons) or [promotion code](https://stripe.com/docs/api#promotion_codes).
# It contains information about when the discount began, when it will end, and what it is applied to.
#
# Related guide: [Applying discounts to subscriptions](https://stripe.com/docs/billing/subscriptions/discounts)
sig { returns(Stripe::Discount) }
attr_reader :discount
end
class Tax < Stripe::StripeObject
# Amount of tax applied for this rate.
sig { returns(Integer) }
attr_reader :amount
# Tax rates can be applied to [invoices](/invoicing/taxes/tax-rates), [subscriptions](/billing/taxes/tax-rates) and [Checkout Sessions](/payments/checkout/use-manual-tax-rates) to collect tax.
#
# Related guide: [Tax rates](/billing/taxes/tax-rates)
sig { returns(Stripe::TaxRate) }
attr_reader :rate
# 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.
sig { returns(T.nilable(String)) }
attr_reader :taxability_reason
# The amount on which tax is calculated, in cents (or local equivalent).
sig { returns(T.nilable(Integer)) }
attr_reader :taxable_amount
end
# The aggregated discounts.
sig { returns(T::Array[Discount]) }
attr_reader :discounts
# The aggregated tax amounts by rate.
sig { returns(T::Array[Tax]) }
attr_reader :taxes
end
# This is the sum of all the discounts.
sig { returns(Integer) }
attr_reader :amount_discount
# This is the sum of all the shipping amounts.
sig { returns(T.nilable(Integer)) }
attr_reader :amount_shipping
# This is the sum of all the tax amounts.
sig { returns(Integer) }
attr_reader :amount_tax
# Attribute for field breakdown
sig { returns(Breakdown) }
attr_reader :breakdown
end
# Total before any discounts or taxes are applied.
sig { returns(Integer) }
attr_reader :amount_subtotal
# Total after discounts and taxes are applied.
sig { returns(Integer) }
attr_reader :amount_total
# The line items that will appear on the next invoice after this quote is accepted. This does not include pending invoice items that exist on the customer but may still be included in the next invoice.
sig { returns(Stripe::ListObject) }
attr_reader :line_items
# Attribute for field total_details
sig { returns(TotalDetails) }
attr_reader :total_details
end
# Details of the most recent reestimate of the quote's preview schedules and upcoming invoices, including the status of Stripe's calculation.
sig { returns(T.nilable(LastReestimationDetails)) }
attr_reader :last_reestimation_details
# The definitive totals and line items the customer will be charged on a recurring basis. Takes into account the line items with recurring prices and discounts with `duration=forever` coupons only. Defaults to `null` if no inputted line items with recurring prices.
sig { returns(T.nilable(Recurring)) }
attr_reader :recurring
# The time at which the quote's estimated schedules and upcoming invoices were generated.
sig { returns(T.nilable(Integer)) }
attr_reader :updated_at
# Attribute for field upfront
sig { returns(Upfront) }
attr_reader :upfront
end
class FromQuote < Stripe::StripeObject
# Whether this quote is a revision of a different quote.
sig { returns(T::Boolean) }
attr_reader :is_revision
# The quote that was cloned.
sig { returns(T.any(String, Stripe::Quote)) }
attr_reader :quote
end
class InvoiceSettings < Stripe::StripeObject
class Issuer < Stripe::StripeObject
# The connected account being referenced when `type` is `account`.
sig { returns(T.any(String, Stripe::Account)) }
attr_reader :account
# Type of the account referenced.
sig { returns(String) }
attr_reader :type
end
# Number of days within which a customer must pay invoices generated by this quote. This value will be `null` for quotes where `collection_method=charge_automatically`.
sig { returns(T.nilable(Integer)) }
attr_reader :days_until_due
# Attribute for field issuer
sig { returns(Issuer) }
attr_reader :issuer
end
class StatusDetails < Stripe::StripeObject
class Canceled < Stripe::StripeObject
# The reason this quote was marked as canceled.
sig { returns(T.nilable(String)) }
attr_reader :reason
# Time at which the quote was marked as canceled. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_reader :transitioned_at
end
class Stale < Stripe::StripeObject
class LastReason < Stripe::StripeObject
class LinesInvalid < Stripe::StripeObject
# The timestamp at which the lines were marked as invalid.
sig { returns(Integer) }
attr_reader :invalid_at
# The list of lines that became invalid at the given timestamp.
sig { returns(T::Array[String]) }
attr_reader :lines
end
class SubscriptionChanged < Stripe::StripeObject
# The subscription's state before the quote was marked as stale.
sig { returns(T.nilable(Stripe::Subscription)) }
attr_reader :previous_subscription
end
class SubscriptionScheduleChanged < Stripe::StripeObject
# The subscription schedule's state before the quote was marked as stale.
sig { returns(T.nilable(Stripe::SubscriptionSchedule)) }
attr_reader :previous_subscription_schedule
end
# The ID of the line that is invalid if the stale reason type is `line_invalid`.
sig { returns(String) }
attr_reader :line_invalid
# The IDs of the lines that are invalid if the stale reason type is `lines_invalid`.
sig { returns(T::Array[LinesInvalid]) }
attr_reader :lines_invalid
# The user supplied mark stale reason.
sig { returns(T.nilable(String)) }
attr_reader :marked_stale
# The ID of the subscription that was canceled.
sig { returns(String) }
attr_reader :subscription_canceled
# Attribute for field subscription_changed
sig { returns(SubscriptionChanged) }
attr_reader :subscription_changed
# The ID of the subscription that was expired.
sig { returns(String) }
attr_reader :subscription_expired
# The ID of the subscription schedule that was canceled.
sig { returns(String) }
attr_reader :subscription_schedule_canceled
# Attribute for field subscription_schedule_changed
sig { returns(SubscriptionScheduleChanged) }
attr_reader :subscription_schedule_changed
# The ID of the subscription schedule that was released.
sig { returns(String) }
attr_reader :subscription_schedule_released
# The reason the quote was marked as stale.
sig { returns(T.nilable(String)) }
attr_reader :type
end
# Time at which the quote expires. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_reader :expires_at
# The most recent reason this quote was marked as stale.
sig { returns(T.nilable(LastReason)) }
attr_reader :last_reason
# Time at which the stale reason was updated. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_reader :last_updated_at
# Time at which the quote was marked as stale. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_reader :transitioned_at
end
# Attribute for field canceled
sig { returns(Canceled) }
attr_reader :canceled
# Attribute for field stale
sig { returns(Stale) }
attr_reader :stale
end
class StatusTransitions < Stripe::StripeObject
# The time that the quote was accepted. Measured in seconds since Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_reader :accepted_at
# The time that the quote was canceled. Measured in seconds since Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_reader :canceled_at
# The time that the quote was finalized. Measured in seconds since Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_reader :finalized_at
end
class SubscriptionData < Stripe::StripeObject
class BillOnAcceptance < Stripe::StripeObject
class BillFrom < Stripe::StripeObject
class LineStartsAt < Stripe::StripeObject
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
end
# The materialized time.
sig { returns(T.nilable(Integer)) }
attr_reader :computed
# The timestamp the given line starts at.
sig { returns(T.nilable(LineStartsAt)) }
attr_reader :line_starts_at
# A precise Unix timestamp.
sig { returns(T.nilable(Integer)) }
attr_reader :timestamp
# The type of method to specify the `bill_from` time.
sig { returns(String) }
attr_reader :type
end
class BillUntil < Stripe::StripeObject
class Duration < Stripe::StripeObject
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_reader :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_reader :interval_count
end
class LineEndsAt < Stripe::StripeObject
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
end
# The materialized time.
sig { returns(T.nilable(Integer)) }
attr_reader :computed
# Time span for the quote line starting from the `starts_at` date.
sig { returns(T.nilable(Duration)) }
attr_reader :duration
# The timestamp the given line ends at.
sig { returns(T.nilable(LineEndsAt)) }
attr_reader :line_ends_at
# A precise Unix timestamp.
sig { returns(T.nilable(Integer)) }
attr_reader :timestamp
# The type of method to specify the `bill_until` time.
sig { returns(String) }
attr_reader :type
end
# The start of the period to bill from when the Quote is accepted.
sig { returns(T.nilable(BillFrom)) }
attr_reader :bill_from
# The end of the period to bill until when the Quote is accepted.
sig { returns(T.nilable(BillUntil)) }
attr_reader :bill_until
end
class Prebilling < Stripe::StripeObject
# Attribute for field iterations
sig { returns(Integer) }
attr_reader :iterations
end
# Describes the period to bill for upon accepting the quote.
sig { returns(T.nilable(BillOnAcceptance)) }
attr_reader :bill_on_acceptance
# Configures when the subscription schedule generates prorations for phase transitions. Possible values are `prorate_on_next_phase` or `prorate_up_front` with the default being `prorate_on_next_phase`. `prorate_on_next_phase` will apply phase changes and generate prorations at transition time. `prorate_up_front` will bill for all phases within the current billing cycle up front.
sig { returns(String) }
attr_reader :billing_behavior
# Whether the subscription will always start a new billing period when the quote is accepted.
sig { returns(T.nilable(String)) }
attr_reader :billing_cycle_anchor
# The [billing mode](/api/subscriptions/create#create_subscription-billing_mode) that will be set on the subscription once the quote is accepted.
sig { returns(String) }
attr_reader :billing_mode
# The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
sig { returns(T.nilable(String)) }
attr_reader :description
# When creating a new subscription, the date of which the subscription schedule will start after the quote is accepted. This date is ignored if it is in the past when the quote is accepted. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_reader :effective_date
# Behavior of the subscription schedule and underlying subscription when it ends.
sig { returns(T.nilable(String)) }
attr_reader :end_behavior
# The id of the subscription that will be updated when the quote is accepted.
sig { returns(T.nilable(T.any(String, Stripe::Subscription))) }
attr_reader :from_subscription
# Set of [key-value pairs](https://stripe.com/docs/api/metadata) that will set metadata on the subscription or subscription schedule when the quote is accepted. If a recurring price is included in `line_items`, this field will be passed to the resulting subscription's `metadata` field. If `subscription_data.effective_date` is used, this field will be passed to the resulting subscription schedule's `phases.metadata` field. Unlike object-level metadata, this field is declarative. Updates will clear prior values.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# If specified, the invoicing for the given billing cycle iterations will be processed when the quote is accepted. Cannot be used with `effective_date`.
sig { returns(T.nilable(Prebilling)) }
attr_reader :prebilling
# Determines how to handle [prorations](https://stripe.com/docs/subscriptions/billing-cycle#prorations) when the quote is accepted.
sig { returns(String) }
attr_reader :proration_behavior
# Integer representing the number of trial period days before the customer is charged for the first time.
sig { returns(T.nilable(Integer)) }
attr_reader :trial_period_days
end
class SubscriptionDataOverride < Stripe::StripeObject
class AppliesTo < Stripe::StripeObject
# A custom string that identifies a new subscription schedule being created upon quote acceptance. All quote lines with the same `new_reference` field will be applied to the creation of a new subscription schedule.
sig { returns(T.nilable(String)) }
attr_reader :new_reference
# The ID of the schedule the line applies to.
sig { returns(T.nilable(String)) }
attr_reader :subscription_schedule
# Describes whether the quote line is affecting a new schedule or an existing schedule.
sig { returns(String) }
attr_reader :type
end
class BillOnAcceptance < Stripe::StripeObject
class BillFrom < Stripe::StripeObject
class LineStartsAt < Stripe::StripeObject
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
end
# The materialized time.
sig { returns(T.nilable(Integer)) }
attr_reader :computed
# The timestamp the given line starts at.
sig { returns(T.nilable(LineStartsAt)) }
attr_reader :line_starts_at
# A precise Unix timestamp.
sig { returns(T.nilable(Integer)) }
attr_reader :timestamp
# The type of method to specify the `bill_from` time.
sig { returns(String) }
attr_reader :type
end
class BillUntil < Stripe::StripeObject
class Duration < Stripe::StripeObject
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_reader :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_reader :interval_count
end
class LineEndsAt < Stripe::StripeObject
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
end
# The materialized time.
sig { returns(T.nilable(Integer)) }
attr_reader :computed
# Time span for the quote line starting from the `starts_at` date.
sig { returns(T.nilable(Duration)) }
attr_reader :duration
# The timestamp the given line ends at.
sig { returns(T.nilable(LineEndsAt)) }
attr_reader :line_ends_at
# A precise Unix timestamp.
sig { returns(T.nilable(Integer)) }
attr_reader :timestamp
# The type of method to specify the `bill_until` time.
sig { returns(String) }
attr_reader :type
end
# The start of the period to bill from when the Quote is accepted.
sig { returns(T.nilable(BillFrom)) }
attr_reader :bill_from
# The end of the period to bill until when the Quote is accepted.
sig { returns(T.nilable(BillUntil)) }
attr_reader :bill_until
end
# Attribute for field applies_to
sig { returns(AppliesTo) }
attr_reader :applies_to
# Describes the period to bill for upon accepting the quote.
sig { returns(T.nilable(BillOnAcceptance)) }
attr_reader :bill_on_acceptance
# Configures when the subscription schedule generates prorations for phase transitions. Possible values are `prorate_on_next_phase` or `prorate_up_front` with the default being `prorate_on_next_phase`. `prorate_on_next_phase` will apply phase changes and generate prorations at transition time. `prorate_up_front` will bill for all phases within the current billing cycle up front.
sig { returns(String) }
attr_reader :billing_behavior
# The customer which this quote belongs to. A customer is required before finalizing the quote. Once specified, it cannot be changed.
sig { returns(T.nilable(String)) }
attr_reader :customer
# The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
sig { returns(T.nilable(String)) }
attr_reader :description
# Behavior of the subscription schedule and underlying subscription when it ends.
sig { returns(T.nilable(String)) }
attr_reader :end_behavior
# Determines how to handle [prorations](https://stripe.com/docs/subscriptions/billing-cycle#prorations) when the quote is accepted.
sig { returns(T.nilable(String)) }
attr_reader :proration_behavior
end
class SubscriptionSchedule < Stripe::StripeObject
class AppliesTo < Stripe::StripeObject
# A custom string that identifies a new subscription schedule being created upon quote acceptance. All quote lines with the same `new_reference` field will be applied to the creation of a new subscription schedule.
sig { returns(T.nilable(String)) }
attr_reader :new_reference
# The ID of the schedule the line applies to.
sig { returns(T.nilable(String)) }
attr_reader :subscription_schedule
# Describes whether the quote line is affecting a new schedule or an existing schedule.
sig { returns(String) }
attr_reader :type
end
# Attribute for field applies_to
sig { returns(AppliesTo) }
attr_reader :applies_to
# The subscription schedule that was created or updated from this quote.
sig { returns(String) }
attr_reader :subscription_schedule
end
class TotalDetails < Stripe::StripeObject
class Breakdown < Stripe::StripeObject
class Discount < Stripe::StripeObject
# The amount discounted.
sig { returns(Integer) }
attr_reader :amount
# A discount represents the actual application of a [coupon](https://stripe.com/docs/api#coupons) or [promotion code](https://stripe.com/docs/api#promotion_codes).
# It contains information about when the discount began, when it will end, and what it is applied to.
#
# Related guide: [Applying discounts to subscriptions](https://stripe.com/docs/billing/subscriptions/discounts)
sig { returns(Stripe::Discount) }
attr_reader :discount
end
class Tax < Stripe::StripeObject
# Amount of tax applied for this rate.
sig { returns(Integer) }
attr_reader :amount
# Tax rates can be applied to [invoices](/invoicing/taxes/tax-rates), [subscriptions](/billing/taxes/tax-rates) and [Checkout Sessions](/payments/checkout/use-manual-tax-rates) to collect tax.
#
# Related guide: [Tax rates](/billing/taxes/tax-rates)
sig { returns(Stripe::TaxRate) }
attr_reader :rate
# 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.
sig { returns(T.nilable(String)) }
attr_reader :taxability_reason
# The amount on which tax is calculated, in cents (or local equivalent).
sig { returns(T.nilable(Integer)) }
attr_reader :taxable_amount
end
# The aggregated discounts.
sig { returns(T::Array[Discount]) }
attr_reader :discounts
# The aggregated tax amounts by rate.
sig { returns(T::Array[Tax]) }
attr_reader :taxes
end
# This is the sum of all the discounts.
sig { returns(Integer) }
attr_reader :amount_discount
# This is the sum of all the shipping amounts.
sig { returns(T.nilable(Integer)) }
attr_reader :amount_shipping
# This is the sum of all the tax amounts.
sig { returns(Integer) }
attr_reader :amount_tax
# Attribute for field breakdown
sig { returns(Breakdown) }
attr_reader :breakdown
end
class TransferData < Stripe::StripeObject
# The amount in cents (or local equivalent) that will be transferred to the destination account when the invoice is paid. By default, the entire amount is transferred to the destination.
sig { returns(T.nilable(Integer)) }
attr_reader :amount
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount will be transferred to the destination.
sig { returns(T.nilable(Float)) }
attr_reader :amount_percent
# The account where funds from the payment will be transferred to upon payment success.
sig { returns(T.any(String, Stripe::Account)) }
attr_reader :destination
end
# Allow quote lines to have `starts_at` in the past if collection is paused between `starts_at` and now.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :allow_backdated_lines
# Total before any discounts or taxes are applied.
sig { returns(Integer) }
attr_reader :amount_subtotal
# Total after discounts and taxes are applied.
sig { returns(Integer) }
attr_reader :amount_total
# ID of the Connect Application that created the quote.
sig { returns(T.nilable(T.any(String, Stripe::Application))) }
attr_reader :application
# The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. Only applicable if there are no line items with recurring prices on the quote.
sig { returns(T.nilable(Integer)) }
attr_reader :application_fee_amount
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. Only applicable if there are line items with recurring prices on the quote.
sig { returns(T.nilable(Float)) }
attr_reader :application_fee_percent
# Attribute for field automatic_tax
sig { returns(AutomaticTax) }
attr_reader :automatic_tax
# Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay invoices at the end of the subscription cycle or on finalization using the default payment method attached to the subscription or customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically`.
sig { returns(String) }
attr_reader :collection_method
# Attribute for field computed
sig { returns(Computed) }
attr_reader :computed
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# 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).
sig { returns(T.nilable(String)) }
attr_reader :currency
# The customer which this quote belongs to. A customer is required before finalizing the quote. Once specified, it cannot be changed.
sig { returns(T.nilable(T.any(String, Stripe::Customer))) }
attr_reader :customer
# The account which this quote belongs to. A customer or account is required before finalizing the quote. Once specified, it cannot be changed.
sig { returns(T.nilable(String)) }
attr_reader :customer_account
# The tax rates applied to this quote.
sig { returns(T::Array[T.any(String, Stripe::TaxRate)]) }
attr_reader :default_tax_rates
# A description that will be displayed on the quote PDF.
sig { returns(T.nilable(String)) }
attr_reader :description
# The discounts applied to this quote.
sig { returns(T::Array[T.any(String, Stripe::Discount)]) }
attr_reader :discounts
# The date on which the quote will be canceled if in `open` or `draft` status. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :expires_at
# A footer that will be displayed on the quote PDF.
sig { returns(T.nilable(String)) }
attr_reader :footer
# Details of the quote that was cloned. See the [cloning documentation](https://stripe.com/docs/quotes/clone) for more details.
sig { returns(T.nilable(FromQuote)) }
attr_reader :from_quote
# A header that will be displayed on the quote PDF.
sig { returns(T.nilable(String)) }
attr_reader :header
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# The invoice that was created from this quote.
sig { returns(T.nilable(T.any(String, Stripe::Invoice))) }
attr_reader :invoice
# Attribute for field invoice_settings
sig { returns(InvoiceSettings) }
attr_reader :invoice_settings
# A list of items the customer is being quoted for.
sig { returns(Stripe::ListObject) }
attr_reader :line_items
# A list of [quote lines](https://docs.stripe.com/api/quote_lines) on the quote. These lines describe changes, in the order provided, that will be used to create new subscription schedules or update existing subscription schedules when the quote is accepted.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :lines
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# 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.
sig { returns(T::Hash[String, String]) }
attr_reader :metadata
# A unique number that identifies this particular quote. This number is assigned once the quote is [finalized](https://stripe.com/docs/quotes/overview#finalize).
sig { returns(T.nilable(String)) }
attr_reader :number
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The account on behalf of which to charge. See the [Connect documentation](https://support.stripe.com/questions/sending-invoices-on-behalf-of-connected-accounts) for details.
sig { returns(T.nilable(T.any(String, Stripe::Account))) }
attr_reader :on_behalf_of
# The status of the quote.
sig { returns(String) }
attr_reader :status
# Details on when and why a quote has been marked as stale or canceled.
sig { returns(T.nilable(StatusDetails)) }
attr_reader :status_details
# Attribute for field status_transitions
sig { returns(StatusTransitions) }
attr_reader :status_transitions
# The subscription that was created or updated from this quote.
sig { returns(T.nilable(T.any(String, Stripe::Subscription))) }
attr_reader :subscription
# Attribute for field subscription_data
sig { returns(SubscriptionData) }
attr_reader :subscription_data
# List representing overrides for `subscription_data` configurations for specific subscription schedules.
sig { returns(T.nilable(T::Array[SubscriptionDataOverride])) }
attr_reader :subscription_data_overrides
# The subscription schedule that was created or updated from this quote.
sig { returns(T.nilable(T.any(String, Stripe::SubscriptionSchedule))) }
attr_reader :subscription_schedule
# The subscription schedules that were created or updated from this quote.
sig { returns(T.nilable(T::Array[SubscriptionSchedule])) }
attr_reader :subscription_schedules
# ID of the test clock this quote belongs to.
sig { returns(T.nilable(T.any(String, Stripe::TestHelpers::TestClock))) }
attr_reader :test_clock
# Attribute for field total_details
sig { returns(TotalDetails) }
attr_reader :total_details
# The account (if any) the payments will be attributed to for tax reporting, and where funds from each payment will be transferred to for each of the invoices.
sig { returns(T.nilable(TransferData)) }
attr_reader :transfer_data
class ListParams < Stripe::RequestParams
# The ID of the customer whose quotes will be retrieved.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# The ID of the account whose quotes will be retrieved.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The subscription which the quote updates.
sig { returns(T.nilable(String)) }
attr_accessor :from_subscription
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# The status of the quote.
sig { returns(T.nilable(String)) }
attr_accessor :status
# Provides a list of quotes that are associated with the specified test clock. The response will not include quotes with test clocks if this and the customer parameter is not set.
sig { returns(T.nilable(String)) }
attr_accessor :test_clock
sig {
params(customer: T.nilable(String), customer_account: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), from_subscription: T.nilable(String), limit: T.nilable(Integer), starting_after: T.nilable(String), status: T.nilable(String), test_clock: T.nilable(String)).void
}
def initialize(
customer: nil,
customer_account: nil,
ending_before: nil,
expand: nil,
from_subscription: nil,
limit: nil,
starting_after: nil,
status: nil,
test_clock: nil
); end
end
class CreateParams < Stripe::RequestParams
class AutomaticTax < Stripe::RequestParams
class Liability < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# Controls whether Stripe will automatically compute tax on the resulting invoices or subscriptions as well as the quote itself.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
sig { returns(T.nilable(::Stripe::Quote::CreateParams::AutomaticTax::Liability)) }
attr_accessor :liability
sig {
params(enabled: T::Boolean, liability: T.nilable(::Stripe::Quote::CreateParams::AutomaticTax::Liability)).void
}
def initialize(enabled: nil, liability: nil); end
end
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig { returns(T.nilable(::Stripe::Quote::CreateParams::Discount::DiscountEnd::Duration)) }
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::Quote::CreateParams::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig { returns(T.nilable(::Stripe::Quote::CreateParams::Discount::DiscountEnd)) }
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::Quote::CreateParams::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class FromQuote < Stripe::RequestParams
# Whether this quote is a revision of the previous quote.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :is_revision
# The `id` of the quote that will be cloned.
sig { returns(String) }
attr_accessor :quote
sig { params(is_revision: T.nilable(T::Boolean), quote: String).void }
def initialize(is_revision: nil, quote: nil); end
end
class InvoiceSettings < Stripe::RequestParams
class Issuer < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# Number of days within which a customer must pay the invoice generated by this quote. This value will be `null` for quotes where `collection_method=charge_automatically`.
sig { returns(T.nilable(Integer)) }
attr_accessor :days_until_due
# The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
sig { returns(T.nilable(::Stripe::Quote::CreateParams::InvoiceSettings::Issuer)) }
attr_accessor :issuer
sig {
params(days_until_due: T.nilable(Integer), issuer: T.nilable(::Stripe::Quote::CreateParams::InvoiceSettings::Issuer)).void
}
def initialize(days_until_due: nil, issuer: nil); end
end
class Line < Stripe::RequestParams
class Action < Stripe::RequestParams
class AddDiscount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
# The coupon code to redeem.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# An ID of an existing discount for a coupon that was already redeemed.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::Quote::CreateParams::Line::Action::AddDiscount::DiscountEnd))
}
attr_accessor :discount_end
# The index, starting at 0, at which to position the new discount. When not supplied, Stripe defaults to appending the discount to the end of the `discounts` array.
sig { returns(T.nilable(Integer)) }
attr_accessor :index
# The promotion code to redeem.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::Quote::CreateParams::Line::Action::AddDiscount::DiscountEnd), index: T.nilable(Integer), promotion_code: T.nilable(String)).void
}
def initialize(
coupon: nil,
discount: nil,
discount_end: nil,
index: nil,
promotion_code: nil
); end
end
class AddItem < Stripe::RequestParams
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::Quote::CreateParams::Line::Action::AddItem::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::Quote::CreateParams::Line::Action::AddItem::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::Quote::CreateParams::Line::Action::AddItem::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::Quote::CreateParams::Line::Action::AddItem::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(
coupon: nil,
discount: nil,
discount_end: nil,
promotion_code: nil
); end
end
class Trial < Stripe::RequestParams
# List of price IDs which, if present on the subscription following a paid trial, constitute opting-in to the paid trial. Currently only supports at most 1 price ID.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :converts_to
# Determines the type of trial for this item.
sig { returns(String) }
attr_accessor :type
sig { params(converts_to: T.nilable(T::Array[String]), type: String).void }
def initialize(converts_to: nil, type: nil); end
end
# The discounts applied to the item. Subscription item discounts are applied before subscription discounts.
sig {
returns(T.nilable(T::Array[::Stripe::Quote::CreateParams::Line::Action::AddItem::Discount]))
}
attr_accessor :discounts
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The ID of the price object.
sig { returns(String) }
attr_accessor :price
# Quantity for this item.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# The tax rates that apply to this subscription item. When set, the `default_tax_rates` on the subscription do not apply to this `subscription_item`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :tax_rates
# Options that configure the trial on the subscription item.
sig { returns(T.nilable(::Stripe::Quote::CreateParams::Line::Action::AddItem::Trial)) }
attr_accessor :trial
sig {
params(discounts: T.nilable(T::Array[::Stripe::Quote::CreateParams::Line::Action::AddItem::Discount]), metadata: T.nilable(T::Hash[String, String]), price: String, quantity: T.nilable(Integer), tax_rates: T.nilable(T::Array[String]), trial: T.nilable(::Stripe::Quote::CreateParams::Line::Action::AddItem::Trial)).void
}
def initialize(
discounts: nil,
metadata: nil,
price: nil,
quantity: nil,
tax_rates: nil,
trial: nil
); end
end
class RemoveDiscount < Stripe::RequestParams
# The coupon code to remove from the `discounts` array.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# The ID of a discount to remove from the `discounts` array.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# The ID of a promotion code to remove from the `discounts` array.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, promotion_code: nil); end
end
class RemoveItem < Stripe::RequestParams
# ID of a price to remove.
sig { returns(String) }
attr_accessor :price
sig { params(price: String).void }
def initialize(price: nil); end
end
class SetDiscount < Stripe::RequestParams
# The coupon code to replace the `discounts` array with.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# An ID of an existing discount to replace the `discounts` array with.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# An ID of an existing promotion code to replace the `discounts` array with.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, promotion_code: nil); end
end
class SetItem < Stripe::RequestParams
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::Quote::CreateParams::Line::Action::SetItem::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::Quote::CreateParams::Line::Action::SetItem::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::Quote::CreateParams::Line::Action::SetItem::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::Quote::CreateParams::Line::Action::SetItem::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(
coupon: nil,
discount: nil,
discount_end: nil,
promotion_code: nil
); end
end
class Trial < Stripe::RequestParams
# List of price IDs which, if present on the subscription following a paid trial, constitute opting-in to the paid trial. Currently only supports at most 1 price ID.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :converts_to
# Determines the type of trial for this item.
sig { returns(String) }
attr_accessor :type
sig { params(converts_to: T.nilable(T::Array[String]), type: String).void }
def initialize(converts_to: nil, type: nil); end
end
# If an item with the `price` already exists, passing this will override the `discounts` array on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `discounts`.
sig {
returns(T.nilable(T::Array[::Stripe::Quote::CreateParams::Line::Action::SetItem::Discount]))
}
attr_accessor :discounts
# If an item with the `price` already exists, passing this will override the `metadata` on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `metadata`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The ID of the price object.
sig { returns(String) }
attr_accessor :price
# If an item with the `price` already exists, passing this will override the quantity on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `quantity`.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# If an item with the `price` already exists, passing this will override the `tax_rates` array on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `tax_rates`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :tax_rates
# If an item with the `price` already exists, passing this will override the `trial` configuration on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `trial`.
sig { returns(T.nilable(::Stripe::Quote::CreateParams::Line::Action::SetItem::Trial)) }
attr_accessor :trial
sig {
params(discounts: T.nilable(T::Array[::Stripe::Quote::CreateParams::Line::Action::SetItem::Discount]), metadata: T.nilable(T::Hash[String, String]), price: String, quantity: T.nilable(Integer), tax_rates: T.nilable(T::Array[String]), trial: T.nilable(::Stripe::Quote::CreateParams::Line::Action::SetItem::Trial)).void
}
def initialize(
discounts: nil,
metadata: nil,
price: nil,
quantity: nil,
tax_rates: nil,
trial: nil
); end
end
# Details for the `add_discount` type.
sig { returns(T.nilable(::Stripe::Quote::CreateParams::Line::Action::AddDiscount)) }
attr_accessor :add_discount
# Details for the `add_item` type.
sig { returns(T.nilable(::Stripe::Quote::CreateParams::Line::Action::AddItem)) }
attr_accessor :add_item
# Details for the `add_metadata` type: specify a hash of key-value pairs.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :add_metadata
# Details for the `remove_discount` type.
sig { returns(T.nilable(::Stripe::Quote::CreateParams::Line::Action::RemoveDiscount)) }
attr_accessor :remove_discount
# Details for the `remove_item` type.
sig { returns(T.nilable(::Stripe::Quote::CreateParams::Line::Action::RemoveItem)) }
attr_accessor :remove_item
# Details for the `remove_metadata` type: specify an array of metadata keys.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :remove_metadata
# Details for the `set_discounts` type.
sig {
returns(T.nilable(T::Array[::Stripe::Quote::CreateParams::Line::Action::SetDiscount]))
}
attr_accessor :set_discounts
# Details for the `set_items` type.
sig { returns(T.nilable(T::Array[::Stripe::Quote::CreateParams::Line::Action::SetItem])) }
attr_accessor :set_items
# Details for the `set_metadata` type: specify an array of key-value pairs.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :set_metadata
# The type of action the quote line performs.
sig { returns(String) }
attr_accessor :type
sig {
params(add_discount: T.nilable(::Stripe::Quote::CreateParams::Line::Action::AddDiscount), add_item: T.nilable(::Stripe::Quote::CreateParams::Line::Action::AddItem), add_metadata: T.nilable(T::Hash[String, String]), remove_discount: T.nilable(::Stripe::Quote::CreateParams::Line::Action::RemoveDiscount), remove_item: T.nilable(::Stripe::Quote::CreateParams::Line::Action::RemoveItem), remove_metadata: T.nilable(T::Array[String]), set_discounts: T.nilable(T::Array[::Stripe::Quote::CreateParams::Line::Action::SetDiscount]), set_items: T.nilable(T::Array[::Stripe::Quote::CreateParams::Line::Action::SetItem]), set_metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), type: String).void
}
def initialize(
add_discount: nil,
add_item: nil,
add_metadata: nil,
remove_discount: nil,
remove_item: nil,
remove_metadata: nil,
set_discounts: nil,
set_items: nil,
set_metadata: nil,
type: nil
); end
end
class AppliesTo < Stripe::RequestParams
# A custom string that identifies a new subscription schedule being created upon quote acceptance. All quote lines with the same `new_reference` field will be applied to the creation of a new subscription schedule.
sig { returns(T.nilable(String)) }
attr_accessor :new_reference
# The ID of the schedule the line applies to.
sig { returns(T.nilable(String)) }
attr_accessor :subscription_schedule
# Describes whether the quote line is affecting a new schedule or an existing schedule.
sig { returns(String) }
attr_accessor :type
sig {
params(new_reference: T.nilable(String), subscription_schedule: T.nilable(String), type: String).void
}
def initialize(new_reference: nil, subscription_schedule: nil, type: nil); end
end
class CancelSubscriptionSchedule < Stripe::RequestParams
# Timestamp helper to cancel the underlying schedule on the accompanying line's start date. Must be set to `line_starts_at`.
sig { returns(String) }
attr_accessor :cancel_at
# If the subscription schedule is `active`, indicates if a final invoice will be generated that contains any un-invoiced metered usage and new/pending proration invoice items. Boolean that defaults to `true`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :invoice_now
# If the subscription schedule is `active`, indicates if the cancellation should be prorated. Boolean that defaults to `true`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :prorate
sig {
params(cancel_at: String, invoice_now: T.nilable(T::Boolean), prorate: T.nilable(T::Boolean)).void
}
def initialize(cancel_at: nil, invoice_now: nil, prorate: nil); end
end
class EndsAt < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
# The ID of a specific discount.
sig { returns(String) }
attr_accessor :discount
sig { params(discount: String).void }
def initialize(discount: nil); end
end
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Use the `end` time of a given discount.
sig { returns(T.nilable(::Stripe::Quote::CreateParams::Line::EndsAt::DiscountEnd)) }
attr_accessor :discount_end
# Time span for the quote line starting from the `starts_at` date.
sig { returns(T.nilable(::Stripe::Quote::CreateParams::Line::EndsAt::Duration)) }
attr_accessor :duration
# A precise Unix timestamp.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# Select a way to pass in `ends_at`.
sig { returns(String) }
attr_accessor :type
sig {
params(discount_end: T.nilable(::Stripe::Quote::CreateParams::Line::EndsAt::DiscountEnd), duration: T.nilable(::Stripe::Quote::CreateParams::Line::EndsAt::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(discount_end: nil, duration: nil, timestamp: nil, type: nil); end
end
class SetPauseCollection < Stripe::RequestParams
class Set < Stripe::RequestParams
# The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`.
sig { returns(String) }
attr_accessor :behavior
sig { params(behavior: String).void }
def initialize(behavior: nil); end
end
# Details of the pause_collection behavior to apply to the amendment.
sig { returns(T.nilable(::Stripe::Quote::CreateParams::Line::SetPauseCollection::Set)) }
attr_accessor :set
# Determines the type of the pause_collection amendment.
sig { returns(String) }
attr_accessor :type
sig {
params(set: T.nilable(::Stripe::Quote::CreateParams::Line::SetPauseCollection::Set), type: String).void
}
def initialize(set: nil, type: nil); end
end
class StartsAt < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
# The ID of a specific discount.
sig { returns(String) }
attr_accessor :discount
sig { params(discount: String).void }
def initialize(discount: nil); end
end
class LineEndsAt < Stripe::RequestParams
# The position of the previous quote line in the `lines` array after which this line should begin. Indexes start from 0 and must be less than the index of the current line in the array.
sig { returns(T.nilable(Integer)) }
attr_accessor :index
sig { params(index: T.nilable(Integer)).void }
def initialize(index: nil); end
end
# Use the `end` time of a given discount.
sig { returns(T.nilable(::Stripe::Quote::CreateParams::Line::StartsAt::DiscountEnd)) }
attr_accessor :discount_end
# The timestamp the given line ends at.
sig { returns(T.nilable(::Stripe::Quote::CreateParams::Line::StartsAt::LineEndsAt)) }
attr_accessor :line_ends_at
# A precise Unix timestamp.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# Select a way to pass in `starts_at`.
sig { returns(String) }
attr_accessor :type
sig {
params(discount_end: T.nilable(::Stripe::Quote::CreateParams::Line::StartsAt::DiscountEnd), line_ends_at: T.nilable(::Stripe::Quote::CreateParams::Line::StartsAt::LineEndsAt), timestamp: T.nilable(Integer), type: String).void
}
def initialize(discount_end: nil, line_ends_at: nil, timestamp: nil, type: nil); end
end
class TrialSettings < Stripe::RequestParams
class EndBehavior < Stripe::RequestParams
# Configure how an opt-in following a paid trial is billed when using `billing_behavior: prorate_up_front`.
sig { returns(T.nilable(String)) }
attr_accessor :prorate_up_front
sig { params(prorate_up_front: T.nilable(String)).void }
def initialize(prorate_up_front: nil); end
end
# Defines how the subscription should behave when a trial ends.
sig {
returns(T.nilable(::Stripe::Quote::CreateParams::Line::TrialSettings::EndBehavior))
}
attr_accessor :end_behavior
sig {
params(end_behavior: T.nilable(::Stripe::Quote::CreateParams::Line::TrialSettings::EndBehavior)).void
}
def initialize(end_behavior: nil); end
end
# An array of operations the quote line performs.
sig { returns(T.nilable(T::Array[::Stripe::Quote::CreateParams::Line::Action])) }
attr_accessor :actions
# Details to identify the subscription schedule the quote line applies to.
sig { returns(T.nilable(::Stripe::Quote::CreateParams::Line::AppliesTo)) }
attr_accessor :applies_to
# For point-in-time quote lines (having no `ends_at` timestamp), this attribute lets you set or remove whether the subscription's billing cycle anchor is reset at the Quote Line `starts_at` timestamp.For time-span based quote lines (having both `starts_at` and `ends_at`), the only valid value is `automatic`, which removes any previously configured billing cycle anchor resets during the window of time spanning the quote line.
sig { returns(T.nilable(String)) }
attr_accessor :billing_cycle_anchor
# A point-in-time operation that cancels an existing subscription schedule at the line's starts_at timestamp. Currently only compatible with `quote_acceptance_date` for `starts_at`. When using cancel_subscription_schedule, the subscription schedule on the quote remains unalterable, except for modifications to the metadata, collection_method or invoice_settings.
sig { returns(T.nilable(::Stripe::Quote::CreateParams::Line::CancelSubscriptionSchedule)) }
attr_accessor :cancel_subscription_schedule
# Details to identify the end of the time range modified by the proposed change. If not supplied, the quote line is considered a point-in-time operation that only affects the exact timestamp at `starts_at`, and a restricted set of attributes is supported on the quote line.
sig { returns(T.nilable(::Stripe::Quote::CreateParams::Line::EndsAt)) }
attr_accessor :ends_at
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
# Defines how to pause collection for the underlying subscription throughout the duration of the amendment.
sig { returns(T.nilable(::Stripe::Quote::CreateParams::Line::SetPauseCollection)) }
attr_accessor :set_pause_collection
# Timestamp helper to end the underlying schedule early, based on the acompanying line's start or end date.
sig { returns(T.nilable(String)) }
attr_accessor :set_schedule_end
# Details to identify the earliest timestamp where the proposed change should take effect.
sig { returns(T.nilable(::Stripe::Quote::CreateParams::Line::StartsAt)) }
attr_accessor :starts_at
# Settings related to subscription trials.
sig { returns(T.nilable(::Stripe::Quote::CreateParams::Line::TrialSettings)) }
attr_accessor :trial_settings
sig {
params(actions: T.nilable(T::Array[::Stripe::Quote::CreateParams::Line::Action]), applies_to: T.nilable(::Stripe::Quote::CreateParams::Line::AppliesTo), billing_cycle_anchor: T.nilable(String), cancel_subscription_schedule: T.nilable(::Stripe::Quote::CreateParams::Line::CancelSubscriptionSchedule), ends_at: T.nilable(::Stripe::Quote::CreateParams::Line::EndsAt), proration_behavior: T.nilable(String), set_pause_collection: T.nilable(::Stripe::Quote::CreateParams::Line::SetPauseCollection), set_schedule_end: T.nilable(String), starts_at: T.nilable(::Stripe::Quote::CreateParams::Line::StartsAt), trial_settings: T.nilable(::Stripe::Quote::CreateParams::Line::TrialSettings)).void
}
def initialize(
actions: nil,
applies_to: nil,
billing_cycle_anchor: nil,
cancel_subscription_schedule: nil,
ends_at: nil,
proration_behavior: nil,
set_pause_collection: nil,
set_schedule_end: nil,
starts_at: nil,
trial_settings: nil
); end
end
class LineItem < Stripe::RequestParams
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::Quote::CreateParams::LineItem::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::Quote::CreateParams::LineItem::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig { returns(T.nilable(::Stripe::Quote::CreateParams::LineItem::Discount::DiscountEnd)) }
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::Quote::CreateParams::LineItem::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class PriceData < Stripe::RequestParams
class Recurring < Stripe::RequestParams
# Specifies billing frequency. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: T.nilable(Integer)).void }
def initialize(interval: nil, interval_count: nil); end
end
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
sig { returns(String) }
attr_accessor :product
# The recurring components of a price such as `interval` and `interval_count`.
sig { returns(T.nilable(::Stripe::Quote::CreateParams::LineItem::PriceData::Recurring)) }
attr_accessor :recurring
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, product: String, recurring: T.nilable(::Stripe::Quote::CreateParams::LineItem::PriceData::Recurring), tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
recurring: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
# The discounts applied to this line item.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Quote::CreateParams::LineItem::Discount]))))
}
attr_accessor :discounts
# The ID of the price object. One of `price` or `price_data` is required.
sig { returns(T.nilable(String)) }
attr_accessor :price
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
sig { returns(T.nilable(::Stripe::Quote::CreateParams::LineItem::PriceData)) }
attr_accessor :price_data
# The quantity of the line item.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# The tax rates which apply to the line item. When set, the `default_tax_rates` on the quote do not apply to this line item.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
sig {
params(discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Quote::CreateParams::LineItem::Discount]))), price: T.nilable(String), price_data: T.nilable(::Stripe::Quote::CreateParams::LineItem::PriceData), quantity: T.nilable(Integer), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String])))).void
}
def initialize(
discounts: nil,
price: nil,
price_data: nil,
quantity: nil,
tax_rates: nil
); end
end
class SubscriptionData < Stripe::RequestParams
class BillOnAcceptance < Stripe::RequestParams
class BillFrom < Stripe::RequestParams
class LineStartsAt < Stripe::RequestParams
# The ID of a quote line.
sig { returns(T.nilable(String)) }
attr_accessor :id
# The position of the previous quote line in the `lines` array after which this line should begin. Indexes start from 0 and must be less than the index of the current line in the array.
sig { returns(T.nilable(Integer)) }
attr_accessor :index
sig { params(id: T.nilable(String), index: T.nilable(Integer)).void }
def initialize(id: nil, index: nil); end
end
# Details of a Quote line to start the bill period from.
sig {
returns(T.nilable(::Stripe::Quote::CreateParams::SubscriptionData::BillOnAcceptance::BillFrom::LineStartsAt))
}
attr_accessor :line_starts_at
# A precise Unix timestamp.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of method to specify the `bill_from` time.
sig { returns(String) }
attr_accessor :type
sig {
params(line_starts_at: T.nilable(::Stripe::Quote::CreateParams::SubscriptionData::BillOnAcceptance::BillFrom::LineStartsAt), timestamp: T.nilable(Integer), type: String).void
}
def initialize(line_starts_at: nil, timestamp: nil, type: nil); end
end
class BillUntil < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
class LineEndsAt < Stripe::RequestParams
# The ID of a quote line.
sig { returns(T.nilable(String)) }
attr_accessor :id
# The position of the previous quote line in the `lines` array after which this line should begin. Indexes start from 0 and must be less than the index of the current line in the array.
sig { returns(T.nilable(Integer)) }
attr_accessor :index
sig { params(id: T.nilable(String), index: T.nilable(Integer)).void }
def initialize(id: nil, index: nil); end
end
# Details of the duration over which to bill.
sig {
returns(T.nilable(::Stripe::Quote::CreateParams::SubscriptionData::BillOnAcceptance::BillUntil::Duration))
}
attr_accessor :duration
# Details of a Quote line item from which to bill until.
sig {
returns(T.nilable(::Stripe::Quote::CreateParams::SubscriptionData::BillOnAcceptance::BillUntil::LineEndsAt))
}
attr_accessor :line_ends_at
# A precise Unix timestamp.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of method to specify the `bill_until` time.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::Quote::CreateParams::SubscriptionData::BillOnAcceptance::BillUntil::Duration), line_ends_at: T.nilable(::Stripe::Quote::CreateParams::SubscriptionData::BillOnAcceptance::BillUntil::LineEndsAt), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, line_ends_at: nil, timestamp: nil, type: nil); end
end
# The start of the period to bill from when the Quote is accepted.
sig {
returns(T.nilable(::Stripe::Quote::CreateParams::SubscriptionData::BillOnAcceptance::BillFrom))
}
attr_accessor :bill_from
# The end of the period to bill until when the Quote is accepted.
sig {
returns(T.nilable(::Stripe::Quote::CreateParams::SubscriptionData::BillOnAcceptance::BillUntil))
}
attr_accessor :bill_until
sig {
params(bill_from: T.nilable(::Stripe::Quote::CreateParams::SubscriptionData::BillOnAcceptance::BillFrom), bill_until: T.nilable(::Stripe::Quote::CreateParams::SubscriptionData::BillOnAcceptance::BillUntil)).void
}
def initialize(bill_from: nil, bill_until: nil); end
end
class Prebilling < Stripe::RequestParams
# This is used to determine the number of billing cycles to prebill.
sig { returns(Integer) }
attr_accessor :iterations
sig { params(iterations: Integer).void }
def initialize(iterations: nil); end
end
# Describes the period to bill for upon accepting the quote.
sig {
returns(T.nilable(::Stripe::Quote::CreateParams::SubscriptionData::BillOnAcceptance))
}
attr_accessor :bill_on_acceptance
# Configures when the subscription schedule generates prorations for phase transitions. Possible values are `prorate_on_next_phase` or `prorate_up_front` with the default being `prorate_on_next_phase`. `prorate_on_next_phase` will apply phase changes and generate prorations at transition time. `prorate_up_front` will bill for all phases within the current billing cycle up front.
sig { returns(T.nilable(String)) }
attr_accessor :billing_behavior
# When specified as `reset`, the subscription will always start a new billing period when the quote is accepted.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :billing_cycle_anchor
# Controls how prorations and invoices for subscriptions are calculated and orchestrated.
sig { returns(T.nilable(String)) }
attr_accessor :billing_mode
# The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
sig { returns(T.nilable(String)) }
attr_accessor :description
# When creating a new subscription, the date of which the subscription schedule will start after the quote is accepted. When updating a subscription, the date of which the subscription will be updated using a subscription schedule. The special value `current_period_end` can be provided to update a subscription at the end of its current period. The `effective_date` is ignored if it is in the past when the quote is accepted.
sig { returns(T.nilable(T.nilable(T.any(String, T.any(String, Integer))))) }
attr_accessor :effective_date
# Behavior of the subscription schedule and underlying subscription when it ends.
sig { returns(T.nilable(String)) }
attr_accessor :end_behavior
# The id of a subscription that the quote will update. By default, the quote will contain the state of the subscription (such as line items, collection method and billing thresholds) unless overridden.
sig { returns(T.nilable(String)) }
attr_accessor :from_subscription
# Set of [key-value pairs](https://stripe.com/docs/api/metadata) that will set metadata on the subscription or subscription schedule when the quote is accepted. If a recurring price is included in `line_items`, this field will be passed to the resulting subscription's `metadata` field. If `subscription_data.effective_date` is used, this field will be passed to the resulting subscription schedule's `phases.metadata` field. Unlike object-level metadata, this field is declarative. Updates will clear prior values.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# If specified, the invoicing for the given billing cycle iterations will be processed when the quote is accepted. Cannot be used with `effective_date`.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Quote::CreateParams::SubscriptionData::Prebilling))))
}
attr_accessor :prebilling
# Determines how to handle [prorations](https://stripe.com/docs/subscriptions/billing-cycle#prorations). When creating a subscription, valid values are `create_prorations` or `none`.
#
# When updating a subscription, valid values are `create_prorations`, `none`, or `always_invoice`.
#
# Passing `create_prorations` will cause proration invoice items to be created when applicable. These proration items will only be invoiced immediately under [certain conditions](https://stripe.com/docs/subscriptions/upgrading-downgrading#immediate-payment). In order to always invoice immediately for prorations, pass `always_invoice`.
#
# Prorations can be disabled by passing `none`.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
# Integer representing the number of trial period days before the customer is charged for the first time.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :trial_period_days
sig {
params(bill_on_acceptance: T.nilable(::Stripe::Quote::CreateParams::SubscriptionData::BillOnAcceptance), billing_behavior: T.nilable(String), billing_cycle_anchor: T.nilable(T.nilable(String)), billing_mode: T.nilable(String), description: T.nilable(String), effective_date: T.nilable(T.nilable(T.any(String, T.any(String, Integer)))), end_behavior: T.nilable(String), from_subscription: T.nilable(String), metadata: T.nilable(T::Hash[String, String]), prebilling: T.nilable(T.nilable(T.any(String, ::Stripe::Quote::CreateParams::SubscriptionData::Prebilling))), proration_behavior: T.nilable(String), trial_period_days: T.nilable(T.nilable(T.any(String, Integer)))).void
}
def initialize(
bill_on_acceptance: nil,
billing_behavior: nil,
billing_cycle_anchor: nil,
billing_mode: nil,
description: nil,
effective_date: nil,
end_behavior: nil,
from_subscription: nil,
metadata: nil,
prebilling: nil,
proration_behavior: nil,
trial_period_days: nil
); end
end
class SubscriptionDataOverride < Stripe::RequestParams
class AppliesTo < Stripe::RequestParams
# A custom string that identifies a new subscription schedule being created upon quote acceptance. All quote lines with the same `new_reference` field will be applied to the creation of a new subscription schedule.
sig { returns(T.nilable(String)) }
attr_accessor :new_reference
# The ID of the schedule the line applies to.
sig { returns(T.nilable(String)) }
attr_accessor :subscription_schedule
# Describes whether the quote line is affecting a new schedule or an existing schedule.
sig { returns(String) }
attr_accessor :type
sig {
params(new_reference: T.nilable(String), subscription_schedule: T.nilable(String), type: String).void
}
def initialize(new_reference: nil, subscription_schedule: nil, type: nil); end
end
class BillOnAcceptance < Stripe::RequestParams
class BillFrom < Stripe::RequestParams
class LineStartsAt < Stripe::RequestParams
# The ID of a quote line.
sig { returns(T.nilable(String)) }
attr_accessor :id
# The position of the previous quote line in the `lines` array after which this line should begin. Indexes start from 0 and must be less than the index of the current line in the array.
sig { returns(T.nilable(Integer)) }
attr_accessor :index
sig { params(id: T.nilable(String), index: T.nilable(Integer)).void }
def initialize(id: nil, index: nil); end
end
# Details of a Quote line to start the bill period from.
sig {
returns(T.nilable(::Stripe::Quote::CreateParams::SubscriptionDataOverride::BillOnAcceptance::BillFrom::LineStartsAt))
}
attr_accessor :line_starts_at
# A precise Unix timestamp.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of method to specify the `bill_from` time.
sig { returns(String) }
attr_accessor :type
sig {
params(line_starts_at: T.nilable(::Stripe::Quote::CreateParams::SubscriptionDataOverride::BillOnAcceptance::BillFrom::LineStartsAt), timestamp: T.nilable(Integer), type: String).void
}
def initialize(line_starts_at: nil, timestamp: nil, type: nil); end
end
class BillUntil < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
class LineEndsAt < Stripe::RequestParams
# The ID of a quote line.
sig { returns(T.nilable(String)) }
attr_accessor :id
# The position of the previous quote line in the `lines` array after which this line should begin. Indexes start from 0 and must be less than the index of the current line in the array.
sig { returns(T.nilable(Integer)) }
attr_accessor :index
sig { params(id: T.nilable(String), index: T.nilable(Integer)).void }
def initialize(id: nil, index: nil); end
end
# Details of the duration over which to bill.
sig {
returns(T.nilable(::Stripe::Quote::CreateParams::SubscriptionDataOverride::BillOnAcceptance::BillUntil::Duration))
}
attr_accessor :duration
# Details of a Quote line item from which to bill until.
sig {
returns(T.nilable(::Stripe::Quote::CreateParams::SubscriptionDataOverride::BillOnAcceptance::BillUntil::LineEndsAt))
}
attr_accessor :line_ends_at
# A precise Unix timestamp.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of method to specify the `bill_until` time.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::Quote::CreateParams::SubscriptionDataOverride::BillOnAcceptance::BillUntil::Duration), line_ends_at: T.nilable(::Stripe::Quote::CreateParams::SubscriptionDataOverride::BillOnAcceptance::BillUntil::LineEndsAt), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, line_ends_at: nil, timestamp: nil, type: nil); end
end
# The start of the period to bill from when the Quote is accepted.
sig {
returns(T.nilable(::Stripe::Quote::CreateParams::SubscriptionDataOverride::BillOnAcceptance::BillFrom))
}
attr_accessor :bill_from
# The end of the period to bill until when the Quote is accepted.
sig {
returns(T.nilable(::Stripe::Quote::CreateParams::SubscriptionDataOverride::BillOnAcceptance::BillUntil))
}
attr_accessor :bill_until
sig {
params(bill_from: T.nilable(::Stripe::Quote::CreateParams::SubscriptionDataOverride::BillOnAcceptance::BillFrom), bill_until: T.nilable(::Stripe::Quote::CreateParams::SubscriptionDataOverride::BillOnAcceptance::BillUntil)).void
}
def initialize(bill_from: nil, bill_until: nil); end
end
# Whether the override applies to an existing Subscription Schedule or a new Subscription Schedule.
sig { returns(::Stripe::Quote::CreateParams::SubscriptionDataOverride::AppliesTo) }
attr_accessor :applies_to
# Describes the period to bill for upon accepting the quote.
sig {
returns(T.nilable(::Stripe::Quote::CreateParams::SubscriptionDataOverride::BillOnAcceptance))
}
attr_accessor :bill_on_acceptance
# Configures when the subscription schedule generates prorations for phase transitions. Possible values are `prorate_on_next_phase` or `prorate_up_front` with the default being `prorate_on_next_phase`. `prorate_on_next_phase` will apply phase changes and generate prorations at transition time. `prorate_up_front` will bill for all phases within the current billing cycle up front.
sig { returns(T.nilable(String)) }
attr_accessor :billing_behavior
# The customer the Subscription Data override applies to. This is only relevant when `applies_to.type=new_reference`.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Behavior of the subscription schedule and underlying subscription when it ends.
sig { returns(T.nilable(String)) }
attr_accessor :end_behavior
# Determines how to handle [prorations](https://stripe.com/docs/subscriptions/billing-cycle#prorations). When creating a subscription, valid values are `create_prorations` or `none`.
#
# When updating a subscription, valid values are `create_prorations`, `none`, or `always_invoice`.
#
# Passing `create_prorations` will cause proration invoice items to be created when applicable. These proration items will only be invoiced immediately under [certain conditions](https://stripe.com/docs/subscriptions/upgrading-downgrading#immediate-payment). In order to always invoice immediately for prorations, pass `always_invoice`.
#
# Prorations can be disabled by passing `none`.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
sig {
params(applies_to: ::Stripe::Quote::CreateParams::SubscriptionDataOverride::AppliesTo, bill_on_acceptance: T.nilable(::Stripe::Quote::CreateParams::SubscriptionDataOverride::BillOnAcceptance), billing_behavior: T.nilable(String), customer: T.nilable(String), description: T.nilable(String), end_behavior: T.nilable(String), proration_behavior: T.nilable(String)).void
}
def initialize(
applies_to: nil,
bill_on_acceptance: nil,
billing_behavior: nil,
customer: nil,
description: nil,
end_behavior: nil,
proration_behavior: nil
); end
end
class TransferData < Stripe::RequestParams
# The amount that will be transferred automatically when the invoice is paid. If no amount is set, the full amount is transferred. There cannot be any line items with recurring prices when using this field.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination. There must be at least 1 line item with a recurring price to use this field.
sig { returns(T.nilable(Float)) }
attr_accessor :amount_percent
# ID of an existing, connected Stripe account.
sig { returns(String) }
attr_accessor :destination
sig {
params(amount: T.nilable(Integer), amount_percent: T.nilable(Float), destination: String).void
}
def initialize(amount: nil, amount_percent: nil, destination: nil); end
end
# Set to true to allow quote lines to have `starts_at` in the past if collection is paused between `starts_at` and now.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :allow_backdated_lines
# The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. There cannot be any line items with recurring prices when using this field.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :application_fee_amount
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. There must be at least 1 line item with a recurring price to use this field.
sig { returns(T.nilable(T.nilable(T.any(String, Float)))) }
attr_accessor :application_fee_percent
# Settings for automatic tax lookup for this quote and resulting invoices and subscriptions.
sig { returns(T.nilable(::Stripe::Quote::CreateParams::AutomaticTax)) }
attr_accessor :automatic_tax
# Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay invoices at the end of the subscription cycle or at invoice finalization using the default payment method attached to the subscription or customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically`.
sig { returns(T.nilable(String)) }
attr_accessor :collection_method
# The customer for which this quote belongs to. A customer is required before finalizing the quote. Once specified, it cannot be changed.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# The account for which this quote belongs to. A customer or account is required before finalizing the quote. Once specified, it cannot be changed.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# The tax rates that will apply to any line item that does not have `tax_rates` set.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :default_tax_rates
# A description that will be displayed on the quote PDF. If no value is passed, the default description configured in your [quote template settings](https://dashboard.stripe.com/settings/billing/quote) will be used.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :description
# The discounts applied to the quote.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Quote::CreateParams::Discount]))))
}
attr_accessor :discounts
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A future timestamp on which the quote will be canceled if in `open` or `draft` status. Measured in seconds since the Unix epoch. If no value is passed, the default expiration date configured in your [quote template settings](https://dashboard.stripe.com/settings/billing/quote) will be used.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_at
# A footer that will be displayed on the quote PDF. If no value is passed, the default footer configured in your [quote template settings](https://dashboard.stripe.com/settings/billing/quote) will be used.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :footer
# Clone an existing quote. The new quote will be created in `status=draft`. When using this parameter, you cannot specify any other parameters except for `expires_at`.
sig { returns(T.nilable(::Stripe::Quote::CreateParams::FromQuote)) }
attr_accessor :from_quote
# A header that will be displayed on the quote PDF. If no value is passed, the default header configured in your [quote template settings](https://dashboard.stripe.com/settings/billing/quote) will be used.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :header
# All invoices will be billed using the specified settings.
sig { returns(T.nilable(::Stripe::Quote::CreateParams::InvoiceSettings)) }
attr_accessor :invoice_settings
# A list of line items the customer is being quoted for. Each line item includes information about the product, the quantity, and the resulting cost.
sig { returns(T.nilable(T::Array[::Stripe::Quote::CreateParams::LineItem])) }
attr_accessor :line_items
# A list of [quote lines](https://docs.stripe.com/api/quote_lines) on the quote. These lines describe changes, in the order provided, that will be used to create new subscription schedules or update existing subscription schedules when the quote is accepted.
sig { returns(T.nilable(T::Array[::Stripe::Quote::CreateParams::Line])) }
attr_accessor :lines
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The account on behalf of which to charge.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :on_behalf_of
# When creating a subscription or subscription schedule, the specified configuration data will be used. There must be at least one line item with a recurring price for a subscription or subscription schedule to be created. A subscription schedule is created if `subscription_data[effective_date]` is present and in the future, otherwise a subscription is created.
sig { returns(T.nilable(::Stripe::Quote::CreateParams::SubscriptionData)) }
attr_accessor :subscription_data
# List representing overrides for `subscription_data` configurations for specific subscription schedules.
sig { returns(T.nilable(T::Array[::Stripe::Quote::CreateParams::SubscriptionDataOverride])) }
attr_accessor :subscription_data_overrides
# ID of the test clock to attach to the quote.
sig { returns(T.nilable(String)) }
attr_accessor :test_clock
# The data with which to automatically create a Transfer for each of the invoices.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Quote::CreateParams::TransferData))))
}
attr_accessor :transfer_data
sig {
params(allow_backdated_lines: T.nilable(T::Boolean), application_fee_amount: T.nilable(T.nilable(T.any(String, Integer))), application_fee_percent: T.nilable(T.nilable(T.any(String, Float))), automatic_tax: T.nilable(::Stripe::Quote::CreateParams::AutomaticTax), collection_method: T.nilable(String), customer: T.nilable(String), customer_account: T.nilable(String), default_tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String]))), description: T.nilable(T.nilable(String)), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Quote::CreateParams::Discount]))), expand: T.nilable(T::Array[String]), expires_at: T.nilable(Integer), footer: T.nilable(T.nilable(String)), from_quote: T.nilable(::Stripe::Quote::CreateParams::FromQuote), header: T.nilable(T.nilable(String)), invoice_settings: T.nilable(::Stripe::Quote::CreateParams::InvoiceSettings), line_items: T.nilable(T::Array[::Stripe::Quote::CreateParams::LineItem]), lines: T.nilable(T::Array[::Stripe::Quote::CreateParams::Line]), metadata: T.nilable(T::Hash[String, String]), on_behalf_of: T.nilable(T.nilable(String)), subscription_data: T.nilable(::Stripe::Quote::CreateParams::SubscriptionData), subscription_data_overrides: T.nilable(T::Array[::Stripe::Quote::CreateParams::SubscriptionDataOverride]), test_clock: T.nilable(String), transfer_data: T.nilable(T.nilable(T.any(String, ::Stripe::Quote::CreateParams::TransferData)))).void
}
def initialize(
allow_backdated_lines: nil,
application_fee_amount: nil,
application_fee_percent: nil,
automatic_tax: nil,
collection_method: nil,
customer: nil,
customer_account: nil,
default_tax_rates: nil,
description: nil,
discounts: nil,
expand: nil,
expires_at: nil,
footer: nil,
from_quote: nil,
header: nil,
invoice_settings: nil,
line_items: nil,
lines: nil,
metadata: nil,
on_behalf_of: nil,
subscription_data: nil,
subscription_data_overrides: nil,
test_clock: nil,
transfer_data: nil
); end
end
class UpdateParams < Stripe::RequestParams
class AutomaticTax < Stripe::RequestParams
class Liability < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# Controls whether Stripe will automatically compute tax on the resulting invoices or subscriptions as well as the quote itself.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
sig { returns(T.nilable(::Stripe::Quote::UpdateParams::AutomaticTax::Liability)) }
attr_accessor :liability
sig {
params(enabled: T::Boolean, liability: T.nilable(::Stripe::Quote::UpdateParams::AutomaticTax::Liability)).void
}
def initialize(enabled: nil, liability: nil); end
end
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig { returns(T.nilable(::Stripe::Quote::UpdateParams::Discount::DiscountEnd::Duration)) }
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::Quote::UpdateParams::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig { returns(T.nilable(::Stripe::Quote::UpdateParams::Discount::DiscountEnd)) }
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::Quote::UpdateParams::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class InvoiceSettings < Stripe::RequestParams
class Issuer < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# Number of days within which a customer must pay the invoice generated by this quote. This value will be `null` for quotes where `collection_method=charge_automatically`.
sig { returns(T.nilable(Integer)) }
attr_accessor :days_until_due
# The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
sig { returns(T.nilable(::Stripe::Quote::UpdateParams::InvoiceSettings::Issuer)) }
attr_accessor :issuer
sig {
params(days_until_due: T.nilable(Integer), issuer: T.nilable(::Stripe::Quote::UpdateParams::InvoiceSettings::Issuer)).void
}
def initialize(days_until_due: nil, issuer: nil); end
end
class Line < Stripe::RequestParams
class Action < Stripe::RequestParams
class AddDiscount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
# The coupon code to redeem.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# An ID of an existing discount for a coupon that was already redeemed.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::Quote::UpdateParams::Line::Action::AddDiscount::DiscountEnd))
}
attr_accessor :discount_end
# The index, starting at 0, at which to position the new discount. When not supplied, Stripe defaults to appending the discount to the end of the `discounts` array.
sig { returns(T.nilable(Integer)) }
attr_accessor :index
# The promotion code to redeem.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::Quote::UpdateParams::Line::Action::AddDiscount::DiscountEnd), index: T.nilable(Integer), promotion_code: T.nilable(String)).void
}
def initialize(
coupon: nil,
discount: nil,
discount_end: nil,
index: nil,
promotion_code: nil
); end
end
class AddItem < Stripe::RequestParams
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::Quote::UpdateParams::Line::Action::AddItem::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::Quote::UpdateParams::Line::Action::AddItem::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::Quote::UpdateParams::Line::Action::AddItem::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::Quote::UpdateParams::Line::Action::AddItem::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(
coupon: nil,
discount: nil,
discount_end: nil,
promotion_code: nil
); end
end
class Trial < Stripe::RequestParams
# List of price IDs which, if present on the subscription following a paid trial, constitute opting-in to the paid trial. Currently only supports at most 1 price ID.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :converts_to
# Determines the type of trial for this item.
sig { returns(String) }
attr_accessor :type
sig { params(converts_to: T.nilable(T::Array[String]), type: String).void }
def initialize(converts_to: nil, type: nil); end
end
# The discounts applied to the item. Subscription item discounts are applied before subscription discounts.
sig {
returns(T.nilable(T::Array[::Stripe::Quote::UpdateParams::Line::Action::AddItem::Discount]))
}
attr_accessor :discounts
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The ID of the price object.
sig { returns(String) }
attr_accessor :price
# Quantity for this item.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# The tax rates that apply to this subscription item. When set, the `default_tax_rates` on the subscription do not apply to this `subscription_item`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :tax_rates
# Options that configure the trial on the subscription item.
sig { returns(T.nilable(::Stripe::Quote::UpdateParams::Line::Action::AddItem::Trial)) }
attr_accessor :trial
sig {
params(discounts: T.nilable(T::Array[::Stripe::Quote::UpdateParams::Line::Action::AddItem::Discount]), metadata: T.nilable(T::Hash[String, String]), price: String, quantity: T.nilable(Integer), tax_rates: T.nilable(T::Array[String]), trial: T.nilable(::Stripe::Quote::UpdateParams::Line::Action::AddItem::Trial)).void
}
def initialize(
discounts: nil,
metadata: nil,
price: nil,
quantity: nil,
tax_rates: nil,
trial: nil
); end
end
class RemoveDiscount < Stripe::RequestParams
# The coupon code to remove from the `discounts` array.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# The ID of a discount to remove from the `discounts` array.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# The ID of a promotion code to remove from the `discounts` array.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, promotion_code: nil); end
end
class RemoveItem < Stripe::RequestParams
# ID of a price to remove.
sig { returns(String) }
attr_accessor :price
sig { params(price: String).void }
def initialize(price: nil); end
end
class SetDiscount < Stripe::RequestParams
# The coupon code to replace the `discounts` array with.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# An ID of an existing discount to replace the `discounts` array with.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# An ID of an existing promotion code to replace the `discounts` array with.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, promotion_code: nil); end
end
class SetItem < Stripe::RequestParams
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::Quote::UpdateParams::Line::Action::SetItem::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::Quote::UpdateParams::Line::Action::SetItem::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::Quote::UpdateParams::Line::Action::SetItem::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::Quote::UpdateParams::Line::Action::SetItem::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(
coupon: nil,
discount: nil,
discount_end: nil,
promotion_code: nil
); end
end
class Trial < Stripe::RequestParams
# List of price IDs which, if present on the subscription following a paid trial, constitute opting-in to the paid trial. Currently only supports at most 1 price ID.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :converts_to
# Determines the type of trial for this item.
sig { returns(String) }
attr_accessor :type
sig { params(converts_to: T.nilable(T::Array[String]), type: String).void }
def initialize(converts_to: nil, type: nil); end
end
# If an item with the `price` already exists, passing this will override the `discounts` array on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `discounts`.
sig {
returns(T.nilable(T::Array[::Stripe::Quote::UpdateParams::Line::Action::SetItem::Discount]))
}
attr_accessor :discounts
# If an item with the `price` already exists, passing this will override the `metadata` on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `metadata`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The ID of the price object.
sig { returns(String) }
attr_accessor :price
# If an item with the `price` already exists, passing this will override the quantity on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `quantity`.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# If an item with the `price` already exists, passing this will override the `tax_rates` array on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `tax_rates`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :tax_rates
# If an item with the `price` already exists, passing this will override the `trial` configuration on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `trial`.
sig { returns(T.nilable(::Stripe::Quote::UpdateParams::Line::Action::SetItem::Trial)) }
attr_accessor :trial
sig {
params(discounts: T.nilable(T::Array[::Stripe::Quote::UpdateParams::Line::Action::SetItem::Discount]), metadata: T.nilable(T::Hash[String, String]), price: String, quantity: T.nilable(Integer), tax_rates: T.nilable(T::Array[String]), trial: T.nilable(::Stripe::Quote::UpdateParams::Line::Action::SetItem::Trial)).void
}
def initialize(
discounts: nil,
metadata: nil,
price: nil,
quantity: nil,
tax_rates: nil,
trial: nil
); end
end
# Details for the `add_discount` type.
sig { returns(T.nilable(::Stripe::Quote::UpdateParams::Line::Action::AddDiscount)) }
attr_accessor :add_discount
# Details for the `add_item` type.
sig { returns(T.nilable(::Stripe::Quote::UpdateParams::Line::Action::AddItem)) }
attr_accessor :add_item
# Details for the `add_metadata` type: specify a hash of key-value pairs.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :add_metadata
# Details for the `remove_discount` type.
sig { returns(T.nilable(::Stripe::Quote::UpdateParams::Line::Action::RemoveDiscount)) }
attr_accessor :remove_discount
# Details for the `remove_item` type.
sig { returns(T.nilable(::Stripe::Quote::UpdateParams::Line::Action::RemoveItem)) }
attr_accessor :remove_item
# Details for the `remove_metadata` type: specify an array of metadata keys.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :remove_metadata
# Details for the `set_discounts` type.
sig {
returns(T.nilable(T::Array[::Stripe::Quote::UpdateParams::Line::Action::SetDiscount]))
}
attr_accessor :set_discounts
# Details for the `set_items` type.
sig { returns(T.nilable(T::Array[::Stripe::Quote::UpdateParams::Line::Action::SetItem])) }
attr_accessor :set_items
# Details for the `set_metadata` type: specify an array of key-value pairs.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :set_metadata
# The type of action the quote line performs.
sig { returns(String) }
attr_accessor :type
sig {
params(add_discount: T.nilable(::Stripe::Quote::UpdateParams::Line::Action::AddDiscount), add_item: T.nilable(::Stripe::Quote::UpdateParams::Line::Action::AddItem), add_metadata: T.nilable(T::Hash[String, String]), remove_discount: T.nilable(::Stripe::Quote::UpdateParams::Line::Action::RemoveDiscount), remove_item: T.nilable(::Stripe::Quote::UpdateParams::Line::Action::RemoveItem), remove_metadata: T.nilable(T::Array[String]), set_discounts: T.nilable(T::Array[::Stripe::Quote::UpdateParams::Line::Action::SetDiscount]), set_items: T.nilable(T::Array[::Stripe::Quote::UpdateParams::Line::Action::SetItem]), set_metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), type: String).void
}
def initialize(
add_discount: nil,
add_item: nil,
add_metadata: nil,
remove_discount: nil,
remove_item: nil,
remove_metadata: nil,
set_discounts: nil,
set_items: nil,
set_metadata: nil,
type: nil
); end
end
class AppliesTo < Stripe::RequestParams
# A custom string that identifies a new subscription schedule being created upon quote acceptance. All quote lines with the same `new_reference` field will be applied to the creation of a new subscription schedule.
sig { returns(T.nilable(String)) }
attr_accessor :new_reference
# The ID of the schedule the line applies to.
sig { returns(T.nilable(String)) }
attr_accessor :subscription_schedule
# Describes whether the quote line is affecting a new schedule or an existing schedule.
sig { returns(String) }
attr_accessor :type
sig {
params(new_reference: T.nilable(String), subscription_schedule: T.nilable(String), type: String).void
}
def initialize(new_reference: nil, subscription_schedule: nil, type: nil); end
end
class CancelSubscriptionSchedule < Stripe::RequestParams
# Timestamp helper to cancel the underlying schedule on the accompanying line's start date. Must be set to `line_starts_at`.
sig { returns(String) }
attr_accessor :cancel_at
# If the subscription schedule is `active`, indicates if a final invoice will be generated that contains any un-invoiced metered usage and new/pending proration invoice items. Boolean that defaults to `true`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :invoice_now
# If the subscription schedule is `active`, indicates if the cancellation should be prorated. Boolean that defaults to `true`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :prorate
sig {
params(cancel_at: String, invoice_now: T.nilable(T::Boolean), prorate: T.nilable(T::Boolean)).void
}
def initialize(cancel_at: nil, invoice_now: nil, prorate: nil); end
end
class EndsAt < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
# The ID of a specific discount.
sig { returns(String) }
attr_accessor :discount
sig { params(discount: String).void }
def initialize(discount: nil); end
end
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Use the `end` time of a given discount.
sig { returns(T.nilable(::Stripe::Quote::UpdateParams::Line::EndsAt::DiscountEnd)) }
attr_accessor :discount_end
# Time span for the quote line starting from the `starts_at` date.
sig { returns(T.nilable(::Stripe::Quote::UpdateParams::Line::EndsAt::Duration)) }
attr_accessor :duration
# A precise Unix timestamp.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# Select a way to pass in `ends_at`.
sig { returns(String) }
attr_accessor :type
sig {
params(discount_end: T.nilable(::Stripe::Quote::UpdateParams::Line::EndsAt::DiscountEnd), duration: T.nilable(::Stripe::Quote::UpdateParams::Line::EndsAt::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(discount_end: nil, duration: nil, timestamp: nil, type: nil); end
end
class SetPauseCollection < Stripe::RequestParams
class Set < Stripe::RequestParams
# The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`.
sig { returns(String) }
attr_accessor :behavior
sig { params(behavior: String).void }
def initialize(behavior: nil); end
end
# Details of the pause_collection behavior to apply to the amendment.
sig { returns(T.nilable(::Stripe::Quote::UpdateParams::Line::SetPauseCollection::Set)) }
attr_accessor :set
# Determines the type of the pause_collection amendment.
sig { returns(String) }
attr_accessor :type
sig {
params(set: T.nilable(::Stripe::Quote::UpdateParams::Line::SetPauseCollection::Set), type: String).void
}
def initialize(set: nil, type: nil); end
end
class StartsAt < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
# The ID of a specific discount.
sig { returns(String) }
attr_accessor :discount
sig { params(discount: String).void }
def initialize(discount: nil); end
end
class LineEndsAt < Stripe::RequestParams
# The ID of a quote line.
sig { returns(T.nilable(String)) }
attr_accessor :id
# The position of the previous quote line in the `lines` array after which this line should begin. Indexes start from 0 and must be less than the index of the current line in the array.
sig { returns(T.nilable(Integer)) }
attr_accessor :index
sig { params(id: T.nilable(String), index: T.nilable(Integer)).void }
def initialize(id: nil, index: nil); end
end
# Use the `end` time of a given discount.
sig { returns(T.nilable(::Stripe::Quote::UpdateParams::Line::StartsAt::DiscountEnd)) }
attr_accessor :discount_end
# The timestamp the given line ends at.
sig { returns(T.nilable(::Stripe::Quote::UpdateParams::Line::StartsAt::LineEndsAt)) }
attr_accessor :line_ends_at
# A precise Unix timestamp.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# Select a way to pass in `starts_at`.
sig { returns(String) }
attr_accessor :type
sig {
params(discount_end: T.nilable(::Stripe::Quote::UpdateParams::Line::StartsAt::DiscountEnd), line_ends_at: T.nilable(::Stripe::Quote::UpdateParams::Line::StartsAt::LineEndsAt), timestamp: T.nilable(Integer), type: String).void
}
def initialize(discount_end: nil, line_ends_at: nil, timestamp: nil, type: nil); end
end
class TrialSettings < Stripe::RequestParams
class EndBehavior < Stripe::RequestParams
# Configure how an opt-in following a paid trial is billed when using `billing_behavior: prorate_up_front`.
sig { returns(T.nilable(String)) }
attr_accessor :prorate_up_front
sig { params(prorate_up_front: T.nilable(String)).void }
def initialize(prorate_up_front: nil); end
end
# Defines how the subscription should behave when a trial ends.
sig {
returns(T.nilable(::Stripe::Quote::UpdateParams::Line::TrialSettings::EndBehavior))
}
attr_accessor :end_behavior
sig {
params(end_behavior: T.nilable(::Stripe::Quote::UpdateParams::Line::TrialSettings::EndBehavior)).void
}
def initialize(end_behavior: nil); end
end
# An array of operations the quote line performs.
sig { returns(T.nilable(T::Array[::Stripe::Quote::UpdateParams::Line::Action])) }
attr_accessor :actions
# Details to identify the subscription schedule the quote line applies to.
sig { returns(T.nilable(::Stripe::Quote::UpdateParams::Line::AppliesTo)) }
attr_accessor :applies_to
# For point-in-time quote lines (having no `ends_at` timestamp), this attribute lets you set or remove whether the subscription's billing cycle anchor is reset at the Quote Line `starts_at` timestamp.For time-span based quote lines (having both `starts_at` and `ends_at`), the only valid value is `automatic`, which removes any previously configured billing cycle anchor resets during the window of time spanning the quote line.
sig { returns(T.nilable(String)) }
attr_accessor :billing_cycle_anchor
# A point-in-time operation that cancels an existing subscription schedule at the line's starts_at timestamp. Currently only compatible with `quote_acceptance_date` for `starts_at`. When using cancel_subscription_schedule, the subscription schedule on the quote remains unalterable, except for modifications to the metadata, collection_method or invoice_settings.
sig { returns(T.nilable(::Stripe::Quote::UpdateParams::Line::CancelSubscriptionSchedule)) }
attr_accessor :cancel_subscription_schedule
# Details to identify the end of the time range modified by the proposed change. If not supplied, the quote line is considered a point-in-time operation that only affects the exact timestamp at `starts_at`, and a restricted set of attributes is supported on the quote line.
sig { returns(T.nilable(::Stripe::Quote::UpdateParams::Line::EndsAt)) }
attr_accessor :ends_at
# The ID of an existing line on the quote.
sig { returns(T.nilable(String)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
# Defines how to pause collection for the underlying subscription throughout the duration of the amendment.
sig { returns(T.nilable(::Stripe::Quote::UpdateParams::Line::SetPauseCollection)) }
attr_accessor :set_pause_collection
# Timestamp helper to end the underlying schedule early, based on the acompanying line's start or end date.
sig { returns(T.nilable(String)) }
attr_accessor :set_schedule_end
# Details to identify the earliest timestamp where the proposed change should take effect.
sig { returns(T.nilable(::Stripe::Quote::UpdateParams::Line::StartsAt)) }
attr_accessor :starts_at
# Settings related to subscription trials.
sig { returns(T.nilable(::Stripe::Quote::UpdateParams::Line::TrialSettings)) }
attr_accessor :trial_settings
sig {
params(actions: T.nilable(T::Array[::Stripe::Quote::UpdateParams::Line::Action]), applies_to: T.nilable(::Stripe::Quote::UpdateParams::Line::AppliesTo), billing_cycle_anchor: T.nilable(String), cancel_subscription_schedule: T.nilable(::Stripe::Quote::UpdateParams::Line::CancelSubscriptionSchedule), ends_at: T.nilable(::Stripe::Quote::UpdateParams::Line::EndsAt), id: T.nilable(String), proration_behavior: T.nilable(String), set_pause_collection: T.nilable(::Stripe::Quote::UpdateParams::Line::SetPauseCollection), set_schedule_end: T.nilable(String), starts_at: T.nilable(::Stripe::Quote::UpdateParams::Line::StartsAt), trial_settings: T.nilable(::Stripe::Quote::UpdateParams::Line::TrialSettings)).void
}
def initialize(
actions: nil,
applies_to: nil,
billing_cycle_anchor: nil,
cancel_subscription_schedule: nil,
ends_at: nil,
id: nil,
proration_behavior: nil,
set_pause_collection: nil,
set_schedule_end: nil,
starts_at: nil,
trial_settings: nil
); end
end
class LineItem < Stripe::RequestParams
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::Quote::UpdateParams::LineItem::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::Quote::UpdateParams::LineItem::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig { returns(T.nilable(::Stripe::Quote::UpdateParams::LineItem::Discount::DiscountEnd)) }
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::Quote::UpdateParams::LineItem::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class PriceData < Stripe::RequestParams
class Recurring < Stripe::RequestParams
# Specifies billing frequency. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: T.nilable(Integer)).void }
def initialize(interval: nil, interval_count: nil); end
end
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
sig { returns(String) }
attr_accessor :product
# The recurring components of a price such as `interval` and `interval_count`.
sig { returns(T.nilable(::Stripe::Quote::UpdateParams::LineItem::PriceData::Recurring)) }
attr_accessor :recurring
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, product: String, recurring: T.nilable(::Stripe::Quote::UpdateParams::LineItem::PriceData::Recurring), tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
recurring: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
# The discounts applied to this line item.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Quote::UpdateParams::LineItem::Discount]))))
}
attr_accessor :discounts
# The ID of an existing line item on the quote.
sig { returns(T.nilable(String)) }
attr_accessor :id
# The ID of the price object. One of `price` or `price_data` is required.
sig { returns(T.nilable(String)) }
attr_accessor :price
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
sig { returns(T.nilable(::Stripe::Quote::UpdateParams::LineItem::PriceData)) }
attr_accessor :price_data
# The quantity of the line item.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# The tax rates which apply to the line item. When set, the `default_tax_rates` on the quote do not apply to this line item.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
sig {
params(discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Quote::UpdateParams::LineItem::Discount]))), id: T.nilable(String), price: T.nilable(String), price_data: T.nilable(::Stripe::Quote::UpdateParams::LineItem::PriceData), quantity: T.nilable(Integer), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String])))).void
}
def initialize(
discounts: nil,
id: nil,
price: nil,
price_data: nil,
quantity: nil,
tax_rates: nil
); end
end
class SubscriptionData < Stripe::RequestParams
class BillOnAcceptance < Stripe::RequestParams
class BillFrom < Stripe::RequestParams
class LineStartsAt < Stripe::RequestParams
# The ID of a quote line.
sig { returns(T.nilable(String)) }
attr_accessor :id
# The position of the previous quote line in the `lines` array after which this line should begin. Indexes start from 0 and must be less than the index of the current line in the array.
sig { returns(T.nilable(Integer)) }
attr_accessor :index
sig { params(id: T.nilable(String), index: T.nilable(Integer)).void }
def initialize(id: nil, index: nil); end
end
# Details of a Quote line to start the bill period from.
sig {
returns(T.nilable(::Stripe::Quote::UpdateParams::SubscriptionData::BillOnAcceptance::BillFrom::LineStartsAt))
}
attr_accessor :line_starts_at
# A precise Unix timestamp.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of method to specify the `bill_from` time.
sig { returns(String) }
attr_accessor :type
sig {
params(line_starts_at: T.nilable(::Stripe::Quote::UpdateParams::SubscriptionData::BillOnAcceptance::BillFrom::LineStartsAt), timestamp: T.nilable(Integer), type: String).void
}
def initialize(line_starts_at: nil, timestamp: nil, type: nil); end
end
class BillUntil < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
class LineEndsAt < Stripe::RequestParams
# The ID of a quote line.
sig { returns(T.nilable(String)) }
attr_accessor :id
# The position of the previous quote line in the `lines` array after which this line should begin. Indexes start from 0 and must be less than the index of the current line in the array.
sig { returns(T.nilable(Integer)) }
attr_accessor :index
sig { params(id: T.nilable(String), index: T.nilable(Integer)).void }
def initialize(id: nil, index: nil); end
end
# Details of the duration over which to bill.
sig {
returns(T.nilable(::Stripe::Quote::UpdateParams::SubscriptionData::BillOnAcceptance::BillUntil::Duration))
}
attr_accessor :duration
# Details of a Quote line item from which to bill until.
sig {
returns(T.nilable(::Stripe::Quote::UpdateParams::SubscriptionData::BillOnAcceptance::BillUntil::LineEndsAt))
}
attr_accessor :line_ends_at
# A precise Unix timestamp.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of method to specify the `bill_until` time.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::Quote::UpdateParams::SubscriptionData::BillOnAcceptance::BillUntil::Duration), line_ends_at: T.nilable(::Stripe::Quote::UpdateParams::SubscriptionData::BillOnAcceptance::BillUntil::LineEndsAt), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, line_ends_at: nil, timestamp: nil, type: nil); end
end
# The start of the period to bill from when the Quote is accepted.
sig {
returns(T.nilable(::Stripe::Quote::UpdateParams::SubscriptionData::BillOnAcceptance::BillFrom))
}
attr_accessor :bill_from
# The end of the period to bill until when the Quote is accepted.
sig {
returns(T.nilable(::Stripe::Quote::UpdateParams::SubscriptionData::BillOnAcceptance::BillUntil))
}
attr_accessor :bill_until
sig {
params(bill_from: T.nilable(::Stripe::Quote::UpdateParams::SubscriptionData::BillOnAcceptance::BillFrom), bill_until: T.nilable(::Stripe::Quote::UpdateParams::SubscriptionData::BillOnAcceptance::BillUntil)).void
}
def initialize(bill_from: nil, bill_until: nil); end
end
class Prebilling < Stripe::RequestParams
# This is used to determine the number of billing cycles to prebill.
sig { returns(Integer) }
attr_accessor :iterations
sig { params(iterations: Integer).void }
def initialize(iterations: nil); end
end
# Describes the period to bill for upon accepting the quote.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Quote::UpdateParams::SubscriptionData::BillOnAcceptance))))
}
attr_accessor :bill_on_acceptance
# Configures when the subscription schedule generates prorations for phase transitions. Possible values are `prorate_on_next_phase` or `prorate_up_front` with the default being `prorate_on_next_phase`. `prorate_on_next_phase` will apply phase changes and generate prorations at transition time. `prorate_up_front` will bill for all phases within the current billing cycle up front.
sig { returns(T.nilable(String)) }
attr_accessor :billing_behavior
# When specified as `reset`, the subscription will always start a new billing period when the quote is accepted.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :billing_cycle_anchor
# The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :description
# When creating a new subscription, the date of which the subscription schedule will start after the quote is accepted. When updating a subscription, the date of which the subscription will be updated using a subscription schedule. The special value `current_period_end` can be provided to update a subscription at the end of its current period. The `effective_date` is ignored if it is in the past when the quote is accepted.
sig { returns(T.nilable(T.nilable(T.any(String, T.any(String, Integer))))) }
attr_accessor :effective_date
# Behavior of the subscription schedule and underlying subscription when it ends.
sig { returns(T.nilable(String)) }
attr_accessor :end_behavior
# Set of [key-value pairs](https://stripe.com/docs/api/metadata) that will set metadata on the subscription or subscription schedule when the quote is accepted. If a recurring price is included in `line_items`, this field will be passed to the resulting subscription's `metadata` field. If `subscription_data.effective_date` is used, this field will be passed to the resulting subscription schedule's `phases.metadata` field. Unlike object-level metadata, this field is declarative. Updates will clear prior values.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# If specified, the invoicing for the given billing cycle iterations will be processed when the quote is accepted. Cannot be used with `effective_date`.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Quote::UpdateParams::SubscriptionData::Prebilling))))
}
attr_accessor :prebilling
# Determines how to handle [prorations](https://stripe.com/docs/subscriptions/billing-cycle#prorations). When creating a subscription, valid values are `create_prorations` or `none`.
#
# When updating a subscription, valid values are `create_prorations`, `none`, or `always_invoice`.
#
# Passing `create_prorations` will cause proration invoice items to be created when applicable. These proration items will only be invoiced immediately under [certain conditions](https://stripe.com/docs/subscriptions/upgrading-downgrading#immediate-payment). In order to always invoice immediately for prorations, pass `always_invoice`.
#
# Prorations can be disabled by passing `none`.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
# Integer representing the number of trial period days before the customer is charged for the first time.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :trial_period_days
sig {
params(bill_on_acceptance: T.nilable(T.nilable(T.any(String, ::Stripe::Quote::UpdateParams::SubscriptionData::BillOnAcceptance))), billing_behavior: T.nilable(String), billing_cycle_anchor: T.nilable(T.nilable(String)), description: T.nilable(T.nilable(String)), effective_date: T.nilable(T.nilable(T.any(String, T.any(String, Integer)))), end_behavior: T.nilable(String), metadata: T.nilable(T::Hash[String, String]), prebilling: T.nilable(T.nilable(T.any(String, ::Stripe::Quote::UpdateParams::SubscriptionData::Prebilling))), proration_behavior: T.nilable(String), trial_period_days: T.nilable(T.nilable(T.any(String, Integer)))).void
}
def initialize(
bill_on_acceptance: nil,
billing_behavior: nil,
billing_cycle_anchor: nil,
description: nil,
effective_date: nil,
end_behavior: nil,
metadata: nil,
prebilling: nil,
proration_behavior: nil,
trial_period_days: nil
); end
end
class SubscriptionDataOverride < Stripe::RequestParams
class AppliesTo < Stripe::RequestParams
# A custom string that identifies a new subscription schedule being created upon quote acceptance. All quote lines with the same `new_reference` field will be applied to the creation of a new subscription schedule.
sig { returns(T.nilable(String)) }
attr_accessor :new_reference
# The ID of the schedule the line applies to.
sig { returns(T.nilable(String)) }
attr_accessor :subscription_schedule
# Describes whether the quote line is affecting a new schedule or an existing schedule.
sig { returns(String) }
attr_accessor :type
sig {
params(new_reference: T.nilable(String), subscription_schedule: T.nilable(String), type: String).void
}
def initialize(new_reference: nil, subscription_schedule: nil, type: nil); end
end
class BillOnAcceptance < Stripe::RequestParams
class BillFrom < Stripe::RequestParams
class LineStartsAt < Stripe::RequestParams
# The ID of a quote line.
sig { returns(T.nilable(String)) }
attr_accessor :id
# The position of the previous quote line in the `lines` array after which this line should begin. Indexes start from 0 and must be less than the index of the current line in the array.
sig { returns(T.nilable(Integer)) }
attr_accessor :index
sig { params(id: T.nilable(String), index: T.nilable(Integer)).void }
def initialize(id: nil, index: nil); end
end
# Details of a Quote line to start the bill period from.
sig {
returns(T.nilable(::Stripe::Quote::UpdateParams::SubscriptionDataOverride::BillOnAcceptance::BillFrom::LineStartsAt))
}
attr_accessor :line_starts_at
# A precise Unix timestamp.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of method to specify the `bill_from` time.
sig { returns(String) }
attr_accessor :type
sig {
params(line_starts_at: T.nilable(::Stripe::Quote::UpdateParams::SubscriptionDataOverride::BillOnAcceptance::BillFrom::LineStartsAt), timestamp: T.nilable(Integer), type: String).void
}
def initialize(line_starts_at: nil, timestamp: nil, type: nil); end
end
class BillUntil < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
class LineEndsAt < Stripe::RequestParams
# The ID of a quote line.
sig { returns(T.nilable(String)) }
attr_accessor :id
# The position of the previous quote line in the `lines` array after which this line should begin. Indexes start from 0 and must be less than the index of the current line in the array.
sig { returns(T.nilable(Integer)) }
attr_accessor :index
sig { params(id: T.nilable(String), index: T.nilable(Integer)).void }
def initialize(id: nil, index: nil); end
end
# Details of the duration over which to bill.
sig {
returns(T.nilable(::Stripe::Quote::UpdateParams::SubscriptionDataOverride::BillOnAcceptance::BillUntil::Duration))
}
attr_accessor :duration
# Details of a Quote line item from which to bill until.
sig {
returns(T.nilable(::Stripe::Quote::UpdateParams::SubscriptionDataOverride::BillOnAcceptance::BillUntil::LineEndsAt))
}
attr_accessor :line_ends_at
# A precise Unix timestamp.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of method to specify the `bill_until` time.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::Quote::UpdateParams::SubscriptionDataOverride::BillOnAcceptance::BillUntil::Duration), line_ends_at: T.nilable(::Stripe::Quote::UpdateParams::SubscriptionDataOverride::BillOnAcceptance::BillUntil::LineEndsAt), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, line_ends_at: nil, timestamp: nil, type: nil); end
end
# The start of the period to bill from when the Quote is accepted.
sig {
returns(T.nilable(::Stripe::Quote::UpdateParams::SubscriptionDataOverride::BillOnAcceptance::BillFrom))
}
attr_accessor :bill_from
# The end of the period to bill until when the Quote is accepted.
sig {
returns(T.nilable(::Stripe::Quote::UpdateParams::SubscriptionDataOverride::BillOnAcceptance::BillUntil))
}
attr_accessor :bill_until
sig {
params(bill_from: T.nilable(::Stripe::Quote::UpdateParams::SubscriptionDataOverride::BillOnAcceptance::BillFrom), bill_until: T.nilable(::Stripe::Quote::UpdateParams::SubscriptionDataOverride::BillOnAcceptance::BillUntil)).void
}
def initialize(bill_from: nil, bill_until: nil); end
end
# Whether the override applies to an existing Subscription Schedule or a new Subscription Schedule.
sig { returns(::Stripe::Quote::UpdateParams::SubscriptionDataOverride::AppliesTo) }
attr_accessor :applies_to
# Describes the period to bill for upon accepting the quote.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Quote::UpdateParams::SubscriptionDataOverride::BillOnAcceptance))))
}
attr_accessor :bill_on_acceptance
# Configures when the subscription schedule generates prorations for phase transitions. Possible values are `prorate_on_next_phase` or `prorate_up_front` with the default being `prorate_on_next_phase`. `prorate_on_next_phase` will apply phase changes and generate prorations at transition time. `prorate_up_front` will bill for all phases within the current billing cycle up front.
sig { returns(T.nilable(String)) }
attr_accessor :billing_behavior
# The customer the Subscription Data override applies to.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :description
# Behavior of the subscription schedule and underlying subscription when it ends.
sig { returns(T.nilable(String)) }
attr_accessor :end_behavior
# Determines how to handle [prorations](https://stripe.com/docs/subscriptions/billing-cycle#prorations). When creating a subscription, valid values are `create_prorations` or `none`.
#
# When updating a subscription, valid values are `create_prorations`, `none`, or `always_invoice`.
#
# Passing `create_prorations` will cause proration invoice items to be created when applicable. These proration items will only be invoiced immediately under [certain conditions](https://stripe.com/docs/subscriptions/upgrading-downgrading#immediate-payment). In order to always invoice immediately for prorations, pass `always_invoice`.
#
# Prorations can be disabled by passing `none`.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
sig {
params(applies_to: ::Stripe::Quote::UpdateParams::SubscriptionDataOverride::AppliesTo, bill_on_acceptance: T.nilable(T.nilable(T.any(String, ::Stripe::Quote::UpdateParams::SubscriptionDataOverride::BillOnAcceptance))), billing_behavior: T.nilable(String), customer: T.nilable(String), description: T.nilable(T.nilable(String)), end_behavior: T.nilable(String), proration_behavior: T.nilable(String)).void
}
def initialize(
applies_to: nil,
bill_on_acceptance: nil,
billing_behavior: nil,
customer: nil,
description: nil,
end_behavior: nil,
proration_behavior: nil
); end
end
class TransferData < Stripe::RequestParams
# The amount that will be transferred automatically when the invoice is paid. If no amount is set, the full amount is transferred. There cannot be any line items with recurring prices when using this field.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination. There must be at least 1 line item with a recurring price to use this field.
sig { returns(T.nilable(Float)) }
attr_accessor :amount_percent
# ID of an existing, connected Stripe account.
sig { returns(String) }
attr_accessor :destination
sig {
params(amount: T.nilable(Integer), amount_percent: T.nilable(Float), destination: String).void
}
def initialize(amount: nil, amount_percent: nil, destination: nil); end
end
# Set to true to allow quote lines to have `starts_at` in the past if collection is paused between `starts_at` and now.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :allow_backdated_lines
# The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. There cannot be any line items with recurring prices when using this field.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :application_fee_amount
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. There must be at least 1 line item with a recurring price to use this field.
sig { returns(T.nilable(T.nilable(T.any(String, Float)))) }
attr_accessor :application_fee_percent
# Settings for automatic tax lookup for this quote and resulting invoices and subscriptions.
sig { returns(T.nilable(::Stripe::Quote::UpdateParams::AutomaticTax)) }
attr_accessor :automatic_tax
# Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay invoices at the end of the subscription cycle or at invoice finalization using the default payment method attached to the subscription or customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically`.
sig { returns(T.nilable(String)) }
attr_accessor :collection_method
# The customer for which this quote belongs to. A customer is required before finalizing the quote. Once specified, it cannot be changed.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# The account for which this quote belongs to. A customer or account is required before finalizing the quote. Once specified, it cannot be changed.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# The tax rates that will apply to any line item that does not have `tax_rates` set.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :default_tax_rates
# A description that will be displayed on the quote PDF.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :description
# The discounts applied to the quote.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Quote::UpdateParams::Discount]))))
}
attr_accessor :discounts
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A future timestamp on which the quote will be canceled if in `open` or `draft` status. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_at
# A footer that will be displayed on the quote PDF.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :footer
# A header that will be displayed on the quote PDF.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :header
# All invoices will be billed using the specified settings.
sig { returns(T.nilable(::Stripe::Quote::UpdateParams::InvoiceSettings)) }
attr_accessor :invoice_settings
# A list of line items the customer is being quoted for. Each line item includes information about the product, the quantity, and the resulting cost.
sig { returns(T.nilable(T::Array[::Stripe::Quote::UpdateParams::LineItem])) }
attr_accessor :line_items
# A list of [quote lines](https://docs.stripe.com/api/quote_lines) on the quote. These lines describe changes, in the order provided, that will be used to create new subscription schedules or update existing subscription schedules when the quote is accepted.
sig { returns(T.nilable(T::Array[::Stripe::Quote::UpdateParams::Line])) }
attr_accessor :lines
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The account on behalf of which to charge.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :on_behalf_of
# When creating a subscription or subscription schedule, the specified configuration data will be used. There must be at least one line item with a recurring price for a subscription or subscription schedule to be created. A subscription schedule is created if `subscription_data[effective_date]` is present and in the future, otherwise a subscription is created.
sig { returns(T.nilable(::Stripe::Quote::UpdateParams::SubscriptionData)) }
attr_accessor :subscription_data
# List representing overrides for `subscription_data` configurations for specific subscription schedules.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Quote::UpdateParams::SubscriptionDataOverride]))))
}
attr_accessor :subscription_data_overrides
# The data with which to automatically create a Transfer for each of the invoices.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Quote::UpdateParams::TransferData))))
}
attr_accessor :transfer_data
sig {
params(allow_backdated_lines: T.nilable(T::Boolean), application_fee_amount: T.nilable(T.nilable(T.any(String, Integer))), application_fee_percent: T.nilable(T.nilable(T.any(String, Float))), automatic_tax: T.nilable(::Stripe::Quote::UpdateParams::AutomaticTax), collection_method: T.nilable(String), customer: T.nilable(String), customer_account: T.nilable(String), default_tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String]))), description: T.nilable(T.nilable(String)), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Quote::UpdateParams::Discount]))), expand: T.nilable(T::Array[String]), expires_at: T.nilable(Integer), footer: T.nilable(T.nilable(String)), header: T.nilable(T.nilable(String)), invoice_settings: T.nilable(::Stripe::Quote::UpdateParams::InvoiceSettings), line_items: T.nilable(T::Array[::Stripe::Quote::UpdateParams::LineItem]), lines: T.nilable(T::Array[::Stripe::Quote::UpdateParams::Line]), metadata: T.nilable(T::Hash[String, String]), on_behalf_of: T.nilable(T.nilable(String)), subscription_data: T.nilable(::Stripe::Quote::UpdateParams::SubscriptionData), subscription_data_overrides: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Quote::UpdateParams::SubscriptionDataOverride]))), transfer_data: T.nilable(T.nilable(T.any(String, ::Stripe::Quote::UpdateParams::TransferData)))).void
}
def initialize(
allow_backdated_lines: nil,
application_fee_amount: nil,
application_fee_percent: nil,
automatic_tax: nil,
collection_method: nil,
customer: nil,
customer_account: nil,
default_tax_rates: nil,
description: nil,
discounts: nil,
expand: nil,
expires_at: nil,
footer: nil,
header: nil,
invoice_settings: nil,
line_items: nil,
lines: nil,
metadata: nil,
on_behalf_of: nil,
subscription_data: nil,
subscription_data_overrides: nil,
transfer_data: nil
); end
end
class ListComputedUpfrontLineItemsParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
class ListLineItemsParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
class ListLinesParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
class AcceptParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class CancelParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class FinalizeQuoteParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A future timestamp on which the quote will be canceled if in `open` or `draft` status. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_at
sig { params(expand: T.nilable(T::Array[String]), expires_at: T.nilable(Integer)).void }
def initialize(expand: nil, expires_at: nil); end
end
class MarkDraftParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class MarkStaleParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Reason the Quote is being marked stale.
sig { returns(T.nilable(String)) }
attr_accessor :reason
sig { params(expand: T.nilable(T::Array[String]), reason: T.nilable(String)).void }
def initialize(expand: nil, reason: nil); end
end
class ReestimateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class PdfParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class ListPreviewInvoiceLinesParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
# Accepts the specified quote.
sig {
params(params: T.any(::Stripe::Quote::AcceptParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Quote)
}
def accept(params = {}, opts = {}); end
# Accepts the specified quote.
sig {
params(quote: String, params: T.any(::Stripe::Quote::AcceptParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Quote)
}
def self.accept(quote, params = {}, opts = {}); end
# Cancels the quote.
sig {
params(params: T.any(::Stripe::Quote::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Quote)
}
def cancel(params = {}, opts = {}); end
# Cancels the quote.
sig {
params(quote: String, params: T.any(::Stripe::Quote::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Quote)
}
def self.cancel(quote, params = {}, opts = {}); end
# A quote models prices and services for a customer. Default options for header, description, footer, and expires_at can be set in the dashboard via the [quote template](https://dashboard.stripe.com/settings/billing/quote).
sig {
params(params: T.any(::Stripe::Quote::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Quote)
}
def self.create(params = {}, opts = {}); end
# Finalizes the quote.
sig {
params(params: T.any(::Stripe::Quote::FinalizeQuoteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Quote)
}
def finalize_quote(params = {}, opts = {}); end
# Finalizes the quote.
sig {
params(quote: String, params: T.any(::Stripe::Quote::FinalizeQuoteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Quote)
}
def self.finalize_quote(quote, params = {}, opts = {}); end
# Returns a list of your quotes.
sig {
params(params: T.any(::Stripe::Quote::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# When retrieving a quote, there is an includable [computed.upfront.line_items](https://stripe.com/docs/api/quotes/object#quote_object-computed-upfront-line_items) property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of upfront line items.
sig {
params(params: T.any(::Stripe::Quote::ListComputedUpfrontLineItemsParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list_computed_upfront_line_items(params = {}, opts = {}); end
# When retrieving a quote, there is an includable [computed.upfront.line_items](https://stripe.com/docs/api/quotes/object#quote_object-computed-upfront-line_items) property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of upfront line items.
sig {
params(quote: String, params: T.any(::Stripe::Quote::ListComputedUpfrontLineItemsParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list_computed_upfront_line_items(quote, params = {}, opts = {}); end
# When retrieving a quote, there is an includable line_items property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items.
sig {
params(params: T.any(::Stripe::Quote::ListLineItemsParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list_line_items(params = {}, opts = {}); end
# When retrieving a quote, there is an includable line_items property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items.
sig {
params(quote: String, params: T.any(::Stripe::Quote::ListLineItemsParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list_line_items(quote, params = {}, opts = {}); end
# Retrieves a paginated list of lines for a quote. These lines describe changes that will be used to create new subscription schedules or update existing subscription schedules when the quote is accepted.
sig {
params(params: T.any(::Stripe::Quote::ListLinesParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list_lines(params = {}, opts = {}); end
# Retrieves a paginated list of lines for a quote. These lines describe changes that will be used to create new subscription schedules or update existing subscription schedules when the quote is accepted.
sig {
params(quote: String, params: T.any(::Stripe::Quote::ListLinesParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list_lines(quote, params = {}, opts = {}); end
# Preview the invoice line items that would be generated by accepting the quote.
sig {
params(preview_invoice: String, params: T.any(::Stripe::Quote::ListPreviewInvoiceLinesParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list_preview_invoice_lines(preview_invoice, params = {}, opts = {}); end
# Preview the invoice line items that would be generated by accepting the quote.
sig {
params(quote: String, preview_invoice: String, params: T.any(::Stripe::Quote::ListPreviewInvoiceLinesParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list_preview_invoice_lines(quote, preview_invoice, params = {}, opts = {}); end
# Converts a stale quote to draft.
sig {
params(params: T.any(::Stripe::Quote::MarkDraftParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Quote)
}
def mark_draft(params = {}, opts = {}); end
# Converts a stale quote to draft.
sig {
params(quote: String, params: T.any(::Stripe::Quote::MarkDraftParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Quote)
}
def self.mark_draft(quote, params = {}, opts = {}); end
# Converts a draft or open quote to stale.
sig {
params(params: T.any(::Stripe::Quote::MarkStaleParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Quote)
}
def mark_stale(params = {}, opts = {}); end
# Converts a draft or open quote to stale.
sig {
params(quote: String, params: T.any(::Stripe::Quote::MarkStaleParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Quote)
}
def self.mark_stale(quote, params = {}, opts = {}); end
# Download the PDF for a finalized quote. Explanation for special handling can be found [here](https://docs.stripe.com/quotes/overview#quote_pdf)
sig {
params(params: T.any(::Stripe::Quote::PdfParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped, read_body_chunk_block: T.untyped).returns(T.untyped)
}
def pdf(params = {}, opts = {}, &read_body_chunk_block); end
# Download the PDF for a finalized quote. Explanation for special handling can be found [here](https://docs.stripe.com/quotes/overview#quote_pdf)
sig {
params(quote: String, params: T.any(::Stripe::Quote::PdfParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped, read_body_chunk_block: T.untyped).returns(T.untyped)
}
def self.pdf(quote, params = {}, opts = {}, &read_body_chunk_block); end
# Recompute the upcoming invoice estimate for the quote.
sig {
params(params: T.any(::Stripe::Quote::ReestimateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Quote)
}
def reestimate(params = {}, opts = {}); end
# Recompute the upcoming invoice estimate for the quote.
sig {
params(quote: String, params: T.any(::Stripe::Quote::ReestimateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Quote)
}
def self.reestimate(quote, params = {}, opts = {}); end
# A quote models prices and services for a customer.
sig {
params(quote: String, params: T.any(::Stripe::Quote::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Quote)
}
def self.update(quote, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
# A quote line defines a set of changes, in the order provided, that will be applied upon quote acceptance.
class QuoteLine < APIResource
class Action < Stripe::StripeObject
class AddDiscount < Stripe::StripeObject
class DiscountEnd < Stripe::StripeObject
# The discount end type.
sig { returns(String) }
attr_reader :type
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(T.any(String, Stripe::Coupon))) }
attr_reader :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(T.any(String, Stripe::Discount))) }
attr_reader :discount
# Details to determine how long the discount should be applied for.
sig { returns(T.nilable(DiscountEnd)) }
attr_reader :discount_end
# The index, starting at 0, at which to position the new discount. When not supplied, Stripe defaults to appending the discount to the end of the `discounts` array.
sig { returns(T.nilable(Integer)) }
attr_reader :index
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(T.any(String, Stripe::PromotionCode))) }
attr_reader :promotion_code
end
class AddItem < Stripe::StripeObject
class Discount < Stripe::StripeObject
class DiscountEnd < Stripe::StripeObject
# The discount end timestamp.
sig { returns(T.nilable(Integer)) }
attr_reader :timestamp
# The discount end type.
sig { returns(String) }
attr_reader :type
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(T.any(String, Stripe::Coupon))) }
attr_reader :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(T.any(String, Stripe::Discount))) }
attr_reader :discount
# Details to determine how long the discount should be applied for.
sig { returns(T.nilable(DiscountEnd)) }
attr_reader :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(T.any(String, Stripe::PromotionCode))) }
attr_reader :promotion_code
end
class Trial < Stripe::StripeObject
# List of price IDs which, if present on the subscription following a paid trial, constitute opting-in to the paid trial.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :converts_to
# Determines the type of trial for this item.
sig { returns(String) }
attr_reader :type
end
# The discounts applied to the subscription item. Subscription item discounts are applied before subscription discounts. Use `expand[]=discounts` to expand each discount.
sig { returns(T::Array[Discount]) }
attr_reader :discounts
# Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an item. Metadata on this item will update the underlying subscription item's `metadata` when the phase is entered.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# ID of the price to which the customer should be subscribed.
sig { returns(T.any(String, Stripe::Price)) }
attr_reader :price
# Quantity of the plan to which the customer should be subscribed.
sig { returns(Integer) }
attr_reader :quantity
# The tax rates which apply to this `phase_item`. When set, the `default_tax_rates` on the phase do not apply to this `phase_item`.
sig { returns(T.nilable(T::Array[Stripe::TaxRate])) }
attr_reader :tax_rates
# Options that configure the trial on the subscription item.
sig { returns(T.nilable(Trial)) }
attr_reader :trial
end
class RemoveDiscount < Stripe::StripeObject
class DiscountEnd < Stripe::StripeObject
# The discount end timestamp.
sig { returns(T.nilable(Integer)) }
attr_reader :timestamp
# The discount end type.
sig { returns(String) }
attr_reader :type
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(T.any(String, Stripe::Coupon))) }
attr_reader :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(T.any(String, Stripe::Discount))) }
attr_reader :discount
# Details to determine how long the discount should be applied for.
sig { returns(T.nilable(DiscountEnd)) }
attr_reader :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(T.any(String, Stripe::PromotionCode))) }
attr_reader :promotion_code
end
class RemoveItem < Stripe::StripeObject
# ID of a price to remove.
sig { returns(T.any(String, Stripe::Price)) }
attr_reader :price
end
class SetDiscount < Stripe::StripeObject
class DiscountEnd < Stripe::StripeObject
# The discount end timestamp.
sig { returns(T.nilable(Integer)) }
attr_reader :timestamp
# The discount end type.
sig { returns(String) }
attr_reader :type
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(T.any(String, Stripe::Coupon))) }
attr_reader :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(T.any(String, Stripe::Discount))) }
attr_reader :discount
# Details to determine how long the discount should be applied for.
sig { returns(T.nilable(DiscountEnd)) }
attr_reader :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(T.any(String, Stripe::PromotionCode))) }
attr_reader :promotion_code
end
class SetItem < Stripe::StripeObject
class Discount < Stripe::StripeObject
class DiscountEnd < Stripe::StripeObject
# The discount end timestamp.
sig { returns(T.nilable(Integer)) }
attr_reader :timestamp
# The discount end type.
sig { returns(String) }
attr_reader :type
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(T.any(String, Stripe::Coupon))) }
attr_reader :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(T.any(String, Stripe::Discount))) }
attr_reader :discount
# Details to determine how long the discount should be applied for.
sig { returns(T.nilable(DiscountEnd)) }
attr_reader :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(T.any(String, Stripe::PromotionCode))) }
attr_reader :promotion_code
end
class Trial < Stripe::StripeObject
# List of price IDs which, if present on the subscription following a paid trial, constitute opting-in to the paid trial.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :converts_to
# Determines the type of trial for this item.
sig { returns(String) }
attr_reader :type
end
# The discounts applied to the subscription item. Subscription item discounts are applied before subscription discounts. Use `expand[]=discounts` to expand each discount.
sig { returns(T::Array[Discount]) }
attr_reader :discounts
# Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an item. Metadata on this item will update the underlying subscription item's `metadata` when the phase is entered.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# ID of the price to which the customer should be subscribed.
sig { returns(T.any(String, Stripe::Price)) }
attr_reader :price
# Quantity of the plan to which the customer should be subscribed.
sig { returns(Integer) }
attr_reader :quantity
# The tax rates which apply to this `phase_item`. When set, the `default_tax_rates` on the phase do not apply to this `phase_item`.
sig { returns(T.nilable(T::Array[Stripe::TaxRate])) }
attr_reader :tax_rates
# Options that configure the trial on the subscription item.
sig { returns(T.nilable(Trial)) }
attr_reader :trial
end
# Details for the `add_discount` type.
sig { returns(T.nilable(AddDiscount)) }
attr_reader :add_discount
# Details for the `add_item` type.
sig { returns(T.nilable(AddItem)) }
attr_reader :add_item
# Details for the `add_metadata` type: specify a hash of key-value pairs.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :add_metadata
# Details for the `remove_discount` type.
sig { returns(T.nilable(RemoveDiscount)) }
attr_reader :remove_discount
# Details for the `remove_item` type.
sig { returns(T.nilable(RemoveItem)) }
attr_reader :remove_item
# Details for the `remove_metadata` type: specify an array of metadata keys.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :remove_metadata
# Details for the `set_discounts` type.
sig { returns(T.nilable(T::Array[SetDiscount])) }
attr_reader :set_discounts
# Details for the `set_items` type.
sig { returns(T.nilable(T::Array[SetItem])) }
attr_reader :set_items
# Details for the `set_metadata` type: specify an array of key-value pairs.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :set_metadata
# The type of action the quote line performs.
sig { returns(String) }
attr_reader :type
end
class AppliesTo < Stripe::StripeObject
# A custom string that identifies a new subscription schedule being created upon quote acceptance. All quote lines with the same `new_reference` field will be applied to the creation of a new subscription schedule.
sig { returns(T.nilable(String)) }
attr_reader :new_reference
# The ID of the schedule the line applies to.
sig { returns(T.nilable(String)) }
attr_reader :subscription_schedule
# Describes whether the quote line is affecting a new schedule or an existing schedule.
sig { returns(String) }
attr_reader :type
end
class CancelSubscriptionSchedule < Stripe::StripeObject
# Timestamp helper to cancel the underlying schedule on the accompanying line's start date. Must be set to `line_starts_at`.
sig { returns(String) }
attr_reader :cancel_at
# If the subscription schedule is `active`, indicates if a final invoice will be generated that contains any un-invoiced metered usage and new/pending proration invoice items. Boolean that defaults to `true`.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :invoice_now
# If the subscription schedule is `active`, indicates if the cancellation should be prorated. Boolean that defaults to `true`.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :prorate
end
class EndsAt < Stripe::StripeObject
class DiscountEnd < Stripe::StripeObject
# The ID of a specific discount.
sig { returns(String) }
attr_reader :discount
end
class Duration < Stripe::StripeObject
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_reader :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_reader :interval_count
end
# The timestamp value that will be used to determine when to make changes to the subscription schedule, as computed from the `ends_at` field. For example, if `ends_at[type]=upcoming_invoice`, the upcoming invoice date will be computed at the time the `ends_at` field was specified and saved. This field will not be recomputed upon future requests to update or finalize the quote unless `ends_at` is respecified. This field is guaranteed to be populated after quote acceptance.
sig { returns(T.nilable(Integer)) }
attr_reader :computed
# Use the `end` time of a given discount.
sig { returns(T.nilable(DiscountEnd)) }
attr_reader :discount_end
# Time span for the quote line starting from the `starts_at` date.
sig { returns(T.nilable(Duration)) }
attr_reader :duration
# A precise Unix timestamp.
sig { returns(T.nilable(Integer)) }
attr_reader :timestamp
# Select a way to pass in `ends_at`.
sig { returns(String) }
attr_reader :type
end
class SetPauseCollection < Stripe::StripeObject
class Set < Stripe::StripeObject
# The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`.
sig { returns(String) }
attr_reader :behavior
end
# If specified, payment collection for this subscription will be paused. Note that the subscription status will be unchanged and will not be updated to `paused`. Learn more about [pausing collection](https://stripe.com/docs/billing/subscriptions/pause-payment).
sig { returns(T.nilable(Set)) }
attr_reader :set
# Defines the type of the pause_collection behavior for the quote line.
sig { returns(String) }
attr_reader :type
end
class StartsAt < Stripe::StripeObject
class DiscountEnd < Stripe::StripeObject
# The ID of a specific discount.
sig { returns(String) }
attr_reader :discount
end
class LineEndsAt < Stripe::StripeObject
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
end
# The timestamp value that will be used to determine when to make changes to the subscription schedule, as computed from the `starts_at` field. For example, if `starts_at[type]=upcoming_invoice`, the upcoming invoice date will be computed at the time the `starts_at` field was specified and saved. This field will not be recomputed upon future requests to update or finalize the quote unless `starts_at` is respecified. This field is guaranteed to be populated after quote acceptance.
sig { returns(T.nilable(Integer)) }
attr_reader :computed
# Use the `end` time of a given discount.
sig { returns(T.nilable(DiscountEnd)) }
attr_reader :discount_end
# The timestamp the given line ends at.
sig { returns(T.nilable(LineEndsAt)) }
attr_reader :line_ends_at
# A precise Unix timestamp.
sig { returns(T.nilable(Integer)) }
attr_reader :timestamp
# Select a way to pass in `starts_at`.
sig { returns(String) }
attr_reader :type
end
class TrialSettings < Stripe::StripeObject
class EndBehavior < Stripe::StripeObject
# Configure how an opt-in following a paid trial is billed when using `billing_behavior: prorate_up_front`.
sig { returns(T.nilable(String)) }
attr_reader :prorate_up_front
end
# Defines how the subscription should behave when a trial ends.
sig { returns(T.nilable(EndBehavior)) }
attr_reader :end_behavior
end
# A list of items the customer is being quoted for.
sig { returns(T::Array[Action]) }
attr_reader :actions
# Details to identify the subscription schedule the quote line applies to.
sig { returns(T.nilable(AppliesTo)) }
attr_reader :applies_to
# For point-in-time quote lines (having no `ends_at` timestamp), this attribute lets you set or remove whether the subscription's billing cycle anchor is reset at the Quote Line `starts_at` timestamp.For time-span based quote lines (having both `starts_at` and `ends_at`), the only valid value is `automatic`, which removes any previously configured billing cycle anchor resets during the window of time spanning the quote line.
sig { returns(T.nilable(String)) }
attr_reader :billing_cycle_anchor
# A point-in-time operation that cancels an existing subscription schedule at the line's starts_at timestamp. Currently only compatible with `quote_acceptance_date` for `starts_at`. When using cancel_subscription_schedule, the subscription schedule on the quote remains unalterable, except for modifications to the metadata, collection_method or invoice_settings.
sig { returns(T.nilable(CancelSubscriptionSchedule)) }
attr_reader :cancel_subscription_schedule
# Details to identify the end of the time range modified by the proposed change. If not supplied, the quote line is considered a point-in-time operation that only affects the exact timestamp at `starts_at`, and a restricted set of attributes is supported on the quote line.
sig { returns(T.nilable(EndsAt)) }
attr_reader :ends_at
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :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.
sig { returns(T.nilable(String)) }
attr_reader :proration_behavior
# Details to modify the pause_collection behavior of the subscription schedule.
sig { returns(T.nilable(SetPauseCollection)) }
attr_reader :set_pause_collection
# Timestamp helper to end the underlying schedule early, based on the acompanying line's start or end date.
sig { returns(T.nilable(String)) }
attr_reader :set_schedule_end
# Details to identify the earliest timestamp where the proposed change should take effect.
sig { returns(T.nilable(StartsAt)) }
attr_reader :starts_at
# Settings related to subscription trials.
sig { returns(T.nilable(TrialSettings)) }
attr_reader :trial_settings
end
end
# typed: true
module Stripe
# Invoices are statements of amounts owed by a customer, and are either
# generated one-off, or generated periodically from a subscription.
#
# They contain [invoice items](https://stripe.com/docs/api#invoiceitems), and proration adjustments
# that may be caused by subscription upgrades/downgrades (if necessary).
#
# If your invoice is configured to be billed through automatic charges,
# Stripe automatically finalizes your invoice and attempts payment. Note
# that finalizing the invoice,
# [when automatic](https://stripe.com/docs/invoicing/integration/automatic-advancement-collection), does
# not happen immediately as the invoice is created. Stripe waits
# until one hour after the last webhook was successfully sent (or the last
# webhook timed out after failing). If you (and the platforms you may have
# connected to) have no webhooks configured, Stripe waits one hour after
# creation to finalize the invoice.
#
# If your invoice is configured to be billed by sending an email, then based on your
# [email settings](https://dashboard.stripe.com/account/billing/automatic),
# Stripe will email the invoice to your customer and await payment. These
# emails can contain a link to a hosted page to pay the invoice.
#
# Stripe applies any customer credit on the account before determining the
# amount due for the invoice (i.e., the amount that will be actually
# charged). If the amount due for the invoice is less than Stripe's [minimum allowed charge
# per currency](https://docs.stripe.com/docs/currencies#minimum-and-maximum-charge-amounts), the
# invoice is automatically marked paid, and we add the amount due to the
# customer's credit balance which is applied to the next invoice.
#
# More details on the customer's credit balance are
# [here](https://stripe.com/docs/billing/customer/balance).
#
# Related guide: [Send invoices to customers](https://stripe.com/docs/billing/invoices/sending)
class QuotePreviewInvoice < APIResource
class AmountsDue < Stripe::StripeObject
# Incremental amount due for this payment in cents (or local equivalent).
sig { returns(Integer) }
attr_reader :amount
# The amount in cents (or local equivalent) that was paid for this payment.
sig { returns(Integer) }
attr_reader :amount_paid
# The difference between the payment’s amount and amount_paid, in cents (or local equivalent).
sig { returns(Integer) }
attr_reader :amount_remaining
# Number of days from when invoice is finalized until the payment is due.
sig { returns(T.nilable(Integer)) }
attr_reader :days_until_due
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_reader :description
# Date on which a payment plan’s payment is due.
sig { returns(T.nilable(Integer)) }
attr_reader :due_date
# Timestamp when the payment was paid.
sig { returns(T.nilable(Integer)) }
attr_reader :paid_at
# The status of the payment, one of `open`, `paid`, or `past_due`
sig { returns(String) }
attr_reader :status
end
class AppliesTo < Stripe::StripeObject
# A custom string that identifies a new subscription schedule being created upon quote acceptance. All quote lines with the same `new_reference` field will be applied to the creation of a new subscription schedule.
sig { returns(T.nilable(String)) }
attr_reader :new_reference
# The ID of the schedule the line applies to.
sig { returns(T.nilable(String)) }
attr_reader :subscription_schedule
# Describes whether the quote line is affecting a new schedule or an existing schedule.
sig { returns(String) }
attr_reader :type
end
class AutomaticTax < Stripe::StripeObject
class Liability < Stripe::StripeObject
# The connected account being referenced when `type` is `account`.
sig { returns(T.any(String, Stripe::Account)) }
attr_reader :account
# Type of the account referenced.
sig { returns(String) }
attr_reader :type
end
# If Stripe disabled automatic tax, this enum describes why.
sig { returns(T.nilable(String)) }
attr_reader :disabled_reason
# 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.
sig { returns(T::Boolean) }
attr_reader :enabled
# The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
sig { returns(T.nilable(Liability)) }
attr_reader :liability
# The tax provider powering automatic tax.
sig { returns(T.nilable(String)) }
attr_reader :provider
# The status of the most recent automated tax calculation for this invoice.
sig { returns(T.nilable(String)) }
attr_reader :status
end
class ConfirmationSecret < Stripe::StripeObject
# The client_secret of the payment that Stripe creates for the invoice after finalization.
sig { returns(String) }
attr_reader :client_secret
# The type of client_secret. Currently this is always payment_intent, referencing the default payment_intent that Stripe creates during invoice finalization
sig { returns(String) }
attr_reader :type
end
class CustomField < Stripe::StripeObject
# The name of the custom field.
sig { returns(String) }
attr_reader :name
# The value of the custom field.
sig { returns(String) }
attr_reader :value
end
class CustomerAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
class CustomerShipping < Stripe::StripeObject
class Address < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Attribute for field address
sig { returns(Address) }
attr_reader :address
# The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
sig { returns(T.nilable(String)) }
attr_reader :carrier
# Recipient name.
sig { returns(String) }
attr_reader :name
# Recipient phone (including extension).
sig { returns(T.nilable(String)) }
attr_reader :phone
# The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
sig { returns(T.nilable(String)) }
attr_reader :tracking_number
end
class CustomerTaxId < Stripe::StripeObject
# The type of the tax ID, one of `ad_nrt`, `ar_cuit`, `eu_vat`, `bo_tin`, `br_cnpj`, `br_cpf`, `cn_tin`, `co_nit`, `cr_tin`, `do_rcn`, `ec_ruc`, `eu_oss_vat`, `hr_oib`, `pe_ruc`, `ro_tin`, `rs_pib`, `sv_nit`, `uy_ruc`, `ve_rif`, `vn_tin`, `gb_vat`, `nz_gst`, `au_abn`, `au_arn`, `in_gst`, `no_vat`, `no_voec`, `za_vat`, `ch_vat`, `mx_rfc`, `sg_uen`, `ru_inn`, `ru_kpp`, `ca_bn`, `hk_br`, `es_cif`, `tw_vat`, `th_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `li_uid`, `li_vat`, `my_itn`, `us_ein`, `kr_brn`, `ca_qst`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `my_sst`, `sg_gst`, `ae_trn`, `cl_tin`, `sa_vat`, `id_npwp`, `my_frp`, `il_vat`, `ge_vat`, `ua_vat`, `is_vat`, `bg_uic`, `hu_tin`, `si_tin`, `ke_pin`, `tr_tin`, `eg_tin`, `ph_tin`, `al_tin`, `bh_vat`, `kz_bin`, `ng_tin`, `om_vat`, `de_stn`, `ch_uid`, `tz_vat`, `uz_vat`, `uz_tin`, `md_vat`, `ma_vat`, `by_tin`, `ao_tin`, `bs_tin`, `bb_tin`, `cd_nif`, `mr_nif`, `me_pib`, `zw_tin`, `ba_tin`, `gn_nif`, `mk_vat`, `sr_fin`, `sn_ninea`, `am_tin`, `np_pan`, `tj_tin`, `ug_tin`, `zm_tin`, `kh_tin`, `aw_tin`, `az_tin`, `bd_bin`, `bj_ifu`, `et_tin`, `kg_tin`, `la_tin`, `cm_niu`, `cv_nif`, `bf_ifu`, or `unknown`
sig { returns(String) }
attr_reader :type
# The value of the tax ID.
sig { returns(T.nilable(String)) }
attr_reader :value
end
class FromInvoice < Stripe::StripeObject
# The relation between this invoice and the cloned invoice
sig { returns(String) }
attr_reader :action
# The invoice that was cloned.
sig { returns(T.any(String, Stripe::Invoice)) }
attr_reader :invoice
end
class Issuer < Stripe::StripeObject
# The connected account being referenced when `type` is `account`.
sig { returns(T.any(String, Stripe::Account)) }
attr_reader :account
# Type of the account referenced.
sig { returns(String) }
attr_reader :type
end
class LastFinalizationError < Stripe::StripeObject
# For card errors resulting from a card issuer decline, a short string indicating [how to proceed with an error](https://stripe.com/docs/declines#retrying-issuer-declines) if they provide one.
sig { returns(String) }
attr_reader :advice_code
# For card errors, the ID of the failed charge.
sig { returns(String) }
attr_reader :charge
# For some errors that could be handled programmatically, a short string indicating the [error code](https://stripe.com/docs/error-codes) reported.
sig { returns(String) }
attr_reader :code
# For card errors resulting from a card issuer decline, a short string indicating the [card issuer's reason for the decline](https://stripe.com/docs/declines#issuer-declines) if they provide one.
sig { returns(String) }
attr_reader :decline_code
# A URL to more information about the [error code](https://stripe.com/docs/error-codes) reported.
sig { returns(String) }
attr_reader :doc_url
# A human-readable message providing more details about the error. For card errors, these messages can be shown to your users.
sig { returns(String) }
attr_reader :message
# For card errors resulting from a card issuer decline, a 2 digit code which indicates the advice given to merchant by the card network on how to proceed with an error.
sig { returns(String) }
attr_reader :network_advice_code
# For card errors resulting from a card issuer decline, a brand specific 2, 3, or 4 digit code which indicates the reason the authorization failed.
sig { returns(String) }
attr_reader :network_decline_code
# If the error is parameter-specific, the parameter related to the error. For example, you can use this to display a message near the correct form field.
sig { returns(String) }
attr_reader :param
# A PaymentIntent guides you through the process of collecting a payment from your customer.
# We recommend that you create exactly one PaymentIntent for each order or
# customer session in your system. You can reference the PaymentIntent later to
# see the history of payment attempts for a particular session.
#
# A PaymentIntent transitions through
# [multiple statuses](https://stripe.com/docs/payments/intents#intent-statuses)
# throughout its lifetime as it interfaces with Stripe.js to perform
# authentication flows and ultimately creates at most one successful charge.
#
# Related guide: [Payment Intents API](https://stripe.com/docs/payments/payment-intents)
sig { returns(Stripe::PaymentIntent) }
attr_reader :payment_intent
# PaymentMethod objects represent your customer's payment instruments.
# You can use them with [PaymentIntents](https://stripe.com/docs/payments/payment-intents) to collect payments or save them to
# Customer objects to store instrument details for future payments.
#
# Related guides: [Payment Methods](https://stripe.com/docs/payments/payment-methods) and [More Payment Scenarios](https://stripe.com/docs/payments/more-payment-scenarios).
sig { returns(Stripe::PaymentMethod) }
attr_reader :payment_method
# If the error is specific to the type of payment method, the payment method type that had a problem. This field is only populated for invoice-related errors.
sig { returns(String) }
attr_reader :payment_method_type
# A URL to the request log entry in your dashboard.
sig { returns(String) }
attr_reader :request_log_url
# A SetupIntent guides you through the process of setting up and saving a customer's payment credentials for future payments.
# For example, you can use a SetupIntent to set up and save your customer's card without immediately collecting a payment.
# Later, you can use [PaymentIntents](https://stripe.com/docs/api#payment_intents) to drive the payment flow.
#
# Create a SetupIntent when you're ready to collect your customer's payment credentials.
# Don't maintain long-lived, unconfirmed SetupIntents because they might not be valid.
# The SetupIntent transitions through multiple [statuses](https://docs.stripe.com/payments/intents#intent-statuses) as it guides
# you through the setup process.
#
# Successful SetupIntents result in payment credentials that are optimized for future payments.
# For example, cardholders in [certain regions](https://stripe.com/guides/strong-customer-authentication) might need to be run through
# [Strong Customer Authentication](https://docs.stripe.com/strong-customer-authentication) during payment method collection
# to streamline later [off-session payments](https://docs.stripe.com/payments/setup-intents).
# If you use the SetupIntent with a [Customer](https://stripe.com/docs/api#setup_intent_object-customer),
# it automatically attaches the resulting payment method to that Customer after successful setup.
# We recommend using SetupIntents or [setup_future_usage](https://stripe.com/docs/api#payment_intent_object-setup_future_usage) on
# PaymentIntents to save payment methods to prevent saving invalid or unoptimized payment methods.
#
# By using SetupIntents, you can reduce friction for your customers, even as regulations change over time.
#
# Related guide: [Setup Intents API](https://docs.stripe.com/payments/setup-intents)
sig { returns(Stripe::SetupIntent) }
attr_reader :setup_intent
# Attribute for field source
sig { returns(T.any(Stripe::Account, Stripe::BankAccount, Stripe::Card, Stripe::Source)) }
attr_reader :source
# The type of error returned. One of `api_error`, `card_error`, `idempotency_error`, or `invalid_request_error`
sig { returns(String) }
attr_reader :type
end
class Parent < Stripe::StripeObject
class QuoteDetails < Stripe::StripeObject
# The quote that generated this invoice
sig { returns(String) }
attr_reader :quote
end
class SubscriptionDetails < Stripe::StripeObject
class PauseCollection < Stripe::StripeObject
# The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`.
sig { returns(T.nilable(String)) }
attr_reader :behavior
# The time after which the subscription will resume collecting payments.
sig { returns(T.nilable(Integer)) }
attr_reader :resumes_at
end
# Set of [key-value pairs](https://stripe.com/docs/api/metadata) defined as subscription metadata when an invoice is created. Becomes an immutable snapshot of the subscription metadata at the time of invoice finalization.
# *Note: This attribute is populated only for invoices created on or after June 29, 2023.*
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# If specified, payment collection for this subscription will be paused. Note that the subscription status will be unchanged and will not be updated to `paused`. Learn more about [pausing collection](https://stripe.com/docs/billing/subscriptions/pause-payment).
sig { returns(T.nilable(PauseCollection)) }
attr_reader :pause_collection
# The subscription that generated this invoice
sig { returns(T.any(String, Stripe::Subscription)) }
attr_reader :subscription
# Only set for upcoming invoices that preview prorations. The time used to calculate prorations.
sig { returns(Integer) }
attr_reader :subscription_proration_date
end
# Details about the quote that generated this invoice
sig { returns(T.nilable(QuoteDetails)) }
attr_reader :quote_details
# Details about the subscription that generated this invoice
sig { returns(T.nilable(SubscriptionDetails)) }
attr_reader :subscription_details
# The type of parent that generated this invoice
sig { returns(String) }
attr_reader :type
end
class PaymentSettings < Stripe::StripeObject
class PaymentMethodOptions < Stripe::StripeObject
class AcssDebit < Stripe::StripeObject
class MandateOptions < Stripe::StripeObject
# Transaction type of the mandate.
sig { returns(T.nilable(String)) }
attr_reader :transaction_type
end
# Attribute for field mandate_options
sig { returns(MandateOptions) }
attr_reader :mandate_options
# Bank account verification method.
sig { returns(String) }
attr_reader :verification_method
end
class Bancontact < Stripe::StripeObject
# Preferred language of the Bancontact authorization page that the customer is redirected to.
sig { returns(String) }
attr_reader :preferred_language
end
class Card < Stripe::StripeObject
class Installments < Stripe::StripeObject
# Whether Installments are enabled for this Invoice.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :enabled
end
# Attribute for field installments
sig { returns(Installments) }
attr_reader :installments
# We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
sig { returns(T.nilable(String)) }
attr_reader :request_three_d_secure
end
class CustomerBalance < Stripe::StripeObject
class BankTransfer < Stripe::StripeObject
class EuBankTransfer < Stripe::StripeObject
# The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
sig { returns(String) }
attr_reader :country
end
# Attribute for field eu_bank_transfer
sig { returns(EuBankTransfer) }
attr_reader :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`, `mx_bank_transfer`, or `us_bank_transfer`.
sig { returns(T.nilable(String)) }
attr_reader :type
end
# Attribute for field bank_transfer
sig { returns(BankTransfer) }
attr_reader :bank_transfer
# The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
sig { returns(T.nilable(String)) }
attr_reader :funding_type
end
class IdBankTransfer < Stripe::StripeObject; end
class Konbini < Stripe::StripeObject; end
class SepaDebit < Stripe::StripeObject; end
class UsBankAccount < Stripe::StripeObject
class FinancialConnections < Stripe::StripeObject
class Filters < Stripe::StripeObject
# The account subcategories to use to filter for possible accounts to link. Valid subcategories are `checking` and `savings`.
sig { returns(T::Array[String]) }
attr_reader :account_subcategories
# The institution to use to filter for possible accounts to link.
sig { returns(String) }
attr_reader :institution
end
# Attribute for field filters
sig { returns(Filters) }
attr_reader :filters
# The list of permissions to request. The `payment_method` permission must be included.
sig { returns(T::Array[String]) }
attr_reader :permissions
# Data features requested to be retrieved upon account creation.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :prefetch
end
# Attribute for field financial_connections
sig { returns(FinancialConnections) }
attr_reader :financial_connections
# Bank account verification method.
sig { returns(String) }
attr_reader :verification_method
end
# If paying by `acss_debit`, this sub-hash contains details about the Canadian pre-authorized debit payment method options to pass to the invoice’s PaymentIntent.
sig { returns(T.nilable(AcssDebit)) }
attr_reader :acss_debit
# If paying by `bancontact`, this sub-hash contains details about the Bancontact payment method options to pass to the invoice’s PaymentIntent.
sig { returns(T.nilable(Bancontact)) }
attr_reader :bancontact
# If paying by `card`, this sub-hash contains details about the Card payment method options to pass to the invoice’s PaymentIntent.
sig { returns(T.nilable(Card)) }
attr_reader :card
# If paying by `customer_balance`, this sub-hash contains details about the Bank transfer payment method options to pass to the invoice’s PaymentIntent.
sig { returns(T.nilable(CustomerBalance)) }
attr_reader :customer_balance
# If paying by `id_bank_transfer`, this sub-hash contains details about the Indonesia bank transfer payment method options to pass to the invoice’s PaymentIntent.
sig { returns(T.nilable(IdBankTransfer)) }
attr_reader :id_bank_transfer
# If paying by `konbini`, this sub-hash contains details about the Konbini payment method options to pass to the invoice’s PaymentIntent.
sig { returns(T.nilable(Konbini)) }
attr_reader :konbini
# If paying by `sepa_debit`, this sub-hash contains details about the SEPA Direct Debit payment method options to pass to the invoice’s PaymentIntent.
sig { returns(T.nilable(SepaDebit)) }
attr_reader :sepa_debit
# If paying by `us_bank_account`, this sub-hash contains details about the ACH direct debit payment method options to pass to the invoice’s PaymentIntent.
sig { returns(T.nilable(UsBankAccount)) }
attr_reader :us_bank_account
end
# ID of the mandate to be used for this invoice. It must correspond to the payment method used to pay the invoice, including the invoice's default_payment_method or default_source, if set.
sig { returns(T.nilable(String)) }
attr_reader :default_mandate
# Payment-method-specific configuration to provide to the invoice’s PaymentIntent.
sig { returns(T.nilable(PaymentMethodOptions)) }
attr_reader :payment_method_options
# The list of payment method types (e.g. card) to provide to the invoice’s PaymentIntent. If not set, Stripe attempts to automatically determine the types to use by looking at the invoice’s default payment method, the subscription’s default payment method, the customer’s default payment method, and your [invoice template settings](https://dashboard.stripe.com/settings/billing/invoice).
sig { returns(T.nilable(T::Array[String])) }
attr_reader :payment_method_types
end
class Rendering < Stripe::StripeObject
class Pdf < Stripe::StripeObject
# Page size of invoice pdf. Options include a4, letter, and auto. If set to auto, page size will be switched to a4 or letter based on customer locale.
sig { returns(T.nilable(String)) }
attr_reader :page_size
end
# How line-item prices and amounts will be displayed with respect to tax on invoice PDFs.
sig { returns(T.nilable(String)) }
attr_reader :amount_tax_display
# Invoice pdf rendering options
sig { returns(T.nilable(Pdf)) }
attr_reader :pdf
# ID of the rendering template that the invoice is formatted by.
sig { returns(T.nilable(String)) }
attr_reader :template
# Version of the rendering template that the invoice is using.
sig { returns(T.nilable(Integer)) }
attr_reader :template_version
end
class ShippingCost < Stripe::StripeObject
class Tax < Stripe::StripeObject
# Amount of tax applied for this rate.
sig { returns(Integer) }
attr_reader :amount
# Tax rates can be applied to [invoices](/invoicing/taxes/tax-rates), [subscriptions](/billing/taxes/tax-rates) and [Checkout Sessions](/payments/checkout/use-manual-tax-rates) to collect tax.
#
# Related guide: [Tax rates](/billing/taxes/tax-rates)
sig { returns(Stripe::TaxRate) }
attr_reader :rate
# 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.
sig { returns(T.nilable(String)) }
attr_reader :taxability_reason
# The amount on which tax is calculated, in cents (or local equivalent).
sig { returns(T.nilable(Integer)) }
attr_reader :taxable_amount
end
# Total shipping cost before any taxes are applied.
sig { returns(Integer) }
attr_reader :amount_subtotal
# Total tax amount applied due to shipping costs. If no tax was applied, defaults to 0.
sig { returns(Integer) }
attr_reader :amount_tax
# Total shipping cost after taxes are applied.
sig { returns(Integer) }
attr_reader :amount_total
# The ID of the ShippingRate for this invoice.
sig { returns(T.nilable(T.any(String, Stripe::ShippingRate))) }
attr_reader :shipping_rate
# The taxes applied to the shipping rate.
sig { returns(T::Array[Tax]) }
attr_reader :taxes
end
class ShippingDetails < Stripe::StripeObject
class Address < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Attribute for field address
sig { returns(Address) }
attr_reader :address
# The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
sig { returns(T.nilable(String)) }
attr_reader :carrier
# Recipient name.
sig { returns(String) }
attr_reader :name
# Recipient phone (including extension).
sig { returns(T.nilable(String)) }
attr_reader :phone
# The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
sig { returns(T.nilable(String)) }
attr_reader :tracking_number
end
class StatusTransitions < Stripe::StripeObject
# The time that the invoice draft was finalized.
sig { returns(T.nilable(Integer)) }
attr_reader :finalized_at
# The time that the invoice was marked uncollectible.
sig { returns(T.nilable(Integer)) }
attr_reader :marked_uncollectible_at
# The time that the invoice was paid.
sig { returns(T.nilable(Integer)) }
attr_reader :paid_at
# The time that the invoice was voided.
sig { returns(T.nilable(Integer)) }
attr_reader :voided_at
end
class ThresholdReason < Stripe::StripeObject
class ItemReason < Stripe::StripeObject
# The IDs of the line items that triggered the threshold invoice.
sig { returns(T::Array[String]) }
attr_reader :line_item_ids
# The quantity threshold boundary that applied to the given line item.
sig { returns(Integer) }
attr_reader :usage_gte
end
# The total invoice amount threshold boundary if it triggered the threshold invoice.
sig { returns(T.nilable(Integer)) }
attr_reader :amount_gte
# Indicates which line items triggered a threshold invoice.
sig { returns(T::Array[ItemReason]) }
attr_reader :item_reasons
end
class TotalDiscountAmount < Stripe::StripeObject
# The amount, in cents (or local equivalent), of the discount.
sig { returns(Integer) }
attr_reader :amount
# The discount that was applied to get this discount amount.
sig { returns(T.any(String, Stripe::Discount)) }
attr_reader :discount
end
class TotalMarginAmount < Stripe::StripeObject
# The amount, in cents (or local equivalent), of the reduction in line item amount.
sig { returns(Integer) }
attr_reader :amount
# The margin that was applied to get this margin amount.
sig { returns(T.any(String, Stripe::Margin)) }
attr_reader :margin
end
class TotalPretaxCreditAmount < Stripe::StripeObject
# The amount, in cents (or local equivalent), of the pretax credit amount.
sig { returns(Integer) }
attr_reader :amount
# The credit balance transaction that was applied to get this pretax credit amount.
sig { returns(T.nilable(T.any(String, Stripe::Billing::CreditBalanceTransaction))) }
attr_reader :credit_balance_transaction
# The discount that was applied to get this pretax credit amount.
sig { returns(T.any(String, Stripe::Discount)) }
attr_reader :discount
# The margin that was applied to get this pretax credit amount.
sig { returns(T.any(String, Stripe::Margin)) }
attr_reader :margin
# Type of the pretax credit amount referenced.
sig { returns(String) }
attr_reader :type
end
class TotalTax < Stripe::StripeObject
class TaxRateDetails < Stripe::StripeObject
# Attribute for field tax_rate
sig { returns(String) }
attr_reader :tax_rate
end
# The amount of the tax, in cents (or local equivalent).
sig { returns(Integer) }
attr_reader :amount
# Whether this tax is inclusive or exclusive.
sig { returns(String) }
attr_reader :tax_behavior
# Additional details about the tax rate. Only present when `type` is `tax_rate_details`.
sig { returns(T.nilable(TaxRateDetails)) }
attr_reader :tax_rate_details
# 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.
sig { returns(String) }
attr_reader :taxability_reason
# The amount on which tax is calculated, in cents (or local equivalent).
sig { returns(T.nilable(Integer)) }
attr_reader :taxable_amount
# The type of tax information.
sig { returns(String) }
attr_reader :type
end
# The country of the business associated with this invoice, most often the business creating the invoice.
sig { returns(T.nilable(String)) }
attr_reader :account_country
# The public name of the business associated with this invoice, most often the business creating the invoice.
sig { returns(T.nilable(String)) }
attr_reader :account_name
# The account tax IDs associated with the invoice. Only editable when the invoice is a draft.
sig { returns(T.nilable(T::Array[T.any(String, Stripe::TaxId)])) }
attr_reader :account_tax_ids
# Final amount due at this time for this invoice. If the invoice's total is smaller than the minimum charge amount, for example, or if there is account credit that can be applied to the invoice, the `amount_due` may be 0. If there is a positive `starting_balance` for the invoice (the customer owes money), the `amount_due` will also take that into account. The charge that gets generated for the invoice will be for the amount specified in `amount_due`.
sig { returns(Integer) }
attr_reader :amount_due
# Amount that was overpaid on the invoice. The amount overpaid is credited to the customer's credit balance.
sig { returns(Integer) }
attr_reader :amount_overpaid
# The amount, in cents (or local equivalent), that was paid.
sig { returns(Integer) }
attr_reader :amount_paid
# The difference between amount_due and amount_paid, in cents (or local equivalent).
sig { returns(Integer) }
attr_reader :amount_remaining
# This is the sum of all the shipping amounts.
sig { returns(Integer) }
attr_reader :amount_shipping
# List of expected payments and corresponding due dates. This value will be null for invoices where collection_method=charge_automatically.
sig { returns(T.nilable(T::Array[AmountsDue])) }
attr_reader :amounts_due
# ID of the Connect Application that created the invoice.
sig { returns(T.nilable(T.any(String, Stripe::Application))) }
attr_reader :application
# Attribute for field applies_to
sig { returns(AppliesTo) }
attr_reader :applies_to
# Number of payment attempts made for this invoice, from the perspective of the payment retry schedule. Any payment attempt counts as the first attempt, and subsequently only automatic retries increment the attempt count. In other words, manual payment attempts after the first attempt do not affect the retry schedule. If a failure is returned with a non-retryable return code, the invoice can no longer be retried unless a new payment method is obtained. Retries will continue to be scheduled, and attempt_count will continue to increment, but retries will only be executed if a new payment method is obtained.
sig { returns(Integer) }
attr_reader :attempt_count
# Whether an attempt has been made to pay the invoice. An invoice is not attempted until 1 hour after the `invoice.created` webhook, for example, so you might not want to display that invoice as unpaid to your users.
sig { returns(T::Boolean) }
attr_reader :attempted
# Attribute for field automatic_tax
sig { returns(AutomaticTax) }
attr_reader :automatic_tax
# The time when this invoice is currently scheduled to be automatically finalized. The field will be `null` if the invoice is not scheduled to finalize in the future. If the invoice is not in the draft state, this field will always be `null` - see `finalized_at` for the time when an already-finalized invoice was finalized.
sig { returns(T.nilable(Integer)) }
attr_reader :automatically_finalizes_at
# Indicates the reason why the invoice was created.
#
# * `manual`: Unrelated to a subscription, for example, created via the invoice editor.
# * `subscription`: No longer in use. Applies to subscriptions from before May 2018 where no distinction was made between updates, cycles, and thresholds.
# * `subscription_create`: A new subscription was created.
# * `subscription_cycle`: A subscription advanced into a new period.
# * `subscription_threshold`: A subscription reached a billing threshold.
# * `subscription_update`: A subscription was updated.
# * `upcoming`: Reserved for simulated invoices, per the upcoming invoice endpoint.
sig { returns(T.nilable(String)) }
attr_reader :billing_reason
# 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.
sig { returns(String) }
attr_reader :collection_method
# The confirmation secret associated with this invoice. Currently, this contains the client_secret of the PaymentIntent that Stripe creates during invoice finalization.
sig { returns(T.nilable(ConfirmationSecret)) }
attr_reader :confirmation_secret
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# 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).
sig { returns(String) }
attr_reader :currency
# Custom fields displayed on the invoice.
sig { returns(T.nilable(T::Array[CustomField])) }
attr_reader :custom_fields
# The ID of the account who will be billed.
sig { returns(T.nilable(String)) }
attr_reader :customer_account
# The customer's address. Until the invoice is finalized, this field will equal `customer.address`. Once the invoice is finalized, this field will no longer be updated.
sig { returns(T.nilable(CustomerAddress)) }
attr_reader :customer_address
# The customer's email. Until the invoice is finalized, this field will equal `customer.email`. Once the invoice is finalized, this field will no longer be updated.
sig { returns(T.nilable(String)) }
attr_reader :customer_email
# The customer's name. Until the invoice is finalized, this field will equal `customer.name`. Once the invoice is finalized, this field will no longer be updated.
sig { returns(T.nilable(String)) }
attr_reader :customer_name
# The customer's phone number. Until the invoice is finalized, this field will equal `customer.phone`. Once the invoice is finalized, this field will no longer be updated.
sig { returns(T.nilable(String)) }
attr_reader :customer_phone
# The customer's shipping information. Until the invoice is finalized, this field will equal `customer.shipping`. Once the invoice is finalized, this field will no longer be updated.
sig { returns(T.nilable(CustomerShipping)) }
attr_reader :customer_shipping
# The customer's tax exempt status. Until the invoice is finalized, this field will equal `customer.tax_exempt`. Once the invoice is finalized, this field will no longer be updated.
sig { returns(T.nilable(String)) }
attr_reader :customer_tax_exempt
# The customer's tax IDs. Until the invoice is finalized, this field will contain the same tax IDs as `customer.tax_ids`. Once the invoice is finalized, this field will no longer be updated.
sig { returns(T.nilable(T::Array[CustomerTaxId])) }
attr_reader :customer_tax_ids
# The margins applied to the invoice. Can be overridden by line item `margins`. Use `expand[]=default_margins` to expand each margin.
sig { returns(T.nilable(T::Array[T.any(String, Stripe::Margin)])) }
attr_reader :default_margins
# 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.
sig { returns(T.nilable(T.any(String, Stripe::PaymentMethod))) }
attr_reader :default_payment_method
# ID of the default payment source for the invoice. It must belong to the customer associated with the invoice and be in a chargeable state. If not set, defaults to the subscription's default source, if any, or to the customer's default source.
sig {
returns(T.nilable(T.any(String, T.any(Stripe::Account, Stripe::BankAccount, Stripe::Card, Stripe::Source))))
}
attr_reader :default_source
# The tax rates applied to this invoice, if any.
sig { returns(T::Array[Stripe::TaxRate]) }
attr_reader :default_tax_rates
# An arbitrary string attached to the object. Often useful for displaying to users. Referenced as 'memo' in the Dashboard.
sig { returns(T.nilable(String)) }
attr_reader :description
# The discounts applied to the invoice. Line item discounts are applied before invoice discounts. Use `expand[]=discounts` to expand each discount.
sig { returns(T::Array[T.any(String, Stripe::Discount)]) }
attr_reader :discounts
# The date on which payment for this invoice is due. This value will be `null` for invoices where `collection_method=charge_automatically`.
sig { returns(T.nilable(Integer)) }
attr_reader :due_date
# The date when this invoice is in effect. Same as `finalized_at` unless overwritten. When defined, this value replaces the system-generated 'Date of issue' printed on the invoice PDF and receipt.
sig { returns(T.nilable(Integer)) }
attr_reader :effective_at
# Ending customer balance after the invoice is finalized. Invoices are finalized approximately an hour after successful webhook delivery or when payment collection is attempted for the invoice. If the invoice has not been finalized yet, this will be null.
sig { returns(T.nilable(Integer)) }
attr_reader :ending_balance
# Footer displayed on the invoice.
sig { returns(T.nilable(String)) }
attr_reader :footer
# Details of the invoice that was cloned. See the [revision documentation](https://stripe.com/docs/invoicing/invoice-revisions) for more details.
sig { returns(T.nilable(FromInvoice)) }
attr_reader :from_invoice
# Unique identifier for the object. For preview invoices created using the [create preview](https://stripe.com/docs/api/invoices/create_preview) endpoint, this id will be prefixed with `upcoming_in`.
sig { returns(String) }
attr_reader :id
# Attribute for field issuer
sig { returns(Issuer) }
attr_reader :issuer
# The error encountered during the previous attempt to finalize the invoice. This field is cleared when the invoice is successfully finalized.
sig { returns(T.nilable(LastFinalizationError)) }
attr_reader :last_finalization_error
# The ID of the most recent non-draft revision of this invoice
sig { returns(T.nilable(T.any(String, Stripe::Invoice))) }
attr_reader :latest_revision
# The individual line items that make up the invoice. `lines` is sorted as follows: (1) pending invoice items (including prorations) in reverse chronological order, (2) subscription items in reverse chronological order, and (3) invoice items added after invoice creation in chronological order.
sig { returns(Stripe::ListObject) }
attr_reader :lines
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# 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.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# The time at which payment will next be attempted. This value will be `null` for invoices where `collection_method=send_invoice`.
sig { returns(T.nilable(Integer)) }
attr_reader :next_payment_attempt
# A unique, identifying string that appears on emails sent to the customer for this invoice. This starts with the customer's unique invoice_prefix if it is specified.
sig { returns(T.nilable(String)) }
attr_reader :number
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The account (if any) for which the funds of the invoice payment are intended. If set, the invoice will be presented with the branding and support information of the specified account. See the [Invoices with Connect](https://stripe.com/docs/billing/invoices/connect) documentation for details.
sig { returns(T.nilable(T.any(String, Stripe::Account))) }
attr_reader :on_behalf_of
# The parent that generated this invoice
sig { returns(T.nilable(Parent)) }
attr_reader :parent
# Attribute for field payment_settings
sig { returns(PaymentSettings) }
attr_reader :payment_settings
# Payments for this invoice
sig { returns(Stripe::ListObject) }
attr_reader :payments
# End of the usage period during which invoice items were added to this invoice. This looks back one period for a subscription invoice. Use the [line item period](/api/invoices/line_item#invoice_line_item_object-period) to get the service period for each price.
sig { returns(Integer) }
attr_reader :period_end
# Start of the usage period during which invoice items were added to this invoice. This looks back one period for a subscription invoice. Use the [line item period](/api/invoices/line_item#invoice_line_item_object-period) to get the service period for each price.
sig { returns(Integer) }
attr_reader :period_start
# Total amount of all post-payment credit notes issued for this invoice.
sig { returns(Integer) }
attr_reader :post_payment_credit_notes_amount
# Total amount of all pre-payment credit notes issued for this invoice.
sig { returns(Integer) }
attr_reader :pre_payment_credit_notes_amount
# This is the transaction number that appears on email receipts sent for this invoice.
sig { returns(T.nilable(String)) }
attr_reader :receipt_number
# The rendering-related settings that control how the invoice is displayed on customer-facing surfaces such as PDF and Hosted Invoice Page.
sig { returns(T.nilable(Rendering)) }
attr_reader :rendering
# The details of the cost of shipping, including the ShippingRate applied on the invoice.
sig { returns(T.nilable(ShippingCost)) }
attr_reader :shipping_cost
# Shipping details for the invoice. The Invoice PDF will use the `shipping_details` value if it is set, otherwise the PDF will render the shipping address from the customer.
sig { returns(T.nilable(ShippingDetails)) }
attr_reader :shipping_details
# Starting customer balance before the invoice is finalized. If the invoice has not been finalized yet, this will be the current customer balance. For revision invoices, this also includes any customer balance that was applied to the original invoice.
sig { returns(Integer) }
attr_reader :starting_balance
# Extra information about an invoice for the customer's credit card statement.
sig { returns(T.nilable(String)) }
attr_reader :statement_descriptor
# The status of the invoice, one of `draft`, `open`, `paid`, `uncollectible`, or `void`. [Learn more](https://stripe.com/docs/billing/invoices/workflow#workflow-overview)
sig { returns(T.nilable(String)) }
attr_reader :status
# Attribute for field status_transitions
sig { returns(StatusTransitions) }
attr_reader :status_transitions
# Attribute for field subscription
sig { returns(T.nilable(T.any(String, Stripe::Subscription))) }
attr_reader :subscription
# 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
sig { returns(Integer) }
attr_reader :subtotal
# The integer amount in cents (or local equivalent) representing the subtotal of the invoice before any invoice level discount or tax is applied. Item discounts are already incorporated
sig { returns(T.nilable(Integer)) }
attr_reader :subtotal_excluding_tax
# ID of the test clock this invoice belongs to.
sig { returns(T.nilable(T.any(String, Stripe::TestHelpers::TestClock))) }
attr_reader :test_clock
# Attribute for field threshold_reason
sig { returns(ThresholdReason) }
attr_reader :threshold_reason
# Total after discounts and taxes.
sig { returns(Integer) }
attr_reader :total
# The aggregate amounts calculated per discount across all line items.
sig { returns(T.nilable(T::Array[TotalDiscountAmount])) }
attr_reader :total_discount_amounts
# The integer amount in cents (or local equivalent) representing the total amount of the invoice including all discounts but excluding all tax.
sig { returns(T.nilable(Integer)) }
attr_reader :total_excluding_tax
# The aggregate amounts calculated per margin across all line items.
sig { returns(T.nilable(T::Array[TotalMarginAmount])) }
attr_reader :total_margin_amounts
# Contains pretax credit amounts (ex: discount, credit grants, etc) that apply to this invoice. This is a combined list of total_pretax_credit_amounts across all invoice line items.
sig { returns(T.nilable(T::Array[TotalPretaxCreditAmount])) }
attr_reader :total_pretax_credit_amounts
# The aggregate tax information of all line items.
sig { returns(T.nilable(T::Array[TotalTax])) }
attr_reader :total_taxes
# Invoices are automatically paid or sent 1 hour after webhooks are delivered, or until all webhook delivery attempts have [been exhausted](https://stripe.com/docs/billing/webhooks#understand). This field tracks the time when webhooks for this invoice were successfully delivered. If the invoice had no webhooks to deliver, this will be set while the invoice is being created.
sig { returns(T.nilable(Integer)) }
attr_reader :webhooks_delivered_at
end
end
# typed: true
module Stripe
class QuotePreviewSubscriptionSchedule < APIResource
class AppliesTo < Stripe::StripeObject
# A custom string that identifies a new subscription schedule being created upon quote acceptance. All quote lines with the same `new_reference` field will be applied to the creation of a new subscription schedule.
sig { returns(T.nilable(String)) }
attr_reader :new_reference
# The ID of the schedule the line applies to.
sig { returns(T.nilable(String)) }
attr_reader :subscription_schedule
# Describes whether the quote line is affecting a new schedule or an existing schedule.
sig { returns(String) }
attr_reader :type
end
class CurrentPhase < Stripe::StripeObject
# The end of this phase of the subscription schedule.
sig { returns(Integer) }
attr_reader :end_date
# The start of this phase of the subscription schedule.
sig { returns(Integer) }
attr_reader :start_date
end
class DefaultSettings < Stripe::StripeObject
class AutomaticTax < Stripe::StripeObject
class Liability < Stripe::StripeObject
# The connected account being referenced when `type` is `account`.
sig { returns(T.any(String, Stripe::Account)) }
attr_reader :account
# Type of the account referenced.
sig { returns(String) }
attr_reader :type
end
# If Stripe disabled automatic tax, this enum describes why.
sig { returns(T.nilable(String)) }
attr_reader :disabled_reason
# Whether Stripe automatically computes tax on invoices created during this phase.
sig { returns(T::Boolean) }
attr_reader :enabled
# The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
sig { returns(T.nilable(Liability)) }
attr_reader :liability
end
class BillingThresholds < Stripe::StripeObject
# Monetary threshold that triggers the subscription to create an invoice
sig { returns(T.nilable(Integer)) }
attr_reader :amount_gte
# Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged. This value may not be `true` if the subscription contains items with plans that have `aggregate_usage=last_ever`.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :reset_billing_cycle_anchor
end
class InvoiceSettings < Stripe::StripeObject
class Issuer < Stripe::StripeObject
# The connected account being referenced when `type` is `account`.
sig { returns(T.any(String, Stripe::Account)) }
attr_reader :account
# Type of the account referenced.
sig { returns(String) }
attr_reader :type
end
# The account tax IDs associated with the subscription schedule. Will be set on invoices generated by the subscription schedule.
sig { returns(T.nilable(T::Array[T.any(String, Stripe::TaxId)])) }
attr_reader :account_tax_ids
# Number of days within which a customer must pay invoices generated by this subscription schedule. This value will be `null` for subscription schedules where `billing=charge_automatically`.
sig { returns(T.nilable(Integer)) }
attr_reader :days_until_due
# Attribute for field issuer
sig { returns(Issuer) }
attr_reader :issuer
end
class TransferData < Stripe::StripeObject
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
sig { returns(T.nilable(Float)) }
attr_reader :amount_percent
# The account where funds from the payment will be transferred to upon payment success.
sig { returns(T.any(String, Stripe::Account)) }
attr_reader :destination
end
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account during this phase of the schedule.
sig { returns(T.nilable(Float)) }
attr_reader :application_fee_percent
# Attribute for field automatic_tax
sig { returns(AutomaticTax) }
attr_reader :automatic_tax
# Possible values are `phase_start` or `automatic`. If `phase_start` then billing cycle anchor of the subscription is set to the start of the phase when entering the phase. If `automatic` then the billing cycle anchor is automatically modified as needed when entering the phase. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).
sig { returns(String) }
attr_reader :billing_cycle_anchor
# Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period
sig { returns(T.nilable(BillingThresholds)) }
attr_reader :billing_thresholds
# Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`.
sig { returns(T.nilable(String)) }
attr_reader :collection_method
# ID of the default payment method for the subscription schedule. If not set, invoices will use the default payment method in the customer's invoice settings.
sig { returns(T.nilable(T.any(String, Stripe::PaymentMethod))) }
attr_reader :default_payment_method
# Subscription description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
sig { returns(T.nilable(String)) }
attr_reader :description
# Attribute for field invoice_settings
sig { returns(InvoiceSettings) }
attr_reader :invoice_settings
# 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.
sig { returns(T.nilable(T.any(String, Stripe::Account))) }
attr_reader :on_behalf_of
# The account (if any) the associated subscription's payments will be attributed to for tax reporting, and where funds from each payment will be transferred to for each of the subscription's invoices.
sig { returns(T.nilable(TransferData)) }
attr_reader :transfer_data
end
class LastPriceMigrationError < Stripe::StripeObject
class FailedTransition < Stripe::StripeObject
# The original price to be migrated.
sig { returns(String) }
attr_reader :source_price
# The intended resulting price of the migration.
sig { returns(String) }
attr_reader :target_price
end
# The time at which the price migration encountered an error.
sig { returns(Integer) }
attr_reader :errored_at
# The involved price pairs in each failed transition.
sig { returns(T::Array[FailedTransition]) }
attr_reader :failed_transitions
# The type of error encountered by the price migration.
sig { returns(String) }
attr_reader :type
end
class Phase < Stripe::StripeObject
class AddInvoiceItem < Stripe::StripeObject
class Discount < Stripe::StripeObject
class DiscountEnd < Stripe::StripeObject
# The discount end timestamp.
sig { returns(T.nilable(Integer)) }
attr_reader :timestamp
# The discount end type.
sig { returns(String) }
attr_reader :type
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(T.any(String, Stripe::Coupon))) }
attr_reader :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(T.any(String, Stripe::Discount))) }
attr_reader :discount
# Details to determine how long the discount should be applied for.
sig { returns(T.nilable(DiscountEnd)) }
attr_reader :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(T.any(String, Stripe::PromotionCode))) }
attr_reader :promotion_code
end
# The stackable discounts that will be applied to the item.
sig { returns(T::Array[Discount]) }
attr_reader :discounts
# ID of the price used to generate the invoice item.
sig { returns(T.any(String, Stripe::Price)) }
attr_reader :price
# The quantity of the invoice item.
sig { returns(T.nilable(Integer)) }
attr_reader :quantity
# The tax rates which apply to the item. When set, the `default_tax_rates` do not apply to this item.
sig { returns(T.nilable(T::Array[Stripe::TaxRate])) }
attr_reader :tax_rates
end
class AutomaticTax < Stripe::StripeObject
class Liability < Stripe::StripeObject
# The connected account being referenced when `type` is `account`.
sig { returns(T.any(String, Stripe::Account)) }
attr_reader :account
# Type of the account referenced.
sig { returns(String) }
attr_reader :type
end
# If Stripe disabled automatic tax, this enum describes why.
sig { returns(T.nilable(String)) }
attr_reader :disabled_reason
# Whether Stripe automatically computes tax on invoices created during this phase.
sig { returns(T::Boolean) }
attr_reader :enabled
# The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
sig { returns(T.nilable(Liability)) }
attr_reader :liability
end
class BillingThresholds < Stripe::StripeObject
# Monetary threshold that triggers the subscription to create an invoice
sig { returns(T.nilable(Integer)) }
attr_reader :amount_gte
# Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged. This value may not be `true` if the subscription contains items with plans that have `aggregate_usage=last_ever`.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :reset_billing_cycle_anchor
end
class Discount < Stripe::StripeObject
class DiscountEnd < Stripe::StripeObject
# The discount end timestamp.
sig { returns(T.nilable(Integer)) }
attr_reader :timestamp
# The discount end type.
sig { returns(String) }
attr_reader :type
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(T.any(String, Stripe::Coupon))) }
attr_reader :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(T.any(String, Stripe::Discount))) }
attr_reader :discount
# Details to determine how long the discount should be applied for.
sig { returns(T.nilable(DiscountEnd)) }
attr_reader :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(T.any(String, Stripe::PromotionCode))) }
attr_reader :promotion_code
end
class InvoiceSettings < Stripe::StripeObject
class Issuer < Stripe::StripeObject
# The connected account being referenced when `type` is `account`.
sig { returns(T.any(String, Stripe::Account)) }
attr_reader :account
# Type of the account referenced.
sig { returns(String) }
attr_reader :type
end
# The account tax IDs associated with this phase of the subscription schedule. Will be set on invoices generated by this phase of the subscription schedule.
sig { returns(T.nilable(T::Array[T.any(String, Stripe::TaxId)])) }
attr_reader :account_tax_ids
# Number of days within which a customer must pay invoices generated by this subscription schedule. This value will be `null` for subscription schedules where `billing=charge_automatically`.
sig { returns(T.nilable(Integer)) }
attr_reader :days_until_due
# The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
sig { returns(T.nilable(Issuer)) }
attr_reader :issuer
end
class Item < Stripe::StripeObject
class BillingThresholds < Stripe::StripeObject
# Usage threshold that triggers the subscription to create an invoice
sig { returns(T.nilable(Integer)) }
attr_reader :usage_gte
end
class Discount < Stripe::StripeObject
class DiscountEnd < Stripe::StripeObject
# The discount end timestamp.
sig { returns(T.nilable(Integer)) }
attr_reader :timestamp
# The discount end type.
sig { returns(String) }
attr_reader :type
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(T.any(String, Stripe::Coupon))) }
attr_reader :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(T.any(String, Stripe::Discount))) }
attr_reader :discount
# Details to determine how long the discount should be applied for.
sig { returns(T.nilable(DiscountEnd)) }
attr_reader :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(T.any(String, Stripe::PromotionCode))) }
attr_reader :promotion_code
end
class Trial < Stripe::StripeObject
# List of price IDs which, if present on the subscription following a paid trial, constitute opting-in to the paid trial.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :converts_to
# Determines the type of trial for this item.
sig { returns(String) }
attr_reader :type
end
# Define thresholds at which an invoice will be sent, and the related subscription advanced to a new billing period
sig { returns(T.nilable(BillingThresholds)) }
attr_reader :billing_thresholds
# The discounts applied to the subscription item. Subscription item discounts are applied before subscription discounts. Use `expand[]=discounts` to expand each discount.
sig { returns(T::Array[Discount]) }
attr_reader :discounts
# Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an item. Metadata on this item will update the underlying subscription item's `metadata` when the phase is entered.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# ID of the plan to which the customer should be subscribed.
sig { returns(T.any(String, Stripe::Plan)) }
attr_reader :plan
# ID of the price to which the customer should be subscribed.
sig { returns(T.any(String, Stripe::Price)) }
attr_reader :price
# Quantity of the plan to which the customer should be subscribed.
sig { returns(Integer) }
attr_reader :quantity
# The tax rates which apply to this `phase_item`. When set, the `default_tax_rates` on the phase do not apply to this `phase_item`.
sig { returns(T.nilable(T::Array[Stripe::TaxRate])) }
attr_reader :tax_rates
# Options that configure the trial on the subscription item.
sig { returns(T.nilable(Trial)) }
attr_reader :trial
end
class PauseCollection < Stripe::StripeObject
# The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`.
sig { returns(String) }
attr_reader :behavior
end
class TransferData < Stripe::StripeObject
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
sig { returns(T.nilable(Float)) }
attr_reader :amount_percent
# The account where funds from the payment will be transferred to upon payment success.
sig { returns(T.any(String, Stripe::Account)) }
attr_reader :destination
end
class TrialSettings < Stripe::StripeObject
class EndBehavior < Stripe::StripeObject
# Configure how an opt-in following a paid trial is billed when using `billing_behavior: prorate_up_front`.
sig { returns(T.nilable(String)) }
attr_reader :prorate_up_front
end
# Defines how the subscription should behave when a trial ends.
sig { returns(T.nilable(EndBehavior)) }
attr_reader :end_behavior
end
# A list of prices and quantities that will generate invoice items appended to the next invoice for this phase.
sig { returns(T::Array[AddInvoiceItem]) }
attr_reader :add_invoice_items
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account during this phase of the schedule.
sig { returns(T.nilable(Float)) }
attr_reader :application_fee_percent
# Attribute for field automatic_tax
sig { returns(AutomaticTax) }
attr_reader :automatic_tax
# Possible values are `phase_start` or `automatic`. If `phase_start` then billing cycle anchor of the subscription is set to the start of the phase when entering the phase. If `automatic` then the billing cycle anchor is automatically modified as needed when entering the phase. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).
sig { returns(T.nilable(String)) }
attr_reader :billing_cycle_anchor
# Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period
sig { returns(T.nilable(BillingThresholds)) }
attr_reader :billing_thresholds
# Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`.
sig { returns(T.nilable(String)) }
attr_reader :collection_method
# 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).
sig { returns(String) }
attr_reader :currency
# ID of the default payment method for the subscription schedule. It must belong to the customer associated with the subscription schedule. If not set, invoices will use the default payment method in the customer's invoice settings.
sig { returns(T.nilable(T.any(String, Stripe::PaymentMethod))) }
attr_reader :default_payment_method
# The default tax rates to apply to the subscription during this phase of the subscription schedule.
sig { returns(T.nilable(T::Array[Stripe::TaxRate])) }
attr_reader :default_tax_rates
# Subscription description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
sig { returns(T.nilable(String)) }
attr_reader :description
# The stackable discounts that will be applied to the subscription on this phase. Subscription item discounts are applied before subscription discounts.
sig { returns(T::Array[Discount]) }
attr_reader :discounts
# The end of this phase of the subscription schedule.
sig { returns(Integer) }
attr_reader :end_date
# The invoice settings applicable during this phase.
sig { returns(T.nilable(InvoiceSettings)) }
attr_reader :invoice_settings
# Subscription items to configure the subscription to during this phase of the subscription schedule.
sig { returns(T::Array[Item]) }
attr_reader :items
# Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to a phase. Metadata on a schedule's phase will update the underlying subscription's `metadata` when the phase is entered. Updating the underlying subscription's `metadata` directly will not affect the current phase's `metadata`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :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.
sig { returns(T.nilable(T.any(String, Stripe::Account))) }
attr_reader :on_behalf_of
# If specified, payment collection for this subscription will be paused. Note that the subscription status will be unchanged and will not be updated to `paused`. Learn more about [pausing collection](https://stripe.com/docs/billing/subscriptions/pause-payment).
sig { returns(T.nilable(PauseCollection)) }
attr_reader :pause_collection
# When transitioning phases, controls how prorations are handled (if any). Possible values are `create_prorations`, `none`, and `always_invoice`.
sig { returns(String) }
attr_reader :proration_behavior
# The start of this phase of the subscription schedule.
sig { returns(Integer) }
attr_reader :start_date
# The account (if any) the associated subscription's payments will be attributed to for tax reporting, and where funds from each payment will be transferred to for each of the subscription's invoices.
sig { returns(T.nilable(TransferData)) }
attr_reader :transfer_data
# Specify behavior of the trial when crossing schedule phase boundaries
sig { returns(T.nilable(String)) }
attr_reader :trial_continuation
# When the trial ends within the phase.
sig { returns(T.nilable(Integer)) }
attr_reader :trial_end
# Settings related to any trials on the subscription during this phase.
sig { returns(T.nilable(TrialSettings)) }
attr_reader :trial_settings
end
class Prebilling < Stripe::StripeObject
# ID of the prebilling invoice.
sig { returns(T.any(String, Stripe::Invoice)) }
attr_reader :invoice
# The end of the last period for which the invoice pre-bills.
sig { returns(Integer) }
attr_reader :period_end
# The start of the first period for which the invoice pre-bills.
sig { returns(Integer) }
attr_reader :period_start
# Whether to cancel or preserve `prebilling` if the subscription is updated during the prebilled period.
sig { returns(String) }
attr_reader :update_behavior
end
# ID of the Connect Application that created the schedule.
sig { returns(T.nilable(T.any(String, Stripe::Application))) }
attr_reader :application
# Attribute for field applies_to
sig { returns(AppliesTo) }
attr_reader :applies_to
# Configures when the subscription schedule generates prorations for phase transitions. Possible values are `prorate_on_next_phase` or `prorate_up_front` with the default being `prorate_on_next_phase`. `prorate_on_next_phase` will apply phase changes and generate prorations at transition time. `prorate_up_front` will bill for all phases within the current billing cycle up front.
sig { returns(String) }
attr_reader :billing_behavior
# The [billing mode](/api/subscriptions/create#create_subscription-billing_mode) that will be used to process all future operations for the subscription schedule.
sig { returns(String) }
attr_reader :billing_mode
# Time at which the subscription schedule was canceled. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_reader :canceled_at
# Time at which the subscription schedule was completed. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_reader :completed_at
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# Object representing the start and end dates for the current phase of the subscription schedule, if it is `active`.
sig { returns(T.nilable(CurrentPhase)) }
attr_reader :current_phase
# ID of the customer who owns the subscription schedule.
sig { returns(T.any(String, Stripe::Customer)) }
attr_reader :customer
# ID of the account who owns the subscription schedule.
sig { returns(T.nilable(String)) }
attr_reader :customer_account
# Attribute for field default_settings
sig { returns(DefaultSettings) }
attr_reader :default_settings
# Behavior of the subscription schedule and underlying subscription when it ends. Possible values are `release` or `cancel` with the default being `release`. `release` will end the subscription schedule and keep the underlying subscription running. `cancel` will end the subscription schedule and cancel the underlying subscription.
sig { returns(String) }
attr_reader :end_behavior
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Details of the most recent price migration that failed for the subscription schedule.
sig { returns(T.nilable(LastPriceMigrationError)) }
attr_reader :last_price_migration_error
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# 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.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Configuration for the subscription schedule's phases.
sig { returns(T::Array[Phase]) }
attr_reader :phases
# Time period and invoice for a Subscription billed in advance.
sig { returns(T.nilable(Prebilling)) }
attr_reader :prebilling
# Time at which the subscription schedule was released. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_reader :released_at
# ID of the subscription once managed by the subscription schedule (if it is released).
sig { returns(T.nilable(String)) }
attr_reader :released_subscription
# The present status of the subscription schedule. Possible values are `not_started`, `active`, `completed`, `released`, and `canceled`. You can read more about the different states in our [behavior guide](https://stripe.com/docs/billing/subscriptions/subscription-schedules).
sig { returns(String) }
attr_reader :status
# ID of the subscription managed by the subscription schedule.
sig { returns(T.nilable(T.any(String, Stripe::Subscription))) }
attr_reader :subscription
# ID of the test clock this subscription schedule belongs to.
sig { returns(T.nilable(T.any(String, Stripe::TestHelpers::TestClock))) }
attr_reader :test_clock
end
end
# typed: true
module Stripe
module Radar
# An early fraud warning indicates that the card issuer has notified us that a
# charge may be fraudulent.
#
# Related guide: [Early fraud warnings](https://stripe.com/docs/disputes/measuring#early-fraud-warnings)
class EarlyFraudWarning < APIResource
# An EFW is actionable if it has not received a dispute and has not been fully refunded. You may wish to proactively refund a charge that receives an EFW, in order to avoid receiving a dispute later.
sig { returns(T::Boolean) }
attr_reader :actionable
# ID of the charge this early fraud warning is for, optionally expanded.
sig { returns(T.any(String, Stripe::Charge)) }
attr_reader :charge
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# The type of fraud labelled by the issuer. One of `card_never_received`, `fraudulent_card_application`, `made_with_counterfeit_card`, `made_with_lost_card`, `made_with_stolen_card`, `misc`, `unauthorized_use_of_card`.
sig { returns(String) }
attr_reader :fraud_type
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# ID of the Payment Intent this early fraud warning is for, optionally expanded.
sig { returns(T.any(String, Stripe::PaymentIntent)) }
attr_reader :payment_intent
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return early fraud warnings for the charge specified by this charge ID.
sig { returns(T.nilable(String)) }
attr_accessor :charge
# Only return early fraud warnings that were created during the given date interval.
sig {
returns(T.nilable(T.any(::Stripe::Radar::EarlyFraudWarning::ListParams::Created, Integer)))
}
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Only return early fraud warnings for charges that were created by the PaymentIntent specified by this PaymentIntent ID.
sig { returns(T.nilable(String)) }
attr_accessor :payment_intent
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(charge: T.nilable(String), created: T.nilable(T.any(::Stripe::Radar::EarlyFraudWarning::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), payment_intent: T.nilable(String), starting_after: T.nilable(String)).void
}
def initialize(
charge: nil,
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
payment_intent: nil,
starting_after: nil
); end
end
# Returns a list of early fraud warnings.
sig {
params(params: T.any(::Stripe::Radar::EarlyFraudWarning::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Radar
# Value lists allow you to group values together which can then be referenced in rules.
#
# Related guide: [Default Stripe lists](https://stripe.com/docs/radar/lists#managing-list-items)
class ValueList < APIResource
# The name of the value list for use in rules.
sig { returns(String) }
attr_reader :alias
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# The name or email address of the user who created this value list.
sig { returns(String) }
attr_reader :created_by
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# The type of items in the value list. One of `card_fingerprint`, `us_bank_account_fingerprint`, `sepa_debit_fingerprint`, `card_bin`, `email`, `ip_address`, `country`, `string`, `case_sensitive_string`, or `customer_id`.
sig { returns(String) }
attr_reader :item_type
# List of items contained within this value list.
sig { returns(Stripe::ListObject) }
attr_reader :list_items
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# 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.
sig { returns(T::Hash[String, String]) }
attr_reader :metadata
# The name of the value list.
sig { returns(String) }
attr_reader :name
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Always true for a deleted object
sig { returns(T::Boolean) }
attr_reader :deleted
class DeleteParams < Stripe::RequestParams; end
class UpdateParams < Stripe::RequestParams
# The name of the value list for use in rules.
sig { returns(T.nilable(String)) }
attr_accessor :alias
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The human-readable name of the value list.
sig { returns(T.nilable(String)) }
attr_accessor :name
sig {
params(alias_: T.nilable(String), expand: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), name: T.nilable(String)).void
}
def initialize(alias_: nil, expand: nil, metadata: nil, name: nil); end
end
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# The alias used to reference the value list when writing rules.
sig { returns(T.nilable(String)) }
attr_accessor :alias
# A value contained within a value list - returns all value lists containing this value.
sig { returns(T.nilable(String)) }
attr_accessor :contains
# Only return value lists that were created during the given date interval.
sig { returns(T.nilable(T.any(::Stripe::Radar::ValueList::ListParams::Created, Integer))) }
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(alias_: T.nilable(String), contains: T.nilable(String), created: T.nilable(T.any(::Stripe::Radar::ValueList::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
alias_: nil,
contains: nil,
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
# The name of the value list for use in rules.
sig { returns(String) }
attr_accessor :alias
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Type of the items in the value list. One of `card_fingerprint`, `us_bank_account_fingerprint`, `sepa_debit_fingerprint`, `card_bin`, `email`, `ip_address`, `country`, `string`, `case_sensitive_string`, or `customer_id`. Use `string` if the item type is unknown or mixed.
sig { returns(T.nilable(String)) }
attr_accessor :item_type
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The human-readable name of the value list.
sig { returns(String) }
attr_accessor :name
sig {
params(alias_: String, expand: T.nilable(T::Array[String]), item_type: T.nilable(String), metadata: T.nilable(T::Hash[String, String]), name: String).void
}
def initialize(alias_: nil, expand: nil, item_type: nil, metadata: nil, name: nil); end
end
# Creates a new ValueList object, which can then be referenced in rules.
sig {
params(params: T.any(::Stripe::Radar::ValueList::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Radar::ValueList)
}
def self.create(params = {}, opts = {}); end
# Deletes a ValueList object, also deleting any items contained within the value list. To be deleted, a value list must not be referenced in any rules.
sig {
params(value_list: String, params: T.any(::Stripe::Radar::ValueList::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Radar::ValueList)
}
def self.delete(value_list, params = {}, opts = {}); end
# Deletes a ValueList object, also deleting any items contained within the value list. To be deleted, a value list must not be referenced in any rules.
sig {
params(params: T.any(::Stripe::Radar::ValueList::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Radar::ValueList)
}
def delete(params = {}, opts = {}); end
# Returns a list of ValueList objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.
sig {
params(params: T.any(::Stripe::Radar::ValueList::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Updates a ValueList object by setting the values of the parameters passed. Any parameters not provided will be left unchanged. Note that item_type is immutable.
sig {
params(value_list: String, params: T.any(::Stripe::Radar::ValueList::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Radar::ValueList)
}
def self.update(value_list, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Radar
# Value list items allow you to add specific values to a given Radar value list, which can then be used in rules.
#
# Related guide: [Managing list items](https://stripe.com/docs/radar/lists#managing-list-items)
class ValueListItem < APIResource
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# The name or email address of the user who added this item to the value list.
sig { returns(String) }
attr_reader :created_by
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The value of the item.
sig { returns(String) }
attr_reader :value
# The identifier of the value list this item belongs to.
sig { returns(String) }
attr_reader :value_list
# Always true for a deleted object
sig { returns(T::Boolean) }
attr_reader :deleted
class DeleteParams < Stripe::RequestParams; end
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return items that were created during the given date interval.
sig {
returns(T.nilable(T.any(::Stripe::Radar::ValueListItem::ListParams::Created, Integer)))
}
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Return items belonging to the parent list whose value matches the specified value (using an "is like" match).
sig { returns(T.nilable(String)) }
attr_accessor :value
# Identifier for the parent value list this item belongs to.
sig { returns(String) }
attr_accessor :value_list
sig {
params(created: T.nilable(T.any(::Stripe::Radar::ValueListItem::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String), value: T.nilable(String), value_list: String).void
}
def initialize(
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil,
value: nil,
value_list: nil
); end
end
class CreateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The value of the item (whose type must match the type of the parent value list).
sig { returns(String) }
attr_accessor :value
# The identifier of the value list which the created item will be added to.
sig { returns(String) }
attr_accessor :value_list
sig { params(expand: T.nilable(T::Array[String]), value: String, value_list: String).void }
def initialize(expand: nil, value: nil, value_list: nil); end
end
# Creates a new ValueListItem object, which is added to the specified parent value list.
sig {
params(params: T.any(::Stripe::Radar::ValueListItem::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Radar::ValueListItem)
}
def self.create(params = {}, opts = {}); end
# Deletes a ValueListItem object, removing it from its parent value list.
sig {
params(item: String, params: T.any(::Stripe::Radar::ValueListItem::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Radar::ValueListItem)
}
def self.delete(item, params = {}, opts = {}); end
# Deletes a ValueListItem object, removing it from its parent value list.
sig {
params(params: T.any(::Stripe::Radar::ValueListItem::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Radar::ValueListItem)
}
def delete(params = {}, opts = {}); end
# Returns a list of ValueListItem objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.
sig {
params(params: T.any(::Stripe::Radar::ValueListItem::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
# Refund objects allow you to refund a previously created charge that isn't
# refunded yet. Funds are refunded to the credit or debit card that's
# initially charged.
#
# Related guide: [Refunds](https://stripe.com/docs/refunds)
class Refund < APIResource
class DestinationDetails < Stripe::StripeObject
class Affirm < Stripe::StripeObject; end
class AfterpayClearpay < Stripe::StripeObject; end
class Alipay < Stripe::StripeObject; end
class Alma < Stripe::StripeObject; end
class AmazonPay < Stripe::StripeObject; end
class AuBankTransfer < Stripe::StripeObject; end
class Blik < Stripe::StripeObject
# For refunds declined by the network, a decline code provided by the network which indicates the reason the refund failed.
sig { returns(T.nilable(String)) }
attr_reader :network_decline_code
# The reference assigned to the refund.
sig { returns(T.nilable(String)) }
attr_reader :reference
# Status of the reference on the refund. This can be `pending`, `available` or `unavailable`.
sig { returns(T.nilable(String)) }
attr_reader :reference_status
end
class BrBankTransfer < Stripe::StripeObject
# The reference assigned to the refund.
sig { returns(T.nilable(String)) }
attr_reader :reference
# Status of the reference on the refund. This can be `pending`, `available` or `unavailable`.
sig { returns(T.nilable(String)) }
attr_reader :reference_status
end
class Card < Stripe::StripeObject
# Value of the reference number assigned to the refund.
sig { returns(String) }
attr_reader :reference
# Status of the reference number on the refund. This can be `pending`, `available` or `unavailable`.
sig { returns(String) }
attr_reader :reference_status
# Type of the reference number assigned to the refund.
sig { returns(String) }
attr_reader :reference_type
# The type of refund. This can be `refund`, `reversal`, or `pending`.
sig { returns(String) }
attr_reader :type
end
class Cashapp < Stripe::StripeObject; end
class CustomerCashBalance < Stripe::StripeObject; end
class Eps < Stripe::StripeObject; end
class EuBankTransfer < Stripe::StripeObject
# The reference assigned to the refund.
sig { returns(T.nilable(String)) }
attr_reader :reference
# Status of the reference on the refund. This can be `pending`, `available` or `unavailable`.
sig { returns(T.nilable(String)) }
attr_reader :reference_status
end
class GbBankTransfer < Stripe::StripeObject
# The reference assigned to the refund.
sig { returns(T.nilable(String)) }
attr_reader :reference
# Status of the reference on the refund. This can be `pending`, `available` or `unavailable`.
sig { returns(T.nilable(String)) }
attr_reader :reference_status
end
class Giropay < Stripe::StripeObject; end
class Grabpay < Stripe::StripeObject; end
class IdBankTransfer < Stripe::StripeObject
# The reference assigned to the refund.
sig { returns(T.nilable(String)) }
attr_reader :reference
# Status of the reference on the refund. This can be `pending`, `available` or `unavailable`.
sig { returns(T.nilable(String)) }
attr_reader :reference_status
end
class JpBankTransfer < Stripe::StripeObject
# The reference assigned to the refund.
sig { returns(T.nilable(String)) }
attr_reader :reference
# Status of the reference on the refund. This can be `pending`, `available` or `unavailable`.
sig { returns(T.nilable(String)) }
attr_reader :reference_status
end
class Klarna < Stripe::StripeObject; end
class Multibanco < Stripe::StripeObject
# The reference assigned to the refund.
sig { returns(T.nilable(String)) }
attr_reader :reference
# Status of the reference on the refund. This can be `pending`, `available` or `unavailable`.
sig { returns(T.nilable(String)) }
attr_reader :reference_status
end
class MxBankTransfer < Stripe::StripeObject
# The reference assigned to the refund.
sig { returns(T.nilable(String)) }
attr_reader :reference
# Status of the reference on the refund. This can be `pending`, `available` or `unavailable`.
sig { returns(T.nilable(String)) }
attr_reader :reference_status
end
class NzBankTransfer < Stripe::StripeObject; end
class P24 < Stripe::StripeObject
# The reference assigned to the refund.
sig { returns(T.nilable(String)) }
attr_reader :reference
# Status of the reference on the refund. This can be `pending`, `available` or `unavailable`.
sig { returns(T.nilable(String)) }
attr_reader :reference_status
end
class Paynow < Stripe::StripeObject; end
class Paypal < Stripe::StripeObject
# For refunds declined by the network, a decline code provided by the network which indicates the reason the refund failed.
sig { returns(T.nilable(String)) }
attr_reader :network_decline_code
end
class Pix < Stripe::StripeObject; end
class Revolut < Stripe::StripeObject; end
class Sofort < Stripe::StripeObject; end
class Swish < Stripe::StripeObject
# For refunds declined by the network, a decline code provided by the network which indicates the reason the refund failed.
sig { returns(T.nilable(String)) }
attr_reader :network_decline_code
# The reference assigned to the refund.
sig { returns(T.nilable(String)) }
attr_reader :reference
# Status of the reference on the refund. This can be `pending`, `available` or `unavailable`.
sig { returns(T.nilable(String)) }
attr_reader :reference_status
end
class ThBankTransfer < Stripe::StripeObject
# The reference assigned to the refund.
sig { returns(T.nilable(String)) }
attr_reader :reference
# Status of the reference on the refund. This can be `pending`, `available` or `unavailable`.
sig { returns(T.nilable(String)) }
attr_reader :reference_status
end
class UsBankTransfer < Stripe::StripeObject
# The reference assigned to the refund.
sig { returns(T.nilable(String)) }
attr_reader :reference
# Status of the reference on the refund. This can be `pending`, `available` or `unavailable`.
sig { returns(T.nilable(String)) }
attr_reader :reference_status
end
class WechatPay < Stripe::StripeObject; end
class Zip < Stripe::StripeObject; end
# Attribute for field affirm
sig { returns(Affirm) }
attr_reader :affirm
# Attribute for field afterpay_clearpay
sig { returns(AfterpayClearpay) }
attr_reader :afterpay_clearpay
# Attribute for field alipay
sig { returns(Alipay) }
attr_reader :alipay
# Attribute for field alma
sig { returns(Alma) }
attr_reader :alma
# Attribute for field amazon_pay
sig { returns(AmazonPay) }
attr_reader :amazon_pay
# Attribute for field au_bank_transfer
sig { returns(AuBankTransfer) }
attr_reader :au_bank_transfer
# Attribute for field blik
sig { returns(Blik) }
attr_reader :blik
# Attribute for field br_bank_transfer
sig { returns(BrBankTransfer) }
attr_reader :br_bank_transfer
# Attribute for field card
sig { returns(Card) }
attr_reader :card
# Attribute for field cashapp
sig { returns(Cashapp) }
attr_reader :cashapp
# Attribute for field customer_cash_balance
sig { returns(CustomerCashBalance) }
attr_reader :customer_cash_balance
# Attribute for field eps
sig { returns(Eps) }
attr_reader :eps
# Attribute for field eu_bank_transfer
sig { returns(EuBankTransfer) }
attr_reader :eu_bank_transfer
# Attribute for field gb_bank_transfer
sig { returns(GbBankTransfer) }
attr_reader :gb_bank_transfer
# Attribute for field giropay
sig { returns(Giropay) }
attr_reader :giropay
# Attribute for field grabpay
sig { returns(Grabpay) }
attr_reader :grabpay
# Attribute for field id_bank_transfer
sig { returns(IdBankTransfer) }
attr_reader :id_bank_transfer
# Attribute for field jp_bank_transfer
sig { returns(JpBankTransfer) }
attr_reader :jp_bank_transfer
# Attribute for field klarna
sig { returns(Klarna) }
attr_reader :klarna
# Attribute for field multibanco
sig { returns(Multibanco) }
attr_reader :multibanco
# Attribute for field mx_bank_transfer
sig { returns(MxBankTransfer) }
attr_reader :mx_bank_transfer
# Attribute for field nz_bank_transfer
sig { returns(NzBankTransfer) }
attr_reader :nz_bank_transfer
# Attribute for field p24
sig { returns(P24) }
attr_reader :p24
# Attribute for field paynow
sig { returns(Paynow) }
attr_reader :paynow
# Attribute for field paypal
sig { returns(Paypal) }
attr_reader :paypal
# Attribute for field pix
sig { returns(Pix) }
attr_reader :pix
# Attribute for field revolut
sig { returns(Revolut) }
attr_reader :revolut
# Attribute for field sofort
sig { returns(Sofort) }
attr_reader :sofort
# Attribute for field swish
sig { returns(Swish) }
attr_reader :swish
# Attribute for field th_bank_transfer
sig { returns(ThBankTransfer) }
attr_reader :th_bank_transfer
# The type of transaction-specific details of the payment method used in the refund (e.g., `card`). An additional hash is included on `destination_details` with a name matching this value. It contains information specific to the refund transaction.
sig { returns(String) }
attr_reader :type
# Attribute for field us_bank_transfer
sig { returns(UsBankTransfer) }
attr_reader :us_bank_transfer
# Attribute for field wechat_pay
sig { returns(WechatPay) }
attr_reader :wechat_pay
# Attribute for field zip
sig { returns(Zip) }
attr_reader :zip
end
class NextAction < Stripe::StripeObject
class DisplayDetails < Stripe::StripeObject
class EmailSent < Stripe::StripeObject
# The timestamp when the email was sent.
sig { returns(Integer) }
attr_reader :email_sent_at
# The recipient's email address.
sig { returns(String) }
attr_reader :email_sent_to
end
# Attribute for field email_sent
sig { returns(EmailSent) }
attr_reader :email_sent
# The expiry timestamp.
sig { returns(Integer) }
attr_reader :expires_at
end
# Attribute for field display_details
sig { returns(DisplayDetails) }
attr_reader :display_details
# Type of the next action to perform.
sig { returns(String) }
attr_reader :type
end
class PresentmentDetails < Stripe::StripeObject
# Amount intended to be collected by this payment, denominated in presentment_currency.
sig { returns(Integer) }
attr_reader :presentment_amount
# Currency presented to the customer during payment.
sig { returns(String) }
attr_reader :presentment_currency
end
# Amount, in cents (or local equivalent).
sig { returns(Integer) }
attr_reader :amount
# Balance transaction that describes the impact on your account balance.
sig { returns(T.nilable(T.any(String, Stripe::BalanceTransaction))) }
attr_reader :balance_transaction
# ID of the charge that's refunded.
sig { returns(T.nilable(T.any(String, Stripe::Charge))) }
attr_reader :charge
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# 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).
sig { returns(String) }
attr_reader :currency
# An arbitrary string attached to the object. You can use this for displaying to users (available on non-card refunds only).
sig { returns(String) }
attr_reader :description
# Attribute for field destination_details
sig { returns(DestinationDetails) }
attr_reader :destination_details
# After the refund fails, this balance transaction describes the adjustment made on your account balance that reverses the initial balance transaction.
sig { returns(T.any(String, Stripe::BalanceTransaction)) }
attr_reader :failure_balance_transaction
# Provides the reason for the refund failure. Possible values are: `lost_or_stolen_card`, `expired_or_canceled_card`, `charge_for_pending_refund_disputed`, `insufficient_funds`, `declined`, `merchant_request`, or `unknown`.
sig { returns(String) }
attr_reader :failure_reason
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# For payment methods without native refund support (for example, Konbini, PromptPay), provide an email address for the customer to receive refund instructions.
sig { returns(String) }
attr_reader :instructions_email
# 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.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# Attribute for field next_action
sig { returns(NextAction) }
attr_reader :next_action
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# ID of the PaymentIntent that's refunded.
sig { returns(T.nilable(T.any(String, Stripe::PaymentIntent))) }
attr_reader :payment_intent
# Provides the reason for why the refund is pending. Possible values are: `processing`, `insufficient_funds`, or `charge_pending`.
sig { returns(String) }
attr_reader :pending_reason
# Attribute for field presentment_details
sig { returns(PresentmentDetails) }
attr_reader :presentment_details
# Reason for the refund, which is either user-provided (`duplicate`, `fraudulent`, or `requested_by_customer`) or generated by Stripe internally (`expired_uncaptured_charge`).
sig { returns(T.nilable(String)) }
attr_reader :reason
# This is the transaction number that appears on email receipts sent for this refund.
sig { returns(T.nilable(String)) }
attr_reader :receipt_number
# The transfer reversal that's associated with the refund. Only present if the charge came from another Stripe account.
sig { returns(T.nilable(T.any(String, Stripe::Reversal))) }
attr_reader :source_transfer_reversal
# Status of the refund. This can be `pending`, `requires_action`, `succeeded`, `failed`, or `canceled`. Learn more about [failed refunds](https://stripe.com/docs/refunds#failed-refunds).
sig { returns(T.nilable(String)) }
attr_reader :status
# This refers to the transfer reversal object if the accompanying transfer reverses. This is only applicable if the charge was created using the destination parameter.
sig { returns(T.nilable(T.any(String, Stripe::Reversal))) }
attr_reader :transfer_reversal
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return refunds for the charge specified by this charge ID.
sig { returns(T.nilable(String)) }
attr_accessor :charge
# Only return refunds that were created during the given date interval.
sig { returns(T.nilable(T.any(::Stripe::Refund::ListParams::Created, Integer))) }
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Only return refunds for the PaymentIntent specified by this ID.
sig { returns(T.nilable(String)) }
attr_accessor :payment_intent
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(charge: T.nilable(String), created: T.nilable(T.any(::Stripe::Refund::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), payment_intent: T.nilable(String), starting_after: T.nilable(String)).void
}
def initialize(
charge: nil,
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
payment_intent: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
# Attribute for param field amount
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# The identifier of the charge to refund.
sig { returns(T.nilable(String)) }
attr_accessor :charge
# 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).
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Customer whose customer balance to refund from.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# For payment methods without native refund support (e.g., Konbini, PromptPay), use this email from the customer to receive refund instructions.
sig { returns(T.nilable(String)) }
attr_accessor :instructions_email
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Origin of the refund
sig { returns(T.nilable(String)) }
attr_accessor :origin
# The identifier of the PaymentIntent to refund.
sig { returns(T.nilable(String)) }
attr_accessor :payment_intent
# String indicating the reason for the refund. If set, possible values are `duplicate`, `fraudulent`, and `requested_by_customer`. If you believe the charge to be fraudulent, specifying `fraudulent` as the reason will add the associated card and email to your [block lists](https://stripe.com/docs/radar/lists), and will also help us improve our fraud detection algorithms.
sig { returns(T.nilable(String)) }
attr_accessor :reason
# Boolean indicating whether the application fee should be refunded when refunding this charge. If a full charge refund is given, the full application fee will be refunded. Otherwise, the application fee will be refunded in an amount proportional to the amount of the charge refunded. An application fee can be refunded only by the application that created the charge.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :refund_application_fee
# Boolean indicating whether the transfer should be reversed when refunding this charge. The transfer will be reversed proportionally to the amount being refunded (either the entire or partial amount).
A transfer can be reversed only by the application that created the charge.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :reverse_transfer
sig {
params(amount: T.nilable(Integer), charge: T.nilable(String), currency: T.nilable(String), customer: T.nilable(String), expand: T.nilable(T::Array[String]), instructions_email: T.nilable(String), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), origin: T.nilable(String), payment_intent: T.nilable(String), reason: T.nilable(String), refund_application_fee: T.nilable(T::Boolean), reverse_transfer: T.nilable(T::Boolean)).void
}
def initialize(
amount: nil,
charge: nil,
currency: nil,
customer: nil,
expand: nil,
instructions_email: nil,
metadata: nil,
origin: nil,
payment_intent: nil,
reason: nil,
refund_application_fee: nil,
reverse_transfer: nil
); end
end
class UpdateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
sig {
params(expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String])))).void
}
def initialize(expand: nil, metadata: nil); end
end
class CancelParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class ExpireParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Cancels a refund with a status of requires_action.
#
# You can't cancel refunds in other states. Only refunds for payment methods that require customer action can enter the requires_action state.
sig {
params(params: T.any(::Stripe::Refund::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Refund)
}
def cancel(params = {}, opts = {}); end
# Cancels a refund with a status of requires_action.
#
# You can't cancel refunds in other states. Only refunds for payment methods that require customer action can enter the requires_action state.
sig {
params(refund: String, params: T.any(::Stripe::Refund::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Refund)
}
def self.cancel(refund, params = {}, opts = {}); end
# When you create a new refund, you must specify a Charge or a PaymentIntent object on which to create it.
#
# Creating a new refund will refund a charge that has previously been created but not yet refunded.
# Funds will be refunded to the credit or debit card that was originally charged.
#
# You can optionally refund only part of a charge.
# You can do so multiple times, until the entire charge has been refunded.
#
# Once entirely refunded, a charge can't be refunded again.
# This method will raise an error when called on an already-refunded charge,
# or when trying to refund more money than is left on a charge.
sig {
params(params: T.any(::Stripe::Refund::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Refund)
}
def self.create(params = {}, opts = {}); end
# Returns a list of all refunds you created. We return the refunds in sorted order, with the most recent refunds appearing first. The 10 most recent refunds are always available by default on the Charge object.
sig {
params(params: T.any(::Stripe::Refund::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Updates the refund that you specify by setting the values of the passed parameters. Any parameters that you don't provide remain unchanged.
#
# This request only accepts metadata as an argument.
sig {
params(refund: String, params: T.any(::Stripe::Refund::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Refund)
}
def self.update(refund, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
module Reporting
# The Report Run object represents an instance of a report type generated with
# specific run parameters. Once the object is created, Stripe begins processing the report.
# When the report has finished running, it will give you a reference to a file
# where you can retrieve your results. For an overview, see
# [API Access to Reports](https://stripe.com/docs/reporting/statements/api).
#
# Note that certain report types can only be run based on your live-mode data (not test-mode
# data), and will error when queried without a [live-mode API key](https://stripe.com/docs/keys#test-live-modes).
class ReportRun < APIResource
class Parameters < Stripe::StripeObject
# The set of output columns requested for inclusion in the report run.
sig { returns(T::Array[String]) }
attr_reader :columns
# Connected account ID by which to filter the report run.
sig { returns(String) }
attr_reader :connected_account
# Currency of objects to be included in the report run.
sig { returns(String) }
attr_reader :currency
# Ending timestamp of data to be included in the report run. Can be any UTC timestamp between 1 second after the user specified `interval_start` and 1 second before this report's last `data_available_end` value.
sig { returns(Integer) }
attr_reader :interval_end
# Starting timestamp of data to be included in the report run. Can be any UTC timestamp between 1 second after this report's `data_available_start` and 1 second before the user specified `interval_end` value.
sig { returns(Integer) }
attr_reader :interval_start
# Payout ID by which to filter the report run.
sig { returns(String) }
attr_reader :payout
# Category of balance transactions to be included in the report run.
sig { returns(String) }
attr_reader :reporting_category
# Defaults to `Etc/UTC`. The output timezone for all timestamps in the report. A list of possible time zone values is maintained at the [IANA Time Zone Database](http://www.iana.org/time-zones). Has no effect on `interval_start` or `interval_end`.
sig { returns(String) }
attr_reader :timezone
end
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# If something should go wrong during the run, a message about the failure (populated when
# `status=failed`).
sig { returns(T.nilable(String)) }
attr_reader :error
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# `true` if the report is run on live mode data and `false` if it is run on test mode data.
sig { returns(T::Boolean) }
attr_reader :livemode
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Attribute for field parameters
sig { returns(Parameters) }
attr_reader :parameters
# The ID of the [report type](https://stripe.com/docs/reports/report-types) to run, such as `"balance.summary.1"`.
sig { returns(String) }
attr_reader :report_type
# The file object representing the result of the report run (populated when
# `status=succeeded`).
sig { returns(T.nilable(Stripe::File)) }
attr_reader :result
# Status of this report run. This will be `pending` when the run is initially created.
# When the run finishes, this will be set to `succeeded` and the `result` field will be populated.
# Rarely, we may encounter an error, at which point this will be set to `failed` and the `error` field will be populated.
sig { returns(String) }
attr_reader :status
# Timestamp at which this run successfully finished (populated when
# `status=succeeded`). Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_reader :succeeded_at
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return Report Runs that were created during the given date interval.
sig {
returns(T.nilable(T.any(::Stripe::Reporting::ReportRun::ListParams::Created, Integer)))
}
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(created: T.nilable(T.any(::Stripe::Reporting::ReportRun::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class Parameters < Stripe::RequestParams
# The set of report columns to include in the report output. If omitted, the Report Type is run with its default column set.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :columns
# Connected account ID to filter for in the report run.
sig { returns(T.nilable(String)) }
attr_accessor :connected_account
# Currency of objects to be included in the report run.
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Ending timestamp of data to be included in the report run (exclusive).
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_end
# Starting timestamp of data to be included in the report run.
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_start
# Payout ID by which to filter the report run.
sig { returns(T.nilable(String)) }
attr_accessor :payout
# Category of balance transactions to be included in the report run.
sig { returns(T.nilable(String)) }
attr_accessor :reporting_category
# Defaults to `Etc/UTC`. The output timezone for all timestamps in the report. A list of possible time zone values is maintained at the [IANA Time Zone Database](http://www.iana.org/time-zones). Has no effect on `interval_start` or `interval_end`.
sig { returns(T.nilable(String)) }
attr_accessor :timezone
sig {
params(columns: T.nilable(T::Array[String]), connected_account: T.nilable(String), currency: T.nilable(String), interval_end: T.nilable(Integer), interval_start: T.nilable(Integer), payout: T.nilable(String), reporting_category: T.nilable(String), timezone: T.nilable(String)).void
}
def initialize(
columns: nil,
connected_account: nil,
currency: nil,
interval_end: nil,
interval_start: nil,
payout: nil,
reporting_category: nil,
timezone: nil
); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Parameters specifying how the report should be run. Different Report Types have different required and optional parameters, listed in the [API Access to Reports](https://stripe.com/docs/reporting/statements/api) documentation.
sig { returns(T.nilable(::Stripe::Reporting::ReportRun::CreateParams::Parameters)) }
attr_accessor :parameters
# The ID of the [report type](https://stripe.com/docs/reporting/statements/api#report-types) to run, such as `"balance.summary.1"`.
sig { returns(String) }
attr_accessor :report_type
sig {
params(expand: T.nilable(T::Array[String]), parameters: T.nilable(::Stripe::Reporting::ReportRun::CreateParams::Parameters), report_type: String).void
}
def initialize(expand: nil, parameters: nil, report_type: nil); end
end
# Creates a new object and begin running the report. (Certain report types require a [live-mode API key](https://stripe.com/docs/keys#test-live-modes).)
sig {
params(params: T.any(::Stripe::Reporting::ReportRun::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Reporting::ReportRun)
}
def self.create(params = {}, opts = {}); end
# Returns a list of Report Runs, with the most recent appearing first.
sig {
params(params: T.any(::Stripe::Reporting::ReportRun::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Reporting
# The Report Type resource corresponds to a particular type of report, such as
# the "Activity summary" or "Itemized payouts" reports. These objects are
# identified by an ID belonging to a set of enumerated values. See
# [API Access to Reports documentation](https://stripe.com/docs/reporting/statements/api)
# for those Report Type IDs, along with required and optional parameters.
#
# Note that certain report types can only be run based on your live-mode data (not test-mode
# data), and will error when queried without a [live-mode API key](https://stripe.com/docs/keys#test-live-modes).
class ReportType < APIResource
# Most recent time for which this Report Type is available. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :data_available_end
# Earliest time for which this Report Type is available. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :data_available_start
# List of column names that are included by default when this Report Type gets run. (If the Report Type doesn't support the `columns` parameter, this will be null.)
sig { returns(T.nilable(T::Array[String])) }
attr_reader :default_columns
# The [ID of the Report Type](https://stripe.com/docs/reporting/statements/api#available-report-types), such as `balance.summary.1`.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# Human-readable name of the Report Type
sig { returns(String) }
attr_reader :name
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# When this Report Type was latest updated. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :updated
# Version of the Report Type. Different versions report with the same ID will have the same purpose, but may take different run parameters or have different result schemas.
sig { returns(Integer) }
attr_reader :version
class ListParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Returns a full list of Report Types.
sig {
params(params: T.any(::Stripe::Reporting::ReportType::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
class ReserveTransaction < APIResource
# Attribute for field amount
sig { returns(Integer) }
attr_reader :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).
sig { returns(String) }
attr_reader :currency
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_reader :description
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
end
end
# typed: true
module Stripe
# Reviews can be used to supplement automated fraud detection with human expertise.
#
# Learn more about [Radar](https://docs.stripe.com/radar) and reviewing payments
# [here](https://stripe.com/docs/radar/reviews).
class Review < APIResource
class IpAddressLocation < Stripe::StripeObject
# The city where the payment originated.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter ISO code representing the country where the payment originated.
sig { returns(T.nilable(String)) }
attr_reader :country
# The geographic latitude where the payment originated.
sig { returns(T.nilable(Float)) }
attr_reader :latitude
# The geographic longitude where the payment originated.
sig { returns(T.nilable(Float)) }
attr_reader :longitude
# The state/county/province/region where the payment originated.
sig { returns(T.nilable(String)) }
attr_reader :region
end
class Session < Stripe::StripeObject
# The browser used in this browser session (e.g., `Chrome`).
sig { returns(T.nilable(String)) }
attr_reader :browser
# Information about the device used for the browser session (e.g., `Samsung SM-G930T`).
sig { returns(T.nilable(String)) }
attr_reader :device
# The platform for the browser session (e.g., `Macintosh`).
sig { returns(T.nilable(String)) }
attr_reader :platform
# The version for the browser session (e.g., `61.0.3163.100`).
sig { returns(T.nilable(String)) }
attr_reader :version
end
# The ZIP or postal code of the card used, if applicable.
sig { returns(T.nilable(String)) }
attr_reader :billing_zip
# The charge associated with this review.
sig { returns(T.nilable(T.any(String, Stripe::Charge))) }
attr_reader :charge
# The reason the review was closed, or null if it has not yet been closed. One of `approved`, `refunded`, `refunded_as_fraud`, `disputed`, `redacted`, or `canceled`.
sig { returns(T.nilable(String)) }
attr_reader :closed_reason
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# The IP address where the payment originated.
sig { returns(T.nilable(String)) }
attr_reader :ip_address
# Information related to the location of the payment. Note that this information is an approximation and attempts to locate the nearest population center - it should not be used to determine a specific address.
sig { returns(T.nilable(IpAddressLocation)) }
attr_reader :ip_address_location
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# If `true`, the review needs action.
sig { returns(T::Boolean) }
attr_reader :open
# The reason the review was opened. One of `rule` or `manual`.
sig { returns(String) }
attr_reader :opened_reason
# The PaymentIntent ID associated with this review, if one exists.
sig { returns(T.any(String, Stripe::PaymentIntent)) }
attr_reader :payment_intent
# The reason the review is currently open or closed. One of `rule`, `manual`, `approved`, `refunded`, `refunded_as_fraud`, `disputed`, `redacted`, or `canceled`.
sig { returns(String) }
attr_reader :reason
# Information related to the browsing session of the user who initiated the payment.
sig { returns(T.nilable(Session)) }
attr_reader :session
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return reviews that were created during the given date interval.
sig { returns(T.nilable(T.any(::Stripe::Review::ListParams::Created, Integer))) }
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(created: T.nilable(T.any(::Stripe::Review::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil
); end
end
class ApproveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Approves a Review object, closing it and removing it from the list of reviews.
sig {
params(params: T.any(::Stripe::Review::ApproveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Review)
}
def approve(params = {}, opts = {}); end
# Approves a Review object, closing it and removing it from the list of reviews.
sig {
params(review: String, params: T.any(::Stripe::Review::ApproveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Review)
}
def self.approve(review, params = {}, opts = {}); end
# Returns a list of Review objects that have open set to true. The objects are sorted in descending order by creation date, with the most recently created object appearing first.
sig {
params(params: T.any(::Stripe::Review::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
end
end
# typed: true
module Stripe
module Sigma
# If you have [scheduled a Sigma query](https://stripe.com/docs/sigma/scheduled-queries), you'll
# receive a `sigma.scheduled_query_run.created` webhook each time the query
# runs. The webhook contains a `ScheduledQueryRun` object, which you can use to
# retrieve the query results.
class ScheduledQueryRun < APIResource
class Error < Stripe::StripeObject
# Information about the run failure.
sig { returns(String) }
attr_reader :message
end
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# When the query was run, Sigma contained a snapshot of your Stripe data at this time.
sig { returns(Integer) }
attr_reader :data_load_time
# Attribute for field error
sig { returns(Error) }
attr_reader :error
# The file object representing the results of the query.
sig { returns(T.nilable(Stripe::File)) }
attr_reader :file
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Time at which the result expires and is no longer available for download.
sig { returns(Integer) }
attr_reader :result_available_until
# SQL for the query.
sig { returns(String) }
attr_reader :sql
# The query's execution status, which will be `completed` for successful runs, and `canceled`, `failed`, or `timed_out` otherwise.
sig { returns(String) }
attr_reader :status
# Title of the query.
sig { returns(String) }
attr_reader :title
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
# Returns a list of scheduled query runs.
sig {
params(params: T.any(::Stripe::Sigma::ScheduledQueryRun::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
# A SetupAttempt describes one attempted confirmation of a SetupIntent,
# whether that confirmation is successful or unsuccessful. You can use
# SetupAttempts to inspect details of a specific attempt at setting up a
# payment method using a SetupIntent.
class SetupAttempt < APIResource
class PaymentMethodDetails < Stripe::StripeObject
class AcssDebit < Stripe::StripeObject; end
class AmazonPay < Stripe::StripeObject; end
class AuBecsDebit < Stripe::StripeObject; end
class BacsDebit < Stripe::StripeObject; end
class Bancontact < Stripe::StripeObject
# Bank code of bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_code
# Name of the bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# Bank Identifier Code of the bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bic
# The ID of the SEPA Direct Debit PaymentMethod which was generated by this SetupAttempt.
sig { returns(T.nilable(T.any(String, Stripe::PaymentMethod))) }
attr_reader :generated_sepa_debit
# The mandate for the SEPA Direct Debit PaymentMethod which was generated by this SetupAttempt.
sig { returns(T.nilable(T.any(String, Stripe::Mandate))) }
attr_reader :generated_sepa_debit_mandate
# Last four characters of the IBAN.
sig { returns(T.nilable(String)) }
attr_reader :iban_last4
# Preferred language of the Bancontact authorization page that the customer is redirected to.
# Can be one of `en`, `de`, `fr`, or `nl`
sig { returns(T.nilable(String)) }
attr_reader :preferred_language
# Owner's verified full name. Values are verified or provided by Bancontact directly
# (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(String)) }
attr_reader :verified_name
end
class Boleto < Stripe::StripeObject; end
class Card < Stripe::StripeObject
class Checks < Stripe::StripeObject
# If a address line1 was provided, results of the check, one of `pass`, `fail`, `unavailable`, or `unchecked`.
sig { returns(T.nilable(String)) }
attr_reader :address_line1_check
# If a address postal code was provided, results of the check, one of `pass`, `fail`, `unavailable`, or `unchecked`.
sig { returns(T.nilable(String)) }
attr_reader :address_postal_code_check
# If a CVC was provided, results of the check, one of `pass`, `fail`, `unavailable`, or `unchecked`.
sig { returns(T.nilable(String)) }
attr_reader :cvc_check
end
class ThreeDSecure < Stripe::StripeObject
# For authenticated transactions: how the customer was authenticated by
# the issuing bank.
sig { returns(T.nilable(String)) }
attr_reader :authentication_flow
# The Electronic Commerce Indicator (ECI). A protocol-level field
# indicating what degree of authentication was performed.
sig { returns(T.nilable(String)) }
attr_reader :electronic_commerce_indicator
# Indicates the outcome of 3D Secure authentication.
sig { returns(T.nilable(String)) }
attr_reader :result
# Additional information about why 3D Secure succeeded or failed based
# on the `result`.
sig { returns(T.nilable(String)) }
attr_reader :result_reason
# The 3D Secure 1 XID or 3D Secure 2 Directory Server Transaction ID
# (dsTransId) for this payment.
sig { returns(T.nilable(String)) }
attr_reader :transaction_id
# The version of 3D Secure that was used.
sig { returns(T.nilable(String)) }
attr_reader :version
end
class Wallet < Stripe::StripeObject
class ApplePay < Stripe::StripeObject; end
class GooglePay < Stripe::StripeObject; end
# Attribute for field apple_pay
sig { returns(ApplePay) }
attr_reader :apple_pay
# Attribute for field google_pay
sig { returns(GooglePay) }
attr_reader :google_pay
# The type of the card wallet, one of `apple_pay`, `google_pay`, or `link`. An additional hash is included on the Wallet subhash with a name matching this value. It contains additional information specific to the card wallet type.
sig { returns(String) }
attr_reader :type
end
# Card brand. Can be `amex`, `diners`, `discover`, `eftpos_au`, `jcb`, `link`, `mastercard`, `unionpay`, `visa`, or `unknown`.
sig { returns(T.nilable(String)) }
attr_reader :brand
# Check results by Card networks on Card address and CVC at the time of authorization
sig { returns(T.nilable(Checks)) }
attr_reader :checks
# 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.
sig { returns(T.nilable(String)) }
attr_reader :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.)
sig { returns(T.nilable(String)) }
attr_reader :description
# Two-digit number representing the card's expiration month.
sig { returns(T.nilable(Integer)) }
attr_reader :exp_month
# Four-digit number representing the card's expiration year.
sig { returns(T.nilable(Integer)) }
attr_reader :exp_year
# Uniquely identifies this particular card number. You can use this attribute to check whether two customers who’ve signed up with you are using the same card number, for example. For payment methods that tokenize card information (Apple Pay, Google Pay), the tokenized number might be provided instead of the underlying card number.
#
# *As of May 1, 2021, card fingerprint in India for Connect changed to allow two fingerprints for the same card---one for India and one for the rest of the world.*
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Card funding type. Can be `credit`, `debit`, `prepaid`, or `unknown`.
sig { returns(T.nilable(String)) }
attr_reader :funding
# Issuer identification number of the card. (For internal use only and not typically available in standard API requests.)
sig { returns(T.nilable(String)) }
attr_reader :iin
# The name of the card's issuing bank. (For internal use only and not typically available in standard API requests.)
sig { returns(T.nilable(String)) }
attr_reader :issuer
# The last four digits of the card.
sig { returns(T.nilable(String)) }
attr_reader :last4
# Identifies which network this charge was processed on. Can be `amex`, `cartes_bancaires`, `diners`, `discover`, `eftpos_au`, `interac`, `jcb`, `link`, `mastercard`, `unionpay`, `visa`, or `unknown`.
sig { returns(T.nilable(String)) }
attr_reader :network
# Populated if this authorization used 3D Secure authentication.
sig { returns(T.nilable(ThreeDSecure)) }
attr_reader :three_d_secure
# If this Card is part of a card wallet, this contains the details of the card wallet.
sig { returns(T.nilable(Wallet)) }
attr_reader :wallet
end
class CardPresent < Stripe::StripeObject
class Offline < Stripe::StripeObject
# Time at which the payment was collected while offline
sig { returns(T.nilable(Integer)) }
attr_reader :stored_at
# The method used to process this payment method offline. Only deferred is allowed.
sig { returns(T.nilable(String)) }
attr_reader :type
end
# The ID of the Card PaymentMethod which was generated by this SetupAttempt.
sig { returns(T.nilable(T.any(String, Stripe::PaymentMethod))) }
attr_reader :generated_card
# Details about payments collected offline.
sig { returns(T.nilable(Offline)) }
attr_reader :offline
end
class Cashapp < Stripe::StripeObject; end
class IdBankTransfer < Stripe::StripeObject
# Bank where the account is located.
sig { returns(T.nilable(String)) }
attr_reader :bank
# Local bank code of the bank.
sig { returns(T.nilable(String)) }
attr_reader :bank_code
# Name of the bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# Merchant name and billing details name, for the customer to check for the correct merchant when performing the bank transfer.
sig { returns(T.nilable(String)) }
attr_reader :display_name
end
class Ideal < Stripe::StripeObject
# The customer's bank. Can be one of `abn_amro`, `asn_bank`, `bunq`, `handelsbanken`, `ing`, `knab`, `moneyou`, `n26`, `nn`, `rabobank`, `regiobank`, `revolut`, `sns_bank`, `triodos_bank`, `van_lanschot`, or `yoursafe`.
sig { returns(T.nilable(String)) }
attr_reader :bank
# The Bank Identifier Code of the customer's bank.
sig { returns(T.nilable(String)) }
attr_reader :bic
# The ID of the SEPA Direct Debit PaymentMethod which was generated by this SetupAttempt.
sig { returns(T.nilable(T.any(String, Stripe::PaymentMethod))) }
attr_reader :generated_sepa_debit
# The mandate for the SEPA Direct Debit PaymentMethod which was generated by this SetupAttempt.
sig { returns(T.nilable(T.any(String, Stripe::Mandate))) }
attr_reader :generated_sepa_debit_mandate
# Last four characters of the IBAN.
sig { returns(T.nilable(String)) }
attr_reader :iban_last4
# Owner's verified full name. Values are verified or provided by iDEAL directly
# (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(String)) }
attr_reader :verified_name
end
class KakaoPay < Stripe::StripeObject; end
class Klarna < Stripe::StripeObject; end
class KrCard < Stripe::StripeObject; end
class Link < Stripe::StripeObject; end
class NaverPay < Stripe::StripeObject
# Uniquely identifies this particular Naver Pay account. You can use this attribute to check whether two Naver Pay accounts are the same.
sig { returns(String) }
attr_reader :buyer_id
end
class NzBankAccount < Stripe::StripeObject; end
class Paypal < Stripe::StripeObject; end
class Payto < Stripe::StripeObject; end
class RevolutPay < Stripe::StripeObject; end
class SepaDebit < Stripe::StripeObject; end
class Sofort < Stripe::StripeObject
# Bank code of bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_code
# Name of the bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# Bank Identifier Code of the bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bic
# The ID of the SEPA Direct Debit PaymentMethod which was generated by this SetupAttempt.
sig { returns(T.nilable(T.any(String, Stripe::PaymentMethod))) }
attr_reader :generated_sepa_debit
# The mandate for the SEPA Direct Debit PaymentMethod which was generated by this SetupAttempt.
sig { returns(T.nilable(T.any(String, Stripe::Mandate))) }
attr_reader :generated_sepa_debit_mandate
# Last four characters of the IBAN.
sig { returns(T.nilable(String)) }
attr_reader :iban_last4
# Preferred language of the Sofort authorization page that the customer is redirected to.
# Can be one of `en`, `de`, `fr`, or `nl`
sig { returns(T.nilable(String)) }
attr_reader :preferred_language
# Owner's verified full name. Values are verified or provided by Sofort directly
# (if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(String)) }
attr_reader :verified_name
end
class StripeBalance < Stripe::StripeObject; end
class UsBankAccount < Stripe::StripeObject; end
# Attribute for field acss_debit
sig { returns(AcssDebit) }
attr_reader :acss_debit
# Attribute for field amazon_pay
sig { returns(AmazonPay) }
attr_reader :amazon_pay
# Attribute for field au_becs_debit
sig { returns(AuBecsDebit) }
attr_reader :au_becs_debit
# Attribute for field bacs_debit
sig { returns(BacsDebit) }
attr_reader :bacs_debit
# Attribute for field bancontact
sig { returns(Bancontact) }
attr_reader :bancontact
# Attribute for field boleto
sig { returns(Boleto) }
attr_reader :boleto
# Attribute for field card
sig { returns(Card) }
attr_reader :card
# Attribute for field card_present
sig { returns(CardPresent) }
attr_reader :card_present
# Attribute for field cashapp
sig { returns(Cashapp) }
attr_reader :cashapp
# Attribute for field id_bank_transfer
sig { returns(IdBankTransfer) }
attr_reader :id_bank_transfer
# Attribute for field ideal
sig { returns(Ideal) }
attr_reader :ideal
# Attribute for field kakao_pay
sig { returns(KakaoPay) }
attr_reader :kakao_pay
# Attribute for field klarna
sig { returns(Klarna) }
attr_reader :klarna
# Attribute for field kr_card
sig { returns(KrCard) }
attr_reader :kr_card
# Attribute for field link
sig { returns(Link) }
attr_reader :link
# Attribute for field naver_pay
sig { returns(NaverPay) }
attr_reader :naver_pay
# Attribute for field nz_bank_account
sig { returns(NzBankAccount) }
attr_reader :nz_bank_account
# Attribute for field paypal
sig { returns(Paypal) }
attr_reader :paypal
# Attribute for field payto
sig { returns(Payto) }
attr_reader :payto
# Attribute for field revolut_pay
sig { returns(RevolutPay) }
attr_reader :revolut_pay
# Attribute for field sepa_debit
sig { returns(SepaDebit) }
attr_reader :sepa_debit
# Attribute for field sofort
sig { returns(Sofort) }
attr_reader :sofort
# Attribute for field stripe_balance
sig { returns(StripeBalance) }
attr_reader :stripe_balance
# The type of the payment method used in the SetupIntent (e.g., `card`). An additional hash is included on `payment_method_details` with a name matching this value. It contains confirmation-specific information for the payment method.
sig { returns(String) }
attr_reader :type
# Attribute for field us_bank_account
sig { returns(UsBankAccount) }
attr_reader :us_bank_account
end
class SetupError < Stripe::StripeObject
# For card errors resulting from a card issuer decline, a short string indicating [how to proceed with an error](https://stripe.com/docs/declines#retrying-issuer-declines) if they provide one.
sig { returns(String) }
attr_reader :advice_code
# For card errors, the ID of the failed charge.
sig { returns(String) }
attr_reader :charge
# For some errors that could be handled programmatically, a short string indicating the [error code](https://stripe.com/docs/error-codes) reported.
sig { returns(String) }
attr_reader :code
# For card errors resulting from a card issuer decline, a short string indicating the [card issuer's reason for the decline](https://stripe.com/docs/declines#issuer-declines) if they provide one.
sig { returns(String) }
attr_reader :decline_code
# A URL to more information about the [error code](https://stripe.com/docs/error-codes) reported.
sig { returns(String) }
attr_reader :doc_url
# A human-readable message providing more details about the error. For card errors, these messages can be shown to your users.
sig { returns(String) }
attr_reader :message
# For card errors resulting from a card issuer decline, a 2 digit code which indicates the advice given to merchant by the card network on how to proceed with an error.
sig { returns(String) }
attr_reader :network_advice_code
# For card errors resulting from a card issuer decline, a brand specific 2, 3, or 4 digit code which indicates the reason the authorization failed.
sig { returns(String) }
attr_reader :network_decline_code
# If the error is parameter-specific, the parameter related to the error. For example, you can use this to display a message near the correct form field.
sig { returns(String) }
attr_reader :param
# A PaymentIntent guides you through the process of collecting a payment from your customer.
# We recommend that you create exactly one PaymentIntent for each order or
# customer session in your system. You can reference the PaymentIntent later to
# see the history of payment attempts for a particular session.
#
# A PaymentIntent transitions through
# [multiple statuses](https://stripe.com/docs/payments/intents#intent-statuses)
# throughout its lifetime as it interfaces with Stripe.js to perform
# authentication flows and ultimately creates at most one successful charge.
#
# Related guide: [Payment Intents API](https://stripe.com/docs/payments/payment-intents)
sig { returns(Stripe::PaymentIntent) }
attr_reader :payment_intent
# PaymentMethod objects represent your customer's payment instruments.
# You can use them with [PaymentIntents](https://stripe.com/docs/payments/payment-intents) to collect payments or save them to
# Customer objects to store instrument details for future payments.
#
# Related guides: [Payment Methods](https://stripe.com/docs/payments/payment-methods) and [More Payment Scenarios](https://stripe.com/docs/payments/more-payment-scenarios).
sig { returns(Stripe::PaymentMethod) }
attr_reader :payment_method
# If the error is specific to the type of payment method, the payment method type that had a problem. This field is only populated for invoice-related errors.
sig { returns(String) }
attr_reader :payment_method_type
# A URL to the request log entry in your dashboard.
sig { returns(String) }
attr_reader :request_log_url
# A SetupIntent guides you through the process of setting up and saving a customer's payment credentials for future payments.
# For example, you can use a SetupIntent to set up and save your customer's card without immediately collecting a payment.
# Later, you can use [PaymentIntents](https://stripe.com/docs/api#payment_intents) to drive the payment flow.
#
# Create a SetupIntent when you're ready to collect your customer's payment credentials.
# Don't maintain long-lived, unconfirmed SetupIntents because they might not be valid.
# The SetupIntent transitions through multiple [statuses](https://docs.stripe.com/payments/intents#intent-statuses) as it guides
# you through the setup process.
#
# Successful SetupIntents result in payment credentials that are optimized for future payments.
# For example, cardholders in [certain regions](https://stripe.com/guides/strong-customer-authentication) might need to be run through
# [Strong Customer Authentication](https://docs.stripe.com/strong-customer-authentication) during payment method collection
# to streamline later [off-session payments](https://docs.stripe.com/payments/setup-intents).
# If you use the SetupIntent with a [Customer](https://stripe.com/docs/api#setup_intent_object-customer),
# it automatically attaches the resulting payment method to that Customer after successful setup.
# We recommend using SetupIntents or [setup_future_usage](https://stripe.com/docs/api#payment_intent_object-setup_future_usage) on
# PaymentIntents to save payment methods to prevent saving invalid or unoptimized payment methods.
#
# By using SetupIntents, you can reduce friction for your customers, even as regulations change over time.
#
# Related guide: [Setup Intents API](https://docs.stripe.com/payments/setup-intents)
sig { returns(Stripe::SetupIntent) }
attr_reader :setup_intent
# Attribute for field source
sig { returns(T.any(Stripe::Account, Stripe::BankAccount, Stripe::Card, Stripe::Source)) }
attr_reader :source
# The type of error returned. One of `api_error`, `card_error`, `idempotency_error`, or `invalid_request_error`
sig { returns(String) }
attr_reader :type
end
# The value of [application](https://stripe.com/docs/api/setup_intents/object#setup_intent_object-application) on the SetupIntent at the time of this confirmation.
sig { returns(T.nilable(T.any(String, Stripe::Application))) }
attr_reader :application
# If present, the SetupIntent's payment method will be attached to the in-context Stripe Account.
#
# It can only be used for this Stripe Account’s own money movement flows like InboundTransfer and OutboundTransfers. It cannot be set to true when setting up a PaymentMethod for a Customer, and defaults to false when attaching a PaymentMethod to a Customer.
sig { returns(T::Boolean) }
attr_reader :attach_to_self
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# The value of [customer](https://stripe.com/docs/api/setup_intents/object#setup_intent_object-customer) on the SetupIntent at the time of this confirmation.
sig { returns(T.nilable(T.any(String, Stripe::Customer))) }
attr_reader :customer
# The value of [customer_account](https://stripe.com/docs/api/setup_intents/object#setup_intent_object-customer_account) on the SetupIntent at the time of this confirmation.
sig { returns(T.nilable(String)) }
attr_reader :customer_account
# Indicates the directions of money movement for which this payment method is intended to be used.
#
# Include `inbound` if you intend to use the payment method as the origin to pull funds from. Include `outbound` if you intend to use the payment method as the destination to send funds to. You can include both if you intend to use the payment method for both purposes.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :flow_directions
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The value of [on_behalf_of](https://stripe.com/docs/api/setup_intents/object#setup_intent_object-on_behalf_of) on the SetupIntent at the time of this confirmation.
sig { returns(T.nilable(T.any(String, Stripe::Account))) }
attr_reader :on_behalf_of
# ID of the payment method used with this SetupAttempt.
sig { returns(T.any(String, Stripe::PaymentMethod)) }
attr_reader :payment_method
# Attribute for field payment_method_details
sig { returns(PaymentMethodDetails) }
attr_reader :payment_method_details
# The error encountered during this attempt to confirm the SetupIntent, if any.
sig { returns(T.nilable(SetupError)) }
attr_reader :setup_error
# ID of the SetupIntent that this attempt belongs to.
sig { returns(T.any(String, Stripe::SetupIntent)) }
attr_reader :setup_intent
# Status of this SetupAttempt, one of `requires_confirmation`, `requires_action`, `processing`, `succeeded`, `failed`, or `abandoned`.
sig { returns(String) }
attr_reader :status
# The value of [usage](https://stripe.com/docs/api/setup_intents/object#setup_intent_object-usage) on the SetupIntent at the time of this confirmation, one of `off_session` or `on_session`.
sig { returns(String) }
attr_reader :usage
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# A filter on the list, based on the object `created` field. The value
# can be a string with an integer Unix timestamp or a
# dictionary with a number of different query options.
sig { returns(T.nilable(T.any(::Stripe::SetupAttempt::ListParams::Created, Integer))) }
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Only return SetupAttempts created by the SetupIntent specified by
# this ID.
sig { returns(String) }
attr_accessor :setup_intent
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(created: T.nilable(T.any(::Stripe::SetupAttempt::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), setup_intent: String, starting_after: T.nilable(String)).void
}
def initialize(
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
setup_intent: nil,
starting_after: nil
); end
end
# Returns a list of SetupAttempts that associate with a provided SetupIntent.
sig {
params(params: T.any(::Stripe::SetupAttempt::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
end
end
# typed: true
module Stripe
# A SetupIntent guides you through the process of setting up and saving a customer's payment credentials for future payments.
# For example, you can use a SetupIntent to set up and save your customer's card without immediately collecting a payment.
# Later, you can use [PaymentIntents](https://stripe.com/docs/api#payment_intents) to drive the payment flow.
#
# Create a SetupIntent when you're ready to collect your customer's payment credentials.
# Don't maintain long-lived, unconfirmed SetupIntents because they might not be valid.
# The SetupIntent transitions through multiple [statuses](https://docs.stripe.com/payments/intents#intent-statuses) as it guides
# you through the setup process.
#
# Successful SetupIntents result in payment credentials that are optimized for future payments.
# For example, cardholders in [certain regions](https://stripe.com/guides/strong-customer-authentication) might need to be run through
# [Strong Customer Authentication](https://docs.stripe.com/strong-customer-authentication) during payment method collection
# to streamline later [off-session payments](https://docs.stripe.com/payments/setup-intents).
# If you use the SetupIntent with a [Customer](https://stripe.com/docs/api#setup_intent_object-customer),
# it automatically attaches the resulting payment method to that Customer after successful setup.
# We recommend using SetupIntents or [setup_future_usage](https://stripe.com/docs/api#payment_intent_object-setup_future_usage) on
# PaymentIntents to save payment methods to prevent saving invalid or unoptimized payment methods.
#
# By using SetupIntents, you can reduce friction for your customers, even as regulations change over time.
#
# Related guide: [Setup Intents API](https://docs.stripe.com/payments/setup-intents)
class SetupIntent < APIResource
class AutomaticPaymentMethods < Stripe::StripeObject
# Controls whether this SetupIntent will accept redirect-based payment methods.
#
# Redirect-based payment methods may require your customer to be redirected to a payment method's app or site for authentication or additional steps. To [confirm](https://stripe.com/docs/api/setup_intents/confirm) this SetupIntent, you may be required to provide a `return_url` to redirect customers back to your site after they authenticate or complete the setup.
sig { returns(String) }
attr_reader :allow_redirects
# Automatically calculates compatible payment methods
sig { returns(T.nilable(T::Boolean)) }
attr_reader :enabled
end
class LastSetupError < Stripe::StripeObject
# For card errors resulting from a card issuer decline, a short string indicating [how to proceed with an error](https://stripe.com/docs/declines#retrying-issuer-declines) if they provide one.
sig { returns(String) }
attr_reader :advice_code
# For card errors, the ID of the failed charge.
sig { returns(String) }
attr_reader :charge
# For some errors that could be handled programmatically, a short string indicating the [error code](https://stripe.com/docs/error-codes) reported.
sig { returns(String) }
attr_reader :code
# For card errors resulting from a card issuer decline, a short string indicating the [card issuer's reason for the decline](https://stripe.com/docs/declines#issuer-declines) if they provide one.
sig { returns(String) }
attr_reader :decline_code
# A URL to more information about the [error code](https://stripe.com/docs/error-codes) reported.
sig { returns(String) }
attr_reader :doc_url
# A human-readable message providing more details about the error. For card errors, these messages can be shown to your users.
sig { returns(String) }
attr_reader :message
# For card errors resulting from a card issuer decline, a 2 digit code which indicates the advice given to merchant by the card network on how to proceed with an error.
sig { returns(String) }
attr_reader :network_advice_code
# For card errors resulting from a card issuer decline, a brand specific 2, 3, or 4 digit code which indicates the reason the authorization failed.
sig { returns(String) }
attr_reader :network_decline_code
# If the error is parameter-specific, the parameter related to the error. For example, you can use this to display a message near the correct form field.
sig { returns(String) }
attr_reader :param
# A PaymentIntent guides you through the process of collecting a payment from your customer.
# We recommend that you create exactly one PaymentIntent for each order or
# customer session in your system. You can reference the PaymentIntent later to
# see the history of payment attempts for a particular session.
#
# A PaymentIntent transitions through
# [multiple statuses](https://stripe.com/docs/payments/intents#intent-statuses)
# throughout its lifetime as it interfaces with Stripe.js to perform
# authentication flows and ultimately creates at most one successful charge.
#
# Related guide: [Payment Intents API](https://stripe.com/docs/payments/payment-intents)
sig { returns(Stripe::PaymentIntent) }
attr_reader :payment_intent
# PaymentMethod objects represent your customer's payment instruments.
# You can use them with [PaymentIntents](https://stripe.com/docs/payments/payment-intents) to collect payments or save them to
# Customer objects to store instrument details for future payments.
#
# Related guides: [Payment Methods](https://stripe.com/docs/payments/payment-methods) and [More Payment Scenarios](https://stripe.com/docs/payments/more-payment-scenarios).
sig { returns(Stripe::PaymentMethod) }
attr_reader :payment_method
# If the error is specific to the type of payment method, the payment method type that had a problem. This field is only populated for invoice-related errors.
sig { returns(String) }
attr_reader :payment_method_type
# A URL to the request log entry in your dashboard.
sig { returns(String) }
attr_reader :request_log_url
# A SetupIntent guides you through the process of setting up and saving a customer's payment credentials for future payments.
# For example, you can use a SetupIntent to set up and save your customer's card without immediately collecting a payment.
# Later, you can use [PaymentIntents](https://stripe.com/docs/api#payment_intents) to drive the payment flow.
#
# Create a SetupIntent when you're ready to collect your customer's payment credentials.
# Don't maintain long-lived, unconfirmed SetupIntents because they might not be valid.
# The SetupIntent transitions through multiple [statuses](https://docs.stripe.com/payments/intents#intent-statuses) as it guides
# you through the setup process.
#
# Successful SetupIntents result in payment credentials that are optimized for future payments.
# For example, cardholders in [certain regions](https://stripe.com/guides/strong-customer-authentication) might need to be run through
# [Strong Customer Authentication](https://docs.stripe.com/strong-customer-authentication) during payment method collection
# to streamline later [off-session payments](https://docs.stripe.com/payments/setup-intents).
# If you use the SetupIntent with a [Customer](https://stripe.com/docs/api#setup_intent_object-customer),
# it automatically attaches the resulting payment method to that Customer after successful setup.
# We recommend using SetupIntents or [setup_future_usage](https://stripe.com/docs/api#payment_intent_object-setup_future_usage) on
# PaymentIntents to save payment methods to prevent saving invalid or unoptimized payment methods.
#
# By using SetupIntents, you can reduce friction for your customers, even as regulations change over time.
#
# Related guide: [Setup Intents API](https://docs.stripe.com/payments/setup-intents)
sig { returns(Stripe::SetupIntent) }
attr_reader :setup_intent
# Attribute for field source
sig { returns(T.any(Stripe::Account, Stripe::BankAccount, Stripe::Card, Stripe::Source)) }
attr_reader :source
# The type of error returned. One of `api_error`, `card_error`, `idempotency_error`, or `invalid_request_error`
sig { returns(String) }
attr_reader :type
end
class NextAction < Stripe::StripeObject
class CashappHandleRedirectOrDisplayQrCode < Stripe::StripeObject
class QrCode < Stripe::StripeObject
# The date (unix timestamp) when the QR code expires.
sig { returns(Integer) }
attr_reader :expires_at
# The image_url_png string used to render QR code
sig { returns(String) }
attr_reader :image_url_png
# The image_url_svg string used to render QR code
sig { returns(String) }
attr_reader :image_url_svg
end
# The URL to the hosted Cash App Pay instructions page, which allows customers to view the QR code, and supports QR code refreshing on expiration.
sig { returns(String) }
attr_reader :hosted_instructions_url
# The url for mobile redirect based auth
sig { returns(String) }
attr_reader :mobile_auth_url
# Attribute for field qr_code
sig { returns(QrCode) }
attr_reader :qr_code
end
class RedirectToUrl < Stripe::StripeObject
# If the customer does not exit their browser while authenticating, they will be redirected to this specified URL after completion.
sig { returns(T.nilable(String)) }
attr_reader :return_url
# The URL you must redirect your customer to in order to authenticate.
sig { returns(T.nilable(String)) }
attr_reader :url
end
class VerifyWithMicrodeposits < Stripe::StripeObject
# The timestamp when the microdeposits are expected to land.
sig { returns(Integer) }
attr_reader :arrival_date
# The URL for the hosted verification page, which allows customers to verify their bank account.
sig { returns(String) }
attr_reader :hosted_verification_url
# The type of the microdeposit sent to the customer. Used to distinguish between different verification methods.
sig { returns(T.nilable(String)) }
attr_reader :microdeposit_type
end
# Attribute for field cashapp_handle_redirect_or_display_qr_code
sig { returns(CashappHandleRedirectOrDisplayQrCode) }
attr_reader :cashapp_handle_redirect_or_display_qr_code
# Attribute for field redirect_to_url
sig { returns(RedirectToUrl) }
attr_reader :redirect_to_url
# Type of the next action to perform. Refer to the other child attributes under `next_action` for available values. Examples include: `redirect_to_url`, `use_stripe_sdk`, `alipay_handle_redirect`, `oxxo_display_details`, or `verify_with_microdeposits`.
sig { returns(String) }
attr_reader :type
# When confirming a SetupIntent with Stripe.js, Stripe.js depends on the contents of this dictionary to invoke authentication flows. The shape of the contents is subject to change and is only intended to be used by Stripe.js.
sig { returns(T::Hash[String, T.untyped]) }
attr_reader :use_stripe_sdk
# Attribute for field verify_with_microdeposits
sig { returns(VerifyWithMicrodeposits) }
attr_reader :verify_with_microdeposits
end
class PaymentMethodConfigurationDetails < Stripe::StripeObject
# ID of the payment method configuration used.
sig { returns(String) }
attr_reader :id
# ID of the parent payment method configuration used.
sig { returns(T.nilable(String)) }
attr_reader :parent
end
class PaymentMethodOptions < Stripe::StripeObject
class AcssDebit < Stripe::StripeObject
class MandateOptions < Stripe::StripeObject
# A URL for custom mandate text
sig { returns(String) }
attr_reader :custom_mandate_url
# List of Stripe products where this mandate can be selected automatically.
sig { returns(T::Array[String]) }
attr_reader :default_for
# Description of the interval. Only required if the 'payment_schedule' parameter is 'interval' or 'combined'.
sig { returns(T.nilable(String)) }
attr_reader :interval_description
# Payment schedule for the mandate.
sig { returns(T.nilable(String)) }
attr_reader :payment_schedule
# Transaction type of the mandate.
sig { returns(T.nilable(String)) }
attr_reader :transaction_type
end
# Currency supported by the bank account
sig { returns(T.nilable(String)) }
attr_reader :currency
# Attribute for field mandate_options
sig { returns(MandateOptions) }
attr_reader :mandate_options
# Bank account verification method.
sig { returns(String) }
attr_reader :verification_method
end
class AmazonPay < Stripe::StripeObject; end
class BacsDebit < Stripe::StripeObject
class MandateOptions < Stripe::StripeObject
# Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'DDIC' or 'STRIPE'.
sig { returns(String) }
attr_reader :reference_prefix
end
# Attribute for field mandate_options
sig { returns(MandateOptions) }
attr_reader :mandate_options
end
class Card < Stripe::StripeObject
class MandateOptions < Stripe::StripeObject
# Amount to be charged for future payments.
sig { returns(Integer) }
attr_reader :amount
# One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.
sig { returns(String) }
attr_reader :amount_type
# 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).
sig { returns(String) }
attr_reader :currency
# A description of the mandate or subscription that is meant to be displayed to the customer.
sig { returns(T.nilable(String)) }
attr_reader :description
# End date of the mandate or subscription. If not provided, the mandate will be active until canceled. If provided, end date should be after start date.
sig { returns(T.nilable(Integer)) }
attr_reader :end_date
# Specifies payment frequency. One of `day`, `week`, `month`, `year`, or `sporadic`.
sig { returns(String) }
attr_reader :interval
# The number of intervals between payments. For example, `interval=month` and `interval_count=3` indicates one payment every three months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks). This parameter is optional when `interval=sporadic`.
sig { returns(T.nilable(Integer)) }
attr_reader :interval_count
# Unique identifier for the mandate or subscription.
sig { returns(String) }
attr_reader :reference
# Start date of the mandate or subscription. Start date should not be lesser than yesterday.
sig { returns(Integer) }
attr_reader :start_date
# Specifies the type of mandates supported. Possible values are `india`.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :supported_types
end
# Configuration options for setting up an eMandate for cards issued in India.
sig { returns(T.nilable(MandateOptions)) }
attr_reader :mandate_options
# Selected network to process this SetupIntent on. Depends on the available networks of the card attached to the setup intent. Can be only set confirm-time.
sig { returns(T.nilable(String)) }
attr_reader :network
# We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. If not provided, this value defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
sig { returns(T.nilable(String)) }
attr_reader :request_three_d_secure
end
class CardPresent < Stripe::StripeObject; end
class Link < Stripe::StripeObject
# [Deprecated] This is a legacy parameter that no longer has any function.
sig { returns(T.nilable(String)) }
attr_reader :persistent_token
end
class Paypal < Stripe::StripeObject
# The PayPal Billing Agreement ID (BAID). This is an ID generated by PayPal which represents the mandate between the merchant and the customer.
sig { returns(T.nilable(String)) }
attr_reader :billing_agreement_id
# 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).
sig { returns(T.nilable(String)) }
attr_reader :currency
# The Stripe connected account IDs of the sellers on the platform for this transaction (optional). Only allowed when [separate charges and transfers](https://stripe.com/docs/connect/separate-charges-and-transfers) are used.
sig { returns(T::Array[String]) }
attr_reader :subsellers
end
class Payto < Stripe::StripeObject
class MandateOptions < Stripe::StripeObject
# Amount that will be collected. It is required when `amount_type` is `fixed`.
sig { returns(T.nilable(Integer)) }
attr_reader :amount
# The type of amount that will be collected. The amount charged must be exact or up to the value of `amount` param for `fixed` or `maximum` type respectively.
sig { returns(T.nilable(String)) }
attr_reader :amount_type
# Date, in YYYY-MM-DD format, after which payments will not be collected. Defaults to no end date.
sig { returns(T.nilable(String)) }
attr_reader :end_date
# The periodicity at which payments will be collected.
sig { returns(T.nilable(String)) }
attr_reader :payment_schedule
# The number of payments that will be made during a payment period. Defaults to 1 except for when `payment_schedule` is `adhoc`. In that case, it defaults to no limit.
sig { returns(T.nilable(Integer)) }
attr_reader :payments_per_period
# The purpose for which payments are made. Defaults to retail.
sig { returns(T.nilable(String)) }
attr_reader :purpose
# Date, in YYYY-MM-DD format, from which payments will be collected. Defaults to confirmation time.
sig { returns(T.nilable(String)) }
attr_reader :start_date
end
# Attribute for field mandate_options
sig { returns(MandateOptions) }
attr_reader :mandate_options
end
class SepaDebit < Stripe::StripeObject
class MandateOptions < Stripe::StripeObject
# Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'STRIPE'.
sig { returns(String) }
attr_reader :reference_prefix
end
# Attribute for field mandate_options
sig { returns(MandateOptions) }
attr_reader :mandate_options
end
class UsBankAccount < Stripe::StripeObject
class FinancialConnections < Stripe::StripeObject
class Filters < Stripe::StripeObject
# The account subcategories to use to filter for possible accounts to link. Valid subcategories are `checking` and `savings`.
sig { returns(T::Array[String]) }
attr_reader :account_subcategories
# The institution to use to filter for possible accounts to link.
sig { returns(String) }
attr_reader :institution
end
class ManualEntry < Stripe::StripeObject
# Settings for configuring manual entry of account details.
sig { returns(String) }
attr_reader :mode
end
# Attribute for field filters
sig { returns(Filters) }
attr_reader :filters
# Attribute for field manual_entry
sig { returns(ManualEntry) }
attr_reader :manual_entry
# The list of permissions to request. The `payment_method` permission must be included.
sig { returns(T::Array[String]) }
attr_reader :permissions
# Data features requested to be retrieved upon account creation.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :prefetch
# For webview integrations only. Upon completing OAuth login in the native browser, the user will be redirected to this URL to return to your app.
sig { returns(String) }
attr_reader :return_url
end
class MandateOptions < Stripe::StripeObject
# Mandate collection method
sig { returns(String) }
attr_reader :collection_method
end
# Attribute for field financial_connections
sig { returns(FinancialConnections) }
attr_reader :financial_connections
# Attribute for field mandate_options
sig { returns(MandateOptions) }
attr_reader :mandate_options
# Bank account verification method.
sig { returns(String) }
attr_reader :verification_method
end
# Attribute for field acss_debit
sig { returns(AcssDebit) }
attr_reader :acss_debit
# Attribute for field amazon_pay
sig { returns(AmazonPay) }
attr_reader :amazon_pay
# Attribute for field bacs_debit
sig { returns(BacsDebit) }
attr_reader :bacs_debit
# Attribute for field card
sig { returns(Card) }
attr_reader :card
# Attribute for field card_present
sig { returns(CardPresent) }
attr_reader :card_present
# Attribute for field link
sig { returns(Link) }
attr_reader :link
# Attribute for field paypal
sig { returns(Paypal) }
attr_reader :paypal
# Attribute for field payto
sig { returns(Payto) }
attr_reader :payto
# Attribute for field sepa_debit
sig { returns(SepaDebit) }
attr_reader :sepa_debit
# Attribute for field us_bank_account
sig { returns(UsBankAccount) }
attr_reader :us_bank_account
end
# ID of the Connect application that created the SetupIntent.
sig { returns(T.nilable(T.any(String, Stripe::Application))) }
attr_reader :application
# If present, the SetupIntent's payment method will be attached to the in-context Stripe Account.
#
# It can only be used for this Stripe Account’s own money movement flows like InboundTransfer and OutboundTransfers. It cannot be set to true when setting up a PaymentMethod for a Customer, and defaults to false when attaching a PaymentMethod to a Customer.
sig { returns(T::Boolean) }
attr_reader :attach_to_self
# Settings for dynamic payment methods compatible with this Setup Intent
sig { returns(T.nilable(AutomaticPaymentMethods)) }
attr_reader :automatic_payment_methods
# Reason for cancellation of this SetupIntent, one of `abandoned`, `requested_by_customer`, or `duplicate`.
sig { returns(T.nilable(String)) }
attr_reader :cancellation_reason
# The client secret of this SetupIntent. Used for client-side retrieval using a publishable key.
#
# The client secret can be used to complete payment setup from your frontend. It should not be stored, logged, or exposed to anyone other than the customer. Make sure that you have TLS enabled on any page that includes the client secret.
sig { returns(T.nilable(String)) }
attr_reader :client_secret
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# ID of the Customer this SetupIntent belongs to, if one exists.
#
# If present, the SetupIntent's payment method will be attached to the Customer on successful setup. Payment methods attached to other Customers cannot be used with this SetupIntent.
sig { returns(T.nilable(T.any(String, Stripe::Customer))) }
attr_reader :customer
# ID of the Account this SetupIntent belongs to, if one exists.
#
# If present, the SetupIntent's payment method will be attached to the Account on successful setup. Payment methods attached to other Accounts cannot be used with this SetupIntent.
sig { returns(T.nilable(String)) }
attr_reader :customer_account
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_reader :description
# Indicates the directions of money movement for which this payment method is intended to be used.
#
# Include `inbound` if you intend to use the payment method as the origin to pull funds from. Include `outbound` if you intend to use the payment method as the destination to send funds to. You can include both if you intend to use the payment method for both purposes.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :flow_directions
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# The error encountered in the previous SetupIntent confirmation.
sig { returns(T.nilable(LastSetupError)) }
attr_reader :last_setup_error
# The most recent SetupAttempt for this SetupIntent.
sig { returns(T.nilable(T.any(String, Stripe::SetupAttempt))) }
attr_reader :latest_attempt
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# ID of the multi use Mandate generated by the SetupIntent.
sig { returns(T.nilable(T.any(String, Stripe::Mandate))) }
attr_reader :mandate
# 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.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# If present, this property tells you what actions you need to take in order for your customer to continue payment setup.
sig { returns(T.nilable(NextAction)) }
attr_reader :next_action
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The account (if any) for which the setup is intended.
sig { returns(T.nilable(T.any(String, Stripe::Account))) }
attr_reader :on_behalf_of
# ID of the payment method used with this SetupIntent. If the payment method is `card_present` and isn't a digital wallet, then the [generated_card](https://docs.stripe.com/api/setup_attempts/object#setup_attempt_object-payment_method_details-card_present-generated_card) associated with the `latest_attempt` is attached to the Customer instead.
sig { returns(T.nilable(T.any(String, Stripe::PaymentMethod))) }
attr_reader :payment_method
# Information about the [payment method configuration](https://stripe.com/docs/api/payment_method_configurations) used for this Setup Intent.
sig { returns(T.nilable(PaymentMethodConfigurationDetails)) }
attr_reader :payment_method_configuration_details
# Payment method-specific configuration for this SetupIntent.
sig { returns(T.nilable(PaymentMethodOptions)) }
attr_reader :payment_method_options
# The list of payment method types (e.g. card) that this SetupIntent is allowed to set up.
sig { returns(T::Array[String]) }
attr_reader :payment_method_types
# ID of the single_use Mandate generated by the SetupIntent.
sig { returns(T.nilable(T.any(String, Stripe::Mandate))) }
attr_reader :single_use_mandate
# [Status](https://stripe.com/docs/payments/intents#intent-statuses) of this SetupIntent, one of `requires_payment_method`, `requires_confirmation`, `requires_action`, `processing`, `canceled`, or `succeeded`.
sig { returns(String) }
attr_reader :status
# Indicates how the payment method is intended to be used in the future.
#
# Use `on_session` if you intend to only reuse the payment method when the customer is in your checkout flow. Use `off_session` if your customer may or may not be in your checkout flow. If not provided, this value defaults to `off_session`.
sig { returns(String) }
attr_reader :usage
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# If present, the SetupIntent's payment method will be attached to the in-context Stripe Account.
#
# It can only be used for this Stripe Account’s own money movement flows like InboundTransfer and OutboundTransfers. It cannot be set to true when setting up a PaymentMethod for a Customer, and defaults to false when attaching a PaymentMethod to a Customer.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :attach_to_self
# A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.
sig { returns(T.nilable(T.any(::Stripe::SetupIntent::ListParams::Created, Integer))) }
attr_accessor :created
# Only return SetupIntents for the customer specified by this customer ID.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# Only return SetupIntents for the account specified by this customer ID.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Only return SetupIntents that associate with the specified payment method.
sig { returns(T.nilable(String)) }
attr_accessor :payment_method
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(attach_to_self: T.nilable(T::Boolean), created: T.nilable(T.any(::Stripe::SetupIntent::ListParams::Created, Integer)), customer: T.nilable(String), customer_account: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), payment_method: T.nilable(String), starting_after: T.nilable(String)).void
}
def initialize(
attach_to_self: nil,
created: nil,
customer: nil,
customer_account: nil,
ending_before: nil,
expand: nil,
limit: nil,
payment_method: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class AutomaticPaymentMethods < Stripe::RequestParams
# Controls whether this SetupIntent will accept redirect-based payment methods.
#
# Redirect-based payment methods may require your customer to be redirected to a payment method's app or site for authentication or additional steps. To [confirm](https://stripe.com/docs/api/setup_intents/confirm) this SetupIntent, you may be required to provide a `return_url` to redirect customers back to your site after they authenticate or complete the setup.
sig { returns(T.nilable(String)) }
attr_accessor :allow_redirects
# Whether this feature is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
sig { params(allow_redirects: T.nilable(String), enabled: T::Boolean).void }
def initialize(allow_redirects: nil, enabled: nil); end
end
class MandateData < Stripe::RequestParams
class CustomerAcceptance < Stripe::RequestParams
class Offline < Stripe::RequestParams; end
class Online < Stripe::RequestParams
# The IP address from which the Mandate was accepted by the customer.
sig { returns(String) }
attr_accessor :ip_address
# The user agent of the browser from which the Mandate was accepted by the customer.
sig { returns(String) }
attr_accessor :user_agent
sig { params(ip_address: String, user_agent: String).void }
def initialize(ip_address: nil, user_agent: nil); end
end
# The time at which the customer accepted the Mandate.
sig { returns(T.nilable(Integer)) }
attr_accessor :accepted_at
# If this is a Mandate accepted offline, this hash contains details about the offline acceptance.
sig {
returns(T.nilable(::Stripe::SetupIntent::CreateParams::MandateData::CustomerAcceptance::Offline))
}
attr_accessor :offline
# If this is a Mandate accepted online, this hash contains details about the online acceptance.
sig {
returns(T.nilable(::Stripe::SetupIntent::CreateParams::MandateData::CustomerAcceptance::Online))
}
attr_accessor :online
# The type of customer acceptance information included with the Mandate. One of `online` or `offline`.
sig { returns(String) }
attr_accessor :type
sig {
params(accepted_at: T.nilable(Integer), offline: T.nilable(::Stripe::SetupIntent::CreateParams::MandateData::CustomerAcceptance::Offline), online: T.nilable(::Stripe::SetupIntent::CreateParams::MandateData::CustomerAcceptance::Online), type: String).void
}
def initialize(accepted_at: nil, offline: nil, online: nil, type: nil); end
end
# This hash contains details about the customer acceptance of the Mandate.
sig { returns(::Stripe::SetupIntent::CreateParams::MandateData::CustomerAcceptance) }
attr_accessor :customer_acceptance
sig {
params(customer_acceptance: ::Stripe::SetupIntent::CreateParams::MandateData::CustomerAcceptance).void
}
def initialize(customer_acceptance: nil); end
end
class PaymentMethodData < Stripe::RequestParams
class AcssDebit < Stripe::RequestParams
# Customer's bank account number.
sig { returns(String) }
attr_accessor :account_number
# Institution number of the customer's bank.
sig { returns(String) }
attr_accessor :institution_number
# Transit number of the customer's bank.
sig { returns(String) }
attr_accessor :transit_number
sig {
params(account_number: String, institution_number: String, transit_number: String).void
}
def initialize(account_number: nil, institution_number: nil, transit_number: nil); end
end
class Affirm < Stripe::RequestParams; end
class AfterpayClearpay < Stripe::RequestParams; end
class Alipay < Stripe::RequestParams; end
class Alma < Stripe::RequestParams; end
class AmazonPay < Stripe::RequestParams; end
class AuBecsDebit < Stripe::RequestParams
# The account number for the bank account.
sig { returns(String) }
attr_accessor :account_number
# Bank-State-Branch number of the bank account.
sig { returns(String) }
attr_accessor :bsb_number
sig { params(account_number: String, bsb_number: String).void }
def initialize(account_number: nil, bsb_number: nil); end
end
class BacsDebit < Stripe::RequestParams
# Account number of the bank account that the funds will be debited from.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Sort code of the bank account. (e.g., `10-20-30`)
sig { returns(T.nilable(String)) }
attr_accessor :sort_code
sig { params(account_number: T.nilable(String), sort_code: T.nilable(String)).void }
def initialize(account_number: nil, sort_code: nil); end
end
class Bancontact < Stripe::RequestParams; end
class Billie < Stripe::RequestParams; end
class BillingDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Billing address.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SetupIntent::CreateParams::PaymentMethodData::BillingDetails::Address))))
}
attr_accessor :address
# Email address.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :email
# Full name.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :name
# Billing phone number (including extension).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :phone
# Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
sig { returns(T.nilable(String)) }
attr_accessor :tax_id
sig {
params(address: T.nilable(T.nilable(T.any(String, ::Stripe::SetupIntent::CreateParams::PaymentMethodData::BillingDetails::Address))), email: T.nilable(T.nilable(String)), name: T.nilable(T.nilable(String)), phone: T.nilable(T.nilable(String)), tax_id: T.nilable(String)).void
}
def initialize(address: nil, email: nil, name: nil, phone: nil, tax_id: nil); end
end
class Blik < Stripe::RequestParams; end
class Boleto < Stripe::RequestParams
# The tax ID of the customer (CPF for individual consumers or CNPJ for businesses consumers)
sig { returns(String) }
attr_accessor :tax_id
sig { params(tax_id: String).void }
def initialize(tax_id: nil); end
end
class Cashapp < Stripe::RequestParams; end
class CustomerBalance < Stripe::RequestParams; end
class Eps < Stripe::RequestParams
# The customer's bank.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class Fpx < Stripe::RequestParams
# Account holder type for FPX transaction
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_type
# The customer's bank.
sig { returns(String) }
attr_accessor :bank
sig { params(account_holder_type: T.nilable(String), bank: String).void }
def initialize(account_holder_type: nil, bank: nil); end
end
class Giropay < Stripe::RequestParams; end
class Gopay < Stripe::RequestParams; end
class Grabpay < Stripe::RequestParams; end
class IdBankTransfer < Stripe::RequestParams
# Bank where the account is held.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class Ideal < Stripe::RequestParams
# The customer's bank. Only use this parameter for existing customers. Don't use it for new customers.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class InteracPresent < Stripe::RequestParams; end
class KakaoPay < Stripe::RequestParams; end
class Klarna < Stripe::RequestParams
class Dob < Stripe::RequestParams
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
# Customer's date of birth
sig {
returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Klarna::Dob))
}
attr_accessor :dob
sig {
params(dob: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Klarna::Dob)).void
}
def initialize(dob: nil); end
end
class Konbini < Stripe::RequestParams; end
class KrCard < Stripe::RequestParams; end
class Link < Stripe::RequestParams; end
class MbWay < Stripe::RequestParams; end
class Mobilepay < Stripe::RequestParams; end
class Multibanco < Stripe::RequestParams; end
class NaverPay < Stripe::RequestParams
# Whether to use Naver Pay points or a card to fund this transaction. If not provided, this defaults to `card`.
sig { returns(T.nilable(String)) }
attr_accessor :funding
sig { params(funding: T.nilable(String)).void }
def initialize(funding: nil); end
end
class NzBankAccount < Stripe::RequestParams
# The name on the bank account. Only required if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod’s billing details.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_name
# The account number for the bank account.
sig { returns(String) }
attr_accessor :account_number
# The numeric code for the bank account's bank.
sig { returns(String) }
attr_accessor :bank_code
# The numeric code for the bank account's bank branch.
sig { returns(String) }
attr_accessor :branch_code
# Attribute for param field reference
sig { returns(T.nilable(String)) }
attr_accessor :reference
# The suffix of the bank account number.
sig { returns(String) }
attr_accessor :suffix
sig {
params(account_holder_name: T.nilable(String), account_number: String, bank_code: String, branch_code: String, reference: T.nilable(String), suffix: String).void
}
def initialize(
account_holder_name: nil,
account_number: nil,
bank_code: nil,
branch_code: nil,
reference: nil,
suffix: nil
); end
end
class Oxxo < Stripe::RequestParams; end
class P24 < Stripe::RequestParams
# The customer's bank.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class PayByBank < Stripe::RequestParams; end
class Payco < Stripe::RequestParams; end
class Paynow < Stripe::RequestParams; end
class Paypal < Stripe::RequestParams; end
class Payto < Stripe::RequestParams
# The account number for the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Bank-State-Branch number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :bsb_number
# The PayID alias for the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :pay_id
sig {
params(account_number: T.nilable(String), bsb_number: T.nilable(String), pay_id: T.nilable(String)).void
}
def initialize(account_number: nil, bsb_number: nil, pay_id: nil); end
end
class Pix < Stripe::RequestParams; end
class Promptpay < Stripe::RequestParams; end
class Qris < Stripe::RequestParams; end
class RadarOptions < Stripe::RequestParams
# A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
sig { returns(T.nilable(String)) }
attr_accessor :session
sig { params(session: T.nilable(String)).void }
def initialize(session: nil); end
end
class Rechnung < Stripe::RequestParams
class Dob < Stripe::RequestParams
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
# Customer's date of birth
sig { returns(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Rechnung::Dob) }
attr_accessor :dob
sig {
params(dob: ::Stripe::SetupIntent::CreateParams::PaymentMethodData::Rechnung::Dob).void
}
def initialize(dob: nil); end
end
class RevolutPay < Stripe::RequestParams; end
class SamsungPay < Stripe::RequestParams; end
class Satispay < Stripe::RequestParams; end
class SepaDebit < Stripe::RequestParams
# IBAN of the bank account.
sig { returns(String) }
attr_accessor :iban
sig { params(iban: String).void }
def initialize(iban: nil); end
end
class Shopeepay < Stripe::RequestParams; end
class Sofort < Stripe::RequestParams
# Two-letter ISO code representing the country the bank account is located in.
sig { returns(String) }
attr_accessor :country
sig { params(country: String).void }
def initialize(country: nil); end
end
class StripeBalance < Stripe::RequestParams
# The connected account ID whose Stripe balance to use as the source of payment
sig { returns(T.nilable(String)) }
attr_accessor :account
# The [source_type](https://docs.stripe.com/api/balance/balance_object#balance_object-available-source_types) of the balance
sig { returns(T.nilable(String)) }
attr_accessor :source_type
sig { params(account: T.nilable(String), source_type: T.nilable(String)).void }
def initialize(account: nil, source_type: nil); end
end
class Swish < Stripe::RequestParams; end
class Twint < Stripe::RequestParams; end
class UsBankAccount < Stripe::RequestParams
# Account holder type: individual or company.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_type
# Account number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Account type: checkings or savings. Defaults to checking if omitted.
sig { returns(T.nilable(String)) }
attr_accessor :account_type
# The ID of a Financial Connections Account to use as a payment method.
sig { returns(T.nilable(String)) }
attr_accessor :financial_connections_account
# Routing number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :routing_number
sig {
params(account_holder_type: T.nilable(String), account_number: T.nilable(String), account_type: T.nilable(String), financial_connections_account: T.nilable(String), routing_number: T.nilable(String)).void
}
def initialize(
account_holder_type: nil,
account_number: nil,
account_type: nil,
financial_connections_account: nil,
routing_number: nil
); end
end
class WechatPay < Stripe::RequestParams; end
class Zip < Stripe::RequestParams; end
# If this is an `acss_debit` PaymentMethod, this hash contains details about the ACSS Debit payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::AcssDebit))
}
attr_accessor :acss_debit
# If this is an `affirm` PaymentMethod, this hash contains details about the Affirm payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Affirm)) }
attr_accessor :affirm
# If this is an `AfterpayClearpay` PaymentMethod, this hash contains details about the AfterpayClearpay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::AfterpayClearpay))
}
attr_accessor :afterpay_clearpay
# If this is an `Alipay` PaymentMethod, this hash contains details about the Alipay payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Alipay)) }
attr_accessor :alipay
# This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :allow_redisplay
# If this is a Alma PaymentMethod, this hash contains details about the Alma payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Alma)) }
attr_accessor :alma
# If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::AmazonPay))
}
attr_accessor :amazon_pay
# If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.
sig {
returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::AuBecsDebit))
}
attr_accessor :au_becs_debit
# If this is a `bacs_debit` PaymentMethod, this hash contains details about the Bacs Direct Debit bank account.
sig {
returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::BacsDebit))
}
attr_accessor :bacs_debit
# If this is a `bancontact` PaymentMethod, this hash contains details about the Bancontact payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Bancontact))
}
attr_accessor :bancontact
# If this is a `billie` PaymentMethod, this hash contains details about the Billie payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Billie)) }
attr_accessor :billie
# Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
sig {
returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::BillingDetails))
}
attr_accessor :billing_details
# If this is a `blik` PaymentMethod, this hash contains details about the BLIK payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Blik)) }
attr_accessor :blik
# If this is a `boleto` PaymentMethod, this hash contains details about the Boleto payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Boleto)) }
attr_accessor :boleto
# If this is a `cashapp` PaymentMethod, this hash contains details about the Cash App Pay payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Cashapp)) }
attr_accessor :cashapp
# If this is a `customer_balance` PaymentMethod, this hash contains details about the CustomerBalance payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::CustomerBalance))
}
attr_accessor :customer_balance
# If this is an `eps` PaymentMethod, this hash contains details about the EPS payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Eps)) }
attr_accessor :eps
# If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Fpx)) }
attr_accessor :fpx
# If this is a `giropay` PaymentMethod, this hash contains details about the Giropay payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Giropay)) }
attr_accessor :giropay
# If this is a Gopay PaymentMethod, this hash contains details about the Gopay payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Gopay)) }
attr_accessor :gopay
# If this is a `grabpay` PaymentMethod, this hash contains details about the GrabPay payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Grabpay)) }
attr_accessor :grabpay
# If this is an `IdBankTransfer` PaymentMethod, this hash contains details about the IdBankTransfer payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::IdBankTransfer))
}
attr_accessor :id_bank_transfer
# If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Ideal)) }
attr_accessor :ideal
# If this is an `interac_present` PaymentMethod, this hash contains details about the Interac Present payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::InteracPresent))
}
attr_accessor :interac_present
# If this is a `kakao_pay` PaymentMethod, this hash contains details about the Kakao Pay payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::KakaoPay)) }
attr_accessor :kakao_pay
# If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Klarna)) }
attr_accessor :klarna
# If this is a `konbini` PaymentMethod, this hash contains details about the Konbini payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Konbini)) }
attr_accessor :konbini
# If this is a `kr_card` PaymentMethod, this hash contains details about the Korean Card payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::KrCard)) }
attr_accessor :kr_card
# If this is an `Link` PaymentMethod, this hash contains details about the Link payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Link)) }
attr_accessor :link
# If this is a MB WAY PaymentMethod, this hash contains details about the MB WAY payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::MbWay)) }
attr_accessor :mb_way
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# If this is a `mobilepay` PaymentMethod, this hash contains details about the MobilePay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Mobilepay))
}
attr_accessor :mobilepay
# If this is a `multibanco` PaymentMethod, this hash contains details about the Multibanco payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Multibanco))
}
attr_accessor :multibanco
# If this is a `naver_pay` PaymentMethod, this hash contains details about the Naver Pay payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::NaverPay)) }
attr_accessor :naver_pay
# If this is an nz_bank_account PaymentMethod, this hash contains details about the nz_bank_account payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::NzBankAccount))
}
attr_accessor :nz_bank_account
# If this is an `oxxo` PaymentMethod, this hash contains details about the OXXO payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Oxxo)) }
attr_accessor :oxxo
# If this is a `p24` PaymentMethod, this hash contains details about the P24 payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::P24)) }
attr_accessor :p24
# If this is a `pay_by_bank` PaymentMethod, this hash contains details about the PayByBank payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::PayByBank))
}
attr_accessor :pay_by_bank
# If this is a `payco` PaymentMethod, this hash contains details about the PAYCO payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Payco)) }
attr_accessor :payco
# If this is a `paynow` PaymentMethod, this hash contains details about the PayNow payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Paynow)) }
attr_accessor :paynow
# If this is a `paypal` PaymentMethod, this hash contains details about the PayPal payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Paypal)) }
attr_accessor :paypal
# If this is a `payto` PaymentMethod, this hash contains details about the PayTo payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Payto)) }
attr_accessor :payto
# If this is a `pix` PaymentMethod, this hash contains details about the Pix payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Pix)) }
attr_accessor :pix
# If this is a `promptpay` PaymentMethod, this hash contains details about the PromptPay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Promptpay))
}
attr_accessor :promptpay
# If this is a `qris` PaymentMethod, this hash contains details about the QRIS payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Qris)) }
attr_accessor :qris
# Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
sig {
returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::RadarOptions))
}
attr_accessor :radar_options
# If this is a `rechnung` PaymentMethod, this hash contains details about the Rechnung payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Rechnung)) }
attr_accessor :rechnung
# If this is a `revolut_pay` PaymentMethod, this hash contains details about the Revolut Pay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::RevolutPay))
}
attr_accessor :revolut_pay
# If this is a `samsung_pay` PaymentMethod, this hash contains details about the SamsungPay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::SamsungPay))
}
attr_accessor :samsung_pay
# If this is a `satispay` PaymentMethod, this hash contains details about the Satispay payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Satispay)) }
attr_accessor :satispay
# If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account.
sig {
returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::SepaDebit))
}
attr_accessor :sepa_debit
# If this is a Shopeepay PaymentMethod, this hash contains details about the Shopeepay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Shopeepay))
}
attr_accessor :shopeepay
# If this is a `sofort` PaymentMethod, this hash contains details about the SOFORT payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Sofort)) }
attr_accessor :sofort
# This hash contains details about the Stripe balance payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::StripeBalance))
}
attr_accessor :stripe_balance
# If this is a `swish` PaymentMethod, this hash contains details about the Swish payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Swish)) }
attr_accessor :swish
# If this is a TWINT PaymentMethod, this hash contains details about the TWINT payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Twint)) }
attr_accessor :twint
# The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
sig { returns(String) }
attr_accessor :type
# If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::UsBankAccount))
}
attr_accessor :us_bank_account
# If this is an `wechat_pay` PaymentMethod, this hash contains details about the wechat_pay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::WechatPay))
}
attr_accessor :wechat_pay
# If this is a `zip` PaymentMethod, this hash contains details about the Zip payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Zip)) }
attr_accessor :zip
sig {
params(acss_debit: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::AcssDebit), affirm: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Affirm), afterpay_clearpay: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::AfterpayClearpay), alipay: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Alipay), allow_redisplay: T.nilable(String), alma: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Alma), amazon_pay: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::AmazonPay), au_becs_debit: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::AuBecsDebit), bacs_debit: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::BacsDebit), bancontact: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Bancontact), billie: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Billie), billing_details: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::BillingDetails), blik: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Blik), boleto: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Boleto), cashapp: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Cashapp), customer_balance: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::CustomerBalance), eps: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Eps), fpx: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Fpx), giropay: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Giropay), gopay: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Gopay), grabpay: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Grabpay), id_bank_transfer: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::IdBankTransfer), ideal: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Ideal), interac_present: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::InteracPresent), kakao_pay: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::KakaoPay), klarna: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Klarna), konbini: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Konbini), kr_card: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::KrCard), link: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Link), mb_way: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::MbWay), metadata: T.nilable(T::Hash[String, String]), mobilepay: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Mobilepay), multibanco: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Multibanco), naver_pay: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::NaverPay), nz_bank_account: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::NzBankAccount), oxxo: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Oxxo), p24: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::P24), pay_by_bank: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::PayByBank), payco: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Payco), paynow: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Paynow), paypal: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Paypal), payto: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Payto), pix: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Pix), promptpay: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Promptpay), qris: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Qris), radar_options: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::RadarOptions), rechnung: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Rechnung), revolut_pay: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::RevolutPay), samsung_pay: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::SamsungPay), satispay: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Satispay), sepa_debit: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::SepaDebit), shopeepay: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Shopeepay), sofort: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Sofort), stripe_balance: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::StripeBalance), swish: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Swish), twint: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Twint), type: String, us_bank_account: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::UsBankAccount), wechat_pay: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::WechatPay), zip: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData::Zip)).void
}
def initialize(
acss_debit: nil,
affirm: nil,
afterpay_clearpay: nil,
alipay: nil,
allow_redisplay: nil,
alma: nil,
amazon_pay: nil,
au_becs_debit: nil,
bacs_debit: nil,
bancontact: nil,
billie: nil,
billing_details: nil,
blik: nil,
boleto: nil,
cashapp: nil,
customer_balance: nil,
eps: nil,
fpx: nil,
giropay: nil,
gopay: nil,
grabpay: nil,
id_bank_transfer: nil,
ideal: nil,
interac_present: nil,
kakao_pay: nil,
klarna: nil,
konbini: nil,
kr_card: nil,
link: nil,
mb_way: nil,
metadata: nil,
mobilepay: nil,
multibanco: nil,
naver_pay: nil,
nz_bank_account: nil,
oxxo: nil,
p24: nil,
pay_by_bank: nil,
payco: nil,
paynow: nil,
paypal: nil,
payto: nil,
pix: nil,
promptpay: nil,
qris: nil,
radar_options: nil,
rechnung: nil,
revolut_pay: nil,
samsung_pay: nil,
satispay: nil,
sepa_debit: nil,
shopeepay: nil,
sofort: nil,
stripe_balance: nil,
swish: nil,
twint: nil,
type: nil,
us_bank_account: nil,
wechat_pay: nil,
zip: nil
); end
end
class PaymentMethodOptions < Stripe::RequestParams
class AcssDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# A URL for custom mandate text to render during confirmation step.
# The URL will be rendered with additional GET parameters `payment_intent` and `payment_intent_client_secret` when confirming a Payment Intent,
# or `setup_intent` and `setup_intent_client_secret` when confirming a Setup Intent.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :custom_mandate_url
# List of Stripe products where this mandate can be selected automatically.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :default_for
# Description of the mandate interval. Only required if 'payment_schedule' parameter is 'interval' or 'combined'.
sig { returns(T.nilable(String)) }
attr_accessor :interval_description
# Payment schedule for the mandate.
sig { returns(T.nilable(String)) }
attr_accessor :payment_schedule
# Transaction type of the mandate.
sig { returns(T.nilable(String)) }
attr_accessor :transaction_type
sig {
params(custom_mandate_url: T.nilable(T.nilable(String)), default_for: T.nilable(T::Array[String]), interval_description: T.nilable(String), payment_schedule: T.nilable(String), transaction_type: T.nilable(String)).void
}
def initialize(
custom_mandate_url: nil,
default_for: nil,
interval_description: nil,
payment_schedule: nil,
transaction_type: nil
); end
end
# 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).
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions::AcssDebit::MandateOptions))
}
attr_accessor :mandate_options
# Bank account verification method.
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(currency: T.nilable(String), mandate_options: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions::AcssDebit::MandateOptions), verification_method: T.nilable(String)).void
}
def initialize(currency: nil, mandate_options: nil, verification_method: nil); end
end
class AmazonPay < Stripe::RequestParams; end
class BacsDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'DDIC' or 'STRIPE'.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :reference_prefix
sig { params(reference_prefix: T.nilable(T.nilable(String))).void }
def initialize(reference_prefix: nil); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions::BacsDebit::MandateOptions))
}
attr_accessor :mandate_options
sig {
params(mandate_options: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions::BacsDebit::MandateOptions)).void
}
def initialize(mandate_options: nil); end
end
class Card < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Amount to be charged for future payments.
sig { returns(Integer) }
attr_accessor :amount
# One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.
sig { returns(String) }
attr_accessor :amount_type
# Currency in which future payments will be charged. 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).
sig { returns(String) }
attr_accessor :currency
# A description of the mandate or subscription that is meant to be displayed to the customer.
sig { returns(T.nilable(String)) }
attr_accessor :description
# End date of the mandate or subscription. If not provided, the mandate will be active until canceled. If provided, end date should be after start date.
sig { returns(T.nilable(Integer)) }
attr_accessor :end_date
# Specifies payment frequency. One of `day`, `week`, `month`, `year`, or `sporadic`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals between payments. For example, `interval=month` and `interval_count=3` indicates one payment every three months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks). This parameter is optional when `interval=sporadic`.
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_count
# Unique identifier for the mandate or subscription.
sig { returns(String) }
attr_accessor :reference
# Start date of the mandate or subscription. Start date should not be lesser than yesterday.
sig { returns(Integer) }
attr_accessor :start_date
# Specifies the type of mandates supported. Possible values are `india`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :supported_types
sig {
params(amount: Integer, amount_type: String, currency: String, description: T.nilable(String), end_date: T.nilable(Integer), interval: String, interval_count: T.nilable(Integer), reference: String, start_date: Integer, supported_types: T.nilable(T::Array[String])).void
}
def initialize(
amount: nil,
amount_type: nil,
currency: nil,
description: nil,
end_date: nil,
interval: nil,
interval_count: nil,
reference: nil,
start_date: nil,
supported_types: nil
); end
end
class ThreeDSecure < Stripe::RequestParams
class NetworkOptions < Stripe::RequestParams
class CartesBancaires < Stripe::RequestParams
# The cryptogram calculation algorithm used by the card Issuer's ACS
# to calculate the Authentication cryptogram. Also known as `cavvAlgorithm`.
# messageExtension: CB-AVALGO
sig { returns(String) }
attr_accessor :cb_avalgo
# The exemption indicator returned from Cartes Bancaires in the ARes.
# message extension: CB-EXEMPTION; string (4 characters)
# This is a 3 byte bitmap (low significant byte first and most significant
# bit first) that has been Base64 encoded
sig { returns(T.nilable(String)) }
attr_accessor :cb_exemption
# The risk score returned from Cartes Bancaires in the ARes.
# message extension: CB-SCORE; numeric value 0-99
sig { returns(T.nilable(Integer)) }
attr_accessor :cb_score
sig {
params(cb_avalgo: String, cb_exemption: T.nilable(String), cb_score: T.nilable(Integer)).void
}
def initialize(cb_avalgo: nil, cb_exemption: nil, cb_score: nil); end
end
# Cartes Bancaires-specific 3DS fields.
sig {
returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions::CartesBancaires))
}
attr_accessor :cartes_bancaires
sig {
params(cartes_bancaires: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions::CartesBancaires)).void
}
def initialize(cartes_bancaires: nil); end
end
# The `transStatus` returned from the card Issuer’s ACS in the ARes.
sig { returns(T.nilable(String)) }
attr_accessor :ares_trans_status
# The cryptogram, also known as the "authentication value" (AAV, CAVV or
# AEVV). This value is 20 bytes, base64-encoded into a 28-character string.
# (Most 3D Secure providers will return the base64-encoded version, which
# is what you should specify here.)
sig { returns(T.nilable(String)) }
attr_accessor :cryptogram
# The Electronic Commerce Indicator (ECI) is returned by your 3D Secure
# provider and indicates what degree of authentication was performed.
sig { returns(T.nilable(String)) }
attr_accessor :electronic_commerce_indicator
# Network specific 3DS fields. Network specific arguments require an
# explicit card brand choice. The parameter `payment_method_options.card.network``
# must be populated accordingly
sig {
returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions))
}
attr_accessor :network_options
# The challenge indicator (`threeDSRequestorChallengeInd`) which was requested in the
# AReq sent to the card Issuer's ACS. A string containing 2 digits from 01-99.
sig { returns(T.nilable(String)) }
attr_accessor :requestor_challenge_indicator
# For 3D Secure 1, the XID. For 3D Secure 2, the Directory Server
# Transaction ID (dsTransID).
sig { returns(T.nilable(String)) }
attr_accessor :transaction_id
# The version of 3D Secure that was performed.
sig { returns(T.nilable(String)) }
attr_accessor :version
sig {
params(ares_trans_status: T.nilable(String), cryptogram: T.nilable(String), electronic_commerce_indicator: T.nilable(String), network_options: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions), requestor_challenge_indicator: T.nilable(String), transaction_id: T.nilable(String), version: T.nilable(String)).void
}
def initialize(
ares_trans_status: nil,
cryptogram: nil,
electronic_commerce_indicator: nil,
network_options: nil,
requestor_challenge_indicator: nil,
transaction_id: nil,
version: nil
); end
end
# Configuration options for setting up an eMandate for cards issued in India.
sig {
returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions::Card::MandateOptions))
}
attr_accessor :mandate_options
# When specified, this parameter signals that a card has been collected
# as MOTO (Mail Order Telephone Order) and thus out of scope for SCA. This
# parameter can only be provided during confirmation.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :moto
# Selected network to process this SetupIntent on. Depends on the available networks of the card attached to the SetupIntent. Can be only set confirm-time.
sig { returns(T.nilable(String)) }
attr_accessor :network
# We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. If not provided, this value defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
sig { returns(T.nilable(String)) }
attr_accessor :request_three_d_secure
# If 3D Secure authentication was performed with a third-party provider,
# the authentication details to use for this setup.
sig {
returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions::Card::ThreeDSecure))
}
attr_accessor :three_d_secure
sig {
params(mandate_options: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions::Card::MandateOptions), moto: T.nilable(T::Boolean), network: T.nilable(String), request_three_d_secure: T.nilable(String), three_d_secure: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions::Card::ThreeDSecure)).void
}
def initialize(
mandate_options: nil,
moto: nil,
network: nil,
request_three_d_secure: nil,
three_d_secure: nil
); end
end
class CardPresent < Stripe::RequestParams; end
class Link < Stripe::RequestParams
# [Deprecated] This is a legacy parameter that no longer has any function.
sig { returns(T.nilable(String)) }
attr_accessor :persistent_token
sig { params(persistent_token: T.nilable(String)).void }
def initialize(persistent_token: nil); end
end
class Paypal < Stripe::RequestParams
# The PayPal Billing Agreement ID (BAID). This is an ID generated by PayPal which represents the mandate between the merchant and the customer.
sig { returns(T.nilable(String)) }
attr_accessor :billing_agreement_id
# Attribute for param field currency
sig { returns(T.nilable(String)) }
attr_accessor :currency
# The Stripe connected account IDs of the sellers on the platform for this transaction (optional). Only allowed when [separate charges and transfers](https://stripe.com/docs/connect/separate-charges-and-transfers) are used.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :subsellers
sig {
params(billing_agreement_id: T.nilable(String), currency: T.nilable(String), subsellers: T.nilable(T::Array[String])).void
}
def initialize(billing_agreement_id: nil, currency: nil, subsellers: nil); end
end
class Payto < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Amount that will be collected. It is required when `amount_type` is `fixed`.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# The type of amount that will be collected. The amount charged must be exact or up to the value of `amount` param for `fixed` or `maximum` type respectively.
sig { returns(T.nilable(String)) }
attr_accessor :amount_type
# Date, in YYYY-MM-DD format, after which payments will not be collected. Defaults to no end date.
sig { returns(T.nilable(String)) }
attr_accessor :end_date
# The periodicity at which payments will be collected.
sig { returns(T.nilable(String)) }
attr_accessor :payment_schedule
# The number of payments that will be made during a payment period. Defaults to 1 except for when `payment_schedule` is `adhoc`. In that case, it defaults to no limit.
sig { returns(T.nilable(Integer)) }
attr_accessor :payments_per_period
# The purpose for which payments are made. Defaults to retail.
sig { returns(T.nilable(String)) }
attr_accessor :purpose
# Date, in YYYY-MM-DD format, from which payments will be collected. Defaults to confirmation time.
sig { returns(T.nilable(String)) }
attr_accessor :start_date
sig {
params(amount: T.nilable(Integer), amount_type: T.nilable(String), end_date: T.nilable(String), payment_schedule: T.nilable(String), payments_per_period: T.nilable(Integer), purpose: T.nilable(String), start_date: T.nilable(String)).void
}
def initialize(
amount: nil,
amount_type: nil,
end_date: nil,
payment_schedule: nil,
payments_per_period: nil,
purpose: nil,
start_date: nil
); end
end
# Additional fields for Mandate creation.
sig {
returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions::Payto::MandateOptions))
}
attr_accessor :mandate_options
sig {
params(mandate_options: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions::Payto::MandateOptions)).void
}
def initialize(mandate_options: nil); end
end
class SepaDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'STRIPE'.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :reference_prefix
sig { params(reference_prefix: T.nilable(T.nilable(String))).void }
def initialize(reference_prefix: nil); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions::SepaDebit::MandateOptions))
}
attr_accessor :mandate_options
sig {
params(mandate_options: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions::SepaDebit::MandateOptions)).void
}
def initialize(mandate_options: nil); end
end
class UsBankAccount < Stripe::RequestParams
class FinancialConnections < Stripe::RequestParams
class Filters < Stripe::RequestParams
# The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :account_subcategories
# ID of the institution to use to filter for selectable accounts.
sig { returns(T.nilable(String)) }
attr_accessor :institution
sig {
params(account_subcategories: T.nilable(T::Array[String]), institution: T.nilable(String)).void
}
def initialize(account_subcategories: nil, institution: nil); end
end
class ManualEntry < Stripe::RequestParams
# Settings for configuring manual entry of account details.
sig { returns(String) }
attr_accessor :mode
sig { params(mode: String).void }
def initialize(mode: nil); end
end
# Provide filters for the linked accounts that the customer can select for the payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::Filters))
}
attr_accessor :filters
# Customize manual entry behavior
sig {
returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::ManualEntry))
}
attr_accessor :manual_entry
# The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :permissions
# List of data features that you would like to retrieve upon account creation.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :prefetch
# For webview integrations only. Upon completing OAuth login in the native browser, the user will be redirected to this URL to return to your app.
sig { returns(T.nilable(String)) }
attr_accessor :return_url
sig {
params(filters: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::Filters), manual_entry: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::ManualEntry), permissions: T.nilable(T::Array[String]), prefetch: T.nilable(T::Array[String]), return_url: T.nilable(String)).void
}
def initialize(
filters: nil,
manual_entry: nil,
permissions: nil,
prefetch: nil,
return_url: nil
); end
end
class MandateOptions < Stripe::RequestParams
# The method used to collect offline mandate customer acceptance.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :collection_method
sig { params(collection_method: T.nilable(T.nilable(String))).void }
def initialize(collection_method: nil); end
end
class Networks < Stripe::RequestParams
# Triggers validations to run across the selected networks
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Array[String])).void }
def initialize(requested: nil); end
end
# Additional fields for Financial Connections Session creation
sig {
returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections))
}
attr_accessor :financial_connections
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions::UsBankAccount::MandateOptions))
}
attr_accessor :mandate_options
# Additional fields for network related functions
sig {
returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions::UsBankAccount::Networks))
}
attr_accessor :networks
# Bank account verification method.
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(financial_connections: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections), mandate_options: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions::UsBankAccount::MandateOptions), networks: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions::UsBankAccount::Networks), verification_method: T.nilable(String)).void
}
def initialize(
financial_connections: nil,
mandate_options: nil,
networks: nil,
verification_method: nil
); end
end
# If this is a `acss_debit` SetupIntent, this sub-hash contains details about the ACSS Debit payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions::AcssDebit))
}
attr_accessor :acss_debit
# If this is a `amazon_pay` SetupIntent, this sub-hash contains details about the AmazonPay payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions::AmazonPay))
}
attr_accessor :amazon_pay
# If this is a `bacs_debit` SetupIntent, this sub-hash contains details about the Bacs Debit payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions::BacsDebit))
}
attr_accessor :bacs_debit
# Configuration for any card setup attempted on this SetupIntent.
sig { returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions::Card)) }
attr_accessor :card
# If this is a `card_present` PaymentMethod, this sub-hash contains details about the card-present payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions::CardPresent))
}
attr_accessor :card_present
# If this is a `link` PaymentMethod, this sub-hash contains details about the Link payment method options.
sig { returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions::Link)) }
attr_accessor :link
# If this is a `paypal` PaymentMethod, this sub-hash contains details about the PayPal payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions::Paypal))
}
attr_accessor :paypal
# If this is a `payto` SetupIntent, this sub-hash contains details about the PayTo payment method options.
sig { returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions::Payto)) }
attr_accessor :payto
# If this is a `sepa_debit` SetupIntent, this sub-hash contains details about the SEPA Debit payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions::SepaDebit))
}
attr_accessor :sepa_debit
# If this is a `us_bank_account` SetupIntent, this sub-hash contains details about the US bank account payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions::UsBankAccount))
}
attr_accessor :us_bank_account
sig {
params(acss_debit: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions::AcssDebit), amazon_pay: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions::AmazonPay), bacs_debit: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions::BacsDebit), card: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions::Card), card_present: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions::CardPresent), link: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions::Link), paypal: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions::Paypal), payto: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions::Payto), sepa_debit: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions::SepaDebit), us_bank_account: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions::UsBankAccount)).void
}
def initialize(
acss_debit: nil,
amazon_pay: nil,
bacs_debit: nil,
card: nil,
card_present: nil,
link: nil,
paypal: nil,
payto: nil,
sepa_debit: nil,
us_bank_account: nil
); end
end
class SingleUse < Stripe::RequestParams
# Amount the customer is granting permission to collect later. A positive integer representing how much to charge in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is $0.50 US or [equivalent in charge currency](https://stripe.com/docs/currencies#minimum-and-maximum-charge-amounts). The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99).
sig { returns(Integer) }
attr_accessor :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).
sig { returns(String) }
attr_accessor :currency
sig { params(amount: Integer, currency: String).void }
def initialize(amount: nil, currency: nil); end
end
# If present, the SetupIntent's payment method will be attached to the in-context Stripe Account.
#
# It can only be used for this Stripe Account’s own money movement flows like InboundTransfer and OutboundTransfers. It cannot be set to true when setting up a PaymentMethod for a Customer, and defaults to false when attaching a PaymentMethod to a Customer.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :attach_to_self
# When you enable this parameter, this SetupIntent accepts payment methods that you enable in the Dashboard and that are compatible with its other parameters.
sig { returns(T.nilable(::Stripe::SetupIntent::CreateParams::AutomaticPaymentMethods)) }
attr_accessor :automatic_payment_methods
# Set to `true` to attempt to confirm this SetupIntent immediately. This parameter defaults to `false`. If a card is the attached payment method, you can provide a `return_url` in case further authentication is necessary.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :confirm
# ID of the ConfirmationToken used to confirm this SetupIntent.
#
# If the provided ConfirmationToken contains properties that are also being provided in this request, such as `payment_method`, then the values in this request will take precedence.
sig { returns(T.nilable(String)) }
attr_accessor :confirmation_token
# ID of the Customer this SetupIntent belongs to, if one exists.
#
# If present, the SetupIntent's payment method will be attached to the Customer on successful setup. Payment methods attached to other Customers cannot be used with this SetupIntent.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# ID of the Account this SetupIntent belongs to, if one exists.
#
# If present, the SetupIntent's payment method will be attached to the Account on successful setup. Payment methods attached to other Accounts cannot be used with this SetupIntent.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Indicates the directions of money movement for which this payment method is intended to be used.
#
# Include `inbound` if you intend to use the payment method as the origin to pull funds from. Include `outbound` if you intend to use the payment method as the destination to send funds to. You can include both if you intend to use the payment method for both purposes.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :flow_directions
# This hash contains details about the mandate to create. This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/setup_intents/create#create_setup_intent-confirm).
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SetupIntent::CreateParams::MandateData))))
}
attr_accessor :mandate_data
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The Stripe account ID created for this SetupIntent.
sig { returns(T.nilable(String)) }
attr_accessor :on_behalf_of
# ID of the payment method (a PaymentMethod, Card, or saved Source object) to attach to this SetupIntent.
sig { returns(T.nilable(String)) }
attr_accessor :payment_method
# The ID of the [payment method configuration](https://stripe.com/docs/api/payment_method_configurations) to use with this SetupIntent.
sig { returns(T.nilable(String)) }
attr_accessor :payment_method_configuration
# When included, this hash creates a PaymentMethod that is set as the [`payment_method`](https://stripe.com/docs/api/setup_intents/object#setup_intent_object-payment_method)
# value in the SetupIntent.
sig { returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData)) }
attr_accessor :payment_method_data
# Payment method-specific configuration for this SetupIntent.
sig { returns(T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions)) }
attr_accessor :payment_method_options
# The list of payment method types (for example, card) that this SetupIntent can use. If you don't provide this, Stripe will dynamically show relevant payment methods from your [payment method settings](https://dashboard.stripe.com/settings/payment_methods).
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :payment_method_types
# The URL to redirect your customer back to after they authenticate or cancel their payment on the payment method's app or site. To redirect to a mobile application, you can alternatively supply an application URI scheme. This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/setup_intents/create#create_setup_intent-confirm).
sig { returns(T.nilable(String)) }
attr_accessor :return_url
# If you populate this hash, this SetupIntent generates a `single_use` mandate after successful completion.
#
# Single-use mandates are only valid for the following payment methods: `acss_debit`, `alipay`, `au_becs_debit`, `bacs_debit`, `bancontact`, `boleto`, `ideal`, `link`, `sepa_debit`, and `us_bank_account`.
sig { returns(T.nilable(::Stripe::SetupIntent::CreateParams::SingleUse)) }
attr_accessor :single_use
# Indicates how the payment method is intended to be used in the future. If not provided, this value defaults to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :usage
# Set to `true` when confirming server-side and using Stripe.js, iOS, or Android client-side SDKs to handle the next actions.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :use_stripe_sdk
sig {
params(attach_to_self: T.nilable(T::Boolean), automatic_payment_methods: T.nilable(::Stripe::SetupIntent::CreateParams::AutomaticPaymentMethods), confirm: T.nilable(T::Boolean), confirmation_token: T.nilable(String), customer: T.nilable(String), customer_account: T.nilable(String), description: T.nilable(String), expand: T.nilable(T::Array[String]), flow_directions: T.nilable(T::Array[String]), mandate_data: T.nilable(T.nilable(T.any(String, ::Stripe::SetupIntent::CreateParams::MandateData))), metadata: T.nilable(T::Hash[String, String]), on_behalf_of: T.nilable(String), payment_method: T.nilable(String), payment_method_configuration: T.nilable(String), payment_method_data: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodData), payment_method_options: T.nilable(::Stripe::SetupIntent::CreateParams::PaymentMethodOptions), payment_method_types: T.nilable(T::Array[String]), return_url: T.nilable(String), single_use: T.nilable(::Stripe::SetupIntent::CreateParams::SingleUse), usage: T.nilable(String), use_stripe_sdk: T.nilable(T::Boolean)).void
}
def initialize(
attach_to_self: nil,
automatic_payment_methods: nil,
confirm: nil,
confirmation_token: nil,
customer: nil,
customer_account: nil,
description: nil,
expand: nil,
flow_directions: nil,
mandate_data: nil,
metadata: nil,
on_behalf_of: nil,
payment_method: nil,
payment_method_configuration: nil,
payment_method_data: nil,
payment_method_options: nil,
payment_method_types: nil,
return_url: nil,
single_use: nil,
usage: nil,
use_stripe_sdk: nil
); end
end
class UpdateParams < Stripe::RequestParams
class PaymentMethodData < Stripe::RequestParams
class AcssDebit < Stripe::RequestParams
# Customer's bank account number.
sig { returns(String) }
attr_accessor :account_number
# Institution number of the customer's bank.
sig { returns(String) }
attr_accessor :institution_number
# Transit number of the customer's bank.
sig { returns(String) }
attr_accessor :transit_number
sig {
params(account_number: String, institution_number: String, transit_number: String).void
}
def initialize(account_number: nil, institution_number: nil, transit_number: nil); end
end
class Affirm < Stripe::RequestParams; end
class AfterpayClearpay < Stripe::RequestParams; end
class Alipay < Stripe::RequestParams; end
class Alma < Stripe::RequestParams; end
class AmazonPay < Stripe::RequestParams; end
class AuBecsDebit < Stripe::RequestParams
# The account number for the bank account.
sig { returns(String) }
attr_accessor :account_number
# Bank-State-Branch number of the bank account.
sig { returns(String) }
attr_accessor :bsb_number
sig { params(account_number: String, bsb_number: String).void }
def initialize(account_number: nil, bsb_number: nil); end
end
class BacsDebit < Stripe::RequestParams
# Account number of the bank account that the funds will be debited from.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Sort code of the bank account. (e.g., `10-20-30`)
sig { returns(T.nilable(String)) }
attr_accessor :sort_code
sig { params(account_number: T.nilable(String), sort_code: T.nilable(String)).void }
def initialize(account_number: nil, sort_code: nil); end
end
class Bancontact < Stripe::RequestParams; end
class Billie < Stripe::RequestParams; end
class BillingDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Billing address.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SetupIntent::UpdateParams::PaymentMethodData::BillingDetails::Address))))
}
attr_accessor :address
# Email address.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :email
# Full name.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :name
# Billing phone number (including extension).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :phone
# Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
sig { returns(T.nilable(String)) }
attr_accessor :tax_id
sig {
params(address: T.nilable(T.nilable(T.any(String, ::Stripe::SetupIntent::UpdateParams::PaymentMethodData::BillingDetails::Address))), email: T.nilable(T.nilable(String)), name: T.nilable(T.nilable(String)), phone: T.nilable(T.nilable(String)), tax_id: T.nilable(String)).void
}
def initialize(address: nil, email: nil, name: nil, phone: nil, tax_id: nil); end
end
class Blik < Stripe::RequestParams; end
class Boleto < Stripe::RequestParams
# The tax ID of the customer (CPF for individual consumers or CNPJ for businesses consumers)
sig { returns(String) }
attr_accessor :tax_id
sig { params(tax_id: String).void }
def initialize(tax_id: nil); end
end
class Cashapp < Stripe::RequestParams; end
class CustomerBalance < Stripe::RequestParams; end
class Eps < Stripe::RequestParams
# The customer's bank.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class Fpx < Stripe::RequestParams
# Account holder type for FPX transaction
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_type
# The customer's bank.
sig { returns(String) }
attr_accessor :bank
sig { params(account_holder_type: T.nilable(String), bank: String).void }
def initialize(account_holder_type: nil, bank: nil); end
end
class Giropay < Stripe::RequestParams; end
class Gopay < Stripe::RequestParams; end
class Grabpay < Stripe::RequestParams; end
class IdBankTransfer < Stripe::RequestParams
# Bank where the account is held.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class Ideal < Stripe::RequestParams
# The customer's bank. Only use this parameter for existing customers. Don't use it for new customers.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class InteracPresent < Stripe::RequestParams; end
class KakaoPay < Stripe::RequestParams; end
class Klarna < Stripe::RequestParams
class Dob < Stripe::RequestParams
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
# Customer's date of birth
sig {
returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Klarna::Dob))
}
attr_accessor :dob
sig {
params(dob: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Klarna::Dob)).void
}
def initialize(dob: nil); end
end
class Konbini < Stripe::RequestParams; end
class KrCard < Stripe::RequestParams; end
class Link < Stripe::RequestParams; end
class MbWay < Stripe::RequestParams; end
class Mobilepay < Stripe::RequestParams; end
class Multibanco < Stripe::RequestParams; end
class NaverPay < Stripe::RequestParams
# Whether to use Naver Pay points or a card to fund this transaction. If not provided, this defaults to `card`.
sig { returns(T.nilable(String)) }
attr_accessor :funding
sig { params(funding: T.nilable(String)).void }
def initialize(funding: nil); end
end
class NzBankAccount < Stripe::RequestParams
# The name on the bank account. Only required if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod’s billing details.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_name
# The account number for the bank account.
sig { returns(String) }
attr_accessor :account_number
# The numeric code for the bank account's bank.
sig { returns(String) }
attr_accessor :bank_code
# The numeric code for the bank account's bank branch.
sig { returns(String) }
attr_accessor :branch_code
# Attribute for param field reference
sig { returns(T.nilable(String)) }
attr_accessor :reference
# The suffix of the bank account number.
sig { returns(String) }
attr_accessor :suffix
sig {
params(account_holder_name: T.nilable(String), account_number: String, bank_code: String, branch_code: String, reference: T.nilable(String), suffix: String).void
}
def initialize(
account_holder_name: nil,
account_number: nil,
bank_code: nil,
branch_code: nil,
reference: nil,
suffix: nil
); end
end
class Oxxo < Stripe::RequestParams; end
class P24 < Stripe::RequestParams
# The customer's bank.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class PayByBank < Stripe::RequestParams; end
class Payco < Stripe::RequestParams; end
class Paynow < Stripe::RequestParams; end
class Paypal < Stripe::RequestParams; end
class Payto < Stripe::RequestParams
# The account number for the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Bank-State-Branch number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :bsb_number
# The PayID alias for the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :pay_id
sig {
params(account_number: T.nilable(String), bsb_number: T.nilable(String), pay_id: T.nilable(String)).void
}
def initialize(account_number: nil, bsb_number: nil, pay_id: nil); end
end
class Pix < Stripe::RequestParams; end
class Promptpay < Stripe::RequestParams; end
class Qris < Stripe::RequestParams; end
class RadarOptions < Stripe::RequestParams
# A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
sig { returns(T.nilable(String)) }
attr_accessor :session
sig { params(session: T.nilable(String)).void }
def initialize(session: nil); end
end
class Rechnung < Stripe::RequestParams
class Dob < Stripe::RequestParams
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
# Customer's date of birth
sig { returns(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Rechnung::Dob) }
attr_accessor :dob
sig {
params(dob: ::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Rechnung::Dob).void
}
def initialize(dob: nil); end
end
class RevolutPay < Stripe::RequestParams; end
class SamsungPay < Stripe::RequestParams; end
class Satispay < Stripe::RequestParams; end
class SepaDebit < Stripe::RequestParams
# IBAN of the bank account.
sig { returns(String) }
attr_accessor :iban
sig { params(iban: String).void }
def initialize(iban: nil); end
end
class Shopeepay < Stripe::RequestParams; end
class Sofort < Stripe::RequestParams
# Two-letter ISO code representing the country the bank account is located in.
sig { returns(String) }
attr_accessor :country
sig { params(country: String).void }
def initialize(country: nil); end
end
class StripeBalance < Stripe::RequestParams
# The connected account ID whose Stripe balance to use as the source of payment
sig { returns(T.nilable(String)) }
attr_accessor :account
# The [source_type](https://docs.stripe.com/api/balance/balance_object#balance_object-available-source_types) of the balance
sig { returns(T.nilable(String)) }
attr_accessor :source_type
sig { params(account: T.nilable(String), source_type: T.nilable(String)).void }
def initialize(account: nil, source_type: nil); end
end
class Swish < Stripe::RequestParams; end
class Twint < Stripe::RequestParams; end
class UsBankAccount < Stripe::RequestParams
# Account holder type: individual or company.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_type
# Account number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Account type: checkings or savings. Defaults to checking if omitted.
sig { returns(T.nilable(String)) }
attr_accessor :account_type
# The ID of a Financial Connections Account to use as a payment method.
sig { returns(T.nilable(String)) }
attr_accessor :financial_connections_account
# Routing number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :routing_number
sig {
params(account_holder_type: T.nilable(String), account_number: T.nilable(String), account_type: T.nilable(String), financial_connections_account: T.nilable(String), routing_number: T.nilable(String)).void
}
def initialize(
account_holder_type: nil,
account_number: nil,
account_type: nil,
financial_connections_account: nil,
routing_number: nil
); end
end
class WechatPay < Stripe::RequestParams; end
class Zip < Stripe::RequestParams; end
# If this is an `acss_debit` PaymentMethod, this hash contains details about the ACSS Debit payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::AcssDebit))
}
attr_accessor :acss_debit
# If this is an `affirm` PaymentMethod, this hash contains details about the Affirm payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Affirm)) }
attr_accessor :affirm
# If this is an `AfterpayClearpay` PaymentMethod, this hash contains details about the AfterpayClearpay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::AfterpayClearpay))
}
attr_accessor :afterpay_clearpay
# If this is an `Alipay` PaymentMethod, this hash contains details about the Alipay payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Alipay)) }
attr_accessor :alipay
# This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :allow_redisplay
# If this is a Alma PaymentMethod, this hash contains details about the Alma payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Alma)) }
attr_accessor :alma
# If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::AmazonPay))
}
attr_accessor :amazon_pay
# If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.
sig {
returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::AuBecsDebit))
}
attr_accessor :au_becs_debit
# If this is a `bacs_debit` PaymentMethod, this hash contains details about the Bacs Direct Debit bank account.
sig {
returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::BacsDebit))
}
attr_accessor :bacs_debit
# If this is a `bancontact` PaymentMethod, this hash contains details about the Bancontact payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Bancontact))
}
attr_accessor :bancontact
# If this is a `billie` PaymentMethod, this hash contains details about the Billie payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Billie)) }
attr_accessor :billie
# Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
sig {
returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::BillingDetails))
}
attr_accessor :billing_details
# If this is a `blik` PaymentMethod, this hash contains details about the BLIK payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Blik)) }
attr_accessor :blik
# If this is a `boleto` PaymentMethod, this hash contains details about the Boleto payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Boleto)) }
attr_accessor :boleto
# If this is a `cashapp` PaymentMethod, this hash contains details about the Cash App Pay payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Cashapp)) }
attr_accessor :cashapp
# If this is a `customer_balance` PaymentMethod, this hash contains details about the CustomerBalance payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::CustomerBalance))
}
attr_accessor :customer_balance
# If this is an `eps` PaymentMethod, this hash contains details about the EPS payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Eps)) }
attr_accessor :eps
# If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Fpx)) }
attr_accessor :fpx
# If this is a `giropay` PaymentMethod, this hash contains details about the Giropay payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Giropay)) }
attr_accessor :giropay
# If this is a Gopay PaymentMethod, this hash contains details about the Gopay payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Gopay)) }
attr_accessor :gopay
# If this is a `grabpay` PaymentMethod, this hash contains details about the GrabPay payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Grabpay)) }
attr_accessor :grabpay
# If this is an `IdBankTransfer` PaymentMethod, this hash contains details about the IdBankTransfer payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::IdBankTransfer))
}
attr_accessor :id_bank_transfer
# If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Ideal)) }
attr_accessor :ideal
# If this is an `interac_present` PaymentMethod, this hash contains details about the Interac Present payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::InteracPresent))
}
attr_accessor :interac_present
# If this is a `kakao_pay` PaymentMethod, this hash contains details about the Kakao Pay payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::KakaoPay)) }
attr_accessor :kakao_pay
# If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Klarna)) }
attr_accessor :klarna
# If this is a `konbini` PaymentMethod, this hash contains details about the Konbini payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Konbini)) }
attr_accessor :konbini
# If this is a `kr_card` PaymentMethod, this hash contains details about the Korean Card payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::KrCard)) }
attr_accessor :kr_card
# If this is an `Link` PaymentMethod, this hash contains details about the Link payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Link)) }
attr_accessor :link
# If this is a MB WAY PaymentMethod, this hash contains details about the MB WAY payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::MbWay)) }
attr_accessor :mb_way
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# If this is a `mobilepay` PaymentMethod, this hash contains details about the MobilePay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Mobilepay))
}
attr_accessor :mobilepay
# If this is a `multibanco` PaymentMethod, this hash contains details about the Multibanco payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Multibanco))
}
attr_accessor :multibanco
# If this is a `naver_pay` PaymentMethod, this hash contains details about the Naver Pay payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::NaverPay)) }
attr_accessor :naver_pay
# If this is an nz_bank_account PaymentMethod, this hash contains details about the nz_bank_account payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::NzBankAccount))
}
attr_accessor :nz_bank_account
# If this is an `oxxo` PaymentMethod, this hash contains details about the OXXO payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Oxxo)) }
attr_accessor :oxxo
# If this is a `p24` PaymentMethod, this hash contains details about the P24 payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::P24)) }
attr_accessor :p24
# If this is a `pay_by_bank` PaymentMethod, this hash contains details about the PayByBank payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::PayByBank))
}
attr_accessor :pay_by_bank
# If this is a `payco` PaymentMethod, this hash contains details about the PAYCO payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Payco)) }
attr_accessor :payco
# If this is a `paynow` PaymentMethod, this hash contains details about the PayNow payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Paynow)) }
attr_accessor :paynow
# If this is a `paypal` PaymentMethod, this hash contains details about the PayPal payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Paypal)) }
attr_accessor :paypal
# If this is a `payto` PaymentMethod, this hash contains details about the PayTo payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Payto)) }
attr_accessor :payto
# If this is a `pix` PaymentMethod, this hash contains details about the Pix payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Pix)) }
attr_accessor :pix
# If this is a `promptpay` PaymentMethod, this hash contains details about the PromptPay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Promptpay))
}
attr_accessor :promptpay
# If this is a `qris` PaymentMethod, this hash contains details about the QRIS payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Qris)) }
attr_accessor :qris
# Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
sig {
returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::RadarOptions))
}
attr_accessor :radar_options
# If this is a `rechnung` PaymentMethod, this hash contains details about the Rechnung payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Rechnung)) }
attr_accessor :rechnung
# If this is a `revolut_pay` PaymentMethod, this hash contains details about the Revolut Pay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::RevolutPay))
}
attr_accessor :revolut_pay
# If this is a `samsung_pay` PaymentMethod, this hash contains details about the SamsungPay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::SamsungPay))
}
attr_accessor :samsung_pay
# If this is a `satispay` PaymentMethod, this hash contains details about the Satispay payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Satispay)) }
attr_accessor :satispay
# If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account.
sig {
returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::SepaDebit))
}
attr_accessor :sepa_debit
# If this is a Shopeepay PaymentMethod, this hash contains details about the Shopeepay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Shopeepay))
}
attr_accessor :shopeepay
# If this is a `sofort` PaymentMethod, this hash contains details about the SOFORT payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Sofort)) }
attr_accessor :sofort
# This hash contains details about the Stripe balance payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::StripeBalance))
}
attr_accessor :stripe_balance
# If this is a `swish` PaymentMethod, this hash contains details about the Swish payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Swish)) }
attr_accessor :swish
# If this is a TWINT PaymentMethod, this hash contains details about the TWINT payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Twint)) }
attr_accessor :twint
# The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
sig { returns(String) }
attr_accessor :type
# If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::UsBankAccount))
}
attr_accessor :us_bank_account
# If this is an `wechat_pay` PaymentMethod, this hash contains details about the wechat_pay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::WechatPay))
}
attr_accessor :wechat_pay
# If this is a `zip` PaymentMethod, this hash contains details about the Zip payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Zip)) }
attr_accessor :zip
sig {
params(acss_debit: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::AcssDebit), affirm: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Affirm), afterpay_clearpay: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::AfterpayClearpay), alipay: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Alipay), allow_redisplay: T.nilable(String), alma: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Alma), amazon_pay: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::AmazonPay), au_becs_debit: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::AuBecsDebit), bacs_debit: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::BacsDebit), bancontact: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Bancontact), billie: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Billie), billing_details: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::BillingDetails), blik: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Blik), boleto: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Boleto), cashapp: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Cashapp), customer_balance: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::CustomerBalance), eps: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Eps), fpx: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Fpx), giropay: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Giropay), gopay: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Gopay), grabpay: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Grabpay), id_bank_transfer: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::IdBankTransfer), ideal: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Ideal), interac_present: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::InteracPresent), kakao_pay: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::KakaoPay), klarna: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Klarna), konbini: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Konbini), kr_card: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::KrCard), link: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Link), mb_way: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::MbWay), metadata: T.nilable(T::Hash[String, String]), mobilepay: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Mobilepay), multibanco: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Multibanco), naver_pay: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::NaverPay), nz_bank_account: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::NzBankAccount), oxxo: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Oxxo), p24: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::P24), pay_by_bank: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::PayByBank), payco: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Payco), paynow: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Paynow), paypal: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Paypal), payto: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Payto), pix: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Pix), promptpay: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Promptpay), qris: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Qris), radar_options: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::RadarOptions), rechnung: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Rechnung), revolut_pay: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::RevolutPay), samsung_pay: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::SamsungPay), satispay: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Satispay), sepa_debit: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::SepaDebit), shopeepay: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Shopeepay), sofort: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Sofort), stripe_balance: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::StripeBalance), swish: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Swish), twint: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Twint), type: String, us_bank_account: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::UsBankAccount), wechat_pay: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::WechatPay), zip: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData::Zip)).void
}
def initialize(
acss_debit: nil,
affirm: nil,
afterpay_clearpay: nil,
alipay: nil,
allow_redisplay: nil,
alma: nil,
amazon_pay: nil,
au_becs_debit: nil,
bacs_debit: nil,
bancontact: nil,
billie: nil,
billing_details: nil,
blik: nil,
boleto: nil,
cashapp: nil,
customer_balance: nil,
eps: nil,
fpx: nil,
giropay: nil,
gopay: nil,
grabpay: nil,
id_bank_transfer: nil,
ideal: nil,
interac_present: nil,
kakao_pay: nil,
klarna: nil,
konbini: nil,
kr_card: nil,
link: nil,
mb_way: nil,
metadata: nil,
mobilepay: nil,
multibanco: nil,
naver_pay: nil,
nz_bank_account: nil,
oxxo: nil,
p24: nil,
pay_by_bank: nil,
payco: nil,
paynow: nil,
paypal: nil,
payto: nil,
pix: nil,
promptpay: nil,
qris: nil,
radar_options: nil,
rechnung: nil,
revolut_pay: nil,
samsung_pay: nil,
satispay: nil,
sepa_debit: nil,
shopeepay: nil,
sofort: nil,
stripe_balance: nil,
swish: nil,
twint: nil,
type: nil,
us_bank_account: nil,
wechat_pay: nil,
zip: nil
); end
end
class PaymentMethodOptions < Stripe::RequestParams
class AcssDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# A URL for custom mandate text to render during confirmation step.
# The URL will be rendered with additional GET parameters `payment_intent` and `payment_intent_client_secret` when confirming a Payment Intent,
# or `setup_intent` and `setup_intent_client_secret` when confirming a Setup Intent.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :custom_mandate_url
# List of Stripe products where this mandate can be selected automatically.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :default_for
# Description of the mandate interval. Only required if 'payment_schedule' parameter is 'interval' or 'combined'.
sig { returns(T.nilable(String)) }
attr_accessor :interval_description
# Payment schedule for the mandate.
sig { returns(T.nilable(String)) }
attr_accessor :payment_schedule
# Transaction type of the mandate.
sig { returns(T.nilable(String)) }
attr_accessor :transaction_type
sig {
params(custom_mandate_url: T.nilable(T.nilable(String)), default_for: T.nilable(T::Array[String]), interval_description: T.nilable(String), payment_schedule: T.nilable(String), transaction_type: T.nilable(String)).void
}
def initialize(
custom_mandate_url: nil,
default_for: nil,
interval_description: nil,
payment_schedule: nil,
transaction_type: nil
); end
end
# 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).
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions::AcssDebit::MandateOptions))
}
attr_accessor :mandate_options
# Bank account verification method.
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(currency: T.nilable(String), mandate_options: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions::AcssDebit::MandateOptions), verification_method: T.nilable(String)).void
}
def initialize(currency: nil, mandate_options: nil, verification_method: nil); end
end
class AmazonPay < Stripe::RequestParams; end
class BacsDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'DDIC' or 'STRIPE'.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :reference_prefix
sig { params(reference_prefix: T.nilable(T.nilable(String))).void }
def initialize(reference_prefix: nil); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions::BacsDebit::MandateOptions))
}
attr_accessor :mandate_options
sig {
params(mandate_options: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions::BacsDebit::MandateOptions)).void
}
def initialize(mandate_options: nil); end
end
class Card < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Amount to be charged for future payments.
sig { returns(Integer) }
attr_accessor :amount
# One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.
sig { returns(String) }
attr_accessor :amount_type
# Currency in which future payments will be charged. 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).
sig { returns(String) }
attr_accessor :currency
# A description of the mandate or subscription that is meant to be displayed to the customer.
sig { returns(T.nilable(String)) }
attr_accessor :description
# End date of the mandate or subscription. If not provided, the mandate will be active until canceled. If provided, end date should be after start date.
sig { returns(T.nilable(Integer)) }
attr_accessor :end_date
# Specifies payment frequency. One of `day`, `week`, `month`, `year`, or `sporadic`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals between payments. For example, `interval=month` and `interval_count=3` indicates one payment every three months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks). This parameter is optional when `interval=sporadic`.
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_count
# Unique identifier for the mandate or subscription.
sig { returns(String) }
attr_accessor :reference
# Start date of the mandate or subscription. Start date should not be lesser than yesterday.
sig { returns(Integer) }
attr_accessor :start_date
# Specifies the type of mandates supported. Possible values are `india`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :supported_types
sig {
params(amount: Integer, amount_type: String, currency: String, description: T.nilable(String), end_date: T.nilable(Integer), interval: String, interval_count: T.nilable(Integer), reference: String, start_date: Integer, supported_types: T.nilable(T::Array[String])).void
}
def initialize(
amount: nil,
amount_type: nil,
currency: nil,
description: nil,
end_date: nil,
interval: nil,
interval_count: nil,
reference: nil,
start_date: nil,
supported_types: nil
); end
end
class ThreeDSecure < Stripe::RequestParams
class NetworkOptions < Stripe::RequestParams
class CartesBancaires < Stripe::RequestParams
# The cryptogram calculation algorithm used by the card Issuer's ACS
# to calculate the Authentication cryptogram. Also known as `cavvAlgorithm`.
# messageExtension: CB-AVALGO
sig { returns(String) }
attr_accessor :cb_avalgo
# The exemption indicator returned from Cartes Bancaires in the ARes.
# message extension: CB-EXEMPTION; string (4 characters)
# This is a 3 byte bitmap (low significant byte first and most significant
# bit first) that has been Base64 encoded
sig { returns(T.nilable(String)) }
attr_accessor :cb_exemption
# The risk score returned from Cartes Bancaires in the ARes.
# message extension: CB-SCORE; numeric value 0-99
sig { returns(T.nilable(Integer)) }
attr_accessor :cb_score
sig {
params(cb_avalgo: String, cb_exemption: T.nilable(String), cb_score: T.nilable(Integer)).void
}
def initialize(cb_avalgo: nil, cb_exemption: nil, cb_score: nil); end
end
# Cartes Bancaires-specific 3DS fields.
sig {
returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions::CartesBancaires))
}
attr_accessor :cartes_bancaires
sig {
params(cartes_bancaires: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions::CartesBancaires)).void
}
def initialize(cartes_bancaires: nil); end
end
# The `transStatus` returned from the card Issuer’s ACS in the ARes.
sig { returns(T.nilable(String)) }
attr_accessor :ares_trans_status
# The cryptogram, also known as the "authentication value" (AAV, CAVV or
# AEVV). This value is 20 bytes, base64-encoded into a 28-character string.
# (Most 3D Secure providers will return the base64-encoded version, which
# is what you should specify here.)
sig { returns(T.nilable(String)) }
attr_accessor :cryptogram
# The Electronic Commerce Indicator (ECI) is returned by your 3D Secure
# provider and indicates what degree of authentication was performed.
sig { returns(T.nilable(String)) }
attr_accessor :electronic_commerce_indicator
# Network specific 3DS fields. Network specific arguments require an
# explicit card brand choice. The parameter `payment_method_options.card.network``
# must be populated accordingly
sig {
returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions))
}
attr_accessor :network_options
# The challenge indicator (`threeDSRequestorChallengeInd`) which was requested in the
# AReq sent to the card Issuer's ACS. A string containing 2 digits from 01-99.
sig { returns(T.nilable(String)) }
attr_accessor :requestor_challenge_indicator
# For 3D Secure 1, the XID. For 3D Secure 2, the Directory Server
# Transaction ID (dsTransID).
sig { returns(T.nilable(String)) }
attr_accessor :transaction_id
# The version of 3D Secure that was performed.
sig { returns(T.nilable(String)) }
attr_accessor :version
sig {
params(ares_trans_status: T.nilable(String), cryptogram: T.nilable(String), electronic_commerce_indicator: T.nilable(String), network_options: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions), requestor_challenge_indicator: T.nilable(String), transaction_id: T.nilable(String), version: T.nilable(String)).void
}
def initialize(
ares_trans_status: nil,
cryptogram: nil,
electronic_commerce_indicator: nil,
network_options: nil,
requestor_challenge_indicator: nil,
transaction_id: nil,
version: nil
); end
end
# Configuration options for setting up an eMandate for cards issued in India.
sig {
returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions::Card::MandateOptions))
}
attr_accessor :mandate_options
# When specified, this parameter signals that a card has been collected
# as MOTO (Mail Order Telephone Order) and thus out of scope for SCA. This
# parameter can only be provided during confirmation.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :moto
# Selected network to process this SetupIntent on. Depends on the available networks of the card attached to the SetupIntent. Can be only set confirm-time.
sig { returns(T.nilable(String)) }
attr_accessor :network
# We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. If not provided, this value defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
sig { returns(T.nilable(String)) }
attr_accessor :request_three_d_secure
# If 3D Secure authentication was performed with a third-party provider,
# the authentication details to use for this setup.
sig {
returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions::Card::ThreeDSecure))
}
attr_accessor :three_d_secure
sig {
params(mandate_options: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions::Card::MandateOptions), moto: T.nilable(T::Boolean), network: T.nilable(String), request_three_d_secure: T.nilable(String), three_d_secure: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions::Card::ThreeDSecure)).void
}
def initialize(
mandate_options: nil,
moto: nil,
network: nil,
request_three_d_secure: nil,
three_d_secure: nil
); end
end
class CardPresent < Stripe::RequestParams; end
class Link < Stripe::RequestParams
# [Deprecated] This is a legacy parameter that no longer has any function.
sig { returns(T.nilable(String)) }
attr_accessor :persistent_token
sig { params(persistent_token: T.nilable(String)).void }
def initialize(persistent_token: nil); end
end
class Paypal < Stripe::RequestParams
# The PayPal Billing Agreement ID (BAID). This is an ID generated by PayPal which represents the mandate between the merchant and the customer.
sig { returns(T.nilable(String)) }
attr_accessor :billing_agreement_id
# Attribute for param field currency
sig { returns(T.nilable(String)) }
attr_accessor :currency
# The Stripe connected account IDs of the sellers on the platform for this transaction (optional). Only allowed when [separate charges and transfers](https://stripe.com/docs/connect/separate-charges-and-transfers) are used.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :subsellers
sig {
params(billing_agreement_id: T.nilable(String), currency: T.nilable(String), subsellers: T.nilable(T::Array[String])).void
}
def initialize(billing_agreement_id: nil, currency: nil, subsellers: nil); end
end
class Payto < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Amount that will be collected. It is required when `amount_type` is `fixed`.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# The type of amount that will be collected. The amount charged must be exact or up to the value of `amount` param for `fixed` or `maximum` type respectively.
sig { returns(T.nilable(String)) }
attr_accessor :amount_type
# Date, in YYYY-MM-DD format, after which payments will not be collected. Defaults to no end date.
sig { returns(T.nilable(String)) }
attr_accessor :end_date
# The periodicity at which payments will be collected.
sig { returns(T.nilable(String)) }
attr_accessor :payment_schedule
# The number of payments that will be made during a payment period. Defaults to 1 except for when `payment_schedule` is `adhoc`. In that case, it defaults to no limit.
sig { returns(T.nilable(Integer)) }
attr_accessor :payments_per_period
# The purpose for which payments are made. Defaults to retail.
sig { returns(T.nilable(String)) }
attr_accessor :purpose
# Date, in YYYY-MM-DD format, from which payments will be collected. Defaults to confirmation time.
sig { returns(T.nilable(String)) }
attr_accessor :start_date
sig {
params(amount: T.nilable(Integer), amount_type: T.nilable(String), end_date: T.nilable(String), payment_schedule: T.nilable(String), payments_per_period: T.nilable(Integer), purpose: T.nilable(String), start_date: T.nilable(String)).void
}
def initialize(
amount: nil,
amount_type: nil,
end_date: nil,
payment_schedule: nil,
payments_per_period: nil,
purpose: nil,
start_date: nil
); end
end
# Additional fields for Mandate creation.
sig {
returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions::Payto::MandateOptions))
}
attr_accessor :mandate_options
sig {
params(mandate_options: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions::Payto::MandateOptions)).void
}
def initialize(mandate_options: nil); end
end
class SepaDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'STRIPE'.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :reference_prefix
sig { params(reference_prefix: T.nilable(T.nilable(String))).void }
def initialize(reference_prefix: nil); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions::SepaDebit::MandateOptions))
}
attr_accessor :mandate_options
sig {
params(mandate_options: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions::SepaDebit::MandateOptions)).void
}
def initialize(mandate_options: nil); end
end
class UsBankAccount < Stripe::RequestParams
class FinancialConnections < Stripe::RequestParams
class Filters < Stripe::RequestParams
# The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :account_subcategories
# ID of the institution to use to filter for selectable accounts.
sig { returns(T.nilable(String)) }
attr_accessor :institution
sig {
params(account_subcategories: T.nilable(T::Array[String]), institution: T.nilable(String)).void
}
def initialize(account_subcategories: nil, institution: nil); end
end
class ManualEntry < Stripe::RequestParams
# Settings for configuring manual entry of account details.
sig { returns(String) }
attr_accessor :mode
sig { params(mode: String).void }
def initialize(mode: nil); end
end
# Provide filters for the linked accounts that the customer can select for the payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::Filters))
}
attr_accessor :filters
# Customize manual entry behavior
sig {
returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::ManualEntry))
}
attr_accessor :manual_entry
# The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :permissions
# List of data features that you would like to retrieve upon account creation.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :prefetch
# For webview integrations only. Upon completing OAuth login in the native browser, the user will be redirected to this URL to return to your app.
sig { returns(T.nilable(String)) }
attr_accessor :return_url
sig {
params(filters: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::Filters), manual_entry: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::ManualEntry), permissions: T.nilable(T::Array[String]), prefetch: T.nilable(T::Array[String]), return_url: T.nilable(String)).void
}
def initialize(
filters: nil,
manual_entry: nil,
permissions: nil,
prefetch: nil,
return_url: nil
); end
end
class MandateOptions < Stripe::RequestParams
# The method used to collect offline mandate customer acceptance.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :collection_method
sig { params(collection_method: T.nilable(T.nilable(String))).void }
def initialize(collection_method: nil); end
end
class Networks < Stripe::RequestParams
# Triggers validations to run across the selected networks
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Array[String])).void }
def initialize(requested: nil); end
end
# Additional fields for Financial Connections Session creation
sig {
returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections))
}
attr_accessor :financial_connections
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions::UsBankAccount::MandateOptions))
}
attr_accessor :mandate_options
# Additional fields for network related functions
sig {
returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions::UsBankAccount::Networks))
}
attr_accessor :networks
# Bank account verification method.
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(financial_connections: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections), mandate_options: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions::UsBankAccount::MandateOptions), networks: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions::UsBankAccount::Networks), verification_method: T.nilable(String)).void
}
def initialize(
financial_connections: nil,
mandate_options: nil,
networks: nil,
verification_method: nil
); end
end
# If this is a `acss_debit` SetupIntent, this sub-hash contains details about the ACSS Debit payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions::AcssDebit))
}
attr_accessor :acss_debit
# If this is a `amazon_pay` SetupIntent, this sub-hash contains details about the AmazonPay payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions::AmazonPay))
}
attr_accessor :amazon_pay
# If this is a `bacs_debit` SetupIntent, this sub-hash contains details about the Bacs Debit payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions::BacsDebit))
}
attr_accessor :bacs_debit
# Configuration for any card setup attempted on this SetupIntent.
sig { returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions::Card)) }
attr_accessor :card
# If this is a `card_present` PaymentMethod, this sub-hash contains details about the card-present payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions::CardPresent))
}
attr_accessor :card_present
# If this is a `link` PaymentMethod, this sub-hash contains details about the Link payment method options.
sig { returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions::Link)) }
attr_accessor :link
# If this is a `paypal` PaymentMethod, this sub-hash contains details about the PayPal payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions::Paypal))
}
attr_accessor :paypal
# If this is a `payto` SetupIntent, this sub-hash contains details about the PayTo payment method options.
sig { returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions::Payto)) }
attr_accessor :payto
# If this is a `sepa_debit` SetupIntent, this sub-hash contains details about the SEPA Debit payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions::SepaDebit))
}
attr_accessor :sepa_debit
# If this is a `us_bank_account` SetupIntent, this sub-hash contains details about the US bank account payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions::UsBankAccount))
}
attr_accessor :us_bank_account
sig {
params(acss_debit: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions::AcssDebit), amazon_pay: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions::AmazonPay), bacs_debit: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions::BacsDebit), card: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions::Card), card_present: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions::CardPresent), link: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions::Link), paypal: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions::Paypal), payto: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions::Payto), sepa_debit: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions::SepaDebit), us_bank_account: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions::UsBankAccount)).void
}
def initialize(
acss_debit: nil,
amazon_pay: nil,
bacs_debit: nil,
card: nil,
card_present: nil,
link: nil,
paypal: nil,
payto: nil,
sepa_debit: nil,
us_bank_account: nil
); end
end
# If present, the SetupIntent's payment method will be attached to the in-context Stripe Account.
#
# It can only be used for this Stripe Account’s own money movement flows like InboundTransfer and OutboundTransfers. It cannot be set to true when setting up a PaymentMethod for a Customer, and defaults to false when attaching a PaymentMethod to a Customer.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :attach_to_self
# ID of the Customer this SetupIntent belongs to, if one exists.
#
# If present, the SetupIntent's payment method will be attached to the Customer on successful setup. Payment methods attached to other Customers cannot be used with this SetupIntent.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# ID of the Account this SetupIntent belongs to, if one exists.
#
# If present, the SetupIntent's payment method will be attached to the Account on successful setup. Payment methods attached to other Accounts cannot be used with this SetupIntent.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Indicates the directions of money movement for which this payment method is intended to be used.
#
# Include `inbound` if you intend to use the payment method as the origin to pull funds from. Include `outbound` if you intend to use the payment method as the destination to send funds to. You can include both if you intend to use the payment method for both purposes.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :flow_directions
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# ID of the payment method (a PaymentMethod, Card, or saved Source object) to attach to this SetupIntent. To unset this field to null, pass in an empty string.
sig { returns(T.nilable(String)) }
attr_accessor :payment_method
# The ID of the [payment method configuration](https://stripe.com/docs/api/payment_method_configurations) to use with this SetupIntent.
sig { returns(T.nilable(String)) }
attr_accessor :payment_method_configuration
# When included, this hash creates a PaymentMethod that is set as the [`payment_method`](https://stripe.com/docs/api/setup_intents/object#setup_intent_object-payment_method)
# value in the SetupIntent.
sig { returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData)) }
attr_accessor :payment_method_data
# Payment method-specific configuration for this SetupIntent.
sig { returns(T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions)) }
attr_accessor :payment_method_options
# The list of payment method types (for example, card) that this SetupIntent can set up. If you don't provide this, Stripe will dynamically show relevant payment methods from your [payment method settings](https://dashboard.stripe.com/settings/payment_methods).
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :payment_method_types
sig {
params(attach_to_self: T.nilable(T::Boolean), customer: T.nilable(String), customer_account: T.nilable(String), description: T.nilable(String), expand: T.nilable(T::Array[String]), flow_directions: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), payment_method: T.nilable(String), payment_method_configuration: T.nilable(String), payment_method_data: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodData), payment_method_options: T.nilable(::Stripe::SetupIntent::UpdateParams::PaymentMethodOptions), payment_method_types: T.nilable(T::Array[String])).void
}
def initialize(
attach_to_self: nil,
customer: nil,
customer_account: nil,
description: nil,
expand: nil,
flow_directions: nil,
metadata: nil,
payment_method: nil,
payment_method_configuration: nil,
payment_method_data: nil,
payment_method_options: nil,
payment_method_types: nil
); end
end
class CancelParams < Stripe::RequestParams
# Reason for canceling this SetupIntent. Possible values are: `abandoned`, `requested_by_customer`, or `duplicate`
sig { returns(T.nilable(String)) }
attr_accessor :cancellation_reason
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig {
params(cancellation_reason: T.nilable(String), expand: T.nilable(T::Array[String])).void
}
def initialize(cancellation_reason: nil, expand: nil); end
end
class ConfirmParams < Stripe::RequestParams
class MandateData < Stripe::RequestParams
class CustomerAcceptance < Stripe::RequestParams
class Offline < Stripe::RequestParams; end
class Online < Stripe::RequestParams
# The IP address from which the Mandate was accepted by the customer.
sig { returns(T.nilable(String)) }
attr_accessor :ip_address
# The user agent of the browser from which the Mandate was accepted by the customer.
sig { returns(T.nilable(String)) }
attr_accessor :user_agent
sig { params(ip_address: T.nilable(String), user_agent: T.nilable(String)).void }
def initialize(ip_address: nil, user_agent: nil); end
end
# The time at which the customer accepted the Mandate.
sig { returns(T.nilable(Integer)) }
attr_accessor :accepted_at
# If this is a Mandate accepted offline, this hash contains details about the offline acceptance.
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::MandateData::CustomerAcceptance::Offline))
}
attr_accessor :offline
# If this is a Mandate accepted online, this hash contains details about the online acceptance.
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::MandateData::CustomerAcceptance::Online))
}
attr_accessor :online
# The type of customer acceptance information included with the Mandate. One of `online` or `offline`.
sig { returns(String) }
attr_accessor :type
sig {
params(accepted_at: T.nilable(Integer), offline: T.nilable(::Stripe::SetupIntent::ConfirmParams::MandateData::CustomerAcceptance::Offline), online: T.nilable(::Stripe::SetupIntent::ConfirmParams::MandateData::CustomerAcceptance::Online), type: String).void
}
def initialize(accepted_at: nil, offline: nil, online: nil, type: nil); end
end
# This hash contains details about the customer acceptance of the Mandate.
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::MandateData::CustomerAcceptance))
}
attr_accessor :customer_acceptance
sig {
params(customer_acceptance: T.nilable(::Stripe::SetupIntent::ConfirmParams::MandateData::CustomerAcceptance)).void
}
def initialize(customer_acceptance: nil); end
end
class PaymentMethodData < Stripe::RequestParams
class AcssDebit < Stripe::RequestParams
# Customer's bank account number.
sig { returns(String) }
attr_accessor :account_number
# Institution number of the customer's bank.
sig { returns(String) }
attr_accessor :institution_number
# Transit number of the customer's bank.
sig { returns(String) }
attr_accessor :transit_number
sig {
params(account_number: String, institution_number: String, transit_number: String).void
}
def initialize(account_number: nil, institution_number: nil, transit_number: nil); end
end
class Affirm < Stripe::RequestParams; end
class AfterpayClearpay < Stripe::RequestParams; end
class Alipay < Stripe::RequestParams; end
class Alma < Stripe::RequestParams; end
class AmazonPay < Stripe::RequestParams; end
class AuBecsDebit < Stripe::RequestParams
# The account number for the bank account.
sig { returns(String) }
attr_accessor :account_number
# Bank-State-Branch number of the bank account.
sig { returns(String) }
attr_accessor :bsb_number
sig { params(account_number: String, bsb_number: String).void }
def initialize(account_number: nil, bsb_number: nil); end
end
class BacsDebit < Stripe::RequestParams
# Account number of the bank account that the funds will be debited from.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Sort code of the bank account. (e.g., `10-20-30`)
sig { returns(T.nilable(String)) }
attr_accessor :sort_code
sig { params(account_number: T.nilable(String), sort_code: T.nilable(String)).void }
def initialize(account_number: nil, sort_code: nil); end
end
class Bancontact < Stripe::RequestParams; end
class Billie < Stripe::RequestParams; end
class BillingDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Billing address.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::BillingDetails::Address))))
}
attr_accessor :address
# Email address.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :email
# Full name.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :name
# Billing phone number (including extension).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :phone
# Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
sig { returns(T.nilable(String)) }
attr_accessor :tax_id
sig {
params(address: T.nilable(T.nilable(T.any(String, ::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::BillingDetails::Address))), email: T.nilable(T.nilable(String)), name: T.nilable(T.nilable(String)), phone: T.nilable(T.nilable(String)), tax_id: T.nilable(String)).void
}
def initialize(address: nil, email: nil, name: nil, phone: nil, tax_id: nil); end
end
class Blik < Stripe::RequestParams; end
class Boleto < Stripe::RequestParams
# The tax ID of the customer (CPF for individual consumers or CNPJ for businesses consumers)
sig { returns(String) }
attr_accessor :tax_id
sig { params(tax_id: String).void }
def initialize(tax_id: nil); end
end
class Cashapp < Stripe::RequestParams; end
class CustomerBalance < Stripe::RequestParams; end
class Eps < Stripe::RequestParams
# The customer's bank.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class Fpx < Stripe::RequestParams
# Account holder type for FPX transaction
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_type
# The customer's bank.
sig { returns(String) }
attr_accessor :bank
sig { params(account_holder_type: T.nilable(String), bank: String).void }
def initialize(account_holder_type: nil, bank: nil); end
end
class Giropay < Stripe::RequestParams; end
class Gopay < Stripe::RequestParams; end
class Grabpay < Stripe::RequestParams; end
class IdBankTransfer < Stripe::RequestParams
# Bank where the account is held.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class Ideal < Stripe::RequestParams
# The customer's bank. Only use this parameter for existing customers. Don't use it for new customers.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class InteracPresent < Stripe::RequestParams; end
class KakaoPay < Stripe::RequestParams; end
class Klarna < Stripe::RequestParams
class Dob < Stripe::RequestParams
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
# Customer's date of birth
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Klarna::Dob))
}
attr_accessor :dob
sig {
params(dob: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Klarna::Dob)).void
}
def initialize(dob: nil); end
end
class Konbini < Stripe::RequestParams; end
class KrCard < Stripe::RequestParams; end
class Link < Stripe::RequestParams; end
class MbWay < Stripe::RequestParams; end
class Mobilepay < Stripe::RequestParams; end
class Multibanco < Stripe::RequestParams; end
class NaverPay < Stripe::RequestParams
# Whether to use Naver Pay points or a card to fund this transaction. If not provided, this defaults to `card`.
sig { returns(T.nilable(String)) }
attr_accessor :funding
sig { params(funding: T.nilable(String)).void }
def initialize(funding: nil); end
end
class NzBankAccount < Stripe::RequestParams
# The name on the bank account. Only required if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod’s billing details.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_name
# The account number for the bank account.
sig { returns(String) }
attr_accessor :account_number
# The numeric code for the bank account's bank.
sig { returns(String) }
attr_accessor :bank_code
# The numeric code for the bank account's bank branch.
sig { returns(String) }
attr_accessor :branch_code
# Attribute for param field reference
sig { returns(T.nilable(String)) }
attr_accessor :reference
# The suffix of the bank account number.
sig { returns(String) }
attr_accessor :suffix
sig {
params(account_holder_name: T.nilable(String), account_number: String, bank_code: String, branch_code: String, reference: T.nilable(String), suffix: String).void
}
def initialize(
account_holder_name: nil,
account_number: nil,
bank_code: nil,
branch_code: nil,
reference: nil,
suffix: nil
); end
end
class Oxxo < Stripe::RequestParams; end
class P24 < Stripe::RequestParams
# The customer's bank.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class PayByBank < Stripe::RequestParams; end
class Payco < Stripe::RequestParams; end
class Paynow < Stripe::RequestParams; end
class Paypal < Stripe::RequestParams; end
class Payto < Stripe::RequestParams
# The account number for the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Bank-State-Branch number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :bsb_number
# The PayID alias for the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :pay_id
sig {
params(account_number: T.nilable(String), bsb_number: T.nilable(String), pay_id: T.nilable(String)).void
}
def initialize(account_number: nil, bsb_number: nil, pay_id: nil); end
end
class Pix < Stripe::RequestParams; end
class Promptpay < Stripe::RequestParams; end
class Qris < Stripe::RequestParams; end
class RadarOptions < Stripe::RequestParams
# A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
sig { returns(T.nilable(String)) }
attr_accessor :session
sig { params(session: T.nilable(String)).void }
def initialize(session: nil); end
end
class Rechnung < Stripe::RequestParams
class Dob < Stripe::RequestParams
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
# Customer's date of birth
sig { returns(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Rechnung::Dob) }
attr_accessor :dob
sig {
params(dob: ::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Rechnung::Dob).void
}
def initialize(dob: nil); end
end
class RevolutPay < Stripe::RequestParams; end
class SamsungPay < Stripe::RequestParams; end
class Satispay < Stripe::RequestParams; end
class SepaDebit < Stripe::RequestParams
# IBAN of the bank account.
sig { returns(String) }
attr_accessor :iban
sig { params(iban: String).void }
def initialize(iban: nil); end
end
class Shopeepay < Stripe::RequestParams; end
class Sofort < Stripe::RequestParams
# Two-letter ISO code representing the country the bank account is located in.
sig { returns(String) }
attr_accessor :country
sig { params(country: String).void }
def initialize(country: nil); end
end
class StripeBalance < Stripe::RequestParams
# The connected account ID whose Stripe balance to use as the source of payment
sig { returns(T.nilable(String)) }
attr_accessor :account
# The [source_type](https://docs.stripe.com/api/balance/balance_object#balance_object-available-source_types) of the balance
sig { returns(T.nilable(String)) }
attr_accessor :source_type
sig { params(account: T.nilable(String), source_type: T.nilable(String)).void }
def initialize(account: nil, source_type: nil); end
end
class Swish < Stripe::RequestParams; end
class Twint < Stripe::RequestParams; end
class UsBankAccount < Stripe::RequestParams
# Account holder type: individual or company.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_type
# Account number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Account type: checkings or savings. Defaults to checking if omitted.
sig { returns(T.nilable(String)) }
attr_accessor :account_type
# The ID of a Financial Connections Account to use as a payment method.
sig { returns(T.nilable(String)) }
attr_accessor :financial_connections_account
# Routing number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :routing_number
sig {
params(account_holder_type: T.nilable(String), account_number: T.nilable(String), account_type: T.nilable(String), financial_connections_account: T.nilable(String), routing_number: T.nilable(String)).void
}
def initialize(
account_holder_type: nil,
account_number: nil,
account_type: nil,
financial_connections_account: nil,
routing_number: nil
); end
end
class WechatPay < Stripe::RequestParams; end
class Zip < Stripe::RequestParams; end
# If this is an `acss_debit` PaymentMethod, this hash contains details about the ACSS Debit payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::AcssDebit))
}
attr_accessor :acss_debit
# If this is an `affirm` PaymentMethod, this hash contains details about the Affirm payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Affirm)) }
attr_accessor :affirm
# If this is an `AfterpayClearpay` PaymentMethod, this hash contains details about the AfterpayClearpay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::AfterpayClearpay))
}
attr_accessor :afterpay_clearpay
# If this is an `Alipay` PaymentMethod, this hash contains details about the Alipay payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Alipay)) }
attr_accessor :alipay
# This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :allow_redisplay
# If this is a Alma PaymentMethod, this hash contains details about the Alma payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Alma)) }
attr_accessor :alma
# If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::AmazonPay))
}
attr_accessor :amazon_pay
# If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::AuBecsDebit))
}
attr_accessor :au_becs_debit
# If this is a `bacs_debit` PaymentMethod, this hash contains details about the Bacs Direct Debit bank account.
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::BacsDebit))
}
attr_accessor :bacs_debit
# If this is a `bancontact` PaymentMethod, this hash contains details about the Bancontact payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Bancontact))
}
attr_accessor :bancontact
# If this is a `billie` PaymentMethod, this hash contains details about the Billie payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Billie)) }
attr_accessor :billie
# Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::BillingDetails))
}
attr_accessor :billing_details
# If this is a `blik` PaymentMethod, this hash contains details about the BLIK payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Blik)) }
attr_accessor :blik
# If this is a `boleto` PaymentMethod, this hash contains details about the Boleto payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Boleto)) }
attr_accessor :boleto
# If this is a `cashapp` PaymentMethod, this hash contains details about the Cash App Pay payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Cashapp)) }
attr_accessor :cashapp
# If this is a `customer_balance` PaymentMethod, this hash contains details about the CustomerBalance payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::CustomerBalance))
}
attr_accessor :customer_balance
# If this is an `eps` PaymentMethod, this hash contains details about the EPS payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Eps)) }
attr_accessor :eps
# If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Fpx)) }
attr_accessor :fpx
# If this is a `giropay` PaymentMethod, this hash contains details about the Giropay payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Giropay)) }
attr_accessor :giropay
# If this is a Gopay PaymentMethod, this hash contains details about the Gopay payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Gopay)) }
attr_accessor :gopay
# If this is a `grabpay` PaymentMethod, this hash contains details about the GrabPay payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Grabpay)) }
attr_accessor :grabpay
# If this is an `IdBankTransfer` PaymentMethod, this hash contains details about the IdBankTransfer payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::IdBankTransfer))
}
attr_accessor :id_bank_transfer
# If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Ideal)) }
attr_accessor :ideal
# If this is an `interac_present` PaymentMethod, this hash contains details about the Interac Present payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::InteracPresent))
}
attr_accessor :interac_present
# If this is a `kakao_pay` PaymentMethod, this hash contains details about the Kakao Pay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::KakaoPay))
}
attr_accessor :kakao_pay
# If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Klarna)) }
attr_accessor :klarna
# If this is a `konbini` PaymentMethod, this hash contains details about the Konbini payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Konbini)) }
attr_accessor :konbini
# If this is a `kr_card` PaymentMethod, this hash contains details about the Korean Card payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::KrCard)) }
attr_accessor :kr_card
# If this is an `Link` PaymentMethod, this hash contains details about the Link payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Link)) }
attr_accessor :link
# If this is a MB WAY PaymentMethod, this hash contains details about the MB WAY payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::MbWay)) }
attr_accessor :mb_way
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# If this is a `mobilepay` PaymentMethod, this hash contains details about the MobilePay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Mobilepay))
}
attr_accessor :mobilepay
# If this is a `multibanco` PaymentMethod, this hash contains details about the Multibanco payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Multibanco))
}
attr_accessor :multibanco
# If this is a `naver_pay` PaymentMethod, this hash contains details about the Naver Pay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::NaverPay))
}
attr_accessor :naver_pay
# If this is an nz_bank_account PaymentMethod, this hash contains details about the nz_bank_account payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::NzBankAccount))
}
attr_accessor :nz_bank_account
# If this is an `oxxo` PaymentMethod, this hash contains details about the OXXO payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Oxxo)) }
attr_accessor :oxxo
# If this is a `p24` PaymentMethod, this hash contains details about the P24 payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::P24)) }
attr_accessor :p24
# If this is a `pay_by_bank` PaymentMethod, this hash contains details about the PayByBank payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::PayByBank))
}
attr_accessor :pay_by_bank
# If this is a `payco` PaymentMethod, this hash contains details about the PAYCO payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Payco)) }
attr_accessor :payco
# If this is a `paynow` PaymentMethod, this hash contains details about the PayNow payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Paynow)) }
attr_accessor :paynow
# If this is a `paypal` PaymentMethod, this hash contains details about the PayPal payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Paypal)) }
attr_accessor :paypal
# If this is a `payto` PaymentMethod, this hash contains details about the PayTo payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Payto)) }
attr_accessor :payto
# If this is a `pix` PaymentMethod, this hash contains details about the Pix payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Pix)) }
attr_accessor :pix
# If this is a `promptpay` PaymentMethod, this hash contains details about the PromptPay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Promptpay))
}
attr_accessor :promptpay
# If this is a `qris` PaymentMethod, this hash contains details about the QRIS payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Qris)) }
attr_accessor :qris
# Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::RadarOptions))
}
attr_accessor :radar_options
# If this is a `rechnung` PaymentMethod, this hash contains details about the Rechnung payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Rechnung))
}
attr_accessor :rechnung
# If this is a `revolut_pay` PaymentMethod, this hash contains details about the Revolut Pay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::RevolutPay))
}
attr_accessor :revolut_pay
# If this is a `samsung_pay` PaymentMethod, this hash contains details about the SamsungPay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::SamsungPay))
}
attr_accessor :samsung_pay
# If this is a `satispay` PaymentMethod, this hash contains details about the Satispay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Satispay))
}
attr_accessor :satispay
# If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account.
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::SepaDebit))
}
attr_accessor :sepa_debit
# If this is a Shopeepay PaymentMethod, this hash contains details about the Shopeepay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Shopeepay))
}
attr_accessor :shopeepay
# If this is a `sofort` PaymentMethod, this hash contains details about the SOFORT payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Sofort)) }
attr_accessor :sofort
# This hash contains details about the Stripe balance payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::StripeBalance))
}
attr_accessor :stripe_balance
# If this is a `swish` PaymentMethod, this hash contains details about the Swish payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Swish)) }
attr_accessor :swish
# If this is a TWINT PaymentMethod, this hash contains details about the TWINT payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Twint)) }
attr_accessor :twint
# The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
sig { returns(String) }
attr_accessor :type
# If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::UsBankAccount))
}
attr_accessor :us_bank_account
# If this is an `wechat_pay` PaymentMethod, this hash contains details about the wechat_pay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::WechatPay))
}
attr_accessor :wechat_pay
# If this is a `zip` PaymentMethod, this hash contains details about the Zip payment method.
sig { returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Zip)) }
attr_accessor :zip
sig {
params(acss_debit: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::AcssDebit), affirm: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Affirm), afterpay_clearpay: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::AfterpayClearpay), alipay: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Alipay), allow_redisplay: T.nilable(String), alma: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Alma), amazon_pay: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::AmazonPay), au_becs_debit: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::AuBecsDebit), bacs_debit: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::BacsDebit), bancontact: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Bancontact), billie: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Billie), billing_details: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::BillingDetails), blik: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Blik), boleto: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Boleto), cashapp: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Cashapp), customer_balance: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::CustomerBalance), eps: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Eps), fpx: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Fpx), giropay: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Giropay), gopay: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Gopay), grabpay: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Grabpay), id_bank_transfer: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::IdBankTransfer), ideal: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Ideal), interac_present: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::InteracPresent), kakao_pay: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::KakaoPay), klarna: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Klarna), konbini: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Konbini), kr_card: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::KrCard), link: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Link), mb_way: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::MbWay), metadata: T.nilable(T::Hash[String, String]), mobilepay: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Mobilepay), multibanco: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Multibanco), naver_pay: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::NaverPay), nz_bank_account: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::NzBankAccount), oxxo: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Oxxo), p24: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::P24), pay_by_bank: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::PayByBank), payco: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Payco), paynow: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Paynow), paypal: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Paypal), payto: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Payto), pix: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Pix), promptpay: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Promptpay), qris: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Qris), radar_options: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::RadarOptions), rechnung: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Rechnung), revolut_pay: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::RevolutPay), samsung_pay: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::SamsungPay), satispay: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Satispay), sepa_debit: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::SepaDebit), shopeepay: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Shopeepay), sofort: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Sofort), stripe_balance: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::StripeBalance), swish: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Swish), twint: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Twint), type: String, us_bank_account: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::UsBankAccount), wechat_pay: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::WechatPay), zip: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData::Zip)).void
}
def initialize(
acss_debit: nil,
affirm: nil,
afterpay_clearpay: nil,
alipay: nil,
allow_redisplay: nil,
alma: nil,
amazon_pay: nil,
au_becs_debit: nil,
bacs_debit: nil,
bancontact: nil,
billie: nil,
billing_details: nil,
blik: nil,
boleto: nil,
cashapp: nil,
customer_balance: nil,
eps: nil,
fpx: nil,
giropay: nil,
gopay: nil,
grabpay: nil,
id_bank_transfer: nil,
ideal: nil,
interac_present: nil,
kakao_pay: nil,
klarna: nil,
konbini: nil,
kr_card: nil,
link: nil,
mb_way: nil,
metadata: nil,
mobilepay: nil,
multibanco: nil,
naver_pay: nil,
nz_bank_account: nil,
oxxo: nil,
p24: nil,
pay_by_bank: nil,
payco: nil,
paynow: nil,
paypal: nil,
payto: nil,
pix: nil,
promptpay: nil,
qris: nil,
radar_options: nil,
rechnung: nil,
revolut_pay: nil,
samsung_pay: nil,
satispay: nil,
sepa_debit: nil,
shopeepay: nil,
sofort: nil,
stripe_balance: nil,
swish: nil,
twint: nil,
type: nil,
us_bank_account: nil,
wechat_pay: nil,
zip: nil
); end
end
class PaymentMethodOptions < Stripe::RequestParams
class AcssDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# A URL for custom mandate text to render during confirmation step.
# The URL will be rendered with additional GET parameters `payment_intent` and `payment_intent_client_secret` when confirming a Payment Intent,
# or `setup_intent` and `setup_intent_client_secret` when confirming a Setup Intent.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :custom_mandate_url
# List of Stripe products where this mandate can be selected automatically.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :default_for
# Description of the mandate interval. Only required if 'payment_schedule' parameter is 'interval' or 'combined'.
sig { returns(T.nilable(String)) }
attr_accessor :interval_description
# Payment schedule for the mandate.
sig { returns(T.nilable(String)) }
attr_accessor :payment_schedule
# Transaction type of the mandate.
sig { returns(T.nilable(String)) }
attr_accessor :transaction_type
sig {
params(custom_mandate_url: T.nilable(T.nilable(String)), default_for: T.nilable(T::Array[String]), interval_description: T.nilable(String), payment_schedule: T.nilable(String), transaction_type: T.nilable(String)).void
}
def initialize(
custom_mandate_url: nil,
default_for: nil,
interval_description: nil,
payment_schedule: nil,
transaction_type: nil
); end
end
# 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).
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions::AcssDebit::MandateOptions))
}
attr_accessor :mandate_options
# Bank account verification method.
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(currency: T.nilable(String), mandate_options: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions::AcssDebit::MandateOptions), verification_method: T.nilable(String)).void
}
def initialize(currency: nil, mandate_options: nil, verification_method: nil); end
end
class AmazonPay < Stripe::RequestParams; end
class BacsDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'DDIC' or 'STRIPE'.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :reference_prefix
sig { params(reference_prefix: T.nilable(T.nilable(String))).void }
def initialize(reference_prefix: nil); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions::BacsDebit::MandateOptions))
}
attr_accessor :mandate_options
sig {
params(mandate_options: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions::BacsDebit::MandateOptions)).void
}
def initialize(mandate_options: nil); end
end
class Card < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Amount to be charged for future payments.
sig { returns(Integer) }
attr_accessor :amount
# One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.
sig { returns(String) }
attr_accessor :amount_type
# Currency in which future payments will be charged. 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).
sig { returns(String) }
attr_accessor :currency
# A description of the mandate or subscription that is meant to be displayed to the customer.
sig { returns(T.nilable(String)) }
attr_accessor :description
# End date of the mandate or subscription. If not provided, the mandate will be active until canceled. If provided, end date should be after start date.
sig { returns(T.nilable(Integer)) }
attr_accessor :end_date
# Specifies payment frequency. One of `day`, `week`, `month`, `year`, or `sporadic`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals between payments. For example, `interval=month` and `interval_count=3` indicates one payment every three months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks). This parameter is optional when `interval=sporadic`.
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_count
# Unique identifier for the mandate or subscription.
sig { returns(String) }
attr_accessor :reference
# Start date of the mandate or subscription. Start date should not be lesser than yesterday.
sig { returns(Integer) }
attr_accessor :start_date
# Specifies the type of mandates supported. Possible values are `india`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :supported_types
sig {
params(amount: Integer, amount_type: String, currency: String, description: T.nilable(String), end_date: T.nilable(Integer), interval: String, interval_count: T.nilable(Integer), reference: String, start_date: Integer, supported_types: T.nilable(T::Array[String])).void
}
def initialize(
amount: nil,
amount_type: nil,
currency: nil,
description: nil,
end_date: nil,
interval: nil,
interval_count: nil,
reference: nil,
start_date: nil,
supported_types: nil
); end
end
class ThreeDSecure < Stripe::RequestParams
class NetworkOptions < Stripe::RequestParams
class CartesBancaires < Stripe::RequestParams
# The cryptogram calculation algorithm used by the card Issuer's ACS
# to calculate the Authentication cryptogram. Also known as `cavvAlgorithm`.
# messageExtension: CB-AVALGO
sig { returns(String) }
attr_accessor :cb_avalgo
# The exemption indicator returned from Cartes Bancaires in the ARes.
# message extension: CB-EXEMPTION; string (4 characters)
# This is a 3 byte bitmap (low significant byte first and most significant
# bit first) that has been Base64 encoded
sig { returns(T.nilable(String)) }
attr_accessor :cb_exemption
# The risk score returned from Cartes Bancaires in the ARes.
# message extension: CB-SCORE; numeric value 0-99
sig { returns(T.nilable(Integer)) }
attr_accessor :cb_score
sig {
params(cb_avalgo: String, cb_exemption: T.nilable(String), cb_score: T.nilable(Integer)).void
}
def initialize(cb_avalgo: nil, cb_exemption: nil, cb_score: nil); end
end
# Cartes Bancaires-specific 3DS fields.
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions::CartesBancaires))
}
attr_accessor :cartes_bancaires
sig {
params(cartes_bancaires: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions::CartesBancaires)).void
}
def initialize(cartes_bancaires: nil); end
end
# The `transStatus` returned from the card Issuer’s ACS in the ARes.
sig { returns(T.nilable(String)) }
attr_accessor :ares_trans_status
# The cryptogram, also known as the "authentication value" (AAV, CAVV or
# AEVV). This value is 20 bytes, base64-encoded into a 28-character string.
# (Most 3D Secure providers will return the base64-encoded version, which
# is what you should specify here.)
sig { returns(T.nilable(String)) }
attr_accessor :cryptogram
# The Electronic Commerce Indicator (ECI) is returned by your 3D Secure
# provider and indicates what degree of authentication was performed.
sig { returns(T.nilable(String)) }
attr_accessor :electronic_commerce_indicator
# Network specific 3DS fields. Network specific arguments require an
# explicit card brand choice. The parameter `payment_method_options.card.network``
# must be populated accordingly
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions))
}
attr_accessor :network_options
# The challenge indicator (`threeDSRequestorChallengeInd`) which was requested in the
# AReq sent to the card Issuer's ACS. A string containing 2 digits from 01-99.
sig { returns(T.nilable(String)) }
attr_accessor :requestor_challenge_indicator
# For 3D Secure 1, the XID. For 3D Secure 2, the Directory Server
# Transaction ID (dsTransID).
sig { returns(T.nilable(String)) }
attr_accessor :transaction_id
# The version of 3D Secure that was performed.
sig { returns(T.nilable(String)) }
attr_accessor :version
sig {
params(ares_trans_status: T.nilable(String), cryptogram: T.nilable(String), electronic_commerce_indicator: T.nilable(String), network_options: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions), requestor_challenge_indicator: T.nilable(String), transaction_id: T.nilable(String), version: T.nilable(String)).void
}
def initialize(
ares_trans_status: nil,
cryptogram: nil,
electronic_commerce_indicator: nil,
network_options: nil,
requestor_challenge_indicator: nil,
transaction_id: nil,
version: nil
); end
end
# Configuration options for setting up an eMandate for cards issued in India.
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions::Card::MandateOptions))
}
attr_accessor :mandate_options
# When specified, this parameter signals that a card has been collected
# as MOTO (Mail Order Telephone Order) and thus out of scope for SCA. This
# parameter can only be provided during confirmation.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :moto
# Selected network to process this SetupIntent on. Depends on the available networks of the card attached to the SetupIntent. Can be only set confirm-time.
sig { returns(T.nilable(String)) }
attr_accessor :network
# We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. If not provided, this value defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
sig { returns(T.nilable(String)) }
attr_accessor :request_three_d_secure
# If 3D Secure authentication was performed with a third-party provider,
# the authentication details to use for this setup.
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions::Card::ThreeDSecure))
}
attr_accessor :three_d_secure
sig {
params(mandate_options: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions::Card::MandateOptions), moto: T.nilable(T::Boolean), network: T.nilable(String), request_three_d_secure: T.nilable(String), three_d_secure: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions::Card::ThreeDSecure)).void
}
def initialize(
mandate_options: nil,
moto: nil,
network: nil,
request_three_d_secure: nil,
three_d_secure: nil
); end
end
class CardPresent < Stripe::RequestParams; end
class Link < Stripe::RequestParams
# [Deprecated] This is a legacy parameter that no longer has any function.
sig { returns(T.nilable(String)) }
attr_accessor :persistent_token
sig { params(persistent_token: T.nilable(String)).void }
def initialize(persistent_token: nil); end
end
class Paypal < Stripe::RequestParams
# The PayPal Billing Agreement ID (BAID). This is an ID generated by PayPal which represents the mandate between the merchant and the customer.
sig { returns(T.nilable(String)) }
attr_accessor :billing_agreement_id
# Attribute for param field currency
sig { returns(T.nilable(String)) }
attr_accessor :currency
# The Stripe connected account IDs of the sellers on the platform for this transaction (optional). Only allowed when [separate charges and transfers](https://stripe.com/docs/connect/separate-charges-and-transfers) are used.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :subsellers
sig {
params(billing_agreement_id: T.nilable(String), currency: T.nilable(String), subsellers: T.nilable(T::Array[String])).void
}
def initialize(billing_agreement_id: nil, currency: nil, subsellers: nil); end
end
class Payto < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Amount that will be collected. It is required when `amount_type` is `fixed`.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# The type of amount that will be collected. The amount charged must be exact or up to the value of `amount` param for `fixed` or `maximum` type respectively.
sig { returns(T.nilable(String)) }
attr_accessor :amount_type
# Date, in YYYY-MM-DD format, after which payments will not be collected. Defaults to no end date.
sig { returns(T.nilable(String)) }
attr_accessor :end_date
# The periodicity at which payments will be collected.
sig { returns(T.nilable(String)) }
attr_accessor :payment_schedule
# The number of payments that will be made during a payment period. Defaults to 1 except for when `payment_schedule` is `adhoc`. In that case, it defaults to no limit.
sig { returns(T.nilable(Integer)) }
attr_accessor :payments_per_period
# The purpose for which payments are made. Defaults to retail.
sig { returns(T.nilable(String)) }
attr_accessor :purpose
# Date, in YYYY-MM-DD format, from which payments will be collected. Defaults to confirmation time.
sig { returns(T.nilable(String)) }
attr_accessor :start_date
sig {
params(amount: T.nilable(Integer), amount_type: T.nilable(String), end_date: T.nilable(String), payment_schedule: T.nilable(String), payments_per_period: T.nilable(Integer), purpose: T.nilable(String), start_date: T.nilable(String)).void
}
def initialize(
amount: nil,
amount_type: nil,
end_date: nil,
payment_schedule: nil,
payments_per_period: nil,
purpose: nil,
start_date: nil
); end
end
# Additional fields for Mandate creation.
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions::Payto::MandateOptions))
}
attr_accessor :mandate_options
sig {
params(mandate_options: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions::Payto::MandateOptions)).void
}
def initialize(mandate_options: nil); end
end
class SepaDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'STRIPE'.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :reference_prefix
sig { params(reference_prefix: T.nilable(T.nilable(String))).void }
def initialize(reference_prefix: nil); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions::SepaDebit::MandateOptions))
}
attr_accessor :mandate_options
sig {
params(mandate_options: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions::SepaDebit::MandateOptions)).void
}
def initialize(mandate_options: nil); end
end
class UsBankAccount < Stripe::RequestParams
class FinancialConnections < Stripe::RequestParams
class Filters < Stripe::RequestParams
# The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :account_subcategories
# ID of the institution to use to filter for selectable accounts.
sig { returns(T.nilable(String)) }
attr_accessor :institution
sig {
params(account_subcategories: T.nilable(T::Array[String]), institution: T.nilable(String)).void
}
def initialize(account_subcategories: nil, institution: nil); end
end
class ManualEntry < Stripe::RequestParams
# Settings for configuring manual entry of account details.
sig { returns(String) }
attr_accessor :mode
sig { params(mode: String).void }
def initialize(mode: nil); end
end
# Provide filters for the linked accounts that the customer can select for the payment method.
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::Filters))
}
attr_accessor :filters
# Customize manual entry behavior
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::ManualEntry))
}
attr_accessor :manual_entry
# The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :permissions
# List of data features that you would like to retrieve upon account creation.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :prefetch
# For webview integrations only. Upon completing OAuth login in the native browser, the user will be redirected to this URL to return to your app.
sig { returns(T.nilable(String)) }
attr_accessor :return_url
sig {
params(filters: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::Filters), manual_entry: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::ManualEntry), permissions: T.nilable(T::Array[String]), prefetch: T.nilable(T::Array[String]), return_url: T.nilable(String)).void
}
def initialize(
filters: nil,
manual_entry: nil,
permissions: nil,
prefetch: nil,
return_url: nil
); end
end
class MandateOptions < Stripe::RequestParams
# The method used to collect offline mandate customer acceptance.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :collection_method
sig { params(collection_method: T.nilable(T.nilable(String))).void }
def initialize(collection_method: nil); end
end
class Networks < Stripe::RequestParams
# Triggers validations to run across the selected networks
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Array[String])).void }
def initialize(requested: nil); end
end
# Additional fields for Financial Connections Session creation
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions::UsBankAccount::FinancialConnections))
}
attr_accessor :financial_connections
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions::UsBankAccount::MandateOptions))
}
attr_accessor :mandate_options
# Additional fields for network related functions
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions::UsBankAccount::Networks))
}
attr_accessor :networks
# Bank account verification method.
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(financial_connections: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions::UsBankAccount::FinancialConnections), mandate_options: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions::UsBankAccount::MandateOptions), networks: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions::UsBankAccount::Networks), verification_method: T.nilable(String)).void
}
def initialize(
financial_connections: nil,
mandate_options: nil,
networks: nil,
verification_method: nil
); end
end
# If this is a `acss_debit` SetupIntent, this sub-hash contains details about the ACSS Debit payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions::AcssDebit))
}
attr_accessor :acss_debit
# If this is a `amazon_pay` SetupIntent, this sub-hash contains details about the AmazonPay payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions::AmazonPay))
}
attr_accessor :amazon_pay
# If this is a `bacs_debit` SetupIntent, this sub-hash contains details about the Bacs Debit payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions::BacsDebit))
}
attr_accessor :bacs_debit
# Configuration for any card setup attempted on this SetupIntent.
sig { returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions::Card)) }
attr_accessor :card
# If this is a `card_present` PaymentMethod, this sub-hash contains details about the card-present payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions::CardPresent))
}
attr_accessor :card_present
# If this is a `link` PaymentMethod, this sub-hash contains details about the Link payment method options.
sig { returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions::Link)) }
attr_accessor :link
# If this is a `paypal` PaymentMethod, this sub-hash contains details about the PayPal payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions::Paypal))
}
attr_accessor :paypal
# If this is a `payto` SetupIntent, this sub-hash contains details about the PayTo payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions::Payto))
}
attr_accessor :payto
# If this is a `sepa_debit` SetupIntent, this sub-hash contains details about the SEPA Debit payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions::SepaDebit))
}
attr_accessor :sepa_debit
# If this is a `us_bank_account` SetupIntent, this sub-hash contains details about the US bank account payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions::UsBankAccount))
}
attr_accessor :us_bank_account
sig {
params(acss_debit: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions::AcssDebit), amazon_pay: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions::AmazonPay), bacs_debit: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions::BacsDebit), card: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions::Card), card_present: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions::CardPresent), link: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions::Link), paypal: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions::Paypal), payto: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions::Payto), sepa_debit: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions::SepaDebit), us_bank_account: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions::UsBankAccount)).void
}
def initialize(
acss_debit: nil,
amazon_pay: nil,
bacs_debit: nil,
card: nil,
card_present: nil,
link: nil,
paypal: nil,
payto: nil,
sepa_debit: nil,
us_bank_account: nil
); end
end
# ID of the ConfirmationToken used to confirm this SetupIntent.
#
# If the provided ConfirmationToken contains properties that are also being provided in this request, such as `payment_method`, then the values in this request will take precedence.
sig { returns(T.nilable(String)) }
attr_accessor :confirmation_token
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Attribute for param field mandate_data
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SetupIntent::ConfirmParams::MandateData))))
}
attr_accessor :mandate_data
# ID of the payment method (a PaymentMethod, Card, or saved Source object) to attach to this SetupIntent.
sig { returns(T.nilable(String)) }
attr_accessor :payment_method
# When included, this hash creates a PaymentMethod that is set as the [`payment_method`](https://stripe.com/docs/api/setup_intents/object#setup_intent_object-payment_method)
# value in the SetupIntent.
sig { returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData)) }
attr_accessor :payment_method_data
# Payment method-specific configuration for this SetupIntent.
sig { returns(T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions)) }
attr_accessor :payment_method_options
# The URL to redirect your customer back to after they authenticate on the payment method's app or site.
# If you'd prefer to redirect to a mobile application, you can alternatively supply an application URI scheme.
# This parameter is only used for cards and other redirect-based payment methods.
sig { returns(T.nilable(String)) }
attr_accessor :return_url
# Set to `true` when confirming server-side and using Stripe.js, iOS, or Android client-side SDKs to handle the next actions.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :use_stripe_sdk
sig {
params(confirmation_token: T.nilable(String), expand: T.nilable(T::Array[String]), mandate_data: T.nilable(T.nilable(T.any(String, ::Stripe::SetupIntent::ConfirmParams::MandateData))), payment_method: T.nilable(String), payment_method_data: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodData), payment_method_options: T.nilable(::Stripe::SetupIntent::ConfirmParams::PaymentMethodOptions), return_url: T.nilable(String), use_stripe_sdk: T.nilable(T::Boolean)).void
}
def initialize(
confirmation_token: nil,
expand: nil,
mandate_data: nil,
payment_method: nil,
payment_method_data: nil,
payment_method_options: nil,
return_url: nil,
use_stripe_sdk: nil
); end
end
class VerifyMicrodepositsParams < Stripe::RequestParams
# Two positive integers, in *cents*, equal to the values of the microdeposits sent to the bank account.
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :amounts
# A six-character code starting with SM present in the microdeposit sent to the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :descriptor_code
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig {
params(amounts: T.nilable(T::Array[Integer]), descriptor_code: T.nilable(String), expand: T.nilable(T::Array[String])).void
}
def initialize(amounts: nil, descriptor_code: nil, expand: nil); end
end
# You can cancel a SetupIntent object when it's in one of these statuses: requires_payment_method, requires_confirmation, or requires_action.
#
# After you cancel it, setup is abandoned and any operations on the SetupIntent fail with an error. You can't cancel the SetupIntent for a Checkout Session. [Expire the Checkout Session](https://docs.stripe.com/docs/api/checkout/sessions/expire) instead.
sig {
params(params: T.any(::Stripe::SetupIntent::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SetupIntent)
}
def cancel(params = {}, opts = {}); end
# You can cancel a SetupIntent object when it's in one of these statuses: requires_payment_method, requires_confirmation, or requires_action.
#
# After you cancel it, setup is abandoned and any operations on the SetupIntent fail with an error. You can't cancel the SetupIntent for a Checkout Session. [Expire the Checkout Session](https://docs.stripe.com/docs/api/checkout/sessions/expire) instead.
sig {
params(intent: String, params: T.any(::Stripe::SetupIntent::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SetupIntent)
}
def self.cancel(intent, params = {}, opts = {}); end
# Confirm that your customer intends to set up the current or
# provided payment method. For example, you would confirm a SetupIntent
# when a customer hits the “Save” button on a payment method management
# page on your website.
#
# If the selected payment method does not require any additional
# steps from the customer, the SetupIntent will transition to the
# succeeded status.
#
# Otherwise, it will transition to the requires_action status and
# suggest additional actions via next_action. If setup fails,
# the SetupIntent will transition to the
# requires_payment_method status or the canceled status if the
# confirmation limit is reached.
sig {
params(params: T.any(::Stripe::SetupIntent::ConfirmParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SetupIntent)
}
def confirm(params = {}, opts = {}); end
# Confirm that your customer intends to set up the current or
# provided payment method. For example, you would confirm a SetupIntent
# when a customer hits the “Save” button on a payment method management
# page on your website.
#
# If the selected payment method does not require any additional
# steps from the customer, the SetupIntent will transition to the
# succeeded status.
#
# Otherwise, it will transition to the requires_action status and
# suggest additional actions via next_action. If setup fails,
# the SetupIntent will transition to the
# requires_payment_method status or the canceled status if the
# confirmation limit is reached.
sig {
params(intent: String, params: T.any(::Stripe::SetupIntent::ConfirmParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SetupIntent)
}
def self.confirm(intent, params = {}, opts = {}); end
# Creates a SetupIntent object.
#
# After you create the SetupIntent, attach a payment method and [confirm](https://docs.stripe.com/docs/api/setup_intents/confirm)
# it to collect any required permissions to charge the payment method later.
sig {
params(params: T.any(::Stripe::SetupIntent::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SetupIntent)
}
def self.create(params = {}, opts = {}); end
# Returns a list of SetupIntents.
sig {
params(params: T.any(::Stripe::SetupIntent::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Updates a SetupIntent object.
sig {
params(intent: String, params: T.any(::Stripe::SetupIntent::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SetupIntent)
}
def self.update(intent, params = {}, opts = {}); end
# Verifies microdeposits on a SetupIntent object.
sig {
params(params: T.any(::Stripe::SetupIntent::VerifyMicrodepositsParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SetupIntent)
}
def verify_microdeposits(params = {}, opts = {}); end
# Verifies microdeposits on a SetupIntent object.
sig {
params(intent: String, params: T.any(::Stripe::SetupIntent::VerifyMicrodepositsParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SetupIntent)
}
def self.verify_microdeposits(intent, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
# Shipping rates describe the price of shipping presented to your customers and
# applied to a purchase. For more information, see [Charge for shipping](https://stripe.com/docs/payments/during-payment/charge-shipping).
class ShippingRate < APIResource
class DeliveryEstimate < Stripe::StripeObject
class Maximum < Stripe::StripeObject
# A unit of time.
sig { returns(String) }
attr_reader :unit
# Must be greater than 0.
sig { returns(Integer) }
attr_reader :value
end
class Minimum < Stripe::StripeObject
# A unit of time.
sig { returns(String) }
attr_reader :unit
# Must be greater than 0.
sig { returns(Integer) }
attr_reader :value
end
# The upper bound of the estimated range. If empty, represents no upper bound i.e., infinite.
sig { returns(T.nilable(Maximum)) }
attr_reader :maximum
# The lower bound of the estimated range. If empty, represents no lower bound.
sig { returns(T.nilable(Minimum)) }
attr_reader :minimum
end
class FixedAmount < Stripe::StripeObject
class CurrencyOptions < Stripe::StripeObject
# A non-negative integer in cents representing how much to charge.
sig { returns(Integer) }
attr_reader :amount
# Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
sig { returns(String) }
attr_reader :tax_behavior
end
# A non-negative integer in cents representing how much to charge.
sig { returns(Integer) }
attr_reader :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).
sig { returns(String) }
attr_reader :currency
# Shipping rates defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
sig { returns(T::Hash[String, CurrencyOptions]) }
attr_reader :currency_options
end
# Whether the shipping rate can be used for new purchases. Defaults to `true`.
sig { returns(T::Boolean) }
attr_reader :active
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# The estimated range for how long shipping will take, meant to be displayable to the customer. This will appear on CheckoutSessions.
sig { returns(T.nilable(DeliveryEstimate)) }
attr_reader :delivery_estimate
# The name of the shipping rate, meant to be displayable to the customer. This will appear on CheckoutSessions.
sig { returns(T.nilable(String)) }
attr_reader :display_name
# Attribute for field fixed_amount
sig { returns(FixedAmount) }
attr_reader :fixed_amount
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# 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.
sig { returns(T::Hash[String, String]) }
attr_reader :metadata
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
sig { returns(T.nilable(String)) }
attr_reader :tax_behavior
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID. The Shipping tax code is `txcd_92010001`.
sig { returns(T.nilable(T.any(String, Stripe::TaxCode))) }
attr_reader :tax_code
# The type of calculation to use on the shipping rate.
sig { returns(String) }
attr_reader :type
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return shipping rates that are active or inactive.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.
sig { returns(T.nilable(T.any(::Stripe::ShippingRate::ListParams::Created, Integer))) }
attr_accessor :created
# Only return shipping rates for the given currency.
sig { returns(T.nilable(String)) }
attr_accessor :currency
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(active: T.nilable(T::Boolean), created: T.nilable(T.any(::Stripe::ShippingRate::ListParams::Created, Integer)), currency: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
active: nil,
created: nil,
currency: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class DeliveryEstimate < Stripe::RequestParams
class Maximum < Stripe::RequestParams
# A unit of time.
sig { returns(String) }
attr_accessor :unit
# Must be greater than 0.
sig { returns(Integer) }
attr_accessor :value
sig { params(unit: String, value: Integer).void }
def initialize(unit: nil, value: nil); end
end
class Minimum < Stripe::RequestParams
# A unit of time.
sig { returns(String) }
attr_accessor :unit
# Must be greater than 0.
sig { returns(Integer) }
attr_accessor :value
sig { params(unit: String, value: Integer).void }
def initialize(unit: nil, value: nil); end
end
# The upper bound of the estimated range. If empty, represents no upper bound i.e., infinite.
sig { returns(T.nilable(::Stripe::ShippingRate::CreateParams::DeliveryEstimate::Maximum)) }
attr_accessor :maximum
# The lower bound of the estimated range. If empty, represents no lower bound.
sig { returns(T.nilable(::Stripe::ShippingRate::CreateParams::DeliveryEstimate::Minimum)) }
attr_accessor :minimum
sig {
params(maximum: T.nilable(::Stripe::ShippingRate::CreateParams::DeliveryEstimate::Maximum), minimum: T.nilable(::Stripe::ShippingRate::CreateParams::DeliveryEstimate::Minimum)).void
}
def initialize(maximum: nil, minimum: nil); end
end
class FixedAmount < Stripe::RequestParams
class CurrencyOptions < Stripe::RequestParams
# A non-negative integer in cents representing how much to charge.
sig { returns(Integer) }
attr_accessor :amount
# Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
sig { params(amount: Integer, tax_behavior: T.nilable(String)).void }
def initialize(amount: nil, tax_behavior: nil); end
end
# A non-negative integer in cents representing how much to charge.
sig { returns(Integer) }
attr_accessor :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).
sig { returns(String) }
attr_accessor :currency
# Shipping rates defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
sig {
returns(T.nilable(T::Hash[String, ::Stripe::ShippingRate::CreateParams::FixedAmount::CurrencyOptions]))
}
attr_accessor :currency_options
sig {
params(amount: Integer, currency: String, currency_options: T.nilable(T::Hash[String, ::Stripe::ShippingRate::CreateParams::FixedAmount::CurrencyOptions])).void
}
def initialize(amount: nil, currency: nil, currency_options: nil); end
end
# The estimated range for how long shipping will take, meant to be displayable to the customer. This will appear on CheckoutSessions.
sig { returns(T.nilable(::Stripe::ShippingRate::CreateParams::DeliveryEstimate)) }
attr_accessor :delivery_estimate
# The name of the shipping rate, meant to be displayable to the customer. This will appear on CheckoutSessions.
sig { returns(String) }
attr_accessor :display_name
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Describes a fixed amount to charge for shipping. Must be present if type is `fixed_amount`.
sig { returns(T.nilable(::Stripe::ShippingRate::CreateParams::FixedAmount)) }
attr_accessor :fixed_amount
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID. The Shipping tax code is `txcd_92010001`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_code
# The type of calculation to use on the shipping rate.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(delivery_estimate: T.nilable(::Stripe::ShippingRate::CreateParams::DeliveryEstimate), display_name: String, expand: T.nilable(T::Array[String]), fixed_amount: T.nilable(::Stripe::ShippingRate::CreateParams::FixedAmount), metadata: T.nilable(T::Hash[String, String]), tax_behavior: T.nilable(String), tax_code: T.nilable(String), type: T.nilable(String)).void
}
def initialize(
delivery_estimate: nil,
display_name: nil,
expand: nil,
fixed_amount: nil,
metadata: nil,
tax_behavior: nil,
tax_code: nil,
type: nil
); end
end
class UpdateParams < Stripe::RequestParams
class FixedAmount < Stripe::RequestParams
class CurrencyOptions < Stripe::RequestParams
# A non-negative integer in cents representing how much to charge.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
sig { params(amount: T.nilable(Integer), tax_behavior: T.nilable(String)).void }
def initialize(amount: nil, tax_behavior: nil); end
end
# Shipping rates defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
sig {
returns(T.nilable(T::Hash[String, ::Stripe::ShippingRate::UpdateParams::FixedAmount::CurrencyOptions]))
}
attr_accessor :currency_options
sig {
params(currency_options: T.nilable(T::Hash[String, ::Stripe::ShippingRate::UpdateParams::FixedAmount::CurrencyOptions])).void
}
def initialize(currency_options: nil); end
end
# Whether the shipping rate can be used for new purchases. Defaults to `true`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Describes a fixed amount to charge for shipping. Must be present if type is `fixed_amount`.
sig { returns(T.nilable(::Stripe::ShippingRate::UpdateParams::FixedAmount)) }
attr_accessor :fixed_amount
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
sig {
params(active: T.nilable(T::Boolean), expand: T.nilable(T::Array[String]), fixed_amount: T.nilable(::Stripe::ShippingRate::UpdateParams::FixedAmount), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), tax_behavior: T.nilable(String)).void
}
def initialize(
active: nil,
expand: nil,
fixed_amount: nil,
metadata: nil,
tax_behavior: nil
); end
end
# Creates a new shipping rate object.
sig {
params(params: T.any(::Stripe::ShippingRate::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ShippingRate)
}
def self.create(params = {}, opts = {}); end
# Returns a list of your shipping rates.
sig {
params(params: T.any(::Stripe::ShippingRate::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Updates an existing shipping rate object.
sig {
params(shipping_rate_token: String, params: T.any(::Stripe::ShippingRate::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ShippingRate)
}
def self.update(shipping_rate_token, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
# `Source` objects allow you to accept a variety of payment methods. They
# represent a customer's payment instrument, and can be used with the Stripe API
# just like a `Card` object: once chargeable, they can be charged, or can be
# attached to customers.
#
# Stripe doesn't recommend using the deprecated [Sources API](https://stripe.com/docs/api/sources).
# We recommend that you adopt the [PaymentMethods API](https://stripe.com/docs/api/payment_methods).
# This newer API provides access to our latest features and payment method types.
#
# Related guides: [Sources API](https://stripe.com/docs/sources) and [Sources & Customers](https://stripe.com/docs/sources/customers).
class Source < APIResource
class AchCreditTransfer < Stripe::StripeObject
# Attribute for field account_number
sig { returns(T.nilable(String)) }
attr_reader :account_number
# Attribute for field bank_name
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# Attribute for field fingerprint
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Attribute for field refund_account_holder_name
sig { returns(T.nilable(String)) }
attr_reader :refund_account_holder_name
# Attribute for field refund_account_holder_type
sig { returns(T.nilable(String)) }
attr_reader :refund_account_holder_type
# Attribute for field refund_routing_number
sig { returns(T.nilable(String)) }
attr_reader :refund_routing_number
# Attribute for field routing_number
sig { returns(T.nilable(String)) }
attr_reader :routing_number
# Attribute for field swift_code
sig { returns(T.nilable(String)) }
attr_reader :swift_code
end
class AchDebit < Stripe::StripeObject
# Attribute for field bank_name
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# Attribute for field country
sig { returns(T.nilable(String)) }
attr_reader :country
# Attribute for field fingerprint
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Attribute for field last4
sig { returns(T.nilable(String)) }
attr_reader :last4
# Attribute for field routing_number
sig { returns(T.nilable(String)) }
attr_reader :routing_number
# Attribute for field type
sig { returns(T.nilable(String)) }
attr_reader :type
end
class AcssDebit < Stripe::StripeObject
# Attribute for field bank_address_city
sig { returns(T.nilable(String)) }
attr_reader :bank_address_city
# Attribute for field bank_address_line_1
sig { returns(T.nilable(String)) }
attr_reader :bank_address_line_1
# Attribute for field bank_address_line_2
sig { returns(T.nilable(String)) }
attr_reader :bank_address_line_2
# Attribute for field bank_address_postal_code
sig { returns(T.nilable(String)) }
attr_reader :bank_address_postal_code
# Attribute for field bank_name
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# Attribute for field category
sig { returns(T.nilable(String)) }
attr_reader :category
# Attribute for field country
sig { returns(T.nilable(String)) }
attr_reader :country
# Attribute for field fingerprint
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Attribute for field last4
sig { returns(T.nilable(String)) }
attr_reader :last4
# Attribute for field routing_number
sig { returns(T.nilable(String)) }
attr_reader :routing_number
end
class Alipay < Stripe::StripeObject
# Attribute for field data_string
sig { returns(T.nilable(String)) }
attr_reader :data_string
# Attribute for field native_url
sig { returns(T.nilable(String)) }
attr_reader :native_url
# Attribute for field statement_descriptor
sig { returns(T.nilable(String)) }
attr_reader :statement_descriptor
end
class AuBecsDebit < Stripe::StripeObject
# Attribute for field bsb_number
sig { returns(T.nilable(String)) }
attr_reader :bsb_number
# Attribute for field fingerprint
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Attribute for field last4
sig { returns(T.nilable(String)) }
attr_reader :last4
end
class Bancontact < Stripe::StripeObject
# Attribute for field bank_code
sig { returns(T.nilable(String)) }
attr_reader :bank_code
# Attribute for field bank_name
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# Attribute for field bic
sig { returns(T.nilable(String)) }
attr_reader :bic
# Attribute for field iban_last4
sig { returns(T.nilable(String)) }
attr_reader :iban_last4
# Attribute for field preferred_language
sig { returns(T.nilable(String)) }
attr_reader :preferred_language
# Attribute for field statement_descriptor
sig { returns(T.nilable(String)) }
attr_reader :statement_descriptor
end
class Card < Stripe::StripeObject
# Attribute for field address_line1_check
sig { returns(T.nilable(String)) }
attr_reader :address_line1_check
# Attribute for field address_zip_check
sig { returns(T.nilable(String)) }
attr_reader :address_zip_check
# Attribute for field brand
sig { returns(T.nilable(String)) }
attr_reader :brand
# Attribute for field brand_product
sig { returns(T.nilable(String)) }
attr_reader :brand_product
# Attribute for field country
sig { returns(T.nilable(String)) }
attr_reader :country
# Attribute for field cvc_check
sig { returns(T.nilable(String)) }
attr_reader :cvc_check
# Attribute for field description
sig { returns(String) }
attr_reader :description
# Attribute for field dynamic_last4
sig { returns(T.nilable(String)) }
attr_reader :dynamic_last4
# Attribute for field exp_month
sig { returns(T.nilable(Integer)) }
attr_reader :exp_month
# Attribute for field exp_year
sig { returns(T.nilable(Integer)) }
attr_reader :exp_year
# Attribute for field fingerprint
sig { returns(String) }
attr_reader :fingerprint
# Attribute for field funding
sig { returns(T.nilable(String)) }
attr_reader :funding
# Attribute for field iin
sig { returns(String) }
attr_reader :iin
# Attribute for field issuer
sig { returns(String) }
attr_reader :issuer
# Attribute for field last4
sig { returns(T.nilable(String)) }
attr_reader :last4
# Attribute for field name
sig { returns(T.nilable(String)) }
attr_reader :name
# Attribute for field three_d_secure
sig { returns(String) }
attr_reader :three_d_secure
# Attribute for field tokenization_method
sig { returns(T.nilable(String)) }
attr_reader :tokenization_method
end
class CardPresent < Stripe::StripeObject
# Attribute for field application_cryptogram
sig { returns(String) }
attr_reader :application_cryptogram
# Attribute for field application_preferred_name
sig { returns(String) }
attr_reader :application_preferred_name
# Attribute for field authorization_code
sig { returns(T.nilable(String)) }
attr_reader :authorization_code
# Attribute for field authorization_response_code
sig { returns(String) }
attr_reader :authorization_response_code
# Attribute for field brand
sig { returns(T.nilable(String)) }
attr_reader :brand
# Attribute for field brand_product
sig { returns(T.nilable(String)) }
attr_reader :brand_product
# Attribute for field country
sig { returns(T.nilable(String)) }
attr_reader :country
# Attribute for field cvm_type
sig { returns(String) }
attr_reader :cvm_type
# Attribute for field data_type
sig { returns(T.nilable(String)) }
attr_reader :data_type
# Attribute for field dedicated_file_name
sig { returns(String) }
attr_reader :dedicated_file_name
# Attribute for field description
sig { returns(String) }
attr_reader :description
# Attribute for field emv_auth_data
sig { returns(String) }
attr_reader :emv_auth_data
# Attribute for field evidence_customer_signature
sig { returns(T.nilable(String)) }
attr_reader :evidence_customer_signature
# Attribute for field evidence_transaction_certificate
sig { returns(T.nilable(String)) }
attr_reader :evidence_transaction_certificate
# Attribute for field exp_month
sig { returns(T.nilable(Integer)) }
attr_reader :exp_month
# Attribute for field exp_year
sig { returns(T.nilable(Integer)) }
attr_reader :exp_year
# Attribute for field fingerprint
sig { returns(String) }
attr_reader :fingerprint
# Attribute for field funding
sig { returns(T.nilable(String)) }
attr_reader :funding
# Attribute for field iin
sig { returns(String) }
attr_reader :iin
# Attribute for field issuer
sig { returns(String) }
attr_reader :issuer
# Attribute for field last4
sig { returns(T.nilable(String)) }
attr_reader :last4
# Attribute for field pos_device_id
sig { returns(T.nilable(String)) }
attr_reader :pos_device_id
# Attribute for field pos_entry_mode
sig { returns(String) }
attr_reader :pos_entry_mode
# Attribute for field read_method
sig { returns(T.nilable(String)) }
attr_reader :read_method
# Attribute for field reader
sig { returns(T.nilable(String)) }
attr_reader :reader
# Attribute for field terminal_verification_results
sig { returns(String) }
attr_reader :terminal_verification_results
# Attribute for field transaction_status_information
sig { returns(String) }
attr_reader :transaction_status_information
end
class CodeVerification < Stripe::StripeObject
# The number of attempts remaining to authenticate the source object with a verification code.
sig { returns(Integer) }
attr_reader :attempts_remaining
# The status of the code verification, either `pending` (awaiting verification, `attempts_remaining` should be greater than 0), `succeeded` (successful verification) or `failed` (failed verification, cannot be verified anymore as `attempts_remaining` should be 0).
sig { returns(String) }
attr_reader :status
end
class Eps < Stripe::StripeObject
# Attribute for field reference
sig { returns(T.nilable(String)) }
attr_reader :reference
# Attribute for field statement_descriptor
sig { returns(T.nilable(String)) }
attr_reader :statement_descriptor
end
class Giropay < Stripe::StripeObject
# Attribute for field bank_code
sig { returns(T.nilable(String)) }
attr_reader :bank_code
# Attribute for field bank_name
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# Attribute for field bic
sig { returns(T.nilable(String)) }
attr_reader :bic
# Attribute for field statement_descriptor
sig { returns(T.nilable(String)) }
attr_reader :statement_descriptor
end
class Ideal < Stripe::StripeObject
# Attribute for field bank
sig { returns(T.nilable(String)) }
attr_reader :bank
# Attribute for field bic
sig { returns(T.nilable(String)) }
attr_reader :bic
# Attribute for field iban_last4
sig { returns(T.nilable(String)) }
attr_reader :iban_last4
# Attribute for field statement_descriptor
sig { returns(T.nilable(String)) }
attr_reader :statement_descriptor
end
class Klarna < Stripe::StripeObject
# Attribute for field background_image_url
sig { returns(String) }
attr_reader :background_image_url
# Attribute for field client_token
sig { returns(T.nilable(String)) }
attr_reader :client_token
# Attribute for field first_name
sig { returns(String) }
attr_reader :first_name
# Attribute for field last_name
sig { returns(String) }
attr_reader :last_name
# Attribute for field locale
sig { returns(String) }
attr_reader :locale
# Attribute for field logo_url
sig { returns(String) }
attr_reader :logo_url
# Attribute for field page_title
sig { returns(String) }
attr_reader :page_title
# Attribute for field pay_later_asset_urls_descriptive
sig { returns(String) }
attr_reader :pay_later_asset_urls_descriptive
# Attribute for field pay_later_asset_urls_standard
sig { returns(String) }
attr_reader :pay_later_asset_urls_standard
# Attribute for field pay_later_name
sig { returns(String) }
attr_reader :pay_later_name
# Attribute for field pay_later_redirect_url
sig { returns(String) }
attr_reader :pay_later_redirect_url
# Attribute for field pay_now_asset_urls_descriptive
sig { returns(String) }
attr_reader :pay_now_asset_urls_descriptive
# Attribute for field pay_now_asset_urls_standard
sig { returns(String) }
attr_reader :pay_now_asset_urls_standard
# Attribute for field pay_now_name
sig { returns(String) }
attr_reader :pay_now_name
# Attribute for field pay_now_redirect_url
sig { returns(String) }
attr_reader :pay_now_redirect_url
# Attribute for field pay_over_time_asset_urls_descriptive
sig { returns(String) }
attr_reader :pay_over_time_asset_urls_descriptive
# Attribute for field pay_over_time_asset_urls_standard
sig { returns(String) }
attr_reader :pay_over_time_asset_urls_standard
# Attribute for field pay_over_time_name
sig { returns(String) }
attr_reader :pay_over_time_name
# Attribute for field pay_over_time_redirect_url
sig { returns(String) }
attr_reader :pay_over_time_redirect_url
# Attribute for field payment_method_categories
sig { returns(String) }
attr_reader :payment_method_categories
# Attribute for field purchase_country
sig { returns(String) }
attr_reader :purchase_country
# Attribute for field purchase_type
sig { returns(String) }
attr_reader :purchase_type
# Attribute for field redirect_url
sig { returns(String) }
attr_reader :redirect_url
# Attribute for field shipping_delay
sig { returns(Integer) }
attr_reader :shipping_delay
# Attribute for field shipping_first_name
sig { returns(String) }
attr_reader :shipping_first_name
# Attribute for field shipping_last_name
sig { returns(String) }
attr_reader :shipping_last_name
end
class Multibanco < Stripe::StripeObject
# Attribute for field entity
sig { returns(T.nilable(String)) }
attr_reader :entity
# Attribute for field reference
sig { returns(T.nilable(String)) }
attr_reader :reference
# Attribute for field refund_account_holder_address_city
sig { returns(T.nilable(String)) }
attr_reader :refund_account_holder_address_city
# Attribute for field refund_account_holder_address_country
sig { returns(T.nilable(String)) }
attr_reader :refund_account_holder_address_country
# Attribute for field refund_account_holder_address_line1
sig { returns(T.nilable(String)) }
attr_reader :refund_account_holder_address_line1
# Attribute for field refund_account_holder_address_line2
sig { returns(T.nilable(String)) }
attr_reader :refund_account_holder_address_line2
# Attribute for field refund_account_holder_address_postal_code
sig { returns(T.nilable(String)) }
attr_reader :refund_account_holder_address_postal_code
# Attribute for field refund_account_holder_address_state
sig { returns(T.nilable(String)) }
attr_reader :refund_account_holder_address_state
# Attribute for field refund_account_holder_name
sig { returns(T.nilable(String)) }
attr_reader :refund_account_holder_name
# Attribute for field refund_iban
sig { returns(T.nilable(String)) }
attr_reader :refund_iban
end
class Owner < Stripe::StripeObject
class Address < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
class VerifiedAddress < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Owner's address.
sig { returns(T.nilable(Address)) }
attr_reader :address
# Owner's email address.
sig { returns(T.nilable(String)) }
attr_reader :email
# Owner's full name.
sig { returns(T.nilable(String)) }
attr_reader :name
# Owner's phone number (including extension).
sig { returns(T.nilable(String)) }
attr_reader :phone
# Verified owner's address. Verified values are verified or provided by the payment method directly (and if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(VerifiedAddress)) }
attr_reader :verified_address
# Verified owner's email address. Verified values are verified or provided by the payment method directly (and if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(String)) }
attr_reader :verified_email
# Verified owner's full name. Verified values are verified or provided by the payment method directly (and if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(String)) }
attr_reader :verified_name
# Verified owner's phone number (including extension). Verified values are verified or provided by the payment method directly (and if supported) at the time of authorization or settlement. They cannot be set or mutated.
sig { returns(T.nilable(String)) }
attr_reader :verified_phone
end
class P24 < Stripe::StripeObject
# Attribute for field reference
sig { returns(T.nilable(String)) }
attr_reader :reference
end
class Paypal < Stripe::StripeObject
# Attribute for field billing_agreement
sig { returns(T.nilable(String)) }
attr_reader :billing_agreement
# Attribute for field fingerprint
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Attribute for field payer_id
sig { returns(T.nilable(String)) }
attr_reader :payer_id
# Attribute for field reference_id
sig { returns(String) }
attr_reader :reference_id
# Attribute for field reference_transaction_amount
sig { returns(String) }
attr_reader :reference_transaction_amount
# Attribute for field reference_transaction_charged
sig { returns(T::Boolean) }
attr_reader :reference_transaction_charged
# Attribute for field statement_descriptor
sig { returns(T.nilable(String)) }
attr_reader :statement_descriptor
# Attribute for field transaction_id
sig { returns(String) }
attr_reader :transaction_id
# Attribute for field verified_email
sig { returns(T.nilable(String)) }
attr_reader :verified_email
end
class Receiver < Stripe::StripeObject
# The address of the receiver source. This is the value that should be communicated to the customer to send their funds to.
sig { returns(T.nilable(String)) }
attr_reader :address
# The total amount that was moved to your balance. This is almost always equal to the amount charged. In rare cases when customers deposit excess funds and we are unable to refund those, those funds get moved to your balance and show up in amount_charged as well. The amount charged is expressed in the source's currency.
sig { returns(Integer) }
attr_reader :amount_charged
# The total amount received by the receiver source. `amount_received = amount_returned + amount_charged` should be true for consumed sources unless customers deposit excess funds. The amount received is expressed in the source's currency.
sig { returns(Integer) }
attr_reader :amount_received
# The total amount that was returned to the customer. The amount returned is expressed in the source's currency.
sig { returns(Integer) }
attr_reader :amount_returned
# Type of refund attribute method, one of `email`, `manual`, or `none`.
sig { returns(String) }
attr_reader :refund_attributes_method
# Type of refund attribute status, one of `missing`, `requested`, or `available`.
sig { returns(String) }
attr_reader :refund_attributes_status
end
class Redirect < Stripe::StripeObject
# The failure reason for the redirect, either `user_abort` (the customer aborted or dropped out of the redirect flow), `declined` (the authentication failed or the transaction was declined), or `processing_error` (the redirect failed due to a technical error). Present only if the redirect status is `failed`.
sig { returns(T.nilable(String)) }
attr_reader :failure_reason
# The URL you provide to redirect the customer to after they authenticated their payment.
sig { returns(String) }
attr_reader :return_url
# The status of the redirect, either `pending` (ready to be used by your customer to authenticate the transaction), `succeeded` (succesful authentication, cannot be reused) or `not_required` (redirect should not be used) or `failed` (failed authentication, cannot be reused).
sig { returns(String) }
attr_reader :status
# The URL provided to you to redirect a customer to as part of a `redirect` authentication flow.
sig { returns(String) }
attr_reader :url
end
class SepaCreditTransfer < Stripe::StripeObject
# Attribute for field bank_name
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# Attribute for field bic
sig { returns(T.nilable(String)) }
attr_reader :bic
# Attribute for field iban
sig { returns(T.nilable(String)) }
attr_reader :iban
# Attribute for field refund_account_holder_address_city
sig { returns(T.nilable(String)) }
attr_reader :refund_account_holder_address_city
# Attribute for field refund_account_holder_address_country
sig { returns(T.nilable(String)) }
attr_reader :refund_account_holder_address_country
# Attribute for field refund_account_holder_address_line1
sig { returns(T.nilable(String)) }
attr_reader :refund_account_holder_address_line1
# Attribute for field refund_account_holder_address_line2
sig { returns(T.nilable(String)) }
attr_reader :refund_account_holder_address_line2
# Attribute for field refund_account_holder_address_postal_code
sig { returns(T.nilable(String)) }
attr_reader :refund_account_holder_address_postal_code
# Attribute for field refund_account_holder_address_state
sig { returns(T.nilable(String)) }
attr_reader :refund_account_holder_address_state
# Attribute for field refund_account_holder_name
sig { returns(T.nilable(String)) }
attr_reader :refund_account_holder_name
# Attribute for field refund_iban
sig { returns(T.nilable(String)) }
attr_reader :refund_iban
end
class SepaDebit < Stripe::StripeObject
# Attribute for field bank_code
sig { returns(T.nilable(String)) }
attr_reader :bank_code
# Attribute for field branch_code
sig { returns(T.nilable(String)) }
attr_reader :branch_code
# Attribute for field country
sig { returns(T.nilable(String)) }
attr_reader :country
# Attribute for field fingerprint
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Attribute for field last4
sig { returns(T.nilable(String)) }
attr_reader :last4
# Attribute for field mandate_reference
sig { returns(T.nilable(String)) }
attr_reader :mandate_reference
# Attribute for field mandate_url
sig { returns(T.nilable(String)) }
attr_reader :mandate_url
end
class Sofort < Stripe::StripeObject
# Attribute for field bank_code
sig { returns(T.nilable(String)) }
attr_reader :bank_code
# Attribute for field bank_name
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# Attribute for field bic
sig { returns(T.nilable(String)) }
attr_reader :bic
# Attribute for field country
sig { returns(T.nilable(String)) }
attr_reader :country
# Attribute for field iban_last4
sig { returns(T.nilable(String)) }
attr_reader :iban_last4
# Attribute for field preferred_language
sig { returns(T.nilable(String)) }
attr_reader :preferred_language
# Attribute for field statement_descriptor
sig { returns(T.nilable(String)) }
attr_reader :statement_descriptor
end
class SourceOrder < Stripe::StripeObject
class Item < Stripe::StripeObject
# The amount (price) for this order item.
sig { returns(T.nilable(Integer)) }
attr_reader :amount
# This currency of this order item. Required when `amount` is present.
sig { returns(T.nilable(String)) }
attr_reader :currency
# Human-readable description for this order item.
sig { returns(T.nilable(String)) }
attr_reader :description
# The ID of the associated object for this line item. Expandable if not null (e.g., expandable to a SKU).
sig { returns(T.nilable(String)) }
attr_reader :parent
# The quantity of this order item. When type is `sku`, this is the number of instances of the SKU to be ordered.
sig { returns(Integer) }
attr_reader :quantity
# The type of this order item. Must be `sku`, `tax`, or `shipping`.
sig { returns(T.nilable(String)) }
attr_reader :type
end
class Shipping < Stripe::StripeObject
class Address < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Attribute for field address
sig { returns(Address) }
attr_reader :address
# The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
sig { returns(T.nilable(String)) }
attr_reader :carrier
# Recipient name.
sig { returns(String) }
attr_reader :name
# Recipient phone (including extension).
sig { returns(T.nilable(String)) }
attr_reader :phone
# The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
sig { returns(T.nilable(String)) }
attr_reader :tracking_number
end
# A positive integer in the smallest currency unit (that is, 100 cents for $1.00, or 1 for ¥1, Japanese Yen being a zero-decimal currency) representing the total amount for the order.
sig { returns(Integer) }
attr_reader :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).
sig { returns(String) }
attr_reader :currency
# The email address of the customer placing the order.
sig { returns(String) }
attr_reader :email
# List of items constituting the order.
sig { returns(T.nilable(T::Array[Item])) }
attr_reader :items
# Attribute for field shipping
sig { returns(Shipping) }
attr_reader :shipping
end
class ThreeDSecure < Stripe::StripeObject
# Attribute for field address_line1_check
sig { returns(T.nilable(String)) }
attr_reader :address_line1_check
# Attribute for field address_zip_check
sig { returns(T.nilable(String)) }
attr_reader :address_zip_check
# Attribute for field authenticated
sig { returns(T.nilable(T::Boolean)) }
attr_reader :authenticated
# Attribute for field brand
sig { returns(T.nilable(String)) }
attr_reader :brand
# Attribute for field brand_product
sig { returns(T.nilable(String)) }
attr_reader :brand_product
# Attribute for field card
sig { returns(T.nilable(String)) }
attr_reader :card
# Attribute for field country
sig { returns(T.nilable(String)) }
attr_reader :country
# Attribute for field customer
sig { returns(T.nilable(String)) }
attr_reader :customer
# Attribute for field cvc_check
sig { returns(T.nilable(String)) }
attr_reader :cvc_check
# Attribute for field description
sig { returns(String) }
attr_reader :description
# Attribute for field dynamic_last4
sig { returns(T.nilable(String)) }
attr_reader :dynamic_last4
# Attribute for field exp_month
sig { returns(T.nilable(Integer)) }
attr_reader :exp_month
# Attribute for field exp_year
sig { returns(T.nilable(Integer)) }
attr_reader :exp_year
# Attribute for field fingerprint
sig { returns(String) }
attr_reader :fingerprint
# Attribute for field funding
sig { returns(T.nilable(String)) }
attr_reader :funding
# Attribute for field iin
sig { returns(String) }
attr_reader :iin
# Attribute for field issuer
sig { returns(String) }
attr_reader :issuer
# Attribute for field last4
sig { returns(T.nilable(String)) }
attr_reader :last4
# Attribute for field name
sig { returns(T.nilable(String)) }
attr_reader :name
# Attribute for field three_d_secure
sig { returns(String) }
attr_reader :three_d_secure
# Attribute for field tokenization_method
sig { returns(T.nilable(String)) }
attr_reader :tokenization_method
end
class Wechat < Stripe::StripeObject
# Attribute for field prepay_id
sig { returns(String) }
attr_reader :prepay_id
# Attribute for field qr_code_url
sig { returns(T.nilable(String)) }
attr_reader :qr_code_url
# Attribute for field statement_descriptor
sig { returns(String) }
attr_reader :statement_descriptor
end
# Attribute for field ach_credit_transfer
sig { returns(AchCreditTransfer) }
attr_reader :ach_credit_transfer
# Attribute for field ach_debit
sig { returns(AchDebit) }
attr_reader :ach_debit
# Attribute for field acss_debit
sig { returns(AcssDebit) }
attr_reader :acss_debit
# Attribute for field alipay
sig { returns(Alipay) }
attr_reader :alipay
# This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to “unspecified”.
sig { returns(T.nilable(String)) }
attr_reader :allow_redisplay
# A positive integer in the smallest currency unit (that is, 100 cents for $1.00, or 1 for ¥1, Japanese Yen being a zero-decimal currency) representing the total amount associated with the source. This is the amount for which the source will be chargeable once ready. Required for `single_use` sources.
sig { returns(T.nilable(Integer)) }
attr_reader :amount
# Attribute for field au_becs_debit
sig { returns(AuBecsDebit) }
attr_reader :au_becs_debit
# Attribute for field bancontact
sig { returns(Bancontact) }
attr_reader :bancontact
# Attribute for field card
sig { returns(Card) }
attr_reader :card
# Attribute for field card_present
sig { returns(CardPresent) }
attr_reader :card_present
# The client secret of the source. Used for client-side retrieval using a publishable key.
sig { returns(String) }
attr_reader :client_secret
# Attribute for field code_verification
sig { returns(CodeVerification) }
attr_reader :code_verification
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# Three-letter [ISO code for the currency](https://stripe.com/docs/currencies) associated with the source. This is the currency for which the source will be chargeable once ready. Required for `single_use` sources.
sig { returns(T.nilable(String)) }
attr_reader :currency
# The ID of the customer to which this source is attached. This will not be present when the source has not been attached to a customer.
sig { returns(String) }
attr_reader :customer
# Attribute for field eps
sig { returns(Eps) }
attr_reader :eps
# The authentication `flow` of the source. `flow` is one of `redirect`, `receiver`, `code_verification`, `none`.
sig { returns(String) }
attr_reader :flow
# Attribute for field giropay
sig { returns(Giropay) }
attr_reader :giropay
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Attribute for field ideal
sig { returns(Ideal) }
attr_reader :ideal
# Attribute for field klarna
sig { returns(Klarna) }
attr_reader :klarna
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# 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.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# Attribute for field multibanco
sig { returns(Multibanco) }
attr_reader :multibanco
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Information about the owner of the payment instrument that may be used or required by particular source types.
sig { returns(T.nilable(Owner)) }
attr_reader :owner
# Attribute for field p24
sig { returns(P24) }
attr_reader :p24
# Attribute for field paypal
sig { returns(Paypal) }
attr_reader :paypal
# Attribute for field receiver
sig { returns(Receiver) }
attr_reader :receiver
# Attribute for field redirect
sig { returns(Redirect) }
attr_reader :redirect
# Attribute for field sepa_credit_transfer
sig { returns(SepaCreditTransfer) }
attr_reader :sepa_credit_transfer
# Attribute for field sepa_debit
sig { returns(SepaDebit) }
attr_reader :sepa_debit
# Attribute for field sofort
sig { returns(Sofort) }
attr_reader :sofort
# Attribute for field source_order
sig { returns(SourceOrder) }
attr_reader :source_order
# Extra information about a source. This will appear on your customer's statement every time you charge the source.
sig { returns(T.nilable(String)) }
attr_reader :statement_descriptor
# The status of the source, one of `canceled`, `chargeable`, `consumed`, `failed`, or `pending`. Only `chargeable` sources can be used to create a charge.
sig { returns(String) }
attr_reader :status
# Attribute for field three_d_secure
sig { returns(ThreeDSecure) }
attr_reader :three_d_secure
# The `type` of the source. The `type` is a payment method, one of `ach_credit_transfer`, `ach_debit`, `alipay`, `bancontact`, `card`, `card_present`, `eps`, `giropay`, `ideal`, `multibanco`, `klarna`, `p24`, `sepa_debit`, `sofort`, `three_d_secure`, or `wechat`. An additional hash is included on the source with a name matching this value. It contains additional information specific to the [payment method](https://stripe.com/docs/sources) used.
sig { returns(String) }
attr_reader :type
# Either `reusable` or `single_use`. Whether this source should be reusable or not. Some source types may or may not be reusable by construction, while others may leave the option at creation. If an incompatible value is passed, an error will be returned.
sig { returns(T.nilable(String)) }
attr_reader :usage
# Attribute for field wechat
sig { returns(Wechat) }
attr_reader :wechat
class UpdateParams < Stripe::RequestParams
class Mandate < Stripe::RequestParams
class Acceptance < Stripe::RequestParams
class Offline < Stripe::RequestParams
# An email to contact you with if a copy of the mandate is requested, required if `type` is `offline`.
sig { returns(String) }
attr_accessor :contact_email
sig { params(contact_email: String).void }
def initialize(contact_email: nil); end
end
class Online < Stripe::RequestParams
# The Unix timestamp (in seconds) when the mandate was accepted or refused by the customer.
sig { returns(T.nilable(Integer)) }
attr_accessor :date
# The IP address from which the mandate was accepted or refused by the customer.
sig { returns(T.nilable(String)) }
attr_accessor :ip
# The user agent of the browser from which the mandate was accepted or refused by the customer.
sig { returns(T.nilable(String)) }
attr_accessor :user_agent
sig {
params(date: T.nilable(Integer), ip: T.nilable(String), user_agent: T.nilable(String)).void
}
def initialize(date: nil, ip: nil, user_agent: nil); end
end
# The Unix timestamp (in seconds) when the mandate was accepted or refused by the customer.
sig { returns(T.nilable(Integer)) }
attr_accessor :date
# The IP address from which the mandate was accepted or refused by the customer.
sig { returns(T.nilable(String)) }
attr_accessor :ip
# The parameters required to store a mandate accepted offline. Should only be set if `mandate[type]` is `offline`
sig { returns(T.nilable(::Stripe::Source::UpdateParams::Mandate::Acceptance::Offline)) }
attr_accessor :offline
# The parameters required to store a mandate accepted online. Should only be set if `mandate[type]` is `online`
sig { returns(T.nilable(::Stripe::Source::UpdateParams::Mandate::Acceptance::Online)) }
attr_accessor :online
# The status of the mandate acceptance. Either `accepted` (the mandate was accepted) or `refused` (the mandate was refused).
sig { returns(String) }
attr_accessor :status
# The type of acceptance information included with the mandate. Either `online` or `offline`
sig { returns(T.nilable(String)) }
attr_accessor :type
# The user agent of the browser from which the mandate was accepted or refused by the customer.
sig { returns(T.nilable(String)) }
attr_accessor :user_agent
sig {
params(date: T.nilable(Integer), ip: T.nilable(String), offline: T.nilable(::Stripe::Source::UpdateParams::Mandate::Acceptance::Offline), online: T.nilable(::Stripe::Source::UpdateParams::Mandate::Acceptance::Online), status: String, type: T.nilable(String), user_agent: T.nilable(String)).void
}
def initialize(
date: nil,
ip: nil,
offline: nil,
online: nil,
status: nil,
type: nil,
user_agent: nil
); end
end
# The parameters required to notify Stripe of a mandate acceptance or refusal by the customer.
sig { returns(T.nilable(::Stripe::Source::UpdateParams::Mandate::Acceptance)) }
attr_accessor :acceptance
# The amount specified by the mandate. (Leave null for a mandate covering all amounts)
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :amount
# The currency specified by the mandate. (Must match `currency` of the source)
sig { returns(T.nilable(String)) }
attr_accessor :currency
# The interval of debits permitted by the mandate. Either `one_time` (just permitting a single debit), `scheduled` (with debits on an agreed schedule or for clearly-defined events), or `variable`(for debits with any frequency)
sig { returns(T.nilable(String)) }
attr_accessor :interval
# The method Stripe should use to notify the customer of upcoming debit instructions and/or mandate confirmation as required by the underlying debit network. Either `email` (an email is sent directly to the customer), `manual` (a `source.mandate_notification` event is sent to your webhooks endpoint and you should handle the notification) or `none` (the underlying debit network does not require any notification).
sig { returns(T.nilable(String)) }
attr_accessor :notification_method
sig {
params(acceptance: T.nilable(::Stripe::Source::UpdateParams::Mandate::Acceptance), amount: T.nilable(T.nilable(T.any(String, Integer))), currency: T.nilable(String), interval: T.nilable(String), notification_method: T.nilable(String)).void
}
def initialize(
acceptance: nil,
amount: nil,
currency: nil,
interval: nil,
notification_method: nil
); end
end
class Owner < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Owner's address.
sig { returns(T.nilable(::Stripe::Source::UpdateParams::Owner::Address)) }
attr_accessor :address
# Owner's email address.
sig { returns(T.nilable(String)) }
attr_accessor :email
# Owner's full name.
sig { returns(T.nilable(String)) }
attr_accessor :name
# Owner's phone number.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(address: T.nilable(::Stripe::Source::UpdateParams::Owner::Address), email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(address: nil, email: nil, name: nil, phone: nil); end
end
class SourceOrder < Stripe::RequestParams
class Item < Stripe::RequestParams
# Attribute for param field amount
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# Attribute for param field currency
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Attribute for param field description
sig { returns(T.nilable(String)) }
attr_accessor :description
# The ID of the SKU being ordered.
sig { returns(T.nilable(String)) }
attr_accessor :parent
# The quantity of this order item. When type is `sku`, this is the number of instances of the SKU to be ordered.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# Attribute for param field type
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(amount: T.nilable(Integer), currency: T.nilable(String), description: T.nilable(String), parent: T.nilable(String), quantity: T.nilable(Integer), type: T.nilable(String)).void
}
def initialize(
amount: nil,
currency: nil,
description: nil,
parent: nil,
quantity: nil,
type: nil
); end
end
class Shipping < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(String) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: String, line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Shipping address.
sig { returns(::Stripe::Source::UpdateParams::SourceOrder::Shipping::Address) }
attr_accessor :address
# The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
sig { returns(T.nilable(String)) }
attr_accessor :carrier
# Recipient name.
sig { returns(T.nilable(String)) }
attr_accessor :name
# Recipient phone (including extension).
sig { returns(T.nilable(String)) }
attr_accessor :phone
# The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
sig { returns(T.nilable(String)) }
attr_accessor :tracking_number
sig {
params(address: ::Stripe::Source::UpdateParams::SourceOrder::Shipping::Address, carrier: T.nilable(String), name: T.nilable(String), phone: T.nilable(String), tracking_number: T.nilable(String)).void
}
def initialize(
address: nil,
carrier: nil,
name: nil,
phone: nil,
tracking_number: nil
); end
end
# List of items constituting the order.
sig { returns(T.nilable(T::Array[::Stripe::Source::UpdateParams::SourceOrder::Item])) }
attr_accessor :items
# Shipping address for the order. Required if any of the SKUs are for products that have `shippable` set to true.
sig { returns(T.nilable(::Stripe::Source::UpdateParams::SourceOrder::Shipping)) }
attr_accessor :shipping
sig {
params(items: T.nilable(T::Array[::Stripe::Source::UpdateParams::SourceOrder::Item]), shipping: T.nilable(::Stripe::Source::UpdateParams::SourceOrder::Shipping)).void
}
def initialize(items: nil, shipping: nil); end
end
# Amount associated with the source.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Information about a mandate possibility attached to a source object (generally for bank debits) as well as its acceptance status.
sig { returns(T.nilable(::Stripe::Source::UpdateParams::Mandate)) }
attr_accessor :mandate
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Information about the owner of the payment instrument that may be used or required by particular source types.
sig { returns(T.nilable(::Stripe::Source::UpdateParams::Owner)) }
attr_accessor :owner
# Information about the items and shipping associated with the source. Required for transactional credit (for example Klarna) sources before you can charge it.
sig { returns(T.nilable(::Stripe::Source::UpdateParams::SourceOrder)) }
attr_accessor :source_order
sig {
params(amount: T.nilable(Integer), expand: T.nilable(T::Array[String]), mandate: T.nilable(::Stripe::Source::UpdateParams::Mandate), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), owner: T.nilable(::Stripe::Source::UpdateParams::Owner), source_order: T.nilable(::Stripe::Source::UpdateParams::SourceOrder)).void
}
def initialize(
amount: nil,
expand: nil,
mandate: nil,
metadata: nil,
owner: nil,
source_order: nil
); end
end
class CreateParams < Stripe::RequestParams
class Mandate < Stripe::RequestParams
class Acceptance < Stripe::RequestParams
class Offline < Stripe::RequestParams
# An email to contact you with if a copy of the mandate is requested, required if `type` is `offline`.
sig { returns(String) }
attr_accessor :contact_email
sig { params(contact_email: String).void }
def initialize(contact_email: nil); end
end
class Online < Stripe::RequestParams
# The Unix timestamp (in seconds) when the mandate was accepted or refused by the customer.
sig { returns(T.nilable(Integer)) }
attr_accessor :date
# The IP address from which the mandate was accepted or refused by the customer.
sig { returns(T.nilable(String)) }
attr_accessor :ip
# The user agent of the browser from which the mandate was accepted or refused by the customer.
sig { returns(T.nilable(String)) }
attr_accessor :user_agent
sig {
params(date: T.nilable(Integer), ip: T.nilable(String), user_agent: T.nilable(String)).void
}
def initialize(date: nil, ip: nil, user_agent: nil); end
end
# The Unix timestamp (in seconds) when the mandate was accepted or refused by the customer.
sig { returns(T.nilable(Integer)) }
attr_accessor :date
# The IP address from which the mandate was accepted or refused by the customer.
sig { returns(T.nilable(String)) }
attr_accessor :ip
# The parameters required to store a mandate accepted offline. Should only be set if `mandate[type]` is `offline`
sig { returns(T.nilable(::Stripe::Source::CreateParams::Mandate::Acceptance::Offline)) }
attr_accessor :offline
# The parameters required to store a mandate accepted online. Should only be set if `mandate[type]` is `online`
sig { returns(T.nilable(::Stripe::Source::CreateParams::Mandate::Acceptance::Online)) }
attr_accessor :online
# The status of the mandate acceptance. Either `accepted` (the mandate was accepted) or `refused` (the mandate was refused).
sig { returns(String) }
attr_accessor :status
# The type of acceptance information included with the mandate. Either `online` or `offline`
sig { returns(T.nilable(String)) }
attr_accessor :type
# The user agent of the browser from which the mandate was accepted or refused by the customer.
sig { returns(T.nilable(String)) }
attr_accessor :user_agent
sig {
params(date: T.nilable(Integer), ip: T.nilable(String), offline: T.nilable(::Stripe::Source::CreateParams::Mandate::Acceptance::Offline), online: T.nilable(::Stripe::Source::CreateParams::Mandate::Acceptance::Online), status: String, type: T.nilable(String), user_agent: T.nilable(String)).void
}
def initialize(
date: nil,
ip: nil,
offline: nil,
online: nil,
status: nil,
type: nil,
user_agent: nil
); end
end
# The parameters required to notify Stripe of a mandate acceptance or refusal by the customer.
sig { returns(T.nilable(::Stripe::Source::CreateParams::Mandate::Acceptance)) }
attr_accessor :acceptance
# The amount specified by the mandate. (Leave null for a mandate covering all amounts)
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :amount
# The currency specified by the mandate. (Must match `currency` of the source)
sig { returns(T.nilable(String)) }
attr_accessor :currency
# The interval of debits permitted by the mandate. Either `one_time` (just permitting a single debit), `scheduled` (with debits on an agreed schedule or for clearly-defined events), or `variable`(for debits with any frequency)
sig { returns(T.nilable(String)) }
attr_accessor :interval
# The method Stripe should use to notify the customer of upcoming debit instructions and/or mandate confirmation as required by the underlying debit network. Either `email` (an email is sent directly to the customer), `manual` (a `source.mandate_notification` event is sent to your webhooks endpoint and you should handle the notification) or `none` (the underlying debit network does not require any notification).
sig { returns(T.nilable(String)) }
attr_accessor :notification_method
sig {
params(acceptance: T.nilable(::Stripe::Source::CreateParams::Mandate::Acceptance), amount: T.nilable(T.nilable(T.any(String, Integer))), currency: T.nilable(String), interval: T.nilable(String), notification_method: T.nilable(String)).void
}
def initialize(
acceptance: nil,
amount: nil,
currency: nil,
interval: nil,
notification_method: nil
); end
end
class Owner < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Owner's address.
sig { returns(T.nilable(::Stripe::Source::CreateParams::Owner::Address)) }
attr_accessor :address
# Owner's email address.
sig { returns(T.nilable(String)) }
attr_accessor :email
# Owner's full name.
sig { returns(T.nilable(String)) }
attr_accessor :name
# Owner's phone number.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(address: T.nilable(::Stripe::Source::CreateParams::Owner::Address), email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(address: nil, email: nil, name: nil, phone: nil); end
end
class Receiver < Stripe::RequestParams
# The method Stripe should use to request information needed to process a refund or mispayment. Either `email` (an email is sent directly to the customer) or `manual` (a `source.refund_attributes_required` event is sent to your webhooks endpoint). Refer to each payment method's documentation to learn which refund attributes may be required.
sig { returns(T.nilable(String)) }
attr_accessor :refund_attributes_method
sig { params(refund_attributes_method: T.nilable(String)).void }
def initialize(refund_attributes_method: nil); end
end
class Redirect < Stripe::RequestParams
# The URL you provide to redirect the customer back to you after they authenticated their payment. It can use your application URI scheme in the context of a mobile application.
sig { returns(String) }
attr_accessor :return_url
sig { params(return_url: String).void }
def initialize(return_url: nil); end
end
class SourceOrder < Stripe::RequestParams
class Item < Stripe::RequestParams
# Attribute for param field amount
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# Attribute for param field currency
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Attribute for param field description
sig { returns(T.nilable(String)) }
attr_accessor :description
# The ID of the SKU being ordered.
sig { returns(T.nilable(String)) }
attr_accessor :parent
# The quantity of this order item. When type is `sku`, this is the number of instances of the SKU to be ordered.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# Attribute for param field type
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(amount: T.nilable(Integer), currency: T.nilable(String), description: T.nilable(String), parent: T.nilable(String), quantity: T.nilable(Integer), type: T.nilable(String)).void
}
def initialize(
amount: nil,
currency: nil,
description: nil,
parent: nil,
quantity: nil,
type: nil
); end
end
class Shipping < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(String) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: String, line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Shipping address.
sig { returns(::Stripe::Source::CreateParams::SourceOrder::Shipping::Address) }
attr_accessor :address
# The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
sig { returns(T.nilable(String)) }
attr_accessor :carrier
# Recipient name.
sig { returns(T.nilable(String)) }
attr_accessor :name
# Recipient phone (including extension).
sig { returns(T.nilable(String)) }
attr_accessor :phone
# The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
sig { returns(T.nilable(String)) }
attr_accessor :tracking_number
sig {
params(address: ::Stripe::Source::CreateParams::SourceOrder::Shipping::Address, carrier: T.nilable(String), name: T.nilable(String), phone: T.nilable(String), tracking_number: T.nilable(String)).void
}
def initialize(
address: nil,
carrier: nil,
name: nil,
phone: nil,
tracking_number: nil
); end
end
# List of items constituting the order.
sig { returns(T.nilable(T::Array[::Stripe::Source::CreateParams::SourceOrder::Item])) }
attr_accessor :items
# Shipping address for the order. Required if any of the SKUs are for products that have `shippable` set to true.
sig { returns(T.nilable(::Stripe::Source::CreateParams::SourceOrder::Shipping)) }
attr_accessor :shipping
sig {
params(items: T.nilable(T::Array[::Stripe::Source::CreateParams::SourceOrder::Item]), shipping: T.nilable(::Stripe::Source::CreateParams::SourceOrder::Shipping)).void
}
def initialize(items: nil, shipping: nil); end
end
# Amount associated with the source. This is the amount for which the source will be chargeable once ready. Required for `single_use` sources. Not supported for `receiver` type sources, where charge amount may not be specified until funds land.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# Three-letter [ISO code for the currency](https://stripe.com/docs/currencies) associated with the source. This is the currency for which the source will be chargeable once ready.
sig { returns(T.nilable(String)) }
attr_accessor :currency
# The `Customer` to whom the original source is attached to. Must be set when the original source is not a `Source` (e.g., `Card`).
sig { returns(T.nilable(String)) }
attr_accessor :customer
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The authentication `flow` of the source to create. `flow` is one of `redirect`, `receiver`, `code_verification`, `none`. It is generally inferred unless a type supports multiple flows.
sig { returns(T.nilable(String)) }
attr_accessor :flow
# Information about a mandate possibility attached to a source object (generally for bank debits) as well as its acceptance status.
sig { returns(T.nilable(::Stripe::Source::CreateParams::Mandate)) }
attr_accessor :mandate
# Attribute for param field metadata
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The source to share.
sig { returns(T.nilable(String)) }
attr_accessor :original_source
# Information about the owner of the payment instrument that may be used or required by particular source types.
sig { returns(T.nilable(::Stripe::Source::CreateParams::Owner)) }
attr_accessor :owner
# Optional parameters for the receiver flow. Can be set only if the source is a receiver (`flow` is `receiver`).
sig { returns(T.nilable(::Stripe::Source::CreateParams::Receiver)) }
attr_accessor :receiver
# Parameters required for the redirect flow. Required if the source is authenticated by a redirect (`flow` is `redirect`).
sig { returns(T.nilable(::Stripe::Source::CreateParams::Redirect)) }
attr_accessor :redirect
# Information about the items and shipping associated with the source. Required for transactional credit (for example Klarna) sources before you can charge it.
sig { returns(T.nilable(::Stripe::Source::CreateParams::SourceOrder)) }
attr_accessor :source_order
# An arbitrary string to be displayed on your customer's statement. As an example, if your website is `RunClub` and the item you're charging for is a race ticket, you may want to specify a `statement_descriptor` of `RunClub 5K race ticket.` While many payment types will display this information, some may not display it at all.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
# An optional token used to create the source. When passed, token properties will override source parameters.
sig { returns(T.nilable(String)) }
attr_accessor :token
# The `type` of the source to create. Required unless `customer` and `original_source` are specified (see the [Cloning card Sources](https://stripe.com/docs/sources/connect#cloning-card-sources) guide)
sig { returns(T.nilable(String)) }
attr_accessor :type
# Attribute for param field usage
sig { returns(T.nilable(String)) }
attr_accessor :usage
sig {
params(amount: T.nilable(Integer), currency: T.nilable(String), customer: T.nilable(String), expand: T.nilable(T::Array[String]), flow: T.nilable(String), mandate: T.nilable(::Stripe::Source::CreateParams::Mandate), metadata: T.nilable(T::Hash[String, String]), original_source: T.nilable(String), owner: T.nilable(::Stripe::Source::CreateParams::Owner), receiver: T.nilable(::Stripe::Source::CreateParams::Receiver), redirect: T.nilable(::Stripe::Source::CreateParams::Redirect), source_order: T.nilable(::Stripe::Source::CreateParams::SourceOrder), statement_descriptor: T.nilable(String), token: T.nilable(String), type: T.nilable(String), usage: T.nilable(String)).void
}
def initialize(
amount: nil,
currency: nil,
customer: nil,
expand: nil,
flow: nil,
mandate: nil,
metadata: nil,
original_source: nil,
owner: nil,
receiver: nil,
redirect: nil,
source_order: nil,
statement_descriptor: nil,
token: nil,
type: nil,
usage: nil
); end
end
class VerifyParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The values needed to verify the source.
sig { returns(T::Array[String]) }
attr_accessor :values
sig { params(expand: T.nilable(T::Array[String]), values: T::Array[String]).void }
def initialize(expand: nil, values: nil); end
end
# Creates a new source object.
sig {
params(params: T.any(::Stripe::Source::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Source)
}
def self.create(params = {}, opts = {}); end
# Updates the specified source by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
#
# This request accepts the metadata and owner as arguments. It is also possible to update type specific information for selected payment methods. Please refer to our [payment method guides](https://docs.stripe.com/docs/sources) for more detail.
sig {
params(source: String, params: T.any(::Stripe::Source::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Source)
}
def self.update(source, params = {}, opts = {}); end
# Verify a given source.
sig {
params(params: T.any(::Stripe::Source::VerifyParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Source)
}
def verify(params = {}, opts = {}); end
# Verify a given source.
sig {
params(source: String, params: T.any(::Stripe::Source::VerifyParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Source)
}
def self.verify(source, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
# Source mandate notifications should be created when a notification related to
# a source mandate must be sent to the payer. They will trigger a webhook or
# deliver an email to the customer.
class SourceMandateNotification < APIResource
class AcssDebit < Stripe::StripeObject
# The statement descriptor associate with the debit.
sig { returns(String) }
attr_reader :statement_descriptor
end
class BacsDebit < Stripe::StripeObject
# Last 4 digits of the account number associated with the debit.
sig { returns(String) }
attr_reader :last4
end
class SepaDebit < Stripe::StripeObject
# SEPA creditor ID.
sig { returns(String) }
attr_reader :creditor_identifier
# Last 4 digits of the account number associated with the debit.
sig { returns(String) }
attr_reader :last4
# Mandate reference associated with the debit.
sig { returns(String) }
attr_reader :mandate_reference
end
# Attribute for field acss_debit
sig { returns(AcssDebit) }
attr_reader :acss_debit
# A positive integer in the smallest currency unit (that is, 100 cents for $1.00, or 1 for ¥1, Japanese Yen being a zero-decimal currency) representing the amount associated with the mandate notification. The amount is expressed in the currency of the underlying source. Required if the notification type is `debit_initiated`.
sig { returns(T.nilable(Integer)) }
attr_reader :amount
# Attribute for field bacs_debit
sig { returns(BacsDebit) }
attr_reader :bacs_debit
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The reason of the mandate notification. Valid reasons are `mandate_confirmed` or `debit_initiated`.
sig { returns(String) }
attr_reader :reason
# Attribute for field sepa_debit
sig { returns(SepaDebit) }
attr_reader :sepa_debit
# `Source` objects allow you to accept a variety of payment methods. They
# represent a customer's payment instrument, and can be used with the Stripe API
# just like a `Card` object: once chargeable, they can be charged, or can be
# attached to customers.
#
# Stripe doesn't recommend using the deprecated [Sources API](https://stripe.com/docs/api/sources).
# We recommend that you adopt the [PaymentMethods API](https://stripe.com/docs/api/payment_methods).
# This newer API provides access to our latest features and payment method types.
#
# Related guides: [Sources API](https://stripe.com/docs/sources) and [Sources & Customers](https://stripe.com/docs/sources/customers).
sig { returns(Stripe::Source) }
attr_reader :source
# The status of the mandate notification. Valid statuses are `pending` or `submitted`.
sig { returns(String) }
attr_reader :status
# The type of source this mandate notification is attached to. Should be the source type identifier code for the payment method, such as `three_d_secure`.
sig { returns(String) }
attr_reader :type
end
end
# typed: true
module Stripe
# Some payment methods have no required amount that a customer must send.
# Customers can be instructed to send any amount, and it can be made up of
# multiple transactions. As such, sources can have multiple associated
# transactions.
class SourceTransaction < StripeObject
class AchCreditTransfer < Stripe::StripeObject
# Customer data associated with the transfer.
sig { returns(String) }
attr_reader :customer_data
# Bank account fingerprint associated with the transfer.
sig { returns(String) }
attr_reader :fingerprint
# Last 4 digits of the account number associated with the transfer.
sig { returns(String) }
attr_reader :last4
# Routing number associated with the transfer.
sig { returns(String) }
attr_reader :routing_number
end
class ChfCreditTransfer < Stripe::StripeObject
# Reference associated with the transfer.
sig { returns(String) }
attr_reader :reference
# Sender's country address.
sig { returns(String) }
attr_reader :sender_address_country
# Sender's line 1 address.
sig { returns(String) }
attr_reader :sender_address_line1
# Sender's bank account IBAN.
sig { returns(String) }
attr_reader :sender_iban
# Sender's name.
sig { returns(String) }
attr_reader :sender_name
end
class GbpCreditTransfer < Stripe::StripeObject
# Bank account fingerprint associated with the Stripe owned bank account receiving the transfer.
sig { returns(String) }
attr_reader :fingerprint
# The credit transfer rails the sender used to push this transfer. The possible rails are: Faster Payments, BACS, CHAPS, and wire transfers. Currently only Faster Payments is supported.
sig { returns(String) }
attr_reader :funding_method
# Last 4 digits of sender account number associated with the transfer.
sig { returns(String) }
attr_reader :last4
# Sender entered arbitrary information about the transfer.
sig { returns(String) }
attr_reader :reference
# Sender account number associated with the transfer.
sig { returns(String) }
attr_reader :sender_account_number
# Sender name associated with the transfer.
sig { returns(String) }
attr_reader :sender_name
# Sender sort code associated with the transfer.
sig { returns(String) }
attr_reader :sender_sort_code
end
class PaperCheck < Stripe::StripeObject
# Time at which the deposited funds will be available for use. Measured in seconds since the Unix epoch.
sig { returns(String) }
attr_reader :available_at
# Comma-separated list of invoice IDs associated with the paper check.
sig { returns(String) }
attr_reader :invoices
end
class SepaCreditTransfer < Stripe::StripeObject
# Reference associated with the transfer.
sig { returns(String) }
attr_reader :reference
# Sender's bank account IBAN.
sig { returns(String) }
attr_reader :sender_iban
# Sender's name.
sig { returns(String) }
attr_reader :sender_name
end
# Attribute for field ach_credit_transfer
sig { returns(AchCreditTransfer) }
attr_reader :ach_credit_transfer
# A positive integer in the smallest currency unit (that is, 100 cents for $1.00, or 1 for ¥1, Japanese Yen being a zero-decimal currency) representing the amount your customer has pushed to the receiver.
sig { returns(Integer) }
attr_reader :amount
# Attribute for field chf_credit_transfer
sig { returns(ChfCreditTransfer) }
attr_reader :chf_credit_transfer
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# 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).
sig { returns(String) }
attr_reader :currency
# Attribute for field gbp_credit_transfer
sig { returns(GbpCreditTransfer) }
attr_reader :gbp_credit_transfer
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Attribute for field paper_check
sig { returns(PaperCheck) }
attr_reader :paper_check
# Attribute for field sepa_credit_transfer
sig { returns(SepaCreditTransfer) }
attr_reader :sepa_credit_transfer
# The ID of the source this transaction is attached to.
sig { returns(String) }
attr_reader :source
# The status of the transaction, one of `succeeded`, `pending`, or `failed`.
sig { returns(String) }
attr_reader :status
# The type of source this transaction is attached to.
sig { returns(String) }
attr_reader :type
end
end
# typed: true
module Stripe
# Subscriptions allow you to charge a customer on a recurring basis.
#
# Related guide: [Creating subscriptions](https://stripe.com/docs/billing/subscriptions/creating)
class Subscription < APIResource
class AutomaticTax < Stripe::StripeObject
class Liability < Stripe::StripeObject
# The connected account being referenced when `type` is `account`.
sig { returns(T.any(String, Stripe::Account)) }
attr_reader :account
# Type of the account referenced.
sig { returns(String) }
attr_reader :type
end
# If Stripe disabled automatic tax, this enum describes why.
sig { returns(T.nilable(String)) }
attr_reader :disabled_reason
# Whether Stripe automatically computes tax on this subscription.
sig { returns(T::Boolean) }
attr_reader :enabled
# The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
sig { returns(T.nilable(Liability)) }
attr_reader :liability
end
class BillingCycleAnchorConfig < Stripe::StripeObject
# The day of the month of the billing_cycle_anchor.
sig { returns(Integer) }
attr_reader :day_of_month
# The hour of the day of the billing_cycle_anchor.
sig { returns(T.nilable(Integer)) }
attr_reader :hour
# The minute of the hour of the billing_cycle_anchor.
sig { returns(T.nilable(Integer)) }
attr_reader :minute
# The month to start full cycle billing periods.
sig { returns(T.nilable(Integer)) }
attr_reader :month
# The second of the minute of the billing_cycle_anchor.
sig { returns(T.nilable(Integer)) }
attr_reader :second
end
class BillingModeDetails < Stripe::StripeObject
# Details on when the current billing_mode was adopted.
sig { returns(Integer) }
attr_reader :updated_at
end
class BillingThresholds < Stripe::StripeObject
# Monetary threshold that triggers the subscription to create an invoice
sig { returns(T.nilable(Integer)) }
attr_reader :amount_gte
# Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged. This value may not be `true` if the subscription contains items with plans that have `aggregate_usage=last_ever`.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :reset_billing_cycle_anchor
end
class CancellationDetails < Stripe::StripeObject
# Additional comments about why the user canceled the subscription, if the subscription was canceled explicitly by the user.
sig { returns(T.nilable(String)) }
attr_reader :comment
# The customer submitted reason for why they canceled, if the subscription was canceled explicitly by the user.
sig { returns(T.nilable(String)) }
attr_reader :feedback
# Why this subscription was canceled.
sig { returns(T.nilable(String)) }
attr_reader :reason
end
class InvoiceSettings < Stripe::StripeObject
class Issuer < Stripe::StripeObject
# The connected account being referenced when `type` is `account`.
sig { returns(T.any(String, Stripe::Account)) }
attr_reader :account
# Type of the account referenced.
sig { returns(String) }
attr_reader :type
end
# The account tax IDs associated with the subscription. Will be set on invoices generated by the subscription.
sig { returns(T.nilable(T::Array[T.any(String, Stripe::TaxId)])) }
attr_reader :account_tax_ids
# Attribute for field issuer
sig { returns(Issuer) }
attr_reader :issuer
end
class LastPriceMigrationError < Stripe::StripeObject
class FailedTransition < Stripe::StripeObject
# The original price to be migrated.
sig { returns(String) }
attr_reader :source_price
# The intended resulting price of the migration.
sig { returns(String) }
attr_reader :target_price
end
# The time at which the price migration encountered an error.
sig { returns(Integer) }
attr_reader :errored_at
# The involved price pairs in each failed transition.
sig { returns(T::Array[FailedTransition]) }
attr_reader :failed_transitions
# The type of error encountered by the price migration.
sig { returns(String) }
attr_reader :type
end
class PauseCollection < Stripe::StripeObject
# The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`.
sig { returns(String) }
attr_reader :behavior
# The time after which the subscription will resume collecting payments.
sig { returns(T.nilable(Integer)) }
attr_reader :resumes_at
end
class PaymentSettings < Stripe::StripeObject
class PaymentMethodOptions < Stripe::StripeObject
class AcssDebit < Stripe::StripeObject
class MandateOptions < Stripe::StripeObject
# Transaction type of the mandate.
sig { returns(T.nilable(String)) }
attr_reader :transaction_type
end
# Attribute for field mandate_options
sig { returns(MandateOptions) }
attr_reader :mandate_options
# Bank account verification method.
sig { returns(String) }
attr_reader :verification_method
end
class Bancontact < Stripe::StripeObject
# Preferred language of the Bancontact authorization page that the customer is redirected to.
sig { returns(String) }
attr_reader :preferred_language
end
class Card < Stripe::StripeObject
class MandateOptions < Stripe::StripeObject
# Amount to be charged for future payments.
sig { returns(T.nilable(Integer)) }
attr_reader :amount
# One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.
sig { returns(T.nilable(String)) }
attr_reader :amount_type
# A description of the mandate or subscription that is meant to be displayed to the customer.
sig { returns(T.nilable(String)) }
attr_reader :description
end
# Attribute for field mandate_options
sig { returns(MandateOptions) }
attr_reader :mandate_options
# Selected network to process this Subscription on. Depends on the available networks of the card attached to the Subscription. Can be only set confirm-time.
sig { returns(T.nilable(String)) }
attr_reader :network
# We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
sig { returns(T.nilable(String)) }
attr_reader :request_three_d_secure
end
class CustomerBalance < Stripe::StripeObject
class BankTransfer < Stripe::StripeObject
class EuBankTransfer < Stripe::StripeObject
# The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
sig { returns(String) }
attr_reader :country
end
# Attribute for field eu_bank_transfer
sig { returns(EuBankTransfer) }
attr_reader :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`, `mx_bank_transfer`, or `us_bank_transfer`.
sig { returns(T.nilable(String)) }
attr_reader :type
end
# Attribute for field bank_transfer
sig { returns(BankTransfer) }
attr_reader :bank_transfer
# The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
sig { returns(T.nilable(String)) }
attr_reader :funding_type
end
class IdBankTransfer < Stripe::StripeObject; end
class Konbini < Stripe::StripeObject; end
class SepaDebit < Stripe::StripeObject; end
class UsBankAccount < Stripe::StripeObject
class FinancialConnections < Stripe::StripeObject
class Filters < Stripe::StripeObject
# The account subcategories to use to filter for possible accounts to link. Valid subcategories are `checking` and `savings`.
sig { returns(T::Array[String]) }
attr_reader :account_subcategories
# The institution to use to filter for possible accounts to link.
sig { returns(String) }
attr_reader :institution
end
# Attribute for field filters
sig { returns(Filters) }
attr_reader :filters
# The list of permissions to request. The `payment_method` permission must be included.
sig { returns(T::Array[String]) }
attr_reader :permissions
# Data features requested to be retrieved upon account creation.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :prefetch
end
# Attribute for field financial_connections
sig { returns(FinancialConnections) }
attr_reader :financial_connections
# Bank account verification method.
sig { returns(String) }
attr_reader :verification_method
end
# This sub-hash contains details about the Canadian pre-authorized debit payment method options to pass to invoices created by the subscription.
sig { returns(T.nilable(AcssDebit)) }
attr_reader :acss_debit
# This sub-hash contains details about the Bancontact payment method options to pass to invoices created by the subscription.
sig { returns(T.nilable(Bancontact)) }
attr_reader :bancontact
# This sub-hash contains details about the Card payment method options to pass to invoices created by the subscription.
sig { returns(T.nilable(Card)) }
attr_reader :card
# This sub-hash contains details about the Bank transfer payment method options to pass to invoices created by the subscription.
sig { returns(T.nilable(CustomerBalance)) }
attr_reader :customer_balance
# This sub-hash contains details about the Indonesia bank transfer payment method options to pass to invoices created by the subscription.
sig { returns(T.nilable(IdBankTransfer)) }
attr_reader :id_bank_transfer
# This sub-hash contains details about the Konbini payment method options to pass to invoices created by the subscription.
sig { returns(T.nilable(Konbini)) }
attr_reader :konbini
# This sub-hash contains details about the SEPA Direct Debit payment method options to pass to invoices created by the subscription.
sig { returns(T.nilable(SepaDebit)) }
attr_reader :sepa_debit
# This sub-hash contains details about the ACH direct debit payment method options to pass to invoices created by the subscription.
sig { returns(T.nilable(UsBankAccount)) }
attr_reader :us_bank_account
end
# Payment-method-specific configuration to provide to invoices created by the subscription.
sig { returns(T.nilable(PaymentMethodOptions)) }
attr_reader :payment_method_options
# The list of payment method types to provide to every invoice created by the subscription. If not set, Stripe attempts to automatically determine the types to use by looking at the invoice’s default payment method, the subscription’s default payment method, the customer’s default payment method, and your [invoice template settings](https://dashboard.stripe.com/settings/billing/invoice).
sig { returns(T.nilable(T::Array[String])) }
attr_reader :payment_method_types
# Configure whether Stripe updates `subscription.default_payment_method` when payment succeeds. Defaults to `off`.
sig { returns(T.nilable(String)) }
attr_reader :save_default_payment_method
end
class PendingInvoiceItemInterval < Stripe::StripeObject
# Specifies invoicing frequency. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_reader :interval
# The number of intervals between invoices. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks).
sig { returns(Integer) }
attr_reader :interval_count
end
class PendingUpdate < Stripe::StripeObject
# If the update is applied, determines the date of the first full invoice, and, for plans with `month` or `year` intervals, the day of the month for subsequent invoices. The timestamp is in UTC format.
sig { returns(T.nilable(Integer)) }
attr_reader :billing_cycle_anchor
# The point after which the changes reflected by this update will be discarded and no longer applied.
sig { returns(Integer) }
attr_reader :expires_at
# The number of iterations of prebilling to apply.
sig { returns(T.nilable(Integer)) }
attr_reader :prebilling_iterations
# List of subscription items, each with an attached plan, that will be set if the update is applied.
sig { returns(T.nilable(T::Array[Stripe::SubscriptionItem])) }
attr_reader :subscription_items
# Unix timestamp representing the end of the trial period the customer will get before being charged for the first time, if the update is applied.
sig { returns(T.nilable(Integer)) }
attr_reader :trial_end
# Indicates if a plan's `trial_period_days` should be applied to the subscription. Setting `trial_end` per subscription is preferred, and this defaults to `false`. Setting this flag to `true` together with `trial_end` is not allowed. See [Using trial periods on subscriptions](https://stripe.com/docs/billing/subscriptions/trials) to learn more.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :trial_from_plan
end
class Prebilling < Stripe::StripeObject
# ID of the prebilling invoice.
sig { returns(T.any(String, Stripe::Invoice)) }
attr_reader :invoice
# The end of the last period for which the invoice pre-bills.
sig { returns(Integer) }
attr_reader :period_end
# The start of the first period for which the invoice pre-bills.
sig { returns(Integer) }
attr_reader :period_start
# Whether to cancel or preserve `prebilling` if the subscription is updated during the prebilled period.
sig { returns(String) }
attr_reader :update_behavior
end
class TransferData < Stripe::StripeObject
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
sig { returns(T.nilable(Float)) }
attr_reader :amount_percent
# The account where funds from the payment will be transferred to upon payment success.
sig { returns(T.any(String, Stripe::Account)) }
attr_reader :destination
end
class TrialSettings < Stripe::StripeObject
class EndBehavior < Stripe::StripeObject
# Indicates how the subscription should change when the trial ends if the user did not provide a payment method.
sig { returns(String) }
attr_reader :missing_payment_method
end
# Defines how a subscription behaves when a free trial ends.
sig { returns(EndBehavior) }
attr_reader :end_behavior
end
# ID of the Connect Application that created the subscription.
sig { returns(T.nilable(T.any(String, Stripe::Application))) }
attr_reader :application
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account.
sig { returns(T.nilable(Float)) }
attr_reader :application_fee_percent
# Attribute for field automatic_tax
sig { returns(AutomaticTax) }
attr_reader :automatic_tax
# The reference point that aligns future [billing cycle](https://stripe.com/docs/subscriptions/billing-cycle) dates. It sets the day of week for `week` intervals, the day of month for `month` and `year` intervals, and the month of year for `year` intervals. The timestamp is in UTC format.
sig { returns(Integer) }
attr_reader :billing_cycle_anchor
# The fixed values used to calculate the `billing_cycle_anchor`.
sig { returns(T.nilable(BillingCycleAnchorConfig)) }
attr_reader :billing_cycle_anchor_config
# Controls how prorations and invoices for subscriptions are calculated and orchestrated.
sig { returns(String) }
attr_reader :billing_mode
# Details about when the current billing_mode was updated.
sig { returns(T.nilable(BillingModeDetails)) }
attr_reader :billing_mode_details
# Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period
sig { returns(T.nilable(BillingThresholds)) }
attr_reader :billing_thresholds
# A date in the future at which the subscription will automatically get canceled
sig { returns(T.nilable(Integer)) }
attr_reader :cancel_at
# Whether this subscription will (if `status=active`) or did (if `status=canceled`) cancel at the end of the current billing period. This field will be removed in a future API version. Please use `cancel_at` instead.
sig { returns(T::Boolean) }
attr_reader :cancel_at_period_end
# If the subscription has been canceled, the date of that cancellation. If the subscription was canceled with `cancel_at_period_end`, `canceled_at` will reflect the time of the most recent update request, not the end of the subscription period when the subscription is automatically moved to a canceled state.
sig { returns(T.nilable(Integer)) }
attr_reader :canceled_at
# Details about why this subscription was cancelled
sig { returns(T.nilable(CancellationDetails)) }
attr_reader :cancellation_details
# Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`.
sig { returns(String) }
attr_reader :collection_method
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# 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).
sig { returns(String) }
attr_reader :currency
# ID of the customer who owns the subscription.
sig { returns(T.any(String, Stripe::Customer)) }
attr_reader :customer
# ID of the account who owns the subscription.
sig { returns(T.nilable(String)) }
attr_reader :customer_account
# Number of days a customer has to pay invoices generated by this subscription. This value will be `null` for subscriptions where `collection_method=charge_automatically`.
sig { returns(T.nilable(Integer)) }
attr_reader :days_until_due
# ID of the default payment method for the subscription. It must belong to the customer associated with the subscription. This takes precedence over `default_source`. If neither are set, invoices will use the customer's [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) or [default_source](https://stripe.com/docs/api/customers/object#customer_object-default_source).
sig { returns(T.nilable(T.any(String, Stripe::PaymentMethod))) }
attr_reader :default_payment_method
# ID of the default payment source for the subscription. It must belong to the customer associated with the subscription and be in a chargeable state. If `default_payment_method` is also set, `default_payment_method` will take precedence. If neither are set, invoices will use the customer's [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) or [default_source](https://stripe.com/docs/api/customers/object#customer_object-default_source).
sig {
returns(T.nilable(T.any(String, T.any(Stripe::Account, Stripe::BankAccount, Stripe::Card, Stripe::Source))))
}
attr_reader :default_source
# The tax rates that will apply to any subscription item that does not have `tax_rates` set. Invoices created will have their `default_tax_rates` populated from the subscription.
sig { returns(T.nilable(T::Array[Stripe::TaxRate])) }
attr_reader :default_tax_rates
# The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
sig { returns(T.nilable(String)) }
attr_reader :description
# The discounts applied to the subscription. Subscription item discounts are applied before subscription discounts. Use `expand[]=discounts` to expand each discount.
sig { returns(T::Array[T.any(String, Stripe::Discount)]) }
attr_reader :discounts
# If the subscription has ended, the date the subscription ended.
sig { returns(T.nilable(Integer)) }
attr_reader :ended_at
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Attribute for field invoice_settings
sig { returns(InvoiceSettings) }
attr_reader :invoice_settings
# List of subscription items, each with an attached price.
sig { returns(Stripe::ListObject) }
attr_reader :items
# Details of the most recent price migration that failed for the subscription.
sig { returns(T.nilable(LastPriceMigrationError)) }
attr_reader :last_price_migration_error
# The most recent invoice this subscription has generated.
sig { returns(T.nilable(T.any(String, Stripe::Invoice))) }
attr_reader :latest_invoice
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# 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.
sig { returns(T::Hash[String, String]) }
attr_reader :metadata
# Specifies the approximate timestamp on which any pending invoice items will be billed according to the schedule provided at `pending_invoice_item_interval`.
sig { returns(T.nilable(Integer)) }
attr_reader :next_pending_invoice_item_invoice
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The account (if any) the charge was made on behalf of for charges associated with this subscription. See the [Connect documentation](https://stripe.com/docs/connect/subscriptions#on-behalf-of) for details.
sig { returns(T.nilable(T.any(String, Stripe::Account))) }
attr_reader :on_behalf_of
# If specified, payment collection for this subscription will be paused. Note that the subscription status will be unchanged and will not be updated to `paused`. Learn more about [pausing collection](https://stripe.com/docs/billing/subscriptions/pause-payment).
sig { returns(T.nilable(PauseCollection)) }
attr_reader :pause_collection
# Payment settings passed on to invoices created by the subscription.
sig { returns(T.nilable(PaymentSettings)) }
attr_reader :payment_settings
# Specifies an interval for how often to bill for any pending invoice items. It is analogous to calling [Create an invoice](https://stripe.com/docs/api#create_invoice) for the given subscription at the specified interval.
sig { returns(T.nilable(PendingInvoiceItemInterval)) }
attr_reader :pending_invoice_item_interval
# You can use this [SetupIntent](https://stripe.com/docs/api/setup_intents) to collect user authentication when creating a subscription without immediate payment or updating a subscription's payment method, allowing you to optimize for off-session payments. Learn more in the [SCA Migration Guide](https://stripe.com/docs/billing/migration/strong-customer-authentication#scenario-2).
sig { returns(T.nilable(T.any(String, Stripe::SetupIntent))) }
attr_reader :pending_setup_intent
# If specified, [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates) that will be applied to the subscription once the `latest_invoice` has been paid.
sig { returns(T.nilable(PendingUpdate)) }
attr_reader :pending_update
# Time period and invoice for a Subscription billed in advance.
sig { returns(T.nilable(Prebilling)) }
attr_reader :prebilling
# The schedule attached to the subscription
sig { returns(T.nilable(T.any(String, Stripe::SubscriptionSchedule))) }
attr_reader :schedule
# Date when the subscription was first created. The date might differ from the `created` date due to backdating.
sig { returns(Integer) }
attr_reader :start_date
# Possible values are `incomplete`, `incomplete_expired`, `trialing`, `active`, `past_due`, `canceled`, `unpaid`, or `paused`.
#
# For `collection_method=charge_automatically` a subscription moves into `incomplete` if the initial payment attempt fails. A subscription in this status can only have metadata and default_source updated. Once the first invoice is paid, the subscription moves into an `active` status. If the first invoice is not paid within 23 hours, the subscription transitions to `incomplete_expired`. This is a terminal status, the open invoice will be voided and no further invoices will be generated.
#
# A subscription that is currently in a trial period is `trialing` and moves to `active` when the trial period is over.
#
# A subscription can only enter a `paused` status [when a trial ends without a payment method](https://stripe.com/docs/billing/subscriptions/trials#create-free-trials-without-payment). A `paused` subscription doesn't generate invoices and can be resumed after your customer adds their payment method. The `paused` status is different from [pausing collection](https://stripe.com/docs/billing/subscriptions/pause-payment), which still generates invoices and leaves the subscription's status unchanged.
#
# If subscription `collection_method=charge_automatically`, it becomes `past_due` when payment is required but cannot be paid (due to failed payment or awaiting additional user actions). Once Stripe has exhausted all payment retry attempts, the subscription will become `canceled` or `unpaid` (depending on your subscriptions settings).
#
# If subscription `collection_method=send_invoice` it becomes `past_due` when its invoice is not paid by the due date, and `canceled` or `unpaid` if it is still not paid by an additional deadline after that. Note that when a subscription has a status of `unpaid`, no subsequent invoices will be attempted (invoices will be created, but then immediately automatically closed). After receiving updated payment information from a customer, you may choose to reopen and pay their closed invoices.
sig { returns(String) }
attr_reader :status
# ID of the test clock this subscription belongs to.
sig { returns(T.nilable(T.any(String, Stripe::TestHelpers::TestClock))) }
attr_reader :test_clock
# The account (if any) the subscription's payments will be attributed to for tax reporting, and where funds from each payment will be transferred to for each of the subscription's invoices.
sig { returns(T.nilable(TransferData)) }
attr_reader :transfer_data
# If the subscription has a trial, the end of that trial.
sig { returns(T.nilable(Integer)) }
attr_reader :trial_end
# Settings related to subscription trials.
sig { returns(T.nilable(TrialSettings)) }
attr_reader :trial_settings
# If the subscription has a trial, the beginning of that trial. For subsequent trials, this date remains as the start of the first ever trial on the subscription.
sig { returns(T.nilable(Integer)) }
attr_reader :trial_start
class CancelParams < Stripe::RequestParams
class CancellationDetails < Stripe::RequestParams
# Additional comments about why the user canceled the subscription, if the subscription was canceled explicitly by the user.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :comment
# The customer submitted reason for why they canceled, if the subscription was canceled explicitly by the user.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :feedback
sig {
params(comment: T.nilable(T.nilable(String)), feedback: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(comment: nil, feedback: nil); end
end
# Details about why this subscription was cancelled
sig { returns(T.nilable(::Stripe::Subscription::CancelParams::CancellationDetails)) }
attr_accessor :cancellation_details
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Will generate a final invoice that invoices for any un-invoiced metered usage and new/pending proration invoice items. Defaults to `false`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :invoice_now
# Will generate a proration invoice item that credits remaining unused time until the subscription period end. Defaults to `false`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :prorate
sig {
params(cancellation_details: T.nilable(::Stripe::Subscription::CancelParams::CancellationDetails), expand: T.nilable(T::Array[String]), invoice_now: T.nilable(T::Boolean), prorate: T.nilable(T::Boolean)).void
}
def initialize(cancellation_details: nil, expand: nil, invoice_now: nil, prorate: nil); end
end
class UpdateParams < Stripe::RequestParams
class AddInvoiceItem < Stripe::RequestParams
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::Subscription::UpdateParams::AddInvoiceItem::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::Subscription::UpdateParams::AddInvoiceItem::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::Subscription::UpdateParams::AddInvoiceItem::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::Subscription::UpdateParams::AddInvoiceItem::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class PriceData < Stripe::RequestParams
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
sig { returns(String) }
attr_accessor :product
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge or a negative integer representing the amount to credit to the customer.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, product: String, tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
# The coupons to redeem into discounts for the item.
sig {
returns(T.nilable(T::Array[::Stripe::Subscription::UpdateParams::AddInvoiceItem::Discount]))
}
attr_accessor :discounts
# The ID of the price object. One of `price` or `price_data` is required.
sig { returns(T.nilable(String)) }
attr_accessor :price
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
sig { returns(T.nilable(::Stripe::Subscription::UpdateParams::AddInvoiceItem::PriceData)) }
attr_accessor :price_data
# Quantity for this item. Defaults to 1.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# The tax rates which apply to the item. When set, the `default_tax_rates` do not apply to this item.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
sig {
params(discounts: T.nilable(T::Array[::Stripe::Subscription::UpdateParams::AddInvoiceItem::Discount]), price: T.nilable(String), price_data: T.nilable(::Stripe::Subscription::UpdateParams::AddInvoiceItem::PriceData), quantity: T.nilable(Integer), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String])))).void
}
def initialize(
discounts: nil,
price: nil,
price_data: nil,
quantity: nil,
tax_rates: nil
); end
end
class AutomaticTax < Stripe::RequestParams
class Liability < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# Enabled automatic tax calculation which will automatically compute tax rates on all invoices generated by the subscription.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
sig { returns(T.nilable(::Stripe::Subscription::UpdateParams::AutomaticTax::Liability)) }
attr_accessor :liability
sig {
params(enabled: T::Boolean, liability: T.nilable(::Stripe::Subscription::UpdateParams::AutomaticTax::Liability)).void
}
def initialize(enabled: nil, liability: nil); end
end
class BillingThresholds < Stripe::RequestParams
# Monetary threshold that triggers the subscription to advance to a new billing period
sig { returns(T.nilable(Integer)) }
attr_accessor :amount_gte
# Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :reset_billing_cycle_anchor
sig {
params(amount_gte: T.nilable(Integer), reset_billing_cycle_anchor: T.nilable(T::Boolean)).void
}
def initialize(amount_gte: nil, reset_billing_cycle_anchor: nil); end
end
class CancellationDetails < Stripe::RequestParams
# Additional comments about why the user canceled the subscription, if the subscription was canceled explicitly by the user.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :comment
# The customer submitted reason for why they canceled, if the subscription was canceled explicitly by the user.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :feedback
sig {
params(comment: T.nilable(T.nilable(String)), feedback: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(comment: nil, feedback: nil); end
end
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::Subscription::UpdateParams::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::Subscription::UpdateParams::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig { returns(T.nilable(::Stripe::Subscription::UpdateParams::Discount::DiscountEnd)) }
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::Subscription::UpdateParams::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class InvoiceSettings < Stripe::RequestParams
class Issuer < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# The account tax IDs associated with the subscription. Will be set on invoices generated by the subscription.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :account_tax_ids
# The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
sig { returns(T.nilable(::Stripe::Subscription::UpdateParams::InvoiceSettings::Issuer)) }
attr_accessor :issuer
sig {
params(account_tax_ids: T.nilable(T.nilable(T.any(String, T::Array[String]))), issuer: T.nilable(::Stripe::Subscription::UpdateParams::InvoiceSettings::Issuer)).void
}
def initialize(account_tax_ids: nil, issuer: nil); end
end
class Item < Stripe::RequestParams
class BillingThresholds < Stripe::RequestParams
# Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))
sig { returns(Integer) }
attr_accessor :usage_gte
sig { params(usage_gte: Integer).void }
def initialize(usage_gte: nil); end
end
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::Subscription::UpdateParams::Item::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::Subscription::UpdateParams::Item::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::Subscription::UpdateParams::Item::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::Subscription::UpdateParams::Item::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class PriceData < Stripe::RequestParams
class Recurring < Stripe::RequestParams
# Specifies billing frequency. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: T.nilable(Integer)).void }
def initialize(interval: nil, interval_count: nil); end
end
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
sig { returns(String) }
attr_accessor :product
# The recurring components of a price such as `interval` and `interval_count`.
sig { returns(::Stripe::Subscription::UpdateParams::Item::PriceData::Recurring) }
attr_accessor :recurring
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, product: String, recurring: ::Stripe::Subscription::UpdateParams::Item::PriceData::Recurring, tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
recurring: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
# Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::UpdateParams::Item::BillingThresholds))))
}
attr_accessor :billing_thresholds
# Delete all usage for a given subscription item. You must pass this when deleting a usage records subscription item. `clear_usage` has no effect if the plan has a billing meter attached.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :clear_usage
# A flag that, if set to `true`, will delete the specified item.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :deleted
# The coupons to redeem into discounts for the subscription item.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Subscription::UpdateParams::Item::Discount]))))
}
attr_accessor :discounts
# Subscription item to update.
sig { returns(T.nilable(String)) }
attr_accessor :id
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Plan ID for this item, as a string.
sig { returns(T.nilable(String)) }
attr_accessor :plan
# The ID of the price object. One of `price` or `price_data` is required. When changing a subscription item's price, `quantity` is set to 1 unless a `quantity` parameter is provided.
sig { returns(T.nilable(String)) }
attr_accessor :price
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
sig { returns(T.nilable(::Stripe::Subscription::UpdateParams::Item::PriceData)) }
attr_accessor :price_data
# Quantity for this item.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
sig {
params(billing_thresholds: T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::UpdateParams::Item::BillingThresholds))), clear_usage: T.nilable(T::Boolean), deleted: T.nilable(T::Boolean), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Subscription::UpdateParams::Item::Discount]))), id: T.nilable(String), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), plan: T.nilable(String), price: T.nilable(String), price_data: T.nilable(::Stripe::Subscription::UpdateParams::Item::PriceData), quantity: T.nilable(Integer), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String])))).void
}
def initialize(
billing_thresholds: nil,
clear_usage: nil,
deleted: nil,
discounts: nil,
id: nil,
metadata: nil,
plan: nil,
price: nil,
price_data: nil,
quantity: nil,
tax_rates: nil
); end
end
class PauseCollection < Stripe::RequestParams
# The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`.
sig { returns(String) }
attr_accessor :behavior
# The time after which the subscription will resume collecting payments.
sig { returns(T.nilable(Integer)) }
attr_accessor :resumes_at
sig { params(behavior: String, resumes_at: T.nilable(Integer)).void }
def initialize(behavior: nil, resumes_at: nil); end
end
class PaymentSettings < Stripe::RequestParams
class PaymentMethodOptions < Stripe::RequestParams
class AcssDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Transaction type of the mandate.
sig { returns(T.nilable(String)) }
attr_accessor :transaction_type
sig { params(transaction_type: T.nilable(String)).void }
def initialize(transaction_type: nil); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::Subscription::UpdateParams::PaymentSettings::PaymentMethodOptions::AcssDebit::MandateOptions))
}
attr_accessor :mandate_options
# Verification method for the intent
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(mandate_options: T.nilable(::Stripe::Subscription::UpdateParams::PaymentSettings::PaymentMethodOptions::AcssDebit::MandateOptions), verification_method: T.nilable(String)).void
}
def initialize(mandate_options: nil, verification_method: nil); end
end
class Bancontact < Stripe::RequestParams
# Preferred language of the Bancontact authorization page that the customer is redirected to.
sig { returns(T.nilable(String)) }
attr_accessor :preferred_language
sig { params(preferred_language: T.nilable(String)).void }
def initialize(preferred_language: nil); end
end
class Card < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Amount to be charged for future payments.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.
sig { returns(T.nilable(String)) }
attr_accessor :amount_type
# A description of the mandate or subscription that is meant to be displayed to the customer.
sig { returns(T.nilable(String)) }
attr_accessor :description
sig {
params(amount: T.nilable(Integer), amount_type: T.nilable(String), description: T.nilable(String)).void
}
def initialize(amount: nil, amount_type: nil, description: nil); end
end
# Configuration options for setting up an eMandate for cards issued in India.
sig {
returns(T.nilable(::Stripe::Subscription::UpdateParams::PaymentSettings::PaymentMethodOptions::Card::MandateOptions))
}
attr_accessor :mandate_options
# Selected network to process this Subscription on. Depends on the available networks of the card attached to the Subscription. Can be only set confirm-time.
sig { returns(T.nilable(String)) }
attr_accessor :network
# We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
sig { returns(T.nilable(String)) }
attr_accessor :request_three_d_secure
sig {
params(mandate_options: T.nilable(::Stripe::Subscription::UpdateParams::PaymentSettings::PaymentMethodOptions::Card::MandateOptions), network: T.nilable(String), request_three_d_secure: T.nilable(String)).void
}
def initialize(mandate_options: nil, network: nil, request_three_d_secure: nil); end
end
class CustomerBalance < Stripe::RequestParams
class BankTransfer < Stripe::RequestParams
class EuBankTransfer < Stripe::RequestParams
# The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
sig { returns(String) }
attr_accessor :country
sig { params(country: String).void }
def initialize(country: nil); end
end
# Configuration for eu_bank_transfer funding type.
sig {
returns(T.nilable(::Stripe::Subscription::UpdateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance::BankTransfer::EuBankTransfer))
}
attr_accessor :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`, `mx_bank_transfer`, or `us_bank_transfer`.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(eu_bank_transfer: T.nilable(::Stripe::Subscription::UpdateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance::BankTransfer::EuBankTransfer), type: T.nilable(String)).void
}
def initialize(eu_bank_transfer: nil, type: nil); end
end
# Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
sig {
returns(T.nilable(::Stripe::Subscription::UpdateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance::BankTransfer))
}
attr_accessor :bank_transfer
# The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
sig { returns(T.nilable(String)) }
attr_accessor :funding_type
sig {
params(bank_transfer: T.nilable(::Stripe::Subscription::UpdateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance::BankTransfer), funding_type: T.nilable(String)).void
}
def initialize(bank_transfer: nil, funding_type: nil); end
end
class IdBankTransfer < Stripe::RequestParams; end
class Konbini < Stripe::RequestParams; end
class SepaDebit < Stripe::RequestParams; end
class UsBankAccount < Stripe::RequestParams
class FinancialConnections < Stripe::RequestParams
class Filters < Stripe::RequestParams
# The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :account_subcategories
# ID of the institution to use to filter for selectable accounts.
sig { returns(T.nilable(String)) }
attr_accessor :institution
sig {
params(account_subcategories: T.nilable(T::Array[String]), institution: T.nilable(String)).void
}
def initialize(account_subcategories: nil, institution: nil); end
end
# Provide filters for the linked accounts that the customer can select for the payment method.
sig {
returns(T.nilable(::Stripe::Subscription::UpdateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount::FinancialConnections::Filters))
}
attr_accessor :filters
# The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :permissions
# List of data features that you would like to retrieve upon account creation.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :prefetch
sig {
params(filters: T.nilable(::Stripe::Subscription::UpdateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount::FinancialConnections::Filters), permissions: T.nilable(T::Array[String]), prefetch: T.nilable(T::Array[String])).void
}
def initialize(filters: nil, permissions: nil, prefetch: nil); end
end
# Additional fields for Financial Connections Session creation
sig {
returns(T.nilable(::Stripe::Subscription::UpdateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount::FinancialConnections))
}
attr_accessor :financial_connections
# Verification method for the intent
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(financial_connections: T.nilable(::Stripe::Subscription::UpdateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount::FinancialConnections), verification_method: T.nilable(String)).void
}
def initialize(financial_connections: nil, verification_method: nil); end
end
# This sub-hash contains details about the Canadian pre-authorized debit payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::UpdateParams::PaymentSettings::PaymentMethodOptions::AcssDebit))))
}
attr_accessor :acss_debit
# This sub-hash contains details about the Bancontact payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::UpdateParams::PaymentSettings::PaymentMethodOptions::Bancontact))))
}
attr_accessor :bancontact
# This sub-hash contains details about the Card payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::UpdateParams::PaymentSettings::PaymentMethodOptions::Card))))
}
attr_accessor :card
# This sub-hash contains details about the Bank transfer payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::UpdateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance))))
}
attr_accessor :customer_balance
# This sub-hash contains details about the Indonesia bank transfer payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::UpdateParams::PaymentSettings::PaymentMethodOptions::IdBankTransfer))))
}
attr_accessor :id_bank_transfer
# This sub-hash contains details about the Konbini payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::UpdateParams::PaymentSettings::PaymentMethodOptions::Konbini))))
}
attr_accessor :konbini
# This sub-hash contains details about the SEPA Direct Debit payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::UpdateParams::PaymentSettings::PaymentMethodOptions::SepaDebit))))
}
attr_accessor :sepa_debit
# This sub-hash contains details about the ACH direct debit payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::UpdateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount))))
}
attr_accessor :us_bank_account
sig {
params(acss_debit: T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::UpdateParams::PaymentSettings::PaymentMethodOptions::AcssDebit))), bancontact: T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::UpdateParams::PaymentSettings::PaymentMethodOptions::Bancontact))), card: T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::UpdateParams::PaymentSettings::PaymentMethodOptions::Card))), customer_balance: T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::UpdateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance))), id_bank_transfer: T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::UpdateParams::PaymentSettings::PaymentMethodOptions::IdBankTransfer))), konbini: T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::UpdateParams::PaymentSettings::PaymentMethodOptions::Konbini))), sepa_debit: T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::UpdateParams::PaymentSettings::PaymentMethodOptions::SepaDebit))), us_bank_account: T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::UpdateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount)))).void
}
def initialize(
acss_debit: nil,
bancontact: nil,
card: nil,
customer_balance: nil,
id_bank_transfer: nil,
konbini: nil,
sepa_debit: nil,
us_bank_account: nil
); end
end
# Payment-method-specific configuration to provide to invoices created by the subscription.
sig {
returns(T.nilable(::Stripe::Subscription::UpdateParams::PaymentSettings::PaymentMethodOptions))
}
attr_accessor :payment_method_options
# The list of payment method types (e.g. card) to provide to the invoice’s PaymentIntent. If not set, Stripe attempts to automatically determine the types to use by looking at the invoice’s default payment method, the subscription’s default payment method, the customer’s default payment method, and your [invoice template settings](https://dashboard.stripe.com/settings/billing/invoice). Should not be specified with payment_method_configuration
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :payment_method_types
# Configure whether Stripe updates `subscription.default_payment_method` when payment succeeds. Defaults to `off` if unspecified.
sig { returns(T.nilable(String)) }
attr_accessor :save_default_payment_method
sig {
params(payment_method_options: T.nilable(::Stripe::Subscription::UpdateParams::PaymentSettings::PaymentMethodOptions), payment_method_types: T.nilable(T.nilable(T.any(String, T::Array[String]))), save_default_payment_method: T.nilable(String)).void
}
def initialize(
payment_method_options: nil,
payment_method_types: nil,
save_default_payment_method: nil
); end
end
class PendingInvoiceItemInterval < Stripe::RequestParams
# Specifies invoicing frequency. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals between invoices. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks).
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: T.nilable(Integer)).void }
def initialize(interval: nil, interval_count: nil); end
end
class Prebilling < Stripe::RequestParams
# This is used to determine the number of billing cycles to prebill.
sig { returns(Integer) }
attr_accessor :iterations
# Whether to cancel or preserve `prebilling` if the subscription is updated during the prebilled period. The default value is `reset`.
sig { returns(T.nilable(String)) }
attr_accessor :update_behavior
sig { params(iterations: Integer, update_behavior: T.nilable(String)).void }
def initialize(iterations: nil, update_behavior: nil); end
end
class TransferData < Stripe::RequestParams
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
sig { returns(T.nilable(Float)) }
attr_accessor :amount_percent
# ID of an existing, connected Stripe account.
sig { returns(String) }
attr_accessor :destination
sig { params(amount_percent: T.nilable(Float), destination: String).void }
def initialize(amount_percent: nil, destination: nil); end
end
class TrialSettings < Stripe::RequestParams
class EndBehavior < Stripe::RequestParams
# Indicates how the subscription should change when the trial ends if the user did not provide a payment method.
sig { returns(String) }
attr_accessor :missing_payment_method
sig { params(missing_payment_method: String).void }
def initialize(missing_payment_method: nil); end
end
# Defines how the subscription should behave when the user's free trial ends.
sig { returns(::Stripe::Subscription::UpdateParams::TrialSettings::EndBehavior) }
attr_accessor :end_behavior
sig {
params(end_behavior: ::Stripe::Subscription::UpdateParams::TrialSettings::EndBehavior).void
}
def initialize(end_behavior: nil); end
end
# A list of prices and quantities that will generate invoice items appended to the next invoice for this subscription. You may pass up to 20 items.
sig { returns(T.nilable(T::Array[::Stripe::Subscription::UpdateParams::AddInvoiceItem])) }
attr_accessor :add_invoice_items
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).
sig { returns(T.nilable(T.nilable(T.any(String, Float)))) }
attr_accessor :application_fee_percent
# Automatic tax settings for this subscription. We recommend you only include this parameter when the existing value is being changed.
sig { returns(T.nilable(::Stripe::Subscription::UpdateParams::AutomaticTax)) }
attr_accessor :automatic_tax
# Either `now` or `unchanged`. Setting the value to `now` resets the subscription's billing cycle anchor to the current time (in UTC). For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).
sig { returns(T.nilable(String)) }
attr_accessor :billing_cycle_anchor
# Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. When updating, pass an empty string to remove previously-defined thresholds.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::UpdateParams::BillingThresholds))))
}
attr_accessor :billing_thresholds
# A timestamp at which the subscription should cancel. If set to a date before the current period ends, this will cause a proration if prorations have been enabled using `proration_behavior`. If set during a future period, this will always cause a proration for that period.
sig { returns(T.nilable(T.nilable(T.any(String, T.any(Integer, String))))) }
attr_accessor :cancel_at
# Indicate whether this subscription should cancel at the end of the current period (`current_period_end`). Defaults to `false`. This param will be removed in a future API version. Please use `cancel_at` instead.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :cancel_at_period_end
# Details about why this subscription was cancelled
sig { returns(T.nilable(::Stripe::Subscription::UpdateParams::CancellationDetails)) }
attr_accessor :cancellation_details
# Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically`.
sig { returns(T.nilable(String)) }
attr_accessor :collection_method
# Number of days a customer has to pay invoices generated by this subscription. Valid only for subscriptions where `collection_method` is set to `send_invoice`.
sig { returns(T.nilable(Integer)) }
attr_accessor :days_until_due
# ID of the default payment method for the subscription. It must belong to the customer associated with the subscription. This takes precedence over `default_source`. If neither are set, invoices will use the customer's [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) or [default_source](https://stripe.com/docs/api/customers/object#customer_object-default_source).
sig { returns(T.nilable(String)) }
attr_accessor :default_payment_method
# ID of the default payment source for the subscription. It must belong to the customer associated with the subscription and be in a chargeable state. If `default_payment_method` is also set, `default_payment_method` will take precedence. If neither are set, invoices will use the customer's [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) or [default_source](https://stripe.com/docs/api/customers/object#customer_object-default_source).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :default_source
# The tax rates that will apply to any subscription item that does not have `tax_rates` set. Invoices created will have their `default_tax_rates` populated from the subscription. Pass an empty string to remove previously-defined tax rates.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :default_tax_rates
# The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :description
# The coupons to redeem into discounts for the subscription. If not specified or empty, inherits the discount from the subscription's customer.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Subscription::UpdateParams::Discount]))))
}
attr_accessor :discounts
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# All invoices will be billed using the specified settings.
sig { returns(T.nilable(::Stripe::Subscription::UpdateParams::InvoiceSettings)) }
attr_accessor :invoice_settings
# A list of up to 20 subscription items, each with an attached price.
sig { returns(T.nilable(T::Array[::Stripe::Subscription::UpdateParams::Item])) }
attr_accessor :items
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Indicates if a customer is on or off-session while an invoice payment is attempted. Defaults to `false` (on-session).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :off_session
# The account on behalf of which to charge, for each of the subscription's invoices.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :on_behalf_of
# If specified, payment collection for this subscription will be paused. Note that the subscription status will be unchanged and will not be updated to `paused`. Learn more about [pausing collection](https://stripe.com/docs/billing/subscriptions/pause-payment).
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::UpdateParams::PauseCollection))))
}
attr_accessor :pause_collection
# Use `allow_incomplete` to transition the subscription to `status=past_due` if a payment is required but cannot be paid. This allows you to manage scenarios where additional user actions are needed to pay a subscription's invoice. For example, SCA regulation may require 3DS authentication to complete payment. See the [SCA Migration Guide](https://stripe.com/docs/billing/migration/strong-customer-authentication) for Billing to learn more. This is the default behavior.
#
# Use `default_incomplete` to transition the subscription to `status=past_due` when payment is required and await explicit confirmation of the invoice's payment intent. This allows simpler management of scenarios where additional user actions are needed to pay a subscription’s invoice. Such as failed payments, [SCA regulation](https://stripe.com/docs/billing/migration/strong-customer-authentication), or collecting a mandate for a bank debit payment method.
#
# Use `pending_if_incomplete` to update the subscription using [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates). When you use `pending_if_incomplete` you can only pass the parameters [supported by pending updates](https://stripe.com/docs/billing/pending-updates-reference#supported-attributes).
#
# Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not update the subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more.
sig { returns(T.nilable(String)) }
attr_accessor :payment_behavior
# Payment settings to pass to invoices created by the subscription.
sig { returns(T.nilable(::Stripe::Subscription::UpdateParams::PaymentSettings)) }
attr_accessor :payment_settings
# Specifies an interval for how often to bill for any pending invoice items. It is analogous to calling [Create an invoice](https://stripe.com/docs/api#create_invoice) for the given subscription at the specified interval.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::UpdateParams::PendingInvoiceItemInterval))))
}
attr_accessor :pending_invoice_item_interval
# If specified, the invoicing for the given billing cycle iterations will be processed now.
sig { returns(T.nilable(::Stripe::Subscription::UpdateParams::Prebilling)) }
attr_accessor :prebilling
# Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/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`.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
# If set, prorations will be calculated as though the subscription was updated at the given time. This can be used to apply exactly the same prorations that were previewed with the [create preview](https://stripe.com/docs/api/invoices/create_preview) endpoint. `proration_date` can also be used to implement custom proration logic, such as prorating by day instead of by second, by providing the time that you wish to use for proration calculations.
sig { returns(T.nilable(Integer)) }
attr_accessor :proration_date
# If specified, the funds from the subscription's invoices will be transferred to the destination and the ID of the resulting transfers will be found on the resulting charges. This will be unset if you POST an empty value.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::UpdateParams::TransferData))))
}
attr_accessor :transfer_data
# Unix timestamp representing the end of the trial period the customer will get before being charged for the first time. This will always overwrite any trials that might apply via a subscribed plan. If set, `trial_end` will override the default trial period of the plan the customer is being subscribed to. The `billing_cycle_anchor` will be updated to the `trial_end` value. The special value `now` can be provided to end the customer's trial immediately. Can be at most two years from `billing_cycle_anchor`.
sig { returns(T.nilable(T.any(String, Integer))) }
attr_accessor :trial_end
# Indicates if a plan's `trial_period_days` should be applied to the subscription. Setting `trial_end` per subscription is preferred, and this defaults to `false`. Setting this flag to `true` together with `trial_end` is not allowed. See [Using trial periods on subscriptions](https://stripe.com/docs/billing/subscriptions/trials) to learn more.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :trial_from_plan
# Settings related to subscription trials.
sig { returns(T.nilable(::Stripe::Subscription::UpdateParams::TrialSettings)) }
attr_accessor :trial_settings
sig {
params(add_invoice_items: T.nilable(T::Array[::Stripe::Subscription::UpdateParams::AddInvoiceItem]), application_fee_percent: T.nilable(T.nilable(T.any(String, Float))), automatic_tax: T.nilable(::Stripe::Subscription::UpdateParams::AutomaticTax), billing_cycle_anchor: T.nilable(String), billing_thresholds: T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::UpdateParams::BillingThresholds))), cancel_at: T.nilable(T.nilable(T.any(String, T.any(Integer, String)))), cancel_at_period_end: T.nilable(T::Boolean), cancellation_details: T.nilable(::Stripe::Subscription::UpdateParams::CancellationDetails), collection_method: T.nilable(String), days_until_due: T.nilable(Integer), default_payment_method: T.nilable(String), default_source: T.nilable(T.nilable(String)), default_tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String]))), description: T.nilable(T.nilable(String)), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Subscription::UpdateParams::Discount]))), expand: T.nilable(T::Array[String]), invoice_settings: T.nilable(::Stripe::Subscription::UpdateParams::InvoiceSettings), items: T.nilable(T::Array[::Stripe::Subscription::UpdateParams::Item]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), off_session: T.nilable(T::Boolean), on_behalf_of: T.nilable(T.nilable(String)), pause_collection: T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::UpdateParams::PauseCollection))), payment_behavior: T.nilable(String), payment_settings: T.nilable(::Stripe::Subscription::UpdateParams::PaymentSettings), pending_invoice_item_interval: T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::UpdateParams::PendingInvoiceItemInterval))), prebilling: T.nilable(::Stripe::Subscription::UpdateParams::Prebilling), proration_behavior: T.nilable(String), proration_date: T.nilable(Integer), transfer_data: T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::UpdateParams::TransferData))), trial_end: T.nilable(T.any(String, Integer)), trial_from_plan: T.nilable(T::Boolean), trial_settings: T.nilable(::Stripe::Subscription::UpdateParams::TrialSettings)).void
}
def initialize(
add_invoice_items: nil,
application_fee_percent: nil,
automatic_tax: nil,
billing_cycle_anchor: nil,
billing_thresholds: nil,
cancel_at: nil,
cancel_at_period_end: nil,
cancellation_details: nil,
collection_method: nil,
days_until_due: nil,
default_payment_method: nil,
default_source: nil,
default_tax_rates: nil,
description: nil,
discounts: nil,
expand: nil,
invoice_settings: nil,
items: nil,
metadata: nil,
off_session: nil,
on_behalf_of: nil,
pause_collection: nil,
payment_behavior: nil,
payment_settings: nil,
pending_invoice_item_interval: nil,
prebilling: nil,
proration_behavior: nil,
proration_date: nil,
transfer_data: nil,
trial_end: nil,
trial_from_plan: nil,
trial_settings: nil
); end
end
class DeleteDiscountParams < Stripe::RequestParams; end
class ListParams < Stripe::RequestParams
class AutomaticTax < Stripe::RequestParams
# Enabled automatic tax calculation which will automatically compute tax rates on all invoices generated by the subscription.
sig { returns(T::Boolean) }
attr_accessor :enabled
sig { params(enabled: T::Boolean).void }
def initialize(enabled: nil); end
end
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
class CurrentPeriodEnd < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
class CurrentPeriodStart < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Filter subscriptions by their automatic tax settings.
sig { returns(T.nilable(::Stripe::Subscription::ListParams::AutomaticTax)) }
attr_accessor :automatic_tax
# The collection method of the subscriptions to retrieve. Either `charge_automatically` or `send_invoice`.
sig { returns(T.nilable(String)) }
attr_accessor :collection_method
# Only return subscriptions that were created during the given date interval.
sig { returns(T.nilable(T.any(::Stripe::Subscription::ListParams::Created, Integer))) }
attr_accessor :created
# Only return subscriptions whose current_period_end falls within the given date interval.
sig {
returns(T.nilable(T.any(::Stripe::Subscription::ListParams::CurrentPeriodEnd, Integer)))
}
attr_accessor :current_period_end
# Only return subscriptions whose current_period_start falls within the given date interval.
sig {
returns(T.nilable(T.any(::Stripe::Subscription::ListParams::CurrentPeriodStart, Integer)))
}
attr_accessor :current_period_start
# The ID of the customer whose subscriptions will be retrieved.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# The ID of the account whose subscriptions will be retrieved.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# The ID of the plan whose subscriptions will be retrieved.
sig { returns(T.nilable(String)) }
attr_accessor :plan
# Filter for subscriptions that contain this recurring price ID.
sig { returns(T.nilable(String)) }
attr_accessor :price
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# The status of the subscriptions to retrieve. Passing in a value of `canceled` will return all canceled subscriptions, including those belonging to deleted customers. Pass `ended` to find subscriptions that are canceled and subscriptions that are expired due to [incomplete payment](https://stripe.com/docs/billing/subscriptions/overview#subscription-statuses). Passing in a value of `all` will return subscriptions of all statuses. If no value is supplied, all subscriptions that have not been canceled are returned.
sig { returns(T.nilable(String)) }
attr_accessor :status
# Filter for subscriptions that are associated with the specified test clock. The response will not include subscriptions with test clocks if this and the customer parameter is not set.
sig { returns(T.nilable(String)) }
attr_accessor :test_clock
sig {
params(automatic_tax: T.nilable(::Stripe::Subscription::ListParams::AutomaticTax), collection_method: T.nilable(String), created: T.nilable(T.any(::Stripe::Subscription::ListParams::Created, Integer)), current_period_end: T.nilable(T.any(::Stripe::Subscription::ListParams::CurrentPeriodEnd, Integer)), current_period_start: T.nilable(T.any(::Stripe::Subscription::ListParams::CurrentPeriodStart, Integer)), customer: T.nilable(String), customer_account: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), plan: T.nilable(String), price: T.nilable(String), starting_after: T.nilable(String), status: T.nilable(String), test_clock: T.nilable(String)).void
}
def initialize(
automatic_tax: nil,
collection_method: nil,
created: nil,
current_period_end: nil,
current_period_start: nil,
customer: nil,
customer_account: nil,
ending_before: nil,
expand: nil,
limit: nil,
plan: nil,
price: nil,
starting_after: nil,
status: nil,
test_clock: nil
); end
end
class CreateParams < Stripe::RequestParams
class AddInvoiceItem < Stripe::RequestParams
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::Subscription::CreateParams::AddInvoiceItem::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::Subscription::CreateParams::AddInvoiceItem::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::Subscription::CreateParams::AddInvoiceItem::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::Subscription::CreateParams::AddInvoiceItem::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class PriceData < Stripe::RequestParams
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
sig { returns(String) }
attr_accessor :product
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge or a negative integer representing the amount to credit to the customer.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, product: String, tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
# The coupons to redeem into discounts for the item.
sig {
returns(T.nilable(T::Array[::Stripe::Subscription::CreateParams::AddInvoiceItem::Discount]))
}
attr_accessor :discounts
# The ID of the price object. One of `price` or `price_data` is required.
sig { returns(T.nilable(String)) }
attr_accessor :price
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
sig { returns(T.nilable(::Stripe::Subscription::CreateParams::AddInvoiceItem::PriceData)) }
attr_accessor :price_data
# Quantity for this item. Defaults to 1.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# The tax rates which apply to the item. When set, the `default_tax_rates` do not apply to this item.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
sig {
params(discounts: T.nilable(T::Array[::Stripe::Subscription::CreateParams::AddInvoiceItem::Discount]), price: T.nilable(String), price_data: T.nilable(::Stripe::Subscription::CreateParams::AddInvoiceItem::PriceData), quantity: T.nilable(Integer), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String])))).void
}
def initialize(
discounts: nil,
price: nil,
price_data: nil,
quantity: nil,
tax_rates: nil
); end
end
class AutomaticTax < Stripe::RequestParams
class Liability < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# Enabled automatic tax calculation which will automatically compute tax rates on all invoices generated by the subscription.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
sig { returns(T.nilable(::Stripe::Subscription::CreateParams::AutomaticTax::Liability)) }
attr_accessor :liability
sig {
params(enabled: T::Boolean, liability: T.nilable(::Stripe::Subscription::CreateParams::AutomaticTax::Liability)).void
}
def initialize(enabled: nil, liability: nil); end
end
class BillingCycleAnchorConfig < Stripe::RequestParams
# The day of the month the billing_cycle_anchor should be. Ranges from 1 to 31.
sig { returns(Integer) }
attr_accessor :day_of_month
# The hour of the day the billing_cycle_anchor should be. Ranges from 0 to 23.
sig { returns(T.nilable(Integer)) }
attr_accessor :hour
# The minute of the hour the billing_cycle_anchor should be. Ranges from 0 to 59.
sig { returns(T.nilable(Integer)) }
attr_accessor :minute
# The month to start full cycle billing periods. Ranges from 1 to 12.
sig { returns(T.nilable(Integer)) }
attr_accessor :month
# The second of the minute the billing_cycle_anchor should be. Ranges from 0 to 59.
sig { returns(T.nilable(Integer)) }
attr_accessor :second
sig {
params(day_of_month: Integer, hour: T.nilable(Integer), minute: T.nilable(Integer), month: T.nilable(Integer), second: T.nilable(Integer)).void
}
def initialize(day_of_month: nil, hour: nil, minute: nil, month: nil, second: nil); end
end
class BillingThresholds < Stripe::RequestParams
# Monetary threshold that triggers the subscription to advance to a new billing period
sig { returns(T.nilable(Integer)) }
attr_accessor :amount_gte
# Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :reset_billing_cycle_anchor
sig {
params(amount_gte: T.nilable(Integer), reset_billing_cycle_anchor: T.nilable(T::Boolean)).void
}
def initialize(amount_gte: nil, reset_billing_cycle_anchor: nil); end
end
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::Subscription::CreateParams::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::Subscription::CreateParams::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig { returns(T.nilable(::Stripe::Subscription::CreateParams::Discount::DiscountEnd)) }
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::Subscription::CreateParams::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class InvoiceSettings < Stripe::RequestParams
class Issuer < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# The account tax IDs associated with the subscription. Will be set on invoices generated by the subscription.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :account_tax_ids
# The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
sig { returns(T.nilable(::Stripe::Subscription::CreateParams::InvoiceSettings::Issuer)) }
attr_accessor :issuer
sig {
params(account_tax_ids: T.nilable(T.nilable(T.any(String, T::Array[String]))), issuer: T.nilable(::Stripe::Subscription::CreateParams::InvoiceSettings::Issuer)).void
}
def initialize(account_tax_ids: nil, issuer: nil); end
end
class Item < Stripe::RequestParams
class BillingThresholds < Stripe::RequestParams
# Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))
sig { returns(Integer) }
attr_accessor :usage_gte
sig { params(usage_gte: Integer).void }
def initialize(usage_gte: nil); end
end
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::Subscription::CreateParams::Item::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::Subscription::CreateParams::Item::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::Subscription::CreateParams::Item::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::Subscription::CreateParams::Item::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class PriceData < Stripe::RequestParams
class Recurring < Stripe::RequestParams
# Specifies billing frequency. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: T.nilable(Integer)).void }
def initialize(interval: nil, interval_count: nil); end
end
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
sig { returns(String) }
attr_accessor :product
# The recurring components of a price such as `interval` and `interval_count`.
sig { returns(::Stripe::Subscription::CreateParams::Item::PriceData::Recurring) }
attr_accessor :recurring
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, product: String, recurring: ::Stripe::Subscription::CreateParams::Item::PriceData::Recurring, tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
recurring: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
class Trial < Stripe::RequestParams
# List of price IDs which, if present on the subscription following a paid trial, constitute opting-in to the paid trial. Currently only supports at most 1 price ID.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :converts_to
# Determines the type of trial for this item.
sig { returns(String) }
attr_accessor :type
sig { params(converts_to: T.nilable(T::Array[String]), type: String).void }
def initialize(converts_to: nil, type: nil); end
end
# Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::CreateParams::Item::BillingThresholds))))
}
attr_accessor :billing_thresholds
# The coupons to redeem into discounts for the subscription item.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Subscription::CreateParams::Item::Discount]))))
}
attr_accessor :discounts
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Plan ID for this item, as a string.
sig { returns(T.nilable(String)) }
attr_accessor :plan
# The ID of the price object.
sig { returns(T.nilable(String)) }
attr_accessor :price
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
sig { returns(T.nilable(::Stripe::Subscription::CreateParams::Item::PriceData)) }
attr_accessor :price_data
# Quantity for this item.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
# Define options to configure the trial on the subscription item.
sig { returns(T.nilable(::Stripe::Subscription::CreateParams::Item::Trial)) }
attr_accessor :trial
sig {
params(billing_thresholds: T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::CreateParams::Item::BillingThresholds))), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Subscription::CreateParams::Item::Discount]))), metadata: T.nilable(T::Hash[String, String]), plan: T.nilable(String), price: T.nilable(String), price_data: T.nilable(::Stripe::Subscription::CreateParams::Item::PriceData), quantity: T.nilable(Integer), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String]))), trial: T.nilable(::Stripe::Subscription::CreateParams::Item::Trial)).void
}
def initialize(
billing_thresholds: nil,
discounts: nil,
metadata: nil,
plan: nil,
price: nil,
price_data: nil,
quantity: nil,
tax_rates: nil,
trial: nil
); end
end
class PaymentSettings < Stripe::RequestParams
class PaymentMethodOptions < Stripe::RequestParams
class AcssDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Transaction type of the mandate.
sig { returns(T.nilable(String)) }
attr_accessor :transaction_type
sig { params(transaction_type: T.nilable(String)).void }
def initialize(transaction_type: nil); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::Subscription::CreateParams::PaymentSettings::PaymentMethodOptions::AcssDebit::MandateOptions))
}
attr_accessor :mandate_options
# Verification method for the intent
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(mandate_options: T.nilable(::Stripe::Subscription::CreateParams::PaymentSettings::PaymentMethodOptions::AcssDebit::MandateOptions), verification_method: T.nilable(String)).void
}
def initialize(mandate_options: nil, verification_method: nil); end
end
class Bancontact < Stripe::RequestParams
# Preferred language of the Bancontact authorization page that the customer is redirected to.
sig { returns(T.nilable(String)) }
attr_accessor :preferred_language
sig { params(preferred_language: T.nilable(String)).void }
def initialize(preferred_language: nil); end
end
class Card < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Amount to be charged for future payments.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.
sig { returns(T.nilable(String)) }
attr_accessor :amount_type
# A description of the mandate or subscription that is meant to be displayed to the customer.
sig { returns(T.nilable(String)) }
attr_accessor :description
sig {
params(amount: T.nilable(Integer), amount_type: T.nilable(String), description: T.nilable(String)).void
}
def initialize(amount: nil, amount_type: nil, description: nil); end
end
# Configuration options for setting up an eMandate for cards issued in India.
sig {
returns(T.nilable(::Stripe::Subscription::CreateParams::PaymentSettings::PaymentMethodOptions::Card::MandateOptions))
}
attr_accessor :mandate_options
# Selected network to process this Subscription on. Depends on the available networks of the card attached to the Subscription. Can be only set confirm-time.
sig { returns(T.nilable(String)) }
attr_accessor :network
# We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
sig { returns(T.nilable(String)) }
attr_accessor :request_three_d_secure
sig {
params(mandate_options: T.nilable(::Stripe::Subscription::CreateParams::PaymentSettings::PaymentMethodOptions::Card::MandateOptions), network: T.nilable(String), request_three_d_secure: T.nilable(String)).void
}
def initialize(mandate_options: nil, network: nil, request_three_d_secure: nil); end
end
class CustomerBalance < Stripe::RequestParams
class BankTransfer < Stripe::RequestParams
class EuBankTransfer < Stripe::RequestParams
# The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
sig { returns(String) }
attr_accessor :country
sig { params(country: String).void }
def initialize(country: nil); end
end
# Configuration for eu_bank_transfer funding type.
sig {
returns(T.nilable(::Stripe::Subscription::CreateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance::BankTransfer::EuBankTransfer))
}
attr_accessor :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`, `mx_bank_transfer`, or `us_bank_transfer`.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(eu_bank_transfer: T.nilable(::Stripe::Subscription::CreateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance::BankTransfer::EuBankTransfer), type: T.nilable(String)).void
}
def initialize(eu_bank_transfer: nil, type: nil); end
end
# Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
sig {
returns(T.nilable(::Stripe::Subscription::CreateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance::BankTransfer))
}
attr_accessor :bank_transfer
# The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
sig { returns(T.nilable(String)) }
attr_accessor :funding_type
sig {
params(bank_transfer: T.nilable(::Stripe::Subscription::CreateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance::BankTransfer), funding_type: T.nilable(String)).void
}
def initialize(bank_transfer: nil, funding_type: nil); end
end
class IdBankTransfer < Stripe::RequestParams; end
class Konbini < Stripe::RequestParams; end
class SepaDebit < Stripe::RequestParams; end
class UsBankAccount < Stripe::RequestParams
class FinancialConnections < Stripe::RequestParams
class Filters < Stripe::RequestParams
# The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :account_subcategories
# ID of the institution to use to filter for selectable accounts.
sig { returns(T.nilable(String)) }
attr_accessor :institution
sig {
params(account_subcategories: T.nilable(T::Array[String]), institution: T.nilable(String)).void
}
def initialize(account_subcategories: nil, institution: nil); end
end
# Provide filters for the linked accounts that the customer can select for the payment method.
sig {
returns(T.nilable(::Stripe::Subscription::CreateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount::FinancialConnections::Filters))
}
attr_accessor :filters
# The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :permissions
# List of data features that you would like to retrieve upon account creation.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :prefetch
sig {
params(filters: T.nilable(::Stripe::Subscription::CreateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount::FinancialConnections::Filters), permissions: T.nilable(T::Array[String]), prefetch: T.nilable(T::Array[String])).void
}
def initialize(filters: nil, permissions: nil, prefetch: nil); end
end
# Additional fields for Financial Connections Session creation
sig {
returns(T.nilable(::Stripe::Subscription::CreateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount::FinancialConnections))
}
attr_accessor :financial_connections
# Verification method for the intent
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(financial_connections: T.nilable(::Stripe::Subscription::CreateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount::FinancialConnections), verification_method: T.nilable(String)).void
}
def initialize(financial_connections: nil, verification_method: nil); end
end
# This sub-hash contains details about the Canadian pre-authorized debit payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::CreateParams::PaymentSettings::PaymentMethodOptions::AcssDebit))))
}
attr_accessor :acss_debit
# This sub-hash contains details about the Bancontact payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::CreateParams::PaymentSettings::PaymentMethodOptions::Bancontact))))
}
attr_accessor :bancontact
# This sub-hash contains details about the Card payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::CreateParams::PaymentSettings::PaymentMethodOptions::Card))))
}
attr_accessor :card
# This sub-hash contains details about the Bank transfer payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::CreateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance))))
}
attr_accessor :customer_balance
# This sub-hash contains details about the Indonesia bank transfer payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::CreateParams::PaymentSettings::PaymentMethodOptions::IdBankTransfer))))
}
attr_accessor :id_bank_transfer
# This sub-hash contains details about the Konbini payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::CreateParams::PaymentSettings::PaymentMethodOptions::Konbini))))
}
attr_accessor :konbini
# This sub-hash contains details about the SEPA Direct Debit payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::CreateParams::PaymentSettings::PaymentMethodOptions::SepaDebit))))
}
attr_accessor :sepa_debit
# This sub-hash contains details about the ACH direct debit payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::CreateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount))))
}
attr_accessor :us_bank_account
sig {
params(acss_debit: T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::CreateParams::PaymentSettings::PaymentMethodOptions::AcssDebit))), bancontact: T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::CreateParams::PaymentSettings::PaymentMethodOptions::Bancontact))), card: T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::CreateParams::PaymentSettings::PaymentMethodOptions::Card))), customer_balance: T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::CreateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance))), id_bank_transfer: T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::CreateParams::PaymentSettings::PaymentMethodOptions::IdBankTransfer))), konbini: T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::CreateParams::PaymentSettings::PaymentMethodOptions::Konbini))), sepa_debit: T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::CreateParams::PaymentSettings::PaymentMethodOptions::SepaDebit))), us_bank_account: T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::CreateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount)))).void
}
def initialize(
acss_debit: nil,
bancontact: nil,
card: nil,
customer_balance: nil,
id_bank_transfer: nil,
konbini: nil,
sepa_debit: nil,
us_bank_account: nil
); end
end
# Payment-method-specific configuration to provide to invoices created by the subscription.
sig {
returns(T.nilable(::Stripe::Subscription::CreateParams::PaymentSettings::PaymentMethodOptions))
}
attr_accessor :payment_method_options
# The list of payment method types (e.g. card) to provide to the invoice’s PaymentIntent. If not set, Stripe attempts to automatically determine the types to use by looking at the invoice’s default payment method, the subscription’s default payment method, the customer’s default payment method, and your [invoice template settings](https://dashboard.stripe.com/settings/billing/invoice). Should not be specified with payment_method_configuration
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :payment_method_types
# Configure whether Stripe updates `subscription.default_payment_method` when payment succeeds. Defaults to `off` if unspecified.
sig { returns(T.nilable(String)) }
attr_accessor :save_default_payment_method
sig {
params(payment_method_options: T.nilable(::Stripe::Subscription::CreateParams::PaymentSettings::PaymentMethodOptions), payment_method_types: T.nilable(T.nilable(T.any(String, T::Array[String]))), save_default_payment_method: T.nilable(String)).void
}
def initialize(
payment_method_options: nil,
payment_method_types: nil,
save_default_payment_method: nil
); end
end
class PendingInvoiceItemInterval < Stripe::RequestParams
# Specifies invoicing frequency. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals between invoices. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks).
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: T.nilable(Integer)).void }
def initialize(interval: nil, interval_count: nil); end
end
class Prebilling < Stripe::RequestParams
# This is used to determine the number of billing cycles to prebill.
sig { returns(Integer) }
attr_accessor :iterations
# Whether to cancel or preserve `prebilling` if the subscription is updated during the prebilled period. The default value is `reset`.
sig { returns(T.nilable(String)) }
attr_accessor :update_behavior
sig { params(iterations: Integer, update_behavior: T.nilable(String)).void }
def initialize(iterations: nil, update_behavior: nil); end
end
class TransferData < Stripe::RequestParams
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
sig { returns(T.nilable(Float)) }
attr_accessor :amount_percent
# ID of an existing, connected Stripe account.
sig { returns(String) }
attr_accessor :destination
sig { params(amount_percent: T.nilable(Float), destination: String).void }
def initialize(amount_percent: nil, destination: nil); end
end
class TrialSettings < Stripe::RequestParams
class EndBehavior < Stripe::RequestParams
# Indicates how the subscription should change when the trial ends if the user did not provide a payment method.
sig { returns(String) }
attr_accessor :missing_payment_method
sig { params(missing_payment_method: String).void }
def initialize(missing_payment_method: nil); end
end
# Defines how the subscription should behave when the user's free trial ends.
sig { returns(::Stripe::Subscription::CreateParams::TrialSettings::EndBehavior) }
attr_accessor :end_behavior
sig {
params(end_behavior: ::Stripe::Subscription::CreateParams::TrialSettings::EndBehavior).void
}
def initialize(end_behavior: nil); end
end
# A list of prices and quantities that will generate invoice items appended to the next invoice for this subscription. You may pass up to 20 items.
sig { returns(T.nilable(T::Array[::Stripe::Subscription::CreateParams::AddInvoiceItem])) }
attr_accessor :add_invoice_items
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).
sig { returns(T.nilable(T.nilable(T.any(String, Float)))) }
attr_accessor :application_fee_percent
# Automatic tax settings for this subscription. We recommend you only include this parameter when the existing value is being changed.
sig { returns(T.nilable(::Stripe::Subscription::CreateParams::AutomaticTax)) }
attr_accessor :automatic_tax
# For new subscriptions, a past timestamp to backdate the subscription's start date to. If set, the first invoice will contain a proration for the timespan between the start date and the current time. Can be combined with trials and the billing cycle anchor.
sig { returns(T.nilable(Integer)) }
attr_accessor :backdate_start_date
# A future timestamp in UTC format to anchor the subscription's [billing cycle](https://stripe.com/docs/subscriptions/billing-cycle). The anchor is the reference point that aligns future billing cycle dates. It sets the day of week for `week` intervals, the day of month for `month` and `year` intervals, and the month of year for `year` intervals.
sig { returns(T.nilable(Integer)) }
attr_accessor :billing_cycle_anchor
# Mutually exclusive with billing_cycle_anchor and only valid with monthly and yearly price intervals. When provided, the billing_cycle_anchor is set to the next occurence of the day_of_month at the hour, minute, and second UTC.
sig { returns(T.nilable(::Stripe::Subscription::CreateParams::BillingCycleAnchorConfig)) }
attr_accessor :billing_cycle_anchor_config
# Controls how prorations and invoices for subscriptions are calculated and orchestrated.
sig { returns(T.nilable(String)) }
attr_accessor :billing_mode
# Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. When updating, pass an empty string to remove previously-defined thresholds.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::CreateParams::BillingThresholds))))
}
attr_accessor :billing_thresholds
# A timestamp at which the subscription should cancel. If set to a date before the current period ends, this will cause a proration if prorations have been enabled using `proration_behavior`. If set during a future period, this will always cause a proration for that period.
sig { returns(T.nilable(T.any(Integer, String))) }
attr_accessor :cancel_at
# Indicate whether this subscription should cancel at the end of the current period (`current_period_end`). Defaults to `false`. This param will be removed in a future API version. Please use `cancel_at` instead.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :cancel_at_period_end
# Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically`.
sig { returns(T.nilable(String)) }
attr_accessor :collection_method
# 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).
sig { returns(T.nilable(String)) }
attr_accessor :currency
# The identifier of the customer to subscribe.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# The identifier of the account to subscribe.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# Number of days a customer has to pay invoices generated by this subscription. Valid only for subscriptions where `collection_method` is set to `send_invoice`.
sig { returns(T.nilable(Integer)) }
attr_accessor :days_until_due
# ID of the default payment method for the subscription. It must belong to the customer associated with the subscription. This takes precedence over `default_source`. If neither are set, invoices will use the customer's [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) or [default_source](https://stripe.com/docs/api/customers/object#customer_object-default_source).
sig { returns(T.nilable(String)) }
attr_accessor :default_payment_method
# ID of the default payment source for the subscription. It must belong to the customer associated with the subscription and be in a chargeable state. If `default_payment_method` is also set, `default_payment_method` will take precedence. If neither are set, invoices will use the customer's [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) or [default_source](https://stripe.com/docs/api/customers/object#customer_object-default_source).
sig { returns(T.nilable(String)) }
attr_accessor :default_source
# The tax rates that will apply to any subscription item that does not have `tax_rates` set. Invoices created will have their `default_tax_rates` populated from the subscription.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :default_tax_rates
# The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
sig { returns(T.nilable(String)) }
attr_accessor :description
# The coupons to redeem into discounts for the subscription. If not specified or empty, inherits the discount from the subscription's customer.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Subscription::CreateParams::Discount]))))
}
attr_accessor :discounts
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# All invoices will be billed using the specified settings.
sig { returns(T.nilable(::Stripe::Subscription::CreateParams::InvoiceSettings)) }
attr_accessor :invoice_settings
# A list of up to 20 subscription items, each with an attached price.
sig { returns(T.nilable(T::Array[::Stripe::Subscription::CreateParams::Item])) }
attr_accessor :items
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Indicates if a customer is on or off-session while an invoice payment is attempted. Defaults to `false` (on-session).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :off_session
# The account on behalf of which to charge, for each of the subscription's invoices.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :on_behalf_of
# Only applies to subscriptions with `collection_method=charge_automatically`.
#
# Use `allow_incomplete` to create Subscriptions with `status=incomplete` if the first invoice can't be paid. Creating Subscriptions with this status allows you to manage scenarios where additional customer actions are needed to pay a subscription's invoice. For example, SCA regulation may require 3DS authentication to complete payment. See the [SCA Migration Guide](https://stripe.com/docs/billing/migration/strong-customer-authentication) for Billing to learn more. This is the default behavior.
#
# Use `default_incomplete` to create Subscriptions with `status=incomplete` when the first invoice requires payment, otherwise start as active. Subscriptions transition to `status=active` when successfully confirming the PaymentIntent on the first invoice. This allows simpler management of scenarios where additional customer actions are needed to pay a subscription’s invoice, such as failed payments, [SCA regulation](https://stripe.com/docs/billing/migration/strong-customer-authentication), or collecting a mandate for a bank debit payment method. If the PaymentIntent is not confirmed within 23 hours Subscriptions transition to `status=incomplete_expired`, which is a terminal state.
#
# Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's first invoice can't be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further customer action is needed, this parameter doesn't create a Subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more.
#
# `pending_if_incomplete` is only used with updates and cannot be passed when creating a Subscription.
#
# Subscriptions with `collection_method=send_invoice` are automatically activated regardless of the first Invoice status.
sig { returns(T.nilable(String)) }
attr_accessor :payment_behavior
# Payment settings to pass to invoices created by the subscription.
sig { returns(T.nilable(::Stripe::Subscription::CreateParams::PaymentSettings)) }
attr_accessor :payment_settings
# Specifies an interval for how often to bill for any pending invoice items. It is analogous to calling [Create an invoice](https://stripe.com/docs/api#create_invoice) for the given subscription at the specified interval.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::CreateParams::PendingInvoiceItemInterval))))
}
attr_accessor :pending_invoice_item_interval
# If specified, the invoicing for the given billing cycle iterations will be processed now.
sig { returns(T.nilable(::Stripe::Subscription::CreateParams::Prebilling)) }
attr_accessor :prebilling
# Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/prorations) resulting from the `billing_cycle_anchor`. If no value is passed, the default is `create_prorations`.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
# If specified, the funds from the subscription's invoices will be transferred to the destination and the ID of the resulting transfers will be found on the resulting charges.
sig { returns(T.nilable(::Stripe::Subscription::CreateParams::TransferData)) }
attr_accessor :transfer_data
# Unix timestamp representing the end of the trial period the customer will get before being charged for the first time. If set, trial_end will override the default trial period of the plan the customer is being subscribed to. The special value `now` can be provided to end the customer's trial immediately. Can be at most two years from `billing_cycle_anchor`. See [Using trial periods on subscriptions](https://stripe.com/docs/billing/subscriptions/trials) to learn more.
sig { returns(T.nilable(T.any(String, Integer))) }
attr_accessor :trial_end
# Indicates if a plan's `trial_period_days` should be applied to the subscription. Setting `trial_end` per subscription is preferred, and this defaults to `false`. Setting this flag to `true` together with `trial_end` is not allowed. See [Using trial periods on subscriptions](https://stripe.com/docs/billing/subscriptions/trials) to learn more.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :trial_from_plan
# Integer representing the number of trial period days before the customer is charged for the first time. This will always overwrite any trials that might apply via a subscribed plan. See [Using trial periods on subscriptions](https://stripe.com/docs/billing/subscriptions/trials) to learn more.
sig { returns(T.nilable(Integer)) }
attr_accessor :trial_period_days
# Settings related to subscription trials.
sig { returns(T.nilable(::Stripe::Subscription::CreateParams::TrialSettings)) }
attr_accessor :trial_settings
sig {
params(add_invoice_items: T.nilable(T::Array[::Stripe::Subscription::CreateParams::AddInvoiceItem]), application_fee_percent: T.nilable(T.nilable(T.any(String, Float))), automatic_tax: T.nilable(::Stripe::Subscription::CreateParams::AutomaticTax), backdate_start_date: T.nilable(Integer), billing_cycle_anchor: T.nilable(Integer), billing_cycle_anchor_config: T.nilable(::Stripe::Subscription::CreateParams::BillingCycleAnchorConfig), billing_mode: T.nilable(String), billing_thresholds: T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::CreateParams::BillingThresholds))), cancel_at: T.nilable(T.any(Integer, String)), cancel_at_period_end: T.nilable(T::Boolean), collection_method: T.nilable(String), currency: T.nilable(String), customer: T.nilable(String), customer_account: T.nilable(String), days_until_due: T.nilable(Integer), default_payment_method: T.nilable(String), default_source: T.nilable(String), default_tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String]))), description: T.nilable(String), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Subscription::CreateParams::Discount]))), expand: T.nilable(T::Array[String]), invoice_settings: T.nilable(::Stripe::Subscription::CreateParams::InvoiceSettings), items: T.nilable(T::Array[::Stripe::Subscription::CreateParams::Item]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), off_session: T.nilable(T::Boolean), on_behalf_of: T.nilable(T.nilable(String)), payment_behavior: T.nilable(String), payment_settings: T.nilable(::Stripe::Subscription::CreateParams::PaymentSettings), pending_invoice_item_interval: T.nilable(T.nilable(T.any(String, ::Stripe::Subscription::CreateParams::PendingInvoiceItemInterval))), prebilling: T.nilable(::Stripe::Subscription::CreateParams::Prebilling), proration_behavior: T.nilable(String), transfer_data: T.nilable(::Stripe::Subscription::CreateParams::TransferData), trial_end: T.nilable(T.any(String, Integer)), trial_from_plan: T.nilable(T::Boolean), trial_period_days: T.nilable(Integer), trial_settings: T.nilable(::Stripe::Subscription::CreateParams::TrialSettings)).void
}
def initialize(
add_invoice_items: nil,
application_fee_percent: nil,
automatic_tax: nil,
backdate_start_date: nil,
billing_cycle_anchor: nil,
billing_cycle_anchor_config: nil,
billing_mode: nil,
billing_thresholds: nil,
cancel_at: nil,
cancel_at_period_end: nil,
collection_method: nil,
currency: nil,
customer: nil,
customer_account: nil,
days_until_due: nil,
default_payment_method: nil,
default_source: nil,
default_tax_rates: nil,
description: nil,
discounts: nil,
expand: nil,
invoice_settings: nil,
items: nil,
metadata: nil,
off_session: nil,
on_behalf_of: nil,
payment_behavior: nil,
payment_settings: nil,
pending_invoice_item_interval: nil,
prebilling: nil,
proration_behavior: nil,
transfer_data: nil,
trial_end: nil,
trial_from_plan: nil,
trial_period_days: nil,
trial_settings: nil
); end
end
class SearchParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for pagination across multiple pages of results. Don't include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.
sig { returns(T.nilable(String)) }
attr_accessor :page
# The search query string. See [search query language](https://stripe.com/docs/search#search-query-language) and the list of supported [query fields for subscriptions](https://stripe.com/docs/search#query-fields-for-subscriptions).
sig { returns(String) }
attr_accessor :query
sig {
params(expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), page: T.nilable(String), query: String).void
}
def initialize(expand: nil, limit: nil, page: nil, query: nil); end
end
class MigrateParams < Stripe::RequestParams
# Controls how prorations and invoices for subscriptions are calculated and orchestrated.
sig { returns(String) }
attr_accessor :billing_mode
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(billing_mode: String, expand: T.nilable(T::Array[String])).void }
def initialize(billing_mode: nil, expand: nil); end
end
class ResumeParams < Stripe::RequestParams
# The billing cycle anchor that applies when the subscription is resumed. Either `now` or `unchanged`. The default is `now`. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).
sig { returns(T.nilable(String)) }
attr_accessor :billing_cycle_anchor
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/prorations) resulting from the `billing_cycle_anchor` being `unchanged`. When the `billing_cycle_anchor` is set to `now` (default value), no prorations are generated. If no value is passed, the default is `create_prorations`.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
# If set, prorations will be calculated as though the subscription was resumed at the given time. This can be used to apply exactly the same prorations that were previewed with the [create preview](https://stripe.com/docs/api/invoices/create_preview) endpoint.
sig { returns(T.nilable(Integer)) }
attr_accessor :proration_date
sig {
params(billing_cycle_anchor: T.nilable(String), expand: T.nilable(T::Array[String]), proration_behavior: T.nilable(String), proration_date: T.nilable(Integer)).void
}
def initialize(
billing_cycle_anchor: nil,
expand: nil,
proration_behavior: nil,
proration_date: nil
); end
end
# Cancels a customer's subscription immediately. The customer won't be charged again for the subscription. After it's canceled, you can no longer update the subscription or its [metadata](https://docs.stripe.com/metadata).
#
# Any pending invoice items that you've created are still charged at the end of the period, unless manually [deleted](https://docs.stripe.com/api#delete_invoiceitem). If you've set the subscription to cancel at the end of the period, any pending prorations are also left in place and collected at the end of the period. But if the subscription is set to cancel immediately, pending prorations are removed if invoice_now and prorate are both set to true.
#
# By default, upon subscription cancellation, Stripe stops automatic collection of all finalized invoices for the customer. This is intended to prevent unexpected payment attempts after the customer has canceled a subscription. However, you can resume automatic collection of the invoices manually after subscription cancellation to have us proceed. Or, you could check for unpaid invoices before allowing the customer to cancel the subscription at all.
sig {
params(params: T.any(::Stripe::Subscription::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Subscription)
}
def cancel(params = {}, opts = {}); end
# Cancels a customer's subscription immediately. The customer won't be charged again for the subscription. After it's canceled, you can no longer update the subscription or its [metadata](https://docs.stripe.com/metadata).
#
# Any pending invoice items that you've created are still charged at the end of the period, unless manually [deleted](https://docs.stripe.com/api#delete_invoiceitem). If you've set the subscription to cancel at the end of the period, any pending prorations are also left in place and collected at the end of the period. But if the subscription is set to cancel immediately, pending prorations are removed if invoice_now and prorate are both set to true.
#
# By default, upon subscription cancellation, Stripe stops automatic collection of all finalized invoices for the customer. This is intended to prevent unexpected payment attempts after the customer has canceled a subscription. However, you can resume automatic collection of the invoices manually after subscription cancellation to have us proceed. Or, you could check for unpaid invoices before allowing the customer to cancel the subscription at all.
sig {
params(subscription_exposed_id: String, params: T.any(::Stripe::Subscription::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Subscription)
}
def self.cancel(subscription_exposed_id, params = {}, opts = {}); end
# Creates a new subscription on an existing customer. Each customer can have up to 500 active or scheduled subscriptions.
#
# When you create a subscription with collection_method=charge_automatically, the first invoice is finalized as part of the request.
# The payment_behavior parameter determines the exact behavior of the initial payment.
#
# To start subscriptions where the first invoice always begins in a draft status, use [subscription schedules](https://docs.stripe.com/docs/billing/subscriptions/subscription-schedules#managing) instead.
# Schedules provide the flexibility to model more complex billing configurations that change over time.
sig {
params(params: T.any(::Stripe::Subscription::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Subscription)
}
def self.create(params = {}, opts = {}); end
# Removes the currently applied discount on a subscription.
sig {
params(params: T.any(::Stripe::Subscription::DeleteDiscountParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Discount)
}
def delete_discount(params = {}, opts = {}); end
# Removes the currently applied discount on a subscription.
sig {
params(subscription_exposed_id: String, params: T.any(::Stripe::Subscription::DeleteDiscountParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Discount)
}
def self.delete_discount(subscription_exposed_id, params = {}, opts = {}); end
# By default, returns a list of subscriptions that have not been canceled. In order to list canceled subscriptions, specify status=canceled.
sig {
params(params: T.any(::Stripe::Subscription::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Upgrade the billing_mode of an existing subscription.
sig {
params(params: T.any(::Stripe::Subscription::MigrateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Subscription)
}
def migrate(params = {}, opts = {}); end
# Upgrade the billing_mode of an existing subscription.
sig {
params(subscription: String, params: T.any(::Stripe::Subscription::MigrateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Subscription)
}
def self.migrate(subscription, params = {}, opts = {}); end
# Initiates resumption of a paused subscription, optionally resetting the billing cycle anchor and creating prorations. If a resumption invoice is generated, it must be paid or marked uncollectible before the subscription will be unpaused. If payment succeeds the subscription will become active, and if payment fails the subscription will be past_due. The resumption invoice will void automatically if not paid by the expiration date.
sig {
params(params: T.any(::Stripe::Subscription::ResumeParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Subscription)
}
def resume(params = {}, opts = {}); end
# Initiates resumption of a paused subscription, optionally resetting the billing cycle anchor and creating prorations. If a resumption invoice is generated, it must be paid or marked uncollectible before the subscription will be unpaused. If payment succeeds the subscription will become active, and if payment fails the subscription will be past_due. The resumption invoice will void automatically if not paid by the expiration date.
sig {
params(subscription: String, params: T.any(::Stripe::Subscription::ResumeParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Subscription)
}
def self.resume(subscription, params = {}, opts = {}); end
sig {
params(params: T.any(::Stripe::Subscription::SearchParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SearchResultObject)
}
def self.search(params = {}, opts = {}); end
sig {
params(params: T.any(::Stripe::Subscription::SearchParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped, blk: T.untyped).returns(Stripe::SearchResultObject)
}
def self.search_auto_paging_each(params = {}, opts = {}, &blk); end
# Updates an existing subscription to match the specified parameters.
# When changing prices or quantities, we optionally prorate the price we charge next month to make up for any price changes.
# To preview how the proration is calculated, use the [create preview](https://docs.stripe.com/docs/api/invoices/create_preview) endpoint.
#
# By default, we prorate subscription changes. For example, if a customer signs up on May 1 for a 100 price, they'll be billed 100 immediately. If on May 15 they switch to a 200 price, then on June 1 they'll be billed 250 (200 for a renewal of her subscription, plus a 50 prorating adjustment for half of the previous month's 100 difference). Similarly, a downgrade generates a credit that is applied to the next invoice. We also prorate when you make quantity changes.
#
# Switching prices does not normally change the billing date or generate an immediate charge unless:
#
#
# The billing interval is changed (for example, from monthly to yearly).
# The subscription moves from free to paid.
# A trial starts or ends.
#
#
# In these cases, we apply a credit for the unused time on the previous price, immediately charge the customer using the new price, and reset the billing date. Learn about how [Stripe immediately attempts payment for subscription changes](https://docs.stripe.com/docs/billing/subscriptions/upgrade-downgrade#immediate-payment).
#
# If you want to charge for an upgrade immediately, pass proration_behavior as always_invoice to create prorations, automatically invoice the customer for those proration adjustments, and attempt to collect payment. If you pass create_prorations, the prorations are created but not automatically invoiced. If you want to bill the customer for the prorations before the subscription's renewal date, you need to manually [invoice the customer](https://docs.stripe.com/docs/api/invoices/create).
#
# If you don't want to prorate, set the proration_behavior option to none. With this option, the customer is billed 100 on May 1 and 200 on June 1. Similarly, if you set proration_behavior to none when switching between different billing intervals (for example, from monthly to yearly), we don't generate any credits for the old subscription's unused time. We still reset the billing date and bill immediately for the new subscription.
#
# Updating the quantity on a subscription many times in an hour may result in [rate limiting. If you need to bill for a frequently changing quantity, consider integrating usage-based billing](https://docs.stripe.com/docs/rate-limits) instead.
sig {
params(subscription_exposed_id: String, params: T.any(::Stripe::Subscription::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Subscription)
}
def self.update(subscription_exposed_id, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
# Subscription items allow you to create customer subscriptions with more than
# one plan, making it easy to represent complex billing relationships.
class SubscriptionItem < APIResource
class BillingThresholds < Stripe::StripeObject
# Usage threshold that triggers the subscription to create an invoice
sig { returns(T.nilable(Integer)) }
attr_reader :usage_gte
end
class Trial < Stripe::StripeObject
# List of price IDs which, if present on the subscription following a paid trial, constitute opting-in to the paid trial.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :converts_to
# Determines the type of trial for this item.
sig { returns(String) }
attr_reader :type
end
# Define thresholds at which an invoice will be sent, and the related subscription advanced to a new billing period
sig { returns(T.nilable(BillingThresholds)) }
attr_reader :billing_thresholds
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# The end time of this subscription item's current billing period.
sig { returns(Integer) }
attr_reader :current_period_end
# The start time of this subscription item's current billing period.
sig { returns(Integer) }
attr_reader :current_period_start
# The discounts applied to the subscription item. Subscription item discounts are applied before subscription discounts. Use `expand[]=discounts` to expand each discount.
sig { returns(T::Array[T.any(String, Stripe::Discount)]) }
attr_reader :discounts
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# 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.
sig { returns(T::Hash[String, String]) }
attr_reader :metadata
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# You can now model subscriptions more flexibly using the [Prices API](https://stripe.com/docs/api#prices). It replaces the Plans API and is backwards compatible to simplify your migration.
#
# Plans define the base price, currency, and billing cycle for recurring purchases of products.
# [Products](https://stripe.com/docs/api#products) help you track inventory or provisioning, and plans help you track pricing. Different physical goods or levels of service should be represented by products, and pricing options should be represented by plans. This approach lets you change prices without having to change your provisioning scheme.
#
# For example, you might have a single "gold" product that has plans for $10/month, $100/year, €9/month, and €90/year.
#
# Related guides: [Set up a subscription](https://stripe.com/docs/billing/subscriptions/set-up-subscription) and more about [products and prices](https://stripe.com/docs/products-prices/overview).
sig { returns(Stripe::Plan) }
attr_reader :plan
# Prices define the unit cost, currency, and (optional) billing cycle for both recurring and one-time purchases of products.
# [Products](https://stripe.com/docs/api#products) help you track inventory or provisioning, and prices help you track payment terms. Different physical goods or levels of service should be represented by products, and pricing options should be represented by prices. This approach lets you change prices without having to change your provisioning scheme.
#
# For example, you might have a single "gold" product that has prices for $10/month, $100/year, and €9 once.
#
# Related guides: [Set up a subscription](https://stripe.com/docs/billing/subscriptions/set-up-subscription), [create an invoice](https://stripe.com/docs/billing/invoices/create), and more about [products and prices](https://stripe.com/docs/products-prices/overview).
sig { returns(Stripe::Price) }
attr_reader :price
# The [quantity](https://stripe.com/docs/subscriptions/quantities) of the plan to which the customer should be subscribed.
sig { returns(Integer) }
attr_reader :quantity
# The `subscription` this `subscription_item` belongs to.
sig { returns(String) }
attr_reader :subscription
# The tax rates which apply to this `subscription_item`. When set, the `default_tax_rates` on the subscription do not apply to this `subscription_item`.
sig { returns(T.nilable(T::Array[Stripe::TaxRate])) }
attr_reader :tax_rates
# Options that configure the trial on the subscription item.
sig { returns(T.nilable(Trial)) }
attr_reader :trial
# Always true for a deleted object
sig { returns(T::Boolean) }
attr_reader :deleted
class DeleteParams < Stripe::RequestParams
# Delete all usage for the given subscription item. Allowed only when the current plan's `usage_type` is `metered`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :clear_usage
# Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/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`.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
# If set, the proration will be calculated as though the subscription was updated at the given time. This can be used to apply the same proration that was previewed with the [upcoming invoice](https://stripe.com/docs/api#retrieve_customer_invoice) endpoint.
sig { returns(T.nilable(Integer)) }
attr_accessor :proration_date
sig {
params(clear_usage: T.nilable(T::Boolean), proration_behavior: T.nilable(String), proration_date: T.nilable(Integer)).void
}
def initialize(clear_usage: nil, proration_behavior: nil, proration_date: nil); end
end
class UpdateParams < Stripe::RequestParams
class BillingThresholds < Stripe::RequestParams
# Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))
sig { returns(Integer) }
attr_accessor :usage_gte
sig { params(usage_gte: Integer).void }
def initialize(usage_gte: nil); end
end
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::SubscriptionItem::UpdateParams::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::SubscriptionItem::UpdateParams::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig { returns(T.nilable(::Stripe::SubscriptionItem::UpdateParams::Discount::DiscountEnd)) }
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::SubscriptionItem::UpdateParams::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class PriceData < Stripe::RequestParams
class Recurring < Stripe::RequestParams
# Specifies billing frequency. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: T.nilable(Integer)).void }
def initialize(interval: nil, interval_count: nil); end
end
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
sig { returns(String) }
attr_accessor :product
# The recurring components of a price such as `interval` and `interval_count`.
sig { returns(::Stripe::SubscriptionItem::UpdateParams::PriceData::Recurring) }
attr_accessor :recurring
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, product: String, recurring: ::Stripe::SubscriptionItem::UpdateParams::PriceData::Recurring, tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
recurring: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
# Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionItem::UpdateParams::BillingThresholds))))
}
attr_accessor :billing_thresholds
# The coupons to redeem into discounts for the subscription item.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::SubscriptionItem::UpdateParams::Discount]))))
}
attr_accessor :discounts
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Indicates if a customer is on or off-session while an invoice payment is attempted. Defaults to `false` (on-session).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :off_session
# Use `allow_incomplete` to transition the subscription to `status=past_due` if a payment is required but cannot be paid. This allows you to manage scenarios where additional user actions are needed to pay a subscription's invoice. For example, SCA regulation may require 3DS authentication to complete payment. See the [SCA Migration Guide](https://stripe.com/docs/billing/migration/strong-customer-authentication) for Billing to learn more. This is the default behavior.
#
# Use `default_incomplete` to transition the subscription to `status=past_due` when payment is required and await explicit confirmation of the invoice's payment intent. This allows simpler management of scenarios where additional user actions are needed to pay a subscription’s invoice. Such as failed payments, [SCA regulation](https://stripe.com/docs/billing/migration/strong-customer-authentication), or collecting a mandate for a bank debit payment method.
#
# Use `pending_if_incomplete` to update the subscription using [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates). When you use `pending_if_incomplete` you can only pass the parameters [supported by pending updates](https://stripe.com/docs/billing/pending-updates-reference#supported-attributes).
#
# Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not update the subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more.
sig { returns(T.nilable(String)) }
attr_accessor :payment_behavior
# The identifier of the new plan for this subscription item.
sig { returns(T.nilable(String)) }
attr_accessor :plan
# The ID of the price object. One of `price` or `price_data` is required. When changing a subscription item's price, `quantity` is set to 1 unless a `quantity` parameter is provided.
sig { returns(T.nilable(String)) }
attr_accessor :price
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
sig { returns(T.nilable(::Stripe::SubscriptionItem::UpdateParams::PriceData)) }
attr_accessor :price_data
# Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/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`.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
# If set, the proration will be calculated as though the subscription was updated at the given time. This can be used to apply the same proration that was previewed with the [upcoming invoice](https://stripe.com/docs/api#retrieve_customer_invoice) endpoint.
sig { returns(T.nilable(Integer)) }
attr_accessor :proration_date
# The quantity you'd like to apply to the subscription item you're creating.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
sig {
params(billing_thresholds: T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionItem::UpdateParams::BillingThresholds))), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::SubscriptionItem::UpdateParams::Discount]))), expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), off_session: T.nilable(T::Boolean), payment_behavior: T.nilable(String), plan: T.nilable(String), price: T.nilable(String), price_data: T.nilable(::Stripe::SubscriptionItem::UpdateParams::PriceData), proration_behavior: T.nilable(String), proration_date: T.nilable(Integer), quantity: T.nilable(Integer), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String])))).void
}
def initialize(
billing_thresholds: nil,
discounts: nil,
expand: nil,
metadata: nil,
off_session: nil,
payment_behavior: nil,
plan: nil,
price: nil,
price_data: nil,
proration_behavior: nil,
proration_date: nil,
quantity: nil,
tax_rates: nil
); end
end
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# The ID of the subscription whose items will be retrieved.
sig { returns(String) }
attr_accessor :subscription
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String), subscription: String).void
}
def initialize(
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil,
subscription: nil
); end
end
class CreateParams < Stripe::RequestParams
class BillingThresholds < Stripe::RequestParams
# Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))
sig { returns(Integer) }
attr_accessor :usage_gte
sig { params(usage_gte: Integer).void }
def initialize(usage_gte: nil); end
end
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::SubscriptionItem::CreateParams::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::SubscriptionItem::CreateParams::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig { returns(T.nilable(::Stripe::SubscriptionItem::CreateParams::Discount::DiscountEnd)) }
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::SubscriptionItem::CreateParams::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class PriceData < Stripe::RequestParams
class Recurring < Stripe::RequestParams
# Specifies billing frequency. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: T.nilable(Integer)).void }
def initialize(interval: nil, interval_count: nil); end
end
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
sig { returns(String) }
attr_accessor :product
# The recurring components of a price such as `interval` and `interval_count`.
sig { returns(::Stripe::SubscriptionItem::CreateParams::PriceData::Recurring) }
attr_accessor :recurring
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, product: String, recurring: ::Stripe::SubscriptionItem::CreateParams::PriceData::Recurring, tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
recurring: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
class Trial < Stripe::RequestParams
# List of price IDs which, if present on the subscription following a paid trial, constitute opting-in to the paid trial. Currently only supports at most 1 price ID.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :converts_to
# Determines the type of trial for this item.
sig { returns(String) }
attr_accessor :type
sig { params(converts_to: T.nilable(T::Array[String]), type: String).void }
def initialize(converts_to: nil, type: nil); end
end
# Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionItem::CreateParams::BillingThresholds))))
}
attr_accessor :billing_thresholds
# The coupons to redeem into discounts for the subscription item.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::SubscriptionItem::CreateParams::Discount]))))
}
attr_accessor :discounts
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Use `allow_incomplete` to transition the subscription to `status=past_due` if a payment is required but cannot be paid. This allows you to manage scenarios where additional user actions are needed to pay a subscription's invoice. For example, SCA regulation may require 3DS authentication to complete payment. See the [SCA Migration Guide](https://stripe.com/docs/billing/migration/strong-customer-authentication) for Billing to learn more. This is the default behavior.
#
# Use `default_incomplete` to transition the subscription to `status=past_due` when payment is required and await explicit confirmation of the invoice's payment intent. This allows simpler management of scenarios where additional user actions are needed to pay a subscription’s invoice. Such as failed payments, [SCA regulation](https://stripe.com/docs/billing/migration/strong-customer-authentication), or collecting a mandate for a bank debit payment method.
#
# Use `pending_if_incomplete` to update the subscription using [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates). When you use `pending_if_incomplete` you can only pass the parameters [supported by pending updates](https://stripe.com/docs/billing/pending-updates-reference#supported-attributes).
#
# Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not update the subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more.
sig { returns(T.nilable(String)) }
attr_accessor :payment_behavior
# The identifier of the plan to add to the subscription.
sig { returns(T.nilable(String)) }
attr_accessor :plan
# The ID of the price object.
sig { returns(T.nilable(String)) }
attr_accessor :price
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
sig { returns(T.nilable(::Stripe::SubscriptionItem::CreateParams::PriceData)) }
attr_accessor :price_data
# Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/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`.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
# If set, the proration will be calculated as though the subscription was updated at the given time. This can be used to apply the same proration that was previewed with the [upcoming invoice](https://stripe.com/docs/api#retrieve_customer_invoice) endpoint.
sig { returns(T.nilable(Integer)) }
attr_accessor :proration_date
# The quantity you'd like to apply to the subscription item you're creating.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# The identifier of the subscription to modify.
sig { returns(String) }
attr_accessor :subscription
# A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
# Options that configure the trial on the subscription item.
sig { returns(T.nilable(::Stripe::SubscriptionItem::CreateParams::Trial)) }
attr_accessor :trial
sig {
params(billing_thresholds: T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionItem::CreateParams::BillingThresholds))), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::SubscriptionItem::CreateParams::Discount]))), expand: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), payment_behavior: T.nilable(String), plan: T.nilable(String), price: T.nilable(String), price_data: T.nilable(::Stripe::SubscriptionItem::CreateParams::PriceData), proration_behavior: T.nilable(String), proration_date: T.nilable(Integer), quantity: T.nilable(Integer), subscription: String, tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String]))), trial: T.nilable(::Stripe::SubscriptionItem::CreateParams::Trial)).void
}
def initialize(
billing_thresholds: nil,
discounts: nil,
expand: nil,
metadata: nil,
payment_behavior: nil,
plan: nil,
price: nil,
price_data: nil,
proration_behavior: nil,
proration_date: nil,
quantity: nil,
subscription: nil,
tax_rates: nil,
trial: nil
); end
end
# Adds a new item to an existing subscription. No existing items will be changed or replaced.
sig {
params(params: T.any(::Stripe::SubscriptionItem::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SubscriptionItem)
}
def self.create(params = {}, opts = {}); end
# Deletes an item from the subscription. Removing a subscription item from a subscription will not cancel the subscription.
sig {
params(item: String, params: T.any(::Stripe::SubscriptionItem::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SubscriptionItem)
}
def self.delete(item, params = {}, opts = {}); end
# Deletes an item from the subscription. Removing a subscription item from a subscription will not cancel the subscription.
sig {
params(params: T.any(::Stripe::SubscriptionItem::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SubscriptionItem)
}
def delete(params = {}, opts = {}); end
# Returns a list of your subscription items for a given subscription.
sig {
params(params: T.any(::Stripe::SubscriptionItem::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Updates the plan or quantity of an item on a current subscription.
sig {
params(item: String, params: T.any(::Stripe::SubscriptionItem::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SubscriptionItem)
}
def self.update(item, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
# A subscription schedule allows you to create and manage the lifecycle of a subscription by predefining expected changes.
#
# Related guide: [Subscription schedules](https://stripe.com/docs/billing/subscriptions/subscription-schedules)
class SubscriptionSchedule < APIResource
class CurrentPhase < Stripe::StripeObject
# The end of this phase of the subscription schedule.
sig { returns(Integer) }
attr_reader :end_date
# The start of this phase of the subscription schedule.
sig { returns(Integer) }
attr_reader :start_date
end
class DefaultSettings < Stripe::StripeObject
class AutomaticTax < Stripe::StripeObject
class Liability < Stripe::StripeObject
# The connected account being referenced when `type` is `account`.
sig { returns(T.any(String, Stripe::Account)) }
attr_reader :account
# Type of the account referenced.
sig { returns(String) }
attr_reader :type
end
# If Stripe disabled automatic tax, this enum describes why.
sig { returns(T.nilable(String)) }
attr_reader :disabled_reason
# Whether Stripe automatically computes tax on invoices created during this phase.
sig { returns(T::Boolean) }
attr_reader :enabled
# The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
sig { returns(T.nilable(Liability)) }
attr_reader :liability
end
class BillingThresholds < Stripe::StripeObject
# Monetary threshold that triggers the subscription to create an invoice
sig { returns(T.nilable(Integer)) }
attr_reader :amount_gte
# Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged. This value may not be `true` if the subscription contains items with plans that have `aggregate_usage=last_ever`.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :reset_billing_cycle_anchor
end
class InvoiceSettings < Stripe::StripeObject
class Issuer < Stripe::StripeObject
# The connected account being referenced when `type` is `account`.
sig { returns(T.any(String, Stripe::Account)) }
attr_reader :account
# Type of the account referenced.
sig { returns(String) }
attr_reader :type
end
# The account tax IDs associated with the subscription schedule. Will be set on invoices generated by the subscription schedule.
sig { returns(T.nilable(T::Array[T.any(String, Stripe::TaxId)])) }
attr_reader :account_tax_ids
# Number of days within which a customer must pay invoices generated by this subscription schedule. This value will be `null` for subscription schedules where `billing=charge_automatically`.
sig { returns(T.nilable(Integer)) }
attr_reader :days_until_due
# Attribute for field issuer
sig { returns(Issuer) }
attr_reader :issuer
end
class TransferData < Stripe::StripeObject
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
sig { returns(T.nilable(Float)) }
attr_reader :amount_percent
# The account where funds from the payment will be transferred to upon payment success.
sig { returns(T.any(String, Stripe::Account)) }
attr_reader :destination
end
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account during this phase of the schedule.
sig { returns(T.nilable(Float)) }
attr_reader :application_fee_percent
# Attribute for field automatic_tax
sig { returns(AutomaticTax) }
attr_reader :automatic_tax
# Possible values are `phase_start` or `automatic`. If `phase_start` then billing cycle anchor of the subscription is set to the start of the phase when entering the phase. If `automatic` then the billing cycle anchor is automatically modified as needed when entering the phase. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).
sig { returns(String) }
attr_reader :billing_cycle_anchor
# Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period
sig { returns(T.nilable(BillingThresholds)) }
attr_reader :billing_thresholds
# Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`.
sig { returns(T.nilable(String)) }
attr_reader :collection_method
# ID of the default payment method for the subscription schedule. If not set, invoices will use the default payment method in the customer's invoice settings.
sig { returns(T.nilable(T.any(String, Stripe::PaymentMethod))) }
attr_reader :default_payment_method
# Subscription description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
sig { returns(T.nilable(String)) }
attr_reader :description
# Attribute for field invoice_settings
sig { returns(InvoiceSettings) }
attr_reader :invoice_settings
# 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.
sig { returns(T.nilable(T.any(String, Stripe::Account))) }
attr_reader :on_behalf_of
# The account (if any) the associated subscription's payments will be attributed to for tax reporting, and where funds from each payment will be transferred to for each of the subscription's invoices.
sig { returns(T.nilable(TransferData)) }
attr_reader :transfer_data
end
class LastPriceMigrationError < Stripe::StripeObject
class FailedTransition < Stripe::StripeObject
# The original price to be migrated.
sig { returns(String) }
attr_reader :source_price
# The intended resulting price of the migration.
sig { returns(String) }
attr_reader :target_price
end
# The time at which the price migration encountered an error.
sig { returns(Integer) }
attr_reader :errored_at
# The involved price pairs in each failed transition.
sig { returns(T::Array[FailedTransition]) }
attr_reader :failed_transitions
# The type of error encountered by the price migration.
sig { returns(String) }
attr_reader :type
end
class Phase < Stripe::StripeObject
class AddInvoiceItem < Stripe::StripeObject
class Discount < Stripe::StripeObject
class DiscountEnd < Stripe::StripeObject
# The discount end timestamp.
sig { returns(T.nilable(Integer)) }
attr_reader :timestamp
# The discount end type.
sig { returns(String) }
attr_reader :type
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(T.any(String, Stripe::Coupon))) }
attr_reader :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(T.any(String, Stripe::Discount))) }
attr_reader :discount
# Details to determine how long the discount should be applied for.
sig { returns(T.nilable(DiscountEnd)) }
attr_reader :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(T.any(String, Stripe::PromotionCode))) }
attr_reader :promotion_code
end
# The stackable discounts that will be applied to the item.
sig { returns(T::Array[Discount]) }
attr_reader :discounts
# ID of the price used to generate the invoice item.
sig { returns(T.any(String, Stripe::Price)) }
attr_reader :price
# The quantity of the invoice item.
sig { returns(T.nilable(Integer)) }
attr_reader :quantity
# The tax rates which apply to the item. When set, the `default_tax_rates` do not apply to this item.
sig { returns(T.nilable(T::Array[Stripe::TaxRate])) }
attr_reader :tax_rates
end
class AutomaticTax < Stripe::StripeObject
class Liability < Stripe::StripeObject
# The connected account being referenced when `type` is `account`.
sig { returns(T.any(String, Stripe::Account)) }
attr_reader :account
# Type of the account referenced.
sig { returns(String) }
attr_reader :type
end
# If Stripe disabled automatic tax, this enum describes why.
sig { returns(T.nilable(String)) }
attr_reader :disabled_reason
# Whether Stripe automatically computes tax on invoices created during this phase.
sig { returns(T::Boolean) }
attr_reader :enabled
# The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
sig { returns(T.nilable(Liability)) }
attr_reader :liability
end
class BillingThresholds < Stripe::StripeObject
# Monetary threshold that triggers the subscription to create an invoice
sig { returns(T.nilable(Integer)) }
attr_reader :amount_gte
# Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged. This value may not be `true` if the subscription contains items with plans that have `aggregate_usage=last_ever`.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :reset_billing_cycle_anchor
end
class Discount < Stripe::StripeObject
class DiscountEnd < Stripe::StripeObject
# The discount end timestamp.
sig { returns(T.nilable(Integer)) }
attr_reader :timestamp
# The discount end type.
sig { returns(String) }
attr_reader :type
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(T.any(String, Stripe::Coupon))) }
attr_reader :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(T.any(String, Stripe::Discount))) }
attr_reader :discount
# Details to determine how long the discount should be applied for.
sig { returns(T.nilable(DiscountEnd)) }
attr_reader :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(T.any(String, Stripe::PromotionCode))) }
attr_reader :promotion_code
end
class InvoiceSettings < Stripe::StripeObject
class Issuer < Stripe::StripeObject
# The connected account being referenced when `type` is `account`.
sig { returns(T.any(String, Stripe::Account)) }
attr_reader :account
# Type of the account referenced.
sig { returns(String) }
attr_reader :type
end
# The account tax IDs associated with this phase of the subscription schedule. Will be set on invoices generated by this phase of the subscription schedule.
sig { returns(T.nilable(T::Array[T.any(String, Stripe::TaxId)])) }
attr_reader :account_tax_ids
# Number of days within which a customer must pay invoices generated by this subscription schedule. This value will be `null` for subscription schedules where `billing=charge_automatically`.
sig { returns(T.nilable(Integer)) }
attr_reader :days_until_due
# The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
sig { returns(T.nilable(Issuer)) }
attr_reader :issuer
end
class Item < Stripe::StripeObject
class BillingThresholds < Stripe::StripeObject
# Usage threshold that triggers the subscription to create an invoice
sig { returns(T.nilable(Integer)) }
attr_reader :usage_gte
end
class Discount < Stripe::StripeObject
class DiscountEnd < Stripe::StripeObject
# The discount end timestamp.
sig { returns(T.nilable(Integer)) }
attr_reader :timestamp
# The discount end type.
sig { returns(String) }
attr_reader :type
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(T.any(String, Stripe::Coupon))) }
attr_reader :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(T.any(String, Stripe::Discount))) }
attr_reader :discount
# Details to determine how long the discount should be applied for.
sig { returns(T.nilable(DiscountEnd)) }
attr_reader :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(T.any(String, Stripe::PromotionCode))) }
attr_reader :promotion_code
end
class Trial < Stripe::StripeObject
# List of price IDs which, if present on the subscription following a paid trial, constitute opting-in to the paid trial.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :converts_to
# Determines the type of trial for this item.
sig { returns(String) }
attr_reader :type
end
# Define thresholds at which an invoice will be sent, and the related subscription advanced to a new billing period
sig { returns(T.nilable(BillingThresholds)) }
attr_reader :billing_thresholds
# The discounts applied to the subscription item. Subscription item discounts are applied before subscription discounts. Use `expand[]=discounts` to expand each discount.
sig { returns(T::Array[Discount]) }
attr_reader :discounts
# Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an item. Metadata on this item will update the underlying subscription item's `metadata` when the phase is entered.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# ID of the plan to which the customer should be subscribed.
sig { returns(T.any(String, Stripe::Plan)) }
attr_reader :plan
# ID of the price to which the customer should be subscribed.
sig { returns(T.any(String, Stripe::Price)) }
attr_reader :price
# Quantity of the plan to which the customer should be subscribed.
sig { returns(Integer) }
attr_reader :quantity
# The tax rates which apply to this `phase_item`. When set, the `default_tax_rates` on the phase do not apply to this `phase_item`.
sig { returns(T.nilable(T::Array[Stripe::TaxRate])) }
attr_reader :tax_rates
# Options that configure the trial on the subscription item.
sig { returns(T.nilable(Trial)) }
attr_reader :trial
end
class PauseCollection < Stripe::StripeObject
# The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`.
sig { returns(String) }
attr_reader :behavior
end
class TransferData < Stripe::StripeObject
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
sig { returns(T.nilable(Float)) }
attr_reader :amount_percent
# The account where funds from the payment will be transferred to upon payment success.
sig { returns(T.any(String, Stripe::Account)) }
attr_reader :destination
end
class TrialSettings < Stripe::StripeObject
class EndBehavior < Stripe::StripeObject
# Configure how an opt-in following a paid trial is billed when using `billing_behavior: prorate_up_front`.
sig { returns(T.nilable(String)) }
attr_reader :prorate_up_front
end
# Defines how the subscription should behave when a trial ends.
sig { returns(T.nilable(EndBehavior)) }
attr_reader :end_behavior
end
# A list of prices and quantities that will generate invoice items appended to the next invoice for this phase.
sig { returns(T::Array[AddInvoiceItem]) }
attr_reader :add_invoice_items
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account during this phase of the schedule.
sig { returns(T.nilable(Float)) }
attr_reader :application_fee_percent
# Attribute for field automatic_tax
sig { returns(AutomaticTax) }
attr_reader :automatic_tax
# Possible values are `phase_start` or `automatic`. If `phase_start` then billing cycle anchor of the subscription is set to the start of the phase when entering the phase. If `automatic` then the billing cycle anchor is automatically modified as needed when entering the phase. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).
sig { returns(T.nilable(String)) }
attr_reader :billing_cycle_anchor
# Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period
sig { returns(T.nilable(BillingThresholds)) }
attr_reader :billing_thresholds
# Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`.
sig { returns(T.nilable(String)) }
attr_reader :collection_method
# 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).
sig { returns(String) }
attr_reader :currency
# ID of the default payment method for the subscription schedule. It must belong to the customer associated with the subscription schedule. If not set, invoices will use the default payment method in the customer's invoice settings.
sig { returns(T.nilable(T.any(String, Stripe::PaymentMethod))) }
attr_reader :default_payment_method
# The default tax rates to apply to the subscription during this phase of the subscription schedule.
sig { returns(T.nilable(T::Array[Stripe::TaxRate])) }
attr_reader :default_tax_rates
# Subscription description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
sig { returns(T.nilable(String)) }
attr_reader :description
# The stackable discounts that will be applied to the subscription on this phase. Subscription item discounts are applied before subscription discounts.
sig { returns(T::Array[Discount]) }
attr_reader :discounts
# The end of this phase of the subscription schedule.
sig { returns(Integer) }
attr_reader :end_date
# The invoice settings applicable during this phase.
sig { returns(T.nilable(InvoiceSettings)) }
attr_reader :invoice_settings
# Subscription items to configure the subscription to during this phase of the subscription schedule.
sig { returns(T::Array[Item]) }
attr_reader :items
# Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to a phase. Metadata on a schedule's phase will update the underlying subscription's `metadata` when the phase is entered. Updating the underlying subscription's `metadata` directly will not affect the current phase's `metadata`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :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.
sig { returns(T.nilable(T.any(String, Stripe::Account))) }
attr_reader :on_behalf_of
# If specified, payment collection for this subscription will be paused. Note that the subscription status will be unchanged and will not be updated to `paused`. Learn more about [pausing collection](https://stripe.com/docs/billing/subscriptions/pause-payment).
sig { returns(T.nilable(PauseCollection)) }
attr_reader :pause_collection
# When transitioning phases, controls how prorations are handled (if any). Possible values are `create_prorations`, `none`, and `always_invoice`.
sig { returns(String) }
attr_reader :proration_behavior
# The start of this phase of the subscription schedule.
sig { returns(Integer) }
attr_reader :start_date
# The account (if any) the associated subscription's payments will be attributed to for tax reporting, and where funds from each payment will be transferred to for each of the subscription's invoices.
sig { returns(T.nilable(TransferData)) }
attr_reader :transfer_data
# Specify behavior of the trial when crossing schedule phase boundaries
sig { returns(T.nilable(String)) }
attr_reader :trial_continuation
# When the trial ends within the phase.
sig { returns(T.nilable(Integer)) }
attr_reader :trial_end
# Settings related to any trials on the subscription during this phase.
sig { returns(T.nilable(TrialSettings)) }
attr_reader :trial_settings
end
class Prebilling < Stripe::StripeObject
# ID of the prebilling invoice.
sig { returns(T.any(String, Stripe::Invoice)) }
attr_reader :invoice
# The end of the last period for which the invoice pre-bills.
sig { returns(Integer) }
attr_reader :period_end
# The start of the first period for which the invoice pre-bills.
sig { returns(Integer) }
attr_reader :period_start
# Whether to cancel or preserve `prebilling` if the subscription is updated during the prebilled period.
sig { returns(String) }
attr_reader :update_behavior
end
# ID of the Connect Application that created the schedule.
sig { returns(T.nilable(T.any(String, Stripe::Application))) }
attr_reader :application
# Configures when the subscription schedule generates prorations for phase transitions. Possible values are `prorate_on_next_phase` or `prorate_up_front` with the default being `prorate_on_next_phase`. `prorate_on_next_phase` will apply phase changes and generate prorations at transition time. `prorate_up_front` will bill for all phases within the current billing cycle up front.
sig { returns(String) }
attr_reader :billing_behavior
# The [billing mode](/api/subscriptions/create#create_subscription-billing_mode) that will be used to process all future operations for the subscription schedule.
sig { returns(String) }
attr_reader :billing_mode
# Time at which the subscription schedule was canceled. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_reader :canceled_at
# Time at which the subscription schedule was completed. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_reader :completed_at
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# Object representing the start and end dates for the current phase of the subscription schedule, if it is `active`.
sig { returns(T.nilable(CurrentPhase)) }
attr_reader :current_phase
# ID of the customer who owns the subscription schedule.
sig { returns(T.any(String, Stripe::Customer)) }
attr_reader :customer
# ID of the account who owns the subscription schedule.
sig { returns(T.nilable(String)) }
attr_reader :customer_account
# Attribute for field default_settings
sig { returns(DefaultSettings) }
attr_reader :default_settings
# Behavior of the subscription schedule and underlying subscription when it ends. Possible values are `release` or `cancel` with the default being `release`. `release` will end the subscription schedule and keep the underlying subscription running. `cancel` will end the subscription schedule and cancel the underlying subscription.
sig { returns(String) }
attr_reader :end_behavior
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Details of the most recent price migration that failed for the subscription schedule.
sig { returns(T.nilable(LastPriceMigrationError)) }
attr_reader :last_price_migration_error
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# 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.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Configuration for the subscription schedule's phases.
sig { returns(T::Array[Phase]) }
attr_reader :phases
# Time period and invoice for a Subscription billed in advance.
sig { returns(T.nilable(Prebilling)) }
attr_reader :prebilling
# Time at which the subscription schedule was released. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_reader :released_at
# ID of the subscription once managed by the subscription schedule (if it is released).
sig { returns(T.nilable(String)) }
attr_reader :released_subscription
# The present status of the subscription schedule. Possible values are `not_started`, `active`, `completed`, `released`, and `canceled`. You can read more about the different states in our [behavior guide](https://stripe.com/docs/billing/subscriptions/subscription-schedules).
sig { returns(String) }
attr_reader :status
# ID of the subscription managed by the subscription schedule.
sig { returns(T.nilable(T.any(String, Stripe::Subscription))) }
attr_reader :subscription
# ID of the test clock this subscription schedule belongs to.
sig { returns(T.nilable(T.any(String, Stripe::TestHelpers::TestClock))) }
attr_reader :test_clock
class ListParams < Stripe::RequestParams
class CanceledAt < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
class CompletedAt < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
class ReleasedAt < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return subscription schedules that were created canceled the given date interval.
sig {
returns(T.nilable(T.any(::Stripe::SubscriptionSchedule::ListParams::CanceledAt, Integer)))
}
attr_accessor :canceled_at
# Only return subscription schedules that completed during the given date interval.
sig {
returns(T.nilable(T.any(::Stripe::SubscriptionSchedule::ListParams::CompletedAt, Integer)))
}
attr_accessor :completed_at
# Only return subscription schedules that were created during the given date interval.
sig {
returns(T.nilable(T.any(::Stripe::SubscriptionSchedule::ListParams::Created, Integer)))
}
attr_accessor :created
# Only return subscription schedules for the given customer.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# Only return subscription schedules for the given account.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Only return subscription schedules that were released during the given date interval.
sig {
returns(T.nilable(T.any(::Stripe::SubscriptionSchedule::ListParams::ReleasedAt, Integer)))
}
attr_accessor :released_at
# Only return subscription schedules that have not started yet.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :scheduled
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(canceled_at: T.nilable(T.any(::Stripe::SubscriptionSchedule::ListParams::CanceledAt, Integer)), completed_at: T.nilable(T.any(::Stripe::SubscriptionSchedule::ListParams::CompletedAt, Integer)), created: T.nilable(T.any(::Stripe::SubscriptionSchedule::ListParams::Created, Integer)), customer: T.nilable(String), customer_account: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), released_at: T.nilable(T.any(::Stripe::SubscriptionSchedule::ListParams::ReleasedAt, Integer)), scheduled: T.nilable(T::Boolean), starting_after: T.nilable(String)).void
}
def initialize(
canceled_at: nil,
completed_at: nil,
created: nil,
customer: nil,
customer_account: nil,
ending_before: nil,
expand: nil,
limit: nil,
released_at: nil,
scheduled: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class DefaultSettings < Stripe::RequestParams
class AutomaticTax < Stripe::RequestParams
class Liability < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# Enabled automatic tax calculation which will automatically compute tax rates on all invoices generated by the subscription.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::CreateParams::DefaultSettings::AutomaticTax::Liability))
}
attr_accessor :liability
sig {
params(enabled: T::Boolean, liability: T.nilable(::Stripe::SubscriptionSchedule::CreateParams::DefaultSettings::AutomaticTax::Liability)).void
}
def initialize(enabled: nil, liability: nil); end
end
class BillingThresholds < Stripe::RequestParams
# Monetary threshold that triggers the subscription to advance to a new billing period
sig { returns(T.nilable(Integer)) }
attr_accessor :amount_gte
# Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :reset_billing_cycle_anchor
sig {
params(amount_gte: T.nilable(Integer), reset_billing_cycle_anchor: T.nilable(T::Boolean)).void
}
def initialize(amount_gte: nil, reset_billing_cycle_anchor: nil); end
end
class InvoiceSettings < Stripe::RequestParams
class Issuer < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# The account tax IDs associated with the subscription schedule. Will be set on invoices generated by the subscription schedule.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :account_tax_ids
# Number of days within which a customer must pay invoices generated by this subscription schedule. This value will be `null` for subscription schedules where `collection_method=charge_automatically`.
sig { returns(T.nilable(Integer)) }
attr_accessor :days_until_due
# The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::CreateParams::DefaultSettings::InvoiceSettings::Issuer))
}
attr_accessor :issuer
sig {
params(account_tax_ids: T.nilable(T.nilable(T.any(String, T::Array[String]))), days_until_due: T.nilable(Integer), issuer: T.nilable(::Stripe::SubscriptionSchedule::CreateParams::DefaultSettings::InvoiceSettings::Issuer)).void
}
def initialize(account_tax_ids: nil, days_until_due: nil, issuer: nil); end
end
class TransferData < Stripe::RequestParams
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
sig { returns(T.nilable(Float)) }
attr_accessor :amount_percent
# ID of an existing, connected Stripe account.
sig { returns(String) }
attr_accessor :destination
sig { params(amount_percent: T.nilable(Float), destination: String).void }
def initialize(amount_percent: nil, destination: nil); end
end
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).
sig { returns(T.nilable(Float)) }
attr_accessor :application_fee_percent
# Default settings for automatic tax computation.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::CreateParams::DefaultSettings::AutomaticTax))
}
attr_accessor :automatic_tax
# Can be set to `phase_start` to set the anchor to the start of the phase or `automatic` to automatically change it if needed. Cannot be set to `phase_start` if this phase specifies a trial. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).
sig { returns(T.nilable(String)) }
attr_accessor :billing_cycle_anchor
# Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionSchedule::CreateParams::DefaultSettings::BillingThresholds))))
}
attr_accessor :billing_thresholds
# Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically` on creation.
sig { returns(T.nilable(String)) }
attr_accessor :collection_method
# ID of the default payment method for the subscription schedule. It must belong to the customer associated with the subscription schedule. If not set, invoices will use the default payment method in the customer's invoice settings.
sig { returns(T.nilable(String)) }
attr_accessor :default_payment_method
# Subscription description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :description
# All invoices will be billed using the specified settings.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::CreateParams::DefaultSettings::InvoiceSettings))
}
attr_accessor :invoice_settings
# The account on behalf of which to charge, for each of the associated subscription's invoices.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :on_behalf_of
# The data with which to automatically create a Transfer for each of the associated subscription's invoices.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionSchedule::CreateParams::DefaultSettings::TransferData))))
}
attr_accessor :transfer_data
sig {
params(application_fee_percent: T.nilable(Float), automatic_tax: T.nilable(::Stripe::SubscriptionSchedule::CreateParams::DefaultSettings::AutomaticTax), billing_cycle_anchor: T.nilable(String), billing_thresholds: T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionSchedule::CreateParams::DefaultSettings::BillingThresholds))), collection_method: T.nilable(String), default_payment_method: T.nilable(String), description: T.nilable(T.nilable(String)), invoice_settings: T.nilable(::Stripe::SubscriptionSchedule::CreateParams::DefaultSettings::InvoiceSettings), on_behalf_of: T.nilable(T.nilable(String)), transfer_data: T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionSchedule::CreateParams::DefaultSettings::TransferData)))).void
}
def initialize(
application_fee_percent: nil,
automatic_tax: nil,
billing_cycle_anchor: nil,
billing_thresholds: nil,
collection_method: nil,
default_payment_method: nil,
description: nil,
invoice_settings: nil,
on_behalf_of: nil,
transfer_data: nil
); end
end
class Phase < Stripe::RequestParams
class AddInvoiceItem < Stripe::RequestParams
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::CreateParams::Phase::AddInvoiceItem::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::SubscriptionSchedule::CreateParams::Phase::AddInvoiceItem::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::CreateParams::Phase::AddInvoiceItem::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::SubscriptionSchedule::CreateParams::Phase::AddInvoiceItem::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class PriceData < Stripe::RequestParams
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
sig { returns(String) }
attr_accessor :product
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge or a negative integer representing the amount to credit to the customer.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, product: String, tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
# The coupons to redeem into discounts for the item.
sig {
returns(T.nilable(T::Array[::Stripe::SubscriptionSchedule::CreateParams::Phase::AddInvoiceItem::Discount]))
}
attr_accessor :discounts
# The ID of the price object. One of `price` or `price_data` is required.
sig { returns(T.nilable(String)) }
attr_accessor :price
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::CreateParams::Phase::AddInvoiceItem::PriceData))
}
attr_accessor :price_data
# Quantity for this item. Defaults to 1.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# The tax rates which apply to the item. When set, the `default_tax_rates` do not apply to this item.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
sig {
params(discounts: T.nilable(T::Array[::Stripe::SubscriptionSchedule::CreateParams::Phase::AddInvoiceItem::Discount]), price: T.nilable(String), price_data: T.nilable(::Stripe::SubscriptionSchedule::CreateParams::Phase::AddInvoiceItem::PriceData), quantity: T.nilable(Integer), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String])))).void
}
def initialize(
discounts: nil,
price: nil,
price_data: nil,
quantity: nil,
tax_rates: nil
); end
end
class AutomaticTax < Stripe::RequestParams
class Liability < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# Enabled automatic tax calculation which will automatically compute tax rates on all invoices generated by the subscription.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::CreateParams::Phase::AutomaticTax::Liability))
}
attr_accessor :liability
sig {
params(enabled: T::Boolean, liability: T.nilable(::Stripe::SubscriptionSchedule::CreateParams::Phase::AutomaticTax::Liability)).void
}
def initialize(enabled: nil, liability: nil); end
end
class BillingThresholds < Stripe::RequestParams
# Monetary threshold that triggers the subscription to advance to a new billing period
sig { returns(T.nilable(Integer)) }
attr_accessor :amount_gte
# Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :reset_billing_cycle_anchor
sig {
params(amount_gte: T.nilable(Integer), reset_billing_cycle_anchor: T.nilable(T::Boolean)).void
}
def initialize(amount_gte: nil, reset_billing_cycle_anchor: nil); end
end
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::CreateParams::Phase::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::SubscriptionSchedule::CreateParams::Phase::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::CreateParams::Phase::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::SubscriptionSchedule::CreateParams::Phase::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class InvoiceSettings < Stripe::RequestParams
class Issuer < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# The account tax IDs associated with this phase of the subscription schedule. Will be set on invoices generated by this phase of the subscription schedule.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :account_tax_ids
# Number of days within which a customer must pay invoices generated by this subscription schedule. This value will be `null` for subscription schedules where `billing=charge_automatically`.
sig { returns(T.nilable(Integer)) }
attr_accessor :days_until_due
# The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::CreateParams::Phase::InvoiceSettings::Issuer))
}
attr_accessor :issuer
sig {
params(account_tax_ids: T.nilable(T.nilable(T.any(String, T::Array[String]))), days_until_due: T.nilable(Integer), issuer: T.nilable(::Stripe::SubscriptionSchedule::CreateParams::Phase::InvoiceSettings::Issuer)).void
}
def initialize(account_tax_ids: nil, days_until_due: nil, issuer: nil); end
end
class Item < Stripe::RequestParams
class BillingThresholds < Stripe::RequestParams
# Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))
sig { returns(Integer) }
attr_accessor :usage_gte
sig { params(usage_gte: Integer).void }
def initialize(usage_gte: nil); end
end
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::CreateParams::Phase::Item::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::SubscriptionSchedule::CreateParams::Phase::Item::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::CreateParams::Phase::Item::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::SubscriptionSchedule::CreateParams::Phase::Item::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class PriceData < Stripe::RequestParams
class Recurring < Stripe::RequestParams
# Specifies billing frequency. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: T.nilable(Integer)).void }
def initialize(interval: nil, interval_count: nil); end
end
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
sig { returns(String) }
attr_accessor :product
# The recurring components of a price such as `interval` and `interval_count`.
sig {
returns(::Stripe::SubscriptionSchedule::CreateParams::Phase::Item::PriceData::Recurring)
}
attr_accessor :recurring
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, product: String, recurring: ::Stripe::SubscriptionSchedule::CreateParams::Phase::Item::PriceData::Recurring, tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
recurring: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
class Trial < Stripe::RequestParams
# List of price IDs which, if present on the subscription following a paid trial, constitute opting-in to the paid trial. Currently only supports at most 1 price ID.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :converts_to
# Determines the type of trial for this item.
sig { returns(String) }
attr_accessor :type
sig { params(converts_to: T.nilable(T::Array[String]), type: String).void }
def initialize(converts_to: nil, type: nil); end
end
# Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionSchedule::CreateParams::Phase::Item::BillingThresholds))))
}
attr_accessor :billing_thresholds
# The coupons to redeem into discounts for the subscription item.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::SubscriptionSchedule::CreateParams::Phase::Item::Discount]))))
}
attr_accessor :discounts
# Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to a configuration item. Metadata on a configuration item will update the underlying subscription item's `metadata` when the phase is entered, adding new keys and replacing existing keys. Individual keys in the subscription item's `metadata` can be unset by posting an empty value to them in the configuration item's `metadata`. To unset all keys in the subscription item's `metadata`, update the subscription item directly or unset every key individually from the configuration item's `metadata`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The plan ID to subscribe to. You may specify the same ID in `plan` and `price`.
sig { returns(T.nilable(String)) }
attr_accessor :plan
# The ID of the price object.
sig { returns(T.nilable(String)) }
attr_accessor :price
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::CreateParams::Phase::Item::PriceData))
}
attr_accessor :price_data
# Quantity for the given price. Can be set only if the price's `usage_type` is `licensed` and not `metered`.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
# Options that configure the trial on the subscription item.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::CreateParams::Phase::Item::Trial))
}
attr_accessor :trial
sig {
params(billing_thresholds: T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionSchedule::CreateParams::Phase::Item::BillingThresholds))), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::SubscriptionSchedule::CreateParams::Phase::Item::Discount]))), metadata: T.nilable(T::Hash[String, String]), plan: T.nilable(String), price: T.nilable(String), price_data: T.nilable(::Stripe::SubscriptionSchedule::CreateParams::Phase::Item::PriceData), quantity: T.nilable(Integer), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String]))), trial: T.nilable(::Stripe::SubscriptionSchedule::CreateParams::Phase::Item::Trial)).void
}
def initialize(
billing_thresholds: nil,
discounts: nil,
metadata: nil,
plan: nil,
price: nil,
price_data: nil,
quantity: nil,
tax_rates: nil,
trial: nil
); end
end
class PauseCollection < Stripe::RequestParams
# The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`.
sig { returns(String) }
attr_accessor :behavior
sig { params(behavior: String).void }
def initialize(behavior: nil); end
end
class TransferData < Stripe::RequestParams
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
sig { returns(T.nilable(Float)) }
attr_accessor :amount_percent
# ID of an existing, connected Stripe account.
sig { returns(String) }
attr_accessor :destination
sig { params(amount_percent: T.nilable(Float), destination: String).void }
def initialize(amount_percent: nil, destination: nil); end
end
class TrialSettings < Stripe::RequestParams
class EndBehavior < Stripe::RequestParams
# Configure how an opt-in following a paid trial is billed when using `billing_behavior: prorate_up_front`.
sig { returns(T.nilable(String)) }
attr_accessor :prorate_up_front
sig { params(prorate_up_front: T.nilable(String)).void }
def initialize(prorate_up_front: nil); end
end
# Defines how the subscription should behave when a trial ends.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::CreateParams::Phase::TrialSettings::EndBehavior))
}
attr_accessor :end_behavior
sig {
params(end_behavior: T.nilable(::Stripe::SubscriptionSchedule::CreateParams::Phase::TrialSettings::EndBehavior)).void
}
def initialize(end_behavior: nil); end
end
# A list of prices and quantities that will generate invoice items appended to the next invoice for this phase. You may pass up to 20 items.
sig {
returns(T.nilable(T::Array[::Stripe::SubscriptionSchedule::CreateParams::Phase::AddInvoiceItem]))
}
attr_accessor :add_invoice_items
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).
sig { returns(T.nilable(Float)) }
attr_accessor :application_fee_percent
# Automatic tax settings for this phase.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::CreateParams::Phase::AutomaticTax))
}
attr_accessor :automatic_tax
# Can be set to `phase_start` to set the anchor to the start of the phase or `automatic` to automatically change it if needed. Cannot be set to `phase_start` if this phase specifies a trial. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).
sig { returns(T.nilable(String)) }
attr_accessor :billing_cycle_anchor
# Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionSchedule::CreateParams::Phase::BillingThresholds))))
}
attr_accessor :billing_thresholds
# Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically` on creation.
sig { returns(T.nilable(String)) }
attr_accessor :collection_method
# 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).
sig { returns(T.nilable(String)) }
attr_accessor :currency
# ID of the default payment method for the subscription schedule. It must belong to the customer associated with the subscription schedule. If not set, invoices will use the default payment method in the customer's invoice settings.
sig { returns(T.nilable(String)) }
attr_accessor :default_payment_method
# A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will set the Subscription's [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates), which means they will be the Invoice's [`default_tax_rates`](https://stripe.com/docs/api/invoices/create#create_invoice-default_tax_rates) for any Invoices issued by the Subscription during this Phase.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :default_tax_rates
# Subscription description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :description
# The coupons to redeem into discounts for the schedule phase. If not specified, inherits the discount from the subscription's customer. Pass an empty string to avoid inheriting any discounts.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::SubscriptionSchedule::CreateParams::Phase::Discount]))))
}
attr_accessor :discounts
# The date at which this phase of the subscription schedule ends. If set, `iterations` must not be set.
sig { returns(T.nilable(Integer)) }
attr_accessor :end_date
# All invoices will be billed using the specified settings.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::CreateParams::Phase::InvoiceSettings))
}
attr_accessor :invoice_settings
# List of configuration items, each with an attached price, to apply during this phase of the subscription schedule.
sig { returns(T::Array[::Stripe::SubscriptionSchedule::CreateParams::Phase::Item]) }
attr_accessor :items
# Integer representing the multiplier applied to the price interval. For example, `iterations=2` applied to a price with `interval=month` and `interval_count=3` results in a phase of duration `2 * 3 months = 6 months`. If set, `end_date` must not be set.
sig { returns(T.nilable(Integer)) }
attr_accessor :iterations
# Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to a phase. Metadata on a schedule's phase will update the underlying subscription's `metadata` when the phase is entered, adding new keys and replacing existing keys in the subscription's `metadata`. Individual keys in the subscription's `metadata` can be unset by posting an empty value to them in the phase's `metadata`. To unset all keys in the subscription's `metadata`, update the subscription directly or unset every key individually from the phase's `metadata`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The account on behalf of which to charge, for each of the associated subscription's invoices.
sig { returns(T.nilable(String)) }
attr_accessor :on_behalf_of
# If specified, payment collection for this subscription will be paused. Note that the subscription status will be unchanged and will not be updated to `paused`. Learn more about [pausing collection](https://stripe.com/docs/billing/subscriptions/pause-payment).
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::CreateParams::Phase::PauseCollection))
}
attr_accessor :pause_collection
# Controls whether the subscription schedule should create [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when transitioning to this phase if there is a difference in billing configuration. 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 (item price, quantity, etc.) of the current phase.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
# The data with which to automatically create a Transfer for each of the associated subscription's invoices.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::CreateParams::Phase::TransferData))
}
attr_accessor :transfer_data
# If set to true the entire phase is counted as a trial and the customer will not be charged for any fees.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :trial
# Specify trial behavior when crossing phase boundaries
sig { returns(T.nilable(String)) }
attr_accessor :trial_continuation
# Sets the phase to trialing from the start date to this date. Must be before the phase end date, can not be combined with `trial`
sig { returns(T.nilable(Integer)) }
attr_accessor :trial_end
# Settings related to subscription trials.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::CreateParams::Phase::TrialSettings))
}
attr_accessor :trial_settings
sig {
params(add_invoice_items: T.nilable(T::Array[::Stripe::SubscriptionSchedule::CreateParams::Phase::AddInvoiceItem]), application_fee_percent: T.nilable(Float), automatic_tax: T.nilable(::Stripe::SubscriptionSchedule::CreateParams::Phase::AutomaticTax), billing_cycle_anchor: T.nilable(String), billing_thresholds: T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionSchedule::CreateParams::Phase::BillingThresholds))), collection_method: T.nilable(String), currency: T.nilable(String), default_payment_method: T.nilable(String), default_tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String]))), description: T.nilable(T.nilable(String)), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::SubscriptionSchedule::CreateParams::Phase::Discount]))), end_date: T.nilable(Integer), invoice_settings: T.nilable(::Stripe::SubscriptionSchedule::CreateParams::Phase::InvoiceSettings), items: T::Array[::Stripe::SubscriptionSchedule::CreateParams::Phase::Item], iterations: T.nilable(Integer), metadata: T.nilable(T::Hash[String, String]), on_behalf_of: T.nilable(String), pause_collection: T.nilable(::Stripe::SubscriptionSchedule::CreateParams::Phase::PauseCollection), proration_behavior: T.nilable(String), transfer_data: T.nilable(::Stripe::SubscriptionSchedule::CreateParams::Phase::TransferData), trial: T.nilable(T::Boolean), trial_continuation: T.nilable(String), trial_end: T.nilable(Integer), trial_settings: T.nilable(::Stripe::SubscriptionSchedule::CreateParams::Phase::TrialSettings)).void
}
def initialize(
add_invoice_items: nil,
application_fee_percent: nil,
automatic_tax: nil,
billing_cycle_anchor: nil,
billing_thresholds: nil,
collection_method: nil,
currency: nil,
default_payment_method: nil,
default_tax_rates: nil,
description: nil,
discounts: nil,
end_date: nil,
invoice_settings: nil,
items: nil,
iterations: nil,
metadata: nil,
on_behalf_of: nil,
pause_collection: nil,
proration_behavior: nil,
transfer_data: nil,
trial: nil,
trial_continuation: nil,
trial_end: nil,
trial_settings: nil
); end
end
class Prebilling < Stripe::RequestParams
# This is used to determine the number of billing cycles to prebill.
sig { returns(Integer) }
attr_accessor :iterations
# Whether to cancel or preserve `prebilling` if the subscription is updated during the prebilled period. The default value is `reset`.
sig { returns(T.nilable(String)) }
attr_accessor :update_behavior
sig { params(iterations: Integer, update_behavior: T.nilable(String)).void }
def initialize(iterations: nil, update_behavior: nil); end
end
# Configures when the subscription schedule generates prorations for phase transitions. Possible values are `prorate_on_next_phase` or `prorate_up_front` with the default being `prorate_on_next_phase`. `prorate_on_next_phase` will apply phase changes and generate prorations at transition time. `prorate_up_front` will bill for all phases within the current billing cycle up front.
sig { returns(T.nilable(String)) }
attr_accessor :billing_behavior
# Controls how prorations and invoices for subscriptions are calculated and orchestrated.
sig { returns(T.nilable(String)) }
attr_accessor :billing_mode
# The identifier of the customer to create the subscription schedule for.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# The identifier of the account to create the subscription schedule for.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# Object representing the subscription schedule's default settings.
sig { returns(T.nilable(::Stripe::SubscriptionSchedule::CreateParams::DefaultSettings)) }
attr_accessor :default_settings
# Behavior of the subscription schedule and underlying subscription when it ends. Possible values are `release` or `cancel` with the default being `release`. `release` will end the subscription schedule and keep the underlying subscription running. `cancel` will end the subscription schedule and cancel the underlying subscription.
sig { returns(T.nilable(String)) }
attr_accessor :end_behavior
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Migrate an existing subscription to be managed by a subscription schedule. If this parameter is set, a subscription schedule will be created using the subscription's item(s), set to auto-renew using the subscription's interval. When using this parameter, other parameters (such as phase values) cannot be set. To create a subscription schedule with other modifications, we recommend making two separate API calls.
sig { returns(T.nilable(String)) }
attr_accessor :from_subscription
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# List representing phases of the subscription schedule. Each phase can be customized to have different durations, plans, and coupons. If there are multiple phases, the `end_date` of one phase will always equal the `start_date` of the next phase.
sig { returns(T.nilable(T::Array[::Stripe::SubscriptionSchedule::CreateParams::Phase])) }
attr_accessor :phases
# If specified, the invoicing for the given billing cycle iterations will be processed now.
sig { returns(T.nilable(::Stripe::SubscriptionSchedule::CreateParams::Prebilling)) }
attr_accessor :prebilling
# When the subscription schedule starts. We recommend using `now` so that it starts the subscription immediately. You can also use a Unix timestamp to backdate the subscription so that it starts on a past date, or set a future date for the subscription to start on.
sig { returns(T.nilable(T.any(Integer, String))) }
attr_accessor :start_date
sig {
params(billing_behavior: T.nilable(String), billing_mode: T.nilable(String), customer: T.nilable(String), customer_account: T.nilable(String), default_settings: T.nilable(::Stripe::SubscriptionSchedule::CreateParams::DefaultSettings), end_behavior: T.nilable(String), expand: T.nilable(T::Array[String]), from_subscription: T.nilable(String), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), phases: T.nilable(T::Array[::Stripe::SubscriptionSchedule::CreateParams::Phase]), prebilling: T.nilable(::Stripe::SubscriptionSchedule::CreateParams::Prebilling), start_date: T.nilable(T.any(Integer, String))).void
}
def initialize(
billing_behavior: nil,
billing_mode: nil,
customer: nil,
customer_account: nil,
default_settings: nil,
end_behavior: nil,
expand: nil,
from_subscription: nil,
metadata: nil,
phases: nil,
prebilling: nil,
start_date: nil
); end
end
class UpdateParams < Stripe::RequestParams
class DefaultSettings < Stripe::RequestParams
class AutomaticTax < Stripe::RequestParams
class Liability < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# Enabled automatic tax calculation which will automatically compute tax rates on all invoices generated by the subscription.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::UpdateParams::DefaultSettings::AutomaticTax::Liability))
}
attr_accessor :liability
sig {
params(enabled: T::Boolean, liability: T.nilable(::Stripe::SubscriptionSchedule::UpdateParams::DefaultSettings::AutomaticTax::Liability)).void
}
def initialize(enabled: nil, liability: nil); end
end
class BillingThresholds < Stripe::RequestParams
# Monetary threshold that triggers the subscription to advance to a new billing period
sig { returns(T.nilable(Integer)) }
attr_accessor :amount_gte
# Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :reset_billing_cycle_anchor
sig {
params(amount_gte: T.nilable(Integer), reset_billing_cycle_anchor: T.nilable(T::Boolean)).void
}
def initialize(amount_gte: nil, reset_billing_cycle_anchor: nil); end
end
class InvoiceSettings < Stripe::RequestParams
class Issuer < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# The account tax IDs associated with the subscription schedule. Will be set on invoices generated by the subscription schedule.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :account_tax_ids
# Number of days within which a customer must pay invoices generated by this subscription schedule. This value will be `null` for subscription schedules where `collection_method=charge_automatically`.
sig { returns(T.nilable(Integer)) }
attr_accessor :days_until_due
# The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::UpdateParams::DefaultSettings::InvoiceSettings::Issuer))
}
attr_accessor :issuer
sig {
params(account_tax_ids: T.nilable(T.nilable(T.any(String, T::Array[String]))), days_until_due: T.nilable(Integer), issuer: T.nilable(::Stripe::SubscriptionSchedule::UpdateParams::DefaultSettings::InvoiceSettings::Issuer)).void
}
def initialize(account_tax_ids: nil, days_until_due: nil, issuer: nil); end
end
class TransferData < Stripe::RequestParams
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
sig { returns(T.nilable(Float)) }
attr_accessor :amount_percent
# ID of an existing, connected Stripe account.
sig { returns(String) }
attr_accessor :destination
sig { params(amount_percent: T.nilable(Float), destination: String).void }
def initialize(amount_percent: nil, destination: nil); end
end
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).
sig { returns(T.nilable(Float)) }
attr_accessor :application_fee_percent
# Default settings for automatic tax computation.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::UpdateParams::DefaultSettings::AutomaticTax))
}
attr_accessor :automatic_tax
# Can be set to `phase_start` to set the anchor to the start of the phase or `automatic` to automatically change it if needed. Cannot be set to `phase_start` if this phase specifies a trial. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).
sig { returns(T.nilable(String)) }
attr_accessor :billing_cycle_anchor
# Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionSchedule::UpdateParams::DefaultSettings::BillingThresholds))))
}
attr_accessor :billing_thresholds
# Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically` on creation.
sig { returns(T.nilable(String)) }
attr_accessor :collection_method
# ID of the default payment method for the subscription schedule. It must belong to the customer associated with the subscription schedule. If not set, invoices will use the default payment method in the customer's invoice settings.
sig { returns(T.nilable(String)) }
attr_accessor :default_payment_method
# Subscription description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :description
# All invoices will be billed using the specified settings.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::UpdateParams::DefaultSettings::InvoiceSettings))
}
attr_accessor :invoice_settings
# The account on behalf of which to charge, for each of the associated subscription's invoices.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :on_behalf_of
# The data with which to automatically create a Transfer for each of the associated subscription's invoices.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionSchedule::UpdateParams::DefaultSettings::TransferData))))
}
attr_accessor :transfer_data
sig {
params(application_fee_percent: T.nilable(Float), automatic_tax: T.nilable(::Stripe::SubscriptionSchedule::UpdateParams::DefaultSettings::AutomaticTax), billing_cycle_anchor: T.nilable(String), billing_thresholds: T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionSchedule::UpdateParams::DefaultSettings::BillingThresholds))), collection_method: T.nilable(String), default_payment_method: T.nilable(String), description: T.nilable(T.nilable(String)), invoice_settings: T.nilable(::Stripe::SubscriptionSchedule::UpdateParams::DefaultSettings::InvoiceSettings), on_behalf_of: T.nilable(T.nilable(String)), transfer_data: T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionSchedule::UpdateParams::DefaultSettings::TransferData)))).void
}
def initialize(
application_fee_percent: nil,
automatic_tax: nil,
billing_cycle_anchor: nil,
billing_thresholds: nil,
collection_method: nil,
default_payment_method: nil,
description: nil,
invoice_settings: nil,
on_behalf_of: nil,
transfer_data: nil
); end
end
class Phase < Stripe::RequestParams
class AddInvoiceItem < Stripe::RequestParams
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::UpdateParams::Phase::AddInvoiceItem::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::SubscriptionSchedule::UpdateParams::Phase::AddInvoiceItem::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::UpdateParams::Phase::AddInvoiceItem::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::SubscriptionSchedule::UpdateParams::Phase::AddInvoiceItem::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class PriceData < Stripe::RequestParams
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
sig { returns(String) }
attr_accessor :product
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge or a negative integer representing the amount to credit to the customer.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, product: String, tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
# The coupons to redeem into discounts for the item.
sig {
returns(T.nilable(T::Array[::Stripe::SubscriptionSchedule::UpdateParams::Phase::AddInvoiceItem::Discount]))
}
attr_accessor :discounts
# The ID of the price object. One of `price` or `price_data` is required.
sig { returns(T.nilable(String)) }
attr_accessor :price
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::UpdateParams::Phase::AddInvoiceItem::PriceData))
}
attr_accessor :price_data
# Quantity for this item. Defaults to 1.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# The tax rates which apply to the item. When set, the `default_tax_rates` do not apply to this item.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
sig {
params(discounts: T.nilable(T::Array[::Stripe::SubscriptionSchedule::UpdateParams::Phase::AddInvoiceItem::Discount]), price: T.nilable(String), price_data: T.nilable(::Stripe::SubscriptionSchedule::UpdateParams::Phase::AddInvoiceItem::PriceData), quantity: T.nilable(Integer), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String])))).void
}
def initialize(
discounts: nil,
price: nil,
price_data: nil,
quantity: nil,
tax_rates: nil
); end
end
class AutomaticTax < Stripe::RequestParams
class Liability < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# Enabled automatic tax calculation which will automatically compute tax rates on all invoices generated by the subscription.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::UpdateParams::Phase::AutomaticTax::Liability))
}
attr_accessor :liability
sig {
params(enabled: T::Boolean, liability: T.nilable(::Stripe::SubscriptionSchedule::UpdateParams::Phase::AutomaticTax::Liability)).void
}
def initialize(enabled: nil, liability: nil); end
end
class BillingThresholds < Stripe::RequestParams
# Monetary threshold that triggers the subscription to advance to a new billing period
sig { returns(T.nilable(Integer)) }
attr_accessor :amount_gte
# Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :reset_billing_cycle_anchor
sig {
params(amount_gte: T.nilable(Integer), reset_billing_cycle_anchor: T.nilable(T::Boolean)).void
}
def initialize(amount_gte: nil, reset_billing_cycle_anchor: nil); end
end
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::UpdateParams::Phase::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::SubscriptionSchedule::UpdateParams::Phase::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::UpdateParams::Phase::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::SubscriptionSchedule::UpdateParams::Phase::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class InvoiceSettings < Stripe::RequestParams
class Issuer < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# The account tax IDs associated with this phase of the subscription schedule. Will be set on invoices generated by this phase of the subscription schedule.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :account_tax_ids
# Number of days within which a customer must pay invoices generated by this subscription schedule. This value will be `null` for subscription schedules where `billing=charge_automatically`.
sig { returns(T.nilable(Integer)) }
attr_accessor :days_until_due
# The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::UpdateParams::Phase::InvoiceSettings::Issuer))
}
attr_accessor :issuer
sig {
params(account_tax_ids: T.nilable(T.nilable(T.any(String, T::Array[String]))), days_until_due: T.nilable(Integer), issuer: T.nilable(::Stripe::SubscriptionSchedule::UpdateParams::Phase::InvoiceSettings::Issuer)).void
}
def initialize(account_tax_ids: nil, days_until_due: nil, issuer: nil); end
end
class Item < Stripe::RequestParams
class BillingThresholds < Stripe::RequestParams
# Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))
sig { returns(Integer) }
attr_accessor :usage_gte
sig { params(usage_gte: Integer).void }
def initialize(usage_gte: nil); end
end
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::UpdateParams::Phase::Item::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::SubscriptionSchedule::UpdateParams::Phase::Item::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::UpdateParams::Phase::Item::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::SubscriptionSchedule::UpdateParams::Phase::Item::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class PriceData < Stripe::RequestParams
class Recurring < Stripe::RequestParams
# Specifies billing frequency. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: T.nilable(Integer)).void }
def initialize(interval: nil, interval_count: nil); end
end
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
sig { returns(String) }
attr_accessor :product
# The recurring components of a price such as `interval` and `interval_count`.
sig {
returns(::Stripe::SubscriptionSchedule::UpdateParams::Phase::Item::PriceData::Recurring)
}
attr_accessor :recurring
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, product: String, recurring: ::Stripe::SubscriptionSchedule::UpdateParams::Phase::Item::PriceData::Recurring, tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
recurring: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
class Trial < Stripe::RequestParams
# List of price IDs which, if present on the subscription following a paid trial, constitute opting-in to the paid trial. Currently only supports at most 1 price ID.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :converts_to
# Determines the type of trial for this item.
sig { returns(String) }
attr_accessor :type
sig { params(converts_to: T.nilable(T::Array[String]), type: String).void }
def initialize(converts_to: nil, type: nil); end
end
# Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionSchedule::UpdateParams::Phase::Item::BillingThresholds))))
}
attr_accessor :billing_thresholds
# The coupons to redeem into discounts for the subscription item.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::SubscriptionSchedule::UpdateParams::Phase::Item::Discount]))))
}
attr_accessor :discounts
# Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to a configuration item. Metadata on a configuration item will update the underlying subscription item's `metadata` when the phase is entered, adding new keys and replacing existing keys. Individual keys in the subscription item's `metadata` can be unset by posting an empty value to them in the configuration item's `metadata`. To unset all keys in the subscription item's `metadata`, update the subscription item directly or unset every key individually from the configuration item's `metadata`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The plan ID to subscribe to. You may specify the same ID in `plan` and `price`.
sig { returns(T.nilable(String)) }
attr_accessor :plan
# The ID of the price object.
sig { returns(T.nilable(String)) }
attr_accessor :price
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::UpdateParams::Phase::Item::PriceData))
}
attr_accessor :price_data
# Quantity for the given price. Can be set only if the price's `usage_type` is `licensed` and not `metered`.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
# Options that configure the trial on the subscription item.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::UpdateParams::Phase::Item::Trial))
}
attr_accessor :trial
sig {
params(billing_thresholds: T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionSchedule::UpdateParams::Phase::Item::BillingThresholds))), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::SubscriptionSchedule::UpdateParams::Phase::Item::Discount]))), metadata: T.nilable(T::Hash[String, String]), plan: T.nilable(String), price: T.nilable(String), price_data: T.nilable(::Stripe::SubscriptionSchedule::UpdateParams::Phase::Item::PriceData), quantity: T.nilable(Integer), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String]))), trial: T.nilable(::Stripe::SubscriptionSchedule::UpdateParams::Phase::Item::Trial)).void
}
def initialize(
billing_thresholds: nil,
discounts: nil,
metadata: nil,
plan: nil,
price: nil,
price_data: nil,
quantity: nil,
tax_rates: nil,
trial: nil
); end
end
class PauseCollection < Stripe::RequestParams
# The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`.
sig { returns(String) }
attr_accessor :behavior
sig { params(behavior: String).void }
def initialize(behavior: nil); end
end
class TransferData < Stripe::RequestParams
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
sig { returns(T.nilable(Float)) }
attr_accessor :amount_percent
# ID of an existing, connected Stripe account.
sig { returns(String) }
attr_accessor :destination
sig { params(amount_percent: T.nilable(Float), destination: String).void }
def initialize(amount_percent: nil, destination: nil); end
end
class TrialSettings < Stripe::RequestParams
class EndBehavior < Stripe::RequestParams
# Configure how an opt-in following a paid trial is billed when using `billing_behavior: prorate_up_front`.
sig { returns(T.nilable(String)) }
attr_accessor :prorate_up_front
sig { params(prorate_up_front: T.nilable(String)).void }
def initialize(prorate_up_front: nil); end
end
# Defines how the subscription should behave when a trial ends.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::UpdateParams::Phase::TrialSettings::EndBehavior))
}
attr_accessor :end_behavior
sig {
params(end_behavior: T.nilable(::Stripe::SubscriptionSchedule::UpdateParams::Phase::TrialSettings::EndBehavior)).void
}
def initialize(end_behavior: nil); end
end
# A list of prices and quantities that will generate invoice items appended to the next invoice for this phase. You may pass up to 20 items.
sig {
returns(T.nilable(T::Array[::Stripe::SubscriptionSchedule::UpdateParams::Phase::AddInvoiceItem]))
}
attr_accessor :add_invoice_items
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).
sig { returns(T.nilable(Float)) }
attr_accessor :application_fee_percent
# Automatic tax settings for this phase.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::UpdateParams::Phase::AutomaticTax))
}
attr_accessor :automatic_tax
# Can be set to `phase_start` to set the anchor to the start of the phase or `automatic` to automatically change it if needed. Cannot be set to `phase_start` if this phase specifies a trial. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).
sig { returns(T.nilable(String)) }
attr_accessor :billing_cycle_anchor
# Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionSchedule::UpdateParams::Phase::BillingThresholds))))
}
attr_accessor :billing_thresholds
# Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically` on creation.
sig { returns(T.nilable(String)) }
attr_accessor :collection_method
# 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).
sig { returns(T.nilable(String)) }
attr_accessor :currency
# ID of the default payment method for the subscription schedule. It must belong to the customer associated with the subscription schedule. If not set, invoices will use the default payment method in the customer's invoice settings.
sig { returns(T.nilable(String)) }
attr_accessor :default_payment_method
# A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will set the Subscription's [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates), which means they will be the Invoice's [`default_tax_rates`](https://stripe.com/docs/api/invoices/create#create_invoice-default_tax_rates) for any Invoices issued by the Subscription during this Phase.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :default_tax_rates
# Subscription description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :description
# The coupons to redeem into discounts for the schedule phase. If not specified, inherits the discount from the subscription's customer. Pass an empty string to avoid inheriting any discounts.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::SubscriptionSchedule::UpdateParams::Phase::Discount]))))
}
attr_accessor :discounts
# The date at which this phase of the subscription schedule ends. If set, `iterations` must not be set.
sig { returns(T.nilable(T.any(Integer, String))) }
attr_accessor :end_date
# All invoices will be billed using the specified settings.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::UpdateParams::Phase::InvoiceSettings))
}
attr_accessor :invoice_settings
# List of configuration items, each with an attached price, to apply during this phase of the subscription schedule.
sig { returns(T::Array[::Stripe::SubscriptionSchedule::UpdateParams::Phase::Item]) }
attr_accessor :items
# Integer representing the multiplier applied to the price interval. For example, `iterations=2` applied to a price with `interval=month` and `interval_count=3` results in a phase of duration `2 * 3 months = 6 months`. If set, `end_date` must not be set.
sig { returns(T.nilable(Integer)) }
attr_accessor :iterations
# Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to a phase. Metadata on a schedule's phase will update the underlying subscription's `metadata` when the phase is entered, adding new keys and replacing existing keys in the subscription's `metadata`. Individual keys in the subscription's `metadata` can be unset by posting an empty value to them in the phase's `metadata`. To unset all keys in the subscription's `metadata`, update the subscription directly or unset every key individually from the phase's `metadata`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The account on behalf of which to charge, for each of the associated subscription's invoices.
sig { returns(T.nilable(String)) }
attr_accessor :on_behalf_of
# If specified, payment collection for this subscription will be paused. Note that the subscription status will be unchanged and will not be updated to `paused`. Learn more about [pausing collection](https://stripe.com/docs/billing/subscriptions/pause-payment).
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::UpdateParams::Phase::PauseCollection))
}
attr_accessor :pause_collection
# Controls whether the subscription schedule should create [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when transitioning to this phase if there is a difference in billing configuration. 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 (item price, quantity, etc.) of the current phase.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
# The date at which this phase of the subscription schedule starts or `now`. Must be set on the first phase.
sig { returns(T.nilable(T.any(Integer, String))) }
attr_accessor :start_date
# The data with which to automatically create a Transfer for each of the associated subscription's invoices.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::UpdateParams::Phase::TransferData))
}
attr_accessor :transfer_data
# If set to true the entire phase is counted as a trial and the customer will not be charged for any fees.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :trial
# Specify trial behavior when crossing phase boundaries
sig { returns(T.nilable(String)) }
attr_accessor :trial_continuation
# Sets the phase to trialing from the start date to this date. Must be before the phase end date, can not be combined with `trial`
sig { returns(T.nilable(T.any(Integer, String))) }
attr_accessor :trial_end
# Settings related to subscription trials.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::UpdateParams::Phase::TrialSettings))
}
attr_accessor :trial_settings
sig {
params(add_invoice_items: T.nilable(T::Array[::Stripe::SubscriptionSchedule::UpdateParams::Phase::AddInvoiceItem]), application_fee_percent: T.nilable(Float), automatic_tax: T.nilable(::Stripe::SubscriptionSchedule::UpdateParams::Phase::AutomaticTax), billing_cycle_anchor: T.nilable(String), billing_thresholds: T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionSchedule::UpdateParams::Phase::BillingThresholds))), collection_method: T.nilable(String), currency: T.nilable(String), default_payment_method: T.nilable(String), default_tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String]))), description: T.nilable(T.nilable(String)), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::SubscriptionSchedule::UpdateParams::Phase::Discount]))), end_date: T.nilable(T.any(Integer, String)), invoice_settings: T.nilable(::Stripe::SubscriptionSchedule::UpdateParams::Phase::InvoiceSettings), items: T::Array[::Stripe::SubscriptionSchedule::UpdateParams::Phase::Item], iterations: T.nilable(Integer), metadata: T.nilable(T::Hash[String, String]), on_behalf_of: T.nilable(String), pause_collection: T.nilable(::Stripe::SubscriptionSchedule::UpdateParams::Phase::PauseCollection), proration_behavior: T.nilable(String), start_date: T.nilable(T.any(Integer, String)), transfer_data: T.nilable(::Stripe::SubscriptionSchedule::UpdateParams::Phase::TransferData), trial: T.nilable(T::Boolean), trial_continuation: T.nilable(String), trial_end: T.nilable(T.any(Integer, String)), trial_settings: T.nilable(::Stripe::SubscriptionSchedule::UpdateParams::Phase::TrialSettings)).void
}
def initialize(
add_invoice_items: nil,
application_fee_percent: nil,
automatic_tax: nil,
billing_cycle_anchor: nil,
billing_thresholds: nil,
collection_method: nil,
currency: nil,
default_payment_method: nil,
default_tax_rates: nil,
description: nil,
discounts: nil,
end_date: nil,
invoice_settings: nil,
items: nil,
iterations: nil,
metadata: nil,
on_behalf_of: nil,
pause_collection: nil,
proration_behavior: nil,
start_date: nil,
transfer_data: nil,
trial: nil,
trial_continuation: nil,
trial_end: nil,
trial_settings: nil
); end
end
class Prebilling < Stripe::RequestParams
# This is used to determine the number of billing cycles to prebill.
sig { returns(Integer) }
attr_accessor :iterations
# Whether to cancel or preserve `prebilling` if the subscription is updated during the prebilled period. The default value is `reset`.
sig { returns(T.nilable(String)) }
attr_accessor :update_behavior
sig { params(iterations: Integer, update_behavior: T.nilable(String)).void }
def initialize(iterations: nil, update_behavior: nil); end
end
# Configures when the subscription schedule generates prorations for phase transitions. Possible values are `prorate_on_next_phase` or `prorate_up_front` with the default being `prorate_on_next_phase`. `prorate_on_next_phase` will apply phase changes and generate prorations at transition time. `prorate_up_front` will bill for all phases within the current billing cycle up front.
sig { returns(T.nilable(String)) }
attr_accessor :billing_behavior
# Object representing the subscription schedule's default settings.
sig { returns(T.nilable(::Stripe::SubscriptionSchedule::UpdateParams::DefaultSettings)) }
attr_accessor :default_settings
# Behavior of the subscription schedule and underlying subscription when it ends. Possible values are `release` or `cancel` with the default being `release`. `release` will end the subscription schedule and keep the underlying subscription running. `cancel` will end the subscription schedule and cancel the underlying subscription.
sig { returns(T.nilable(String)) }
attr_accessor :end_behavior
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# List representing phases of the subscription schedule. Each phase can be customized to have different durations, plans, and coupons. If there are multiple phases, the `end_date` of one phase will always equal the `start_date` of the next phase. Note that past phases can be omitted.
sig { returns(T.nilable(T::Array[::Stripe::SubscriptionSchedule::UpdateParams::Phase])) }
attr_accessor :phases
# If specified, the invoicing for the given billing cycle iterations will be processed now.
sig { returns(T.nilable(::Stripe::SubscriptionSchedule::UpdateParams::Prebilling)) }
attr_accessor :prebilling
# If the update changes the billing configuration (item price, quantity, etc.) of the current phase, indicates how prorations from this change should be handled. The default value is `create_prorations`.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
sig {
params(billing_behavior: T.nilable(String), default_settings: T.nilable(::Stripe::SubscriptionSchedule::UpdateParams::DefaultSettings), end_behavior: T.nilable(String), expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), phases: T.nilable(T::Array[::Stripe::SubscriptionSchedule::UpdateParams::Phase]), prebilling: T.nilable(::Stripe::SubscriptionSchedule::UpdateParams::Prebilling), proration_behavior: T.nilable(String)).void
}
def initialize(
billing_behavior: nil,
default_settings: nil,
end_behavior: nil,
expand: nil,
metadata: nil,
phases: nil,
prebilling: nil,
proration_behavior: nil
); end
end
class AmendParams < Stripe::RequestParams
class Amendment < Stripe::RequestParams
class AmendmentEnd < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
# The ID of a specific discount.
sig { returns(String) }
attr_accessor :discount
sig { params(discount: String).void }
def initialize(discount: nil); end
end
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Use the `end` time of a given discount.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Amendment::AmendmentEnd::DiscountEnd))
}
attr_accessor :discount_end
# Time span for the amendment starting from the `amendment_start`.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Amendment::AmendmentEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the amendment to end. Must be after the `amendment_start`.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# Select one of three ways to pass the `amendment_end`.
sig { returns(String) }
attr_accessor :type
sig {
params(discount_end: T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Amendment::AmendmentEnd::DiscountEnd), duration: T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Amendment::AmendmentEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(discount_end: nil, duration: nil, timestamp: nil, type: nil); end
end
class AmendmentStart < Stripe::RequestParams
class AmendmentEnd < Stripe::RequestParams
# The position of the previous amendment in the `amendments` array after which this amendment should begin. Indexes start from 0 and must be less than the index of the current amendment in the array.
sig { returns(Integer) }
attr_accessor :index
sig { params(index: Integer).void }
def initialize(index: nil); end
end
class DiscountEnd < Stripe::RequestParams
# The ID of a specific discount.
sig { returns(String) }
attr_accessor :discount
sig { params(discount: String).void }
def initialize(discount: nil); end
end
# Details of another amendment in the same array, immediately after which this amendment should begin.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Amendment::AmendmentStart::AmendmentEnd))
}
attr_accessor :amendment_end
# Use the `end` time of a given discount.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Amendment::AmendmentStart::DiscountEnd))
}
attr_accessor :discount_end
# A precise Unix timestamp for the amendment to start.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# Select one of three ways to pass the `amendment_start`.
sig { returns(String) }
attr_accessor :type
sig {
params(amendment_end: T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Amendment::AmendmentStart::AmendmentEnd), discount_end: T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Amendment::AmendmentStart::DiscountEnd), timestamp: T.nilable(Integer), type: String).void
}
def initialize(amendment_end: nil, discount_end: nil, timestamp: nil, type: nil); end
end
class DiscountAction < Stripe::RequestParams
class Add < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
# The coupon code to redeem.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# An ID of an existing discount for a coupon that was already redeemed.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Amendment::DiscountAction::Add::DiscountEnd))
}
attr_accessor :discount_end
# The index, starting at 0, at which to position the new discount. When not supplied, Stripe defaults to appending the discount to the end of the `discounts` array.
sig { returns(T.nilable(Integer)) }
attr_accessor :index
# The promotion code to redeem.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Amendment::DiscountAction::Add::DiscountEnd), index: T.nilable(Integer), promotion_code: T.nilable(String)).void
}
def initialize(
coupon: nil,
discount: nil,
discount_end: nil,
index: nil,
promotion_code: nil
); end
end
class Remove < Stripe::RequestParams
# The coupon code to remove from the `discounts` array.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# The ID of a discount to remove from the `discounts` array.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# The ID of a promotion code to remove from the `discounts` array.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, promotion_code: nil); end
end
class Set < Stripe::RequestParams
# The coupon code to replace the `discounts` array with.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# An ID of an existing discount to replace the `discounts` array with.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# An ID of an existing promotion code to replace the `discounts` array with.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, promotion_code: nil); end
end
# Details of the discount to add.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Amendment::DiscountAction::Add))
}
attr_accessor :add
# Details of the discount to remove.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Amendment::DiscountAction::Remove))
}
attr_accessor :remove
# Details of the discount to replace the existing discounts with.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Amendment::DiscountAction::Set))
}
attr_accessor :set
# Determines the type of discount action.
sig { returns(String) }
attr_accessor :type
sig {
params(add: T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Amendment::DiscountAction::Add), remove: T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Amendment::DiscountAction::Remove), set: T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Amendment::DiscountAction::Set), type: String).void
}
def initialize(add: nil, remove: nil, set: nil, type: nil); end
end
class ItemAction < Stripe::RequestParams
class Add < Stripe::RequestParams
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Amendment::ItemAction::Add::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Amendment::ItemAction::Add::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Amendment::ItemAction::Add::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Amendment::ItemAction::Add::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(
coupon: nil,
discount: nil,
discount_end: nil,
promotion_code: nil
); end
end
class Trial < Stripe::RequestParams
# List of price IDs which, if present on the subscription following a paid trial, constitute opting-in to the paid trial. Currently only supports at most 1 price ID.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :converts_to
# Determines the type of trial for this item.
sig { returns(String) }
attr_accessor :type
sig { params(converts_to: T.nilable(T::Array[String]), type: String).void }
def initialize(converts_to: nil, type: nil); end
end
# The discounts applied to the item. Subscription item discounts are applied before subscription discounts.
sig {
returns(T.nilable(T::Array[::Stripe::SubscriptionSchedule::AmendParams::Amendment::ItemAction::Add::Discount]))
}
attr_accessor :discounts
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The ID of the price object.
sig { returns(String) }
attr_accessor :price
# Quantity for this item.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# The tax rates that apply to this subscription item. When set, the `default_tax_rates` on the subscription do not apply to this `subscription_item`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :tax_rates
# Options that configure the trial on the subscription item.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Amendment::ItemAction::Add::Trial))
}
attr_accessor :trial
sig {
params(discounts: T.nilable(T::Array[::Stripe::SubscriptionSchedule::AmendParams::Amendment::ItemAction::Add::Discount]), metadata: T.nilable(T::Hash[String, String]), price: String, quantity: T.nilable(Integer), tax_rates: T.nilable(T::Array[String]), trial: T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Amendment::ItemAction::Add::Trial)).void
}
def initialize(
discounts: nil,
metadata: nil,
price: nil,
quantity: nil,
tax_rates: nil,
trial: nil
); end
end
class Remove < Stripe::RequestParams
# ID of a price to remove.
sig { returns(String) }
attr_accessor :price
sig { params(price: String).void }
def initialize(price: nil); end
end
class Set < Stripe::RequestParams
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Amendment::ItemAction::Set::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Amendment::ItemAction::Set::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Amendment::ItemAction::Set::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Amendment::ItemAction::Set::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(
coupon: nil,
discount: nil,
discount_end: nil,
promotion_code: nil
); end
end
class Trial < Stripe::RequestParams
# List of price IDs which, if present on the subscription following a paid trial, constitute opting-in to the paid trial. Currently only supports at most 1 price ID.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :converts_to
# Determines the type of trial for this item.
sig { returns(String) }
attr_accessor :type
sig { params(converts_to: T.nilable(T::Array[String]), type: String).void }
def initialize(converts_to: nil, type: nil); end
end
# If an item with the `price` already exists, passing this will override the `discounts` array on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `discounts`.
sig {
returns(T.nilable(T::Array[::Stripe::SubscriptionSchedule::AmendParams::Amendment::ItemAction::Set::Discount]))
}
attr_accessor :discounts
# If an item with the `price` already exists, passing this will override the `metadata` on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `metadata`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The ID of the price object.
sig { returns(String) }
attr_accessor :price
# If an item with the `price` already exists, passing this will override the quantity on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `quantity`.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# If an item with the `price` already exists, passing this will override the `tax_rates` array on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `tax_rates`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :tax_rates
# If an item with the `price` already exists, passing this will override the `trial` configuration on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `trial`.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Amendment::ItemAction::Set::Trial))
}
attr_accessor :trial
sig {
params(discounts: T.nilable(T::Array[::Stripe::SubscriptionSchedule::AmendParams::Amendment::ItemAction::Set::Discount]), metadata: T.nilable(T::Hash[String, String]), price: String, quantity: T.nilable(Integer), tax_rates: T.nilable(T::Array[String]), trial: T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Amendment::ItemAction::Set::Trial)).void
}
def initialize(
discounts: nil,
metadata: nil,
price: nil,
quantity: nil,
tax_rates: nil,
trial: nil
); end
end
# Details of the subscription item to add. If an item with the same `price` exists, it will be replaced by this new item. Otherwise, it adds the new item.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Amendment::ItemAction::Add))
}
attr_accessor :add
# Details of the subscription item to remove.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Amendment::ItemAction::Remove))
}
attr_accessor :remove
# Details of the subscription item to replace the existing items with. If an item with the `set[price]` already exists, the `items` array is not cleared. Instead, all of the other `set` properties that are passed in this request will replace the existing values for the configuration item.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Amendment::ItemAction::Set))
}
attr_accessor :set
# Determines the type of item action.
sig { returns(String) }
attr_accessor :type
sig {
params(add: T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Amendment::ItemAction::Add), remove: T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Amendment::ItemAction::Remove), set: T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Amendment::ItemAction::Set), type: String).void
}
def initialize(add: nil, remove: nil, set: nil, type: nil); end
end
class MetadataAction < Stripe::RequestParams
# Key-value pairs to add to schedule phase metadata. These values will merge with existing schedule phase metadata.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :add
# Keys to remove from schedule phase metadata.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :remove
# Key-value pairs to set as schedule phase metadata. Existing schedule phase metadata will be overwritten.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :set
# Select one of three ways to update phase-level `metadata` on subscription schedules.
sig { returns(String) }
attr_accessor :type
sig {
params(add: T.nilable(T::Hash[String, String]), remove: T.nilable(T::Array[String]), set: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), type: String).void
}
def initialize(add: nil, remove: nil, set: nil, type: nil); end
end
class SetPauseCollection < Stripe::RequestParams
class Set < Stripe::RequestParams
# The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`.
sig { returns(String) }
attr_accessor :behavior
sig { params(behavior: String).void }
def initialize(behavior: nil); end
end
# Details of the pause_collection behavior to apply to the amendment.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Amendment::SetPauseCollection::Set))
}
attr_accessor :set
# Determines the type of the pause_collection amendment.
sig { returns(String) }
attr_accessor :type
sig {
params(set: T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Amendment::SetPauseCollection::Set), type: String).void
}
def initialize(set: nil, type: nil); end
end
class TrialSettings < Stripe::RequestParams
class EndBehavior < Stripe::RequestParams
# Configure how an opt-in following a paid trial is billed when using `billing_behavior: prorate_up_front`.
sig { returns(T.nilable(String)) }
attr_accessor :prorate_up_front
sig { params(prorate_up_front: T.nilable(String)).void }
def initialize(prorate_up_front: nil); end
end
# Defines how the subscription should behave when a trial ends.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Amendment::TrialSettings::EndBehavior))
}
attr_accessor :end_behavior
sig {
params(end_behavior: T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Amendment::TrialSettings::EndBehavior)).void
}
def initialize(end_behavior: nil); end
end
# Details to identify the end of the time range modified by the proposed change. If not supplied, the amendment is considered a point-in-time operation that only affects the exact timestamp at `amendment_start`, and a restricted set of attributes is supported on the amendment.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Amendment::AmendmentEnd))
}
attr_accessor :amendment_end
# Details to identify the earliest timestamp where the proposed change should take effect.
sig { returns(::Stripe::SubscriptionSchedule::AmendParams::Amendment::AmendmentStart) }
attr_accessor :amendment_start
# For point-in-time amendments (having no `amendment_end`), this attribute lets you set or remove whether the subscription's billing cycle anchor is reset at the `amendment_start` timestamp.For time-span based amendments (having both `amendment_start` and `amendment_end`), the only value valid is `automatic`, which removes any previously configured billing cycle anchor resets scheduled to occur during the window of time spanned by the amendment.
sig { returns(T.nilable(String)) }
attr_accessor :billing_cycle_anchor
# Changes to the coupons being redeemed or discounts being applied during the amendment time span.
sig {
returns(T.nilable(T::Array[::Stripe::SubscriptionSchedule::AmendParams::Amendment::DiscountAction]))
}
attr_accessor :discount_actions
# Changes to the subscription items during the amendment time span.
sig {
returns(T.nilable(T::Array[::Stripe::SubscriptionSchedule::AmendParams::Amendment::ItemAction]))
}
attr_accessor :item_actions
# Instructions for how to modify phase metadata
sig {
returns(T.nilable(T::Array[::Stripe::SubscriptionSchedule::AmendParams::Amendment::MetadataAction]))
}
attr_accessor :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`.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
# Defines how to pause collection for the underlying subscription throughout the duration of the amendment.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Amendment::SetPauseCollection))
}
attr_accessor :set_pause_collection
# Ends the subscription schedule early as dictated by either the accompanying amendment's start or end.
sig { returns(T.nilable(String)) }
attr_accessor :set_schedule_end
# Settings related to subscription trials.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Amendment::TrialSettings))
}
attr_accessor :trial_settings
sig {
params(amendment_end: T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Amendment::AmendmentEnd), amendment_start: ::Stripe::SubscriptionSchedule::AmendParams::Amendment::AmendmentStart, billing_cycle_anchor: T.nilable(String), discount_actions: T.nilable(T::Array[::Stripe::SubscriptionSchedule::AmendParams::Amendment::DiscountAction]), item_actions: T.nilable(T::Array[::Stripe::SubscriptionSchedule::AmendParams::Amendment::ItemAction]), metadata_actions: T.nilable(T::Array[::Stripe::SubscriptionSchedule::AmendParams::Amendment::MetadataAction]), proration_behavior: T.nilable(String), set_pause_collection: T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Amendment::SetPauseCollection), set_schedule_end: T.nilable(String), trial_settings: T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Amendment::TrialSettings)).void
}
def initialize(
amendment_end: nil,
amendment_start: nil,
billing_cycle_anchor: nil,
discount_actions: nil,
item_actions: nil,
metadata_actions: nil,
proration_behavior: nil,
set_pause_collection: nil,
set_schedule_end: nil,
trial_settings: nil
); end
end
class Prebilling < Stripe::RequestParams
class BillFrom < Stripe::RequestParams
class AmendmentStart < Stripe::RequestParams
# The position of the amendment in the `amendments` array with which prebilling should begin. Indexes start from 0 and must be less than the total number of supplied amendments.
sig { returns(Integer) }
attr_accessor :index
sig { params(index: Integer).void }
def initialize(index: nil); end
end
# Start the prebilled period when a specified amendment begins.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Prebilling::BillFrom::AmendmentStart))
}
attr_accessor :amendment_start
# Start the prebilled period at a precise integer timestamp, starting from the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# Select one of several ways to pass the `bill_from` value.
sig { returns(String) }
attr_accessor :type
sig {
params(amendment_start: T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Prebilling::BillFrom::AmendmentStart), timestamp: T.nilable(Integer), type: String).void
}
def initialize(amendment_start: nil, timestamp: nil, type: nil); end
end
class BillUntil < Stripe::RequestParams
class AmendmentEnd < Stripe::RequestParams
# The position of the amendment in the `amendments` array at which prebilling should end. Indexes start from 0 and must be less than the total number of supplied amendments.
sig { returns(Integer) }
attr_accessor :index
sig { params(index: Integer).void }
def initialize(index: nil); end
end
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# End the prebilled period when a specified amendment ends.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Prebilling::BillUntil::AmendmentEnd))
}
attr_accessor :amendment_end
# Time span for prebilling, starting from `bill_from`.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Prebilling::BillUntil::Duration))
}
attr_accessor :duration
# End the prebilled period at a precise integer timestamp, starting from the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# Select one of several ways to pass the `bill_until` value.
sig { returns(String) }
attr_accessor :type
sig {
params(amendment_end: T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Prebilling::BillUntil::AmendmentEnd), duration: T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Prebilling::BillUntil::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(amendment_end: nil, duration: nil, timestamp: nil, type: nil); end
end
# The beginning of the prebilled time period. The default value is `now`.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Prebilling::BillFrom))
}
attr_accessor :bill_from
# The end of the prebilled time period.
sig {
returns(T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Prebilling::BillUntil))
}
attr_accessor :bill_until
# When the prebilling invoice should be created. The default value is `now`.
sig { returns(T.nilable(String)) }
attr_accessor :invoice_at
# Whether to cancel or preserve `prebilling` if the subscription is updated during the prebilled period. The default value is `reset`.
sig { returns(T.nilable(String)) }
attr_accessor :update_behavior
sig {
params(bill_from: T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Prebilling::BillFrom), bill_until: T.nilable(::Stripe::SubscriptionSchedule::AmendParams::Prebilling::BillUntil), invoice_at: T.nilable(String), update_behavior: T.nilable(String)).void
}
def initialize(bill_from: nil, bill_until: nil, invoice_at: nil, update_behavior: nil); end
end
class ScheduleSettings < Stripe::RequestParams
# Behavior of the subscription schedule and underlying subscription when it ends.
sig { returns(T.nilable(String)) }
attr_accessor :end_behavior
sig { params(end_behavior: T.nilable(String)).void }
def initialize(end_behavior: nil); end
end
# Changes to apply to the phases of the subscription schedule, in the order provided.
sig { returns(T.nilable(T::Array[::Stripe::SubscriptionSchedule::AmendParams::Amendment])) }
attr_accessor :amendments
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Provide any time periods to bill in advance.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::SubscriptionSchedule::AmendParams::Prebilling]))))
}
attr_accessor :prebilling
# In cases where the amendment changes the currently active phase,
# specifies if and how to prorate at the time of the request.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
# Changes to apply to the subscription schedule.
sig { returns(T.nilable(::Stripe::SubscriptionSchedule::AmendParams::ScheduleSettings)) }
attr_accessor :schedule_settings
sig {
params(amendments: T.nilable(T::Array[::Stripe::SubscriptionSchedule::AmendParams::Amendment]), expand: T.nilable(T::Array[String]), prebilling: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::SubscriptionSchedule::AmendParams::Prebilling]))), proration_behavior: T.nilable(String), schedule_settings: T.nilable(::Stripe::SubscriptionSchedule::AmendParams::ScheduleSettings)).void
}
def initialize(
amendments: nil,
expand: nil,
prebilling: nil,
proration_behavior: nil,
schedule_settings: nil
); end
end
class CancelParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# If the subscription schedule is `active`, indicates if a final invoice will be generated that contains any un-invoiced metered usage and new/pending proration invoice items. Defaults to `true`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :invoice_now
# If the subscription schedule is `active`, indicates if the cancellation should be prorated. Defaults to `true`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :prorate
sig {
params(expand: T.nilable(T::Array[String]), invoice_now: T.nilable(T::Boolean), prorate: T.nilable(T::Boolean)).void
}
def initialize(expand: nil, invoice_now: nil, prorate: nil); end
end
class ReleaseParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Keep any cancellation on the subscription that the schedule has set
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :preserve_cancel_date
sig {
params(expand: T.nilable(T::Array[String]), preserve_cancel_date: T.nilable(T::Boolean)).void
}
def initialize(expand: nil, preserve_cancel_date: nil); end
end
# Amends an existing subscription schedule.
sig {
params(params: T.any(::Stripe::SubscriptionSchedule::AmendParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SubscriptionSchedule)
}
def amend(params = {}, opts = {}); end
# Amends an existing subscription schedule.
sig {
params(schedule: String, params: T.any(::Stripe::SubscriptionSchedule::AmendParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SubscriptionSchedule)
}
def self.amend(schedule, params = {}, opts = {}); end
# Cancels a subscription schedule and its associated subscription immediately (if the subscription schedule has an active subscription). A subscription schedule can only be canceled if its status is not_started or active.
sig {
params(params: T.any(::Stripe::SubscriptionSchedule::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SubscriptionSchedule)
}
def cancel(params = {}, opts = {}); end
# Cancels a subscription schedule and its associated subscription immediately (if the subscription schedule has an active subscription). A subscription schedule can only be canceled if its status is not_started or active.
sig {
params(schedule: String, params: T.any(::Stripe::SubscriptionSchedule::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SubscriptionSchedule)
}
def self.cancel(schedule, params = {}, opts = {}); end
# Creates a new subscription schedule object. Each customer can have up to 500 active or scheduled subscriptions.
sig {
params(params: T.any(::Stripe::SubscriptionSchedule::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SubscriptionSchedule)
}
def self.create(params = {}, opts = {}); end
# Retrieves the list of your subscription schedules.
sig {
params(params: T.any(::Stripe::SubscriptionSchedule::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Releases the subscription schedule immediately, which will stop scheduling of its phases, but leave any existing subscription in place. A schedule can only be released if its status is not_started or active. If the subscription schedule is currently associated with a subscription, releasing it will remove its subscription property and set the subscription's ID to the released_subscription property.
sig {
params(params: T.any(::Stripe::SubscriptionSchedule::ReleaseParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SubscriptionSchedule)
}
def release(params = {}, opts = {}); end
# Releases the subscription schedule immediately, which will stop scheduling of its phases, but leave any existing subscription in place. A schedule can only be released if its status is not_started or active. If the subscription schedule is currently associated with a subscription, releasing it will remove its subscription property and set the subscription's ID to the released_subscription property.
sig {
params(schedule: String, params: T.any(::Stripe::SubscriptionSchedule::ReleaseParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SubscriptionSchedule)
}
def self.release(schedule, params = {}, opts = {}); end
# Updates an existing subscription schedule.
sig {
params(schedule: String, params: T.any(::Stripe::SubscriptionSchedule::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SubscriptionSchedule)
}
def self.update(schedule, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
module Tax
# A Tax Association exposes the Tax Transactions that Stripe attempted to create on your behalf based on the PaymentIntent input
class Association < APIResource
class TaxTransactionAttempt < Stripe::StripeObject
class Committed < Stripe::StripeObject
# The [Tax Transaction](https://stripe.com/docs/api/tax/transaction/object)
sig { returns(String) }
attr_reader :transaction
end
class Errored < Stripe::StripeObject
# Details on why we couldn't commit the tax transaction.
sig { returns(String) }
attr_reader :reason
end
# Attribute for field committed
sig { returns(Committed) }
attr_reader :committed
# Attribute for field errored
sig { returns(Errored) }
attr_reader :errored
# The source of the tax transaction attempt. This is either a refund or a payment intent.
sig { returns(String) }
attr_reader :source
# The status of the transaction attempt. This can be `errored` or `committed`.
sig { returns(String) }
attr_reader :status
end
# The [Tax Calculation](https://stripe.com/docs/api/tax/calculations/object) that was included in PaymentIntent.
sig { returns(String) }
attr_reader :calculation
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The [PaymentIntent](https://stripe.com/docs/api/payment_intents/object) that this Tax Association is tracking.
sig { returns(String) }
attr_reader :payment_intent
# Information about the tax transactions linked to this payment intent
sig { returns(T.nilable(T::Array[TaxTransactionAttempt])) }
attr_reader :tax_transaction_attempts
class FindParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Valid [PaymentIntent](https://stripe.com/docs/api/payment_intents/object) id
sig { returns(String) }
attr_accessor :payment_intent
sig { params(expand: T.nilable(T::Array[String]), payment_intent: String).void }
def initialize(expand: nil, payment_intent: nil); end
end
# Finds a tax association object by PaymentIntent id.
sig {
params(params: T.any(::Stripe::Tax::Association::FindParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Tax::Association)
}
def self.find(params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Tax
# A Tax Calculation allows you to calculate the tax to collect from your customer.
#
# Related guide: [Calculate tax in your custom payment flow](https://stripe.com/docs/tax/custom)
class Calculation < APIResource
class CustomerDetails < Stripe::StripeObject
class Address < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(String) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State/province as an [ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2) subdivision code, without country prefix. Example: "NY" or "TX".
sig { returns(T.nilable(String)) }
attr_reader :state
end
class TaxId < Stripe::StripeObject
# The type of the tax ID, one of `ad_nrt`, `ar_cuit`, `eu_vat`, `bo_tin`, `br_cnpj`, `br_cpf`, `cn_tin`, `co_nit`, `cr_tin`, `do_rcn`, `ec_ruc`, `eu_oss_vat`, `hr_oib`, `pe_ruc`, `ro_tin`, `rs_pib`, `sv_nit`, `uy_ruc`, `ve_rif`, `vn_tin`, `gb_vat`, `nz_gst`, `au_abn`, `au_arn`, `in_gst`, `no_vat`, `no_voec`, `za_vat`, `ch_vat`, `mx_rfc`, `sg_uen`, `ru_inn`, `ru_kpp`, `ca_bn`, `hk_br`, `es_cif`, `tw_vat`, `th_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `li_uid`, `li_vat`, `my_itn`, `us_ein`, `kr_brn`, `ca_qst`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `my_sst`, `sg_gst`, `ae_trn`, `cl_tin`, `sa_vat`, `id_npwp`, `my_frp`, `il_vat`, `ge_vat`, `ua_vat`, `is_vat`, `bg_uic`, `hu_tin`, `si_tin`, `ke_pin`, `tr_tin`, `eg_tin`, `ph_tin`, `al_tin`, `bh_vat`, `kz_bin`, `ng_tin`, `om_vat`, `de_stn`, `ch_uid`, `tz_vat`, `uz_vat`, `uz_tin`, `md_vat`, `ma_vat`, `by_tin`, `ao_tin`, `bs_tin`, `bb_tin`, `cd_nif`, `mr_nif`, `me_pib`, `zw_tin`, `ba_tin`, `gn_nif`, `mk_vat`, `sr_fin`, `sn_ninea`, `am_tin`, `np_pan`, `tj_tin`, `ug_tin`, `zm_tin`, `kh_tin`, `aw_tin`, `az_tin`, `bd_bin`, `bj_ifu`, `et_tin`, `kg_tin`, `la_tin`, `cm_niu`, `cv_nif`, `bf_ifu`, or `unknown`
sig { returns(String) }
attr_reader :type
# The value of the tax ID.
sig { returns(String) }
attr_reader :value
end
# The customer's postal address (for example, home or business location).
sig { returns(T.nilable(Address)) }
attr_reader :address
# The type of customer address provided.
sig { returns(T.nilable(String)) }
attr_reader :address_source
# The customer's IP address (IPv4 or IPv6).
sig { returns(T.nilable(String)) }
attr_reader :ip_address
# The customer's tax IDs (for example, EU VAT numbers).
sig { returns(T::Array[TaxId]) }
attr_reader :tax_ids
# The taxability override used for taxation.
sig { returns(String) }
attr_reader :taxability_override
end
class ShipFromDetails < Stripe::StripeObject
class Address < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(String) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State/province as an [ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2) subdivision code, without country prefix. Example: "NY" or "TX".
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Attribute for field address
sig { returns(Address) }
attr_reader :address
end
class ShippingCost < Stripe::StripeObject
class TaxBreakdown < Stripe::StripeObject
class Jurisdiction < Stripe::StripeObject
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(String) }
attr_reader :country
# A human-readable name for the jurisdiction imposing the tax.
sig { returns(String) }
attr_reader :display_name
# Indicates the level of the jurisdiction imposing the tax.
sig { returns(String) }
attr_reader :level
# [ISO 3166-2 subdivision code](https://en.wikipedia.org/wiki/ISO_3166-2), without country prefix. For example, "NY" for New York, United States.
sig { returns(T.nilable(String)) }
attr_reader :state
end
class TaxRateDetails < Stripe::StripeObject
# A localized display name for tax type, intended to be human-readable. For example, "Local Sales and Use Tax", "Value-added tax (VAT)", or "Umsatzsteuer (USt.)".
sig { returns(String) }
attr_reader :display_name
# The tax rate percentage as a string. For example, 8.5% is represented as "8.5".
sig { returns(String) }
attr_reader :percentage_decimal
# The tax type, such as `vat` or `sales_tax`.
sig { returns(String) }
attr_reader :tax_type
end
# The amount of tax, in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(Integer) }
attr_reader :amount
# Attribute for field jurisdiction
sig { returns(Jurisdiction) }
attr_reader :jurisdiction
# Indicates whether the jurisdiction was determined by the origin (merchant's address) or destination (customer's address).
sig { returns(String) }
attr_reader :sourcing
# Details regarding the rate for this tax. This field will be `null` when the tax is not imposed, for example if the product is exempt from tax.
sig { returns(T.nilable(TaxRateDetails)) }
attr_reader :tax_rate_details
# 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.
sig { returns(String) }
attr_reader :taxability_reason
# The amount on which tax is calculated, in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(Integer) }
attr_reader :taxable_amount
end
# The shipping amount in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal). If `tax_behavior=inclusive`, then this amount includes taxes. Otherwise, taxes were calculated on top of this amount.
sig { returns(Integer) }
attr_reader :amount
# The amount of tax calculated for shipping, in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(Integer) }
attr_reader :amount_tax
# The ID of an existing [ShippingRate](https://stripe.com/docs/api/shipping_rates/object).
sig { returns(String) }
attr_reader :shipping_rate
# Specifies whether the `amount` includes taxes. If `tax_behavior=inclusive`, then the amount includes taxes.
sig { returns(String) }
attr_reader :tax_behavior
# Detailed account of taxes relevant to shipping cost.
sig { returns(T::Array[TaxBreakdown]) }
attr_reader :tax_breakdown
# The [tax code](https://stripe.com/docs/tax/tax-categories) ID used for shipping.
sig { returns(String) }
attr_reader :tax_code
end
class TaxBreakdown < Stripe::StripeObject
class TaxRateDetails < Stripe::StripeObject
class FlatAmount < Stripe::StripeObject
# Amount of the tax when the `rate_type` is `flat_amount`. This positive integer represents how much to charge in the smallest currency unit (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99).
sig { returns(Integer) }
attr_reader :amount
# Three-letter ISO currency code, in lowercase.
sig { returns(String) }
attr_reader :currency
end
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# The amount of the tax rate when the `rate_type` is `flat_amount`. Tax rates with `rate_type` `percentage` can vary based on the transaction, resulting in this field being `null`. This field exposes the amount and currency of the flat tax rate.
sig { returns(T.nilable(FlatAmount)) }
attr_reader :flat_amount
# The tax rate percentage as a string. For example, 8.5% is represented as `"8.5"`.
sig { returns(String) }
attr_reader :percentage_decimal
# Indicates the type of tax rate applied to the taxable amount. This value can be `null` when no tax applies to the location. This field is only present for TaxRates created by Stripe Tax.
sig { returns(T.nilable(String)) }
attr_reader :rate_type
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
# The tax type, such as `vat` or `sales_tax`.
sig { returns(T.nilable(String)) }
attr_reader :tax_type
end
# The amount of tax, in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(Integer) }
attr_reader :amount
# Specifies whether the tax amount is included in the line item amount.
sig { returns(T::Boolean) }
attr_reader :inclusive
# Attribute for field tax_rate_details
sig { returns(TaxRateDetails) }
attr_reader :tax_rate_details
# The reasoning behind this tax, for example, if the product is tax exempt. We might extend the possible values for this field to support new tax rules.
sig { returns(String) }
attr_reader :taxability_reason
# The amount on which tax is calculated, in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(Integer) }
attr_reader :taxable_amount
end
# Total amount after taxes in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(Integer) }
attr_reader :amount_total
# 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).
sig { returns(String) }
attr_reader :currency
# The ID of an existing [Customer](https://stripe.com/docs/api/customers/object) used for the resource.
sig { returns(T.nilable(String)) }
attr_reader :customer
# Attribute for field customer_details
sig { returns(CustomerDetails) }
attr_reader :customer_details
# Timestamp of date at which the tax calculation will expire.
sig { returns(T.nilable(Integer)) }
attr_reader :expires_at
# Unique identifier for the calculation.
sig { returns(T.nilable(String)) }
attr_reader :id
# The list of items the customer is purchasing.
sig { returns(T.nilable(Stripe::ListObject)) }
attr_reader :line_items
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The details of the ship from location, such as the address.
sig { returns(T.nilable(ShipFromDetails)) }
attr_reader :ship_from_details
# The shipping cost details for the calculation.
sig { returns(T.nilable(ShippingCost)) }
attr_reader :shipping_cost
# The amount of tax to be collected on top of the line item prices.
sig { returns(Integer) }
attr_reader :tax_amount_exclusive
# The amount of tax already included in the line item prices.
sig { returns(Integer) }
attr_reader :tax_amount_inclusive
# Breakdown of individual tax amounts that add up to the total.
sig { returns(T::Array[TaxBreakdown]) }
attr_reader :tax_breakdown
# Timestamp of date at which the tax rules and rates in effect applies for the calculation.
sig { returns(Integer) }
attr_reader :tax_date
class ListLineItemsParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
class CreateParams < Stripe::RequestParams
class CustomerDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(String) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :postal_code
# State, county, province, or region. We recommend sending [ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2) subdivision code value when possible.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :state
sig {
params(city: T.nilable(T.nilable(String)), country: String, line1: T.nilable(T.nilable(String)), line2: T.nilable(T.nilable(String)), postal_code: T.nilable(T.nilable(String)), state: T.nilable(T.nilable(String))).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class TaxId < Stripe::RequestParams
# Type of the tax ID, one of `ad_nrt`, `ae_trn`, `al_tin`, `am_tin`, `ao_tin`, `ar_cuit`, `au_abn`, `au_arn`, `aw_tin`, `az_tin`, `ba_tin`, `bb_tin`, `bd_bin`, `bf_ifu`, `bg_uic`, `bh_vat`, `bj_ifu`, `bo_tin`, `br_cnpj`, `br_cpf`, `bs_tin`, `by_tin`, `ca_bn`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `ca_qst`, `cd_nif`, `ch_uid`, `ch_vat`, `cl_tin`, `cm_niu`, `cn_tin`, `co_nit`, `cr_tin`, `cv_nif`, `de_stn`, `do_rcn`, `ec_ruc`, `eg_tin`, `es_cif`, `et_tin`, `eu_oss_vat`, `eu_vat`, `gb_vat`, `ge_vat`, `gn_nif`, `hk_br`, `hr_oib`, `hu_tin`, `id_npwp`, `il_vat`, `in_gst`, `is_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `ke_pin`, `kg_tin`, `kh_tin`, `kr_brn`, `kz_bin`, `la_tin`, `li_uid`, `li_vat`, `ma_vat`, `md_vat`, `me_pib`, `mk_vat`, `mr_nif`, `mx_rfc`, `my_frp`, `my_itn`, `my_sst`, `ng_tin`, `no_vat`, `no_voec`, `np_pan`, `nz_gst`, `om_vat`, `pe_ruc`, `ph_tin`, `ro_tin`, `rs_pib`, `ru_inn`, `ru_kpp`, `sa_vat`, `sg_gst`, `sg_uen`, `si_tin`, `sn_ninea`, `sr_fin`, `sv_nit`, `th_vat`, `tj_tin`, `tr_tin`, `tw_vat`, `tz_vat`, `ua_vat`, `ug_tin`, `us_ein`, `uy_ruc`, `uz_tin`, `uz_vat`, `ve_rif`, `vn_tin`, `za_vat`, `zm_tin`, or `zw_tin`
sig { returns(String) }
attr_accessor :type
# Value of the tax ID.
sig { returns(String) }
attr_accessor :value
sig { params(type: String, value: String).void }
def initialize(type: nil, value: nil); end
end
# The customer's postal address (for example, home or business location).
sig {
returns(T.nilable(::Stripe::Tax::Calculation::CreateParams::CustomerDetails::Address))
}
attr_accessor :address
# The type of customer address provided.
sig { returns(T.nilable(String)) }
attr_accessor :address_source
# The customer's IP address (IPv4 or IPv6).
sig { returns(T.nilable(String)) }
attr_accessor :ip_address
# The customer's tax IDs. Stripe Tax might consider a transaction with applicable tax IDs to be B2B, which might affect the tax calculation result. Stripe Tax doesn't validate tax IDs for correctness.
sig {
returns(T.nilable(T::Array[::Stripe::Tax::Calculation::CreateParams::CustomerDetails::TaxId]))
}
attr_accessor :tax_ids
# Overrides the tax calculation result to allow you to not collect tax from your customer. Use this if you've manually checked your customer's tax exemptions. Prefer providing the customer's `tax_ids` where possible, which automatically determines whether `reverse_charge` applies.
sig { returns(T.nilable(String)) }
attr_accessor :taxability_override
sig {
params(address: T.nilable(::Stripe::Tax::Calculation::CreateParams::CustomerDetails::Address), address_source: T.nilable(String), ip_address: T.nilable(String), tax_ids: T.nilable(T::Array[::Stripe::Tax::Calculation::CreateParams::CustomerDetails::TaxId]), taxability_override: T.nilable(String)).void
}
def initialize(
address: nil,
address_source: nil,
ip_address: nil,
tax_ids: nil,
taxability_override: nil
); end
end
class LineItem < Stripe::RequestParams
# A positive integer representing the line item's total price in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
# If `tax_behavior=inclusive`, then this amount includes taxes. Otherwise, taxes are calculated on top of this amount.
sig { returns(Integer) }
attr_accessor :amount
# 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.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# If provided, the product's `tax_code` will be used as the line item's `tax_code`.
sig { returns(T.nilable(String)) }
attr_accessor :product
# The number of units of the item being purchased. Used to calculate the per-unit price from the total `amount` for the line. For example, if `amount=100` and `quantity=4`, the calculated unit price is 25.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# A custom identifier for this line item, which must be unique across the line items in the calculation. The reference helps identify each line item in exported [tax reports](https://stripe.com/docs/tax/reports).
sig { returns(T.nilable(String)) }
attr_accessor :reference
# Specifies whether the `amount` includes taxes. Defaults to `exclusive`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID to use for this line item. If not provided, we will use the tax code from the provided `product` param. If neither `tax_code` nor `product` is provided, we will use the default tax code from your Tax Settings.
sig { returns(T.nilable(String)) }
attr_accessor :tax_code
sig {
params(amount: Integer, metadata: T.nilable(T::Hash[String, String]), product: T.nilable(String), quantity: T.nilable(Integer), reference: T.nilable(String), tax_behavior: T.nilable(String), tax_code: T.nilable(String)).void
}
def initialize(
amount: nil,
metadata: nil,
product: nil,
quantity: nil,
reference: nil,
tax_behavior: nil,
tax_code: nil
); end
end
class ShipFromDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(String) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :postal_code
# State/province as an [ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2) subdivision code, without country prefix. Example: "NY" or "TX".
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :state
sig {
params(city: T.nilable(T.nilable(String)), country: String, line1: T.nilable(T.nilable(String)), line2: T.nilable(T.nilable(String)), postal_code: T.nilable(T.nilable(String)), state: T.nilable(T.nilable(String))).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# The address from which the goods are being shipped from.
sig { returns(::Stripe::Tax::Calculation::CreateParams::ShipFromDetails::Address) }
attr_accessor :address
sig {
params(address: ::Stripe::Tax::Calculation::CreateParams::ShipFromDetails::Address).void
}
def initialize(address: nil); end
end
class ShippingCost < Stripe::RequestParams
# A positive integer in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) representing the shipping charge. If `tax_behavior=inclusive`, then this amount includes taxes. Otherwise, taxes are calculated on top of this amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# If provided, the [shipping rate](https://stripe.com/docs/api/shipping_rates/object)'s `amount`, `tax_code` and `tax_behavior` are used. If you provide a shipping rate, then you cannot pass the `amount`, `tax_code`, or `tax_behavior` parameters.
sig { returns(T.nilable(String)) }
attr_accessor :shipping_rate
# Specifies whether the `amount` includes taxes. If `tax_behavior=inclusive`, then the amount includes taxes. Defaults to `exclusive`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# The [tax code](https://stripe.com/docs/tax/tax-categories) used to calculate tax on shipping. If not provided, the default shipping tax code from your [Tax Settings](https://dashboard.stripe.com/settings/tax) is used.
sig { returns(T.nilable(String)) }
attr_accessor :tax_code
sig {
params(amount: T.nilable(Integer), shipping_rate: T.nilable(String), tax_behavior: T.nilable(String), tax_code: T.nilable(String)).void
}
def initialize(amount: nil, shipping_rate: nil, tax_behavior: nil, tax_code: nil); end
end
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of an existing customer to use for this calculation. If provided, the customer's address and tax IDs are copied to `customer_details`.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# Details about the customer, including address and tax IDs.
sig { returns(T.nilable(::Stripe::Tax::Calculation::CreateParams::CustomerDetails)) }
attr_accessor :customer_details
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A list of items the customer is purchasing.
sig { returns(T::Array[::Stripe::Tax::Calculation::CreateParams::LineItem]) }
attr_accessor :line_items
# Details about the address from which the goods are being shipped.
sig { returns(T.nilable(::Stripe::Tax::Calculation::CreateParams::ShipFromDetails)) }
attr_accessor :ship_from_details
# Shipping cost details to be used for the calculation.
sig { returns(T.nilable(::Stripe::Tax::Calculation::CreateParams::ShippingCost)) }
attr_accessor :shipping_cost
# Timestamp of date at which the tax rules and rates in effect applies for the calculation. Measured in seconds since the Unix epoch. Can be up to 48 hours in the past, and up to 48 hours in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :tax_date
sig {
params(currency: String, customer: T.nilable(String), customer_details: T.nilable(::Stripe::Tax::Calculation::CreateParams::CustomerDetails), expand: T.nilable(T::Array[String]), line_items: T::Array[::Stripe::Tax::Calculation::CreateParams::LineItem], ship_from_details: T.nilable(::Stripe::Tax::Calculation::CreateParams::ShipFromDetails), shipping_cost: T.nilable(::Stripe::Tax::Calculation::CreateParams::ShippingCost), tax_date: T.nilable(Integer)).void
}
def initialize(
currency: nil,
customer: nil,
customer_details: nil,
expand: nil,
line_items: nil,
ship_from_details: nil,
shipping_cost: nil,
tax_date: nil
); end
end
# Calculates tax based on the input and returns a Tax Calculation object.
sig {
params(params: T.any(::Stripe::Tax::Calculation::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Tax::Calculation)
}
def self.create(params = {}, opts = {}); end
# Retrieves the line items of a tax calculation as a collection, if the calculation hasn't expired.
sig {
params(params: T.any(::Stripe::Tax::Calculation::ListLineItemsParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list_line_items(params = {}, opts = {}); end
# Retrieves the line items of a tax calculation as a collection, if the calculation hasn't expired.
sig {
params(calculation: String, params: T.any(::Stripe::Tax::Calculation::ListLineItemsParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list_line_items(calculation, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Tax
class CalculationLineItem < APIResource
class TaxBreakdown < Stripe::StripeObject
class Jurisdiction < Stripe::StripeObject
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(String) }
attr_reader :country
# A human-readable name for the jurisdiction imposing the tax.
sig { returns(String) }
attr_reader :display_name
# Indicates the level of the jurisdiction imposing the tax.
sig { returns(String) }
attr_reader :level
# [ISO 3166-2 subdivision code](https://en.wikipedia.org/wiki/ISO_3166-2), without country prefix. For example, "NY" for New York, United States.
sig { returns(T.nilable(String)) }
attr_reader :state
end
class TaxRateDetails < Stripe::StripeObject
# A localized display name for tax type, intended to be human-readable. For example, "Local Sales and Use Tax", "Value-added tax (VAT)", or "Umsatzsteuer (USt.)".
sig { returns(String) }
attr_reader :display_name
# The tax rate percentage as a string. For example, 8.5% is represented as "8.5".
sig { returns(String) }
attr_reader :percentage_decimal
# The tax type, such as `vat` or `sales_tax`.
sig { returns(String) }
attr_reader :tax_type
end
# The amount of tax, in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(Integer) }
attr_reader :amount
# Attribute for field jurisdiction
sig { returns(Jurisdiction) }
attr_reader :jurisdiction
# Indicates whether the jurisdiction was determined by the origin (merchant's address) or destination (customer's address).
sig { returns(String) }
attr_reader :sourcing
# Details regarding the rate for this tax. This field will be `null` when the tax is not imposed, for example if the product is exempt from tax.
sig { returns(T.nilable(TaxRateDetails)) }
attr_reader :tax_rate_details
# 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.
sig { returns(String) }
attr_reader :taxability_reason
# The amount on which tax is calculated, in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(Integer) }
attr_reader :taxable_amount
end
# The line item amount in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal). If `tax_behavior=inclusive`, then this amount includes taxes. Otherwise, taxes were calculated on top of this amount.
sig { returns(Integer) }
attr_reader :amount
# The amount of tax calculated for this line item, in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(Integer) }
attr_reader :amount_tax
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# 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.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The ID of an existing [Product](https://stripe.com/docs/api/products/object).
sig { returns(T.nilable(String)) }
attr_reader :product
# The number of units of the item being purchased. For reversals, this is the quantity reversed.
sig { returns(Integer) }
attr_reader :quantity
# A custom identifier for this line item.
sig { returns(String) }
attr_reader :reference
# Specifies whether the `amount` includes taxes. If `tax_behavior=inclusive`, then the amount includes taxes.
sig { returns(String) }
attr_reader :tax_behavior
# Detailed account of taxes relevant to this line item.
sig { returns(T.nilable(T::Array[TaxBreakdown])) }
attr_reader :tax_breakdown
# The [tax code](https://stripe.com/docs/tax/tax-categories) ID used for this resource.
sig { returns(String) }
attr_reader :tax_code
end
end
end
# typed: true
module Stripe
module Tax
# Tax forms are legal documents which are delivered to one or more tax authorities for information reporting purposes.
#
# Related guide: [US tax reporting for Connect platforms](https://stripe.com/docs/connect/tax-reporting)
class Form < APIResource
class AuSerr < Stripe::StripeObject
# End date of the period represented by the information reported on the tax form.
sig { returns(String) }
attr_reader :reporting_period_end_date
# Start date of the period represented by the information reported on the tax form.
sig { returns(String) }
attr_reader :reporting_period_start_date
end
class CaMrdp < Stripe::StripeObject
# End date of the period represented by the information reported on the tax form.
sig { returns(String) }
attr_reader :reporting_period_end_date
# Start date of the period represented by the information reported on the tax form.
sig { returns(String) }
attr_reader :reporting_period_start_date
end
class EuDac7 < Stripe::StripeObject
# End date of the period represented by the information reported on the tax form.
sig { returns(String) }
attr_reader :reporting_period_end_date
# Start date of the period represented by the information reported on the tax form.
sig { returns(String) }
attr_reader :reporting_period_start_date
end
class FilingStatus < Stripe::StripeObject
class Jurisdiction < Stripe::StripeObject
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(String) }
attr_reader :country
# Indicates the level of the jurisdiction where the form was filed.
sig { returns(String) }
attr_reader :level
# [ISO 3166-2 U.S. state code](https://en.wikipedia.org/wiki/ISO_3166-2:US), without country prefix, if any. For example, "NY" for New York, United States. Null for non-U.S. forms.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Time when the filing status was updated.
sig { returns(Integer) }
attr_reader :effective_at
# Attribute for field jurisdiction
sig { returns(Jurisdiction) }
attr_reader :jurisdiction
# The current status of the filed form.
sig { returns(String) }
attr_reader :value
end
class GbMrdp < Stripe::StripeObject
# End date of the period represented by the information reported on the tax form.
sig { returns(String) }
attr_reader :reporting_period_end_date
# Start date of the period represented by the information reported on the tax form.
sig { returns(String) }
attr_reader :reporting_period_start_date
end
class NzMrdp < Stripe::StripeObject
# End date of the period represented by the information reported on the tax form.
sig { returns(String) }
attr_reader :reporting_period_end_date
# Start date of the period represented by the information reported on the tax form.
sig { returns(String) }
attr_reader :reporting_period_start_date
end
class Payee < Stripe::StripeObject
# The ID of the payee's Stripe account.
sig { returns(T.nilable(T.any(String, Stripe::Account))) }
attr_reader :account
# The external reference to this payee.
sig { returns(T.nilable(String)) }
attr_reader :external_reference
# Either `account` or `external_reference`.
sig { returns(String) }
attr_reader :type
end
class Us1099K < Stripe::StripeObject
# Year represented by the information reported on the tax form.
sig { returns(Integer) }
attr_reader :reporting_year
end
class Us1099Misc < Stripe::StripeObject
# Year represented by the information reported on the tax form.
sig { returns(Integer) }
attr_reader :reporting_year
end
class Us1099Nec < Stripe::StripeObject
# Year represented by the information reported on the tax form.
sig { returns(Integer) }
attr_reader :reporting_year
end
# Attribute for field au_serr
sig { returns(AuSerr) }
attr_reader :au_serr
# Attribute for field ca_mrdp
sig { returns(CaMrdp) }
attr_reader :ca_mrdp
# The form that corrects this form, if any.
sig { returns(T.nilable(T.any(String, Stripe::Tax::Form))) }
attr_reader :corrected_by
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# Attribute for field eu_dac7
sig { returns(EuDac7) }
attr_reader :eu_dac7
# A list of tax filing statuses. Note that a filing status will only be included if the form has been filed directly with the jurisdiction’s tax authority.
sig { returns(T::Array[FilingStatus]) }
attr_reader :filing_statuses
# Attribute for field gb_mrdp
sig { returns(GbMrdp) }
attr_reader :gb_mrdp
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# Attribute for field nz_mrdp
sig { returns(NzMrdp) }
attr_reader :nz_mrdp
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Attribute for field payee
sig { returns(Payee) }
attr_reader :payee
# The type of the tax form. An additional hash is included on the tax form with a name matching this value. It contains additional information specific to the tax form type.
sig { returns(String) }
attr_reader :type
# Attribute for field us_1099_k
sig { returns(Us1099K) }
attr_reader :us_1099_k
# Attribute for field us_1099_misc
sig { returns(Us1099Misc) }
attr_reader :us_1099_misc
# Attribute for field us_1099_nec
sig { returns(Us1099Nec) }
attr_reader :us_1099_nec
class ListParams < Stripe::RequestParams
class Payee < Stripe::RequestParams
# The ID of the Stripe account whose forms will be retrieved.
sig { returns(T.nilable(String)) }
attr_accessor :account
# The external reference to the payee whose forms will be retrieved.
sig { returns(T.nilable(String)) }
attr_accessor :external_reference
# Specifies the payee type. Either `account` or `external_reference`.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(account: T.nilable(String), external_reference: T.nilable(String), type: T.nilable(String)).void
}
def initialize(account: nil, external_reference: nil, type: nil); end
end
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# The payee whose volume is represented on the tax form.
sig { returns(::Stripe::Tax::Form::ListParams::Payee) }
attr_accessor :payee
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# An optional filter on the list, based on the object `type` field. Without the filter, the list includes all current and future tax form types. If your integration expects only one type of tax form in the response, make sure to provide a type value in the request.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), payee: ::Stripe::Tax::Form::ListParams::Payee, starting_after: T.nilable(String), type: T.nilable(String)).void
}
def initialize(
ending_before: nil,
expand: nil,
limit: nil,
payee: nil,
starting_after: nil,
type: nil
); end
end
class PdfParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Returns a list of tax forms which were previously created. The tax forms are returned in sorted order, with the oldest tax forms appearing first.
sig {
params(params: T.any(::Stripe::Tax::Form::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Download the PDF for a tax form.
sig {
params(params: T.any(::Stripe::Tax::Form::PdfParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped, read_body_chunk_block: T.untyped).returns(T.untyped)
}
def pdf(params = {}, opts = {}, &read_body_chunk_block); end
# Download the PDF for a tax form.
sig {
params(id: String, params: T.any(::Stripe::Tax::Form::PdfParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped, read_body_chunk_block: T.untyped).returns(T.untyped)
}
def self.pdf(id, params = {}, opts = {}, &read_body_chunk_block); end
end
end
end
# typed: true
module Stripe
module Tax
# A Tax `Registration` lets us know that your business is registered to collect tax on payments within a region, enabling you to [automatically collect tax](https://stripe.com/docs/tax).
#
# Stripe doesn't register on your behalf with the relevant authorities when you create a Tax `Registration` object. For more information on how to register to collect tax, see [our guide](https://stripe.com/docs/tax/registering).
#
# Related guide: [Using the Registrations API](https://stripe.com/docs/tax/registrations-api)
class Registration < APIResource
class CountryOptions < Stripe::StripeObject
class Ae < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Al < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Am < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Ao < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class At < Stripe::StripeObject
class Standard < Stripe::StripeObject
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_reader :place_of_supply_scheme
end
# Attribute for field standard
sig { returns(Standard) }
attr_reader :standard
# Type of registration in an EU country.
sig { returns(String) }
attr_reader :type
end
class Au < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Aw < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Az < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Ba < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Bb < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Bd < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Be < Stripe::StripeObject
class Standard < Stripe::StripeObject
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_reader :place_of_supply_scheme
end
# Attribute for field standard
sig { returns(Standard) }
attr_reader :standard
# Type of registration in an EU country.
sig { returns(String) }
attr_reader :type
end
class Bf < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Bg < Stripe::StripeObject
class Standard < Stripe::StripeObject
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_reader :place_of_supply_scheme
end
# Attribute for field standard
sig { returns(Standard) }
attr_reader :standard
# Type of registration in an EU country.
sig { returns(String) }
attr_reader :type
end
class Bh < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Bj < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Bs < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class By < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Ca < Stripe::StripeObject
class ProvinceStandard < Stripe::StripeObject
# Two-letter CA province code ([ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2)).
sig { returns(String) }
attr_reader :province
end
# Attribute for field province_standard
sig { returns(ProvinceStandard) }
attr_reader :province_standard
# Type of registration in Canada.
sig { returns(String) }
attr_reader :type
end
class Cd < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Ch < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Cl < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Cm < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Co < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Cr < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Cv < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Cy < Stripe::StripeObject
class Standard < Stripe::StripeObject
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_reader :place_of_supply_scheme
end
# Attribute for field standard
sig { returns(Standard) }
attr_reader :standard
# Type of registration in an EU country.
sig { returns(String) }
attr_reader :type
end
class Cz < Stripe::StripeObject
class Standard < Stripe::StripeObject
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_reader :place_of_supply_scheme
end
# Attribute for field standard
sig { returns(Standard) }
attr_reader :standard
# Type of registration in an EU country.
sig { returns(String) }
attr_reader :type
end
class De < Stripe::StripeObject
class Standard < Stripe::StripeObject
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_reader :place_of_supply_scheme
end
# Attribute for field standard
sig { returns(Standard) }
attr_reader :standard
# Type of registration in an EU country.
sig { returns(String) }
attr_reader :type
end
class Dk < Stripe::StripeObject
class Standard < Stripe::StripeObject
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_reader :place_of_supply_scheme
end
# Attribute for field standard
sig { returns(Standard) }
attr_reader :standard
# Type of registration in an EU country.
sig { returns(String) }
attr_reader :type
end
class Ec < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Ee < Stripe::StripeObject
class Standard < Stripe::StripeObject
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_reader :place_of_supply_scheme
end
# Attribute for field standard
sig { returns(Standard) }
attr_reader :standard
# Type of registration in an EU country.
sig { returns(String) }
attr_reader :type
end
class Eg < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Es < Stripe::StripeObject
class Standard < Stripe::StripeObject
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_reader :place_of_supply_scheme
end
# Attribute for field standard
sig { returns(Standard) }
attr_reader :standard
# Type of registration in an EU country.
sig { returns(String) }
attr_reader :type
end
class Et < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Fi < Stripe::StripeObject
class Standard < Stripe::StripeObject
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_reader :place_of_supply_scheme
end
# Attribute for field standard
sig { returns(Standard) }
attr_reader :standard
# Type of registration in an EU country.
sig { returns(String) }
attr_reader :type
end
class Fr < Stripe::StripeObject
class Standard < Stripe::StripeObject
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_reader :place_of_supply_scheme
end
# Attribute for field standard
sig { returns(Standard) }
attr_reader :standard
# Type of registration in an EU country.
sig { returns(String) }
attr_reader :type
end
class Gb < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Ge < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Gn < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Gr < Stripe::StripeObject
class Standard < Stripe::StripeObject
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_reader :place_of_supply_scheme
end
# Attribute for field standard
sig { returns(Standard) }
attr_reader :standard
# Type of registration in an EU country.
sig { returns(String) }
attr_reader :type
end
class Hr < Stripe::StripeObject
class Standard < Stripe::StripeObject
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_reader :place_of_supply_scheme
end
# Attribute for field standard
sig { returns(Standard) }
attr_reader :standard
# Type of registration in an EU country.
sig { returns(String) }
attr_reader :type
end
class Hu < Stripe::StripeObject
class Standard < Stripe::StripeObject
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_reader :place_of_supply_scheme
end
# Attribute for field standard
sig { returns(Standard) }
attr_reader :standard
# Type of registration in an EU country.
sig { returns(String) }
attr_reader :type
end
class Id < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Ie < Stripe::StripeObject
class Standard < Stripe::StripeObject
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_reader :place_of_supply_scheme
end
# Attribute for field standard
sig { returns(Standard) }
attr_reader :standard
# Type of registration in an EU country.
sig { returns(String) }
attr_reader :type
end
class In < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Is < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class It < Stripe::StripeObject
class Standard < Stripe::StripeObject
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_reader :place_of_supply_scheme
end
# Attribute for field standard
sig { returns(Standard) }
attr_reader :standard
# Type of registration in an EU country.
sig { returns(String) }
attr_reader :type
end
class Jp < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Ke < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Kg < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Kh < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Kr < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Kz < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class La < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Lt < Stripe::StripeObject
class Standard < Stripe::StripeObject
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_reader :place_of_supply_scheme
end
# Attribute for field standard
sig { returns(Standard) }
attr_reader :standard
# Type of registration in an EU country.
sig { returns(String) }
attr_reader :type
end
class Lu < Stripe::StripeObject
class Standard < Stripe::StripeObject
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_reader :place_of_supply_scheme
end
# Attribute for field standard
sig { returns(Standard) }
attr_reader :standard
# Type of registration in an EU country.
sig { returns(String) }
attr_reader :type
end
class Lv < Stripe::StripeObject
class Standard < Stripe::StripeObject
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_reader :place_of_supply_scheme
end
# Attribute for field standard
sig { returns(Standard) }
attr_reader :standard
# Type of registration in an EU country.
sig { returns(String) }
attr_reader :type
end
class Ma < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Md < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Me < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Mk < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Mr < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Mt < Stripe::StripeObject
class Standard < Stripe::StripeObject
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_reader :place_of_supply_scheme
end
# Attribute for field standard
sig { returns(Standard) }
attr_reader :standard
# Type of registration in an EU country.
sig { returns(String) }
attr_reader :type
end
class Mx < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class My < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Ng < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Nl < Stripe::StripeObject
class Standard < Stripe::StripeObject
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_reader :place_of_supply_scheme
end
# Attribute for field standard
sig { returns(Standard) }
attr_reader :standard
# Type of registration in an EU country.
sig { returns(String) }
attr_reader :type
end
class No < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Np < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Nz < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Om < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Pe < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Ph < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Pl < Stripe::StripeObject
class Standard < Stripe::StripeObject
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_reader :place_of_supply_scheme
end
# Attribute for field standard
sig { returns(Standard) }
attr_reader :standard
# Type of registration in an EU country.
sig { returns(String) }
attr_reader :type
end
class Pt < Stripe::StripeObject
class Standard < Stripe::StripeObject
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_reader :place_of_supply_scheme
end
# Attribute for field standard
sig { returns(Standard) }
attr_reader :standard
# Type of registration in an EU country.
sig { returns(String) }
attr_reader :type
end
class Ro < Stripe::StripeObject
class Standard < Stripe::StripeObject
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_reader :place_of_supply_scheme
end
# Attribute for field standard
sig { returns(Standard) }
attr_reader :standard
# Type of registration in an EU country.
sig { returns(String) }
attr_reader :type
end
class Rs < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Ru < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Sa < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Se < Stripe::StripeObject
class Standard < Stripe::StripeObject
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_reader :place_of_supply_scheme
end
# Attribute for field standard
sig { returns(Standard) }
attr_reader :standard
# Type of registration in an EU country.
sig { returns(String) }
attr_reader :type
end
class Sg < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Si < Stripe::StripeObject
class Standard < Stripe::StripeObject
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_reader :place_of_supply_scheme
end
# Attribute for field standard
sig { returns(Standard) }
attr_reader :standard
# Type of registration in an EU country.
sig { returns(String) }
attr_reader :type
end
class Sk < Stripe::StripeObject
class Standard < Stripe::StripeObject
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_reader :place_of_supply_scheme
end
# Attribute for field standard
sig { returns(Standard) }
attr_reader :standard
# Type of registration in an EU country.
sig { returns(String) }
attr_reader :type
end
class Sn < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Sr < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Th < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Tj < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Tr < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Tz < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Ug < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Us < Stripe::StripeObject
class LocalAmusementTax < Stripe::StripeObject
# A [FIPS code](https://www.census.gov/library/reference/code-lists/ansi.html) representing the local jurisdiction.
sig { returns(String) }
attr_reader :jurisdiction
end
class LocalLeaseTax < Stripe::StripeObject
# A [FIPS code](https://www.census.gov/library/reference/code-lists/ansi.html) representing the local jurisdiction.
sig { returns(String) }
attr_reader :jurisdiction
end
class StateSalesTax < Stripe::StripeObject
class Election < Stripe::StripeObject
# A [FIPS code](https://www.census.gov/library/reference/code-lists/ansi.html) representing the local jurisdiction.
sig { returns(String) }
attr_reader :jurisdiction
# The type of the election for the state sales tax registration.
sig { returns(String) }
attr_reader :type
end
# Elections for the state sales tax registration.
sig { returns(T::Array[Election]) }
attr_reader :elections
end
# Attribute for field local_amusement_tax
sig { returns(LocalAmusementTax) }
attr_reader :local_amusement_tax
# Attribute for field local_lease_tax
sig { returns(LocalLeaseTax) }
attr_reader :local_lease_tax
# Two-letter US state code ([ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2)).
sig { returns(String) }
attr_reader :state
# Attribute for field state_sales_tax
sig { returns(StateSalesTax) }
attr_reader :state_sales_tax
# Type of registration in the US.
sig { returns(String) }
attr_reader :type
end
class Uy < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Uz < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Vn < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Za < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Zm < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
class Zw < Stripe::StripeObject
# Type of registration in `country`.
sig { returns(String) }
attr_reader :type
end
# Attribute for field ae
sig { returns(Ae) }
attr_reader :ae
# Attribute for field al
sig { returns(Al) }
attr_reader :al
# Attribute for field am
sig { returns(Am) }
attr_reader :am
# Attribute for field ao
sig { returns(Ao) }
attr_reader :ao
# Attribute for field at
sig { returns(At) }
attr_reader :at
# Attribute for field au
sig { returns(Au) }
attr_reader :au
# Attribute for field aw
sig { returns(Aw) }
attr_reader :aw
# Attribute for field az
sig { returns(Az) }
attr_reader :az
# Attribute for field ba
sig { returns(Ba) }
attr_reader :ba
# Attribute for field bb
sig { returns(Bb) }
attr_reader :bb
# Attribute for field bd
sig { returns(Bd) }
attr_reader :bd
# Attribute for field be
sig { returns(Be) }
attr_reader :be
# Attribute for field bf
sig { returns(Bf) }
attr_reader :bf
# Attribute for field bg
sig { returns(Bg) }
attr_reader :bg
# Attribute for field bh
sig { returns(Bh) }
attr_reader :bh
# Attribute for field bj
sig { returns(Bj) }
attr_reader :bj
# Attribute for field bs
sig { returns(Bs) }
attr_reader :bs
# Attribute for field by
sig { returns(By) }
attr_reader :by
# Attribute for field ca
sig { returns(Ca) }
attr_reader :ca
# Attribute for field cd
sig { returns(Cd) }
attr_reader :cd
# Attribute for field ch
sig { returns(Ch) }
attr_reader :ch
# Attribute for field cl
sig { returns(Cl) }
attr_reader :cl
# Attribute for field cm
sig { returns(Cm) }
attr_reader :cm
# Attribute for field co
sig { returns(Co) }
attr_reader :co
# Attribute for field cr
sig { returns(Cr) }
attr_reader :cr
# Attribute for field cv
sig { returns(Cv) }
attr_reader :cv
# Attribute for field cy
sig { returns(Cy) }
attr_reader :cy
# Attribute for field cz
sig { returns(Cz) }
attr_reader :cz
# Attribute for field de
sig { returns(De) }
attr_reader :de
# Attribute for field dk
sig { returns(Dk) }
attr_reader :dk
# Attribute for field ec
sig { returns(Ec) }
attr_reader :ec
# Attribute for field ee
sig { returns(Ee) }
attr_reader :ee
# Attribute for field eg
sig { returns(Eg) }
attr_reader :eg
# Attribute for field es
sig { returns(Es) }
attr_reader :es
# Attribute for field et
sig { returns(Et) }
attr_reader :et
# Attribute for field fi
sig { returns(Fi) }
attr_reader :fi
# Attribute for field fr
sig { returns(Fr) }
attr_reader :fr
# Attribute for field gb
sig { returns(Gb) }
attr_reader :gb
# Attribute for field ge
sig { returns(Ge) }
attr_reader :ge
# Attribute for field gn
sig { returns(Gn) }
attr_reader :gn
# Attribute for field gr
sig { returns(Gr) }
attr_reader :gr
# Attribute for field hr
sig { returns(Hr) }
attr_reader :hr
# Attribute for field hu
sig { returns(Hu) }
attr_reader :hu
# Attribute for field id
sig { returns(Id) }
attr_reader :id
# Attribute for field ie
sig { returns(Ie) }
attr_reader :ie
# Attribute for field in
sig { returns(In) }
attr_reader :in
# Attribute for field is
sig { returns(Is) }
attr_reader :is
# Attribute for field it
sig { returns(It) }
attr_reader :it
# Attribute for field jp
sig { returns(Jp) }
attr_reader :jp
# Attribute for field ke
sig { returns(Ke) }
attr_reader :ke
# Attribute for field kg
sig { returns(Kg) }
attr_reader :kg
# Attribute for field kh
sig { returns(Kh) }
attr_reader :kh
# Attribute for field kr
sig { returns(Kr) }
attr_reader :kr
# Attribute for field kz
sig { returns(Kz) }
attr_reader :kz
# Attribute for field la
sig { returns(La) }
attr_reader :la
# Attribute for field lt
sig { returns(Lt) }
attr_reader :lt
# Attribute for field lu
sig { returns(Lu) }
attr_reader :lu
# Attribute for field lv
sig { returns(Lv) }
attr_reader :lv
# Attribute for field ma
sig { returns(Ma) }
attr_reader :ma
# Attribute for field md
sig { returns(Md) }
attr_reader :md
# Attribute for field me
sig { returns(Me) }
attr_reader :me
# Attribute for field mk
sig { returns(Mk) }
attr_reader :mk
# Attribute for field mr
sig { returns(Mr) }
attr_reader :mr
# Attribute for field mt
sig { returns(Mt) }
attr_reader :mt
# Attribute for field mx
sig { returns(Mx) }
attr_reader :mx
# Attribute for field my
sig { returns(My) }
attr_reader :my
# Attribute for field ng
sig { returns(Ng) }
attr_reader :ng
# Attribute for field nl
sig { returns(Nl) }
attr_reader :nl
# Attribute for field no
sig { returns(No) }
attr_reader :no
# Attribute for field np
sig { returns(Np) }
attr_reader :np
# Attribute for field nz
sig { returns(Nz) }
attr_reader :nz
# Attribute for field om
sig { returns(Om) }
attr_reader :om
# Attribute for field pe
sig { returns(Pe) }
attr_reader :pe
# Attribute for field ph
sig { returns(Ph) }
attr_reader :ph
# Attribute for field pl
sig { returns(Pl) }
attr_reader :pl
# Attribute for field pt
sig { returns(Pt) }
attr_reader :pt
# Attribute for field ro
sig { returns(Ro) }
attr_reader :ro
# Attribute for field rs
sig { returns(Rs) }
attr_reader :rs
# Attribute for field ru
sig { returns(Ru) }
attr_reader :ru
# Attribute for field sa
sig { returns(Sa) }
attr_reader :sa
# Attribute for field se
sig { returns(Se) }
attr_reader :se
# Attribute for field sg
sig { returns(Sg) }
attr_reader :sg
# Attribute for field si
sig { returns(Si) }
attr_reader :si
# Attribute for field sk
sig { returns(Sk) }
attr_reader :sk
# Attribute for field sn
sig { returns(Sn) }
attr_reader :sn
# Attribute for field sr
sig { returns(Sr) }
attr_reader :sr
# Attribute for field th
sig { returns(Th) }
attr_reader :th
# Attribute for field tj
sig { returns(Tj) }
attr_reader :tj
# Attribute for field tr
sig { returns(Tr) }
attr_reader :tr
# Attribute for field tz
sig { returns(Tz) }
attr_reader :tz
# Attribute for field ug
sig { returns(Ug) }
attr_reader :ug
# Attribute for field us
sig { returns(Us) }
attr_reader :us
# Attribute for field uy
sig { returns(Uy) }
attr_reader :uy
# Attribute for field uz
sig { returns(Uz) }
attr_reader :uz
# Attribute for field vn
sig { returns(Vn) }
attr_reader :vn
# Attribute for field za
sig { returns(Za) }
attr_reader :za
# Attribute for field zm
sig { returns(Zm) }
attr_reader :zm
# Attribute for field zw
sig { returns(Zw) }
attr_reader :zw
end
# Time at which the registration becomes active. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :active_from
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(String) }
attr_reader :country
# Attribute for field country_options
sig { returns(CountryOptions) }
attr_reader :country_options
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# If set, the registration stops being active at this time. If not set, the registration will be active indefinitely. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_reader :expires_at
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The status of the registration. This field is present for convenience and can be deduced from `active_from` and `expires_at`.
sig { returns(String) }
attr_reader :status
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# The status of the Tax Registration.
sig { returns(T.nilable(String)) }
attr_accessor :status
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String), status: T.nilable(String)).void
}
def initialize(
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil,
status: nil
); end
end
class CreateParams < Stripe::RequestParams
class CountryOptions < Stripe::RequestParams
class Ae < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Al < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Am < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Ao < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class At < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::At::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::At::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Au < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Aw < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Az < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Ba < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Bb < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Bd < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Be < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Be::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Be::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Bf < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Bg < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Bg::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Bg::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Bh < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Bj < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Bs < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class By < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Ca < Stripe::RequestParams
class ProvinceStandard < Stripe::RequestParams
# Two-letter CA province code ([ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2)).
sig { returns(String) }
attr_accessor :province
sig { params(province: String).void }
def initialize(province: nil); end
end
# Options for the provincial tax registration.
sig {
returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Ca::ProvinceStandard))
}
attr_accessor :province_standard
# Type of registration to be created in Canada.
sig { returns(String) }
attr_accessor :type
sig {
params(province_standard: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Ca::ProvinceStandard), type: String).void
}
def initialize(province_standard: nil, type: nil); end
end
class Cd < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Ch < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Cl < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Cm < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Co < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Cr < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Cv < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Cy < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Cy::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Cy::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Cz < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Cz::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Cz::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class De < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::De::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::De::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Dk < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Dk::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Dk::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Ec < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Ee < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Ee::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Ee::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Eg < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Es < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Es::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Es::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Et < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Fi < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Fi::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Fi::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Fr < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Fr::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Fr::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Gb < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Ge < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Gn < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Gr < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Gr::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Gr::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Hr < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Hr::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Hr::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Hu < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Hu::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Hu::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Id < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Ie < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Ie::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Ie::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class In < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Is < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class It < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::It::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::It::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Jp < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Ke < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Kg < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Kh < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Kr < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Kz < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class La < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Lt < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Lt::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Lt::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Lu < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Lu::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Lu::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Lv < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Lv::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Lv::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Ma < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Md < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Me < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Mk < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Mr < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Mt < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Mt::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Mt::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Mx < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class My < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Ng < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Nl < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Nl::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Nl::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class No < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Np < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Nz < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Om < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Pe < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Ph < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Pl < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Pl::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Pl::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Pt < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Pt::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Pt::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Ro < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Ro::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Ro::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Rs < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Ru < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Sa < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Se < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Se::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Se::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Sg < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Si < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Si::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Si::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Sk < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Sk::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Sk::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Sn < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Sr < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Th < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Tj < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Tr < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Tz < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Ug < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Us < Stripe::RequestParams
class LocalAmusementTax < Stripe::RequestParams
# A [FIPS code](https://www.census.gov/library/reference/code-lists/ansi.html) representing the local jurisdiction. Supported FIPS codes are: `14000` (Chicago), `06613` (Bloomington), `21696` (East Dundee), `24582` (Evanston), `45421` (Lynwood), `48892` (Midlothian), `64343` (River Grove), and `68081` (Schiller Park).
sig { returns(String) }
attr_accessor :jurisdiction
sig { params(jurisdiction: String).void }
def initialize(jurisdiction: nil); end
end
class LocalLeaseTax < Stripe::RequestParams
# A [FIPS code](https://www.census.gov/library/reference/code-lists/ansi.html) representing the local jurisdiction. Supported FIPS codes are: `14000` (Chicago).
sig { returns(String) }
attr_accessor :jurisdiction
sig { params(jurisdiction: String).void }
def initialize(jurisdiction: nil); end
end
class StateSalesTax < Stripe::RequestParams
class Election < Stripe::RequestParams
# A [FIPS code](https://www.census.gov/library/reference/code-lists/ansi.html) representing the local jurisdiction. Supported FIPS codes are: `003` (Allegheny County) and `60000` (Philadelphia City).
sig { returns(T.nilable(String)) }
attr_accessor :jurisdiction
# The type of the election for the state sales tax registration.
sig { returns(String) }
attr_accessor :type
sig { params(jurisdiction: T.nilable(String), type: String).void }
def initialize(jurisdiction: nil, type: nil); end
end
# Elections for the state sales tax registration.
sig {
returns(T::Array[::Stripe::Tax::Registration::CreateParams::CountryOptions::Us::StateSalesTax::Election])
}
attr_accessor :elections
sig {
params(elections: T::Array[::Stripe::Tax::Registration::CreateParams::CountryOptions::Us::StateSalesTax::Election]).void
}
def initialize(elections: nil); end
end
# Options for the local amusement tax registration.
sig {
returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Us::LocalAmusementTax))
}
attr_accessor :local_amusement_tax
# Options for the local lease tax registration.
sig {
returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Us::LocalLeaseTax))
}
attr_accessor :local_lease_tax
# Two-letter US state code ([ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2)).
sig { returns(String) }
attr_accessor :state
# Options for the state sales tax registration.
sig {
returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Us::StateSalesTax))
}
attr_accessor :state_sales_tax
# Type of registration to be created in the US.
sig { returns(String) }
attr_accessor :type
sig {
params(local_amusement_tax: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Us::LocalAmusementTax), local_lease_tax: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Us::LocalLeaseTax), state: String, state_sales_tax: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Us::StateSalesTax), type: String).void
}
def initialize(
local_amusement_tax: nil,
local_lease_tax: nil,
state: nil,
state_sales_tax: nil,
type: nil
); end
end
class Uy < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Uz < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Vn < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Za < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Zm < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Zw < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
# Options for the registration in AE.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Ae)) }
attr_accessor :ae
# Options for the registration in AL.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Al)) }
attr_accessor :al
# Options for the registration in AM.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Am)) }
attr_accessor :am
# Options for the registration in AO.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Ao)) }
attr_accessor :ao
# Options for the registration in AT.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::At)) }
attr_accessor :at
# Options for the registration in AU.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Au)) }
attr_accessor :au
# Options for the registration in AW.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Aw)) }
attr_accessor :aw
# Options for the registration in AZ.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Az)) }
attr_accessor :az
# Options for the registration in BA.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Ba)) }
attr_accessor :ba
# Options for the registration in BB.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Bb)) }
attr_accessor :bb
# Options for the registration in BD.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Bd)) }
attr_accessor :bd
# Options for the registration in BE.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Be)) }
attr_accessor :be
# Options for the registration in BF.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Bf)) }
attr_accessor :bf
# Options for the registration in BG.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Bg)) }
attr_accessor :bg
# Options for the registration in BH.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Bh)) }
attr_accessor :bh
# Options for the registration in BJ.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Bj)) }
attr_accessor :bj
# Options for the registration in BS.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Bs)) }
attr_accessor :bs
# Options for the registration in BY.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::By)) }
attr_accessor :by
# Options for the registration in CA.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Ca)) }
attr_accessor :ca
# Options for the registration in CD.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Cd)) }
attr_accessor :cd
# Options for the registration in CH.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Ch)) }
attr_accessor :ch
# Options for the registration in CL.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Cl)) }
attr_accessor :cl
# Options for the registration in CM.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Cm)) }
attr_accessor :cm
# Options for the registration in CO.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Co)) }
attr_accessor :co
# Options for the registration in CR.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Cr)) }
attr_accessor :cr
# Options for the registration in CV.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Cv)) }
attr_accessor :cv
# Options for the registration in CY.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Cy)) }
attr_accessor :cy
# Options for the registration in CZ.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Cz)) }
attr_accessor :cz
# Options for the registration in DE.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::De)) }
attr_accessor :de
# Options for the registration in DK.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Dk)) }
attr_accessor :dk
# Options for the registration in EC.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Ec)) }
attr_accessor :ec
# Options for the registration in EE.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Ee)) }
attr_accessor :ee
# Options for the registration in EG.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Eg)) }
attr_accessor :eg
# Options for the registration in ES.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Es)) }
attr_accessor :es
# Options for the registration in ET.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Et)) }
attr_accessor :et
# Options for the registration in FI.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Fi)) }
attr_accessor :fi
# Options for the registration in FR.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Fr)) }
attr_accessor :fr
# Options for the registration in GB.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Gb)) }
attr_accessor :gb
# Options for the registration in GE.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Ge)) }
attr_accessor :ge
# Options for the registration in GN.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Gn)) }
attr_accessor :gn
# Options for the registration in GR.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Gr)) }
attr_accessor :gr
# Options for the registration in HR.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Hr)) }
attr_accessor :hr
# Options for the registration in HU.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Hu)) }
attr_accessor :hu
# Options for the registration in ID.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Id)) }
attr_accessor :id
# Options for the registration in IE.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Ie)) }
attr_accessor :ie
# Options for the registration in IN.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::In)) }
attr_accessor :in
# Options for the registration in IS.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Is)) }
attr_accessor :is
# Options for the registration in IT.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::It)) }
attr_accessor :it
# Options for the registration in JP.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Jp)) }
attr_accessor :jp
# Options for the registration in KE.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Ke)) }
attr_accessor :ke
# Options for the registration in KG.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Kg)) }
attr_accessor :kg
# Options for the registration in KH.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Kh)) }
attr_accessor :kh
# Options for the registration in KR.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Kr)) }
attr_accessor :kr
# Options for the registration in KZ.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Kz)) }
attr_accessor :kz
# Options for the registration in LA.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::La)) }
attr_accessor :la
# Options for the registration in LT.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Lt)) }
attr_accessor :lt
# Options for the registration in LU.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Lu)) }
attr_accessor :lu
# Options for the registration in LV.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Lv)) }
attr_accessor :lv
# Options for the registration in MA.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Ma)) }
attr_accessor :ma
# Options for the registration in MD.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Md)) }
attr_accessor :md
# Options for the registration in ME.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Me)) }
attr_accessor :me
# Options for the registration in MK.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Mk)) }
attr_accessor :mk
# Options for the registration in MR.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Mr)) }
attr_accessor :mr
# Options for the registration in MT.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Mt)) }
attr_accessor :mt
# Options for the registration in MX.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Mx)) }
attr_accessor :mx
# Options for the registration in MY.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::My)) }
attr_accessor :my
# Options for the registration in NG.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Ng)) }
attr_accessor :ng
# Options for the registration in NL.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Nl)) }
attr_accessor :nl
# Options for the registration in NO.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::No)) }
attr_accessor :no
# Options for the registration in NP.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Np)) }
attr_accessor :np
# Options for the registration in NZ.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Nz)) }
attr_accessor :nz
# Options for the registration in OM.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Om)) }
attr_accessor :om
# Options for the registration in PE.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Pe)) }
attr_accessor :pe
# Options for the registration in PH.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Ph)) }
attr_accessor :ph
# Options for the registration in PL.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Pl)) }
attr_accessor :pl
# Options for the registration in PT.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Pt)) }
attr_accessor :pt
# Options for the registration in RO.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Ro)) }
attr_accessor :ro
# Options for the registration in RS.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Rs)) }
attr_accessor :rs
# Options for the registration in RU.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Ru)) }
attr_accessor :ru
# Options for the registration in SA.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Sa)) }
attr_accessor :sa
# Options for the registration in SE.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Se)) }
attr_accessor :se
# Options for the registration in SG.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Sg)) }
attr_accessor :sg
# Options for the registration in SI.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Si)) }
attr_accessor :si
# Options for the registration in SK.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Sk)) }
attr_accessor :sk
# Options for the registration in SN.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Sn)) }
attr_accessor :sn
# Options for the registration in SR.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Sr)) }
attr_accessor :sr
# Options for the registration in TH.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Th)) }
attr_accessor :th
# Options for the registration in TJ.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Tj)) }
attr_accessor :tj
# Options for the registration in TR.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Tr)) }
attr_accessor :tr
# Options for the registration in TZ.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Tz)) }
attr_accessor :tz
# Options for the registration in UG.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Ug)) }
attr_accessor :ug
# Options for the registration in US.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Us)) }
attr_accessor :us
# Options for the registration in UY.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Uy)) }
attr_accessor :uy
# Options for the registration in UZ.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Uz)) }
attr_accessor :uz
# Options for the registration in VN.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Vn)) }
attr_accessor :vn
# Options for the registration in ZA.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Za)) }
attr_accessor :za
# Options for the registration in ZM.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Zm)) }
attr_accessor :zm
# Options for the registration in ZW.
sig { returns(T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Zw)) }
attr_accessor :zw
sig {
params(ae: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Ae), al: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Al), am: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Am), ao: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Ao), at: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::At), au: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Au), aw: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Aw), az: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Az), ba: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Ba), bb: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Bb), bd: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Bd), be: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Be), bf: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Bf), bg: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Bg), bh: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Bh), bj: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Bj), bs: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Bs), by: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::By), ca: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Ca), cd: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Cd), ch: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Ch), cl: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Cl), cm: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Cm), co: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Co), cr: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Cr), cv: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Cv), cy: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Cy), cz: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Cz), de: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::De), dk: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Dk), ec: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Ec), ee: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Ee), eg: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Eg), es: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Es), et: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Et), fi: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Fi), fr: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Fr), gb: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Gb), ge: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Ge), gn: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Gn), gr: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Gr), hr: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Hr), hu: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Hu), id: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Id), ie: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Ie), in_: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::In), is: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Is), it: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::It), jp: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Jp), ke: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Ke), kg: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Kg), kh: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Kh), kr: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Kr), kz: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Kz), la: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::La), lt: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Lt), lu: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Lu), lv: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Lv), ma: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Ma), md: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Md), me: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Me), mk: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Mk), mr: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Mr), mt: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Mt), mx: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Mx), my: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::My), ng: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Ng), nl: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Nl), no: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::No), np: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Np), nz: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Nz), om: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Om), pe: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Pe), ph: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Ph), pl: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Pl), pt: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Pt), ro: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Ro), rs: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Rs), ru: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Ru), sa: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Sa), se: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Se), sg: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Sg), si: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Si), sk: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Sk), sn: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Sn), sr: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Sr), th: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Th), tj: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Tj), tr: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Tr), tz: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Tz), ug: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Ug), us: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Us), uy: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Uy), uz: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Uz), vn: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Vn), za: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Za), zm: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Zm), zw: T.nilable(::Stripe::Tax::Registration::CreateParams::CountryOptions::Zw)).void
}
def initialize(
ae: nil,
al: nil,
am: nil,
ao: nil,
at: nil,
au: nil,
aw: nil,
az: nil,
ba: nil,
bb: nil,
bd: nil,
be: nil,
bf: nil,
bg: nil,
bh: nil,
bj: nil,
bs: nil,
by: nil,
ca: nil,
cd: nil,
ch: nil,
cl: nil,
cm: nil,
co: nil,
cr: nil,
cv: nil,
cy: nil,
cz: nil,
de: nil,
dk: nil,
ec: nil,
ee: nil,
eg: nil,
es: nil,
et: nil,
fi: nil,
fr: nil,
gb: nil,
ge: nil,
gn: nil,
gr: nil,
hr: nil,
hu: nil,
id: nil,
ie: nil,
in_: nil,
is: nil,
it: nil,
jp: nil,
ke: nil,
kg: nil,
kh: nil,
kr: nil,
kz: nil,
la: nil,
lt: nil,
lu: nil,
lv: nil,
ma: nil,
md: nil,
me: nil,
mk: nil,
mr: nil,
mt: nil,
mx: nil,
my: nil,
ng: nil,
nl: nil,
no: nil,
np: nil,
nz: nil,
om: nil,
pe: nil,
ph: nil,
pl: nil,
pt: nil,
ro: nil,
rs: nil,
ru: nil,
sa: nil,
se: nil,
sg: nil,
si: nil,
sk: nil,
sn: nil,
sr: nil,
th: nil,
tj: nil,
tr: nil,
tz: nil,
ug: nil,
us: nil,
uy: nil,
uz: nil,
vn: nil,
za: nil,
zm: nil,
zw: nil
); end
end
# Time at which the Tax Registration becomes active. It can be either `now` to indicate the current time, or a future timestamp measured in seconds since the Unix epoch.
sig { returns(T.any(String, Integer)) }
attr_accessor :active_from
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(String) }
attr_accessor :country
# Specific options for a registration in the specified `country`.
sig { returns(::Stripe::Tax::Registration::CreateParams::CountryOptions) }
attr_accessor :country_options
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# If set, the Tax Registration stops being active at this time. If not set, the Tax Registration will be active indefinitely. Timestamp measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_at
sig {
params(active_from: T.any(String, Integer), country: String, country_options: ::Stripe::Tax::Registration::CreateParams::CountryOptions, expand: T.nilable(T::Array[String]), expires_at: T.nilable(Integer)).void
}
def initialize(
active_from: nil,
country: nil,
country_options: nil,
expand: nil,
expires_at: nil
); end
end
class UpdateParams < Stripe::RequestParams
# Time at which the registration becomes active. It can be either `now` to indicate the current time, or a timestamp measured in seconds since the Unix epoch.
sig { returns(T.nilable(T.any(String, Integer))) }
attr_accessor :active_from
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# If set, the registration stops being active at this time. If not set, the registration will be active indefinitely. It can be either `now` to indicate the current time, or a timestamp measured in seconds since the Unix epoch.
sig { returns(T.nilable(T.nilable(T.any(String, T.any(String, Integer))))) }
attr_accessor :expires_at
sig {
params(active_from: T.nilable(T.any(String, Integer)), expand: T.nilable(T::Array[String]), expires_at: T.nilable(T.nilable(T.any(String, T.any(String, Integer))))).void
}
def initialize(active_from: nil, expand: nil, expires_at: nil); end
end
# Creates a new Tax Registration object.
sig {
params(params: T.any(::Stripe::Tax::Registration::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Tax::Registration)
}
def self.create(params = {}, opts = {}); end
# Returns a list of Tax Registration objects.
sig {
params(params: T.any(::Stripe::Tax::Registration::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Updates an existing Tax Registration object.
#
# A registration cannot be deleted after it has been created. If you wish to end a registration you may do so by setting expires_at.
sig {
params(id: String, params: T.any(::Stripe::Tax::Registration::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Tax::Registration)
}
def self.update(id, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Tax
# You can use Tax `Settings` to manage configurations used by Stripe Tax calculations.
#
# Related guide: [Using the Settings API](https://stripe.com/docs/tax/settings-api)
class Settings < SingletonAPIResource
class Defaults < Stripe::StripeObject
# 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.
sig { returns(T.nilable(String)) }
attr_reader :tax_behavior
# Default [tax code](https://stripe.com/docs/tax/tax-categories) used to classify your products and prices.
sig { returns(T.nilable(String)) }
attr_reader :tax_code
end
class HeadOffice < Stripe::StripeObject
class Address < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Attribute for field address
sig { returns(Address) }
attr_reader :address
end
class StatusDetails < Stripe::StripeObject
class Active < Stripe::StripeObject; end
class Pending < Stripe::StripeObject
# 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.
sig { returns(T.nilable(T::Array[String])) }
attr_reader :missing_fields
end
# Attribute for field active
sig { returns(Active) }
attr_reader :active
# Attribute for field pending
sig { returns(Pending) }
attr_reader :pending
end
# Attribute for field defaults
sig { returns(Defaults) }
attr_reader :defaults
# The place where your business is located.
sig { returns(T.nilable(HeadOffice)) }
attr_reader :head_office
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The status of the Tax `Settings`.
sig { returns(String) }
attr_reader :status
# Attribute for field status_details
sig { returns(StatusDetails) }
attr_reader :status_details
class UpdateParams < Stripe::RequestParams
class Defaults < Stripe::RequestParams
# Specifies the default [tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#tax-behavior) to be used when the item's price has unspecified tax behavior. One of inclusive, exclusive, or inferred_by_currency. Once specified, it cannot be changed back to null.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
sig { returns(T.nilable(String)) }
attr_accessor :tax_code
sig { params(tax_behavior: T.nilable(String), tax_code: T.nilable(String)).void }
def initialize(tax_behavior: nil, tax_code: nil); end
end
class HeadOffice < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State/province as an [ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2) subdivision code, without country prefix. Example: "NY" or "TX".
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# The location of the business for tax purposes.
sig { returns(::Stripe::Tax::Settings::UpdateParams::HeadOffice::Address) }
attr_accessor :address
sig { params(address: ::Stripe::Tax::Settings::UpdateParams::HeadOffice::Address).void }
def initialize(address: nil); end
end
# Default configuration to be used on Stripe Tax calculations.
sig { returns(T.nilable(::Stripe::Tax::Settings::UpdateParams::Defaults)) }
attr_accessor :defaults
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The place where your business is located.
sig { returns(T.nilable(::Stripe::Tax::Settings::UpdateParams::HeadOffice)) }
attr_accessor :head_office
sig {
params(defaults: T.nilable(::Stripe::Tax::Settings::UpdateParams::Defaults), expand: T.nilable(T::Array[String]), head_office: T.nilable(::Stripe::Tax::Settings::UpdateParams::HeadOffice)).void
}
def initialize(defaults: nil, expand: nil, head_office: nil); end
end
end
end
end
# typed: true
module Stripe
module Tax
# A Tax Transaction records the tax collected from or refunded to your customer.
#
# Related guide: [Calculate tax in your custom payment flow](https://stripe.com/docs/tax/custom#tax-transaction)
class Transaction < APIResource
class CustomerDetails < Stripe::StripeObject
class Address < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(String) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State/province as an [ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2) subdivision code, without country prefix. Example: "NY" or "TX".
sig { returns(T.nilable(String)) }
attr_reader :state
end
class TaxId < Stripe::StripeObject
# The type of the tax ID, one of `ad_nrt`, `ar_cuit`, `eu_vat`, `bo_tin`, `br_cnpj`, `br_cpf`, `cn_tin`, `co_nit`, `cr_tin`, `do_rcn`, `ec_ruc`, `eu_oss_vat`, `hr_oib`, `pe_ruc`, `ro_tin`, `rs_pib`, `sv_nit`, `uy_ruc`, `ve_rif`, `vn_tin`, `gb_vat`, `nz_gst`, `au_abn`, `au_arn`, `in_gst`, `no_vat`, `no_voec`, `za_vat`, `ch_vat`, `mx_rfc`, `sg_uen`, `ru_inn`, `ru_kpp`, `ca_bn`, `hk_br`, `es_cif`, `tw_vat`, `th_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `li_uid`, `li_vat`, `my_itn`, `us_ein`, `kr_brn`, `ca_qst`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `my_sst`, `sg_gst`, `ae_trn`, `cl_tin`, `sa_vat`, `id_npwp`, `my_frp`, `il_vat`, `ge_vat`, `ua_vat`, `is_vat`, `bg_uic`, `hu_tin`, `si_tin`, `ke_pin`, `tr_tin`, `eg_tin`, `ph_tin`, `al_tin`, `bh_vat`, `kz_bin`, `ng_tin`, `om_vat`, `de_stn`, `ch_uid`, `tz_vat`, `uz_vat`, `uz_tin`, `md_vat`, `ma_vat`, `by_tin`, `ao_tin`, `bs_tin`, `bb_tin`, `cd_nif`, `mr_nif`, `me_pib`, `zw_tin`, `ba_tin`, `gn_nif`, `mk_vat`, `sr_fin`, `sn_ninea`, `am_tin`, `np_pan`, `tj_tin`, `ug_tin`, `zm_tin`, `kh_tin`, `aw_tin`, `az_tin`, `bd_bin`, `bj_ifu`, `et_tin`, `kg_tin`, `la_tin`, `cm_niu`, `cv_nif`, `bf_ifu`, or `unknown`
sig { returns(String) }
attr_reader :type
# The value of the tax ID.
sig { returns(String) }
attr_reader :value
end
# The customer's postal address (for example, home or business location).
sig { returns(T.nilable(Address)) }
attr_reader :address
# The type of customer address provided.
sig { returns(T.nilable(String)) }
attr_reader :address_source
# The customer's IP address (IPv4 or IPv6).
sig { returns(T.nilable(String)) }
attr_reader :ip_address
# The customer's tax IDs (for example, EU VAT numbers).
sig { returns(T::Array[TaxId]) }
attr_reader :tax_ids
# The taxability override used for taxation.
sig { returns(String) }
attr_reader :taxability_override
end
class Reversal < Stripe::StripeObject
# The `id` of the reversed `Transaction` object.
sig { returns(T.nilable(String)) }
attr_reader :original_transaction
end
class ShipFromDetails < Stripe::StripeObject
class Address < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(String) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State/province as an [ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2) subdivision code, without country prefix. Example: "NY" or "TX".
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Attribute for field address
sig { returns(Address) }
attr_reader :address
end
class ShippingCost < Stripe::StripeObject
class TaxBreakdown < Stripe::StripeObject
class Jurisdiction < Stripe::StripeObject
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(String) }
attr_reader :country
# A human-readable name for the jurisdiction imposing the tax.
sig { returns(String) }
attr_reader :display_name
# Indicates the level of the jurisdiction imposing the tax.
sig { returns(String) }
attr_reader :level
# [ISO 3166-2 subdivision code](https://en.wikipedia.org/wiki/ISO_3166-2), without country prefix. For example, "NY" for New York, United States.
sig { returns(T.nilable(String)) }
attr_reader :state
end
class TaxRateDetails < Stripe::StripeObject
# A localized display name for tax type, intended to be human-readable. For example, "Local Sales and Use Tax", "Value-added tax (VAT)", or "Umsatzsteuer (USt.)".
sig { returns(String) }
attr_reader :display_name
# The tax rate percentage as a string. For example, 8.5% is represented as "8.5".
sig { returns(String) }
attr_reader :percentage_decimal
# The tax type, such as `vat` or `sales_tax`.
sig { returns(String) }
attr_reader :tax_type
end
# The amount of tax, in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(Integer) }
attr_reader :amount
# Attribute for field jurisdiction
sig { returns(Jurisdiction) }
attr_reader :jurisdiction
# Indicates whether the jurisdiction was determined by the origin (merchant's address) or destination (customer's address).
sig { returns(String) }
attr_reader :sourcing
# Details regarding the rate for this tax. This field will be `null` when the tax is not imposed, for example if the product is exempt from tax.
sig { returns(T.nilable(TaxRateDetails)) }
attr_reader :tax_rate_details
# 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.
sig { returns(String) }
attr_reader :taxability_reason
# The amount on which tax is calculated, in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(Integer) }
attr_reader :taxable_amount
end
# The shipping amount in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal). If `tax_behavior=inclusive`, then this amount includes taxes. Otherwise, taxes were calculated on top of this amount.
sig { returns(Integer) }
attr_reader :amount
# The amount of tax calculated for shipping, in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(Integer) }
attr_reader :amount_tax
# The ID of an existing [ShippingRate](https://stripe.com/docs/api/shipping_rates/object).
sig { returns(String) }
attr_reader :shipping_rate
# Specifies whether the `amount` includes taxes. If `tax_behavior=inclusive`, then the amount includes taxes.
sig { returns(String) }
attr_reader :tax_behavior
# Detailed account of taxes relevant to shipping cost. (It is not populated for the transaction resource object and will be removed in the next API version.)
sig { returns(T::Array[TaxBreakdown]) }
attr_reader :tax_breakdown
# The [tax code](https://stripe.com/docs/tax/tax-categories) ID used for shipping.
sig { returns(String) }
attr_reader :tax_code
end
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# 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).
sig { returns(String) }
attr_reader :currency
# The ID of an existing [Customer](https://stripe.com/docs/api/customers/object) used for the resource.
sig { returns(T.nilable(String)) }
attr_reader :customer
# Attribute for field customer_details
sig { returns(CustomerDetails) }
attr_reader :customer_details
# Unique identifier for the transaction.
sig { returns(String) }
attr_reader :id
# The tax collected or refunded, by line item.
sig { returns(T.nilable(Stripe::ListObject)) }
attr_reader :line_items
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# 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.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The Unix timestamp representing when the tax liability is assumed or reduced.
sig { returns(Integer) }
attr_reader :posted_at
# A custom unique identifier, such as 'myOrder_123'.
sig { returns(String) }
attr_reader :reference
# If `type=reversal`, contains information about what was reversed.
sig { returns(T.nilable(Reversal)) }
attr_reader :reversal
# The details of the ship from location, such as the address.
sig { returns(T.nilable(ShipFromDetails)) }
attr_reader :ship_from_details
# The shipping cost details for the transaction.
sig { returns(T.nilable(ShippingCost)) }
attr_reader :shipping_cost
# Timestamp of date at which the tax rules and rates in effect applies for the calculation.
sig { returns(Integer) }
attr_reader :tax_date
# If `reversal`, this transaction reverses an earlier transaction.
sig { returns(String) }
attr_reader :type
class ListLineItemsParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
class CreateFromCalculationParams < Stripe::RequestParams
# Tax Calculation ID to be used as input when creating the transaction.
sig { returns(String) }
attr_accessor :calculation
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The Unix timestamp representing when the tax liability is assumed or reduced, which determines the liability posting period and handling in tax liability reports. The timestamp must fall within the `tax_date` and the current time, unless the `tax_date` is scheduled in advance. Defaults to the current time.
sig { returns(T.nilable(Integer)) }
attr_accessor :posted_at
# A custom order or sale identifier, such as 'myOrder_123'. Must be unique across all transactions, including reversals.
sig { returns(String) }
attr_accessor :reference
sig {
params(calculation: String, expand: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), posted_at: T.nilable(Integer), reference: String).void
}
def initialize(
calculation: nil,
expand: nil,
metadata: nil,
posted_at: nil,
reference: nil
); end
end
class CreateReversalParams < Stripe::RequestParams
class LineItem < Stripe::RequestParams
# The amount to reverse, in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) in negative.
sig { returns(Integer) }
attr_accessor :amount
# The amount of tax to reverse, in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) in negative.
sig { returns(Integer) }
attr_accessor :amount_tax
# 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.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The `id` of the line item to reverse in the original transaction.
sig { returns(String) }
attr_accessor :original_line_item
# The quantity reversed. Appears in [tax exports](https://stripe.com/docs/tax/reports), but does not affect the amount of tax reversed.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# A custom identifier for this line item in the reversal transaction, such as 'L1-refund'.
sig { returns(String) }
attr_accessor :reference
sig {
params(amount: Integer, amount_tax: Integer, metadata: T.nilable(T::Hash[String, String]), original_line_item: String, quantity: T.nilable(Integer), reference: String).void
}
def initialize(
amount: nil,
amount_tax: nil,
metadata: nil,
original_line_item: nil,
quantity: nil,
reference: nil
); end
end
class ShippingCost < Stripe::RequestParams
# The amount to reverse, in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) in negative.
sig { returns(Integer) }
attr_accessor :amount
# The amount of tax to reverse, in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) in negative.
sig { returns(Integer) }
attr_accessor :amount_tax
sig { params(amount: Integer, amount_tax: Integer).void }
def initialize(amount: nil, amount_tax: nil); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A flat amount to reverse across the entire transaction, in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) in negative. This value represents the total amount to refund from the transaction, including taxes.
sig { returns(T.nilable(Integer)) }
attr_accessor :flat_amount
# The line item amounts to reverse.
sig {
returns(T.nilable(T::Array[::Stripe::Tax::Transaction::CreateReversalParams::LineItem]))
}
attr_accessor :line_items
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# If `partial`, the provided line item or shipping cost amounts are reversed. If `full`, the original transaction is fully reversed.
sig { returns(String) }
attr_accessor :mode
# The ID of the Transaction to partially or fully reverse.
sig { returns(String) }
attr_accessor :original_transaction
# A custom identifier for this reversal, such as `myOrder_123-refund_1`, which must be unique across all transactions. The reference helps identify this reversal transaction in exported [tax reports](https://stripe.com/docs/tax/reports).
sig { returns(String) }
attr_accessor :reference
# The shipping cost to reverse.
sig { returns(T.nilable(::Stripe::Tax::Transaction::CreateReversalParams::ShippingCost)) }
attr_accessor :shipping_cost
sig {
params(expand: T.nilable(T::Array[String]), flat_amount: T.nilable(Integer), line_items: T.nilable(T::Array[::Stripe::Tax::Transaction::CreateReversalParams::LineItem]), metadata: T.nilable(T::Hash[String, String]), mode: String, original_transaction: String, reference: String, shipping_cost: T.nilable(::Stripe::Tax::Transaction::CreateReversalParams::ShippingCost)).void
}
def initialize(
expand: nil,
flat_amount: nil,
line_items: nil,
metadata: nil,
mode: nil,
original_transaction: nil,
reference: nil,
shipping_cost: nil
); end
end
# Creates a Tax Transaction from a calculation, if that calculation hasn't expired. Calculations expire after 90 days.
sig {
params(params: T.any(::Stripe::Tax::Transaction::CreateFromCalculationParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Tax::Transaction)
}
def self.create_from_calculation(params = {}, opts = {}); end
# Partially or fully reverses a previously created Transaction.
sig {
params(params: T.any(::Stripe::Tax::Transaction::CreateReversalParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Tax::Transaction)
}
def self.create_reversal(params = {}, opts = {}); end
# Retrieves the line items of a committed standalone transaction as a collection.
sig {
params(params: T.any(::Stripe::Tax::Transaction::ListLineItemsParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list_line_items(params = {}, opts = {}); end
# Retrieves the line items of a committed standalone transaction as a collection.
sig {
params(transaction: String, params: T.any(::Stripe::Tax::Transaction::ListLineItemsParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list_line_items(transaction, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Tax
class TransactionLineItem < APIResource
class Reversal < Stripe::StripeObject
# The `id` of the line item to reverse in the original transaction.
sig { returns(String) }
attr_reader :original_line_item
end
# The line item amount in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal). If `tax_behavior=inclusive`, then this amount includes taxes. Otherwise, taxes were calculated on top of this amount.
sig { returns(Integer) }
attr_reader :amount
# The amount of tax calculated for this line item, in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(Integer) }
attr_reader :amount_tax
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# 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.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The ID of an existing [Product](https://stripe.com/docs/api/products/object).
sig { returns(T.nilable(String)) }
attr_reader :product
# The number of units of the item being purchased. For reversals, this is the quantity reversed.
sig { returns(Integer) }
attr_reader :quantity
# A custom identifier for this line item in the transaction.
sig { returns(String) }
attr_reader :reference
# If `type=reversal`, contains information about what was reversed.
sig { returns(T.nilable(Reversal)) }
attr_reader :reversal
# Specifies whether the `amount` includes taxes. If `tax_behavior=inclusive`, then the amount includes taxes.
sig { returns(String) }
attr_reader :tax_behavior
# The [tax code](https://stripe.com/docs/tax/tax-categories) ID used for this resource.
sig { returns(String) }
attr_reader :tax_code
# If `reversal`, this line item reverses an earlier transaction.
sig { returns(String) }
attr_reader :type
end
end
end
# typed: true
module Stripe
# [Tax codes](https://stripe.com/docs/tax/tax-categories) classify goods and services for tax purposes.
class TaxCode < APIResource
# A detailed description of which types of products the tax code represents.
sig { returns(String) }
attr_reader :description
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# A short name for the tax code.
sig { returns(String) }
attr_reader :name
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
# A list of [all tax codes available](https://stripe.com/docs/tax/tax-categories) to add to Products in order to allow specific tax calculations.
sig {
params(params: T.any(::Stripe::TaxCode::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class TaxDeductedAtSource < APIResource
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The end of the invoicing period. This TDS applies to Stripe fees collected during this invoicing period.
sig { returns(Integer) }
attr_reader :period_end
# The start of the invoicing period. This TDS applies to Stripe fees collected during this invoicing period.
sig { returns(Integer) }
attr_reader :period_start
# The TAN that was supplied to Stripe when TDS was assessed
sig { returns(String) }
attr_reader :tax_deduction_account_number
end
end
# typed: true
module Stripe
# You can add one or multiple tax IDs to a [customer](https://stripe.com/docs/api/customers) or account.
# Customer and account tax IDs get displayed on related invoices and credit notes.
#
# Related guides: [Customer tax identification numbers](https://stripe.com/docs/billing/taxes/tax-ids), [Account tax IDs](https://stripe.com/docs/invoicing/connect#account-tax-ids)
class TaxId < APIResource
class Owner < Stripe::StripeObject
# The account being referenced when `type` is `account`.
sig { returns(T.any(String, Stripe::Account)) }
attr_reader :account
# The Connect Application being referenced when `type` is `application`.
sig { returns(T.any(String, Stripe::Application)) }
attr_reader :application
# The customer being referenced when `type` is `customer`.
sig { returns(T.any(String, Stripe::Customer)) }
attr_reader :customer
# The account being referenced when `type` is `customer`.
sig { returns(T.nilable(String)) }
attr_reader :customer_account
# Type of owner referenced.
sig { returns(String) }
attr_reader :type
end
class Verification < Stripe::StripeObject
# Verification status, one of `pending`, `verified`, `unverified`, or `unavailable`.
sig { returns(String) }
attr_reader :status
# Verified address.
sig { returns(T.nilable(String)) }
attr_reader :verified_address
# Verified name.
sig { returns(T.nilable(String)) }
attr_reader :verified_name
end
# Two-letter ISO code representing the country of the tax ID.
sig { returns(T.nilable(String)) }
attr_reader :country
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# ID of the customer.
sig { returns(T.nilable(T.any(String, Stripe::Customer))) }
attr_reader :customer
# ID of the account.
sig { returns(T.nilable(String)) }
attr_reader :customer_account
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The account or customer the tax ID belongs to.
sig { returns(T.nilable(Owner)) }
attr_reader :owner
# Type of the tax ID, one of `ad_nrt`, `ae_trn`, `al_tin`, `am_tin`, `ao_tin`, `ar_cuit`, `au_abn`, `au_arn`, `aw_tin`, `az_tin`, `ba_tin`, `bb_tin`, `bd_bin`, `bf_ifu`, `bg_uic`, `bh_vat`, `bj_ifu`, `bo_tin`, `br_cnpj`, `br_cpf`, `bs_tin`, `by_tin`, `ca_bn`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `ca_qst`, `cd_nif`, `ch_uid`, `ch_vat`, `cl_tin`, `cm_niu`, `cn_tin`, `co_nit`, `cr_tin`, `cv_nif`, `de_stn`, `do_rcn`, `ec_ruc`, `eg_tin`, `es_cif`, `et_tin`, `eu_oss_vat`, `eu_vat`, `gb_vat`, `ge_vat`, `gn_nif`, `hk_br`, `hr_oib`, `hu_tin`, `id_npwp`, `il_vat`, `in_gst`, `is_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `ke_pin`, `kg_tin`, `kh_tin`, `kr_brn`, `kz_bin`, `la_tin`, `li_uid`, `li_vat`, `ma_vat`, `md_vat`, `me_pib`, `mk_vat`, `mr_nif`, `mx_rfc`, `my_frp`, `my_itn`, `my_sst`, `ng_tin`, `no_vat`, `no_voec`, `np_pan`, `nz_gst`, `om_vat`, `pe_ruc`, `ph_tin`, `ro_tin`, `rs_pib`, `ru_inn`, `ru_kpp`, `sa_vat`, `sg_gst`, `sg_uen`, `si_tin`, `sn_ninea`, `sr_fin`, `sv_nit`, `th_vat`, `tj_tin`, `tr_tin`, `tw_vat`, `tz_vat`, `ua_vat`, `ug_tin`, `us_ein`, `uy_ruc`, `uz_tin`, `uz_vat`, `ve_rif`, `vn_tin`, `za_vat`, `zm_tin`, or `zw_tin`. Note that some legacy tax IDs have type `unknown`
sig { returns(String) }
attr_reader :type
# Value of the tax ID.
sig { returns(String) }
attr_reader :value
# Tax ID verification information.
sig { returns(T.nilable(Verification)) }
attr_reader :verification
# Always true for a deleted object
sig { returns(T::Boolean) }
attr_reader :deleted
class DeleteParams < Stripe::RequestParams; end
class ListParams < Stripe::RequestParams
class Owner < Stripe::RequestParams
# Account the tax ID belongs to. Required when `type=account`
sig { returns(T.nilable(String)) }
attr_accessor :account
# Customer the tax ID belongs to. Required when `type=customer`
sig { returns(T.nilable(String)) }
attr_accessor :customer
# v2 Account the tax ID belongs to. Can be used in place of `customer` when `type=customer`
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# Type of owner referenced.
sig { returns(String) }
attr_accessor :type
sig {
params(account: T.nilable(String), customer: T.nilable(String), customer_account: T.nilable(String), type: String).void
}
def initialize(account: nil, customer: nil, customer_account: nil, type: nil); end
end
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# The account or customer the tax ID belongs to. Defaults to `owner[type]=self`.
sig { returns(T.nilable(::Stripe::TaxId::ListParams::Owner)) }
attr_accessor :owner
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), owner: T.nilable(::Stripe::TaxId::ListParams::Owner), starting_after: T.nilable(String)).void
}
def initialize(
ending_before: nil,
expand: nil,
limit: nil,
owner: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class Owner < Stripe::RequestParams
# Account the tax ID belongs to. Required when `type=account`
sig { returns(T.nilable(String)) }
attr_accessor :account
# Customer the tax ID belongs to. Required when `type=customer`
sig { returns(T.nilable(String)) }
attr_accessor :customer
# v2 Account the tax ID belongs to. Can be used in place of `customer` when `type=customer`
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# Type of owner referenced.
sig { returns(String) }
attr_accessor :type
sig {
params(account: T.nilable(String), customer: T.nilable(String), customer_account: T.nilable(String), type: String).void
}
def initialize(account: nil, customer: nil, customer_account: nil, type: nil); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The account or customer the tax ID belongs to. Defaults to `owner[type]=self`.
sig { returns(T.nilable(::Stripe::TaxId::CreateParams::Owner)) }
attr_accessor :owner
# Type of the tax ID, one of `ad_nrt`, `ae_trn`, `al_tin`, `am_tin`, `ao_tin`, `ar_cuit`, `au_abn`, `au_arn`, `aw_tin`, `az_tin`, `ba_tin`, `bb_tin`, `bd_bin`, `bf_ifu`, `bg_uic`, `bh_vat`, `bj_ifu`, `bo_tin`, `br_cnpj`, `br_cpf`, `bs_tin`, `by_tin`, `ca_bn`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `ca_qst`, `cd_nif`, `ch_uid`, `ch_vat`, `cl_tin`, `cm_niu`, `cn_tin`, `co_nit`, `cr_tin`, `cv_nif`, `de_stn`, `do_rcn`, `ec_ruc`, `eg_tin`, `es_cif`, `et_tin`, `eu_oss_vat`, `eu_vat`, `gb_vat`, `ge_vat`, `gn_nif`, `hk_br`, `hr_oib`, `hu_tin`, `id_npwp`, `il_vat`, `in_gst`, `is_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `ke_pin`, `kg_tin`, `kh_tin`, `kr_brn`, `kz_bin`, `la_tin`, `li_uid`, `li_vat`, `ma_vat`, `md_vat`, `me_pib`, `mk_vat`, `mr_nif`, `mx_rfc`, `my_frp`, `my_itn`, `my_sst`, `ng_tin`, `no_vat`, `no_voec`, `np_pan`, `nz_gst`, `om_vat`, `pe_ruc`, `ph_tin`, `ro_tin`, `rs_pib`, `ru_inn`, `ru_kpp`, `sa_vat`, `sg_gst`, `sg_uen`, `si_tin`, `sn_ninea`, `sr_fin`, `sv_nit`, `th_vat`, `tj_tin`, `tr_tin`, `tw_vat`, `tz_vat`, `ua_vat`, `ug_tin`, `us_ein`, `uy_ruc`, `uz_tin`, `uz_vat`, `ve_rif`, `vn_tin`, `za_vat`, `zm_tin`, or `zw_tin`
sig { returns(String) }
attr_accessor :type
# Value of the tax ID.
sig { returns(String) }
attr_accessor :value
sig {
params(expand: T.nilable(T::Array[String]), owner: T.nilable(::Stripe::TaxId::CreateParams::Owner), type: String, value: String).void
}
def initialize(expand: nil, owner: nil, type: nil, value: nil); end
end
# Creates a new account or customer tax_id object.
sig {
params(params: T.any(::Stripe::TaxId::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::TaxId)
}
def self.create(params = {}, opts = {}); end
# Deletes an existing account or customer tax_id object.
sig {
params(id: String, params: T.any(::Stripe::TaxId::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::TaxId)
}
def self.delete(id, params = {}, opts = {}); end
# Deletes an existing account or customer tax_id object.
sig {
params(params: T.any(::Stripe::TaxId::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::TaxId)
}
def delete(params = {}, opts = {}); end
# Returns a list of tax IDs.
sig {
params(params: T.any(::Stripe::TaxId::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
end
end
# typed: true
module Stripe
# Tax rates can be applied to [invoices](https://docs.stripe.com/invoicing/taxes/tax-rates), [subscriptions](https://docs.stripe.com/billing/taxes/tax-rates) and [Checkout Sessions](https://docs.stripe.com/payments/checkout/use-manual-tax-rates) to collect tax.
#
# Related guide: [Tax rates](https://docs.stripe.com/billing/taxes/tax-rates)
class TaxRate < APIResource
class FlatAmount < Stripe::StripeObject
# Amount of the tax when the `rate_type` is `flat_amount`. This positive integer represents how much to charge in the smallest currency unit (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99).
sig { returns(Integer) }
attr_reader :amount
# Three-letter ISO currency code, in lowercase.
sig { returns(String) }
attr_reader :currency
end
# Defaults to `true`. When set to `false`, this tax rate cannot be used with new applications or Checkout Sessions, but will still work for subscriptions and invoices that already have it set.
sig { returns(T::Boolean) }
attr_reader :active
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# An arbitrary string attached to the tax rate for your internal use only. It will not be visible to your customers.
sig { returns(T.nilable(String)) }
attr_reader :description
# The display name of the tax rates as it will appear to your customer on their receipt email, PDF, and the hosted invoice page.
sig { returns(String) }
attr_reader :display_name
# Actual/effective tax rate percentage out of 100. For tax calculations with automatic_tax[enabled]=true,
# this percentage reflects the rate actually used to calculate tax based on the product's taxability
# and whether the user is registered to collect taxes in the corresponding jurisdiction.
sig { returns(T.nilable(Float)) }
attr_reader :effective_percentage
# The amount of the tax rate when the `rate_type` is `flat_amount`. Tax rates with `rate_type` `percentage` can vary based on the transaction, resulting in this field being `null`. This field exposes the amount and currency of the flat tax rate.
sig { returns(T.nilable(FlatAmount)) }
attr_reader :flat_amount
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# This specifies if the tax rate is inclusive or exclusive.
sig { returns(T::Boolean) }
attr_reader :inclusive
# The jurisdiction for the tax rate. You can use this label field for tax reporting purposes. It also appears on your customer’s invoice.
sig { returns(T.nilable(String)) }
attr_reader :jurisdiction
# The level of the jurisdiction that imposes this tax rate. Will be `null` for manually defined tax rates.
sig { returns(T.nilable(String)) }
attr_reader :jurisdiction_level
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# 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.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Tax rate percentage out of 100. For tax calculations with automatic_tax[enabled]=true, this percentage includes the statutory tax rate of non-taxable jurisdictions.
sig { returns(Float) }
attr_reader :percentage
# Indicates the type of tax rate applied to the taxable amount. This value can be `null` when no tax applies to the location. This field is only present for TaxRates created by Stripe Tax.
sig { returns(T.nilable(String)) }
attr_reader :rate_type
# [ISO 3166-2 subdivision code](https://en.wikipedia.org/wiki/ISO_3166-2), without country prefix. For example, "NY" for New York, United States.
sig { returns(T.nilable(String)) }
attr_reader :state
# The high-level tax type, such as `vat` or `sales_tax`.
sig { returns(T.nilable(String)) }
attr_reader :tax_type
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Optional flag to filter by tax rates that are either active or inactive (archived).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# Optional range for filtering created date.
sig { returns(T.nilable(T.any(::Stripe::TaxRate::ListParams::Created, Integer))) }
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Optional flag to filter by tax rates that are inclusive (or those that are not inclusive).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :inclusive
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(active: T.nilable(T::Boolean), created: T.nilable(T.any(::Stripe::TaxRate::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), inclusive: T.nilable(T::Boolean), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
active: nil,
created: nil,
ending_before: nil,
expand: nil,
inclusive: nil,
limit: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
# Flag determining whether the tax rate is active or inactive (archived). Inactive tax rates cannot be used with new applications or Checkout Sessions, but will still work for subscriptions and invoices that already have it set.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# An arbitrary string attached to the tax rate for your internal use only. It will not be visible to your customers.
sig { returns(T.nilable(String)) }
attr_accessor :description
# The display name of the tax rate, which will be shown to users.
sig { returns(String) }
attr_accessor :display_name
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# This specifies if the tax rate is inclusive or exclusive.
sig { returns(T::Boolean) }
attr_accessor :inclusive
# The jurisdiction for the tax rate. You can use this label field for tax reporting purposes. It also appears on your customer’s invoice.
sig { returns(T.nilable(String)) }
attr_accessor :jurisdiction
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# This represents the tax rate percent out of 100.
sig { returns(Float) }
attr_accessor :percentage
# [ISO 3166-2 subdivision code](https://en.wikipedia.org/wiki/ISO_3166-2), without country prefix. For example, "NY" for New York, United States.
sig { returns(T.nilable(String)) }
attr_accessor :state
# The high-level tax type, such as `vat` or `sales_tax`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_type
sig {
params(active: T.nilable(T::Boolean), country: T.nilable(String), description: T.nilable(String), display_name: String, expand: T.nilable(T::Array[String]), inclusive: T::Boolean, jurisdiction: T.nilable(String), metadata: T.nilable(T::Hash[String, String]), percentage: Float, state: T.nilable(String), tax_type: T.nilable(String)).void
}
def initialize(
active: nil,
country: nil,
description: nil,
display_name: nil,
expand: nil,
inclusive: nil,
jurisdiction: nil,
metadata: nil,
percentage: nil,
state: nil,
tax_type: nil
); end
end
class UpdateParams < Stripe::RequestParams
# Flag determining whether the tax rate is active or inactive (archived). Inactive tax rates cannot be used with new applications or Checkout Sessions, but will still work for subscriptions and invoices that already have it set.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# An arbitrary string attached to the tax rate for your internal use only. It will not be visible to your customers.
sig { returns(T.nilable(String)) }
attr_accessor :description
# The display name of the tax rate, which will be shown to users.
sig { returns(T.nilable(String)) }
attr_accessor :display_name
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The jurisdiction for the tax rate. You can use this label field for tax reporting purposes. It also appears on your customer’s invoice.
sig { returns(T.nilable(String)) }
attr_accessor :jurisdiction
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# [ISO 3166-2 subdivision code](https://en.wikipedia.org/wiki/ISO_3166-2), without country prefix. For example, "NY" for New York, United States.
sig { returns(T.nilable(String)) }
attr_accessor :state
# The high-level tax type, such as `vat` or `sales_tax`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_type
sig {
params(active: T.nilable(T::Boolean), country: T.nilable(String), description: T.nilable(String), display_name: T.nilable(String), expand: T.nilable(T::Array[String]), jurisdiction: T.nilable(String), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), state: T.nilable(String), tax_type: T.nilable(String)).void
}
def initialize(
active: nil,
country: nil,
description: nil,
display_name: nil,
expand: nil,
jurisdiction: nil,
metadata: nil,
state: nil,
tax_type: nil
); end
end
# Creates a new tax rate.
sig {
params(params: T.any(::Stripe::TaxRate::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::TaxRate)
}
def self.create(params = {}, opts = {}); end
# Returns a list of your tax rates. Tax rates are returned sorted by creation date, with the most recently created tax rates appearing first.
sig {
params(params: T.any(::Stripe::TaxRate::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Updates an existing tax rate.
sig {
params(tax_rate: String, params: T.any(::Stripe::TaxRate::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::TaxRate)
}
def self.update(tax_rate, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
module Terminal
# A Configurations object represents how features should be configured for terminal readers.
class Configuration < APIResource
class BbposWiseposE < Stripe::StripeObject
# A File ID representing an image to display on the reader
sig { returns(T.any(String, Stripe::File)) }
attr_reader :splashscreen
end
class Offline < Stripe::StripeObject
# Determines whether to allow transactions to be collected while reader is offline. Defaults to false.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :enabled
end
class RebootWindow < Stripe::StripeObject
# Integer between 0 to 23 that represents the end hour of the reboot time window. The value must be different than the start_hour.
sig { returns(Integer) }
attr_reader :end_hour
# Integer between 0 to 23 that represents the start hour of the reboot time window.
sig { returns(Integer) }
attr_reader :start_hour
end
class StripeS700 < Stripe::StripeObject
# A File ID representing an image to display on the reader
sig { returns(T.any(String, Stripe::File)) }
attr_reader :splashscreen
end
class Tipping < Stripe::StripeObject
class Aud < Stripe::StripeObject
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_reader :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_reader :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(Integer) }
attr_reader :smart_tip_threshold
end
class Cad < Stripe::StripeObject
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_reader :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_reader :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(Integer) }
attr_reader :smart_tip_threshold
end
class Chf < Stripe::StripeObject
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_reader :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_reader :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(Integer) }
attr_reader :smart_tip_threshold
end
class Czk < Stripe::StripeObject
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_reader :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_reader :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(Integer) }
attr_reader :smart_tip_threshold
end
class Dkk < Stripe::StripeObject
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_reader :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_reader :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(Integer) }
attr_reader :smart_tip_threshold
end
class Eur < Stripe::StripeObject
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_reader :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_reader :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(Integer) }
attr_reader :smart_tip_threshold
end
class Gbp < Stripe::StripeObject
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_reader :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_reader :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(Integer) }
attr_reader :smart_tip_threshold
end
class Hkd < Stripe::StripeObject
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_reader :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_reader :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(Integer) }
attr_reader :smart_tip_threshold
end
class Jpy < Stripe::StripeObject
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_reader :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_reader :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(Integer) }
attr_reader :smart_tip_threshold
end
class Myr < Stripe::StripeObject
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_reader :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_reader :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(Integer) }
attr_reader :smart_tip_threshold
end
class Nok < Stripe::StripeObject
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_reader :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_reader :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(Integer) }
attr_reader :smart_tip_threshold
end
class Nzd < Stripe::StripeObject
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_reader :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_reader :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(Integer) }
attr_reader :smart_tip_threshold
end
class Pln < Stripe::StripeObject
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_reader :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_reader :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(Integer) }
attr_reader :smart_tip_threshold
end
class Sek < Stripe::StripeObject
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_reader :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_reader :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(Integer) }
attr_reader :smart_tip_threshold
end
class Sgd < Stripe::StripeObject
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_reader :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_reader :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(Integer) }
attr_reader :smart_tip_threshold
end
class Usd < Stripe::StripeObject
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_reader :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_reader :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(Integer) }
attr_reader :smart_tip_threshold
end
# Attribute for field aud
sig { returns(Aud) }
attr_reader :aud
# Attribute for field cad
sig { returns(Cad) }
attr_reader :cad
# Attribute for field chf
sig { returns(Chf) }
attr_reader :chf
# Attribute for field czk
sig { returns(Czk) }
attr_reader :czk
# Attribute for field dkk
sig { returns(Dkk) }
attr_reader :dkk
# Attribute for field eur
sig { returns(Eur) }
attr_reader :eur
# Attribute for field gbp
sig { returns(Gbp) }
attr_reader :gbp
# Attribute for field hkd
sig { returns(Hkd) }
attr_reader :hkd
# Attribute for field jpy
sig { returns(Jpy) }
attr_reader :jpy
# Attribute for field myr
sig { returns(Myr) }
attr_reader :myr
# Attribute for field nok
sig { returns(Nok) }
attr_reader :nok
# Attribute for field nzd
sig { returns(Nzd) }
attr_reader :nzd
# Attribute for field pln
sig { returns(Pln) }
attr_reader :pln
# Attribute for field sek
sig { returns(Sek) }
attr_reader :sek
# Attribute for field sgd
sig { returns(Sgd) }
attr_reader :sgd
# Attribute for field usd
sig { returns(Usd) }
attr_reader :usd
end
class VerifoneP400 < Stripe::StripeObject
# A File ID representing an image to display on the reader
sig { returns(T.any(String, Stripe::File)) }
attr_reader :splashscreen
end
class Wifi < Stripe::StripeObject
class EnterpriseEapPeap < Stripe::StripeObject
# A File ID representing a PEM file containing the server certificate
sig { returns(String) }
attr_reader :ca_certificate_file
# Password for connecting to the WiFi network
sig { returns(String) }
attr_reader :password
# Name of the WiFi network
sig { returns(String) }
attr_reader :ssid
# Username for connecting to the WiFi network
sig { returns(String) }
attr_reader :username
end
class EnterpriseEapTls < Stripe::StripeObject
# A File ID representing a PEM file containing the server certificate
sig { returns(String) }
attr_reader :ca_certificate_file
# A File ID representing a PEM file containing the client certificate
sig { returns(String) }
attr_reader :client_certificate_file
# A File ID representing a PEM file containing the client RSA private key
sig { returns(String) }
attr_reader :private_key_file
# Password for the private key file
sig { returns(String) }
attr_reader :private_key_file_password
# Name of the WiFi network
sig { returns(String) }
attr_reader :ssid
end
class PersonalPsk < Stripe::StripeObject
# Password for connecting to the WiFi network
sig { returns(String) }
attr_reader :password
# Name of the WiFi network
sig { returns(String) }
attr_reader :ssid
end
# Attribute for field enterprise_eap_peap
sig { returns(EnterpriseEapPeap) }
attr_reader :enterprise_eap_peap
# Attribute for field enterprise_eap_tls
sig { returns(EnterpriseEapTls) }
attr_reader :enterprise_eap_tls
# Attribute for field personal_psk
sig { returns(PersonalPsk) }
attr_reader :personal_psk
# Security type of the WiFi network. The hash with the corresponding name contains the credentials for this security type.
sig { returns(String) }
attr_reader :type
end
# Attribute for field bbpos_wisepos_e
sig { returns(BbposWiseposE) }
attr_reader :bbpos_wisepos_e
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Whether this Configuration is the default for your account
sig { returns(T.nilable(T::Boolean)) }
attr_reader :is_account_default
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# String indicating the name of the Configuration object, set by the user
sig { returns(T.nilable(String)) }
attr_reader :name
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Attribute for field offline
sig { returns(Offline) }
attr_reader :offline
# Attribute for field reboot_window
sig { returns(RebootWindow) }
attr_reader :reboot_window
# Attribute for field stripe_s700
sig { returns(StripeS700) }
attr_reader :stripe_s700
# Attribute for field tipping
sig { returns(Tipping) }
attr_reader :tipping
# Attribute for field verifone_p400
sig { returns(VerifoneP400) }
attr_reader :verifone_p400
# Attribute for field wifi
sig { returns(Wifi) }
attr_reader :wifi
# Always true for a deleted object
sig { returns(T::Boolean) }
attr_reader :deleted
class DeleteParams < Stripe::RequestParams; end
class UpdateParams < Stripe::RequestParams
class BbposWiseposE < Stripe::RequestParams
# A File ID representing an image to display on the reader
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :splashscreen
sig { params(splashscreen: T.nilable(T.nilable(String))).void }
def initialize(splashscreen: nil); end
end
class Offline < Stripe::RequestParams
# Determines whether to allow transactions to be collected while reader is offline. Defaults to false.
sig { returns(T::Boolean) }
attr_accessor :enabled
sig { params(enabled: T::Boolean).void }
def initialize(enabled: nil); end
end
class RebootWindow < Stripe::RequestParams
# Integer between 0 to 23 that represents the end hour of the reboot time window. The value must be different than the start_hour.
sig { returns(Integer) }
attr_accessor :end_hour
# Integer between 0 to 23 that represents the start hour of the reboot time window.
sig { returns(Integer) }
attr_accessor :start_hour
sig { params(end_hour: Integer, start_hour: Integer).void }
def initialize(end_hour: nil, start_hour: nil); end
end
class StripeS700 < Stripe::RequestParams
# A File ID representing an image you would like displayed on the reader.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :splashscreen
sig { params(splashscreen: T.nilable(T.nilable(String))).void }
def initialize(splashscreen: nil); end
end
class Tipping < Stripe::RequestParams
class Aud < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Cad < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Chf < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Czk < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Dkk < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Eur < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Gbp < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Hkd < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Jpy < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Myr < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Nok < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Nzd < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Pln < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Sek < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Sgd < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Usd < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
# Tipping configuration for AUD
sig { returns(T.nilable(::Stripe::Terminal::Configuration::UpdateParams::Tipping::Aud)) }
attr_accessor :aud
# Tipping configuration for CAD
sig { returns(T.nilable(::Stripe::Terminal::Configuration::UpdateParams::Tipping::Cad)) }
attr_accessor :cad
# Tipping configuration for CHF
sig { returns(T.nilable(::Stripe::Terminal::Configuration::UpdateParams::Tipping::Chf)) }
attr_accessor :chf
# Tipping configuration for CZK
sig { returns(T.nilable(::Stripe::Terminal::Configuration::UpdateParams::Tipping::Czk)) }
attr_accessor :czk
# Tipping configuration for DKK
sig { returns(T.nilable(::Stripe::Terminal::Configuration::UpdateParams::Tipping::Dkk)) }
attr_accessor :dkk
# Tipping configuration for EUR
sig { returns(T.nilable(::Stripe::Terminal::Configuration::UpdateParams::Tipping::Eur)) }
attr_accessor :eur
# Tipping configuration for GBP
sig { returns(T.nilable(::Stripe::Terminal::Configuration::UpdateParams::Tipping::Gbp)) }
attr_accessor :gbp
# Tipping configuration for HKD
sig { returns(T.nilable(::Stripe::Terminal::Configuration::UpdateParams::Tipping::Hkd)) }
attr_accessor :hkd
# Tipping configuration for JPY
sig { returns(T.nilable(::Stripe::Terminal::Configuration::UpdateParams::Tipping::Jpy)) }
attr_accessor :jpy
# Tipping configuration for MYR
sig { returns(T.nilable(::Stripe::Terminal::Configuration::UpdateParams::Tipping::Myr)) }
attr_accessor :myr
# Tipping configuration for NOK
sig { returns(T.nilable(::Stripe::Terminal::Configuration::UpdateParams::Tipping::Nok)) }
attr_accessor :nok
# Tipping configuration for NZD
sig { returns(T.nilable(::Stripe::Terminal::Configuration::UpdateParams::Tipping::Nzd)) }
attr_accessor :nzd
# Tipping configuration for PLN
sig { returns(T.nilable(::Stripe::Terminal::Configuration::UpdateParams::Tipping::Pln)) }
attr_accessor :pln
# Tipping configuration for SEK
sig { returns(T.nilable(::Stripe::Terminal::Configuration::UpdateParams::Tipping::Sek)) }
attr_accessor :sek
# Tipping configuration for SGD
sig { returns(T.nilable(::Stripe::Terminal::Configuration::UpdateParams::Tipping::Sgd)) }
attr_accessor :sgd
# Tipping configuration for USD
sig { returns(T.nilable(::Stripe::Terminal::Configuration::UpdateParams::Tipping::Usd)) }
attr_accessor :usd
sig {
params(aud: T.nilable(::Stripe::Terminal::Configuration::UpdateParams::Tipping::Aud), cad: T.nilable(::Stripe::Terminal::Configuration::UpdateParams::Tipping::Cad), chf: T.nilable(::Stripe::Terminal::Configuration::UpdateParams::Tipping::Chf), czk: T.nilable(::Stripe::Terminal::Configuration::UpdateParams::Tipping::Czk), dkk: T.nilable(::Stripe::Terminal::Configuration::UpdateParams::Tipping::Dkk), eur: T.nilable(::Stripe::Terminal::Configuration::UpdateParams::Tipping::Eur), gbp: T.nilable(::Stripe::Terminal::Configuration::UpdateParams::Tipping::Gbp), hkd: T.nilable(::Stripe::Terminal::Configuration::UpdateParams::Tipping::Hkd), jpy: T.nilable(::Stripe::Terminal::Configuration::UpdateParams::Tipping::Jpy), myr: T.nilable(::Stripe::Terminal::Configuration::UpdateParams::Tipping::Myr), nok: T.nilable(::Stripe::Terminal::Configuration::UpdateParams::Tipping::Nok), nzd: T.nilable(::Stripe::Terminal::Configuration::UpdateParams::Tipping::Nzd), pln: T.nilable(::Stripe::Terminal::Configuration::UpdateParams::Tipping::Pln), sek: T.nilable(::Stripe::Terminal::Configuration::UpdateParams::Tipping::Sek), sgd: T.nilable(::Stripe::Terminal::Configuration::UpdateParams::Tipping::Sgd), usd: T.nilable(::Stripe::Terminal::Configuration::UpdateParams::Tipping::Usd)).void
}
def initialize(
aud: nil,
cad: nil,
chf: nil,
czk: nil,
dkk: nil,
eur: nil,
gbp: nil,
hkd: nil,
jpy: nil,
myr: nil,
nok: nil,
nzd: nil,
pln: nil,
sek: nil,
sgd: nil,
usd: nil
); end
end
class VerifoneP400 < Stripe::RequestParams
# A File ID representing an image you would like displayed on the reader.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :splashscreen
sig { params(splashscreen: T.nilable(T.nilable(String))).void }
def initialize(splashscreen: nil); end
end
class Wifi < Stripe::RequestParams
class EnterpriseEapPeap < Stripe::RequestParams
# A File ID representing a PEM file containing the server certificate
sig { returns(T.nilable(String)) }
attr_accessor :ca_certificate_file
# Password for connecting to the WiFi network
sig { returns(String) }
attr_accessor :password
# Name of the WiFi network
sig { returns(String) }
attr_accessor :ssid
# Username for connecting to the WiFi network
sig { returns(String) }
attr_accessor :username
sig {
params(ca_certificate_file: T.nilable(String), password: String, ssid: String, username: String).void
}
def initialize(ca_certificate_file: nil, password: nil, ssid: nil, username: nil); end
end
class EnterpriseEapTls < Stripe::RequestParams
# A File ID representing a PEM file containing the server certificate
sig { returns(T.nilable(String)) }
attr_accessor :ca_certificate_file
# A File ID representing a PEM file containing the client certificate
sig { returns(String) }
attr_accessor :client_certificate_file
# A File ID representing a PEM file containing the client RSA private key
sig { returns(String) }
attr_accessor :private_key_file
# Password for the private key file
sig { returns(T.nilable(String)) }
attr_accessor :private_key_file_password
# Name of the WiFi network
sig { returns(String) }
attr_accessor :ssid
sig {
params(ca_certificate_file: T.nilable(String), client_certificate_file: String, private_key_file: String, private_key_file_password: T.nilable(String), ssid: String).void
}
def initialize(
ca_certificate_file: nil,
client_certificate_file: nil,
private_key_file: nil,
private_key_file_password: nil,
ssid: nil
); end
end
class PersonalPsk < Stripe::RequestParams
# Password for connecting to the WiFi network
sig { returns(String) }
attr_accessor :password
# Name of the WiFi network
sig { returns(String) }
attr_accessor :ssid
sig { params(password: String, ssid: String).void }
def initialize(password: nil, ssid: nil); end
end
# Credentials for a WPA-Enterprise WiFi network using the EAP-PEAP authentication method.
sig {
returns(T.nilable(::Stripe::Terminal::Configuration::UpdateParams::Wifi::EnterpriseEapPeap))
}
attr_accessor :enterprise_eap_peap
# Credentials for a WPA-Enterprise WiFi network using the EAP-TLS authentication method.
sig {
returns(T.nilable(::Stripe::Terminal::Configuration::UpdateParams::Wifi::EnterpriseEapTls))
}
attr_accessor :enterprise_eap_tls
# Credentials for a WPA-Personal WiFi network.
sig {
returns(T.nilable(::Stripe::Terminal::Configuration::UpdateParams::Wifi::PersonalPsk))
}
attr_accessor :personal_psk
# Security type of the WiFi network. Fill out the hash with the corresponding name to provide the set of credentials for this security type.
sig { returns(String) }
attr_accessor :type
sig {
params(enterprise_eap_peap: T.nilable(::Stripe::Terminal::Configuration::UpdateParams::Wifi::EnterpriseEapPeap), enterprise_eap_tls: T.nilable(::Stripe::Terminal::Configuration::UpdateParams::Wifi::EnterpriseEapTls), personal_psk: T.nilable(::Stripe::Terminal::Configuration::UpdateParams::Wifi::PersonalPsk), type: String).void
}
def initialize(
enterprise_eap_peap: nil,
enterprise_eap_tls: nil,
personal_psk: nil,
type: nil
); end
end
# An object containing device type specific settings for BBPOS WisePOS E readers
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Terminal::Configuration::UpdateParams::BbposWiseposE))))
}
attr_accessor :bbpos_wisepos_e
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Name of the configuration
sig { returns(T.nilable(String)) }
attr_accessor :name
# Configurations for collecting transactions offline.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Terminal::Configuration::UpdateParams::Offline))))
}
attr_accessor :offline
# Reboot time settings for readers that support customized reboot time configuration.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Terminal::Configuration::UpdateParams::RebootWindow))))
}
attr_accessor :reboot_window
# An object containing device type specific settings for Stripe S700 readers
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Terminal::Configuration::UpdateParams::StripeS700))))
}
attr_accessor :stripe_s700
# Tipping configurations for readers supporting on-reader tips
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Terminal::Configuration::UpdateParams::Tipping))))
}
attr_accessor :tipping
# An object containing device type specific settings for Verifone P400 readers
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Terminal::Configuration::UpdateParams::VerifoneP400))))
}
attr_accessor :verifone_p400
# Configurations for connecting to a WiFi network.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Terminal::Configuration::UpdateParams::Wifi))))
}
attr_accessor :wifi
sig {
params(bbpos_wisepos_e: T.nilable(T.nilable(T.any(String, ::Stripe::Terminal::Configuration::UpdateParams::BbposWiseposE))), expand: T.nilable(T::Array[String]), name: T.nilable(String), offline: T.nilable(T.nilable(T.any(String, ::Stripe::Terminal::Configuration::UpdateParams::Offline))), reboot_window: T.nilable(T.nilable(T.any(String, ::Stripe::Terminal::Configuration::UpdateParams::RebootWindow))), stripe_s700: T.nilable(T.nilable(T.any(String, ::Stripe::Terminal::Configuration::UpdateParams::StripeS700))), tipping: T.nilable(T.nilable(T.any(String, ::Stripe::Terminal::Configuration::UpdateParams::Tipping))), verifone_p400: T.nilable(T.nilable(T.any(String, ::Stripe::Terminal::Configuration::UpdateParams::VerifoneP400))), wifi: T.nilable(T.nilable(T.any(String, ::Stripe::Terminal::Configuration::UpdateParams::Wifi)))).void
}
def initialize(
bbpos_wisepos_e: nil,
expand: nil,
name: nil,
offline: nil,
reboot_window: nil,
stripe_s700: nil,
tipping: nil,
verifone_p400: nil,
wifi: nil
); end
end
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# if present, only return the account default or non-default configurations.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :is_account_default
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), is_account_default: T.nilable(T::Boolean), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
ending_before: nil,
expand: nil,
is_account_default: nil,
limit: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class BbposWiseposE < Stripe::RequestParams
# A File ID representing an image to display on the reader
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :splashscreen
sig { params(splashscreen: T.nilable(T.nilable(String))).void }
def initialize(splashscreen: nil); end
end
class Offline < Stripe::RequestParams
# Determines whether to allow transactions to be collected while reader is offline. Defaults to false.
sig { returns(T::Boolean) }
attr_accessor :enabled
sig { params(enabled: T::Boolean).void }
def initialize(enabled: nil); end
end
class RebootWindow < Stripe::RequestParams
# Integer between 0 to 23 that represents the end hour of the reboot time window. The value must be different than the start_hour.
sig { returns(Integer) }
attr_accessor :end_hour
# Integer between 0 to 23 that represents the start hour of the reboot time window.
sig { returns(Integer) }
attr_accessor :start_hour
sig { params(end_hour: Integer, start_hour: Integer).void }
def initialize(end_hour: nil, start_hour: nil); end
end
class StripeS700 < Stripe::RequestParams
# A File ID representing an image you would like displayed on the reader.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :splashscreen
sig { params(splashscreen: T.nilable(T.nilable(String))).void }
def initialize(splashscreen: nil); end
end
class Tipping < Stripe::RequestParams
class Aud < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Cad < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Chf < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Czk < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Dkk < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Eur < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Gbp < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Hkd < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Jpy < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Myr < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Nok < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Nzd < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Pln < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Sek < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Sgd < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Usd < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
# Tipping configuration for AUD
sig { returns(T.nilable(::Stripe::Terminal::Configuration::CreateParams::Tipping::Aud)) }
attr_accessor :aud
# Tipping configuration for CAD
sig { returns(T.nilable(::Stripe::Terminal::Configuration::CreateParams::Tipping::Cad)) }
attr_accessor :cad
# Tipping configuration for CHF
sig { returns(T.nilable(::Stripe::Terminal::Configuration::CreateParams::Tipping::Chf)) }
attr_accessor :chf
# Tipping configuration for CZK
sig { returns(T.nilable(::Stripe::Terminal::Configuration::CreateParams::Tipping::Czk)) }
attr_accessor :czk
# Tipping configuration for DKK
sig { returns(T.nilable(::Stripe::Terminal::Configuration::CreateParams::Tipping::Dkk)) }
attr_accessor :dkk
# Tipping configuration for EUR
sig { returns(T.nilable(::Stripe::Terminal::Configuration::CreateParams::Tipping::Eur)) }
attr_accessor :eur
# Tipping configuration for GBP
sig { returns(T.nilable(::Stripe::Terminal::Configuration::CreateParams::Tipping::Gbp)) }
attr_accessor :gbp
# Tipping configuration for HKD
sig { returns(T.nilable(::Stripe::Terminal::Configuration::CreateParams::Tipping::Hkd)) }
attr_accessor :hkd
# Tipping configuration for JPY
sig { returns(T.nilable(::Stripe::Terminal::Configuration::CreateParams::Tipping::Jpy)) }
attr_accessor :jpy
# Tipping configuration for MYR
sig { returns(T.nilable(::Stripe::Terminal::Configuration::CreateParams::Tipping::Myr)) }
attr_accessor :myr
# Tipping configuration for NOK
sig { returns(T.nilable(::Stripe::Terminal::Configuration::CreateParams::Tipping::Nok)) }
attr_accessor :nok
# Tipping configuration for NZD
sig { returns(T.nilable(::Stripe::Terminal::Configuration::CreateParams::Tipping::Nzd)) }
attr_accessor :nzd
# Tipping configuration for PLN
sig { returns(T.nilable(::Stripe::Terminal::Configuration::CreateParams::Tipping::Pln)) }
attr_accessor :pln
# Tipping configuration for SEK
sig { returns(T.nilable(::Stripe::Terminal::Configuration::CreateParams::Tipping::Sek)) }
attr_accessor :sek
# Tipping configuration for SGD
sig { returns(T.nilable(::Stripe::Terminal::Configuration::CreateParams::Tipping::Sgd)) }
attr_accessor :sgd
# Tipping configuration for USD
sig { returns(T.nilable(::Stripe::Terminal::Configuration::CreateParams::Tipping::Usd)) }
attr_accessor :usd
sig {
params(aud: T.nilable(::Stripe::Terminal::Configuration::CreateParams::Tipping::Aud), cad: T.nilable(::Stripe::Terminal::Configuration::CreateParams::Tipping::Cad), chf: T.nilable(::Stripe::Terminal::Configuration::CreateParams::Tipping::Chf), czk: T.nilable(::Stripe::Terminal::Configuration::CreateParams::Tipping::Czk), dkk: T.nilable(::Stripe::Terminal::Configuration::CreateParams::Tipping::Dkk), eur: T.nilable(::Stripe::Terminal::Configuration::CreateParams::Tipping::Eur), gbp: T.nilable(::Stripe::Terminal::Configuration::CreateParams::Tipping::Gbp), hkd: T.nilable(::Stripe::Terminal::Configuration::CreateParams::Tipping::Hkd), jpy: T.nilable(::Stripe::Terminal::Configuration::CreateParams::Tipping::Jpy), myr: T.nilable(::Stripe::Terminal::Configuration::CreateParams::Tipping::Myr), nok: T.nilable(::Stripe::Terminal::Configuration::CreateParams::Tipping::Nok), nzd: T.nilable(::Stripe::Terminal::Configuration::CreateParams::Tipping::Nzd), pln: T.nilable(::Stripe::Terminal::Configuration::CreateParams::Tipping::Pln), sek: T.nilable(::Stripe::Terminal::Configuration::CreateParams::Tipping::Sek), sgd: T.nilable(::Stripe::Terminal::Configuration::CreateParams::Tipping::Sgd), usd: T.nilable(::Stripe::Terminal::Configuration::CreateParams::Tipping::Usd)).void
}
def initialize(
aud: nil,
cad: nil,
chf: nil,
czk: nil,
dkk: nil,
eur: nil,
gbp: nil,
hkd: nil,
jpy: nil,
myr: nil,
nok: nil,
nzd: nil,
pln: nil,
sek: nil,
sgd: nil,
usd: nil
); end
end
class VerifoneP400 < Stripe::RequestParams
# A File ID representing an image you would like displayed on the reader.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :splashscreen
sig { params(splashscreen: T.nilable(T.nilable(String))).void }
def initialize(splashscreen: nil); end
end
class Wifi < Stripe::RequestParams
class EnterpriseEapPeap < Stripe::RequestParams
# A File ID representing a PEM file containing the server certificate
sig { returns(T.nilable(String)) }
attr_accessor :ca_certificate_file
# Password for connecting to the WiFi network
sig { returns(String) }
attr_accessor :password
# Name of the WiFi network
sig { returns(String) }
attr_accessor :ssid
# Username for connecting to the WiFi network
sig { returns(String) }
attr_accessor :username
sig {
params(ca_certificate_file: T.nilable(String), password: String, ssid: String, username: String).void
}
def initialize(ca_certificate_file: nil, password: nil, ssid: nil, username: nil); end
end
class EnterpriseEapTls < Stripe::RequestParams
# A File ID representing a PEM file containing the server certificate
sig { returns(T.nilable(String)) }
attr_accessor :ca_certificate_file
# A File ID representing a PEM file containing the client certificate
sig { returns(String) }
attr_accessor :client_certificate_file
# A File ID representing a PEM file containing the client RSA private key
sig { returns(String) }
attr_accessor :private_key_file
# Password for the private key file
sig { returns(T.nilable(String)) }
attr_accessor :private_key_file_password
# Name of the WiFi network
sig { returns(String) }
attr_accessor :ssid
sig {
params(ca_certificate_file: T.nilable(String), client_certificate_file: String, private_key_file: String, private_key_file_password: T.nilable(String), ssid: String).void
}
def initialize(
ca_certificate_file: nil,
client_certificate_file: nil,
private_key_file: nil,
private_key_file_password: nil,
ssid: nil
); end
end
class PersonalPsk < Stripe::RequestParams
# Password for connecting to the WiFi network
sig { returns(String) }
attr_accessor :password
# Name of the WiFi network
sig { returns(String) }
attr_accessor :ssid
sig { params(password: String, ssid: String).void }
def initialize(password: nil, ssid: nil); end
end
# Credentials for a WPA-Enterprise WiFi network using the EAP-PEAP authentication method.
sig {
returns(T.nilable(::Stripe::Terminal::Configuration::CreateParams::Wifi::EnterpriseEapPeap))
}
attr_accessor :enterprise_eap_peap
# Credentials for a WPA-Enterprise WiFi network using the EAP-TLS authentication method.
sig {
returns(T.nilable(::Stripe::Terminal::Configuration::CreateParams::Wifi::EnterpriseEapTls))
}
attr_accessor :enterprise_eap_tls
# Credentials for a WPA-Personal WiFi network.
sig {
returns(T.nilable(::Stripe::Terminal::Configuration::CreateParams::Wifi::PersonalPsk))
}
attr_accessor :personal_psk
# Security type of the WiFi network. Fill out the hash with the corresponding name to provide the set of credentials for this security type.
sig { returns(String) }
attr_accessor :type
sig {
params(enterprise_eap_peap: T.nilable(::Stripe::Terminal::Configuration::CreateParams::Wifi::EnterpriseEapPeap), enterprise_eap_tls: T.nilable(::Stripe::Terminal::Configuration::CreateParams::Wifi::EnterpriseEapTls), personal_psk: T.nilable(::Stripe::Terminal::Configuration::CreateParams::Wifi::PersonalPsk), type: String).void
}
def initialize(
enterprise_eap_peap: nil,
enterprise_eap_tls: nil,
personal_psk: nil,
type: nil
); end
end
# An object containing device type specific settings for BBPOS WisePOS E readers
sig { returns(T.nilable(::Stripe::Terminal::Configuration::CreateParams::BbposWiseposE)) }
attr_accessor :bbpos_wisepos_e
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Name of the configuration
sig { returns(T.nilable(String)) }
attr_accessor :name
# Configurations for collecting transactions offline.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Terminal::Configuration::CreateParams::Offline))))
}
attr_accessor :offline
# Reboot time settings for readers that support customized reboot time configuration.
sig { returns(T.nilable(::Stripe::Terminal::Configuration::CreateParams::RebootWindow)) }
attr_accessor :reboot_window
# An object containing device type specific settings for Stripe S700 readers
sig { returns(T.nilable(::Stripe::Terminal::Configuration::CreateParams::StripeS700)) }
attr_accessor :stripe_s700
# Tipping configurations for readers supporting on-reader tips
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Terminal::Configuration::CreateParams::Tipping))))
}
attr_accessor :tipping
# An object containing device type specific settings for Verifone P400 readers
sig { returns(T.nilable(::Stripe::Terminal::Configuration::CreateParams::VerifoneP400)) }
attr_accessor :verifone_p400
# Configurations for connecting to a WiFi network.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Terminal::Configuration::CreateParams::Wifi))))
}
attr_accessor :wifi
sig {
params(bbpos_wisepos_e: T.nilable(::Stripe::Terminal::Configuration::CreateParams::BbposWiseposE), expand: T.nilable(T::Array[String]), name: T.nilable(String), offline: T.nilable(T.nilable(T.any(String, ::Stripe::Terminal::Configuration::CreateParams::Offline))), reboot_window: T.nilable(::Stripe::Terminal::Configuration::CreateParams::RebootWindow), stripe_s700: T.nilable(::Stripe::Terminal::Configuration::CreateParams::StripeS700), tipping: T.nilable(T.nilable(T.any(String, ::Stripe::Terminal::Configuration::CreateParams::Tipping))), verifone_p400: T.nilable(::Stripe::Terminal::Configuration::CreateParams::VerifoneP400), wifi: T.nilable(T.nilable(T.any(String, ::Stripe::Terminal::Configuration::CreateParams::Wifi)))).void
}
def initialize(
bbpos_wisepos_e: nil,
expand: nil,
name: nil,
offline: nil,
reboot_window: nil,
stripe_s700: nil,
tipping: nil,
verifone_p400: nil,
wifi: nil
); end
end
# Creates a new Configuration object.
sig {
params(params: T.any(::Stripe::Terminal::Configuration::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Configuration)
}
def self.create(params = {}, opts = {}); end
# Deletes a Configuration object.
sig {
params(configuration: String, params: T.any(::Stripe::Terminal::Configuration::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Configuration)
}
def self.delete(configuration, params = {}, opts = {}); end
# Deletes a Configuration object.
sig {
params(params: T.any(::Stripe::Terminal::Configuration::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Configuration)
}
def delete(params = {}, opts = {}); end
# Returns a list of Configuration objects.
sig {
params(params: T.any(::Stripe::Terminal::Configuration::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Updates a new Configuration object.
sig {
params(configuration: String, params: T.any(::Stripe::Terminal::Configuration::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Configuration)
}
def self.update(configuration, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Terminal
# A Connection Token is used by the Stripe Terminal SDK to connect to a reader.
#
# Related guide: [Fleet management](https://stripe.com/docs/terminal/fleet/locations)
class ConnectionToken < APIResource
# The id of the location that this connection token is scoped to. Note that location scoping only applies to internet-connected readers. For more details, see [the docs on scoping connection tokens](https://docs.stripe.com/terminal/fleet/locations-and-zones?dashboard-or-api=api#connection-tokens).
sig { returns(String) }
attr_reader :location
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Your application should pass this token to the Stripe Terminal SDK.
sig { returns(String) }
attr_reader :secret
class CreateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The id of the location that this connection token is scoped to. If specified the connection token will only be usable with readers assigned to that location, otherwise the connection token will be usable with all readers. Note that location scoping only applies to internet-connected readers. For more details, see [the docs on scoping connection tokens](https://docs.stripe.com/terminal/fleet/locations-and-zones?dashboard-or-api=api#connection-tokens).
sig { returns(T.nilable(String)) }
attr_accessor :location
sig { params(expand: T.nilable(T::Array[String]), location: T.nilable(String)).void }
def initialize(expand: nil, location: nil); end
end
# To connect to a reader the Stripe Terminal SDK needs to retrieve a short-lived connection token from Stripe, proxied through your server. On your backend, add an endpoint that creates and returns a connection token.
sig {
params(params: T.any(::Stripe::Terminal::ConnectionToken::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::ConnectionToken)
}
def self.create(params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Terminal
# A Location represents a grouping of readers.
#
# Related guide: [Fleet management](https://stripe.com/docs/terminal/fleet/locations)
class Location < APIResource
class Address < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Attribute for field address
sig { returns(Address) }
attr_reader :address
# The ID of a configuration that will be used to customize all readers in this location.
sig { returns(String) }
attr_reader :configuration_overrides
# The display name of the location.
sig { returns(String) }
attr_reader :display_name
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# 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.
sig { returns(T::Hash[String, String]) }
attr_reader :metadata
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Always true for a deleted object
sig { returns(T::Boolean) }
attr_reader :deleted
class DeleteParams < Stripe::RequestParams; end
class UpdateParams < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# The full address of the location. You can't change the location's `country`. If you need to modify the `country` field, create a new `Location` object and re-register any existing readers to that location.
sig { returns(T.nilable(::Stripe::Terminal::Location::UpdateParams::Address)) }
attr_accessor :address
# The ID of a configuration that will be used to customize all readers in this location.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :configuration_overrides
# A name for the location.
sig { returns(T.nilable(String)) }
attr_accessor :display_name
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
sig {
params(address: T.nilable(::Stripe::Terminal::Location::UpdateParams::Address), configuration_overrides: T.nilable(T.nilable(String)), display_name: T.nilable(String), expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String])))).void
}
def initialize(
address: nil,
configuration_overrides: nil,
display_name: nil,
expand: nil,
metadata: nil
); end
end
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
class CreateParams < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(String) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: String, line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# The full address of the location.
sig { returns(::Stripe::Terminal::Location::CreateParams::Address) }
attr_accessor :address
# The ID of a configuration that will be used to customize all readers in this location.
sig { returns(T.nilable(String)) }
attr_accessor :configuration_overrides
# A name for the location. Maximum length is 1000 characters.
sig { returns(String) }
attr_accessor :display_name
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
sig {
params(address: ::Stripe::Terminal::Location::CreateParams::Address, configuration_overrides: T.nilable(String), display_name: String, expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String])))).void
}
def initialize(
address: nil,
configuration_overrides: nil,
display_name: nil,
expand: nil,
metadata: nil
); end
end
# Creates a new Location object.
# For further details, including which address fields are required in each country, see the [Manage locations](https://docs.stripe.com/docs/terminal/fleet/locations) guide.
sig {
params(params: T.any(::Stripe::Terminal::Location::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Location)
}
def self.create(params = {}, opts = {}); end
# Deletes a Location object.
sig {
params(location: String, params: T.any(::Stripe::Terminal::Location::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Location)
}
def self.delete(location, params = {}, opts = {}); end
# Deletes a Location object.
sig {
params(params: T.any(::Stripe::Terminal::Location::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Location)
}
def delete(params = {}, opts = {}); end
# Returns a list of Location objects.
sig {
params(params: T.any(::Stripe::Terminal::Location::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Updates a Location object by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
sig {
params(location: String, params: T.any(::Stripe::Terminal::Location::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Location)
}
def self.update(location, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Terminal
# A Reader represents a physical device for accepting payment details.
#
# Related guide: [Connecting to a reader](https://stripe.com/docs/terminal/payments/connect-reader)
class Reader < APIResource
class Action < Stripe::StripeObject
class CollectInputs < Stripe::StripeObject
class Input < Stripe::StripeObject
class CustomText < Stripe::StripeObject
# Customize the default description for this input
sig { returns(T.nilable(String)) }
attr_reader :description
# Customize the default label for this input's skip button
sig { returns(T.nilable(String)) }
attr_reader :skip_button
# Customize the default label for this input's submit button
sig { returns(T.nilable(String)) }
attr_reader :submit_button
# Customize the default title for this input
sig { returns(T.nilable(String)) }
attr_reader :title
end
class Email < Stripe::StripeObject
# The collected email address
sig { returns(T.nilable(String)) }
attr_reader :value
end
class Numeric < Stripe::StripeObject
# The collected number
sig { returns(T.nilable(String)) }
attr_reader :value
end
class Phone < Stripe::StripeObject
# The collected phone number
sig { returns(T.nilable(String)) }
attr_reader :value
end
class Selection < Stripe::StripeObject
class Choice < Stripe::StripeObject
# The id to be selected
sig { returns(T.nilable(String)) }
attr_reader :id
# The button style for the choice
sig { returns(T.nilable(String)) }
attr_reader :style
# The text to be selected
sig { returns(String) }
attr_reader :text
end
# List of possible choices to be selected
sig { returns(T::Array[Choice]) }
attr_reader :choices
# The id of the selected choice
sig { returns(T.nilable(String)) }
attr_reader :id
# The text of the selected choice
sig { returns(T.nilable(String)) }
attr_reader :text
end
class Signature < Stripe::StripeObject
# The File ID of a collected signature image
sig { returns(T.nilable(String)) }
attr_reader :value
end
class Text < Stripe::StripeObject
# The collected text value
sig { returns(T.nilable(String)) }
attr_reader :value
end
class Toggle < Stripe::StripeObject
# The toggle's default value
sig { returns(T.nilable(String)) }
attr_reader :default_value
# The toggle's description text
sig { returns(T.nilable(String)) }
attr_reader :description
# The toggle's title text
sig { returns(T.nilable(String)) }
attr_reader :title
# The toggle's collected value
sig { returns(T.nilable(String)) }
attr_reader :value
end
# Default text of input being collected.
sig { returns(T.nilable(CustomText)) }
attr_reader :custom_text
# Information about a email being collected using a reader
sig { returns(Email) }
attr_reader :email
# Information about a number being collected using a reader
sig { returns(Numeric) }
attr_reader :numeric
# Information about a phone number being collected using a reader
sig { returns(Phone) }
attr_reader :phone
# Indicate that this input is required, disabling the skip button.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :required
# Information about a selection being collected using a reader
sig { returns(Selection) }
attr_reader :selection
# Information about a signature being collected using a reader
sig { returns(Signature) }
attr_reader :signature
# Indicate that this input was skipped by the user.
sig { returns(T::Boolean) }
attr_reader :skipped
# Information about text being collected using a reader
sig { returns(Text) }
attr_reader :text
# List of toggles being collected. Values are present if collection is complete.
sig { returns(T.nilable(T::Array[Toggle])) }
attr_reader :toggles
# Type of input being collected.
sig { returns(String) }
attr_reader :type
end
# List of inputs to be collected.
sig { returns(T::Array[Input]) }
attr_reader :inputs
# 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.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
end
class CollectPaymentMethod < Stripe::StripeObject
class CollectConfig < Stripe::StripeObject
class Tipping < Stripe::StripeObject
# Amount used to calculate tip suggestions on tipping selection screen for this transaction. Must be a positive integer in the smallest currency unit (e.g., 100 cents to represent $1.00 or 100 to represent ¥100, a zero-decimal currency).
sig { returns(Integer) }
attr_reader :amount_eligible
end
# Enable customer initiated cancellation when processing this payment.
sig { returns(T::Boolean) }
attr_reader :enable_customer_cancellation
# Override showing a tipping selection screen on this transaction.
sig { returns(T::Boolean) }
attr_reader :skip_tipping
# Represents a per-transaction tipping configuration
sig { returns(Tipping) }
attr_reader :tipping
end
# Account the payment intent belongs to.
sig { returns(String) }
attr_reader :account
# Represents a per-transaction override of a reader configuration
sig { returns(CollectConfig) }
attr_reader :collect_config
# Most recent PaymentIntent processed by the reader.
sig { returns(T.any(String, Stripe::PaymentIntent)) }
attr_reader :payment_intent
# PaymentMethod objects represent your customer's payment instruments.
# You can use them with [PaymentIntents](https://stripe.com/docs/payments/payment-intents) to collect payments or save them to
# Customer objects to store instrument details for future payments.
#
# Related guides: [Payment Methods](https://stripe.com/docs/payments/payment-methods) and [More Payment Scenarios](https://stripe.com/docs/payments/more-payment-scenarios).
sig { returns(Stripe::PaymentMethod) }
attr_reader :payment_method
end
class ConfirmPaymentIntent < Stripe::StripeObject
class ConfirmConfig < Stripe::StripeObject
# If the customer does not abandon authenticating the payment, they will be redirected to this specified URL after completion.
sig { returns(String) }
attr_reader :return_url
end
# Account the payment intent belongs to.
sig { returns(String) }
attr_reader :account
# Represents a per-transaction override of a reader configuration
sig { returns(ConfirmConfig) }
attr_reader :confirm_config
# Most recent PaymentIntent processed by the reader.
sig { returns(T.any(String, Stripe::PaymentIntent)) }
attr_reader :payment_intent
end
class ProcessPaymentIntent < Stripe::StripeObject
class ProcessConfig < Stripe::StripeObject
class Tipping < Stripe::StripeObject
# Amount used to calculate tip suggestions on tipping selection screen for this transaction. Must be a positive integer in the smallest currency unit (e.g., 100 cents to represent $1.00 or 100 to represent ¥100, a zero-decimal currency).
sig { returns(Integer) }
attr_reader :amount_eligible
end
# Enable customer initiated cancellation when processing this payment.
sig { returns(T::Boolean) }
attr_reader :enable_customer_cancellation
# If the customer does not abandon authenticating the payment, they will be redirected to this specified URL after completion.
sig { returns(String) }
attr_reader :return_url
# Override showing a tipping selection screen on this transaction.
sig { returns(T::Boolean) }
attr_reader :skip_tipping
# Represents a per-transaction tipping configuration
sig { returns(Tipping) }
attr_reader :tipping
end
# Account the payment intent belongs to.
sig { returns(String) }
attr_reader :account
# Most recent PaymentIntent processed by the reader.
sig { returns(T.any(String, Stripe::PaymentIntent)) }
attr_reader :payment_intent
# Represents a per-transaction override of a reader configuration
sig { returns(ProcessConfig) }
attr_reader :process_config
end
class ProcessSetupIntent < Stripe::StripeObject
class ProcessConfig < Stripe::StripeObject
# Enable customer initiated cancellation when processing this SetupIntent.
sig { returns(T::Boolean) }
attr_reader :enable_customer_cancellation
end
# ID of a card PaymentMethod generated from the card_present PaymentMethod that may be attached to a Customer for future transactions. Only present if it was possible to generate a card PaymentMethod.
sig { returns(String) }
attr_reader :generated_card
# Represents a per-setup override of a reader configuration
sig { returns(ProcessConfig) }
attr_reader :process_config
# Most recent SetupIntent processed by the reader.
sig { returns(T.any(String, Stripe::SetupIntent)) }
attr_reader :setup_intent
end
class RefundPayment < Stripe::StripeObject
class RefundPaymentConfig < Stripe::StripeObject
# Enable customer initiated cancellation when refunding this payment.
sig { returns(T::Boolean) }
attr_reader :enable_customer_cancellation
end
# Account the payment intent belongs to.
sig { returns(String) }
attr_reader :account
# The amount being refunded.
sig { returns(Integer) }
attr_reader :amount
# Charge that is being refunded.
sig { returns(T.any(String, Stripe::Charge)) }
attr_reader :charge
# 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.
sig { returns(T::Hash[String, String]) }
attr_reader :metadata
# Payment intent that is being refunded.
sig { returns(T.any(String, Stripe::PaymentIntent)) }
attr_reader :payment_intent
# The reason for the refund.
sig { returns(String) }
attr_reader :reason
# Unique identifier for the refund object.
sig { returns(T.any(String, Stripe::Refund)) }
attr_reader :refund
# Boolean indicating whether the application fee should be refunded when refunding this charge. If a full charge refund is given, the full application fee will be refunded. Otherwise, the application fee will be refunded in an amount proportional to the amount of the charge refunded. An application fee can be refunded only by the application that created the charge.
sig { returns(T::Boolean) }
attr_reader :refund_application_fee
# Represents a per-transaction override of a reader configuration
sig { returns(RefundPaymentConfig) }
attr_reader :refund_payment_config
# Boolean indicating whether the transfer should be reversed when refunding this charge. The transfer will be reversed proportionally to the amount being refunded (either the entire or partial amount). A transfer can be reversed only by the application that created the charge.
sig { returns(T::Boolean) }
attr_reader :reverse_transfer
end
class SetReaderDisplay < Stripe::StripeObject
class Cart < Stripe::StripeObject
class LineItem < Stripe::StripeObject
# The amount of the line item. A positive integer in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(Integer) }
attr_reader :amount
# Description of the line item.
sig { returns(String) }
attr_reader :description
# The quantity of the line item.
sig { returns(Integer) }
attr_reader :quantity
end
# 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).
sig { returns(String) }
attr_reader :currency
# List of line items in the cart.
sig { returns(T::Array[LineItem]) }
attr_reader :line_items
# Tax amount for the entire cart. A positive integer in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(T.nilable(Integer)) }
attr_reader :tax
# Total amount for the entire cart, including tax. A positive integer in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(Integer) }
attr_reader :total
end
# Cart object to be displayed by the reader.
sig { returns(T.nilable(Cart)) }
attr_reader :cart
# Type of information to be displayed by the reader.
sig { returns(String) }
attr_reader :type
end
# Represents a reader action to collect customer inputs
sig { returns(CollectInputs) }
attr_reader :collect_inputs
# Represents a reader action to collect a payment method
sig { returns(CollectPaymentMethod) }
attr_reader :collect_payment_method
# Represents a reader action to confirm a payment
sig { returns(ConfirmPaymentIntent) }
attr_reader :confirm_payment_intent
# Failure code, only set if status is `failed`.
sig { returns(T.nilable(String)) }
attr_reader :failure_code
# Detailed failure message, only set if status is `failed`.
sig { returns(T.nilable(String)) }
attr_reader :failure_message
# Represents a reader action to process a payment intent
sig { returns(ProcessPaymentIntent) }
attr_reader :process_payment_intent
# Represents a reader action to process a setup intent
sig { returns(ProcessSetupIntent) }
attr_reader :process_setup_intent
# Represents a reader action to refund a payment
sig { returns(RefundPayment) }
attr_reader :refund_payment
# Represents a reader action to set the reader display
sig { returns(SetReaderDisplay) }
attr_reader :set_reader_display
# Status of the action performed by the reader.
sig { returns(String) }
attr_reader :status
# Type of action performed by the reader.
sig { returns(String) }
attr_reader :type
end
# The most recent action performed by the reader.
sig { returns(T.nilable(Action)) }
attr_reader :action
# The current software version of the reader.
sig { returns(T.nilable(String)) }
attr_reader :device_sw_version
# Device type of the reader.
sig { returns(String) }
attr_reader :device_type
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# The local IP address of the reader.
sig { returns(T.nilable(String)) }
attr_reader :ip_address
# Custom label given to the reader for easier identification.
sig { returns(String) }
attr_reader :label
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# The location identifier of the reader.
sig { returns(T.nilable(T.any(String, Stripe::Terminal::Location))) }
attr_reader :location
# 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.
sig { returns(T::Hash[String, String]) }
attr_reader :metadata
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Serial number of the reader.
sig { returns(String) }
attr_reader :serial_number
# The networking status of the reader. We do not recommend using this field in flows that may block taking payments.
sig { returns(T.nilable(String)) }
attr_reader :status
# Always true for a deleted object
sig { returns(T::Boolean) }
attr_reader :deleted
class DeleteParams < Stripe::RequestParams; end
class UpdateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The new label of the reader.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :label
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
sig {
params(expand: T.nilable(T::Array[String]), label: T.nilable(T.nilable(String)), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String])))).void
}
def initialize(expand: nil, label: nil, metadata: nil); end
end
class ListParams < Stripe::RequestParams
# Filters readers by device type
sig { returns(T.nilable(String)) }
attr_accessor :device_type
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A location ID to filter the response list to only readers at the specific location
sig { returns(T.nilable(String)) }
attr_accessor :location
# Filters readers by serial number
sig { returns(T.nilable(String)) }
attr_accessor :serial_number
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# A status filter to filter readers to only offline or online readers
sig { returns(T.nilable(String)) }
attr_accessor :status
sig {
params(device_type: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), location: T.nilable(String), serial_number: T.nilable(String), starting_after: T.nilable(String), status: T.nilable(String)).void
}
def initialize(
device_type: nil,
ending_before: nil,
expand: nil,
limit: nil,
location: nil,
serial_number: nil,
starting_after: nil,
status: nil
); end
end
class CreateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Custom label given to the reader for easier identification. If no label is specified, the registration code will be used.
sig { returns(T.nilable(String)) }
attr_accessor :label
# The location to assign the reader to.
sig { returns(T.nilable(String)) }
attr_accessor :location
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# A code generated by the reader used for registering to an account.
sig { returns(String) }
attr_accessor :registration_code
sig {
params(expand: T.nilable(T::Array[String]), label: T.nilable(String), location: T.nilable(String), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), registration_code: String).void
}
def initialize(
expand: nil,
label: nil,
location: nil,
metadata: nil,
registration_code: nil
); end
end
class CancelActionParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class CollectInputsParams < Stripe::RequestParams
class Input < Stripe::RequestParams
class CustomText < Stripe::RequestParams
# The description which will be displayed when collecting this input
sig { returns(T.nilable(String)) }
attr_accessor :description
# The skip button text
sig { returns(T.nilable(String)) }
attr_accessor :skip_button
# The submit button text
sig { returns(T.nilable(String)) }
attr_accessor :submit_button
# The title which will be displayed when collecting this input
sig { returns(String) }
attr_accessor :title
sig {
params(description: T.nilable(String), skip_button: T.nilable(String), submit_button: T.nilable(String), title: String).void
}
def initialize(description: nil, skip_button: nil, submit_button: nil, title: nil); end
end
class Selection < Stripe::RequestParams
class Choice < Stripe::RequestParams
# The unique identifier for this choice
sig { returns(String) }
attr_accessor :id
# The style of the button which will be shown for this choice
sig { returns(T.nilable(String)) }
attr_accessor :style
# The text which will be shown on the button for this choice
sig { returns(String) }
attr_accessor :text
sig { params(id: String, style: T.nilable(String), text: String).void }
def initialize(id: nil, style: nil, text: nil); end
end
# List of choices for the `selection` input
sig {
returns(T::Array[::Stripe::Terminal::Reader::CollectInputsParams::Input::Selection::Choice])
}
attr_accessor :choices
sig {
params(choices: T::Array[::Stripe::Terminal::Reader::CollectInputsParams::Input::Selection::Choice]).void
}
def initialize(choices: nil); end
end
class Toggle < Stripe::RequestParams
# The default value of the toggle
sig { returns(T.nilable(String)) }
attr_accessor :default_value
# The description which will be displayed for the toggle
sig { returns(T.nilable(String)) }
attr_accessor :description
# The title which will be displayed for the toggle
sig { returns(T.nilable(String)) }
attr_accessor :title
sig {
params(default_value: T.nilable(String), description: T.nilable(String), title: T.nilable(String)).void
}
def initialize(default_value: nil, description: nil, title: nil); end
end
# Customize the text which will be displayed while collecting this input
sig { returns(::Stripe::Terminal::Reader::CollectInputsParams::Input::CustomText) }
attr_accessor :custom_text
# Indicate that this input is required, disabling the skip button
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :required
# Options for the `selection` input
sig {
returns(T.nilable(::Stripe::Terminal::Reader::CollectInputsParams::Input::Selection))
}
attr_accessor :selection
# List of toggles to be displayed and customization for the toggles
sig {
returns(T.nilable(T::Array[::Stripe::Terminal::Reader::CollectInputsParams::Input::Toggle]))
}
attr_accessor :toggles
# The type of input to collect
sig { returns(String) }
attr_accessor :type
sig {
params(custom_text: ::Stripe::Terminal::Reader::CollectInputsParams::Input::CustomText, required: T.nilable(T::Boolean), selection: T.nilable(::Stripe::Terminal::Reader::CollectInputsParams::Input::Selection), toggles: T.nilable(T::Array[::Stripe::Terminal::Reader::CollectInputsParams::Input::Toggle]), type: String).void
}
def initialize(
custom_text: nil,
required: nil,
selection: nil,
toggles: nil,
type: nil
); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# List of inputs to be collected using the Reader
sig { returns(T::Array[::Stripe::Terminal::Reader::CollectInputsParams::Input]) }
attr_accessor :inputs
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
sig {
params(expand: T.nilable(T::Array[String]), inputs: T::Array[::Stripe::Terminal::Reader::CollectInputsParams::Input], metadata: T.nilable(T::Hash[String, String])).void
}
def initialize(expand: nil, inputs: nil, metadata: nil); end
end
class CollectPaymentMethodParams < Stripe::RequestParams
class CollectConfig < Stripe::RequestParams
class Tipping < Stripe::RequestParams
# Amount used to calculate tip suggestions on tipping selection screen for this transaction. Must be a positive integer in the smallest currency unit (e.g., 100 cents to represent $1.00 or 100 to represent ¥100, a zero-decimal currency).
sig { returns(T.nilable(Integer)) }
attr_accessor :amount_eligible
sig { params(amount_eligible: T.nilable(Integer)).void }
def initialize(amount_eligible: nil); end
end
# This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow.
sig { returns(T.nilable(String)) }
attr_accessor :allow_redisplay
# Enables cancel button on transaction screens.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :enable_customer_cancellation
# Override showing a tipping selection screen on this transaction.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :skip_tipping
# Tipping configuration for this transaction.
sig {
returns(T.nilable(::Stripe::Terminal::Reader::CollectPaymentMethodParams::CollectConfig::Tipping))
}
attr_accessor :tipping
sig {
params(allow_redisplay: T.nilable(String), enable_customer_cancellation: T.nilable(T::Boolean), skip_tipping: T.nilable(T::Boolean), tipping: T.nilable(::Stripe::Terminal::Reader::CollectPaymentMethodParams::CollectConfig::Tipping)).void
}
def initialize(
allow_redisplay: nil,
enable_customer_cancellation: nil,
skip_tipping: nil,
tipping: nil
); end
end
# Configuration overrides
sig {
returns(T.nilable(::Stripe::Terminal::Reader::CollectPaymentMethodParams::CollectConfig))
}
attr_accessor :collect_config
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# PaymentIntent ID
sig { returns(String) }
attr_accessor :payment_intent
sig {
params(collect_config: T.nilable(::Stripe::Terminal::Reader::CollectPaymentMethodParams::CollectConfig), expand: T.nilable(T::Array[String]), payment_intent: String).void
}
def initialize(collect_config: nil, expand: nil, payment_intent: nil); end
end
class ConfirmPaymentIntentParams < Stripe::RequestParams
class ConfirmConfig < Stripe::RequestParams
# The URL to redirect your customer back to after they authenticate or cancel their payment on the payment method's app or site. If you'd prefer to redirect to a mobile application, you can alternatively supply an application URI scheme.
sig { returns(T.nilable(String)) }
attr_accessor :return_url
sig { params(return_url: T.nilable(String)).void }
def initialize(return_url: nil); end
end
# Configuration overrides
sig {
returns(T.nilable(::Stripe::Terminal::Reader::ConfirmPaymentIntentParams::ConfirmConfig))
}
attr_accessor :confirm_config
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# PaymentIntent ID
sig { returns(String) }
attr_accessor :payment_intent
sig {
params(confirm_config: T.nilable(::Stripe::Terminal::Reader::ConfirmPaymentIntentParams::ConfirmConfig), expand: T.nilable(T::Array[String]), payment_intent: String).void
}
def initialize(confirm_config: nil, expand: nil, payment_intent: nil); end
end
class ProcessPaymentIntentParams < Stripe::RequestParams
class ProcessConfig < Stripe::RequestParams
class Tipping < Stripe::RequestParams
# Amount used to calculate tip suggestions on tipping selection screen for this transaction. Must be a positive integer in the smallest currency unit (e.g., 100 cents to represent $1.00 or 100 to represent ¥100, a zero-decimal currency).
sig { returns(T.nilable(Integer)) }
attr_accessor :amount_eligible
sig { params(amount_eligible: T.nilable(Integer)).void }
def initialize(amount_eligible: nil); end
end
# This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow.
sig { returns(T.nilable(String)) }
attr_accessor :allow_redisplay
# Enables cancel button on transaction screens.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :enable_customer_cancellation
# The URL to redirect your customer back to after they authenticate or cancel their payment on the payment method's app or site. If you'd prefer to redirect to a mobile application, you can alternatively supply an application URI scheme.
sig { returns(T.nilable(String)) }
attr_accessor :return_url
# Override showing a tipping selection screen on this transaction.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :skip_tipping
# Tipping configuration for this transaction.
sig {
returns(T.nilable(::Stripe::Terminal::Reader::ProcessPaymentIntentParams::ProcessConfig::Tipping))
}
attr_accessor :tipping
sig {
params(allow_redisplay: T.nilable(String), enable_customer_cancellation: T.nilable(T::Boolean), return_url: T.nilable(String), skip_tipping: T.nilable(T::Boolean), tipping: T.nilable(::Stripe::Terminal::Reader::ProcessPaymentIntentParams::ProcessConfig::Tipping)).void
}
def initialize(
allow_redisplay: nil,
enable_customer_cancellation: nil,
return_url: nil,
skip_tipping: nil,
tipping: nil
); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# PaymentIntent ID
sig { returns(String) }
attr_accessor :payment_intent
# Configuration overrides
sig {
returns(T.nilable(::Stripe::Terminal::Reader::ProcessPaymentIntentParams::ProcessConfig))
}
attr_accessor :process_config
sig {
params(expand: T.nilable(T::Array[String]), payment_intent: String, process_config: T.nilable(::Stripe::Terminal::Reader::ProcessPaymentIntentParams::ProcessConfig)).void
}
def initialize(expand: nil, payment_intent: nil, process_config: nil); end
end
class ProcessSetupIntentParams < Stripe::RequestParams
class ProcessConfig < Stripe::RequestParams
# Enables cancel button on transaction screens.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :enable_customer_cancellation
sig { params(enable_customer_cancellation: T.nilable(T::Boolean)).void }
def initialize(enable_customer_cancellation: nil); end
end
# This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow.
sig { returns(String) }
attr_accessor :allow_redisplay
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Configuration overrides
sig {
returns(T.nilable(::Stripe::Terminal::Reader::ProcessSetupIntentParams::ProcessConfig))
}
attr_accessor :process_config
# SetupIntent ID
sig { returns(String) }
attr_accessor :setup_intent
sig {
params(allow_redisplay: String, expand: T.nilable(T::Array[String]), process_config: T.nilable(::Stripe::Terminal::Reader::ProcessSetupIntentParams::ProcessConfig), setup_intent: String).void
}
def initialize(
allow_redisplay: nil,
expand: nil,
process_config: nil,
setup_intent: nil
); end
end
class RefundPaymentParams < Stripe::RequestParams
class RefundPaymentConfig < Stripe::RequestParams
# Enables cancel button on transaction screens.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :enable_customer_cancellation
sig { params(enable_customer_cancellation: T.nilable(T::Boolean)).void }
def initialize(enable_customer_cancellation: nil); end
end
# A positive integer in __cents__ representing how much of this charge to refund.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# ID of the Charge to refund.
sig { returns(T.nilable(String)) }
attr_accessor :charge
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# ID of the PaymentIntent to refund.
sig { returns(T.nilable(String)) }
attr_accessor :payment_intent
# Boolean indicating whether the application fee should be refunded when refunding this charge. If a full charge refund is given, the full application fee will be refunded. Otherwise, the application fee will be refunded in an amount proportional to the amount of the charge refunded. An application fee can be refunded only by the application that created the charge.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :refund_application_fee
# Configuration overrides
sig {
returns(T.nilable(::Stripe::Terminal::Reader::RefundPaymentParams::RefundPaymentConfig))
}
attr_accessor :refund_payment_config
# Boolean indicating whether the transfer should be reversed when refunding this charge. The transfer will be reversed proportionally to the amount being refunded (either the entire or partial amount). A transfer can be reversed only by the application that created the charge.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :reverse_transfer
sig {
params(amount: T.nilable(Integer), charge: T.nilable(String), expand: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), payment_intent: T.nilable(String), refund_application_fee: T.nilable(T::Boolean), refund_payment_config: T.nilable(::Stripe::Terminal::Reader::RefundPaymentParams::RefundPaymentConfig), reverse_transfer: T.nilable(T::Boolean)).void
}
def initialize(
amount: nil,
charge: nil,
expand: nil,
metadata: nil,
payment_intent: nil,
refund_application_fee: nil,
refund_payment_config: nil,
reverse_transfer: nil
); end
end
class SetReaderDisplayParams < Stripe::RequestParams
class Cart < Stripe::RequestParams
class LineItem < Stripe::RequestParams
# The price of the item in cents.
sig { returns(Integer) }
attr_accessor :amount
# The description or name of the item.
sig { returns(String) }
attr_accessor :description
# The quantity of the line item being purchased.
sig { returns(Integer) }
attr_accessor :quantity
sig { params(amount: Integer, description: String, quantity: Integer).void }
def initialize(amount: nil, description: nil, quantity: nil); end
end
# 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).
sig { returns(String) }
attr_accessor :currency
# Array of line items that were purchased.
sig {
returns(T::Array[::Stripe::Terminal::Reader::SetReaderDisplayParams::Cart::LineItem])
}
attr_accessor :line_items
# The amount of tax in cents.
sig { returns(T.nilable(Integer)) }
attr_accessor :tax
# Total balance of cart due in cents.
sig { returns(Integer) }
attr_accessor :total
sig {
params(currency: String, line_items: T::Array[::Stripe::Terminal::Reader::SetReaderDisplayParams::Cart::LineItem], tax: T.nilable(Integer), total: Integer).void
}
def initialize(currency: nil, line_items: nil, tax: nil, total: nil); end
end
# Cart
sig { returns(T.nilable(::Stripe::Terminal::Reader::SetReaderDisplayParams::Cart)) }
attr_accessor :cart
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Type
sig { returns(String) }
attr_accessor :type
sig {
params(cart: T.nilable(::Stripe::Terminal::Reader::SetReaderDisplayParams::Cart), expand: T.nilable(T::Array[String]), type: String).void
}
def initialize(cart: nil, expand: nil, type: nil); end
end
class PresentPaymentMethodParams < Stripe::RequestParams
class CardPresent < Stripe::RequestParams
# The card number, as a string without any separators.
sig { returns(T.nilable(String)) }
attr_accessor :number
sig { params(number: T.nilable(String)).void }
def initialize(number: nil); end
end
class InteracPresent < Stripe::RequestParams
# Card Number
sig { returns(T.nilable(String)) }
attr_accessor :number
sig { params(number: T.nilable(String)).void }
def initialize(number: nil); end
end
# Simulated on-reader tip amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount_tip
# Simulated data for the card_present payment method.
sig {
returns(T.nilable(::Stripe::Terminal::Reader::PresentPaymentMethodParams::CardPresent))
}
attr_accessor :card_present
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Simulated data for the interac_present payment method.
sig {
returns(T.nilable(::Stripe::Terminal::Reader::PresentPaymentMethodParams::InteracPresent))
}
attr_accessor :interac_present
# Simulated payment type.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(amount_tip: T.nilable(Integer), card_present: T.nilable(::Stripe::Terminal::Reader::PresentPaymentMethodParams::CardPresent), expand: T.nilable(T::Array[String]), interac_present: T.nilable(::Stripe::Terminal::Reader::PresentPaymentMethodParams::InteracPresent), type: T.nilable(String)).void
}
def initialize(
amount_tip: nil,
card_present: nil,
expand: nil,
interac_present: nil,
type: nil
); end
end
class SucceedInputCollectionParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# This parameter defines the skip behavior for input collection.
sig { returns(T.nilable(String)) }
attr_accessor :skip_non_required_inputs
sig {
params(expand: T.nilable(T::Array[String]), skip_non_required_inputs: T.nilable(String)).void
}
def initialize(expand: nil, skip_non_required_inputs: nil); end
end
class TimeoutInputCollectionParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Cancels the current reader action.
sig {
params(params: T.any(::Stripe::Terminal::Reader::CancelActionParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Reader)
}
def cancel_action(params = {}, opts = {}); end
# Cancels the current reader action.
sig {
params(reader: String, params: T.any(::Stripe::Terminal::Reader::CancelActionParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Reader)
}
def self.cancel_action(reader, params = {}, opts = {}); end
# Initiates an input collection flow on a Reader.
sig {
params(params: T.any(::Stripe::Terminal::Reader::CollectInputsParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Reader)
}
def collect_inputs(params = {}, opts = {}); end
# Initiates an input collection flow on a Reader.
sig {
params(reader: String, params: T.any(::Stripe::Terminal::Reader::CollectInputsParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Reader)
}
def self.collect_inputs(reader, params = {}, opts = {}); end
# Initiates a payment flow on a Reader and updates the PaymentIntent with card details before manual confirmation.
sig {
params(params: T.any(::Stripe::Terminal::Reader::CollectPaymentMethodParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Reader)
}
def collect_payment_method(params = {}, opts = {}); end
# Initiates a payment flow on a Reader and updates the PaymentIntent with card details before manual confirmation.
sig {
params(reader: String, params: T.any(::Stripe::Terminal::Reader::CollectPaymentMethodParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Reader)
}
def self.collect_payment_method(reader, params = {}, opts = {}); end
# Finalizes a payment on a Reader.
sig {
params(params: T.any(::Stripe::Terminal::Reader::ConfirmPaymentIntentParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Reader)
}
def confirm_payment_intent(params = {}, opts = {}); end
# Finalizes a payment on a Reader.
sig {
params(reader: String, params: T.any(::Stripe::Terminal::Reader::ConfirmPaymentIntentParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Reader)
}
def self.confirm_payment_intent(reader, params = {}, opts = {}); end
# Creates a new Reader object.
sig {
params(params: T.any(::Stripe::Terminal::Reader::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Reader)
}
def self.create(params = {}, opts = {}); end
# Deletes a Reader object.
sig {
params(reader: String, params: T.any(::Stripe::Terminal::Reader::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Reader)
}
def self.delete(reader, params = {}, opts = {}); end
# Deletes a Reader object.
sig {
params(params: T.any(::Stripe::Terminal::Reader::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Reader)
}
def delete(params = {}, opts = {}); end
# Returns a list of Reader objects.
sig {
params(params: T.any(::Stripe::Terminal::Reader::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Initiates a payment flow on a Reader.
sig {
params(params: T.any(::Stripe::Terminal::Reader::ProcessPaymentIntentParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Reader)
}
def process_payment_intent(params = {}, opts = {}); end
# Initiates a payment flow on a Reader.
sig {
params(reader: String, params: T.any(::Stripe::Terminal::Reader::ProcessPaymentIntentParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Reader)
}
def self.process_payment_intent(reader, params = {}, opts = {}); end
# Initiates a setup intent flow on a Reader.
sig {
params(params: T.any(::Stripe::Terminal::Reader::ProcessSetupIntentParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Reader)
}
def process_setup_intent(params = {}, opts = {}); end
# Initiates a setup intent flow on a Reader.
sig {
params(reader: String, params: T.any(::Stripe::Terminal::Reader::ProcessSetupIntentParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Reader)
}
def self.process_setup_intent(reader, params = {}, opts = {}); end
# Initiates a refund on a Reader
sig {
params(params: T.any(::Stripe::Terminal::Reader::RefundPaymentParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Reader)
}
def refund_payment(params = {}, opts = {}); end
# Initiates a refund on a Reader
sig {
params(reader: String, params: T.any(::Stripe::Terminal::Reader::RefundPaymentParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Reader)
}
def self.refund_payment(reader, params = {}, opts = {}); end
# Sets reader display to show cart details.
sig {
params(params: T.any(::Stripe::Terminal::Reader::SetReaderDisplayParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Reader)
}
def set_reader_display(params = {}, opts = {}); end
# Sets reader display to show cart details.
sig {
params(reader: String, params: T.any(::Stripe::Terminal::Reader::SetReaderDisplayParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Reader)
}
def self.set_reader_display(reader, params = {}, opts = {}); end
# Updates a Reader object by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
sig {
params(reader: String, params: T.any(::Stripe::Terminal::Reader::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Reader)
}
def self.update(reader, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Terminal
# Returns data collected by Terminal readers. This data is only stored for 24 hours.
class ReaderCollectedData < APIResource
class Magstripe < Stripe::StripeObject
# The raw magstripe data collected by the reader.
sig { returns(T.nilable(String)) }
attr_reader :data
end
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# The magstripe data collected by the reader.
sig { returns(T.nilable(Magstripe)) }
attr_reader :magstripe
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The type of data collected by the reader.
sig { returns(String) }
attr_reader :type
end
end
end
# typed: true
module Stripe
module TestHelpers
# A test clock enables deterministic control over objects in testmode. With a test clock, you can create
# objects at a frozen time in the past or future, and advance to a specific future time to observe webhooks and state changes. After the clock advances,
# you can either validate the current state of your scenario (and test your assumptions), change the current state of your scenario (and test more complex scenarios), or keep advancing forward in time.
class TestClock < APIResource
class StatusDetails < Stripe::StripeObject
class Advancing < Stripe::StripeObject
# The `frozen_time` that the Test Clock is advancing towards.
sig { returns(Integer) }
attr_reader :target_frozen_time
end
# Attribute for field advancing
sig { returns(Advancing) }
attr_reader :advancing
end
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# Time at which this clock is scheduled to auto delete.
sig { returns(Integer) }
attr_reader :deletes_after
# Time at which all objects belonging to this clock are frozen.
sig { returns(Integer) }
attr_reader :frozen_time
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# The custom name supplied at creation.
sig { returns(T.nilable(String)) }
attr_reader :name
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The status of the Test Clock.
sig { returns(String) }
attr_reader :status
# Attribute for field status_details
sig { returns(StatusDetails) }
attr_reader :status_details
# Always true for a deleted object
sig { returns(T::Boolean) }
attr_reader :deleted
class DeleteParams < Stripe::RequestParams; end
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
class CreateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The initial frozen time for this test clock.
sig { returns(Integer) }
attr_accessor :frozen_time
# The name for this test clock.
sig { returns(T.nilable(String)) }
attr_accessor :name
sig {
params(expand: T.nilable(T::Array[String]), frozen_time: Integer, name: T.nilable(String)).void
}
def initialize(expand: nil, frozen_time: nil, name: nil); end
end
class AdvanceParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The time to advance the test clock. Must be after the test clock's current frozen time. Cannot be more than two intervals in the future from the shortest subscription in this test clock. If there are no subscriptions in this test clock, it cannot be more than two years in the future.
sig { returns(Integer) }
attr_accessor :frozen_time
sig { params(expand: T.nilable(T::Array[String]), frozen_time: Integer).void }
def initialize(expand: nil, frozen_time: nil); end
end
# Starts advancing a test clock to a specified time in the future. Advancement is done when status changes to Ready.
sig {
params(params: T.any(::Stripe::TestHelpers::TestClock::AdvanceParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::TestHelpers::TestClock)
}
def advance(params = {}, opts = {}); end
# Starts advancing a test clock to a specified time in the future. Advancement is done when status changes to Ready.
sig {
params(test_clock: String, params: T.any(::Stripe::TestHelpers::TestClock::AdvanceParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::TestHelpers::TestClock)
}
def self.advance(test_clock, params = {}, opts = {}); end
# Creates a new test clock that can be attached to new customers and quotes.
sig {
params(params: T.any(::Stripe::TestHelpers::TestClock::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::TestHelpers::TestClock)
}
def self.create(params = {}, opts = {}); end
# Deletes a test clock.
sig {
params(test_clock: String, params: T.any(::Stripe::TestHelpers::TestClock::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::TestHelpers::TestClock)
}
def self.delete(test_clock, params = {}, opts = {}); end
# Deletes a test clock.
sig {
params(params: T.any(::Stripe::TestHelpers::TestClock::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::TestHelpers::TestClock)
}
def delete(params = {}, opts = {}); end
# Returns a list of your test clocks.
sig {
params(params: T.any(::Stripe::TestHelpers::TestClock::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
# Tokenization is the process Stripe uses to collect sensitive card or bank
# account details, or personally identifiable information (PII), directly from
# your customers in a secure manner. A token representing this information is
# returned to your server to use. Use our
# [recommended payments integrations](https://stripe.com/docs/payments) to perform this process
# on the client-side. This guarantees that no sensitive card data touches your server,
# and allows your integration to operate in a PCI-compliant way.
#
# If you can't use client-side tokenization, you can also create tokens using
# the API with either your publishable or secret API key. If
# your integration uses this method, you're responsible for any PCI compliance
# that it might require, and you must keep your secret API key safe. Unlike with
# client-side tokenization, your customer's information isn't sent directly to
# Stripe, so we can't determine how it's handled or stored.
#
# You can't store or use tokens more than once. To store card or bank account
# information for later use, create [Customer](https://stripe.com/docs/api#customers)
# objects or [External accounts](https://docs.stripe.com/api#external_accounts).
# [Radar](https://stripe.com/docs/radar), our integrated solution for automatic fraud protection,
# performs best with integrations that use client-side tokenization.
class Token < APIResource
# These bank accounts are payment methods on `Customer` objects.
#
# On the other hand [External Accounts](/api#external_accounts) are transfer
# destinations on `Account` objects for connected accounts.
# They can be bank accounts or debit cards as well, and are documented in the links above.
#
# Related guide: [Bank debits and transfers](/payments/bank-debits-transfers)
sig { returns(Stripe::BankAccount) }
attr_reader :bank_account
# You can store multiple cards on a customer in order to charge the customer
# later. You can also store multiple debit cards on a recipient in order to
# transfer to those cards later.
#
# Related guide: [Card payments with Sources](https://stripe.com/docs/sources/cards)
sig { returns(Stripe::Card) }
attr_reader :card
# IP address of the client that generates the token.
sig { returns(T.nilable(String)) }
attr_reader :client_ip
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Type of the token: `account`, `bank_account`, `card`, or `pii`.
sig { returns(String) }
attr_reader :type
# Determines if you have already used this token (you can only use tokens once).
sig { returns(T::Boolean) }
attr_reader :used
class CreateParams < Stripe::RequestParams
class Account < Stripe::RequestParams
class Company < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class AddressKana < Stripe::RequestParams
# City or ward.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Block or building number.
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Building details.
sig { returns(T.nilable(String)) }
attr_accessor :line2
# Postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# Prefecture.
sig { returns(T.nilable(String)) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_accessor :town
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), town: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
class AddressKanji < Stripe::RequestParams
# City or ward.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Block or building number.
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Building details.
sig { returns(T.nilable(String)) }
attr_accessor :line2
# Postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# Prefecture.
sig { returns(T.nilable(String)) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_accessor :town
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), town: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
class DirectorshipDeclaration < Stripe::RequestParams
# The Unix timestamp marking when the directorship declaration attestation was made.
sig { returns(T.nilable(Integer)) }
attr_accessor :date
# The IP address from which the directorship declaration attestation was made.
sig { returns(T.nilable(String)) }
attr_accessor :ip
# The user agent of the browser from which the directorship declaration attestation was made.
sig { returns(T.nilable(String)) }
attr_accessor :user_agent
sig {
params(date: T.nilable(Integer), ip: T.nilable(String), user_agent: T.nilable(String)).void
}
def initialize(date: nil, ip: nil, user_agent: nil); end
end
class OwnershipDeclaration < Stripe::RequestParams
# The Unix timestamp marking when the beneficial owner attestation was made.
sig { returns(T.nilable(Integer)) }
attr_accessor :date
# The IP address from which the beneficial owner attestation was made.
sig { returns(T.nilable(String)) }
attr_accessor :ip
# The user agent of the browser from which the beneficial owner attestation was made.
sig { returns(T.nilable(String)) }
attr_accessor :user_agent
sig {
params(date: T.nilable(Integer), ip: T.nilable(String), user_agent: T.nilable(String)).void
}
def initialize(date: nil, ip: nil, user_agent: nil); end
end
class RegistrationDate < Stripe::RequestParams
# The day of registration, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of registration, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of registration.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
class Verification < Stripe::RequestParams
class Document < Stripe::RequestParams
# The back of a document returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `additional_verification`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :back
# The front of a document returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `additional_verification`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :front
sig { params(back: T.nilable(String), front: T.nilable(String)).void }
def initialize(back: nil, front: nil); end
end
# A document verifying the business.
sig {
returns(T.nilable(::Stripe::Token::CreateParams::Account::Company::Verification::Document))
}
attr_accessor :document
sig {
params(document: T.nilable(::Stripe::Token::CreateParams::Account::Company::Verification::Document)).void
}
def initialize(document: nil); end
end
# The company's primary address.
sig { returns(T.nilable(::Stripe::Token::CreateParams::Account::Company::Address)) }
attr_accessor :address
# The Kana variation of the company's primary address (Japan only).
sig { returns(T.nilable(::Stripe::Token::CreateParams::Account::Company::AddressKana)) }
attr_accessor :address_kana
# The Kanji variation of the company's primary address (Japan only).
sig { returns(T.nilable(::Stripe::Token::CreateParams::Account::Company::AddressKanji)) }
attr_accessor :address_kanji
# Whether the company's directors have been provided. Set this Boolean to `true` after creating all the company's directors with [the Persons API](/api/persons) for accounts with a `relationship.director` requirement. This value is not automatically set to `true` after creating directors, so it needs to be updated to indicate all directors have been provided.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :directors_provided
# This hash is used to attest that the directors information provided to Stripe is both current and correct.
sig {
returns(T.nilable(::Stripe::Token::CreateParams::Account::Company::DirectorshipDeclaration))
}
attr_accessor :directorship_declaration
# Whether the company's executives have been provided. Set this Boolean to `true` after creating all the company's executives with [the Persons API](/api/persons) for accounts with a `relationship.executive` requirement.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :executives_provided
# The export license ID number of the company, also referred as Import Export Code (India only).
sig { returns(T.nilable(String)) }
attr_accessor :export_license_id
# The purpose code to use for export transactions (India only).
sig { returns(T.nilable(String)) }
attr_accessor :export_purpose_code
# The company's legal name.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The Kana variation of the company's legal name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :name_kana
# The Kanji variation of the company's legal name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :name_kanji
# Whether the company's owners have been provided. Set this Boolean to `true` after creating all the company's owners with [the Persons API](/api/persons) for accounts with a `relationship.owner` requirement.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :owners_provided
# This hash is used to attest that the beneficial owner information provided to Stripe is both current and correct.
sig {
returns(T.nilable(::Stripe::Token::CreateParams::Account::Company::OwnershipDeclaration))
}
attr_accessor :ownership_declaration
# Whether the user described by the data in the token has been shown the Ownership Declaration and indicated that it is correct.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :ownership_declaration_shown_and_signed
# This value is used to determine if a business is exempt from providing ultimate beneficial owners. See [this support article](https://support.stripe.com/questions/exemption-from-providing-ownership-details) and [changelog](https://docs.stripe.com/changelog/acacia/2025-01-27/ownership-exemption-reason-accounts-api) for more details.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :ownership_exemption_reason
# The company's phone number (used for verification).
sig { returns(T.nilable(String)) }
attr_accessor :phone
# Attribute for param field registration_date
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Token::CreateParams::Account::Company::RegistrationDate))))
}
attr_accessor :registration_date
# The identification number given to a company when it is registered or incorporated, if distinct from the identification number used for filing taxes. (Examples are the CIN for companies and LLP IN for partnerships in India, and the Company Registration Number in Hong Kong).
sig { returns(T.nilable(String)) }
attr_accessor :registration_number
# The category identifying the legal structure of the company or legal entity. See [Business structure](/connect/identity-verification#business-structure) for more details. Pass an empty string to unset this value.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :structure
# The business ID number of the company, as appropriate for the company’s country. (Examples are an Employer ID Number in the U.S., a Business Number in Canada, or a Company Number in the UK.)
sig { returns(T.nilable(String)) }
attr_accessor :tax_id
# The jurisdiction in which the `tax_id` is registered (Germany-based companies only).
sig { returns(T.nilable(String)) }
attr_accessor :tax_id_registrar
# The VAT number of the company.
sig { returns(T.nilable(String)) }
attr_accessor :vat_id
# Information on the verification state of the company.
sig { returns(T.nilable(::Stripe::Token::CreateParams::Account::Company::Verification)) }
attr_accessor :verification
sig {
params(address: T.nilable(::Stripe::Token::CreateParams::Account::Company::Address), address_kana: T.nilable(::Stripe::Token::CreateParams::Account::Company::AddressKana), address_kanji: T.nilable(::Stripe::Token::CreateParams::Account::Company::AddressKanji), directors_provided: T.nilable(T::Boolean), directorship_declaration: T.nilable(::Stripe::Token::CreateParams::Account::Company::DirectorshipDeclaration), executives_provided: T.nilable(T::Boolean), export_license_id: T.nilable(String), export_purpose_code: T.nilable(String), name: T.nilable(String), name_kana: T.nilable(String), name_kanji: T.nilable(String), owners_provided: T.nilable(T::Boolean), ownership_declaration: T.nilable(::Stripe::Token::CreateParams::Account::Company::OwnershipDeclaration), ownership_declaration_shown_and_signed: T.nilable(T::Boolean), ownership_exemption_reason: T.nilable(T.nilable(T.any(String, String))), phone: T.nilable(String), registration_date: T.nilable(T.nilable(T.any(String, ::Stripe::Token::CreateParams::Account::Company::RegistrationDate))), registration_number: T.nilable(String), structure: T.nilable(T.nilable(T.any(String, String))), tax_id: T.nilable(String), tax_id_registrar: T.nilable(String), vat_id: T.nilable(String), verification: T.nilable(::Stripe::Token::CreateParams::Account::Company::Verification)).void
}
def initialize(
address: nil,
address_kana: nil,
address_kanji: nil,
directors_provided: nil,
directorship_declaration: nil,
executives_provided: nil,
export_license_id: nil,
export_purpose_code: nil,
name: nil,
name_kana: nil,
name_kanji: nil,
owners_provided: nil,
ownership_declaration: nil,
ownership_declaration_shown_and_signed: nil,
ownership_exemption_reason: nil,
phone: nil,
registration_date: nil,
registration_number: nil,
structure: nil,
tax_id: nil,
tax_id_registrar: nil,
vat_id: nil,
verification: nil
); end
end
class Individual < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class AddressKana < Stripe::RequestParams
# City or ward.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Block or building number.
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Building details.
sig { returns(T.nilable(String)) }
attr_accessor :line2
# Postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# Prefecture.
sig { returns(T.nilable(String)) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_accessor :town
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), town: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
class AddressKanji < Stripe::RequestParams
# City or ward.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Block or building number.
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Building details.
sig { returns(T.nilable(String)) }
attr_accessor :line2
# Postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# Prefecture.
sig { returns(T.nilable(String)) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_accessor :town
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), town: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
class Dob < Stripe::RequestParams
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
class RegisteredAddress < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class Relationship < Stripe::RequestParams
# Whether the person is a director of the account's legal entity. Directors are typically members of the governing board of the company, or responsible for ensuring the company meets its regulatory obligations.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :director
# Whether the person has significant responsibility to control, manage, or direct the organization.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :executive
# Whether the person is an owner of the account’s legal entity.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :owner
# The percent owned by the person of the account's legal entity.
sig { returns(T.nilable(T.nilable(T.any(String, Float)))) }
attr_accessor :percent_ownership
# The person's title (e.g., CEO, Support Engineer).
sig { returns(T.nilable(String)) }
attr_accessor :title
sig {
params(director: T.nilable(T::Boolean), executive: T.nilable(T::Boolean), owner: T.nilable(T::Boolean), percent_ownership: T.nilable(T.nilable(T.any(String, Float))), title: T.nilable(String)).void
}
def initialize(
director: nil,
executive: nil,
owner: nil,
percent_ownership: nil,
title: nil
); end
end
class Verification < Stripe::RequestParams
class AdditionalDocument < Stripe::RequestParams
# The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :back
# The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :front
sig { params(back: T.nilable(String), front: T.nilable(String)).void }
def initialize(back: nil, front: nil); end
end
class Document < Stripe::RequestParams
# The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :back
# The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :front
sig { params(back: T.nilable(String), front: T.nilable(String)).void }
def initialize(back: nil, front: nil); end
end
# A document showing address, either a passport, local ID card, or utility bill from a well-known utility company.
sig {
returns(T.nilable(::Stripe::Token::CreateParams::Account::Individual::Verification::AdditionalDocument))
}
attr_accessor :additional_document
# An identifying document, either a passport or local ID card.
sig {
returns(T.nilable(::Stripe::Token::CreateParams::Account::Individual::Verification::Document))
}
attr_accessor :document
sig {
params(additional_document: T.nilable(::Stripe::Token::CreateParams::Account::Individual::Verification::AdditionalDocument), document: T.nilable(::Stripe::Token::CreateParams::Account::Individual::Verification::Document)).void
}
def initialize(additional_document: nil, document: nil); end
end
# The individual's primary address.
sig { returns(T.nilable(::Stripe::Token::CreateParams::Account::Individual::Address)) }
attr_accessor :address
# The Kana variation of the individual's primary address (Japan only).
sig {
returns(T.nilable(::Stripe::Token::CreateParams::Account::Individual::AddressKana))
}
attr_accessor :address_kana
# The Kanji variation of the individual's primary address (Japan only).
sig {
returns(T.nilable(::Stripe::Token::CreateParams::Account::Individual::AddressKanji))
}
attr_accessor :address_kanji
# The individual's date of birth.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Token::CreateParams::Account::Individual::Dob))))
}
attr_accessor :dob
# The individual's email address.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The individual's first name.
sig { returns(T.nilable(String)) }
attr_accessor :first_name
# The Kana variation of the individual's first name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :first_name_kana
# The Kanji variation of the individual's first name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :first_name_kanji
# A list of alternate names or aliases that the individual is known by.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :full_name_aliases
# The individual's gender
sig { returns(T.nilable(String)) }
attr_accessor :gender
# The government-issued ID number of the individual, as appropriate for the representative's country. (Examples are a Social Security Number in the U.S., or a Social Insurance Number in Canada). Instead of the number itself, you can also provide a [PII token created with Stripe.js](/js/tokens/create_token?type=pii).
sig { returns(T.nilable(String)) }
attr_accessor :id_number
# The government-issued secondary ID number of the individual, as appropriate for the representative's country, will be used for enhanced verification checks. In Thailand, this would be the laser code found on the back of an ID card. Instead of the number itself, you can also provide a [PII token created with Stripe.js](/js/tokens/create_token?type=pii).
sig { returns(T.nilable(String)) }
attr_accessor :id_number_secondary
# The individual's last name.
sig { returns(T.nilable(String)) }
attr_accessor :last_name
# The Kana variation of the individual's last name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :last_name_kana
# The Kanji variation of the individual's last name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :last_name_kanji
# The individual's maiden name.
sig { returns(T.nilable(String)) }
attr_accessor :maiden_name
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# The individual's phone number.
sig { returns(T.nilable(String)) }
attr_accessor :phone
# Indicates if the person or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction.
sig { returns(T.nilable(String)) }
attr_accessor :political_exposure
# The individual's registered address.
sig {
returns(T.nilable(::Stripe::Token::CreateParams::Account::Individual::RegisteredAddress))
}
attr_accessor :registered_address
# Describes the person’s relationship to the account.
sig {
returns(T.nilable(::Stripe::Token::CreateParams::Account::Individual::Relationship))
}
attr_accessor :relationship
# The last four digits of the individual's Social Security Number (U.S. only).
sig { returns(T.nilable(String)) }
attr_accessor :ssn_last_4
# The individual's verification document information.
sig {
returns(T.nilable(::Stripe::Token::CreateParams::Account::Individual::Verification))
}
attr_accessor :verification
sig {
params(address: T.nilable(::Stripe::Token::CreateParams::Account::Individual::Address), address_kana: T.nilable(::Stripe::Token::CreateParams::Account::Individual::AddressKana), address_kanji: T.nilable(::Stripe::Token::CreateParams::Account::Individual::AddressKanji), dob: T.nilable(T.nilable(T.any(String, ::Stripe::Token::CreateParams::Account::Individual::Dob))), email: T.nilable(String), first_name: T.nilable(String), first_name_kana: T.nilable(String), first_name_kanji: T.nilable(String), full_name_aliases: T.nilable(T.nilable(T.any(String, T::Array[String]))), gender: T.nilable(String), id_number: T.nilable(String), id_number_secondary: T.nilable(String), last_name: T.nilable(String), last_name_kana: T.nilable(String), last_name_kanji: T.nilable(String), maiden_name: T.nilable(String), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), phone: T.nilable(String), political_exposure: T.nilable(String), registered_address: T.nilable(::Stripe::Token::CreateParams::Account::Individual::RegisteredAddress), relationship: T.nilable(::Stripe::Token::CreateParams::Account::Individual::Relationship), ssn_last_4: T.nilable(String), verification: T.nilable(::Stripe::Token::CreateParams::Account::Individual::Verification)).void
}
def initialize(
address: nil,
address_kana: nil,
address_kanji: nil,
dob: nil,
email: nil,
first_name: nil,
first_name_kana: nil,
first_name_kanji: nil,
full_name_aliases: nil,
gender: nil,
id_number: nil,
id_number_secondary: nil,
last_name: nil,
last_name_kana: nil,
last_name_kanji: nil,
maiden_name: nil,
metadata: nil,
phone: nil,
political_exposure: nil,
registered_address: nil,
relationship: nil,
ssn_last_4: nil,
verification: nil
); end
end
# The business type.
sig { returns(T.nilable(String)) }
attr_accessor :business_type
# Information about the company or business.
sig { returns(T.nilable(::Stripe::Token::CreateParams::Account::Company)) }
attr_accessor :company
# Information about the person represented by the account.
sig { returns(T.nilable(::Stripe::Token::CreateParams::Account::Individual)) }
attr_accessor :individual
# Whether the user described by the data in the token has been shown [the Stripe Connected Account Agreement](/connect/account-tokens#stripe-connected-account-agreement). When creating an account token to create a new Connect account, this value must be `true`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :tos_shown_and_accepted
sig {
params(business_type: T.nilable(String), company: T.nilable(::Stripe::Token::CreateParams::Account::Company), individual: T.nilable(::Stripe::Token::CreateParams::Account::Individual), tos_shown_and_accepted: T.nilable(T::Boolean)).void
}
def initialize(
business_type: nil,
company: nil,
individual: nil,
tos_shown_and_accepted: nil
); end
end
class BankAccount < Stripe::RequestParams
# The name of the person or business that owns the bank account. This field is required when attaching the bank account to a `Customer` object.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_name
# The type of entity that holds the account. It can be `company` or `individual`. This field is required when attaching the bank account to a `Customer` object.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_type
# The account number for the bank account, in string form. Must be a checking account.
sig { returns(String) }
attr_accessor :account_number
# The bank account type. This can only be `checking` or `savings` in most countries. In Japan, this can only be `futsu` or `toza`.
sig { returns(T.nilable(String)) }
attr_accessor :account_type
# The country in which the bank account is located.
sig { returns(String) }
attr_accessor :country
# The currency the bank account is in. This must be a country/currency pairing that [Stripe supports.](https://stripe.com/docs/payouts)
sig { returns(T.nilable(String)) }
attr_accessor :currency
# The ID of a Payment Method with a `type` of `us_bank_account`. The Payment Method's bank account information will be copied and returned as a Bank Account Token. This parameter is exclusive with respect to all other parameters in the `bank_account` hash. You must include the top-level `customer` parameter if the Payment Method is attached to a `Customer` object. If the Payment Method is not attached to a `Customer` object, it will be consumed and cannot be used again. You may not use Payment Methods which were created by a Setup Intent with `attach_to_self=true`.
sig { returns(T.nilable(String)) }
attr_accessor :payment_method
# The routing number, sort code, or other country-appropriate institution number for the bank account. For US bank accounts, this is required and should be the ACH routing number, not the wire routing number. If you are providing an IBAN for `account_number`, this field is not required.
sig { returns(T.nilable(String)) }
attr_accessor :routing_number
sig {
params(account_holder_name: T.nilable(String), account_holder_type: T.nilable(String), account_number: String, account_type: T.nilable(String), country: String, currency: T.nilable(String), payment_method: T.nilable(String), routing_number: T.nilable(String)).void
}
def initialize(
account_holder_name: nil,
account_holder_type: nil,
account_number: nil,
account_type: nil,
country: nil,
currency: nil,
payment_method: nil,
routing_number: nil
); end
end
class Card < Stripe::RequestParams
class Networks < Stripe::RequestParams
# The customer's preferred card network for co-branded cards. Supports `cartes_bancaires`, `mastercard`, or `visa`. Selection of a network that does not apply to the card will be stored as `invalid_preference` on the card.
sig { returns(T.nilable(String)) }
attr_accessor :preferred
sig { params(preferred: T.nilable(String)).void }
def initialize(preferred: nil); end
end
# City / District / Suburb / Town / Village.
sig { returns(T.nilable(String)) }
attr_accessor :address_city
# Billing address country, if provided.
sig { returns(T.nilable(String)) }
attr_accessor :address_country
# Address line 1 (Street address / PO Box / Company name).
sig { returns(T.nilable(String)) }
attr_accessor :address_line1
# Address line 2 (Apartment / Suite / Unit / Building).
sig { returns(T.nilable(String)) }
attr_accessor :address_line2
# State / County / Province / Region.
sig { returns(T.nilable(String)) }
attr_accessor :address_state
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :address_zip
# Required in order to add the card to an account; in all other cases, this parameter is not used. When added to an account, the card (which must be a debit card) can be used as a transfer destination for funds in this currency.
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Card security code. Highly recommended to always include this value.
sig { returns(T.nilable(String)) }
attr_accessor :cvc
# Two-digit number representing the card's expiration month.
sig { returns(String) }
attr_accessor :exp_month
# Two- or four-digit number representing the card's expiration year.
sig { returns(String) }
attr_accessor :exp_year
# Cardholder's full name.
sig { returns(T.nilable(String)) }
attr_accessor :name
# Contains information about card networks used to process the payment.
sig { returns(T.nilable(::Stripe::Token::CreateParams::Card::Networks)) }
attr_accessor :networks
# The card number, as a string without any separators.
sig { returns(String) }
attr_accessor :number
sig {
params(address_city: T.nilable(String), address_country: T.nilable(String), address_line1: T.nilable(String), address_line2: T.nilable(String), address_state: T.nilable(String), address_zip: T.nilable(String), currency: T.nilable(String), cvc: T.nilable(String), exp_month: String, exp_year: String, name: T.nilable(String), networks: T.nilable(::Stripe::Token::CreateParams::Card::Networks), number: String).void
}
def initialize(
address_city: nil,
address_country: nil,
address_line1: nil,
address_line2: nil,
address_state: nil,
address_zip: nil,
currency: nil,
cvc: nil,
exp_month: nil,
exp_year: nil,
name: nil,
networks: nil,
number: nil
); end
end
class CvcUpdate < Stripe::RequestParams
# The CVC value, in string form.
sig { returns(String) }
attr_accessor :cvc
sig { params(cvc: String).void }
def initialize(cvc: nil); end
end
class Person < Stripe::RequestParams
class AdditionalTosAcceptances < Stripe::RequestParams
class Account < Stripe::RequestParams
# The Unix timestamp marking when the account representative accepted the service agreement.
sig { returns(T.nilable(Integer)) }
attr_accessor :date
# The IP address from which the account representative accepted the service agreement.
sig { returns(T.nilable(String)) }
attr_accessor :ip
# The user agent of the browser from which the account representative accepted the service agreement.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :user_agent
sig {
params(date: T.nilable(Integer), ip: T.nilable(String), user_agent: T.nilable(T.nilable(String))).void
}
def initialize(date: nil, ip: nil, user_agent: nil); end
end
# Details on the legal guardian's acceptance of the main Stripe service agreement.
sig {
returns(T.nilable(::Stripe::Token::CreateParams::Person::AdditionalTosAcceptances::Account))
}
attr_accessor :account
sig {
params(account: T.nilable(::Stripe::Token::CreateParams::Person::AdditionalTosAcceptances::Account)).void
}
def initialize(account: nil); end
end
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class AddressKana < Stripe::RequestParams
# City or ward.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Block or building number.
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Building details.
sig { returns(T.nilable(String)) }
attr_accessor :line2
# Postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# Prefecture.
sig { returns(T.nilable(String)) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_accessor :town
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), town: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
class AddressKanji < Stripe::RequestParams
# City or ward.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Block or building number.
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Building details.
sig { returns(T.nilable(String)) }
attr_accessor :line2
# Postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# Prefecture.
sig { returns(T.nilable(String)) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_accessor :town
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), town: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
class Dob < Stripe::RequestParams
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
class Documents < Stripe::RequestParams
class CompanyAuthorization < Stripe::RequestParams
# One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :files
sig { params(files: T.nilable(T::Array[String])).void }
def initialize(files: nil); end
end
class Passport < Stripe::RequestParams
# One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :files
sig { params(files: T.nilable(T::Array[String])).void }
def initialize(files: nil); end
end
class Visa < Stripe::RequestParams
# One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :files
sig { params(files: T.nilable(T::Array[String])).void }
def initialize(files: nil); end
end
# One or more documents that demonstrate proof that this person is authorized to represent the company.
sig {
returns(T.nilable(::Stripe::Token::CreateParams::Person::Documents::CompanyAuthorization))
}
attr_accessor :company_authorization
# One or more documents showing the person's passport page with photo and personal data.
sig { returns(T.nilable(::Stripe::Token::CreateParams::Person::Documents::Passport)) }
attr_accessor :passport
# One or more documents showing the person's visa required for living in the country where they are residing.
sig { returns(T.nilable(::Stripe::Token::CreateParams::Person::Documents::Visa)) }
attr_accessor :visa
sig {
params(company_authorization: T.nilable(::Stripe::Token::CreateParams::Person::Documents::CompanyAuthorization), passport: T.nilable(::Stripe::Token::CreateParams::Person::Documents::Passport), visa: T.nilable(::Stripe::Token::CreateParams::Person::Documents::Visa)).void
}
def initialize(company_authorization: nil, passport: nil, visa: nil); end
end
class RegisteredAddress < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class Relationship < Stripe::RequestParams
# Whether the person is the authorizer of the account's representative.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :authorizer
# Whether the person is a director of the account's legal entity. Directors are typically members of the governing board of the company, or responsible for ensuring the company meets its regulatory obligations.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :director
# Whether the person has significant responsibility to control, manage, or direct the organization.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :executive
# Whether the person is the legal guardian of the account's representative.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :legal_guardian
# Whether the person is an owner of the account’s legal entity.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :owner
# The percent owned by the person of the account's legal entity.
sig { returns(T.nilable(T.nilable(T.any(String, Float)))) }
attr_accessor :percent_ownership
# Whether the person is authorized as the primary representative of the account. This is the person nominated by the business to provide information about themselves, and general information about the account. There can only be one representative at any given time. At the time the account is created, this person should be set to the person responsible for opening the account.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :representative
# The person's title (e.g., CEO, Support Engineer).
sig { returns(T.nilable(String)) }
attr_accessor :title
sig {
params(authorizer: T.nilable(T::Boolean), director: T.nilable(T::Boolean), executive: T.nilable(T::Boolean), legal_guardian: T.nilable(T::Boolean), owner: T.nilable(T::Boolean), percent_ownership: T.nilable(T.nilable(T.any(String, Float))), representative: T.nilable(T::Boolean), title: T.nilable(String)).void
}
def initialize(
authorizer: nil,
director: nil,
executive: nil,
legal_guardian: nil,
owner: nil,
percent_ownership: nil,
representative: nil,
title: nil
); end
end
class UsCfpbData < Stripe::RequestParams
class EthnicityDetails < Stripe::RequestParams
# The persons ethnicity
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :ethnicity
# Please specify your origin, when other is selected.
sig { returns(T.nilable(String)) }
attr_accessor :ethnicity_other
sig {
params(ethnicity: T.nilable(T::Array[String]), ethnicity_other: T.nilable(String)).void
}
def initialize(ethnicity: nil, ethnicity_other: nil); end
end
class RaceDetails < Stripe::RequestParams
# The persons race.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :race
# Please specify your race, when other is selected.
sig { returns(T.nilable(String)) }
attr_accessor :race_other
sig { params(race: T.nilable(T::Array[String]), race_other: T.nilable(String)).void }
def initialize(race: nil, race_other: nil); end
end
# The persons ethnicity details
sig {
returns(T.nilable(::Stripe::Token::CreateParams::Person::UsCfpbData::EthnicityDetails))
}
attr_accessor :ethnicity_details
# The persons race details
sig { returns(T.nilable(::Stripe::Token::CreateParams::Person::UsCfpbData::RaceDetails)) }
attr_accessor :race_details
# The persons self-identified gender
sig { returns(T.nilable(String)) }
attr_accessor :self_identified_gender
sig {
params(ethnicity_details: T.nilable(::Stripe::Token::CreateParams::Person::UsCfpbData::EthnicityDetails), race_details: T.nilable(::Stripe::Token::CreateParams::Person::UsCfpbData::RaceDetails), self_identified_gender: T.nilable(String)).void
}
def initialize(
ethnicity_details: nil,
race_details: nil,
self_identified_gender: nil
); end
end
class Verification < Stripe::RequestParams
class AdditionalDocument < Stripe::RequestParams
# The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :back
# The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :front
sig { params(back: T.nilable(String), front: T.nilable(String)).void }
def initialize(back: nil, front: nil); end
end
class Document < Stripe::RequestParams
# The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :back
# The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :front
sig { params(back: T.nilable(String), front: T.nilable(String)).void }
def initialize(back: nil, front: nil); end
end
# A document showing address, either a passport, local ID card, or utility bill from a well-known utility company.
sig {
returns(T.nilable(::Stripe::Token::CreateParams::Person::Verification::AdditionalDocument))
}
attr_accessor :additional_document
# An identifying document, either a passport or local ID card.
sig { returns(T.nilable(::Stripe::Token::CreateParams::Person::Verification::Document)) }
attr_accessor :document
sig {
params(additional_document: T.nilable(::Stripe::Token::CreateParams::Person::Verification::AdditionalDocument), document: T.nilable(::Stripe::Token::CreateParams::Person::Verification::Document)).void
}
def initialize(additional_document: nil, document: nil); end
end
# Details on the legal guardian's or authorizer's acceptance of the required Stripe agreements.
sig { returns(T.nilable(::Stripe::Token::CreateParams::Person::AdditionalTosAcceptances)) }
attr_accessor :additional_tos_acceptances
# The person's address.
sig { returns(T.nilable(::Stripe::Token::CreateParams::Person::Address)) }
attr_accessor :address
# The Kana variation of the person's address (Japan only).
sig { returns(T.nilable(::Stripe::Token::CreateParams::Person::AddressKana)) }
attr_accessor :address_kana
# The Kanji variation of the person's address (Japan only).
sig { returns(T.nilable(::Stripe::Token::CreateParams::Person::AddressKanji)) }
attr_accessor :address_kanji
# The person's date of birth.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Token::CreateParams::Person::Dob))))
}
attr_accessor :dob
# Documents that may be submitted to satisfy various informational requests.
sig { returns(T.nilable(::Stripe::Token::CreateParams::Person::Documents)) }
attr_accessor :documents
# The person's email address.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The person's first name.
sig { returns(T.nilable(String)) }
attr_accessor :first_name
# The Kana variation of the person's first name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :first_name_kana
# The Kanji variation of the person's first name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :first_name_kanji
# A list of alternate names or aliases that the person is known by.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :full_name_aliases
# The person's gender (International regulations require either "male" or "female").
sig { returns(T.nilable(String)) }
attr_accessor :gender
# The person's ID number, as appropriate for their country. For example, a social security number in the U.S., social insurance number in Canada, etc. Instead of the number itself, you can also provide a [PII token provided by Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).
sig { returns(T.nilable(String)) }
attr_accessor :id_number
# The person's secondary ID number, as appropriate for their country, will be used for enhanced verification checks. In Thailand, this would be the laser code found on the back of an ID card. Instead of the number itself, you can also provide a [PII token provided by Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).
sig { returns(T.nilable(String)) }
attr_accessor :id_number_secondary
# The person's last name.
sig { returns(T.nilable(String)) }
attr_accessor :last_name
# The Kana variation of the person's last name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :last_name_kana
# The Kanji variation of the person's last name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :last_name_kanji
# The person's maiden name.
sig { returns(T.nilable(String)) }
attr_accessor :maiden_name
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# The country where the person is a national. Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)), or "XX" if unavailable.
sig { returns(T.nilable(String)) }
attr_accessor :nationality
# The person's phone number.
sig { returns(T.nilable(String)) }
attr_accessor :phone
# Indicates if the person or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction.
sig { returns(T.nilable(String)) }
attr_accessor :political_exposure
# The person's registered address.
sig { returns(T.nilable(::Stripe::Token::CreateParams::Person::RegisteredAddress)) }
attr_accessor :registered_address
# The relationship that this person has with the account's legal entity.
sig { returns(T.nilable(::Stripe::Token::CreateParams::Person::Relationship)) }
attr_accessor :relationship
# The last four digits of the person's Social Security number (U.S. only).
sig { returns(T.nilable(String)) }
attr_accessor :ssn_last_4
# Demographic data related to the person.
sig { returns(T.nilable(::Stripe::Token::CreateParams::Person::UsCfpbData)) }
attr_accessor :us_cfpb_data
# The person's verification status.
sig { returns(T.nilable(::Stripe::Token::CreateParams::Person::Verification)) }
attr_accessor :verification
sig {
params(additional_tos_acceptances: T.nilable(::Stripe::Token::CreateParams::Person::AdditionalTosAcceptances), address: T.nilable(::Stripe::Token::CreateParams::Person::Address), address_kana: T.nilable(::Stripe::Token::CreateParams::Person::AddressKana), address_kanji: T.nilable(::Stripe::Token::CreateParams::Person::AddressKanji), dob: T.nilable(T.nilable(T.any(String, ::Stripe::Token::CreateParams::Person::Dob))), documents: T.nilable(::Stripe::Token::CreateParams::Person::Documents), email: T.nilable(String), first_name: T.nilable(String), first_name_kana: T.nilable(String), first_name_kanji: T.nilable(String), full_name_aliases: T.nilable(T.nilable(T.any(String, T::Array[String]))), gender: T.nilable(String), id_number: T.nilable(String), id_number_secondary: T.nilable(String), last_name: T.nilable(String), last_name_kana: T.nilable(String), last_name_kanji: T.nilable(String), maiden_name: T.nilable(String), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), nationality: T.nilable(String), phone: T.nilable(String), political_exposure: T.nilable(String), registered_address: T.nilable(::Stripe::Token::CreateParams::Person::RegisteredAddress), relationship: T.nilable(::Stripe::Token::CreateParams::Person::Relationship), ssn_last_4: T.nilable(String), us_cfpb_data: T.nilable(::Stripe::Token::CreateParams::Person::UsCfpbData), verification: T.nilable(::Stripe::Token::CreateParams::Person::Verification)).void
}
def initialize(
additional_tos_acceptances: nil,
address: nil,
address_kana: nil,
address_kanji: nil,
dob: nil,
documents: nil,
email: nil,
first_name: nil,
first_name_kana: nil,
first_name_kanji: nil,
full_name_aliases: nil,
gender: nil,
id_number: nil,
id_number_secondary: nil,
last_name: nil,
last_name_kana: nil,
last_name_kanji: nil,
maiden_name: nil,
metadata: nil,
nationality: nil,
phone: nil,
political_exposure: nil,
registered_address: nil,
relationship: nil,
ssn_last_4: nil,
us_cfpb_data: nil,
verification: nil
); end
end
class Pii < Stripe::RequestParams
# The `id_number` for the PII, in string form.
sig { returns(T.nilable(String)) }
attr_accessor :id_number
sig { params(id_number: T.nilable(String)).void }
def initialize(id_number: nil); end
end
# Information for the account this token represents.
sig { returns(T.nilable(::Stripe::Token::CreateParams::Account)) }
attr_accessor :account
# The bank account this token will represent.
sig { returns(T.nilable(::Stripe::Token::CreateParams::BankAccount)) }
attr_accessor :bank_account
# The card this token will represent. If you also pass in a customer, the card must be the ID of a card belonging to the customer. Otherwise, if you do not pass in a customer, this is a dictionary containing a user's credit card details, with the options described below.
sig { returns(T.nilable(T.any(::Stripe::Token::CreateParams::Card, String))) }
attr_accessor :card
# Create a token for the customer, which is owned by the application's account. You can only use this with an [OAuth access token](https://stripe.com/docs/connect/standard-accounts) or [Stripe-Account header](https://stripe.com/docs/connect/authentication). Learn more about [cloning saved payment methods](https://stripe.com/docs/connect/cloning-saved-payment-methods).
sig { returns(T.nilable(String)) }
attr_accessor :customer
# The updated CVC value this token represents.
sig { returns(T.nilable(::Stripe::Token::CreateParams::CvcUpdate)) }
attr_accessor :cvc_update
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Information for the person this token represents.
sig { returns(T.nilable(::Stripe::Token::CreateParams::Person)) }
attr_accessor :person
# The PII this token represents.
sig { returns(T.nilable(::Stripe::Token::CreateParams::Pii)) }
attr_accessor :pii
sig {
params(account: T.nilable(::Stripe::Token::CreateParams::Account), bank_account: T.nilable(::Stripe::Token::CreateParams::BankAccount), card: T.nilable(T.any(::Stripe::Token::CreateParams::Card, String)), customer: T.nilable(String), cvc_update: T.nilable(::Stripe::Token::CreateParams::CvcUpdate), expand: T.nilable(T::Array[String]), person: T.nilable(::Stripe::Token::CreateParams::Person), pii: T.nilable(::Stripe::Token::CreateParams::Pii)).void
}
def initialize(
account: nil,
bank_account: nil,
card: nil,
customer: nil,
cvc_update: nil,
expand: nil,
person: nil,
pii: nil
); end
end
# Creates a single-use token that represents a bank account's details.
# You can use this token with any v1 API method in place of a bank account dictionary. You can only use this token once. To do so, attach it to a [connected account](https://docs.stripe.com/api#accounts) where [controller.requirement_collection](https://docs.stripe.com/api/accounts/object#account_object-controller-requirement_collection) is application, which includes Custom accounts.
sig {
params(params: T.any(::Stripe::Token::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Token)
}
def self.create(params = {}, opts = {}); end
end
end
# typed: true
module Stripe
# To top up your Stripe balance, you create a top-up object. You can retrieve
# individual top-ups, as well as list all top-ups. Top-ups are identified by a
# unique, random ID.
#
# Related guide: [Topping up your platform account](https://stripe.com/docs/connect/top-ups)
class Topup < APIResource
# Amount transferred.
sig { returns(Integer) }
attr_reader :amount
# ID of the balance transaction that describes the impact of this top-up on your account balance. May not be specified depending on status of top-up.
sig { returns(T.nilable(T.any(String, Stripe::BalanceTransaction))) }
attr_reader :balance_transaction
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# 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).
sig { returns(String) }
attr_reader :currency
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_reader :description
# Date the funds are expected to arrive in your Stripe account for payouts. This factors in delays like weekends or bank holidays. May not be specified depending on status of top-up.
sig { returns(T.nilable(Integer)) }
attr_reader :expected_availability_date
# Error code explaining reason for top-up failure if available (see [the errors section](https://stripe.com/docs/api#errors) for a list of codes).
sig { returns(T.nilable(String)) }
attr_reader :failure_code
# Message to user further explaining reason for top-up failure if available.
sig { returns(T.nilable(String)) }
attr_reader :failure_message
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# 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.
sig { returns(T::Hash[String, String]) }
attr_reader :metadata
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The source field is deprecated. It might not always be present in the API response.
sig { returns(T.nilable(Stripe::Source)) }
attr_reader :source
# Extra information about a top-up. This will appear on your source's bank statement. It must contain at least one letter.
sig { returns(T.nilable(String)) }
attr_reader :statement_descriptor
# The status of the top-up is either `canceled`, `failed`, `pending`, `reversed`, or `succeeded`.
sig { returns(String) }
attr_reader :status
# A string that identifies this top-up as part of a group.
sig { returns(T.nilable(String)) }
attr_reader :transfer_group
class ListParams < Stripe::RequestParams
class Amount < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# A positive integer representing how much to transfer.
sig { returns(T.nilable(T.any(::Stripe::Topup::ListParams::Amount, Integer))) }
attr_accessor :amount
# A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.
sig { returns(T.nilable(T.any(::Stripe::Topup::ListParams::Created, Integer))) }
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return top-ups that have the given status. One of `canceled`, `failed`, `pending` or `succeeded`.
sig { returns(T.nilable(String)) }
attr_accessor :status
sig {
params(amount: T.nilable(T.any(::Stripe::Topup::ListParams::Amount, Integer)), created: T.nilable(T.any(::Stripe::Topup::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String), status: T.nilable(String)).void
}
def initialize(
amount: nil,
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil,
status: nil
); end
end
class CreateParams < Stripe::RequestParams
# A positive integer representing how much to transfer.
sig { returns(Integer) }
attr_accessor :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).
sig { returns(String) }
attr_accessor :currency
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# The ID of a source to transfer funds from. For most users, this should be left unspecified which will use the bank account that was set up in the dashboard for the specified currency. In test mode, this can be a test bank token (see [Testing Top-ups](https://stripe.com/docs/connect/testing#testing-top-ups)).
sig { returns(T.nilable(String)) }
attr_accessor :source
# Extra information about a top-up for the source's bank statement. Limited to 15 ASCII characters.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
# A string that identifies this top-up as part of a group.
sig { returns(T.nilable(String)) }
attr_accessor :transfer_group
sig {
params(amount: Integer, currency: String, description: T.nilable(String), expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), source: T.nilable(String), statement_descriptor: T.nilable(String), transfer_group: T.nilable(String)).void
}
def initialize(
amount: nil,
currency: nil,
description: nil,
expand: nil,
metadata: nil,
source: nil,
statement_descriptor: nil,
transfer_group: nil
); end
end
class UpdateParams < Stripe::RequestParams
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
sig {
params(description: T.nilable(String), expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String])))).void
}
def initialize(description: nil, expand: nil, metadata: nil); end
end
class CancelParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Cancels a top-up. Only pending top-ups can be canceled.
sig {
params(params: T.any(::Stripe::Topup::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Topup)
}
def cancel(params = {}, opts = {}); end
# Cancels a top-up. Only pending top-ups can be canceled.
sig {
params(topup: String, params: T.any(::Stripe::Topup::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Topup)
}
def self.cancel(topup, params = {}, opts = {}); end
# Top up the balance of an account
sig {
params(params: T.any(::Stripe::Topup::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Topup)
}
def self.create(params = {}, opts = {}); end
# Returns a list of top-ups.
sig {
params(params: T.any(::Stripe::Topup::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Updates the metadata of a top-up. Other top-up details are not editable by design.
sig {
params(topup: String, params: T.any(::Stripe::Topup::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Topup)
}
def self.update(topup, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
# A `Transfer` object is created when you move funds between Stripe accounts as
# part of Connect.
#
# Before April 6, 2017, transfers also represented movement of funds from a
# Stripe account to a card or bank account. This behavior has since been split
# out into a [Payout](https://stripe.com/docs/api#payout_object) object, with corresponding payout endpoints. For more
# information, read about the
# [transfer/payout split](https://stripe.com/docs/transfer-payout-split).
#
# Related guide: [Creating separate charges and transfers](https://stripe.com/docs/connect/separate-charges-and-transfers)
class Transfer < APIResource
# Amount in cents (or local equivalent) to be transferred.
sig { returns(Integer) }
attr_reader :amount
# Amount in cents (or local equivalent) reversed (can be less than the amount attribute on the transfer if a partial reversal was issued).
sig { returns(Integer) }
attr_reader :amount_reversed
# Balance transaction that describes the impact of this transfer on your account balance.
sig { returns(T.nilable(T.any(String, Stripe::BalanceTransaction))) }
attr_reader :balance_transaction
# Time that this record of the transfer was first created.
sig { returns(Integer) }
attr_reader :created
# 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).
sig { returns(String) }
attr_reader :currency
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_reader :description
# ID of the Stripe account the transfer was sent to.
sig { returns(T.nilable(T.any(String, Stripe::Account))) }
attr_reader :destination
# If the destination is a Stripe account, this will be the ID of the payment that the destination account received for the transfer.
sig { returns(T.any(String, Stripe::Charge)) }
attr_reader :destination_payment
# The FX Quote used for the transfer.
sig { returns(String) }
attr_reader :fx_quote
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# 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.
sig { returns(T::Hash[String, String]) }
attr_reader :metadata
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# A list of reversals that have been applied to the transfer.
sig { returns(Stripe::ListObject) }
attr_reader :reversals
# Whether the transfer has been fully reversed. If the transfer is only partially reversed, this attribute will still be false.
sig { returns(T::Boolean) }
attr_reader :reversed
# ID of the charge that was used to fund the transfer. If null, the transfer was funded from the available balance.
sig { returns(T.nilable(T.any(String, Stripe::Charge))) }
attr_reader :source_transaction
# The source balance this transfer came from. One of `card`, `fpx`, or `bank_account`.
sig { returns(String) }
attr_reader :source_type
# A string that identifies this transaction as part of a group. See the [Connect documentation](https://stripe.com/docs/connect/separate-charges-and-transfers#transfer-options) for details.
sig { returns(T.nilable(String)) }
attr_reader :transfer_group
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return transfers that were created during the given date interval.
sig { returns(T.nilable(T.any(::Stripe::Transfer::ListParams::Created, Integer))) }
attr_accessor :created
# Only return transfers for the destination specified by this account ID.
sig { returns(T.nilable(String)) }
attr_accessor :destination
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return transfers with the specified transfer group.
sig { returns(T.nilable(String)) }
attr_accessor :transfer_group
sig {
params(created: T.nilable(T.any(::Stripe::Transfer::ListParams::Created, Integer)), destination: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String), transfer_group: T.nilable(String)).void
}
def initialize(
created: nil,
destination: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil,
transfer_group: nil
); end
end
class CreateParams < Stripe::RequestParams
# A positive integer in cents (or local equivalent) representing how much to transfer.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# Three-letter [ISO code for currency](https://www.iso.org/iso-4217-currency-codes.html) in lowercase. Must be a [supported currency](https://docs.stripe.com/currencies).
sig { returns(String) }
attr_accessor :currency
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# The ID of a connected Stripe account. See the Connect documentation for details.
sig { returns(String) }
attr_accessor :destination
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The FX rate in the quote is validated and used to convert the transfer amount to the destination currency.
sig { returns(T.nilable(String)) }
attr_accessor :fx_quote
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# You can use this parameter to transfer funds from a charge before they are added to your available balance. A pending balance will transfer immediately but the funds will not become available until the original charge becomes available. [See the Connect documentation](https://stripe.com/docs/connect/separate-charges-and-transfers#transfer-availability) for details.
sig { returns(T.nilable(String)) }
attr_accessor :source_transaction
# The source balance to use for this transfer. One of `bank_account`, `card`, or `fpx`. For most users, this will default to `card`.
sig { returns(T.nilable(String)) }
attr_accessor :source_type
# A string that identifies this transaction as part of a group. See the [Connect documentation](https://stripe.com/docs/connect/separate-charges-and-transfers#transfer-options) for details.
sig { returns(T.nilable(String)) }
attr_accessor :transfer_group
sig {
params(amount: T.nilable(Integer), currency: String, description: T.nilable(String), destination: String, expand: T.nilable(T::Array[String]), fx_quote: T.nilable(String), metadata: T.nilable(T::Hash[String, String]), source_transaction: T.nilable(String), source_type: T.nilable(String), transfer_group: T.nilable(String)).void
}
def initialize(
amount: nil,
currency: nil,
description: nil,
destination: nil,
expand: nil,
fx_quote: nil,
metadata: nil,
source_transaction: nil,
source_type: nil,
transfer_group: nil
); end
end
class UpdateParams < Stripe::RequestParams
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
sig {
params(description: T.nilable(String), expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String])))).void
}
def initialize(description: nil, expand: nil, metadata: nil); end
end
# To send funds from your Stripe account to a connected account, you create a new transfer object. Your [Stripe balance](https://docs.stripe.com/api#balance) must be able to cover the transfer amount, or you'll receive an “Insufficient Funds” error.
sig {
params(params: T.any(::Stripe::Transfer::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Transfer)
}
def self.create(params = {}, opts = {}); end
# Returns a list of existing transfers sent to connected accounts. The transfers are returned in sorted order, with the most recently created transfers appearing first.
sig {
params(params: T.any(::Stripe::Transfer::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Updates the specified transfer by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
#
# This request accepts only metadata as an argument.
sig {
params(transfer: String, params: T.any(::Stripe::Transfer::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Transfer)
}
def self.update(transfer, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
# [Stripe Connect](https://stripe.com/docs/connect) platforms can reverse transfers made to a
# connected account, either entirely or partially, and can also specify whether
# to refund any related application fees. Transfer reversals add to the
# platform's balance and subtract from the destination account's balance.
#
# Reversing a transfer that was made for a [destination
# charge](https://docs.stripe.com/docs/connect/destination-charges) is allowed only up to the amount of
# the charge. It is possible to reverse a
# [transfer_group](https://stripe.com/docs/connect/separate-charges-and-transfers#transfer-options)
# transfer only if the destination account has enough balance to cover the
# reversal.
#
# Related guide: [Reverse transfers](https://stripe.com/docs/connect/separate-charges-and-transfers#reverse-transfers)
class Reversal < APIResource
# Amount, in cents (or local equivalent).
sig { returns(Integer) }
attr_reader :amount
# Balance transaction that describes the impact on your account balance.
sig { returns(T.nilable(T.any(String, Stripe::BalanceTransaction))) }
attr_reader :balance_transaction
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# 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).
sig { returns(String) }
attr_reader :currency
# Linked payment refund for the transfer reversal.
sig { returns(T.nilable(T.any(String, Stripe::Refund))) }
attr_reader :destination_payment_refund
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# 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.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# ID of the refund responsible for the transfer reversal.
sig { returns(T.nilable(T.any(String, Stripe::Refund))) }
attr_reader :source_refund
# ID of the transfer that was reversed.
sig { returns(T.any(String, Stripe::Transfer)) }
attr_reader :transfer
end
end
# typed: true
module Stripe
module Treasury
# You can reverse some [ReceivedCredits](https://stripe.com/docs/api#received_credits) depending on their network and source flow. Reversing a ReceivedCredit leads to the creation of a new object known as a CreditReversal.
class CreditReversal < APIResource
class StatusTransitions < Stripe::StripeObject
# Timestamp describing when the CreditReversal changed status to `posted`
sig { returns(T.nilable(Integer)) }
attr_reader :posted_at
end
# Amount (in cents) transferred.
sig { returns(Integer) }
attr_reader :amount
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# 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).
sig { returns(String) }
attr_reader :currency
# The FinancialAccount to reverse funds from.
sig { returns(String) }
attr_reader :financial_account
# A [hosted transaction receipt](https://stripe.com/docs/treasury/moving-money/regulatory-receipts) URL that is provided when money movement is considered regulated under Stripe's money transmission licenses.
sig { returns(T.nilable(String)) }
attr_reader :hosted_regulatory_receipt_url
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# 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.
sig { returns(T::Hash[String, String]) }
attr_reader :metadata
# The rails used to reverse the funds.
sig { returns(String) }
attr_reader :network
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The ReceivedCredit being reversed.
sig { returns(String) }
attr_reader :received_credit
# Status of the CreditReversal
sig { returns(String) }
attr_reader :status
# Attribute for field status_transitions
sig { returns(StatusTransitions) }
attr_reader :status_transitions
# The Transaction associated with this object.
sig { returns(T.nilable(T.any(String, Stripe::Treasury::Transaction))) }
attr_reader :transaction
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Returns objects associated with this FinancialAccount.
sig { returns(String) }
attr_accessor :financial_account
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Only return CreditReversals for the ReceivedCredit ID.
sig { returns(T.nilable(String)) }
attr_accessor :received_credit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return CreditReversals for a given status.
sig { returns(T.nilable(String)) }
attr_accessor :status
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), financial_account: String, limit: T.nilable(Integer), received_credit: T.nilable(String), starting_after: T.nilable(String), status: T.nilable(String)).void
}
def initialize(
ending_before: nil,
expand: nil,
financial_account: nil,
limit: nil,
received_credit: nil,
starting_after: nil,
status: nil
); end
end
class CreateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The ReceivedCredit to reverse.
sig { returns(String) }
attr_accessor :received_credit
sig {
params(expand: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), received_credit: String).void
}
def initialize(expand: nil, metadata: nil, received_credit: nil); end
end
# Reverses a ReceivedCredit and creates a CreditReversal object.
sig {
params(params: T.any(::Stripe::Treasury::CreditReversal::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::CreditReversal)
}
def self.create(params = {}, opts = {}); end
# Returns a list of CreditReversals.
sig {
params(params: T.any(::Stripe::Treasury::CreditReversal::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Treasury
# You can reverse some [ReceivedDebits](https://stripe.com/docs/api#received_debits) depending on their network and source flow. Reversing a ReceivedDebit leads to the creation of a new object known as a DebitReversal.
class DebitReversal < APIResource
class LinkedFlows < Stripe::StripeObject
# Set if there is an Issuing dispute associated with the DebitReversal.
sig { returns(T.nilable(String)) }
attr_reader :issuing_dispute
end
class StatusTransitions < Stripe::StripeObject
# Timestamp describing when the DebitReversal changed status to `completed`.
sig { returns(T.nilable(Integer)) }
attr_reader :completed_at
end
# Amount (in cents) transferred.
sig { returns(Integer) }
attr_reader :amount
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# 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).
sig { returns(String) }
attr_reader :currency
# The FinancialAccount to reverse funds from.
sig { returns(T.nilable(String)) }
attr_reader :financial_account
# A [hosted transaction receipt](https://stripe.com/docs/treasury/moving-money/regulatory-receipts) URL that is provided when money movement is considered regulated under Stripe's money transmission licenses.
sig { returns(T.nilable(String)) }
attr_reader :hosted_regulatory_receipt_url
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Other flows linked to a DebitReversal.
sig { returns(T.nilable(LinkedFlows)) }
attr_reader :linked_flows
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# 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.
sig { returns(T::Hash[String, String]) }
attr_reader :metadata
# The rails used to reverse the funds.
sig { returns(String) }
attr_reader :network
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The ReceivedDebit being reversed.
sig { returns(String) }
attr_reader :received_debit
# Status of the DebitReversal
sig { returns(String) }
attr_reader :status
# Attribute for field status_transitions
sig { returns(StatusTransitions) }
attr_reader :status_transitions
# The Transaction associated with this object.
sig { returns(T.nilable(T.any(String, Stripe::Treasury::Transaction))) }
attr_reader :transaction
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Returns objects associated with this FinancialAccount.
sig { returns(String) }
attr_accessor :financial_account
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Only return DebitReversals for the ReceivedDebit ID.
sig { returns(T.nilable(String)) }
attr_accessor :received_debit
# Only return DebitReversals for a given resolution.
sig { returns(T.nilable(String)) }
attr_accessor :resolution
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return DebitReversals for a given status.
sig { returns(T.nilable(String)) }
attr_accessor :status
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), financial_account: String, limit: T.nilable(Integer), received_debit: T.nilable(String), resolution: T.nilable(String), starting_after: T.nilable(String), status: T.nilable(String)).void
}
def initialize(
ending_before: nil,
expand: nil,
financial_account: nil,
limit: nil,
received_debit: nil,
resolution: nil,
starting_after: nil,
status: nil
); end
end
class CreateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The ReceivedDebit to reverse.
sig { returns(String) }
attr_accessor :received_debit
sig {
params(expand: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), received_debit: String).void
}
def initialize(expand: nil, metadata: nil, received_debit: nil); end
end
# Reverses a ReceivedDebit and creates a DebitReversal object.
sig {
params(params: T.any(::Stripe::Treasury::DebitReversal::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::DebitReversal)
}
def self.create(params = {}, opts = {}); end
# Returns a list of DebitReversals.
sig {
params(params: T.any(::Stripe::Treasury::DebitReversal::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Treasury
# Stripe Treasury provides users with a container for money called a FinancialAccount that is separate from their Payments balance.
# FinancialAccounts serve as the source and destination of Treasury's money movement APIs.
class FinancialAccount < APIResource
class Balance < Stripe::StripeObject
# Funds the user can spend right now.
sig { returns(T::Hash[String, Integer]) }
attr_reader :cash
# Funds not spendable yet, but will become available at a later time.
sig { returns(T::Hash[String, Integer]) }
attr_reader :inbound_pending
# Funds in the account, but not spendable because they are being held for pending outbound flows.
sig { returns(T::Hash[String, Integer]) }
attr_reader :outbound_pending
end
class FinancialAddress < Stripe::StripeObject
class Aba < Stripe::StripeObject
# The name of the person or business that owns the bank account.
sig { returns(String) }
attr_reader :account_holder_name
# The account number.
sig { returns(T.nilable(String)) }
attr_reader :account_number
# The last four characters of the account number.
sig { returns(String) }
attr_reader :account_number_last4
# Name of the bank.
sig { returns(String) }
attr_reader :bank_name
# Routing number for the account.
sig { returns(String) }
attr_reader :routing_number
end
# ABA Records contain U.S. bank account details per the ABA format.
sig { returns(Aba) }
attr_reader :aba
# The list of networks that the address supports
sig { returns(T::Array[String]) }
attr_reader :supported_networks
# The type of financial address
sig { returns(String) }
attr_reader :type
end
class PlatformRestrictions < Stripe::StripeObject
# Restricts all inbound money movement.
sig { returns(T.nilable(String)) }
attr_reader :inbound_flows
# Restricts all outbound money movement.
sig { returns(T.nilable(String)) }
attr_reader :outbound_flows
end
class StatusDetails < Stripe::StripeObject
class Closed < Stripe::StripeObject
# The array that contains reasons for a FinancialAccount closure.
sig { returns(T::Array[String]) }
attr_reader :reasons
end
# Details related to the closure of this FinancialAccount
sig { returns(T.nilable(Closed)) }
attr_reader :closed
end
# The array of paths to active Features in the Features hash.
sig { returns(T::Array[String]) }
attr_reader :active_features
# Balance information for the FinancialAccount
sig { returns(Balance) }
attr_reader :balance
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(String) }
attr_reader :country
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# The display name for the FinancialAccount. Use this field to customize the names of the FinancialAccounts for your connected accounts. Unlike the `nickname` field, `display_name` is not internal metadata and will be exposed to connected accounts.
sig { returns(T.nilable(String)) }
attr_reader :display_name
# Encodes whether a FinancialAccount has access to a particular Feature, with a `status` enum and associated `status_details`.
# Stripe or the platform can control Features via the requested field.
sig { returns(Stripe::Treasury::FinancialAccountFeatures) }
attr_reader :features
# The set of credentials that resolve to a FinancialAccount.
sig { returns(T::Array[FinancialAddress]) }
attr_reader :financial_addresses
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Attribute for field is_default
sig { returns(T::Boolean) }
attr_reader :is_default
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# 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.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_reader :metadata
# The nickname for the FinancialAccount.
sig { returns(T.nilable(String)) }
attr_reader :nickname
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The array of paths to pending Features in the Features hash.
sig { returns(T::Array[String]) }
attr_reader :pending_features
# The set of functionalities that the platform can restrict on the FinancialAccount.
sig { returns(T.nilable(PlatformRestrictions)) }
attr_reader :platform_restrictions
# The array of paths to restricted Features in the Features hash.
sig { returns(T::Array[String]) }
attr_reader :restricted_features
# Status of this FinancialAccount.
sig { returns(String) }
attr_reader :status
# Attribute for field status_details
sig { returns(StatusDetails) }
attr_reader :status_details
# The currencies the FinancialAccount can hold a balance in. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase.
sig { returns(T::Array[String]) }
attr_reader :supported_currencies
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return FinancialAccounts that were created during the given date interval.
sig {
returns(T.nilable(T.any(::Stripe::Treasury::FinancialAccount::ListParams::Created, Integer)))
}
attr_accessor :created
# An object ID cursor for use in pagination.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit ranging from 1 to 100 (defaults to 10).
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# An object ID cursor for use in pagination.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(created: T.nilable(T.any(::Stripe::Treasury::FinancialAccount::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class Features < Stripe::RequestParams
class CardIssuing < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class DepositInsurance < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class FinancialAddresses < Stripe::RequestParams
class Aba < Stripe::RequestParams
# Requested bank partner
sig { returns(T.nilable(String)) }
attr_accessor :bank
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(bank: T.nilable(String), requested: T::Boolean).void }
def initialize(bank: nil, requested: nil); end
end
# Adds an ABA FinancialAddress to the FinancialAccount.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccount::CreateParams::Features::FinancialAddresses::Aba))
}
attr_accessor :aba
sig {
params(aba: T.nilable(::Stripe::Treasury::FinancialAccount::CreateParams::Features::FinancialAddresses::Aba)).void
}
def initialize(aba: nil); end
end
class InboundTransfers < Stripe::RequestParams
class Ach < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
# Enables ACH Debits via the InboundTransfers API.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccount::CreateParams::Features::InboundTransfers::Ach))
}
attr_accessor :ach
sig {
params(ach: T.nilable(::Stripe::Treasury::FinancialAccount::CreateParams::Features::InboundTransfers::Ach)).void
}
def initialize(ach: nil); end
end
class IntraStripeFlows < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class OutboundPayments < Stripe::RequestParams
class Ach < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class UsDomesticWire < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
# Enables ACH transfers via the OutboundPayments API.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccount::CreateParams::Features::OutboundPayments::Ach))
}
attr_accessor :ach
# Enables US domestic wire transfers via the OutboundPayments API.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccount::CreateParams::Features::OutboundPayments::UsDomesticWire))
}
attr_accessor :us_domestic_wire
sig {
params(ach: T.nilable(::Stripe::Treasury::FinancialAccount::CreateParams::Features::OutboundPayments::Ach), us_domestic_wire: T.nilable(::Stripe::Treasury::FinancialAccount::CreateParams::Features::OutboundPayments::UsDomesticWire)).void
}
def initialize(ach: nil, us_domestic_wire: nil); end
end
class OutboundTransfers < Stripe::RequestParams
class Ach < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class UsDomesticWire < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
# Enables ACH transfers via the OutboundTransfers API.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccount::CreateParams::Features::OutboundTransfers::Ach))
}
attr_accessor :ach
# Enables US domestic wire transfers via the OutboundTransfers API.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccount::CreateParams::Features::OutboundTransfers::UsDomesticWire))
}
attr_accessor :us_domestic_wire
sig {
params(ach: T.nilable(::Stripe::Treasury::FinancialAccount::CreateParams::Features::OutboundTransfers::Ach), us_domestic_wire: T.nilable(::Stripe::Treasury::FinancialAccount::CreateParams::Features::OutboundTransfers::UsDomesticWire)).void
}
def initialize(ach: nil, us_domestic_wire: nil); end
end
# Encodes the FinancialAccount's ability to be used with the Issuing product, including attaching cards to and drawing funds from the FinancialAccount.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccount::CreateParams::Features::CardIssuing))
}
attr_accessor :card_issuing
# Represents whether this FinancialAccount is eligible for deposit insurance. Various factors determine the insurance amount.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccount::CreateParams::Features::DepositInsurance))
}
attr_accessor :deposit_insurance
# Contains Features that add FinancialAddresses to the FinancialAccount.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccount::CreateParams::Features::FinancialAddresses))
}
attr_accessor :financial_addresses
# Contains settings related to adding funds to a FinancialAccount from another Account with the same owner.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccount::CreateParams::Features::InboundTransfers))
}
attr_accessor :inbound_transfers
# Represents the ability for the FinancialAccount to send money to, or receive money from other FinancialAccounts (for example, via OutboundPayment).
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccount::CreateParams::Features::IntraStripeFlows))
}
attr_accessor :intra_stripe_flows
# Includes Features related to initiating money movement out of the FinancialAccount to someone else's bucket of money.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccount::CreateParams::Features::OutboundPayments))
}
attr_accessor :outbound_payments
# Contains a Feature and settings related to moving money out of the FinancialAccount into another Account with the same owner.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccount::CreateParams::Features::OutboundTransfers))
}
attr_accessor :outbound_transfers
sig {
params(card_issuing: T.nilable(::Stripe::Treasury::FinancialAccount::CreateParams::Features::CardIssuing), deposit_insurance: T.nilable(::Stripe::Treasury::FinancialAccount::CreateParams::Features::DepositInsurance), financial_addresses: T.nilable(::Stripe::Treasury::FinancialAccount::CreateParams::Features::FinancialAddresses), inbound_transfers: T.nilable(::Stripe::Treasury::FinancialAccount::CreateParams::Features::InboundTransfers), intra_stripe_flows: T.nilable(::Stripe::Treasury::FinancialAccount::CreateParams::Features::IntraStripeFlows), outbound_payments: T.nilable(::Stripe::Treasury::FinancialAccount::CreateParams::Features::OutboundPayments), outbound_transfers: T.nilable(::Stripe::Treasury::FinancialAccount::CreateParams::Features::OutboundTransfers)).void
}
def initialize(
card_issuing: nil,
deposit_insurance: nil,
financial_addresses: nil,
inbound_transfers: nil,
intra_stripe_flows: nil,
outbound_payments: nil,
outbound_transfers: nil
); end
end
class PlatformRestrictions < Stripe::RequestParams
# Restricts all inbound money movement.
sig { returns(T.nilable(String)) }
attr_accessor :inbound_flows
# Restricts all outbound money movement.
sig { returns(T.nilable(String)) }
attr_accessor :outbound_flows
sig { params(inbound_flows: T.nilable(String), outbound_flows: T.nilable(String)).void }
def initialize(inbound_flows: nil, outbound_flows: nil); end
end
# The display name for the FinancialAccount. Use this field to customize the names of the FinancialAccounts for your connected accounts. Unlike the `nickname` field, `display_name` is not internal metadata and will be exposed to connected accounts.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :display_name
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Encodes whether a FinancialAccount has access to a particular feature. Stripe or the platform can control features via the requested field.
sig { returns(T.nilable(::Stripe::Treasury::FinancialAccount::CreateParams::Features)) }
attr_accessor :features
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The nickname for the FinancialAccount.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :nickname
# The set of functionalities that the platform can restrict on the FinancialAccount.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccount::CreateParams::PlatformRestrictions))
}
attr_accessor :platform_restrictions
# The currencies the FinancialAccount can hold a balance in.
sig { returns(T::Array[String]) }
attr_accessor :supported_currencies
sig {
params(display_name: T.nilable(T.nilable(String)), expand: T.nilable(T::Array[String]), features: T.nilable(::Stripe::Treasury::FinancialAccount::CreateParams::Features), metadata: T.nilable(T::Hash[String, String]), nickname: T.nilable(T.nilable(String)), platform_restrictions: T.nilable(::Stripe::Treasury::FinancialAccount::CreateParams::PlatformRestrictions), supported_currencies: T::Array[String]).void
}
def initialize(
display_name: nil,
expand: nil,
features: nil,
metadata: nil,
nickname: nil,
platform_restrictions: nil,
supported_currencies: nil
); end
end
class UpdateParams < Stripe::RequestParams
class Features < Stripe::RequestParams
class CardIssuing < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class DepositInsurance < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class FinancialAddresses < Stripe::RequestParams
class Aba < Stripe::RequestParams
# Requested bank partner
sig { returns(T.nilable(String)) }
attr_accessor :bank
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(bank: T.nilable(String), requested: T::Boolean).void }
def initialize(bank: nil, requested: nil); end
end
# Adds an ABA FinancialAddress to the FinancialAccount.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccount::UpdateParams::Features::FinancialAddresses::Aba))
}
attr_accessor :aba
sig {
params(aba: T.nilable(::Stripe::Treasury::FinancialAccount::UpdateParams::Features::FinancialAddresses::Aba)).void
}
def initialize(aba: nil); end
end
class InboundTransfers < Stripe::RequestParams
class Ach < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
# Enables ACH Debits via the InboundTransfers API.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccount::UpdateParams::Features::InboundTransfers::Ach))
}
attr_accessor :ach
sig {
params(ach: T.nilable(::Stripe::Treasury::FinancialAccount::UpdateParams::Features::InboundTransfers::Ach)).void
}
def initialize(ach: nil); end
end
class IntraStripeFlows < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class OutboundPayments < Stripe::RequestParams
class Ach < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class UsDomesticWire < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
# Enables ACH transfers via the OutboundPayments API.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccount::UpdateParams::Features::OutboundPayments::Ach))
}
attr_accessor :ach
# Enables US domestic wire transfers via the OutboundPayments API.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccount::UpdateParams::Features::OutboundPayments::UsDomesticWire))
}
attr_accessor :us_domestic_wire
sig {
params(ach: T.nilable(::Stripe::Treasury::FinancialAccount::UpdateParams::Features::OutboundPayments::Ach), us_domestic_wire: T.nilable(::Stripe::Treasury::FinancialAccount::UpdateParams::Features::OutboundPayments::UsDomesticWire)).void
}
def initialize(ach: nil, us_domestic_wire: nil); end
end
class OutboundTransfers < Stripe::RequestParams
class Ach < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class UsDomesticWire < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
# Enables ACH transfers via the OutboundTransfers API.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccount::UpdateParams::Features::OutboundTransfers::Ach))
}
attr_accessor :ach
# Enables US domestic wire transfers via the OutboundTransfers API.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccount::UpdateParams::Features::OutboundTransfers::UsDomesticWire))
}
attr_accessor :us_domestic_wire
sig {
params(ach: T.nilable(::Stripe::Treasury::FinancialAccount::UpdateParams::Features::OutboundTransfers::Ach), us_domestic_wire: T.nilable(::Stripe::Treasury::FinancialAccount::UpdateParams::Features::OutboundTransfers::UsDomesticWire)).void
}
def initialize(ach: nil, us_domestic_wire: nil); end
end
# Encodes the FinancialAccount's ability to be used with the Issuing product, including attaching cards to and drawing funds from the FinancialAccount.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccount::UpdateParams::Features::CardIssuing))
}
attr_accessor :card_issuing
# Represents whether this FinancialAccount is eligible for deposit insurance. Various factors determine the insurance amount.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccount::UpdateParams::Features::DepositInsurance))
}
attr_accessor :deposit_insurance
# Contains Features that add FinancialAddresses to the FinancialAccount.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccount::UpdateParams::Features::FinancialAddresses))
}
attr_accessor :financial_addresses
# Contains settings related to adding funds to a FinancialAccount from another Account with the same owner.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccount::UpdateParams::Features::InboundTransfers))
}
attr_accessor :inbound_transfers
# Represents the ability for the FinancialAccount to send money to, or receive money from other FinancialAccounts (for example, via OutboundPayment).
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccount::UpdateParams::Features::IntraStripeFlows))
}
attr_accessor :intra_stripe_flows
# Includes Features related to initiating money movement out of the FinancialAccount to someone else's bucket of money.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccount::UpdateParams::Features::OutboundPayments))
}
attr_accessor :outbound_payments
# Contains a Feature and settings related to moving money out of the FinancialAccount into another Account with the same owner.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccount::UpdateParams::Features::OutboundTransfers))
}
attr_accessor :outbound_transfers
sig {
params(card_issuing: T.nilable(::Stripe::Treasury::FinancialAccount::UpdateParams::Features::CardIssuing), deposit_insurance: T.nilable(::Stripe::Treasury::FinancialAccount::UpdateParams::Features::DepositInsurance), financial_addresses: T.nilable(::Stripe::Treasury::FinancialAccount::UpdateParams::Features::FinancialAddresses), inbound_transfers: T.nilable(::Stripe::Treasury::FinancialAccount::UpdateParams::Features::InboundTransfers), intra_stripe_flows: T.nilable(::Stripe::Treasury::FinancialAccount::UpdateParams::Features::IntraStripeFlows), outbound_payments: T.nilable(::Stripe::Treasury::FinancialAccount::UpdateParams::Features::OutboundPayments), outbound_transfers: T.nilable(::Stripe::Treasury::FinancialAccount::UpdateParams::Features::OutboundTransfers)).void
}
def initialize(
card_issuing: nil,
deposit_insurance: nil,
financial_addresses: nil,
inbound_transfers: nil,
intra_stripe_flows: nil,
outbound_payments: nil,
outbound_transfers: nil
); end
end
class ForwardingSettings < Stripe::RequestParams
# The financial_account id
sig { returns(T.nilable(String)) }
attr_accessor :financial_account
# The payment_method or bank account id. This needs to be a verified bank account.
sig { returns(T.nilable(String)) }
attr_accessor :payment_method
# The type of the bank account provided. This can be either "financial_account" or "payment_method"
sig { returns(String) }
attr_accessor :type
sig {
params(financial_account: T.nilable(String), payment_method: T.nilable(String), type: String).void
}
def initialize(financial_account: nil, payment_method: nil, type: nil); end
end
class PlatformRestrictions < Stripe::RequestParams
# Restricts all inbound money movement.
sig { returns(T.nilable(String)) }
attr_accessor :inbound_flows
# Restricts all outbound money movement.
sig { returns(T.nilable(String)) }
attr_accessor :outbound_flows
sig { params(inbound_flows: T.nilable(String), outbound_flows: T.nilable(String)).void }
def initialize(inbound_flows: nil, outbound_flows: nil); end
end
# The display name for the FinancialAccount. Use this field to customize the names of the FinancialAccounts for your connected accounts. Unlike the `nickname` field, `display_name` is not internal metadata and will be exposed to connected accounts.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :display_name
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Encodes whether a FinancialAccount has access to a particular feature, with a status enum and associated `status_details`. Stripe or the platform may control features via the requested field.
sig { returns(T.nilable(::Stripe::Treasury::FinancialAccount::UpdateParams::Features)) }
attr_accessor :features
# A different bank account where funds can be deposited/debited in order to get the closing FA's balance to $0
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccount::UpdateParams::ForwardingSettings))
}
attr_accessor :forwarding_settings
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The nickname for the FinancialAccount.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :nickname
# The set of functionalities that the platform can restrict on the FinancialAccount.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccount::UpdateParams::PlatformRestrictions))
}
attr_accessor :platform_restrictions
sig {
params(display_name: T.nilable(T.nilable(String)), expand: T.nilable(T::Array[String]), features: T.nilable(::Stripe::Treasury::FinancialAccount::UpdateParams::Features), forwarding_settings: T.nilable(::Stripe::Treasury::FinancialAccount::UpdateParams::ForwardingSettings), metadata: T.nilable(T::Hash[String, String]), nickname: T.nilable(T.nilable(String)), platform_restrictions: T.nilable(::Stripe::Treasury::FinancialAccount::UpdateParams::PlatformRestrictions)).void
}
def initialize(
display_name: nil,
expand: nil,
features: nil,
forwarding_settings: nil,
metadata: nil,
nickname: nil,
platform_restrictions: nil
); end
end
class RetrieveFeaturesParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateFeaturesParams < Stripe::RequestParams
class CardIssuing < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class DepositInsurance < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class FinancialAddresses < Stripe::RequestParams
class Aba < Stripe::RequestParams
# Requested bank partner
sig { returns(T.nilable(String)) }
attr_accessor :bank
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(bank: T.nilable(String), requested: T::Boolean).void }
def initialize(bank: nil, requested: nil); end
end
# Adds an ABA FinancialAddress to the FinancialAccount.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccount::UpdateFeaturesParams::FinancialAddresses::Aba))
}
attr_accessor :aba
sig {
params(aba: T.nilable(::Stripe::Treasury::FinancialAccount::UpdateFeaturesParams::FinancialAddresses::Aba)).void
}
def initialize(aba: nil); end
end
class InboundTransfers < Stripe::RequestParams
class Ach < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
# Enables ACH Debits via the InboundTransfers API.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccount::UpdateFeaturesParams::InboundTransfers::Ach))
}
attr_accessor :ach
sig {
params(ach: T.nilable(::Stripe::Treasury::FinancialAccount::UpdateFeaturesParams::InboundTransfers::Ach)).void
}
def initialize(ach: nil); end
end
class IntraStripeFlows < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class OutboundPayments < Stripe::RequestParams
class Ach < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class UsDomesticWire < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
# Enables ACH transfers via the OutboundPayments API.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccount::UpdateFeaturesParams::OutboundPayments::Ach))
}
attr_accessor :ach
# Enables US domestic wire transfers via the OutboundPayments API.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccount::UpdateFeaturesParams::OutboundPayments::UsDomesticWire))
}
attr_accessor :us_domestic_wire
sig {
params(ach: T.nilable(::Stripe::Treasury::FinancialAccount::UpdateFeaturesParams::OutboundPayments::Ach), us_domestic_wire: T.nilable(::Stripe::Treasury::FinancialAccount::UpdateFeaturesParams::OutboundPayments::UsDomesticWire)).void
}
def initialize(ach: nil, us_domestic_wire: nil); end
end
class OutboundTransfers < Stripe::RequestParams
class Ach < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class UsDomesticWire < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
# Enables ACH transfers via the OutboundTransfers API.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccount::UpdateFeaturesParams::OutboundTransfers::Ach))
}
attr_accessor :ach
# Enables US domestic wire transfers via the OutboundTransfers API.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccount::UpdateFeaturesParams::OutboundTransfers::UsDomesticWire))
}
attr_accessor :us_domestic_wire
sig {
params(ach: T.nilable(::Stripe::Treasury::FinancialAccount::UpdateFeaturesParams::OutboundTransfers::Ach), us_domestic_wire: T.nilable(::Stripe::Treasury::FinancialAccount::UpdateFeaturesParams::OutboundTransfers::UsDomesticWire)).void
}
def initialize(ach: nil, us_domestic_wire: nil); end
end
# Encodes the FinancialAccount's ability to be used with the Issuing product, including attaching cards to and drawing funds from the FinancialAccount.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccount::UpdateFeaturesParams::CardIssuing))
}
attr_accessor :card_issuing
# Represents whether this FinancialAccount is eligible for deposit insurance. Various factors determine the insurance amount.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccount::UpdateFeaturesParams::DepositInsurance))
}
attr_accessor :deposit_insurance
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Contains Features that add FinancialAddresses to the FinancialAccount.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccount::UpdateFeaturesParams::FinancialAddresses))
}
attr_accessor :financial_addresses
# Contains settings related to adding funds to a FinancialAccount from another Account with the same owner.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccount::UpdateFeaturesParams::InboundTransfers))
}
attr_accessor :inbound_transfers
# Represents the ability for the FinancialAccount to send money to, or receive money from other FinancialAccounts (for example, via OutboundPayment).
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccount::UpdateFeaturesParams::IntraStripeFlows))
}
attr_accessor :intra_stripe_flows
# Includes Features related to initiating money movement out of the FinancialAccount to someone else's bucket of money.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccount::UpdateFeaturesParams::OutboundPayments))
}
attr_accessor :outbound_payments
# Contains a Feature and settings related to moving money out of the FinancialAccount into another Account with the same owner.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccount::UpdateFeaturesParams::OutboundTransfers))
}
attr_accessor :outbound_transfers
sig {
params(card_issuing: T.nilable(::Stripe::Treasury::FinancialAccount::UpdateFeaturesParams::CardIssuing), deposit_insurance: T.nilable(::Stripe::Treasury::FinancialAccount::UpdateFeaturesParams::DepositInsurance), expand: T.nilable(T::Array[String]), financial_addresses: T.nilable(::Stripe::Treasury::FinancialAccount::UpdateFeaturesParams::FinancialAddresses), inbound_transfers: T.nilable(::Stripe::Treasury::FinancialAccount::UpdateFeaturesParams::InboundTransfers), intra_stripe_flows: T.nilable(::Stripe::Treasury::FinancialAccount::UpdateFeaturesParams::IntraStripeFlows), outbound_payments: T.nilable(::Stripe::Treasury::FinancialAccount::UpdateFeaturesParams::OutboundPayments), outbound_transfers: T.nilable(::Stripe::Treasury::FinancialAccount::UpdateFeaturesParams::OutboundTransfers)).void
}
def initialize(
card_issuing: nil,
deposit_insurance: nil,
expand: nil,
financial_addresses: nil,
inbound_transfers: nil,
intra_stripe_flows: nil,
outbound_payments: nil,
outbound_transfers: nil
); end
end
class CloseParams < Stripe::RequestParams
class ForwardingSettings < Stripe::RequestParams
# The financial_account id
sig { returns(T.nilable(String)) }
attr_accessor :financial_account
# The payment_method or bank account id. This needs to be a verified bank account.
sig { returns(T.nilable(String)) }
attr_accessor :payment_method
# The type of the bank account provided. This can be either "financial_account" or "payment_method"
sig { returns(String) }
attr_accessor :type
sig {
params(financial_account: T.nilable(String), payment_method: T.nilable(String), type: String).void
}
def initialize(financial_account: nil, payment_method: nil, type: nil); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A different bank account where funds can be deposited/debited in order to get the closing FA's balance to $0
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccount::CloseParams::ForwardingSettings))
}
attr_accessor :forwarding_settings
sig {
params(expand: T.nilable(T::Array[String]), forwarding_settings: T.nilable(::Stripe::Treasury::FinancialAccount::CloseParams::ForwardingSettings)).void
}
def initialize(expand: nil, forwarding_settings: nil); end
end
# Closes a FinancialAccount. A FinancialAccount can only be closed if it has a zero balance, has no pending InboundTransfers, and has canceled all attached Issuing cards.
sig {
params(params: T.any(::Stripe::Treasury::FinancialAccount::CloseParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::FinancialAccount)
}
def close(params = {}, opts = {}); end
# Closes a FinancialAccount. A FinancialAccount can only be closed if it has a zero balance, has no pending InboundTransfers, and has canceled all attached Issuing cards.
sig {
params(financial_account: String, params: T.any(::Stripe::Treasury::FinancialAccount::CloseParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::FinancialAccount)
}
def self.close(financial_account, params = {}, opts = {}); end
# Creates a new FinancialAccount. Each connected account can have up to three FinancialAccounts by default.
sig {
params(params: T.any(::Stripe::Treasury::FinancialAccount::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::FinancialAccount)
}
def self.create(params = {}, opts = {}); end
# Returns a list of FinancialAccounts.
sig {
params(params: T.any(::Stripe::Treasury::FinancialAccount::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Retrieves Features information associated with the FinancialAccount.
sig {
params(params: T.any(::Stripe::Treasury::FinancialAccount::RetrieveFeaturesParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::FinancialAccountFeatures)
}
def retrieve_features(params = {}, opts = {}); end
# Retrieves Features information associated with the FinancialAccount.
sig {
params(financial_account: String, params: T.any(::Stripe::Treasury::FinancialAccount::RetrieveFeaturesParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::FinancialAccountFeatures)
}
def self.retrieve_features(financial_account, params = {}, opts = {}); end
# Updates the details of a FinancialAccount.
sig {
params(financial_account: String, params: T.any(::Stripe::Treasury::FinancialAccount::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::FinancialAccount)
}
def self.update(financial_account, params = {}, opts = {}); end
# Updates the Features associated with a FinancialAccount.
sig {
params(params: T.any(::Stripe::Treasury::FinancialAccount::UpdateFeaturesParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::FinancialAccountFeatures)
}
def update_features(params = {}, opts = {}); end
# Updates the Features associated with a FinancialAccount.
sig {
params(financial_account: String, params: T.any(::Stripe::Treasury::FinancialAccount::UpdateFeaturesParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::FinancialAccountFeatures)
}
def self.update_features(financial_account, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Treasury
# Encodes whether a FinancialAccount has access to a particular Feature, with a `status` enum and associated `status_details`.
# Stripe or the platform can control Features via the requested field.
class FinancialAccountFeatures < APIResource
class CardIssuing < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Represents the reason why the status is `pending` or `restricted`.
sig { returns(String) }
attr_reader :code
# Represents what the user should do, if anything, to activate the Feature.
sig { returns(T.nilable(String)) }
attr_reader :resolution
# The `platform_restrictions` that are restricting this Feature.
sig { returns(String) }
attr_reader :restriction
end
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_reader :requested
# Whether the Feature is operational.
sig { returns(String) }
attr_reader :status
# Additional details; includes at least one entry when the status is not `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class DepositInsurance < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Represents the reason why the status is `pending` or `restricted`.
sig { returns(String) }
attr_reader :code
# Represents what the user should do, if anything, to activate the Feature.
sig { returns(T.nilable(String)) }
attr_reader :resolution
# The `platform_restrictions` that are restricting this Feature.
sig { returns(String) }
attr_reader :restriction
end
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_reader :requested
# Whether the Feature is operational.
sig { returns(String) }
attr_reader :status
# Additional details; includes at least one entry when the status is not `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class FinancialAddresses < Stripe::StripeObject
class Aba < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Represents the reason why the status is `pending` or `restricted`.
sig { returns(String) }
attr_reader :code
# Represents what the user should do, if anything, to activate the Feature.
sig { returns(T.nilable(String)) }
attr_reader :resolution
# The `platform_restrictions` that are restricting this Feature.
sig { returns(String) }
attr_reader :restriction
end
# Requested bank partner for this Financial Account
sig { returns(String) }
attr_reader :bank
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_reader :requested
# Whether the Feature is operational.
sig { returns(String) }
attr_reader :status
# Additional details; includes at least one entry when the status is not `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
# Toggle settings for enabling/disabling the ABA address feature
sig { returns(Aba) }
attr_reader :aba
end
class InboundTransfers < Stripe::StripeObject
class Ach < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Represents the reason why the status is `pending` or `restricted`.
sig { returns(String) }
attr_reader :code
# Represents what the user should do, if anything, to activate the Feature.
sig { returns(T.nilable(String)) }
attr_reader :resolution
# The `platform_restrictions` that are restricting this Feature.
sig { returns(String) }
attr_reader :restriction
end
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_reader :requested
# Whether the Feature is operational.
sig { returns(String) }
attr_reader :status
# Additional details; includes at least one entry when the status is not `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
# Toggle settings for enabling/disabling an inbound ACH specific feature
sig { returns(Ach) }
attr_reader :ach
end
class IntraStripeFlows < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Represents the reason why the status is `pending` or `restricted`.
sig { returns(String) }
attr_reader :code
# Represents what the user should do, if anything, to activate the Feature.
sig { returns(T.nilable(String)) }
attr_reader :resolution
# The `platform_restrictions` that are restricting this Feature.
sig { returns(String) }
attr_reader :restriction
end
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_reader :requested
# Whether the Feature is operational.
sig { returns(String) }
attr_reader :status
# Additional details; includes at least one entry when the status is not `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class OutboundPayments < Stripe::StripeObject
class Ach < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Represents the reason why the status is `pending` or `restricted`.
sig { returns(String) }
attr_reader :code
# Represents what the user should do, if anything, to activate the Feature.
sig { returns(T.nilable(String)) }
attr_reader :resolution
# The `platform_restrictions` that are restricting this Feature.
sig { returns(String) }
attr_reader :restriction
end
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_reader :requested
# Whether the Feature is operational.
sig { returns(String) }
attr_reader :status
# Additional details; includes at least one entry when the status is not `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class UsDomesticWire < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Represents the reason why the status is `pending` or `restricted`.
sig { returns(String) }
attr_reader :code
# Represents what the user should do, if anything, to activate the Feature.
sig { returns(T.nilable(String)) }
attr_reader :resolution
# The `platform_restrictions` that are restricting this Feature.
sig { returns(String) }
attr_reader :restriction
end
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_reader :requested
# Whether the Feature is operational.
sig { returns(String) }
attr_reader :status
# Additional details; includes at least one entry when the status is not `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
# Toggle settings for enabling/disabling an outbound ACH specific feature
sig { returns(Ach) }
attr_reader :ach
# Toggle settings for enabling/disabling a feature
sig { returns(UsDomesticWire) }
attr_reader :us_domestic_wire
end
class OutboundTransfers < Stripe::StripeObject
class Ach < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Represents the reason why the status is `pending` or `restricted`.
sig { returns(String) }
attr_reader :code
# Represents what the user should do, if anything, to activate the Feature.
sig { returns(T.nilable(String)) }
attr_reader :resolution
# The `platform_restrictions` that are restricting this Feature.
sig { returns(String) }
attr_reader :restriction
end
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_reader :requested
# Whether the Feature is operational.
sig { returns(String) }
attr_reader :status
# Additional details; includes at least one entry when the status is not `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
class UsDomesticWire < Stripe::StripeObject
class StatusDetail < Stripe::StripeObject
# Represents the reason why the status is `pending` or `restricted`.
sig { returns(String) }
attr_reader :code
# Represents what the user should do, if anything, to activate the Feature.
sig { returns(T.nilable(String)) }
attr_reader :resolution
# The `platform_restrictions` that are restricting this Feature.
sig { returns(String) }
attr_reader :restriction
end
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_reader :requested
# Whether the Feature is operational.
sig { returns(String) }
attr_reader :status
# Additional details; includes at least one entry when the status is not `active`.
sig { returns(T::Array[StatusDetail]) }
attr_reader :status_details
end
# Toggle settings for enabling/disabling an outbound ACH specific feature
sig { returns(Ach) }
attr_reader :ach
# Toggle settings for enabling/disabling a feature
sig { returns(UsDomesticWire) }
attr_reader :us_domestic_wire
end
# Toggle settings for enabling/disabling a feature
sig { returns(CardIssuing) }
attr_reader :card_issuing
# Toggle settings for enabling/disabling a feature
sig { returns(DepositInsurance) }
attr_reader :deposit_insurance
# Settings related to Financial Addresses features on a Financial Account
sig { returns(FinancialAddresses) }
attr_reader :financial_addresses
# InboundTransfers contains inbound transfers features for a FinancialAccount.
sig { returns(InboundTransfers) }
attr_reader :inbound_transfers
# Toggle settings for enabling/disabling a feature
sig { returns(IntraStripeFlows) }
attr_reader :intra_stripe_flows
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Settings related to Outbound Payments features on a Financial Account
sig { returns(OutboundPayments) }
attr_reader :outbound_payments
# OutboundTransfers contains outbound transfers features for a FinancialAccount.
sig { returns(OutboundTransfers) }
attr_reader :outbound_transfers
end
end
end
# typed: true
module Stripe
module Treasury
# Use [InboundTransfers](https://docs.stripe.com/docs/treasury/moving-money/financial-accounts/into/inbound-transfers) to add funds to your [FinancialAccount](https://stripe.com/docs/api#financial_accounts) via a PaymentMethod that is owned by you. The funds will be transferred via an ACH debit.
#
# Related guide: [Moving money with Treasury using InboundTransfer objects](https://docs.stripe.com/docs/treasury/moving-money/financial-accounts/into/inbound-transfers)
class InboundTransfer < APIResource
class FailureDetails < Stripe::StripeObject
# Reason for the failure.
sig { returns(String) }
attr_reader :code
end
class LinkedFlows < Stripe::StripeObject
# If funds for this flow were returned after the flow went to the `succeeded` state, this field contains a reference to the ReceivedDebit return.
sig { returns(T.nilable(String)) }
attr_reader :received_debit
end
class OriginPaymentMethodDetails < Stripe::StripeObject
class BillingDetails < Stripe::StripeObject
class Address < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Attribute for field address
sig { returns(Address) }
attr_reader :address
# Email address.
sig { returns(T.nilable(String)) }
attr_reader :email
# Full name.
sig { returns(T.nilable(String)) }
attr_reader :name
end
class UsBankAccount < Stripe::StripeObject
# Account holder type: individual or company.
sig { returns(T.nilable(String)) }
attr_reader :account_holder_type
# Account type: checkings or savings. Defaults to checking if omitted.
sig { returns(T.nilable(String)) }
attr_reader :account_type
# Name of the bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Last four digits of the bank account number.
sig { returns(T.nilable(String)) }
attr_reader :last4
# ID of the mandate used to make this payment.
sig { returns(T.any(String, Stripe::Mandate)) }
attr_reader :mandate
# The network rails used. See the [docs](https://stripe.com/docs/treasury/money-movement/timelines) to learn more about money movement timelines for each network type.
sig { returns(String) }
attr_reader :network
# Routing number of the bank account.
sig { returns(T.nilable(String)) }
attr_reader :routing_number
end
# Attribute for field billing_details
sig { returns(BillingDetails) }
attr_reader :billing_details
# The type of the payment method used in the InboundTransfer.
sig { returns(String) }
attr_reader :type
# Attribute for field us_bank_account
sig { returns(UsBankAccount) }
attr_reader :us_bank_account
end
class StatusTransitions < Stripe::StripeObject
# Timestamp describing when an InboundTransfer changed status to `canceled`.
sig { returns(T.nilable(Integer)) }
attr_reader :canceled_at
# Timestamp describing when an InboundTransfer changed status to `failed`.
sig { returns(T.nilable(Integer)) }
attr_reader :failed_at
# Timestamp describing when an InboundTransfer changed status to `succeeded`.
sig { returns(T.nilable(Integer)) }
attr_reader :succeeded_at
end
# Amount (in cents) transferred.
sig { returns(Integer) }
attr_reader :amount
# Returns `true` if the InboundTransfer is able to be canceled.
sig { returns(T::Boolean) }
attr_reader :cancelable
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# 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).
sig { returns(String) }
attr_reader :currency
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_reader :description
# Details about this InboundTransfer's failure. Only set when status is `failed`.
sig { returns(T.nilable(FailureDetails)) }
attr_reader :failure_details
# The FinancialAccount that received the funds.
sig { returns(String) }
attr_reader :financial_account
# A [hosted transaction receipt](https://stripe.com/docs/treasury/moving-money/regulatory-receipts) URL that is provided when money movement is considered regulated under Stripe's money transmission licenses.
sig { returns(T.nilable(String)) }
attr_reader :hosted_regulatory_receipt_url
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Attribute for field linked_flows
sig { returns(LinkedFlows) }
attr_reader :linked_flows
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# 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.
sig { returns(T::Hash[String, String]) }
attr_reader :metadata
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The origin payment method to be debited for an InboundTransfer.
sig { returns(T.nilable(String)) }
attr_reader :origin_payment_method
# Details about the PaymentMethod for an InboundTransfer.
sig { returns(T.nilable(OriginPaymentMethodDetails)) }
attr_reader :origin_payment_method_details
# Returns `true` if the funds for an InboundTransfer were returned after the InboundTransfer went to the `succeeded` state.
sig { returns(T.nilable(T::Boolean)) }
attr_reader :returned
# Statement descriptor shown when funds are debited from the source. Not all payment networks support `statement_descriptor`.
sig { returns(String) }
attr_reader :statement_descriptor
# Status of the InboundTransfer: `processing`, `succeeded`, `failed`, and `canceled`. An InboundTransfer is `processing` if it is created and pending. The status changes to `succeeded` once the funds have been "confirmed" and a `transaction` is created and posted. The status changes to `failed` if the transfer fails.
sig { returns(String) }
attr_reader :status
# Attribute for field status_transitions
sig { returns(StatusTransitions) }
attr_reader :status_transitions
# The Transaction associated with this object.
sig { returns(T.nilable(T.any(String, Stripe::Treasury::Transaction))) }
attr_reader :transaction
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Returns objects associated with this FinancialAccount.
sig { returns(String) }
attr_accessor :financial_account
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return InboundTransfers that have the given status: `processing`, `succeeded`, `failed` or `canceled`.
sig { returns(T.nilable(String)) }
attr_accessor :status
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), financial_account: String, limit: T.nilable(Integer), starting_after: T.nilable(String), status: T.nilable(String)).void
}
def initialize(
ending_before: nil,
expand: nil,
financial_account: nil,
limit: nil,
starting_after: nil,
status: nil
); end
end
class CreateParams < Stripe::RequestParams
# Amount (in cents) to be transferred.
sig { returns(Integer) }
attr_accessor :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).
sig { returns(String) }
attr_accessor :currency
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The FinancialAccount to send funds to.
sig { returns(String) }
attr_accessor :financial_account
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The origin payment method to be debited for the InboundTransfer.
sig { returns(String) }
attr_accessor :origin_payment_method
# The complete description that appears on your customers' statements. Maximum 10 characters.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
sig {
params(amount: Integer, currency: String, description: T.nilable(String), expand: T.nilable(T::Array[String]), financial_account: String, metadata: T.nilable(T::Hash[String, String]), origin_payment_method: String, statement_descriptor: T.nilable(String)).void
}
def initialize(
amount: nil,
currency: nil,
description: nil,
expand: nil,
financial_account: nil,
metadata: nil,
origin_payment_method: nil,
statement_descriptor: nil
); end
end
class CancelParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class FailParams < Stripe::RequestParams
class FailureDetails < Stripe::RequestParams
# Reason for the failure.
sig { returns(T.nilable(String)) }
attr_accessor :code
sig { params(code: T.nilable(String)).void }
def initialize(code: nil); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Details about a failed InboundTransfer.
sig { returns(T.nilable(::Stripe::Treasury::InboundTransfer::FailParams::FailureDetails)) }
attr_accessor :failure_details
sig {
params(expand: T.nilable(T::Array[String]), failure_details: T.nilable(::Stripe::Treasury::InboundTransfer::FailParams::FailureDetails)).void
}
def initialize(expand: nil, failure_details: nil); end
end
class ReturnInboundTransferParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class SucceedParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Cancels an InboundTransfer.
sig {
params(params: T.any(::Stripe::Treasury::InboundTransfer::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::InboundTransfer)
}
def cancel(params = {}, opts = {}); end
# Cancels an InboundTransfer.
sig {
params(inbound_transfer: String, params: T.any(::Stripe::Treasury::InboundTransfer::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::InboundTransfer)
}
def self.cancel(inbound_transfer, params = {}, opts = {}); end
# Creates an InboundTransfer.
sig {
params(params: T.any(::Stripe::Treasury::InboundTransfer::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::InboundTransfer)
}
def self.create(params = {}, opts = {}); end
# Returns a list of InboundTransfers sent from the specified FinancialAccount.
sig {
params(params: T.any(::Stripe::Treasury::InboundTransfer::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Treasury
# Use [OutboundPayments](https://docs.stripe.com/docs/treasury/moving-money/financial-accounts/out-of/outbound-payments) to send funds to another party's external bank account or [FinancialAccount](https://stripe.com/docs/api#financial_accounts). To send money to an account belonging to the same user, use an [OutboundTransfer](https://stripe.com/docs/api#outbound_transfers).
#
# Simulate OutboundPayment state changes with the `/v1/test_helpers/treasury/outbound_payments` endpoints. These methods can only be called on test mode objects.
#
# Related guide: [Moving money with Treasury using OutboundPayment objects](https://docs.stripe.com/docs/treasury/moving-money/financial-accounts/out-of/outbound-payments)
class OutboundPayment < APIResource
class DestinationPaymentMethodDetails < Stripe::StripeObject
class BillingDetails < Stripe::StripeObject
class Address < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Attribute for field address
sig { returns(Address) }
attr_reader :address
# Email address.
sig { returns(T.nilable(String)) }
attr_reader :email
# Full name.
sig { returns(T.nilable(String)) }
attr_reader :name
end
class FinancialAccount < Stripe::StripeObject
# Token of the FinancialAccount.
sig { returns(String) }
attr_reader :id
# The rails used to send funds.
sig { returns(String) }
attr_reader :network
end
class UsBankAccount < Stripe::StripeObject
# Account holder type: individual or company.
sig { returns(T.nilable(String)) }
attr_reader :account_holder_type
# Account type: checkings or savings. Defaults to checking if omitted.
sig { returns(T.nilable(String)) }
attr_reader :account_type
# Name of the bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Last four digits of the bank account number.
sig { returns(T.nilable(String)) }
attr_reader :last4
# ID of the mandate used to make this payment.
sig { returns(T.any(String, Stripe::Mandate)) }
attr_reader :mandate
# The network rails used. See the [docs](https://stripe.com/docs/treasury/money-movement/timelines) to learn more about money movement timelines for each network type.
sig { returns(String) }
attr_reader :network
# Routing number of the bank account.
sig { returns(T.nilable(String)) }
attr_reader :routing_number
end
# Attribute for field billing_details
sig { returns(BillingDetails) }
attr_reader :billing_details
# Attribute for field financial_account
sig { returns(FinancialAccount) }
attr_reader :financial_account
# The type of the payment method used in the OutboundPayment.
sig { returns(String) }
attr_reader :type
# Attribute for field us_bank_account
sig { returns(UsBankAccount) }
attr_reader :us_bank_account
end
class EndUserDetails < Stripe::StripeObject
# IP address of the user initiating the OutboundPayment. Set if `present` is set to `true`. IP address collection is required for risk and compliance reasons. This will be used to help determine if the OutboundPayment is authorized or should be blocked.
sig { returns(T.nilable(String)) }
attr_reader :ip_address
# `true` if the OutboundPayment creation request is being made on behalf of an end user by a platform. Otherwise, `false`.
sig { returns(T::Boolean) }
attr_reader :present
end
class ReturnedDetails < Stripe::StripeObject
# Reason for the return.
sig { returns(String) }
attr_reader :code
# The Transaction associated with this object.
sig { returns(T.any(String, Stripe::Treasury::Transaction)) }
attr_reader :transaction
end
class StatusTransitions < Stripe::StripeObject
# Timestamp describing when an OutboundPayment changed status to `canceled`.
sig { returns(T.nilable(Integer)) }
attr_reader :canceled_at
# Timestamp describing when an OutboundPayment changed status to `failed`.
sig { returns(T.nilable(Integer)) }
attr_reader :failed_at
# Timestamp describing when an OutboundPayment changed status to `posted`.
sig { returns(T.nilable(Integer)) }
attr_reader :posted_at
# Timestamp describing when an OutboundPayment changed status to `returned`.
sig { returns(T.nilable(Integer)) }
attr_reader :returned_at
end
class TrackingDetails < Stripe::StripeObject
class Ach < Stripe::StripeObject
# ACH trace ID of the OutboundPayment for payments sent over the `ach` network.
sig { returns(String) }
attr_reader :trace_id
end
class UsDomesticWire < Stripe::StripeObject
# CHIPS System Sequence Number (SSN) of the OutboundPayment for payments sent over the `us_domestic_wire` network.
sig { returns(T.nilable(String)) }
attr_reader :chips
# IMAD of the OutboundPayment for payments sent over the `us_domestic_wire` network.
sig { returns(T.nilable(String)) }
attr_reader :imad
# OMAD of the OutboundPayment for payments sent over the `us_domestic_wire` network.
sig { returns(T.nilable(String)) }
attr_reader :omad
end
# Attribute for field ach
sig { returns(Ach) }
attr_reader :ach
# The US bank account network used to send funds.
sig { returns(String) }
attr_reader :type
# Attribute for field us_domestic_wire
sig { returns(UsDomesticWire) }
attr_reader :us_domestic_wire
end
# Amount (in cents) transferred.
sig { returns(Integer) }
attr_reader :amount
# Returns `true` if the object can be canceled, and `false` otherwise.
sig { returns(T::Boolean) }
attr_reader :cancelable
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# 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).
sig { returns(String) }
attr_reader :currency
# ID of the [customer](https://stripe.com/docs/api/customers) to whom an OutboundPayment is sent.
sig { returns(T.nilable(String)) }
attr_reader :customer
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_reader :description
# The PaymentMethod via which an OutboundPayment is sent. This field can be empty if the OutboundPayment was created using `destination_payment_method_data`.
sig { returns(T.nilable(String)) }
attr_reader :destination_payment_method
# Details about the PaymentMethod for an OutboundPayment.
sig { returns(T.nilable(DestinationPaymentMethodDetails)) }
attr_reader :destination_payment_method_details
# Details about the end user.
sig { returns(T.nilable(EndUserDetails)) }
attr_reader :end_user_details
# The date when funds are expected to arrive in the destination account.
sig { returns(Integer) }
attr_reader :expected_arrival_date
# The FinancialAccount that funds were pulled from.
sig { returns(String) }
attr_reader :financial_account
# A [hosted transaction receipt](https://stripe.com/docs/treasury/moving-money/regulatory-receipts) URL that is provided when money movement is considered regulated under Stripe's money transmission licenses.
sig { returns(T.nilable(String)) }
attr_reader :hosted_regulatory_receipt_url
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# 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.
sig { returns(T::Hash[String, String]) }
attr_reader :metadata
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Details about a returned OutboundPayment. Only set when the status is `returned`.
sig { returns(T.nilable(ReturnedDetails)) }
attr_reader :returned_details
# The description that appears on the receiving end for an OutboundPayment (for example, bank statement for external bank transfer).
sig { returns(String) }
attr_reader :statement_descriptor
# Current status of the OutboundPayment: `processing`, `failed`, `posted`, `returned`, `canceled`. An OutboundPayment is `processing` if it has been created and is pending. The status changes to `posted` once the OutboundPayment has been "confirmed" and funds have left the account, or to `failed` or `canceled`. If an OutboundPayment fails to arrive at its destination, its status will change to `returned`.
sig { returns(String) }
attr_reader :status
# Attribute for field status_transitions
sig { returns(StatusTransitions) }
attr_reader :status_transitions
# Details about network-specific tracking information if available.
sig { returns(T.nilable(TrackingDetails)) }
attr_reader :tracking_details
# The Transaction associated with this object.
sig { returns(T.any(String, Stripe::Treasury::Transaction)) }
attr_reader :transaction
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return OutboundPayments that were created during the given date interval.
sig {
returns(T.nilable(T.any(::Stripe::Treasury::OutboundPayment::ListParams::Created, Integer)))
}
attr_accessor :created
# Only return OutboundPayments sent to this customer.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Returns objects associated with this FinancialAccount.
sig { returns(String) }
attr_accessor :financial_account
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return OutboundPayments that have the given status: `processing`, `failed`, `posted`, `returned`, or `canceled`.
sig { returns(T.nilable(String)) }
attr_accessor :status
sig {
params(created: T.nilable(T.any(::Stripe::Treasury::OutboundPayment::ListParams::Created, Integer)), customer: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), financial_account: String, limit: T.nilable(Integer), starting_after: T.nilable(String), status: T.nilable(String)).void
}
def initialize(
created: nil,
customer: nil,
ending_before: nil,
expand: nil,
financial_account: nil,
limit: nil,
starting_after: nil,
status: nil
); end
end
class CreateParams < Stripe::RequestParams
class DestinationPaymentMethodData < Stripe::RequestParams
class BillingDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Billing address.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Treasury::OutboundPayment::CreateParams::DestinationPaymentMethodData::BillingDetails::Address))))
}
attr_accessor :address
# Email address.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :email
# Full name.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :name
# Billing phone number (including extension).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :phone
sig {
params(address: T.nilable(T.nilable(T.any(String, ::Stripe::Treasury::OutboundPayment::CreateParams::DestinationPaymentMethodData::BillingDetails::Address))), email: T.nilable(T.nilable(String)), name: T.nilable(T.nilable(String)), phone: T.nilable(T.nilable(String))).void
}
def initialize(address: nil, email: nil, name: nil, phone: nil); end
end
class UsBankAccount < Stripe::RequestParams
# Account holder type: individual or company.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_type
# Account number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Account type: checkings or savings. Defaults to checking if omitted.
sig { returns(T.nilable(String)) }
attr_accessor :account_type
# The ID of a Financial Connections Account to use as a payment method.
sig { returns(T.nilable(String)) }
attr_accessor :financial_connections_account
# Routing number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :routing_number
sig {
params(account_holder_type: T.nilable(String), account_number: T.nilable(String), account_type: T.nilable(String), financial_connections_account: T.nilable(String), routing_number: T.nilable(String)).void
}
def initialize(
account_holder_type: nil,
account_number: nil,
account_type: nil,
financial_connections_account: nil,
routing_number: nil
); end
end
# Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
sig {
returns(T.nilable(::Stripe::Treasury::OutboundPayment::CreateParams::DestinationPaymentMethodData::BillingDetails))
}
attr_accessor :billing_details
# Required if type is set to `financial_account`. The FinancialAccount ID to send funds to.
sig { returns(T.nilable(String)) }
attr_accessor :financial_account
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
sig { returns(String) }
attr_accessor :type
# Required hash if type is set to `us_bank_account`.
sig {
returns(T.nilable(::Stripe::Treasury::OutboundPayment::CreateParams::DestinationPaymentMethodData::UsBankAccount))
}
attr_accessor :us_bank_account
sig {
params(billing_details: T.nilable(::Stripe::Treasury::OutboundPayment::CreateParams::DestinationPaymentMethodData::BillingDetails), financial_account: T.nilable(String), metadata: T.nilable(T::Hash[String, String]), type: String, us_bank_account: T.nilable(::Stripe::Treasury::OutboundPayment::CreateParams::DestinationPaymentMethodData::UsBankAccount)).void
}
def initialize(
billing_details: nil,
financial_account: nil,
metadata: nil,
type: nil,
us_bank_account: nil
); end
end
class DestinationPaymentMethodOptions < Stripe::RequestParams
class UsBankAccount < Stripe::RequestParams
# Specifies the network rails to be used. If not set, will default to the PaymentMethod's preferred network. See the [docs](https://stripe.com/docs/treasury/money-movement/timelines) to learn more about money movement timelines for each network type.
sig { returns(T.nilable(String)) }
attr_accessor :network
sig { params(network: T.nilable(String)).void }
def initialize(network: nil); end
end
# Optional fields for `us_bank_account`.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Treasury::OutboundPayment::CreateParams::DestinationPaymentMethodOptions::UsBankAccount))))
}
attr_accessor :us_bank_account
sig {
params(us_bank_account: T.nilable(T.nilable(T.any(String, ::Stripe::Treasury::OutboundPayment::CreateParams::DestinationPaymentMethodOptions::UsBankAccount)))).void
}
def initialize(us_bank_account: nil); end
end
class EndUserDetails < Stripe::RequestParams
# IP address of the user initiating the OutboundPayment. Must be supplied if `present` is set to `true`.
sig { returns(T.nilable(String)) }
attr_accessor :ip_address
# `True` if the OutboundPayment creation request is being made on behalf of an end user by a platform. Otherwise, `false`.
sig { returns(T::Boolean) }
attr_accessor :present
sig { params(ip_address: T.nilable(String), present: T::Boolean).void }
def initialize(ip_address: nil, present: nil); end
end
# Amount (in cents) to be transferred.
sig { returns(Integer) }
attr_accessor :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).
sig { returns(String) }
attr_accessor :currency
# ID of the customer to whom the OutboundPayment is sent. Must match the Customer attached to the `destination_payment_method` passed in.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# The PaymentMethod to use as the payment instrument for the OutboundPayment. Exclusive with `destination_payment_method_data`.
sig { returns(T.nilable(String)) }
attr_accessor :destination_payment_method
# Hash used to generate the PaymentMethod to be used for this OutboundPayment. Exclusive with `destination_payment_method`.
sig {
returns(T.nilable(::Stripe::Treasury::OutboundPayment::CreateParams::DestinationPaymentMethodData))
}
attr_accessor :destination_payment_method_data
# Payment method-specific configuration for this OutboundPayment.
sig {
returns(T.nilable(::Stripe::Treasury::OutboundPayment::CreateParams::DestinationPaymentMethodOptions))
}
attr_accessor :destination_payment_method_options
# End user details.
sig {
returns(T.nilable(::Stripe::Treasury::OutboundPayment::CreateParams::EndUserDetails))
}
attr_accessor :end_user_details
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The FinancialAccount to pull funds from.
sig { returns(String) }
attr_accessor :financial_account
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The description that appears on the receiving end for this OutboundPayment (for example, bank statement for external bank transfer). Maximum 10 characters for `ach` payments, 140 characters for `us_domestic_wire` payments, or 500 characters for `stripe` network transfers. The default value is "payment".
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
sig {
params(amount: Integer, currency: String, customer: T.nilable(String), description: T.nilable(String), destination_payment_method: T.nilable(String), destination_payment_method_data: T.nilable(::Stripe::Treasury::OutboundPayment::CreateParams::DestinationPaymentMethodData), destination_payment_method_options: T.nilable(::Stripe::Treasury::OutboundPayment::CreateParams::DestinationPaymentMethodOptions), end_user_details: T.nilable(::Stripe::Treasury::OutboundPayment::CreateParams::EndUserDetails), expand: T.nilable(T::Array[String]), financial_account: String, metadata: T.nilable(T::Hash[String, String]), statement_descriptor: T.nilable(String)).void
}
def initialize(
amount: nil,
currency: nil,
customer: nil,
description: nil,
destination_payment_method: nil,
destination_payment_method_data: nil,
destination_payment_method_options: nil,
end_user_details: nil,
expand: nil,
financial_account: nil,
metadata: nil,
statement_descriptor: nil
); end
end
class CancelParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
class TrackingDetails < Stripe::RequestParams
class Ach < Stripe::RequestParams
# ACH trace ID for funds sent over the `ach` network.
sig { returns(String) }
attr_accessor :trace_id
sig { params(trace_id: String).void }
def initialize(trace_id: nil); end
end
class UsDomesticWire < Stripe::RequestParams
# CHIPS System Sequence Number (SSN) for funds sent over the `us_domestic_wire` network.
sig { returns(T.nilable(String)) }
attr_accessor :chips
# IMAD for funds sent over the `us_domestic_wire` network.
sig { returns(T.nilable(String)) }
attr_accessor :imad
# OMAD for funds sent over the `us_domestic_wire` network.
sig { returns(T.nilable(String)) }
attr_accessor :omad
sig {
params(chips: T.nilable(String), imad: T.nilable(String), omad: T.nilable(String)).void
}
def initialize(chips: nil, imad: nil, omad: nil); end
end
# ACH network tracking details.
sig {
returns(T.nilable(::Stripe::Treasury::OutboundPayment::UpdateParams::TrackingDetails::Ach))
}
attr_accessor :ach
# The US bank account network used to send funds.
sig { returns(String) }
attr_accessor :type
# US domestic wire network tracking details.
sig {
returns(T.nilable(::Stripe::Treasury::OutboundPayment::UpdateParams::TrackingDetails::UsDomesticWire))
}
attr_accessor :us_domestic_wire
sig {
params(ach: T.nilable(::Stripe::Treasury::OutboundPayment::UpdateParams::TrackingDetails::Ach), type: String, us_domestic_wire: T.nilable(::Stripe::Treasury::OutboundPayment::UpdateParams::TrackingDetails::UsDomesticWire)).void
}
def initialize(ach: nil, type: nil, us_domestic_wire: nil); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Details about network-specific tracking information.
sig { returns(::Stripe::Treasury::OutboundPayment::UpdateParams::TrackingDetails) }
attr_accessor :tracking_details
sig {
params(expand: T.nilable(T::Array[String]), tracking_details: ::Stripe::Treasury::OutboundPayment::UpdateParams::TrackingDetails).void
}
def initialize(expand: nil, tracking_details: nil); end
end
class FailParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class PostParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class ReturnOutboundPaymentParams < Stripe::RequestParams
class ReturnedDetails < Stripe::RequestParams
# The return code to be set on the OutboundPayment object.
sig { returns(T.nilable(String)) }
attr_accessor :code
sig { params(code: T.nilable(String)).void }
def initialize(code: nil); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Optional hash to set the return code.
sig {
returns(T.nilable(::Stripe::Treasury::OutboundPayment::ReturnOutboundPaymentParams::ReturnedDetails))
}
attr_accessor :returned_details
sig {
params(expand: T.nilable(T::Array[String]), returned_details: T.nilable(::Stripe::Treasury::OutboundPayment::ReturnOutboundPaymentParams::ReturnedDetails)).void
}
def initialize(expand: nil, returned_details: nil); end
end
# Cancel an OutboundPayment.
sig {
params(params: T.any(::Stripe::Treasury::OutboundPayment::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::OutboundPayment)
}
def cancel(params = {}, opts = {}); end
# Cancel an OutboundPayment.
sig {
params(id: String, params: T.any(::Stripe::Treasury::OutboundPayment::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::OutboundPayment)
}
def self.cancel(id, params = {}, opts = {}); end
# Creates an OutboundPayment.
sig {
params(params: T.any(::Stripe::Treasury::OutboundPayment::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::OutboundPayment)
}
def self.create(params = {}, opts = {}); end
# Returns a list of OutboundPayments sent from the specified FinancialAccount.
sig {
params(params: T.any(::Stripe::Treasury::OutboundPayment::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Treasury
# Use [OutboundTransfers](https://docs.stripe.com/docs/treasury/moving-money/financial-accounts/out-of/outbound-transfers) to transfer funds from a [FinancialAccount](https://stripe.com/docs/api#financial_accounts) to a PaymentMethod belonging to the same entity. To send funds to a different party, use [OutboundPayments](https://stripe.com/docs/api#outbound_payments) instead. You can send funds over ACH rails or through a domestic wire transfer to a user's own external bank account.
#
# Simulate OutboundTransfer state changes with the `/v1/test_helpers/treasury/outbound_transfers` endpoints. These methods can only be called on test mode objects.
#
# Related guide: [Moving money with Treasury using OutboundTransfer objects](https://docs.stripe.com/docs/treasury/moving-money/financial-accounts/out-of/outbound-transfers)
class OutboundTransfer < APIResource
class DestinationPaymentMethodDetails < Stripe::StripeObject
class BillingDetails < Stripe::StripeObject
class Address < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Attribute for field address
sig { returns(Address) }
attr_reader :address
# Email address.
sig { returns(T.nilable(String)) }
attr_reader :email
# Full name.
sig { returns(T.nilable(String)) }
attr_reader :name
end
class FinancialAccount < Stripe::StripeObject
# Token of the FinancialAccount.
sig { returns(String) }
attr_reader :id
# The rails used to send funds.
sig { returns(String) }
attr_reader :network
end
class UsBankAccount < Stripe::StripeObject
# Account holder type: individual or company.
sig { returns(T.nilable(String)) }
attr_reader :account_holder_type
# Account type: checkings or savings. Defaults to checking if omitted.
sig { returns(T.nilable(String)) }
attr_reader :account_type
# Name of the bank associated with the bank account.
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.
sig { returns(T.nilable(String)) }
attr_reader :fingerprint
# Last four digits of the bank account number.
sig { returns(T.nilable(String)) }
attr_reader :last4
# ID of the mandate used to make this payment.
sig { returns(T.any(String, Stripe::Mandate)) }
attr_reader :mandate
# The network rails used. See the [docs](https://stripe.com/docs/treasury/money-movement/timelines) to learn more about money movement timelines for each network type.
sig { returns(String) }
attr_reader :network
# Routing number of the bank account.
sig { returns(T.nilable(String)) }
attr_reader :routing_number
end
# Attribute for field billing_details
sig { returns(BillingDetails) }
attr_reader :billing_details
# Attribute for field financial_account
sig { returns(FinancialAccount) }
attr_reader :financial_account
# The type of the payment method used in the OutboundTransfer.
sig { returns(String) }
attr_reader :type
# Attribute for field us_bank_account
sig { returns(UsBankAccount) }
attr_reader :us_bank_account
end
class NetworkDetails < Stripe::StripeObject
class Ach < Stripe::StripeObject
# ACH Addenda record
sig { returns(T.nilable(String)) }
attr_reader :addenda
end
# Details about an ACH transaction.
sig { returns(T.nilable(Ach)) }
attr_reader :ach
# The type of flow that originated the OutboundTransfer.
sig { returns(String) }
attr_reader :type
end
class ReturnedDetails < Stripe::StripeObject
# Reason for the return.
sig { returns(String) }
attr_reader :code
# The Transaction associated with this object.
sig { returns(T.any(String, Stripe::Treasury::Transaction)) }
attr_reader :transaction
end
class StatusTransitions < Stripe::StripeObject
# Timestamp describing when an OutboundTransfer changed status to `canceled`
sig { returns(T.nilable(Integer)) }
attr_reader :canceled_at
# Timestamp describing when an OutboundTransfer changed status to `failed`
sig { returns(T.nilable(Integer)) }
attr_reader :failed_at
# Timestamp describing when an OutboundTransfer changed status to `posted`
sig { returns(T.nilable(Integer)) }
attr_reader :posted_at
# Timestamp describing when an OutboundTransfer changed status to `returned`
sig { returns(T.nilable(Integer)) }
attr_reader :returned_at
end
class TrackingDetails < Stripe::StripeObject
class Ach < Stripe::StripeObject
# ACH trace ID of the OutboundTransfer for transfers sent over the `ach` network.
sig { returns(String) }
attr_reader :trace_id
end
class UsDomesticWire < Stripe::StripeObject
# CHIPS System Sequence Number (SSN) of the OutboundTransfer for transfers sent over the `us_domestic_wire` network.
sig { returns(T.nilable(String)) }
attr_reader :chips
# IMAD of the OutboundTransfer for transfers sent over the `us_domestic_wire` network.
sig { returns(T.nilable(String)) }
attr_reader :imad
# OMAD of the OutboundTransfer for transfers sent over the `us_domestic_wire` network.
sig { returns(T.nilable(String)) }
attr_reader :omad
end
# Attribute for field ach
sig { returns(Ach) }
attr_reader :ach
# The US bank account network used to send funds.
sig { returns(String) }
attr_reader :type
# Attribute for field us_domestic_wire
sig { returns(UsDomesticWire) }
attr_reader :us_domestic_wire
end
# Amount (in cents) transferred.
sig { returns(Integer) }
attr_reader :amount
# Returns `true` if the object can be canceled, and `false` otherwise.
sig { returns(T::Boolean) }
attr_reader :cancelable
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# 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).
sig { returns(String) }
attr_reader :currency
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_reader :description
# The PaymentMethod used as the payment instrument for an OutboundTransfer.
sig { returns(T.nilable(String)) }
attr_reader :destination_payment_method
# Attribute for field destination_payment_method_details
sig { returns(DestinationPaymentMethodDetails) }
attr_reader :destination_payment_method_details
# The date when funds are expected to arrive in the destination account.
sig { returns(Integer) }
attr_reader :expected_arrival_date
# The FinancialAccount that funds were pulled from.
sig { returns(String) }
attr_reader :financial_account
# A [hosted transaction receipt](https://stripe.com/docs/treasury/moving-money/regulatory-receipts) URL that is provided when money movement is considered regulated under Stripe's money transmission licenses.
sig { returns(T.nilable(String)) }
attr_reader :hosted_regulatory_receipt_url
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# 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.
sig { returns(T::Hash[String, String]) }
attr_reader :metadata
# Details about the network used for the OutboundTransfer.
sig { returns(T.nilable(NetworkDetails)) }
attr_reader :network_details
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Details about a returned OutboundTransfer. Only set when the status is `returned`.
sig { returns(T.nilable(ReturnedDetails)) }
attr_reader :returned_details
# Information about the OutboundTransfer to be sent to the recipient account.
sig { returns(String) }
attr_reader :statement_descriptor
# Current status of the OutboundTransfer: `processing`, `failed`, `canceled`, `posted`, `returned`. An OutboundTransfer is `processing` if it has been created and is pending. The status changes to `posted` once the OutboundTransfer has been "confirmed" and funds have left the account, or to `failed` or `canceled`. If an OutboundTransfer fails to arrive at its destination, its status will change to `returned`.
sig { returns(String) }
attr_reader :status
# Attribute for field status_transitions
sig { returns(StatusTransitions) }
attr_reader :status_transitions
# Details about network-specific tracking information if available.
sig { returns(T.nilable(TrackingDetails)) }
attr_reader :tracking_details
# The Transaction associated with this object.
sig { returns(T.any(String, Stripe::Treasury::Transaction)) }
attr_reader :transaction
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Returns objects associated with this FinancialAccount.
sig { returns(String) }
attr_accessor :financial_account
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return OutboundTransfers that have the given status: `processing`, `canceled`, `failed`, `posted`, or `returned`.
sig { returns(T.nilable(String)) }
attr_accessor :status
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), financial_account: String, limit: T.nilable(Integer), starting_after: T.nilable(String), status: T.nilable(String)).void
}
def initialize(
ending_before: nil,
expand: nil,
financial_account: nil,
limit: nil,
starting_after: nil,
status: nil
); end
end
class CreateParams < Stripe::RequestParams
class DestinationPaymentMethodData < Stripe::RequestParams
# Required if type is set to `financial_account`. The FinancialAccount ID to send funds to.
sig { returns(T.nilable(String)) }
attr_accessor :financial_account
# The type of the destination.
sig { returns(String) }
attr_accessor :type
sig { params(financial_account: T.nilable(String), type: String).void }
def initialize(financial_account: nil, type: nil); end
end
class DestinationPaymentMethodOptions < Stripe::RequestParams
class UsBankAccount < Stripe::RequestParams
# Specifies the network rails to be used. If not set, will default to the PaymentMethod's preferred network. See the [docs](https://stripe.com/docs/treasury/money-movement/timelines) to learn more about money movement timelines for each network type.
sig { returns(T.nilable(String)) }
attr_accessor :network
sig { params(network: T.nilable(String)).void }
def initialize(network: nil); end
end
# Optional fields for `us_bank_account`.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Treasury::OutboundTransfer::CreateParams::DestinationPaymentMethodOptions::UsBankAccount))))
}
attr_accessor :us_bank_account
sig {
params(us_bank_account: T.nilable(T.nilable(T.any(String, ::Stripe::Treasury::OutboundTransfer::CreateParams::DestinationPaymentMethodOptions::UsBankAccount)))).void
}
def initialize(us_bank_account: nil); end
end
class NetworkDetails < Stripe::RequestParams
class Ach < Stripe::RequestParams
# Addenda record data associated with this OutboundTransfer.
sig { returns(T.nilable(String)) }
attr_accessor :addenda
sig { params(addenda: T.nilable(String)).void }
def initialize(addenda: nil); end
end
# Optional fields for `ach`.
sig {
returns(T.nilable(::Stripe::Treasury::OutboundTransfer::CreateParams::NetworkDetails::Ach))
}
attr_accessor :ach
# The type of flow that originated the OutboundTransfer.
sig { returns(String) }
attr_accessor :type
sig {
params(ach: T.nilable(::Stripe::Treasury::OutboundTransfer::CreateParams::NetworkDetails::Ach), type: String).void
}
def initialize(ach: nil, type: nil); end
end
# Amount (in cents) to be transferred.
sig { returns(Integer) }
attr_accessor :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).
sig { returns(String) }
attr_accessor :currency
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# The PaymentMethod to use as the payment instrument for the OutboundTransfer.
sig { returns(T.nilable(String)) }
attr_accessor :destination_payment_method
# Hash used to generate the PaymentMethod to be used for this OutboundTransfer. Exclusive with `destination_payment_method`.
sig {
returns(T.nilable(::Stripe::Treasury::OutboundTransfer::CreateParams::DestinationPaymentMethodData))
}
attr_accessor :destination_payment_method_data
# Hash describing payment method configuration details.
sig {
returns(T.nilable(::Stripe::Treasury::OutboundTransfer::CreateParams::DestinationPaymentMethodOptions))
}
attr_accessor :destination_payment_method_options
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The FinancialAccount to pull funds from.
sig { returns(String) }
attr_accessor :financial_account
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Details about the network used for the OutboundTransfer.
sig {
returns(T.nilable(::Stripe::Treasury::OutboundTransfer::CreateParams::NetworkDetails))
}
attr_accessor :network_details
# Statement descriptor to be shown on the receiving end of an OutboundTransfer. Maximum 10 characters for `ach` transfers or 140 characters for `us_domestic_wire` transfers. The default value is "transfer".
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
sig {
params(amount: Integer, currency: String, description: T.nilable(String), destination_payment_method: T.nilable(String), destination_payment_method_data: T.nilable(::Stripe::Treasury::OutboundTransfer::CreateParams::DestinationPaymentMethodData), destination_payment_method_options: T.nilable(::Stripe::Treasury::OutboundTransfer::CreateParams::DestinationPaymentMethodOptions), expand: T.nilable(T::Array[String]), financial_account: String, metadata: T.nilable(T::Hash[String, String]), network_details: T.nilable(::Stripe::Treasury::OutboundTransfer::CreateParams::NetworkDetails), statement_descriptor: T.nilable(String)).void
}
def initialize(
amount: nil,
currency: nil,
description: nil,
destination_payment_method: nil,
destination_payment_method_data: nil,
destination_payment_method_options: nil,
expand: nil,
financial_account: nil,
metadata: nil,
network_details: nil,
statement_descriptor: nil
); end
end
class CancelParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
class TrackingDetails < Stripe::RequestParams
class Ach < Stripe::RequestParams
# ACH trace ID for funds sent over the `ach` network.
sig { returns(String) }
attr_accessor :trace_id
sig { params(trace_id: String).void }
def initialize(trace_id: nil); end
end
class UsDomesticWire < Stripe::RequestParams
# CHIPS System Sequence Number (SSN) for funds sent over the `us_domestic_wire` network.
sig { returns(T.nilable(String)) }
attr_accessor :chips
# IMAD for funds sent over the `us_domestic_wire` network.
sig { returns(T.nilable(String)) }
attr_accessor :imad
# OMAD for funds sent over the `us_domestic_wire` network.
sig { returns(T.nilable(String)) }
attr_accessor :omad
sig {
params(chips: T.nilable(String), imad: T.nilable(String), omad: T.nilable(String)).void
}
def initialize(chips: nil, imad: nil, omad: nil); end
end
# ACH network tracking details.
sig {
returns(T.nilable(::Stripe::Treasury::OutboundTransfer::UpdateParams::TrackingDetails::Ach))
}
attr_accessor :ach
# The US bank account network used to send funds.
sig { returns(String) }
attr_accessor :type
# US domestic wire network tracking details.
sig {
returns(T.nilable(::Stripe::Treasury::OutboundTransfer::UpdateParams::TrackingDetails::UsDomesticWire))
}
attr_accessor :us_domestic_wire
sig {
params(ach: T.nilable(::Stripe::Treasury::OutboundTransfer::UpdateParams::TrackingDetails::Ach), type: String, us_domestic_wire: T.nilable(::Stripe::Treasury::OutboundTransfer::UpdateParams::TrackingDetails::UsDomesticWire)).void
}
def initialize(ach: nil, type: nil, us_domestic_wire: nil); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Details about network-specific tracking information.
sig { returns(::Stripe::Treasury::OutboundTransfer::UpdateParams::TrackingDetails) }
attr_accessor :tracking_details
sig {
params(expand: T.nilable(T::Array[String]), tracking_details: ::Stripe::Treasury::OutboundTransfer::UpdateParams::TrackingDetails).void
}
def initialize(expand: nil, tracking_details: nil); end
end
class FailParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class PostParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class ReturnOutboundTransferParams < Stripe::RequestParams
class ReturnedDetails < Stripe::RequestParams
# Reason for the return.
sig { returns(T.nilable(String)) }
attr_accessor :code
sig { params(code: T.nilable(String)).void }
def initialize(code: nil); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Details about a returned OutboundTransfer.
sig {
returns(T.nilable(::Stripe::Treasury::OutboundTransfer::ReturnOutboundTransferParams::ReturnedDetails))
}
attr_accessor :returned_details
sig {
params(expand: T.nilable(T::Array[String]), returned_details: T.nilable(::Stripe::Treasury::OutboundTransfer::ReturnOutboundTransferParams::ReturnedDetails)).void
}
def initialize(expand: nil, returned_details: nil); end
end
# An OutboundTransfer can be canceled if the funds have not yet been paid out.
sig {
params(params: T.any(::Stripe::Treasury::OutboundTransfer::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::OutboundTransfer)
}
def cancel(params = {}, opts = {}); end
# An OutboundTransfer can be canceled if the funds have not yet been paid out.
sig {
params(outbound_transfer: String, params: T.any(::Stripe::Treasury::OutboundTransfer::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::OutboundTransfer)
}
def self.cancel(outbound_transfer, params = {}, opts = {}); end
# Creates an OutboundTransfer.
sig {
params(params: T.any(::Stripe::Treasury::OutboundTransfer::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::OutboundTransfer)
}
def self.create(params = {}, opts = {}); end
# Returns a list of OutboundTransfers sent from the specified FinancialAccount.
sig {
params(params: T.any(::Stripe::Treasury::OutboundTransfer::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Treasury
# ReceivedCredits represent funds sent to a [FinancialAccount](https://stripe.com/docs/api#financial_accounts) (for example, via ACH or wire). These money movements are not initiated from the FinancialAccount.
class ReceivedCredit < APIResource
class InitiatingPaymentMethodDetails < Stripe::StripeObject
class BillingDetails < Stripe::StripeObject
class Address < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Attribute for field address
sig { returns(Address) }
attr_reader :address
# Email address.
sig { returns(T.nilable(String)) }
attr_reader :email
# Full name.
sig { returns(T.nilable(String)) }
attr_reader :name
end
class FinancialAccount < Stripe::StripeObject
# The FinancialAccount ID.
sig { returns(String) }
attr_reader :id
# The rails the ReceivedCredit was sent over. A FinancialAccount can only send funds over `stripe`.
sig { returns(String) }
attr_reader :network
end
class UsBankAccount < Stripe::StripeObject
# Bank name.
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# The last four digits of the bank account number.
sig { returns(T.nilable(String)) }
attr_reader :last4
# The routing number for the bank account.
sig { returns(T.nilable(String)) }
attr_reader :routing_number
end
# Set when `type` is `balance`.
sig { returns(String) }
attr_reader :balance
# Attribute for field billing_details
sig { returns(BillingDetails) }
attr_reader :billing_details
# Attribute for field financial_account
sig { returns(FinancialAccount) }
attr_reader :financial_account
# Set when `type` is `issuing_card`. This is an [Issuing Card](https://stripe.com/docs/api#issuing_cards) ID.
sig { returns(String) }
attr_reader :issuing_card
# Polymorphic type matching the originating money movement's source. This can be an external account, a Stripe balance, or a FinancialAccount.
sig { returns(String) }
attr_reader :type
# Attribute for field us_bank_account
sig { returns(UsBankAccount) }
attr_reader :us_bank_account
end
class LinkedFlows < Stripe::StripeObject
class SourceFlowDetails < Stripe::StripeObject
# You can reverse some [ReceivedCredits](https://stripe.com/docs/api#received_credits) depending on their network and source flow. Reversing a ReceivedCredit leads to the creation of a new object known as a CreditReversal.
sig { returns(Stripe::Treasury::CreditReversal) }
attr_reader :credit_reversal
# Use [OutboundPayments](https://docs.stripe.com/docs/treasury/moving-money/financial-accounts/out-of/outbound-payments) to send funds to another party's external bank account or [FinancialAccount](https://stripe.com/docs/api#financial_accounts). To send money to an account belonging to the same user, use an [OutboundTransfer](https://stripe.com/docs/api#outbound_transfers).
#
# Simulate OutboundPayment state changes with the `/v1/test_helpers/treasury/outbound_payments` endpoints. These methods can only be called on test mode objects.
#
# Related guide: [Moving money with Treasury using OutboundPayment objects](https://docs.stripe.com/docs/treasury/moving-money/financial-accounts/out-of/outbound-payments)
sig { returns(Stripe::Treasury::OutboundPayment) }
attr_reader :outbound_payment
# Use [OutboundTransfers](https://docs.stripe.com/docs/treasury/moving-money/financial-accounts/out-of/outbound-transfers) to transfer funds from a [FinancialAccount](https://stripe.com/docs/api#financial_accounts) to a PaymentMethod belonging to the same entity. To send funds to a different party, use [OutboundPayments](https://stripe.com/docs/api#outbound_payments) instead. You can send funds over ACH rails or through a domestic wire transfer to a user's own external bank account.
#
# Simulate OutboundTransfer state changes with the `/v1/test_helpers/treasury/outbound_transfers` endpoints. These methods can only be called on test mode objects.
#
# Related guide: [Moving money with Treasury using OutboundTransfer objects](https://docs.stripe.com/docs/treasury/moving-money/financial-accounts/out-of/outbound-transfers)
sig { returns(Stripe::Treasury::OutboundTransfer) }
attr_reader :outbound_transfer
# A `Payout` object is created when you receive funds from Stripe, or when you
# initiate a payout to either a bank account or debit card of a [connected
# Stripe account](/docs/connect/bank-debit-card-payouts). You can retrieve individual payouts,
# and list all payouts. Payouts are made on [varying
# schedules](/docs/connect/manage-payout-schedule), depending on your country and
# industry.
#
# Related guide: [Receiving payouts](https://stripe.com/docs/payouts)
sig { returns(Stripe::Payout) }
attr_reader :payout
# The type of the source flow that originated the ReceivedCredit.
sig { returns(String) }
attr_reader :type
end
# The CreditReversal created as a result of this ReceivedCredit being reversed.
sig { returns(T.nilable(String)) }
attr_reader :credit_reversal
# Set if the ReceivedCredit was created due to an [Issuing Authorization](https://stripe.com/docs/api#issuing_authorizations) object.
sig { returns(T.nilable(String)) }
attr_reader :issuing_authorization
# Set if the ReceivedCredit is also viewable as an [Issuing transaction](https://stripe.com/docs/api#issuing_transactions) object.
sig { returns(T.nilable(String)) }
attr_reader :issuing_transaction
# ID of the source flow. Set if `network` is `stripe` and the source flow is visible to the user. Examples of source flows include OutboundPayments, payouts, or CreditReversals.
sig { returns(T.nilable(String)) }
attr_reader :source_flow
# The expandable object of the source flow.
sig { returns(T.nilable(SourceFlowDetails)) }
attr_reader :source_flow_details
# The type of flow that originated the ReceivedCredit (for example, `outbound_payment`).
sig { returns(T.nilable(String)) }
attr_reader :source_flow_type
end
class NetworkDetails < Stripe::StripeObject
class Ach < Stripe::StripeObject
# ACH Addenda record
sig { returns(T.nilable(String)) }
attr_reader :addenda
end
# Details about an ACH transaction.
sig { returns(T.nilable(Ach)) }
attr_reader :ach
# The type of flow that originated the ReceivedCredit.
sig { returns(String) }
attr_reader :type
end
class ReversalDetails < Stripe::StripeObject
# Time before which a ReceivedCredit can be reversed.
sig { returns(T.nilable(Integer)) }
attr_reader :deadline
# Set if a ReceivedCredit cannot be reversed.
sig { returns(T.nilable(String)) }
attr_reader :restricted_reason
end
# Amount (in cents) transferred.
sig { returns(Integer) }
attr_reader :amount
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# 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).
sig { returns(String) }
attr_reader :currency
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(String) }
attr_reader :description
# Reason for the failure. A ReceivedCredit might fail because the receiving FinancialAccount is closed or frozen.
sig { returns(T.nilable(String)) }
attr_reader :failure_code
# The FinancialAccount that received the funds.
sig { returns(T.nilable(String)) }
attr_reader :financial_account
# A [hosted transaction receipt](https://stripe.com/docs/treasury/moving-money/regulatory-receipts) URL that is provided when money movement is considered regulated under Stripe's money transmission licenses.
sig { returns(T.nilable(String)) }
attr_reader :hosted_regulatory_receipt_url
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Attribute for field initiating_payment_method_details
sig { returns(InitiatingPaymentMethodDetails) }
attr_reader :initiating_payment_method_details
# Attribute for field linked_flows
sig { returns(LinkedFlows) }
attr_reader :linked_flows
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# The rails used to send the funds.
sig { returns(String) }
attr_reader :network
# Details specific to the money movement rails.
sig { returns(T.nilable(NetworkDetails)) }
attr_reader :network_details
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Details describing when a ReceivedCredit may be reversed.
sig { returns(T.nilable(ReversalDetails)) }
attr_reader :reversal_details
# Status of the ReceivedCredit. ReceivedCredits are created either `succeeded` (approved) or `failed` (declined). If a ReceivedCredit is declined, the failure reason can be found in the `failure_code` field.
sig { returns(String) }
attr_reader :status
# The Transaction associated with this object.
sig { returns(T.nilable(T.any(String, Stripe::Treasury::Transaction))) }
attr_reader :transaction
class ListParams < Stripe::RequestParams
class LinkedFlows < Stripe::RequestParams
# The source flow type.
sig { returns(String) }
attr_accessor :source_flow_type
sig { params(source_flow_type: String).void }
def initialize(source_flow_type: nil); end
end
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The FinancialAccount that received the funds.
sig { returns(String) }
attr_accessor :financial_account
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Only return ReceivedCredits described by the flow.
sig { returns(T.nilable(::Stripe::Treasury::ReceivedCredit::ListParams::LinkedFlows)) }
attr_accessor :linked_flows
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return ReceivedCredits that have the given status: `succeeded` or `failed`.
sig { returns(T.nilable(String)) }
attr_accessor :status
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), financial_account: String, limit: T.nilable(Integer), linked_flows: T.nilable(::Stripe::Treasury::ReceivedCredit::ListParams::LinkedFlows), starting_after: T.nilable(String), status: T.nilable(String)).void
}
def initialize(
ending_before: nil,
expand: nil,
financial_account: nil,
limit: nil,
linked_flows: nil,
starting_after: nil,
status: nil
); end
end
class CreateParams < Stripe::RequestParams
class InitiatingPaymentMethodDetails < Stripe::RequestParams
class UsBankAccount < Stripe::RequestParams
# The bank account holder's name.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_name
# The bank account number.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# The bank account's routing number.
sig { returns(T.nilable(String)) }
attr_accessor :routing_number
sig {
params(account_holder_name: T.nilable(String), account_number: T.nilable(String), routing_number: T.nilable(String)).void
}
def initialize(account_holder_name: nil, account_number: nil, routing_number: nil); end
end
# The source type.
sig { returns(String) }
attr_accessor :type
# Optional fields for `us_bank_account`.
sig {
returns(T.nilable(::Stripe::Treasury::ReceivedCredit::CreateParams::InitiatingPaymentMethodDetails::UsBankAccount))
}
attr_accessor :us_bank_account
sig {
params(type: String, us_bank_account: T.nilable(::Stripe::Treasury::ReceivedCredit::CreateParams::InitiatingPaymentMethodDetails::UsBankAccount)).void
}
def initialize(type: nil, us_bank_account: nil); end
end
class NetworkDetails < Stripe::RequestParams
class Ach < Stripe::RequestParams
# ACH Addenda record
sig { returns(T.nilable(String)) }
attr_accessor :addenda
sig { params(addenda: T.nilable(String)).void }
def initialize(addenda: nil); end
end
# Optional fields for `ach`.
sig {
returns(T.nilable(::Stripe::Treasury::ReceivedCredit::CreateParams::NetworkDetails::Ach))
}
attr_accessor :ach
# The type of flow that originated the ReceivedCredit.
sig { returns(String) }
attr_accessor :type
sig {
params(ach: T.nilable(::Stripe::Treasury::ReceivedCredit::CreateParams::NetworkDetails::Ach), type: String).void
}
def initialize(ach: nil, type: nil); end
end
# Amount (in cents) to be transferred.
sig { returns(Integer) }
attr_accessor :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).
sig { returns(String) }
attr_accessor :currency
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The FinancialAccount to send funds to.
sig { returns(String) }
attr_accessor :financial_account
# Initiating payment method details for the object.
sig {
returns(T.nilable(::Stripe::Treasury::ReceivedCredit::CreateParams::InitiatingPaymentMethodDetails))
}
attr_accessor :initiating_payment_method_details
# Specifies the network rails to be used. If not set, will default to the PaymentMethod's preferred network. See the [docs](https://stripe.com/docs/treasury/money-movement/timelines) to learn more about money movement timelines for each network type.
sig { returns(String) }
attr_accessor :network
# Details about the network used for the ReceivedCredit.
sig { returns(T.nilable(::Stripe::Treasury::ReceivedCredit::CreateParams::NetworkDetails)) }
attr_accessor :network_details
sig {
params(amount: Integer, currency: String, description: T.nilable(String), expand: T.nilable(T::Array[String]), financial_account: String, initiating_payment_method_details: T.nilable(::Stripe::Treasury::ReceivedCredit::CreateParams::InitiatingPaymentMethodDetails), network: String, network_details: T.nilable(::Stripe::Treasury::ReceivedCredit::CreateParams::NetworkDetails)).void
}
def initialize(
amount: nil,
currency: nil,
description: nil,
expand: nil,
financial_account: nil,
initiating_payment_method_details: nil,
network: nil,
network_details: nil
); end
end
# Returns a list of ReceivedCredits.
sig {
params(params: T.any(::Stripe::Treasury::ReceivedCredit::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Treasury
# ReceivedDebits represent funds pulled from a [FinancialAccount](https://stripe.com/docs/api#financial_accounts). These are not initiated from the FinancialAccount.
class ReceivedDebit < APIResource
class InitiatingPaymentMethodDetails < Stripe::StripeObject
class BillingDetails < Stripe::StripeObject
class Address < Stripe::StripeObject
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_reader :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_reader :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_reader :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_reader :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_reader :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_reader :state
end
# Attribute for field address
sig { returns(Address) }
attr_reader :address
# Email address.
sig { returns(T.nilable(String)) }
attr_reader :email
# Full name.
sig { returns(T.nilable(String)) }
attr_reader :name
end
class FinancialAccount < Stripe::StripeObject
# The FinancialAccount ID.
sig { returns(String) }
attr_reader :id
# The rails the ReceivedCredit was sent over. A FinancialAccount can only send funds over `stripe`.
sig { returns(String) }
attr_reader :network
end
class UsBankAccount < Stripe::StripeObject
# Bank name.
sig { returns(T.nilable(String)) }
attr_reader :bank_name
# The last four digits of the bank account number.
sig { returns(T.nilable(String)) }
attr_reader :last4
# The routing number for the bank account.
sig { returns(T.nilable(String)) }
attr_reader :routing_number
end
# Set when `type` is `balance`.
sig { returns(String) }
attr_reader :balance
# Attribute for field billing_details
sig { returns(BillingDetails) }
attr_reader :billing_details
# Attribute for field financial_account
sig { returns(FinancialAccount) }
attr_reader :financial_account
# Set when `type` is `issuing_card`. This is an [Issuing Card](https://stripe.com/docs/api#issuing_cards) ID.
sig { returns(String) }
attr_reader :issuing_card
# Polymorphic type matching the originating money movement's source. This can be an external account, a Stripe balance, or a FinancialAccount.
sig { returns(String) }
attr_reader :type
# Attribute for field us_bank_account
sig { returns(UsBankAccount) }
attr_reader :us_bank_account
end
class LinkedFlows < Stripe::StripeObject
# The DebitReversal created as a result of this ReceivedDebit being reversed.
sig { returns(T.nilable(String)) }
attr_reader :debit_reversal
# Set if the ReceivedDebit is associated with an InboundTransfer's return of funds.
sig { returns(T.nilable(String)) }
attr_reader :inbound_transfer
# Set if the ReceivedDebit was created due to an [Issuing Authorization](https://stripe.com/docs/api#issuing_authorizations) object.
sig { returns(T.nilable(String)) }
attr_reader :issuing_authorization
# Set if the ReceivedDebit is also viewable as an [Issuing Dispute](https://stripe.com/docs/api#issuing_disputes) object.
sig { returns(T.nilable(String)) }
attr_reader :issuing_transaction
# Set if the ReceivedDebit was created due to a [Payout](https://stripe.com/docs/api#payouts) object.
sig { returns(T.nilable(String)) }
attr_reader :payout
# The ReceivedCredit that Capital withheld from
sig { returns(T.nilable(String)) }
attr_reader :received_credit_capital_withholding
end
class NetworkDetails < Stripe::StripeObject
class Ach < Stripe::StripeObject
# ACH Addenda record
sig { returns(T.nilable(String)) }
attr_reader :addenda
end
# Details about an ACH transaction.
sig { returns(T.nilable(Ach)) }
attr_reader :ach
# The type of flow that originated the ReceivedDebit.
sig { returns(String) }
attr_reader :type
end
class ReversalDetails < Stripe::StripeObject
# Time before which a ReceivedDebit can be reversed.
sig { returns(T.nilable(Integer)) }
attr_reader :deadline
# Set if a ReceivedDebit can't be reversed.
sig { returns(T.nilable(String)) }
attr_reader :restricted_reason
end
# Amount (in cents) transferred.
sig { returns(Integer) }
attr_reader :amount
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# 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).
sig { returns(String) }
attr_reader :currency
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(String) }
attr_reader :description
# Reason for the failure. A ReceivedDebit might fail because the FinancialAccount doesn't have sufficient funds, is closed, or is frozen.
sig { returns(T.nilable(String)) }
attr_reader :failure_code
# The FinancialAccount that funds were pulled from.
sig { returns(T.nilable(String)) }
attr_reader :financial_account
# A [hosted transaction receipt](https://stripe.com/docs/treasury/moving-money/regulatory-receipts) URL that is provided when money movement is considered regulated under Stripe's money transmission licenses.
sig { returns(T.nilable(String)) }
attr_reader :hosted_regulatory_receipt_url
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Attribute for field initiating_payment_method_details
sig { returns(InitiatingPaymentMethodDetails) }
attr_reader :initiating_payment_method_details
# Attribute for field linked_flows
sig { returns(LinkedFlows) }
attr_reader :linked_flows
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# The network used for the ReceivedDebit.
sig { returns(String) }
attr_reader :network
# Details specific to the money movement rails.
sig { returns(T.nilable(NetworkDetails)) }
attr_reader :network_details
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Details describing when a ReceivedDebit might be reversed.
sig { returns(T.nilable(ReversalDetails)) }
attr_reader :reversal_details
# Status of the ReceivedDebit. ReceivedDebits are created with a status of either `succeeded` (approved) or `failed` (declined). The failure reason can be found under the `failure_code`.
sig { returns(String) }
attr_reader :status
# The Transaction associated with this object.
sig { returns(T.nilable(T.any(String, Stripe::Treasury::Transaction))) }
attr_reader :transaction
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The FinancialAccount that funds were pulled from.
sig { returns(String) }
attr_accessor :financial_account
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return ReceivedDebits that have the given status: `succeeded` or `failed`.
sig { returns(T.nilable(String)) }
attr_accessor :status
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), financial_account: String, limit: T.nilable(Integer), starting_after: T.nilable(String), status: T.nilable(String)).void
}
def initialize(
ending_before: nil,
expand: nil,
financial_account: nil,
limit: nil,
starting_after: nil,
status: nil
); end
end
class CreateParams < Stripe::RequestParams
class InitiatingPaymentMethodDetails < Stripe::RequestParams
class UsBankAccount < Stripe::RequestParams
# The bank account holder's name.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_name
# The bank account number.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# The bank account's routing number.
sig { returns(T.nilable(String)) }
attr_accessor :routing_number
sig {
params(account_holder_name: T.nilable(String), account_number: T.nilable(String), routing_number: T.nilable(String)).void
}
def initialize(account_holder_name: nil, account_number: nil, routing_number: nil); end
end
# The source type.
sig { returns(String) }
attr_accessor :type
# Optional fields for `us_bank_account`.
sig {
returns(T.nilable(::Stripe::Treasury::ReceivedDebit::CreateParams::InitiatingPaymentMethodDetails::UsBankAccount))
}
attr_accessor :us_bank_account
sig {
params(type: String, us_bank_account: T.nilable(::Stripe::Treasury::ReceivedDebit::CreateParams::InitiatingPaymentMethodDetails::UsBankAccount)).void
}
def initialize(type: nil, us_bank_account: nil); end
end
class NetworkDetails < Stripe::RequestParams
class Ach < Stripe::RequestParams
# Addenda record data associated with this ReceivedDebit.
sig { returns(T.nilable(String)) }
attr_accessor :addenda
sig { params(addenda: T.nilable(String)).void }
def initialize(addenda: nil); end
end
# Optional fields for `ach`.
sig {
returns(T.nilable(::Stripe::Treasury::ReceivedDebit::CreateParams::NetworkDetails::Ach))
}
attr_accessor :ach
# The type of flow that originated the ReceivedDebit.
sig { returns(String) }
attr_accessor :type
sig {
params(ach: T.nilable(::Stripe::Treasury::ReceivedDebit::CreateParams::NetworkDetails::Ach), type: String).void
}
def initialize(ach: nil, type: nil); end
end
# Amount (in cents) to be transferred.
sig { returns(Integer) }
attr_accessor :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).
sig { returns(String) }
attr_accessor :currency
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The FinancialAccount to pull funds from.
sig { returns(String) }
attr_accessor :financial_account
# Initiating payment method details for the object.
sig {
returns(T.nilable(::Stripe::Treasury::ReceivedDebit::CreateParams::InitiatingPaymentMethodDetails))
}
attr_accessor :initiating_payment_method_details
# Specifies the network rails to be used. If not set, will default to the PaymentMethod's preferred network. See the [docs](https://stripe.com/docs/treasury/money-movement/timelines) to learn more about money movement timelines for each network type.
sig { returns(String) }
attr_accessor :network
# Details about the network used for the ReceivedDebit.
sig { returns(T.nilable(::Stripe::Treasury::ReceivedDebit::CreateParams::NetworkDetails)) }
attr_accessor :network_details
sig {
params(amount: Integer, currency: String, description: T.nilable(String), expand: T.nilable(T::Array[String]), financial_account: String, initiating_payment_method_details: T.nilable(::Stripe::Treasury::ReceivedDebit::CreateParams::InitiatingPaymentMethodDetails), network: String, network_details: T.nilable(::Stripe::Treasury::ReceivedDebit::CreateParams::NetworkDetails)).void
}
def initialize(
amount: nil,
currency: nil,
description: nil,
expand: nil,
financial_account: nil,
initiating_payment_method_details: nil,
network: nil,
network_details: nil
); end
end
# Returns a list of ReceivedDebits.
sig {
params(params: T.any(::Stripe::Treasury::ReceivedDebit::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Treasury
# Transactions represent changes to a [FinancialAccount's](https://stripe.com/docs/api#financial_accounts) balance.
class Transaction < APIResource
class BalanceImpact < Stripe::StripeObject
# The change made to funds the user can spend right now.
sig { returns(Integer) }
attr_reader :cash
# The change made to funds that are not spendable yet, but will become available at a later time.
sig { returns(Integer) }
attr_reader :inbound_pending
# The change made to funds in the account, but not spendable because they are being held for pending outbound flows.
sig { returns(Integer) }
attr_reader :outbound_pending
end
class FlowDetails < Stripe::StripeObject
# You can reverse some [ReceivedCredits](https://stripe.com/docs/api#received_credits) depending on their network and source flow. Reversing a ReceivedCredit leads to the creation of a new object known as a CreditReversal.
sig { returns(Stripe::Treasury::CreditReversal) }
attr_reader :credit_reversal
# You can reverse some [ReceivedDebits](https://stripe.com/docs/api#received_debits) depending on their network and source flow. Reversing a ReceivedDebit leads to the creation of a new object known as a DebitReversal.
sig { returns(Stripe::Treasury::DebitReversal) }
attr_reader :debit_reversal
# Use [InboundTransfers](https://docs.stripe.com/docs/treasury/moving-money/financial-accounts/into/inbound-transfers) to add funds to your [FinancialAccount](https://stripe.com/docs/api#financial_accounts) via a PaymentMethod that is owned by you. The funds will be transferred via an ACH debit.
#
# Related guide: [Moving money with Treasury using InboundTransfer objects](https://docs.stripe.com/docs/treasury/moving-money/financial-accounts/into/inbound-transfers)
sig { returns(Stripe::Treasury::InboundTransfer) }
attr_reader :inbound_transfer
# When an [issued card](https://stripe.com/docs/issuing) is used to make a purchase, an Issuing `Authorization`
# object is created. [Authorizations](https://stripe.com/docs/issuing/purchases/authorizations) must be approved for the
# purchase to be completed successfully.
#
# Related guide: [Issued card authorizations](https://stripe.com/docs/issuing/purchases/authorizations)
sig { returns(Stripe::Issuing::Authorization) }
attr_reader :issuing_authorization
# Use [OutboundPayments](https://docs.stripe.com/docs/treasury/moving-money/financial-accounts/out-of/outbound-payments) to send funds to another party's external bank account or [FinancialAccount](https://stripe.com/docs/api#financial_accounts). To send money to an account belonging to the same user, use an [OutboundTransfer](https://stripe.com/docs/api#outbound_transfers).
#
# Simulate OutboundPayment state changes with the `/v1/test_helpers/treasury/outbound_payments` endpoints. These methods can only be called on test mode objects.
#
# Related guide: [Moving money with Treasury using OutboundPayment objects](https://docs.stripe.com/docs/treasury/moving-money/financial-accounts/out-of/outbound-payments)
sig { returns(Stripe::Treasury::OutboundPayment) }
attr_reader :outbound_payment
# Use [OutboundTransfers](https://docs.stripe.com/docs/treasury/moving-money/financial-accounts/out-of/outbound-transfers) to transfer funds from a [FinancialAccount](https://stripe.com/docs/api#financial_accounts) to a PaymentMethod belonging to the same entity. To send funds to a different party, use [OutboundPayments](https://stripe.com/docs/api#outbound_payments) instead. You can send funds over ACH rails or through a domestic wire transfer to a user's own external bank account.
#
# Simulate OutboundTransfer state changes with the `/v1/test_helpers/treasury/outbound_transfers` endpoints. These methods can only be called on test mode objects.
#
# Related guide: [Moving money with Treasury using OutboundTransfer objects](https://docs.stripe.com/docs/treasury/moving-money/financial-accounts/out-of/outbound-transfers)
sig { returns(Stripe::Treasury::OutboundTransfer) }
attr_reader :outbound_transfer
# ReceivedCredits represent funds sent to a [FinancialAccount](https://stripe.com/docs/api#financial_accounts) (for example, via ACH or wire). These money movements are not initiated from the FinancialAccount.
sig { returns(Stripe::Treasury::ReceivedCredit) }
attr_reader :received_credit
# ReceivedDebits represent funds pulled from a [FinancialAccount](https://stripe.com/docs/api#financial_accounts). These are not initiated from the FinancialAccount.
sig { returns(Stripe::Treasury::ReceivedDebit) }
attr_reader :received_debit
# Type of the flow that created the Transaction. Set to the same value as `flow_type`.
sig { returns(String) }
attr_reader :type
end
class StatusTransitions < Stripe::StripeObject
# Timestamp describing when the Transaction changed status to `posted`.
sig { returns(T.nilable(Integer)) }
attr_reader :posted_at
# Timestamp describing when the Transaction changed status to `void`.
sig { returns(T.nilable(Integer)) }
attr_reader :void_at
end
# Amount (in cents) transferred.
sig { returns(Integer) }
attr_reader :amount
# Change to a FinancialAccount's balance
sig { returns(BalanceImpact) }
attr_reader :balance_impact
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# 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).
sig { returns(String) }
attr_reader :currency
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(String) }
attr_reader :description
# A list of TransactionEntries that are part of this Transaction. This cannot be expanded in any list endpoints.
sig { returns(T.nilable(Stripe::ListObject)) }
attr_reader :entries
# The FinancialAccount associated with this object.
sig { returns(String) }
attr_reader :financial_account
# ID of the flow that created the Transaction.
sig { returns(T.nilable(String)) }
attr_reader :flow
# Details of the flow that created the Transaction.
sig { returns(T.nilable(FlowDetails)) }
attr_reader :flow_details
# Type of the flow that created the Transaction.
sig { returns(String) }
attr_reader :flow_type
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# Status of the Transaction.
sig { returns(String) }
attr_reader :status
# Attribute for field status_transitions
sig { returns(StatusTransitions) }
attr_reader :status_transitions
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
class StatusTransitions < Stripe::RequestParams
class PostedAt < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Returns Transactions with `posted_at` within the specified range.
sig {
returns(T.nilable(T.any(::Stripe::Treasury::Transaction::ListParams::StatusTransitions::PostedAt, Integer)))
}
attr_accessor :posted_at
sig {
params(posted_at: T.nilable(T.any(::Stripe::Treasury::Transaction::ListParams::StatusTransitions::PostedAt, Integer))).void
}
def initialize(posted_at: nil); end
end
# Only return Transactions that were created during the given date interval.
sig {
returns(T.nilable(T.any(::Stripe::Treasury::Transaction::ListParams::Created, Integer)))
}
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Returns objects associated with this FinancialAccount.
sig { returns(String) }
attr_accessor :financial_account
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# The results are in reverse chronological order by `created` or `posted_at`. The default is `created`.
sig { returns(T.nilable(String)) }
attr_accessor :order_by
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return Transactions that have the given status: `open`, `posted`, or `void`.
sig { returns(T.nilable(String)) }
attr_accessor :status
# A filter for the `status_transitions.posted_at` timestamp. When using this filter, `status=posted` and `order_by=posted_at` must also be specified.
sig { returns(T.nilable(::Stripe::Treasury::Transaction::ListParams::StatusTransitions)) }
attr_accessor :status_transitions
sig {
params(created: T.nilable(T.any(::Stripe::Treasury::Transaction::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), financial_account: String, limit: T.nilable(Integer), order_by: T.nilable(String), starting_after: T.nilable(String), status: T.nilable(String), status_transitions: T.nilable(::Stripe::Treasury::Transaction::ListParams::StatusTransitions)).void
}
def initialize(
created: nil,
ending_before: nil,
expand: nil,
financial_account: nil,
limit: nil,
order_by: nil,
starting_after: nil,
status: nil,
status_transitions: nil
); end
end
# Retrieves a list of Transaction objects.
sig {
params(params: T.any(::Stripe::Treasury::Transaction::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Treasury
# TransactionEntries represent individual units of money movements within a single [Transaction](https://stripe.com/docs/api#transactions).
class TransactionEntry < APIResource
class BalanceImpact < Stripe::StripeObject
# The change made to funds the user can spend right now.
sig { returns(Integer) }
attr_reader :cash
# The change made to funds that are not spendable yet, but will become available at a later time.
sig { returns(Integer) }
attr_reader :inbound_pending
# The change made to funds in the account, but not spendable because they are being held for pending outbound flows.
sig { returns(Integer) }
attr_reader :outbound_pending
end
class FlowDetails < Stripe::StripeObject
# You can reverse some [ReceivedCredits](https://stripe.com/docs/api#received_credits) depending on their network and source flow. Reversing a ReceivedCredit leads to the creation of a new object known as a CreditReversal.
sig { returns(Stripe::Treasury::CreditReversal) }
attr_reader :credit_reversal
# You can reverse some [ReceivedDebits](https://stripe.com/docs/api#received_debits) depending on their network and source flow. Reversing a ReceivedDebit leads to the creation of a new object known as a DebitReversal.
sig { returns(Stripe::Treasury::DebitReversal) }
attr_reader :debit_reversal
# Use [InboundTransfers](https://docs.stripe.com/docs/treasury/moving-money/financial-accounts/into/inbound-transfers) to add funds to your [FinancialAccount](https://stripe.com/docs/api#financial_accounts) via a PaymentMethod that is owned by you. The funds will be transferred via an ACH debit.
#
# Related guide: [Moving money with Treasury using InboundTransfer objects](https://docs.stripe.com/docs/treasury/moving-money/financial-accounts/into/inbound-transfers)
sig { returns(Stripe::Treasury::InboundTransfer) }
attr_reader :inbound_transfer
# When an [issued card](https://stripe.com/docs/issuing) is used to make a purchase, an Issuing `Authorization`
# object is created. [Authorizations](https://stripe.com/docs/issuing/purchases/authorizations) must be approved for the
# purchase to be completed successfully.
#
# Related guide: [Issued card authorizations](https://stripe.com/docs/issuing/purchases/authorizations)
sig { returns(Stripe::Issuing::Authorization) }
attr_reader :issuing_authorization
# Use [OutboundPayments](https://docs.stripe.com/docs/treasury/moving-money/financial-accounts/out-of/outbound-payments) to send funds to another party's external bank account or [FinancialAccount](https://stripe.com/docs/api#financial_accounts). To send money to an account belonging to the same user, use an [OutboundTransfer](https://stripe.com/docs/api#outbound_transfers).
#
# Simulate OutboundPayment state changes with the `/v1/test_helpers/treasury/outbound_payments` endpoints. These methods can only be called on test mode objects.
#
# Related guide: [Moving money with Treasury using OutboundPayment objects](https://docs.stripe.com/docs/treasury/moving-money/financial-accounts/out-of/outbound-payments)
sig { returns(Stripe::Treasury::OutboundPayment) }
attr_reader :outbound_payment
# Use [OutboundTransfers](https://docs.stripe.com/docs/treasury/moving-money/financial-accounts/out-of/outbound-transfers) to transfer funds from a [FinancialAccount](https://stripe.com/docs/api#financial_accounts) to a PaymentMethod belonging to the same entity. To send funds to a different party, use [OutboundPayments](https://stripe.com/docs/api#outbound_payments) instead. You can send funds over ACH rails or through a domestic wire transfer to a user's own external bank account.
#
# Simulate OutboundTransfer state changes with the `/v1/test_helpers/treasury/outbound_transfers` endpoints. These methods can only be called on test mode objects.
#
# Related guide: [Moving money with Treasury using OutboundTransfer objects](https://docs.stripe.com/docs/treasury/moving-money/financial-accounts/out-of/outbound-transfers)
sig { returns(Stripe::Treasury::OutboundTransfer) }
attr_reader :outbound_transfer
# ReceivedCredits represent funds sent to a [FinancialAccount](https://stripe.com/docs/api#financial_accounts) (for example, via ACH or wire). These money movements are not initiated from the FinancialAccount.
sig { returns(Stripe::Treasury::ReceivedCredit) }
attr_reader :received_credit
# ReceivedDebits represent funds pulled from a [FinancialAccount](https://stripe.com/docs/api#financial_accounts). These are not initiated from the FinancialAccount.
sig { returns(Stripe::Treasury::ReceivedDebit) }
attr_reader :received_debit
# Type of the flow that created the Transaction. Set to the same value as `flow_type`.
sig { returns(String) }
attr_reader :type
end
# Change to a FinancialAccount's balance
sig { returns(BalanceImpact) }
attr_reader :balance_impact
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# 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).
sig { returns(String) }
attr_reader :currency
# When the TransactionEntry will impact the FinancialAccount's balance.
sig { returns(Integer) }
attr_reader :effective_at
# The FinancialAccount associated with this object.
sig { returns(String) }
attr_reader :financial_account
# Token of the flow associated with the TransactionEntry.
sig { returns(T.nilable(String)) }
attr_reader :flow
# Details of the flow associated with the TransactionEntry.
sig { returns(T.nilable(FlowDetails)) }
attr_reader :flow_details
# Type of the flow associated with the TransactionEntry.
sig { returns(String) }
attr_reader :flow_type
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The Transaction associated with this object.
sig { returns(T.any(String, Stripe::Treasury::Transaction)) }
attr_reader :transaction
# The specific money movement that generated the TransactionEntry.
sig { returns(String) }
attr_reader :type
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
class EffectiveAt < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return TransactionEntries that were created during the given date interval.
sig {
returns(T.nilable(T.any(::Stripe::Treasury::TransactionEntry::ListParams::Created, Integer)))
}
attr_accessor :created
# Attribute for param field effective_at
sig {
returns(T.nilable(T.any(::Stripe::Treasury::TransactionEntry::ListParams::EffectiveAt, Integer)))
}
attr_accessor :effective_at
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Returns objects associated with this FinancialAccount.
sig { returns(String) }
attr_accessor :financial_account
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# The results are in reverse chronological order by `created` or `effective_at`. The default is `created`.
sig { returns(T.nilable(String)) }
attr_accessor :order_by
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return TransactionEntries associated with this Transaction.
sig { returns(T.nilable(String)) }
attr_accessor :transaction
sig {
params(created: T.nilable(T.any(::Stripe::Treasury::TransactionEntry::ListParams::Created, Integer)), effective_at: T.nilable(T.any(::Stripe::Treasury::TransactionEntry::ListParams::EffectiveAt, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), financial_account: String, limit: T.nilable(Integer), order_by: T.nilable(String), starting_after: T.nilable(String), transaction: T.nilable(String)).void
}
def initialize(
created: nil,
effective_at: nil,
ending_before: nil,
expand: nil,
financial_account: nil,
limit: nil,
order_by: nil,
starting_after: nil,
transaction: nil
); end
end
# Retrieves a list of TransactionEntry objects.
sig {
params(params: T.any(::Stripe::Treasury::TransactionEntry::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
# You can configure [webhook endpoints](https://docs.stripe.com/webhooks/) via the API to be
# notified about events that happen in your Stripe account or connected
# accounts.
#
# Most users configure webhooks from [the dashboard](https://dashboard.stripe.com/webhooks), which provides a user interface for registering and testing your webhook endpoints.
#
# Related guide: [Setting up webhooks](https://docs.stripe.com/webhooks/configure)
class WebhookEndpoint < APIResource
# The API version events are rendered as for this webhook endpoint.
sig { returns(T.nilable(String)) }
attr_reader :api_version
# The ID of the associated Connect application.
sig { returns(T.nilable(String)) }
attr_reader :application
# Time at which the object was created. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_reader :created
# An optional description of what the webhook is used for.
sig { returns(T.nilable(String)) }
attr_reader :description
# The list of events to enable for this endpoint. `['*']` indicates that all events are enabled, except those that require explicit selection.
sig { returns(T::Array[String]) }
attr_reader :enabled_events
# Unique identifier for the object.
sig { returns(String) }
attr_reader :id
# Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
sig { returns(T::Boolean) }
attr_reader :livemode
# 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.
sig { returns(T::Hash[String, String]) }
attr_reader :metadata
# String representing the object's type. Objects of the same type share the same value.
sig { returns(String) }
attr_reader :object
# The endpoint's secret, used to generate [webhook signatures](https://docs.stripe.com/webhooks/signatures). Only returned at creation.
sig { returns(String) }
attr_reader :secret
# The status of the webhook. It can be `enabled` or `disabled`.
sig { returns(String) }
attr_reader :status
# The URL of the webhook endpoint.
sig { returns(String) }
attr_reader :url
# Always true for a deleted object
sig { returns(T::Boolean) }
attr_reader :deleted
class DeleteParams < Stripe::RequestParams; end
class UpdateParams < Stripe::RequestParams
# An optional description of what the webhook is used for.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :description
# Disable the webhook endpoint if set to true.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :disabled
# The list of events to enable for this endpoint. You may specify `['*']` to enable all events, except those that require explicit selection.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :enabled_events
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# The URL of the webhook endpoint.
sig { returns(T.nilable(String)) }
attr_accessor :url
sig {
params(description: T.nilable(T.nilable(String)), disabled: T.nilable(T::Boolean), enabled_events: T.nilable(T::Array[String]), expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), url: T.nilable(String)).void
}
def initialize(
description: nil,
disabled: nil,
enabled_events: nil,
expand: nil,
metadata: nil,
url: nil
); end
end
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
class CreateParams < Stripe::RequestParams
# Events sent to this endpoint will be generated with this Stripe Version instead of your account's default Stripe Version.
sig { returns(T.nilable(String)) }
attr_accessor :api_version
# Whether this endpoint should receive events from connected accounts (`true`), or from your account (`false`). Defaults to `false`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :connect
# An optional description of what the webhook is used for.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :description
# The list of events to enable for this endpoint. You may specify `['*']` to enable all events, except those that require explicit selection.
sig { returns(T::Array[String]) }
attr_accessor :enabled_events
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# The URL of the webhook endpoint.
sig { returns(String) }
attr_accessor :url
sig {
params(api_version: T.nilable(String), connect: T.nilable(T::Boolean), description: T.nilable(T.nilable(String)), enabled_events: T::Array[String], expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), url: String).void
}
def initialize(
api_version: nil,
connect: nil,
description: nil,
enabled_events: nil,
expand: nil,
metadata: nil,
url: nil
); end
end
# A webhook endpoint must have a url and a list of enabled_events. You may optionally specify the Boolean connect parameter. If set to true, then a Connect webhook endpoint that notifies the specified url about events from all connected accounts is created; otherwise an account webhook endpoint that notifies the specified url only about events from your account is created. You can also create webhook endpoints in the [webhooks settings](https://dashboard.stripe.com/account/webhooks) section of the Dashboard.
sig {
params(params: T.any(::Stripe::WebhookEndpoint::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::WebhookEndpoint)
}
def self.create(params = {}, opts = {}); end
# You can also delete webhook endpoints via the [webhook endpoint management](https://dashboard.stripe.com/account/webhooks) page of the Stripe dashboard.
sig {
params(webhook_endpoint: String, params: T.any(::Stripe::WebhookEndpoint::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::WebhookEndpoint)
}
def self.delete(webhook_endpoint, params = {}, opts = {}); end
# You can also delete webhook endpoints via the [webhook endpoint management](https://dashboard.stripe.com/account/webhooks) page of the Stripe dashboard.
sig {
params(params: T.any(::Stripe::WebhookEndpoint::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::WebhookEndpoint)
}
def delete(params = {}, opts = {}); end
# Returns a list of your webhook endpoints.
sig {
params(params: T.any(::Stripe::WebhookEndpoint::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def self.list(params = {}, opts = {}); end
# Updates the webhook endpoint. You may edit the url, the list of enabled_events, and the status of your endpoint.
sig {
params(webhook_endpoint: String, params: T.any(::Stripe::WebhookEndpoint::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::WebhookEndpoint)
}
def self.update(webhook_endpoint, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class V1Services < StripeService
attr_reader :accounts
attr_reader :account_links
attr_reader :account_notices
attr_reader :account_sessions
attr_reader :apple_pay_domains
attr_reader :application_fees
attr_reader :apps
attr_reader :balance
attr_reader :balance_settings
attr_reader :balance_transactions
attr_reader :billing
attr_reader :billing_portal
attr_reader :capital
attr_reader :charges
attr_reader :checkout
attr_reader :climate
attr_reader :confirmation_tokens
attr_reader :test_helpers
attr_reader :country_specs
attr_reader :coupons
attr_reader :credit_notes
attr_reader :customers
attr_reader :customer_sessions
attr_reader :disputes
attr_reader :entitlements
attr_reader :ephemeral_keys
attr_reader :events
attr_reader :exchange_rates
attr_reader :files
attr_reader :file_links
attr_reader :financial_connections
attr_reader :forwarding
attr_reader :fx_quotes
attr_reader :identity
attr_reader :invoices
attr_reader :invoice_rendering_templates
attr_reader :invoice_items
attr_reader :issuing
attr_reader :mandates
attr_reader :margins
attr_reader :orders
attr_reader :payment_attempt_records
attr_reader :payment_intents
attr_reader :payment_links
attr_reader :payment_methods
attr_reader :payment_method_configurations
attr_reader :payment_method_domains
attr_reader :payment_records
attr_reader :payouts
attr_reader :plans
attr_reader :prices
attr_reader :privacy
attr_reader :products
attr_reader :promotion_codes
attr_reader :quotes
attr_reader :radar
attr_reader :refunds
attr_reader :reporting
attr_reader :reviews
attr_reader :sigma
attr_reader :setup_attempts
attr_reader :setup_intents
attr_reader :shipping_rates
attr_reader :sources
attr_reader :subscriptions
attr_reader :subscription_items
attr_reader :subscription_schedules
attr_reader :tax
attr_reader :tax_codes
attr_reader :tax_ids
attr_reader :tax_rates
attr_reader :terminal
attr_reader :tokens
attr_reader :topups
attr_reader :transfers
attr_reader :treasury
attr_reader :webhook_endpoints
attr_reader :external_accounts
end
end
# typed: true
module Stripe
class AccountService < StripeService
attr_reader :capabilities
attr_reader :external_accounts
attr_reader :login_links
attr_reader :persons
class DeleteParams < Stripe::RequestParams; end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
class BankAccount < Stripe::RequestParams
# Attribute for param field object
sig { returns(String) }
attr_accessor :object
# The name of the person or business that owns the bank account.This field is required when attaching the bank account to a `Customer` object.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_name
# The type of entity that holds the account. It can be `company` or `individual`. This field is required when attaching the bank account to a `Customer` object.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_type
# The account number for the bank account, in string form. Must be a checking account.
sig { returns(String) }
attr_accessor :account_number
# The country in which the bank account is located.
sig { returns(String) }
attr_accessor :country
# The currency the bank account is in. This must be a country/currency pairing that [Stripe supports.](docs/payouts)
sig { returns(T.nilable(String)) }
attr_accessor :currency
# The routing number, sort code, or other country-appropriate institution number for the bank account. For US bank accounts, this is required and should be the ACH routing number, not the wire routing number. If you are providing an IBAN for `account_number`, this field is not required.
sig { returns(T.nilable(String)) }
attr_accessor :routing_number
sig {
params(object: String, account_holder_name: T.nilable(String), account_holder_type: T.nilable(String), account_number: String, country: String, currency: T.nilable(String), routing_number: T.nilable(String)).void
}
def initialize(
object: nil,
account_holder_name: nil,
account_holder_type: nil,
account_number: nil,
country: nil,
currency: nil,
routing_number: nil
); end
end
class BusinessProfile < Stripe::RequestParams
class AnnualRevenue < Stripe::RequestParams
# A non-negative integer representing the amount in the [smallest currency unit](/currencies#zero-decimal).
sig { returns(Integer) }
attr_accessor :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).
sig { returns(String) }
attr_accessor :currency
# The close-out date of the preceding fiscal year in ISO 8601 format. E.g. 2023-12-31 for the 31st of December, 2023.
sig { returns(String) }
attr_accessor :fiscal_year_end
sig { params(amount: Integer, currency: String, fiscal_year_end: String).void }
def initialize(amount: nil, currency: nil, fiscal_year_end: nil); end
end
class MonthlyEstimatedRevenue < Stripe::RequestParams
# A non-negative integer representing how much to charge in the [smallest currency unit](/currencies#zero-decimal).
sig { returns(Integer) }
attr_accessor :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).
sig { returns(String) }
attr_accessor :currency
sig { params(amount: Integer, currency: String).void }
def initialize(amount: nil, currency: nil); end
end
class SupportAddress < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# The applicant's gross annual revenue for its preceding fiscal year.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::BusinessProfile::AnnualRevenue))
}
attr_accessor :annual_revenue
# An estimated upper bound of employees, contractors, vendors, etc. currently working for the business.
sig { returns(T.nilable(Integer)) }
attr_accessor :estimated_worker_count
# [The merchant category code for the account](/connect/setting-mcc). MCCs are used to classify businesses based on the goods or services they provide.
sig { returns(T.nilable(String)) }
attr_accessor :mcc
# Whether the business is a minority-owned, women-owned, and/or LGBTQI+-owned business.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :minority_owned_business_designation
# An estimate of the monthly revenue of the business. Only accepted for accounts in Brazil and India.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::BusinessProfile::MonthlyEstimatedRevenue))
}
attr_accessor :monthly_estimated_revenue
# The customer-facing business name.
sig { returns(T.nilable(String)) }
attr_accessor :name
# Internal-only description of the product sold by, or service provided by, the business. Used by Stripe for risk and underwriting purposes.
sig { returns(T.nilable(String)) }
attr_accessor :product_description
# A publicly available mailing address for sending support issues to.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::BusinessProfile::SupportAddress))
}
attr_accessor :support_address
# A publicly available email address for sending support issues to.
sig { returns(T.nilable(String)) }
attr_accessor :support_email
# A publicly available phone number to call with support issues.
sig { returns(T.nilable(String)) }
attr_accessor :support_phone
# A publicly available website for handling support issues.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :support_url
# The business's publicly available website.
sig { returns(T.nilable(String)) }
attr_accessor :url
sig {
params(annual_revenue: T.nilable(::Stripe::AccountService::UpdateParams::BusinessProfile::AnnualRevenue), estimated_worker_count: T.nilable(Integer), mcc: T.nilable(String), minority_owned_business_designation: T.nilable(T::Array[String]), monthly_estimated_revenue: T.nilable(::Stripe::AccountService::UpdateParams::BusinessProfile::MonthlyEstimatedRevenue), name: T.nilable(String), product_description: T.nilable(String), support_address: T.nilable(::Stripe::AccountService::UpdateParams::BusinessProfile::SupportAddress), support_email: T.nilable(String), support_phone: T.nilable(String), support_url: T.nilable(T.nilable(String)), url: T.nilable(String)).void
}
def initialize(
annual_revenue: nil,
estimated_worker_count: nil,
mcc: nil,
minority_owned_business_designation: nil,
monthly_estimated_revenue: nil,
name: nil,
product_description: nil,
support_address: nil,
support_email: nil,
support_phone: nil,
support_url: nil,
url: nil
); end
end
class Capabilities < Stripe::RequestParams
class AcssDebitPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class AffirmPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class AfterpayClearpayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class AlmaPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class AmazonPayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class AuBecsDebitPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class AutomaticIndirectTax < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class BacsDebitPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class BancontactPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class BankTransferPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class BilliePayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class BlikPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class BoletoPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class CardIssuing < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class CardPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class CartesBancairesPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class CashappPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class EpsPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class FpxPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class GbBankTransferPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class GiropayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class GopayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class GrabpayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class IdBankTransferPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class IdBankTransferPaymentsBca < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class IdealPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class IndiaInternationalPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class JcbPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class JpBankTransferPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class KakaoPayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class KlarnaPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class KonbiniPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class KrCardPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class LegacyPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class LinkPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class MbWayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class MobilepayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class MultibancoPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class MxBankTransferPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class NaverPayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class NzBankAccountBecsDebitPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class OxxoPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class P24Payments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class PayByBankPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class PaycoPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class PaynowPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class PaypalPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class PaytoPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class PixPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class PromptpayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class QrisPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class RechnungPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class RevolutPayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class SamsungPayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class SatispayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class SepaBankTransferPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class SepaDebitPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class ShopeepayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class SofortPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class StripeBalancePayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class SwishPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class TaxReportingUs1099K < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class TaxReportingUs1099Misc < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class Transfers < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class Treasury < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class TreasuryEvolve < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class TreasuryFifthThird < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class TreasuryGoldmanSachs < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class TwintPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class UsBankAccountAchPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class UsBankTransferPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class ZipPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
# The acss_debit_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::AcssDebitPayments))
}
attr_accessor :acss_debit_payments
# The affirm_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::AffirmPayments))
}
attr_accessor :affirm_payments
# The afterpay_clearpay_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::AfterpayClearpayPayments))
}
attr_accessor :afterpay_clearpay_payments
# The alma_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::AlmaPayments))
}
attr_accessor :alma_payments
# The amazon_pay_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::AmazonPayPayments))
}
attr_accessor :amazon_pay_payments
# The au_becs_debit_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::AuBecsDebitPayments))
}
attr_accessor :au_becs_debit_payments
# The automatic_indirect_tax capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::AutomaticIndirectTax))
}
attr_accessor :automatic_indirect_tax
# The bacs_debit_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::BacsDebitPayments))
}
attr_accessor :bacs_debit_payments
# The bancontact_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::BancontactPayments))
}
attr_accessor :bancontact_payments
# The bank_transfer_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::BankTransferPayments))
}
attr_accessor :bank_transfer_payments
# The billie_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::BilliePayments))
}
attr_accessor :billie_payments
# The blik_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::BlikPayments))
}
attr_accessor :blik_payments
# The boleto_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::BoletoPayments))
}
attr_accessor :boleto_payments
# The card_issuing capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::CardIssuing))
}
attr_accessor :card_issuing
# The card_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::CardPayments))
}
attr_accessor :card_payments
# The cartes_bancaires_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::CartesBancairesPayments))
}
attr_accessor :cartes_bancaires_payments
# The cashapp_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::CashappPayments))
}
attr_accessor :cashapp_payments
# The eps_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::EpsPayments))
}
attr_accessor :eps_payments
# The fpx_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::FpxPayments))
}
attr_accessor :fpx_payments
# The gb_bank_transfer_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::GbBankTransferPayments))
}
attr_accessor :gb_bank_transfer_payments
# The giropay_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::GiropayPayments))
}
attr_accessor :giropay_payments
# The gopay_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::GopayPayments))
}
attr_accessor :gopay_payments
# The grabpay_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::GrabpayPayments))
}
attr_accessor :grabpay_payments
# The id_bank_transfer_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::IdBankTransferPayments))
}
attr_accessor :id_bank_transfer_payments
# The id_bank_transfer_payments_bca capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::IdBankTransferPaymentsBca))
}
attr_accessor :id_bank_transfer_payments_bca
# The ideal_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::IdealPayments))
}
attr_accessor :ideal_payments
# The india_international_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::IndiaInternationalPayments))
}
attr_accessor :india_international_payments
# The jcb_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::JcbPayments))
}
attr_accessor :jcb_payments
# The jp_bank_transfer_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::JpBankTransferPayments))
}
attr_accessor :jp_bank_transfer_payments
# The kakao_pay_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::KakaoPayPayments))
}
attr_accessor :kakao_pay_payments
# The klarna_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::KlarnaPayments))
}
attr_accessor :klarna_payments
# The konbini_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::KonbiniPayments))
}
attr_accessor :konbini_payments
# The kr_card_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::KrCardPayments))
}
attr_accessor :kr_card_payments
# The legacy_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::LegacyPayments))
}
attr_accessor :legacy_payments
# The link_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::LinkPayments))
}
attr_accessor :link_payments
# The mb_way_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::MbWayPayments))
}
attr_accessor :mb_way_payments
# The mobilepay_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::MobilepayPayments))
}
attr_accessor :mobilepay_payments
# The multibanco_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::MultibancoPayments))
}
attr_accessor :multibanco_payments
# The mx_bank_transfer_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::MxBankTransferPayments))
}
attr_accessor :mx_bank_transfer_payments
# The naver_pay_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::NaverPayPayments))
}
attr_accessor :naver_pay_payments
# The nz_bank_account_becs_debit_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::NzBankAccountBecsDebitPayments))
}
attr_accessor :nz_bank_account_becs_debit_payments
# The oxxo_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::OxxoPayments))
}
attr_accessor :oxxo_payments
# The p24_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::P24Payments))
}
attr_accessor :p24_payments
# The pay_by_bank_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::PayByBankPayments))
}
attr_accessor :pay_by_bank_payments
# The payco_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::PaycoPayments))
}
attr_accessor :payco_payments
# The paynow_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::PaynowPayments))
}
attr_accessor :paynow_payments
# The paypal_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::PaypalPayments))
}
attr_accessor :paypal_payments
# The payto_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::PaytoPayments))
}
attr_accessor :payto_payments
# The pix_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::PixPayments))
}
attr_accessor :pix_payments
# The promptpay_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::PromptpayPayments))
}
attr_accessor :promptpay_payments
# The qris_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::QrisPayments))
}
attr_accessor :qris_payments
# The rechnung_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::RechnungPayments))
}
attr_accessor :rechnung_payments
# The revolut_pay_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::RevolutPayPayments))
}
attr_accessor :revolut_pay_payments
# The samsung_pay_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::SamsungPayPayments))
}
attr_accessor :samsung_pay_payments
# The satispay_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::SatispayPayments))
}
attr_accessor :satispay_payments
# The sepa_bank_transfer_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::SepaBankTransferPayments))
}
attr_accessor :sepa_bank_transfer_payments
# The sepa_debit_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::SepaDebitPayments))
}
attr_accessor :sepa_debit_payments
# The shopeepay_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::ShopeepayPayments))
}
attr_accessor :shopeepay_payments
# The sofort_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::SofortPayments))
}
attr_accessor :sofort_payments
# The stripe_balance_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::StripeBalancePayments))
}
attr_accessor :stripe_balance_payments
# The swish_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::SwishPayments))
}
attr_accessor :swish_payments
# The tax_reporting_us_1099_k capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::TaxReportingUs1099K))
}
attr_accessor :tax_reporting_us_1099_k
# The tax_reporting_us_1099_misc capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::TaxReportingUs1099Misc))
}
attr_accessor :tax_reporting_us_1099_misc
# The transfers capability.
sig { returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::Transfers)) }
attr_accessor :transfers
# The treasury capability.
sig { returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::Treasury)) }
attr_accessor :treasury
# The treasury_evolve capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::TreasuryEvolve))
}
attr_accessor :treasury_evolve
# The treasury_fifth_third capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::TreasuryFifthThird))
}
attr_accessor :treasury_fifth_third
# The treasury_goldman_sachs capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::TreasuryGoldmanSachs))
}
attr_accessor :treasury_goldman_sachs
# The twint_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::TwintPayments))
}
attr_accessor :twint_payments
# The us_bank_account_ach_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::UsBankAccountAchPayments))
}
attr_accessor :us_bank_account_ach_payments
# The us_bank_transfer_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::UsBankTransferPayments))
}
attr_accessor :us_bank_transfer_payments
# The zip_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::ZipPayments))
}
attr_accessor :zip_payments
sig {
params(acss_debit_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::AcssDebitPayments), affirm_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::AffirmPayments), afterpay_clearpay_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::AfterpayClearpayPayments), alma_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::AlmaPayments), amazon_pay_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::AmazonPayPayments), au_becs_debit_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::AuBecsDebitPayments), automatic_indirect_tax: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::AutomaticIndirectTax), bacs_debit_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::BacsDebitPayments), bancontact_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::BancontactPayments), bank_transfer_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::BankTransferPayments), billie_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::BilliePayments), blik_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::BlikPayments), boleto_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::BoletoPayments), card_issuing: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::CardIssuing), card_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::CardPayments), cartes_bancaires_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::CartesBancairesPayments), cashapp_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::CashappPayments), eps_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::EpsPayments), fpx_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::FpxPayments), gb_bank_transfer_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::GbBankTransferPayments), giropay_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::GiropayPayments), gopay_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::GopayPayments), grabpay_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::GrabpayPayments), id_bank_transfer_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::IdBankTransferPayments), id_bank_transfer_payments_bca: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::IdBankTransferPaymentsBca), ideal_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::IdealPayments), india_international_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::IndiaInternationalPayments), jcb_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::JcbPayments), jp_bank_transfer_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::JpBankTransferPayments), kakao_pay_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::KakaoPayPayments), klarna_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::KlarnaPayments), konbini_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::KonbiniPayments), kr_card_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::KrCardPayments), legacy_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::LegacyPayments), link_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::LinkPayments), mb_way_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::MbWayPayments), mobilepay_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::MobilepayPayments), multibanco_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::MultibancoPayments), mx_bank_transfer_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::MxBankTransferPayments), naver_pay_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::NaverPayPayments), nz_bank_account_becs_debit_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::NzBankAccountBecsDebitPayments), oxxo_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::OxxoPayments), p24_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::P24Payments), pay_by_bank_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::PayByBankPayments), payco_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::PaycoPayments), paynow_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::PaynowPayments), paypal_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::PaypalPayments), payto_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::PaytoPayments), pix_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::PixPayments), promptpay_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::PromptpayPayments), qris_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::QrisPayments), rechnung_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::RechnungPayments), revolut_pay_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::RevolutPayPayments), samsung_pay_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::SamsungPayPayments), satispay_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::SatispayPayments), sepa_bank_transfer_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::SepaBankTransferPayments), sepa_debit_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::SepaDebitPayments), shopeepay_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::ShopeepayPayments), sofort_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::SofortPayments), stripe_balance_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::StripeBalancePayments), swish_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::SwishPayments), tax_reporting_us_1099_k: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::TaxReportingUs1099K), tax_reporting_us_1099_misc: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::TaxReportingUs1099Misc), transfers: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::Transfers), treasury: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::Treasury), treasury_evolve: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::TreasuryEvolve), treasury_fifth_third: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::TreasuryFifthThird), treasury_goldman_sachs: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::TreasuryGoldmanSachs), twint_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::TwintPayments), us_bank_account_ach_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::UsBankAccountAchPayments), us_bank_transfer_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::UsBankTransferPayments), zip_payments: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities::ZipPayments)).void
}
def initialize(
acss_debit_payments: nil,
affirm_payments: nil,
afterpay_clearpay_payments: nil,
alma_payments: nil,
amazon_pay_payments: nil,
au_becs_debit_payments: nil,
automatic_indirect_tax: nil,
bacs_debit_payments: nil,
bancontact_payments: nil,
bank_transfer_payments: nil,
billie_payments: nil,
blik_payments: nil,
boleto_payments: nil,
card_issuing: nil,
card_payments: nil,
cartes_bancaires_payments: nil,
cashapp_payments: nil,
eps_payments: nil,
fpx_payments: nil,
gb_bank_transfer_payments: nil,
giropay_payments: nil,
gopay_payments: nil,
grabpay_payments: nil,
id_bank_transfer_payments: nil,
id_bank_transfer_payments_bca: nil,
ideal_payments: nil,
india_international_payments: nil,
jcb_payments: nil,
jp_bank_transfer_payments: nil,
kakao_pay_payments: nil,
klarna_payments: nil,
konbini_payments: nil,
kr_card_payments: nil,
legacy_payments: nil,
link_payments: nil,
mb_way_payments: nil,
mobilepay_payments: nil,
multibanco_payments: nil,
mx_bank_transfer_payments: nil,
naver_pay_payments: nil,
nz_bank_account_becs_debit_payments: nil,
oxxo_payments: nil,
p24_payments: nil,
pay_by_bank_payments: nil,
payco_payments: nil,
paynow_payments: nil,
paypal_payments: nil,
payto_payments: nil,
pix_payments: nil,
promptpay_payments: nil,
qris_payments: nil,
rechnung_payments: nil,
revolut_pay_payments: nil,
samsung_pay_payments: nil,
satispay_payments: nil,
sepa_bank_transfer_payments: nil,
sepa_debit_payments: nil,
shopeepay_payments: nil,
sofort_payments: nil,
stripe_balance_payments: nil,
swish_payments: nil,
tax_reporting_us_1099_k: nil,
tax_reporting_us_1099_misc: nil,
transfers: nil,
treasury: nil,
treasury_evolve: nil,
treasury_fifth_third: nil,
treasury_goldman_sachs: nil,
twint_payments: nil,
us_bank_account_ach_payments: nil,
us_bank_transfer_payments: nil,
zip_payments: nil
); end
end
class Card < Stripe::RequestParams
# Attribute for param field object
sig { returns(String) }
attr_accessor :object
# Attribute for param field address_city
sig { returns(T.nilable(String)) }
attr_accessor :address_city
# Attribute for param field address_country
sig { returns(T.nilable(String)) }
attr_accessor :address_country
# Attribute for param field address_line1
sig { returns(T.nilable(String)) }
attr_accessor :address_line1
# Attribute for param field address_line2
sig { returns(T.nilable(String)) }
attr_accessor :address_line2
# Attribute for param field address_state
sig { returns(T.nilable(String)) }
attr_accessor :address_state
# Attribute for param field address_zip
sig { returns(T.nilable(String)) }
attr_accessor :address_zip
# Attribute for param field currency
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Attribute for param field cvc
sig { returns(T.nilable(String)) }
attr_accessor :cvc
# Attribute for param field exp_month
sig { returns(Integer) }
attr_accessor :exp_month
# Attribute for param field exp_year
sig { returns(Integer) }
attr_accessor :exp_year
# Attribute for param field name
sig { returns(T.nilable(String)) }
attr_accessor :name
# Attribute for param field number
sig { returns(String) }
attr_accessor :number
# 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.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Attribute for param field default_for_currency
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :default_for_currency
sig {
params(object: String, address_city: T.nilable(String), address_country: T.nilable(String), address_line1: T.nilable(String), address_line2: T.nilable(String), address_state: T.nilable(String), address_zip: T.nilable(String), currency: T.nilable(String), cvc: T.nilable(String), exp_month: Integer, exp_year: Integer, name: T.nilable(String), number: String, metadata: T.nilable(T::Hash[String, String]), default_for_currency: T.nilable(T::Boolean)).void
}
def initialize(
object: nil,
address_city: nil,
address_country: nil,
address_line1: nil,
address_line2: nil,
address_state: nil,
address_zip: nil,
currency: nil,
cvc: nil,
exp_month: nil,
exp_year: nil,
name: nil,
number: nil,
metadata: nil,
default_for_currency: nil
); end
end
class CardToken < Stripe::RequestParams
# Attribute for param field object
sig { returns(String) }
attr_accessor :object
# Attribute for param field currency
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Attribute for param field token
sig { returns(String) }
attr_accessor :token
sig { params(object: String, currency: T.nilable(String), token: String).void }
def initialize(object: nil, currency: nil, token: nil); end
end
class Company < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class AddressKana < Stripe::RequestParams
# City or ward.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Block or building number.
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Building details.
sig { returns(T.nilable(String)) }
attr_accessor :line2
# Postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# Prefecture.
sig { returns(T.nilable(String)) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_accessor :town
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), town: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
class AddressKanji < Stripe::RequestParams
# City or ward.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Block or building number.
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Building details.
sig { returns(T.nilable(String)) }
attr_accessor :line2
# Postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# Prefecture.
sig { returns(T.nilable(String)) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_accessor :town
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), town: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
class DirectorshipDeclaration < Stripe::RequestParams
# The Unix timestamp marking when the directorship declaration attestation was made.
sig { returns(T.nilable(Integer)) }
attr_accessor :date
# The IP address from which the directorship declaration attestation was made.
sig { returns(T.nilable(String)) }
attr_accessor :ip
# The user agent of the browser from which the directorship declaration attestation was made.
sig { returns(T.nilable(String)) }
attr_accessor :user_agent
sig {
params(date: T.nilable(Integer), ip: T.nilable(String), user_agent: T.nilable(String)).void
}
def initialize(date: nil, ip: nil, user_agent: nil); end
end
class OwnershipDeclaration < Stripe::RequestParams
# The Unix timestamp marking when the beneficial owner attestation was made.
sig { returns(T.nilable(Integer)) }
attr_accessor :date
# The IP address from which the beneficial owner attestation was made.
sig { returns(T.nilable(String)) }
attr_accessor :ip
# The user agent of the browser from which the beneficial owner attestation was made.
sig { returns(T.nilable(String)) }
attr_accessor :user_agent
sig {
params(date: T.nilable(Integer), ip: T.nilable(String), user_agent: T.nilable(String)).void
}
def initialize(date: nil, ip: nil, user_agent: nil); end
end
class RegistrationDate < Stripe::RequestParams
# The day of registration, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of registration, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of registration.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
class Verification < Stripe::RequestParams
class Document < Stripe::RequestParams
# The back of a document returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `additional_verification`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :back
# The front of a document returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `additional_verification`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :front
sig { params(back: T.nilable(String), front: T.nilable(String)).void }
def initialize(back: nil, front: nil); end
end
# A document verifying the business.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Company::Verification::Document))
}
attr_accessor :document
sig {
params(document: T.nilable(::Stripe::AccountService::UpdateParams::Company::Verification::Document)).void
}
def initialize(document: nil); end
end
# The company's primary address.
sig { returns(T.nilable(::Stripe::AccountService::UpdateParams::Company::Address)) }
attr_accessor :address
# The Kana variation of the company's primary address (Japan only).
sig { returns(T.nilable(::Stripe::AccountService::UpdateParams::Company::AddressKana)) }
attr_accessor :address_kana
# The Kanji variation of the company's primary address (Japan only).
sig { returns(T.nilable(::Stripe::AccountService::UpdateParams::Company::AddressKanji)) }
attr_accessor :address_kanji
# Whether the company's directors have been provided. Set this Boolean to `true` after creating all the company's directors with [the Persons API](/api/persons) for accounts with a `relationship.director` requirement. This value is not automatically set to `true` after creating directors, so it needs to be updated to indicate all directors have been provided.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :directors_provided
# This hash is used to attest that the directors information provided to Stripe is both current and correct.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Company::DirectorshipDeclaration))
}
attr_accessor :directorship_declaration
# Whether the company's executives have been provided. Set this Boolean to `true` after creating all the company's executives with [the Persons API](/api/persons) for accounts with a `relationship.executive` requirement.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :executives_provided
# The export license ID number of the company, also referred as Import Export Code (India only).
sig { returns(T.nilable(String)) }
attr_accessor :export_license_id
# The purpose code to use for export transactions (India only).
sig { returns(T.nilable(String)) }
attr_accessor :export_purpose_code
# The company's legal name.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The Kana variation of the company's legal name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :name_kana
# The Kanji variation of the company's legal name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :name_kanji
# Whether the company's owners have been provided. Set this Boolean to `true` after creating all the company's owners with [the Persons API](/api/persons) for accounts with a `relationship.owner` requirement.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :owners_provided
# This hash is used to attest that the beneficial owner information provided to Stripe is both current and correct.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Company::OwnershipDeclaration))
}
attr_accessor :ownership_declaration
# This value is used to determine if a business is exempt from providing ultimate beneficial owners. See [this support article](https://support.stripe.com/questions/exemption-from-providing-ownership-details) and [changelog](https://docs.stripe.com/changelog/acacia/2025-01-27/ownership-exemption-reason-accounts-api) for more details.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :ownership_exemption_reason
# The company's phone number (used for verification).
sig { returns(T.nilable(String)) }
attr_accessor :phone
# Attribute for param field registration_date
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::AccountService::UpdateParams::Company::RegistrationDate))))
}
attr_accessor :registration_date
# The identification number given to a company when it is registered or incorporated, if distinct from the identification number used for filing taxes. (Examples are the CIN for companies and LLP IN for partnerships in India, and the Company Registration Number in Hong Kong).
sig { returns(T.nilable(String)) }
attr_accessor :registration_number
# The category identifying the legal structure of the company or legal entity. See [Business structure](/connect/identity-verification#business-structure) for more details. Pass an empty string to unset this value.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :structure
# The business ID number of the company, as appropriate for the company’s country. (Examples are an Employer ID Number in the U.S., a Business Number in Canada, or a Company Number in the UK.)
sig { returns(T.nilable(String)) }
attr_accessor :tax_id
# The jurisdiction in which the `tax_id` is registered (Germany-based companies only).
sig { returns(T.nilable(String)) }
attr_accessor :tax_id_registrar
# The VAT number of the company.
sig { returns(T.nilable(String)) }
attr_accessor :vat_id
# Information on the verification state of the company.
sig { returns(T.nilable(::Stripe::AccountService::UpdateParams::Company::Verification)) }
attr_accessor :verification
sig {
params(address: T.nilable(::Stripe::AccountService::UpdateParams::Company::Address), address_kana: T.nilable(::Stripe::AccountService::UpdateParams::Company::AddressKana), address_kanji: T.nilable(::Stripe::AccountService::UpdateParams::Company::AddressKanji), directors_provided: T.nilable(T::Boolean), directorship_declaration: T.nilable(::Stripe::AccountService::UpdateParams::Company::DirectorshipDeclaration), executives_provided: T.nilable(T::Boolean), export_license_id: T.nilable(String), export_purpose_code: T.nilable(String), name: T.nilable(String), name_kana: T.nilable(String), name_kanji: T.nilable(String), owners_provided: T.nilable(T::Boolean), ownership_declaration: T.nilable(::Stripe::AccountService::UpdateParams::Company::OwnershipDeclaration), ownership_exemption_reason: T.nilable(T.nilable(T.any(String, String))), phone: T.nilable(String), registration_date: T.nilable(T.nilable(T.any(String, ::Stripe::AccountService::UpdateParams::Company::RegistrationDate))), registration_number: T.nilable(String), structure: T.nilable(T.nilable(T.any(String, String))), tax_id: T.nilable(String), tax_id_registrar: T.nilable(String), vat_id: T.nilable(String), verification: T.nilable(::Stripe::AccountService::UpdateParams::Company::Verification)).void
}
def initialize(
address: nil,
address_kana: nil,
address_kanji: nil,
directors_provided: nil,
directorship_declaration: nil,
executives_provided: nil,
export_license_id: nil,
export_purpose_code: nil,
name: nil,
name_kana: nil,
name_kanji: nil,
owners_provided: nil,
ownership_declaration: nil,
ownership_exemption_reason: nil,
phone: nil,
registration_date: nil,
registration_number: nil,
structure: nil,
tax_id: nil,
tax_id_registrar: nil,
vat_id: nil,
verification: nil
); end
end
class Documents < Stripe::RequestParams
class BankAccountOwnershipVerification < Stripe::RequestParams
# One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :files
sig { params(files: T.nilable(T::Array[String])).void }
def initialize(files: nil); end
end
class CompanyLicense < Stripe::RequestParams
# One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :files
sig { params(files: T.nilable(T::Array[String])).void }
def initialize(files: nil); end
end
class CompanyMemorandumOfAssociation < Stripe::RequestParams
# One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :files
sig { params(files: T.nilable(T::Array[String])).void }
def initialize(files: nil); end
end
class CompanyMinisterialDecree < Stripe::RequestParams
# One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :files
sig { params(files: T.nilable(T::Array[String])).void }
def initialize(files: nil); end
end
class CompanyRegistrationVerification < Stripe::RequestParams
# One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :files
sig { params(files: T.nilable(T::Array[String])).void }
def initialize(files: nil); end
end
class CompanyTaxIdVerification < Stripe::RequestParams
# One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :files
sig { params(files: T.nilable(T::Array[String])).void }
def initialize(files: nil); end
end
class ProofOfRegistration < Stripe::RequestParams
# One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :files
sig { params(files: T.nilable(T::Array[String])).void }
def initialize(files: nil); end
end
class ProofOfUltimateBeneficialOwnership < Stripe::RequestParams
# One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :files
sig { params(files: T.nilable(T::Array[String])).void }
def initialize(files: nil); end
end
# One or more documents that support the [Bank account ownership verification](https://support.stripe.com/questions/bank-account-ownership-verification) requirement. Must be a document associated with the account’s primary active bank account that displays the last 4 digits of the account number, either a statement or a check.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Documents::BankAccountOwnershipVerification))
}
attr_accessor :bank_account_ownership_verification
# One or more documents that demonstrate proof of a company's license to operate.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Documents::CompanyLicense))
}
attr_accessor :company_license
# One or more documents showing the company's Memorandum of Association.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Documents::CompanyMemorandumOfAssociation))
}
attr_accessor :company_memorandum_of_association
# (Certain countries only) One or more documents showing the ministerial decree legalizing the company's establishment.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Documents::CompanyMinisterialDecree))
}
attr_accessor :company_ministerial_decree
# One or more documents that demonstrate proof of a company's registration with the appropriate local authorities.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Documents::CompanyRegistrationVerification))
}
attr_accessor :company_registration_verification
# One or more documents that demonstrate proof of a company's tax ID.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Documents::CompanyTaxIdVerification))
}
attr_accessor :company_tax_id_verification
# One or more documents showing the company’s proof of registration with the national business registry.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Documents::ProofOfRegistration))
}
attr_accessor :proof_of_registration
# One or more documents that demonstrate proof of ultimate beneficial ownership.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Documents::ProofOfUltimateBeneficialOwnership))
}
attr_accessor :proof_of_ultimate_beneficial_ownership
sig {
params(bank_account_ownership_verification: T.nilable(::Stripe::AccountService::UpdateParams::Documents::BankAccountOwnershipVerification), company_license: T.nilable(::Stripe::AccountService::UpdateParams::Documents::CompanyLicense), company_memorandum_of_association: T.nilable(::Stripe::AccountService::UpdateParams::Documents::CompanyMemorandumOfAssociation), company_ministerial_decree: T.nilable(::Stripe::AccountService::UpdateParams::Documents::CompanyMinisterialDecree), company_registration_verification: T.nilable(::Stripe::AccountService::UpdateParams::Documents::CompanyRegistrationVerification), company_tax_id_verification: T.nilable(::Stripe::AccountService::UpdateParams::Documents::CompanyTaxIdVerification), proof_of_registration: T.nilable(::Stripe::AccountService::UpdateParams::Documents::ProofOfRegistration), proof_of_ultimate_beneficial_ownership: T.nilable(::Stripe::AccountService::UpdateParams::Documents::ProofOfUltimateBeneficialOwnership)).void
}
def initialize(
bank_account_ownership_verification: nil,
company_license: nil,
company_memorandum_of_association: nil,
company_ministerial_decree: nil,
company_registration_verification: nil,
company_tax_id_verification: nil,
proof_of_registration: nil,
proof_of_ultimate_beneficial_ownership: nil
); end
end
class Groups < Stripe::RequestParams
# The group the account is in to determine their payments pricing, and null if the account is on customized pricing. [See the Platform pricing tool documentation](https://stripe.com/docs/connect/platform-pricing-tools) for details.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :payments_pricing
sig { params(payments_pricing: T.nilable(T.nilable(String))).void }
def initialize(payments_pricing: nil); end
end
class Individual < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class AddressKana < Stripe::RequestParams
# City or ward.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Block or building number.
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Building details.
sig { returns(T.nilable(String)) }
attr_accessor :line2
# Postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# Prefecture.
sig { returns(T.nilable(String)) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_accessor :town
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), town: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
class AddressKanji < Stripe::RequestParams
# City or ward.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Block or building number.
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Building details.
sig { returns(T.nilable(String)) }
attr_accessor :line2
# Postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# Prefecture.
sig { returns(T.nilable(String)) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_accessor :town
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), town: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
class Dob < Stripe::RequestParams
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
class RegisteredAddress < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class Relationship < Stripe::RequestParams
# Whether the person is a director of the account's legal entity. Directors are typically members of the governing board of the company, or responsible for ensuring the company meets its regulatory obligations.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :director
# Whether the person has significant responsibility to control, manage, or direct the organization.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :executive
# Whether the person is an owner of the account’s legal entity.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :owner
# The percent owned by the person of the account's legal entity.
sig { returns(T.nilable(T.nilable(T.any(String, Float)))) }
attr_accessor :percent_ownership
# The person's title (e.g., CEO, Support Engineer).
sig { returns(T.nilable(String)) }
attr_accessor :title
sig {
params(director: T.nilable(T::Boolean), executive: T.nilable(T::Boolean), owner: T.nilable(T::Boolean), percent_ownership: T.nilable(T.nilable(T.any(String, Float))), title: T.nilable(String)).void
}
def initialize(
director: nil,
executive: nil,
owner: nil,
percent_ownership: nil,
title: nil
); end
end
class Verification < Stripe::RequestParams
class AdditionalDocument < Stripe::RequestParams
# The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :back
# The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :front
sig { params(back: T.nilable(String), front: T.nilable(String)).void }
def initialize(back: nil, front: nil); end
end
class Document < Stripe::RequestParams
# The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :back
# The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :front
sig { params(back: T.nilable(String), front: T.nilable(String)).void }
def initialize(back: nil, front: nil); end
end
# A document showing address, either a passport, local ID card, or utility bill from a well-known utility company.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Individual::Verification::AdditionalDocument))
}
attr_accessor :additional_document
# An identifying document, either a passport or local ID card.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Individual::Verification::Document))
}
attr_accessor :document
sig {
params(additional_document: T.nilable(::Stripe::AccountService::UpdateParams::Individual::Verification::AdditionalDocument), document: T.nilable(::Stripe::AccountService::UpdateParams::Individual::Verification::Document)).void
}
def initialize(additional_document: nil, document: nil); end
end
# The individual's primary address.
sig { returns(T.nilable(::Stripe::AccountService::UpdateParams::Individual::Address)) }
attr_accessor :address
# The Kana variation of the individual's primary address (Japan only).
sig { returns(T.nilable(::Stripe::AccountService::UpdateParams::Individual::AddressKana)) }
attr_accessor :address_kana
# The Kanji variation of the individual's primary address (Japan only).
sig { returns(T.nilable(::Stripe::AccountService::UpdateParams::Individual::AddressKanji)) }
attr_accessor :address_kanji
# The individual's date of birth.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::AccountService::UpdateParams::Individual::Dob))))
}
attr_accessor :dob
# The individual's email address.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The individual's first name.
sig { returns(T.nilable(String)) }
attr_accessor :first_name
# The Kana variation of the individual's first name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :first_name_kana
# The Kanji variation of the individual's first name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :first_name_kanji
# A list of alternate names or aliases that the individual is known by.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :full_name_aliases
# The individual's gender
sig { returns(T.nilable(String)) }
attr_accessor :gender
# The government-issued ID number of the individual, as appropriate for the representative's country. (Examples are a Social Security Number in the U.S., or a Social Insurance Number in Canada). Instead of the number itself, you can also provide a [PII token created with Stripe.js](/js/tokens/create_token?type=pii).
sig { returns(T.nilable(String)) }
attr_accessor :id_number
# The government-issued secondary ID number of the individual, as appropriate for the representative's country, will be used for enhanced verification checks. In Thailand, this would be the laser code found on the back of an ID card. Instead of the number itself, you can also provide a [PII token created with Stripe.js](/js/tokens/create_token?type=pii).
sig { returns(T.nilable(String)) }
attr_accessor :id_number_secondary
# The individual's last name.
sig { returns(T.nilable(String)) }
attr_accessor :last_name
# The Kana variation of the individual's last name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :last_name_kana
# The Kanji variation of the individual's last name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :last_name_kanji
# The individual's maiden name.
sig { returns(T.nilable(String)) }
attr_accessor :maiden_name
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# The individual's phone number.
sig { returns(T.nilable(String)) }
attr_accessor :phone
# Indicates if the person or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction.
sig { returns(T.nilable(String)) }
attr_accessor :political_exposure
# The individual's registered address.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Individual::RegisteredAddress))
}
attr_accessor :registered_address
# Describes the person’s relationship to the account.
sig { returns(T.nilable(::Stripe::AccountService::UpdateParams::Individual::Relationship)) }
attr_accessor :relationship
# The last four digits of the individual's Social Security Number (U.S. only).
sig { returns(T.nilable(String)) }
attr_accessor :ssn_last_4
# The individual's verification document information.
sig { returns(T.nilable(::Stripe::AccountService::UpdateParams::Individual::Verification)) }
attr_accessor :verification
sig {
params(address: T.nilable(::Stripe::AccountService::UpdateParams::Individual::Address), address_kana: T.nilable(::Stripe::AccountService::UpdateParams::Individual::AddressKana), address_kanji: T.nilable(::Stripe::AccountService::UpdateParams::Individual::AddressKanji), dob: T.nilable(T.nilable(T.any(String, ::Stripe::AccountService::UpdateParams::Individual::Dob))), email: T.nilable(String), first_name: T.nilable(String), first_name_kana: T.nilable(String), first_name_kanji: T.nilable(String), full_name_aliases: T.nilable(T.nilable(T.any(String, T::Array[String]))), gender: T.nilable(String), id_number: T.nilable(String), id_number_secondary: T.nilable(String), last_name: T.nilable(String), last_name_kana: T.nilable(String), last_name_kanji: T.nilable(String), maiden_name: T.nilable(String), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), phone: T.nilable(String), political_exposure: T.nilable(String), registered_address: T.nilable(::Stripe::AccountService::UpdateParams::Individual::RegisteredAddress), relationship: T.nilable(::Stripe::AccountService::UpdateParams::Individual::Relationship), ssn_last_4: T.nilable(String), verification: T.nilable(::Stripe::AccountService::UpdateParams::Individual::Verification)).void
}
def initialize(
address: nil,
address_kana: nil,
address_kanji: nil,
dob: nil,
email: nil,
first_name: nil,
first_name_kana: nil,
first_name_kanji: nil,
full_name_aliases: nil,
gender: nil,
id_number: nil,
id_number_secondary: nil,
last_name: nil,
last_name_kana: nil,
last_name_kanji: nil,
maiden_name: nil,
metadata: nil,
phone: nil,
political_exposure: nil,
registered_address: nil,
relationship: nil,
ssn_last_4: nil,
verification: nil
); end
end
class RiskControls < Stripe::RequestParams
class Charges < Stripe::RequestParams
# To request to pause a risk control, pass `true`. To request to unpause a risk control, pass `false`.
# There can be a delay before the risk control is paused or unpaused.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :pause_requested
sig { params(pause_requested: T.nilable(T::Boolean)).void }
def initialize(pause_requested: nil); end
end
class Payouts < Stripe::RequestParams
# To request to pause a risk control, pass `true`. To request to unpause a risk control, pass `false`.
# There can be a delay before the risk control is paused or unpaused.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :pause_requested
sig { params(pause_requested: T.nilable(T::Boolean)).void }
def initialize(pause_requested: nil); end
end
# Represents the risk control status of charges. Please see [this page for more details](https://stripe.com/docs/connect/pausing-payments-or-payouts-on-connected-accounts).
sig { returns(T.nilable(::Stripe::AccountService::UpdateParams::RiskControls::Charges)) }
attr_accessor :charges
# Represents the risk control status of payouts. Please see [this page for more details](https://stripe.com/docs/connect/pausing-payments-or-payouts-on-connected-accounts).
sig { returns(T.nilable(::Stripe::AccountService::UpdateParams::RiskControls::Payouts)) }
attr_accessor :payouts
sig {
params(charges: T.nilable(::Stripe::AccountService::UpdateParams::RiskControls::Charges), payouts: T.nilable(::Stripe::AccountService::UpdateParams::RiskControls::Payouts)).void
}
def initialize(charges: nil, payouts: nil); end
end
class Settings < Stripe::RequestParams
class BacsDebitPayments < Stripe::RequestParams
# The Bacs Direct Debit Display Name for this account. For payments made with Bacs Direct Debit, this name appears on the mandate as the statement descriptor. Mobile banking apps display it as the name of the business. To use custom branding, set the Bacs Direct Debit Display Name during or right after creation. Custom branding incurs an additional monthly fee for the platform. If you don't set the display name before requesting Bacs capability, it's automatically set as "Stripe" and the account is onboarded to Stripe branding, which is free.
sig { returns(T.nilable(String)) }
attr_accessor :display_name
sig { params(display_name: T.nilable(String)).void }
def initialize(display_name: nil); end
end
class BankBcaOnboarding < Stripe::RequestParams
# Bank BCA business account holder name
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_name
# Bank BCA business account number
sig { returns(T.nilable(String)) }
attr_accessor :business_account_number
sig {
params(account_holder_name: T.nilable(String), business_account_number: T.nilable(String)).void
}
def initialize(account_holder_name: nil, business_account_number: nil); end
end
class Branding < Stripe::RequestParams
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) An icon for the account. Must be square and at least 128px x 128px.
sig { returns(T.nilable(String)) }
attr_accessor :icon
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) A logo for the account that will be used in Checkout instead of the icon and without the account's name next to it if provided. Must be at least 128px x 128px.
sig { returns(T.nilable(String)) }
attr_accessor :logo
# A CSS hex color value representing the primary branding color for this account.
sig { returns(T.nilable(String)) }
attr_accessor :primary_color
# A CSS hex color value representing the secondary branding color for this account.
sig { returns(T.nilable(String)) }
attr_accessor :secondary_color
sig {
params(icon: T.nilable(String), logo: T.nilable(String), primary_color: T.nilable(String), secondary_color: T.nilable(String)).void
}
def initialize(icon: nil, logo: nil, primary_color: nil, secondary_color: nil); end
end
class Capital < Stripe::RequestParams
# Per-currency mapping of user-selected destination accounts used to pay out loans.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :payout_destination
# Per-currency mapping of all destination accounts eligible to receive Capital financing payouts.
sig { returns(T.nilable(T::Hash[String, T::Array[String]])) }
attr_accessor :payout_destination_selector
sig {
params(payout_destination: T.nilable(T::Hash[String, String]), payout_destination_selector: T.nilable(T::Hash[String, T::Array[String]])).void
}
def initialize(payout_destination: nil, payout_destination_selector: nil); end
end
class CardIssuing < Stripe::RequestParams
class TosAcceptance < Stripe::RequestParams
# The Unix timestamp marking when the account representative accepted the service agreement.
sig { returns(T.nilable(Integer)) }
attr_accessor :date
# The IP address from which the account representative accepted the service agreement.
sig { returns(T.nilable(String)) }
attr_accessor :ip
# The user agent of the browser from which the account representative accepted the service agreement.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :user_agent
sig {
params(date: T.nilable(Integer), ip: T.nilable(String), user_agent: T.nilable(T.nilable(String))).void
}
def initialize(date: nil, ip: nil, user_agent: nil); end
end
# Details on the account's acceptance of the [Stripe Issuing Terms and Disclosures](/issuing/connect/tos_acceptance).
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Settings::CardIssuing::TosAcceptance))
}
attr_accessor :tos_acceptance
sig {
params(tos_acceptance: T.nilable(::Stripe::AccountService::UpdateParams::Settings::CardIssuing::TosAcceptance)).void
}
def initialize(tos_acceptance: nil); end
end
class CardPayments < Stripe::RequestParams
class DeclineOn < Stripe::RequestParams
# Whether Stripe automatically declines charges with an incorrect ZIP or postal code. This setting only applies when a ZIP or postal code is provided and they fail bank verification.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :avs_failure
# Whether Stripe automatically declines charges with an incorrect CVC. This setting only applies when a CVC is provided and it fails bank verification.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :cvc_failure
sig {
params(avs_failure: T.nilable(T::Boolean), cvc_failure: T.nilable(T::Boolean)).void
}
def initialize(avs_failure: nil, cvc_failure: nil); end
end
# Automatically declines certain charge types regardless of whether the card issuer accepted or declined the charge.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Settings::CardPayments::DeclineOn))
}
attr_accessor :decline_on
# The default text that appears on credit card statements when a charge is made. This field prefixes any dynamic `statement_descriptor` specified on the charge. `statement_descriptor_prefix` is useful for maximizing descriptor space for the dynamic portion.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor_prefix
# The Kana variation of the default text that appears on credit card statements when a charge is made (Japan only). This field prefixes any dynamic `statement_descriptor_suffix_kana` specified on the charge. `statement_descriptor_prefix_kana` is useful for maximizing descriptor space for the dynamic portion.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :statement_descriptor_prefix_kana
# The Kanji variation of the default text that appears on credit card statements when a charge is made (Japan only). This field prefixes any dynamic `statement_descriptor_suffix_kanji` specified on the charge. `statement_descriptor_prefix_kanji` is useful for maximizing descriptor space for the dynamic portion.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :statement_descriptor_prefix_kanji
sig {
params(decline_on: T.nilable(::Stripe::AccountService::UpdateParams::Settings::CardPayments::DeclineOn), statement_descriptor_prefix: T.nilable(String), statement_descriptor_prefix_kana: T.nilable(T.nilable(String)), statement_descriptor_prefix_kanji: T.nilable(T.nilable(String))).void
}
def initialize(
decline_on: nil,
statement_descriptor_prefix: nil,
statement_descriptor_prefix_kana: nil,
statement_descriptor_prefix_kanji: nil
); end
end
class Invoices < Stripe::RequestParams
# The list of default Account Tax IDs to automatically include on invoices. Account Tax IDs get added when an invoice is finalized.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :default_account_tax_ids
# Whether payment methods should be saved when a payment is completed for a one-time invoices on a hosted invoice page.
sig { returns(T.nilable(String)) }
attr_accessor :hosted_payment_method_save
sig {
params(default_account_tax_ids: T.nilable(T.nilable(T.any(String, T::Array[String]))), hosted_payment_method_save: T.nilable(String)).void
}
def initialize(default_account_tax_ids: nil, hosted_payment_method_save: nil); end
end
class Payments < Stripe::RequestParams
# The default text that appears on statements for non-card charges outside of Japan. For card charges, if you don't set a `statement_descriptor_prefix`, this text is also used as the statement descriptor prefix. In that case, if concatenating the statement descriptor suffix causes the combined statement descriptor to exceed 22 characters, we truncate the `statement_descriptor` text to limit the full descriptor to 22 characters. For more information about statement descriptors and their requirements, see the [account settings documentation](https://docs.stripe.com/get-started/account/statement-descriptors).
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
# The Kana variation of `statement_descriptor` used for charges in Japan. Japanese statement descriptors have [special requirements](https://docs.stripe.com/get-started/account/statement-descriptors#set-japanese-statement-descriptors).
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor_kana
# The Kanji variation of `statement_descriptor` used for charges in Japan. Japanese statement descriptors have [special requirements](https://docs.stripe.com/get-started/account/statement-descriptors#set-japanese-statement-descriptors).
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor_kanji
sig {
params(statement_descriptor: T.nilable(String), statement_descriptor_kana: T.nilable(String), statement_descriptor_kanji: T.nilable(String)).void
}
def initialize(
statement_descriptor: nil,
statement_descriptor_kana: nil,
statement_descriptor_kanji: nil
); end
end
class Payouts < Stripe::RequestParams
class Schedule < Stripe::RequestParams
# The number of days charge funds are held before being paid out. May also be set to `minimum`, representing the lowest available value for the account country. Default is `minimum`. The `delay_days` parameter remains at the last configured value if `interval` is `manual`. [Learn more about controlling payout delay days](/connect/manage-payout-schedule).
sig { returns(T.nilable(T.any(String, Integer))) }
attr_accessor :delay_days
# How frequently available funds are paid out. One of: `daily`, `manual`, `weekly`, or `monthly`. Default is `daily`.
sig { returns(T.nilable(String)) }
attr_accessor :interval
# The day of the month when available funds are paid out, specified as a number between 1--31. Payouts nominally scheduled between the 29th and 31st of the month are instead sent on the last day of a shorter month. Required and applicable only if `interval` is `monthly`.
sig { returns(T.nilable(Integer)) }
attr_accessor :monthly_anchor
# The day of the week when available funds are paid out, specified as `monday`, `tuesday`, etc. (required and applicable only if `interval` is `weekly`.)
sig { returns(T.nilable(String)) }
attr_accessor :weekly_anchor
sig {
params(delay_days: T.nilable(T.any(String, Integer)), interval: T.nilable(String), monthly_anchor: T.nilable(Integer), weekly_anchor: T.nilable(String)).void
}
def initialize(
delay_days: nil,
interval: nil,
monthly_anchor: nil,
weekly_anchor: nil
); end
end
# A Boolean indicating whether Stripe should try to reclaim negative balances from an attached bank account. For details, see [Understanding Connect Account Balances](/connect/account-balances).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :debit_negative_balances
# Details on when funds from charges are available, and when they are paid out to an external account. For details, see our [Setting Bank and Debit Card Payouts](/connect/bank-transfers#payout-information) documentation.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Settings::Payouts::Schedule))
}
attr_accessor :schedule
# The text that appears on the bank account statement for payouts. If not set, this defaults to the platform's bank descriptor as set in the Dashboard.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
sig {
params(debit_negative_balances: T.nilable(T::Boolean), schedule: T.nilable(::Stripe::AccountService::UpdateParams::Settings::Payouts::Schedule), statement_descriptor: T.nilable(String)).void
}
def initialize(
debit_negative_balances: nil,
schedule: nil,
statement_descriptor: nil
); end
end
class TaxForms < Stripe::RequestParams
# Whether the account opted out of receiving their tax forms by postal delivery.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :consented_to_paperless_delivery
sig { params(consented_to_paperless_delivery: T.nilable(T::Boolean)).void }
def initialize(consented_to_paperless_delivery: nil); end
end
class Treasury < Stripe::RequestParams
class TosAcceptance < Stripe::RequestParams
# The Unix timestamp marking when the account representative accepted the service agreement.
sig { returns(T.nilable(Integer)) }
attr_accessor :date
# The IP address from which the account representative accepted the service agreement.
sig { returns(T.nilable(String)) }
attr_accessor :ip
# The user agent of the browser from which the account representative accepted the service agreement.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :user_agent
sig {
params(date: T.nilable(Integer), ip: T.nilable(String), user_agent: T.nilable(T.nilable(String))).void
}
def initialize(date: nil, ip: nil, user_agent: nil); end
end
# Details on the account's acceptance of the Stripe Treasury Services Agreement.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Settings::Treasury::TosAcceptance))
}
attr_accessor :tos_acceptance
sig {
params(tos_acceptance: T.nilable(::Stripe::AccountService::UpdateParams::Settings::Treasury::TosAcceptance)).void
}
def initialize(tos_acceptance: nil); end
end
# Settings specific to Bacs Direct Debit payments.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Settings::BacsDebitPayments))
}
attr_accessor :bacs_debit_payments
# Settings specific to bank BCA onboarding for Indonesia bank transfers payments method.
sig {
returns(T.nilable(::Stripe::AccountService::UpdateParams::Settings::BankBcaOnboarding))
}
attr_accessor :bank_bca_onboarding
# Settings used to apply the account's branding to email receipts, invoices, Checkout, and other products.
sig { returns(T.nilable(::Stripe::AccountService::UpdateParams::Settings::Branding)) }
attr_accessor :branding
# Settings specific to the account's use of the Capital product.
sig { returns(T.nilable(::Stripe::AccountService::UpdateParams::Settings::Capital)) }
attr_accessor :capital
# Settings specific to the account's use of the Card Issuing product.
sig { returns(T.nilable(::Stripe::AccountService::UpdateParams::Settings::CardIssuing)) }
attr_accessor :card_issuing
# Settings specific to card charging on the account.
sig { returns(T.nilable(::Stripe::AccountService::UpdateParams::Settings::CardPayments)) }
attr_accessor :card_payments
# Settings specific to the account's use of Invoices.
sig { returns(T.nilable(::Stripe::AccountService::UpdateParams::Settings::Invoices)) }
attr_accessor :invoices
# Settings that apply across payment methods for charging on the account.
sig { returns(T.nilable(::Stripe::AccountService::UpdateParams::Settings::Payments)) }
attr_accessor :payments
# Settings specific to the account's payouts.
sig { returns(T.nilable(::Stripe::AccountService::UpdateParams::Settings::Payouts)) }
attr_accessor :payouts
# Settings specific to the account's tax forms.
sig { returns(T.nilable(::Stripe::AccountService::UpdateParams::Settings::TaxForms)) }
attr_accessor :tax_forms
# Settings specific to the account's Treasury FinancialAccounts.
sig { returns(T.nilable(::Stripe::AccountService::UpdateParams::Settings::Treasury)) }
attr_accessor :treasury
sig {
params(bacs_debit_payments: T.nilable(::Stripe::AccountService::UpdateParams::Settings::BacsDebitPayments), bank_bca_onboarding: T.nilable(::Stripe::AccountService::UpdateParams::Settings::BankBcaOnboarding), branding: T.nilable(::Stripe::AccountService::UpdateParams::Settings::Branding), capital: T.nilable(::Stripe::AccountService::UpdateParams::Settings::Capital), card_issuing: T.nilable(::Stripe::AccountService::UpdateParams::Settings::CardIssuing), card_payments: T.nilable(::Stripe::AccountService::UpdateParams::Settings::CardPayments), invoices: T.nilable(::Stripe::AccountService::UpdateParams::Settings::Invoices), payments: T.nilable(::Stripe::AccountService::UpdateParams::Settings::Payments), payouts: T.nilable(::Stripe::AccountService::UpdateParams::Settings::Payouts), tax_forms: T.nilable(::Stripe::AccountService::UpdateParams::Settings::TaxForms), treasury: T.nilable(::Stripe::AccountService::UpdateParams::Settings::Treasury)).void
}
def initialize(
bacs_debit_payments: nil,
bank_bca_onboarding: nil,
branding: nil,
capital: nil,
card_issuing: nil,
card_payments: nil,
invoices: nil,
payments: nil,
payouts: nil,
tax_forms: nil,
treasury: nil
); end
end
class TosAcceptance < Stripe::RequestParams
# The Unix timestamp marking when the account representative accepted their service agreement.
sig { returns(T.nilable(Integer)) }
attr_accessor :date
# The IP address from which the account representative accepted their service agreement.
sig { returns(T.nilable(String)) }
attr_accessor :ip
# The user's service agreement type.
sig { returns(T.nilable(String)) }
attr_accessor :service_agreement
# The user agent of the browser from which the account representative accepted their service agreement.
sig { returns(T.nilable(String)) }
attr_accessor :user_agent
sig {
params(date: T.nilable(Integer), ip: T.nilable(String), service_agreement: T.nilable(String), user_agent: T.nilable(String)).void
}
def initialize(date: nil, ip: nil, service_agreement: nil, user_agent: nil); end
end
# An [account token](https://stripe.com/docs/api#create_account_token), used to securely provide details to the account.
sig { returns(T.nilable(String)) }
attr_accessor :account_token
# Business information about the account.
sig { returns(T.nilable(::Stripe::AccountService::UpdateParams::BusinessProfile)) }
attr_accessor :business_profile
# The business type. Once you create an [Account Link](/api/account_links) or [Account Session](/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.
sig { returns(T.nilable(String)) }
attr_accessor :business_type
# Each key of the dictionary represents a capability, and each capability
# maps to its settings (for example, whether it has been requested or not). Each
# capability is inactive until you have provided its specific
# requirements and Stripe has verified them. An account might have some
# of its requested capabilities be active and some be inactive.
#
# Required when [account.controller.stripe_dashboard.type](/api/accounts/create#create_account-controller-dashboard-type)
# is `none`, which includes Custom accounts.
sig { returns(T.nilable(::Stripe::AccountService::UpdateParams::Capabilities)) }
attr_accessor :capabilities
# Information about the company or business. This field is available for any `business_type`. Once you create an [Account Link](/api/account_links) or [Account Session](/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.
sig { returns(T.nilable(::Stripe::AccountService::UpdateParams::Company)) }
attr_accessor :company
# Three-letter ISO currency code representing the default currency for the account. This must be a currency that [Stripe supports in the account's country](https://docs.stripe.com/payouts).
sig { returns(T.nilable(String)) }
attr_accessor :default_currency
# Documents that may be submitted to satisfy various informational requests.
sig { returns(T.nilable(::Stripe::AccountService::UpdateParams::Documents)) }
attr_accessor :documents
# The email address of the account holder. This is only to make the account easier to identify to you. If [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts, Stripe doesn't email the account without your consent.
sig { returns(T.nilable(String)) }
attr_accessor :email
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A card or bank account to attach to the account for receiving [payouts](/connect/bank-debit-card-payouts) (you won’t be able to use it for top-ups). You can provide either a token, like the ones returned by [Stripe.js](/js), or a dictionary, as documented in the `external_account` parameter for [bank account](/api#account_create_bank_account) creation.
By default, providing an external account sets it as the new default external account for its currency, and deletes the old default if one exists. To add additional external accounts without replacing the existing default for the currency, use the [bank account](/api#account_create_bank_account) or [card creation](/api#account_create_card) APIs. After you create an [Account Link](/api/account_links) or [Account Session](/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.
sig {
returns(T.nilable(T.nilable(T.any(String, T.any(String, ::Stripe::AccountService::UpdateParams::BankAccount, ::Stripe::AccountService::UpdateParams::Card, ::Stripe::AccountService::UpdateParams::CardToken)))))
}
attr_accessor :external_account
# A hash of account group type to tokens. These are account groups this account should be added to.
sig { returns(T.nilable(::Stripe::AccountService::UpdateParams::Groups)) }
attr_accessor :groups
# Information about the person represented by the account. This field is null unless `business_type` is set to `individual`. Once you create an [Account Link](/api/account_links) or [Account Session](/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.
sig { returns(T.nilable(::Stripe::AccountService::UpdateParams::Individual)) }
attr_accessor :individual
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# A hash to configure risk controls on the account. Please see [this page for more details](/connect/pausing-payments-or-payouts-on-connected-accounts).
sig { returns(T.nilable(::Stripe::AccountService::UpdateParams::RiskControls)) }
attr_accessor :risk_controls
# Options for customizing how the account functions within Stripe.
sig { returns(T.nilable(::Stripe::AccountService::UpdateParams::Settings)) }
attr_accessor :settings
# Details on the account's acceptance of the [Stripe Services Agreement](/connect/updating-accounts#tos-acceptance). This property can only be updated for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts. This property defaults to a `full` service agreement when empty.
sig { returns(T.nilable(::Stripe::AccountService::UpdateParams::TosAcceptance)) }
attr_accessor :tos_acceptance
sig {
params(account_token: T.nilable(String), business_profile: T.nilable(::Stripe::AccountService::UpdateParams::BusinessProfile), business_type: T.nilable(String), capabilities: T.nilable(::Stripe::AccountService::UpdateParams::Capabilities), company: T.nilable(::Stripe::AccountService::UpdateParams::Company), default_currency: T.nilable(String), documents: T.nilable(::Stripe::AccountService::UpdateParams::Documents), email: T.nilable(String), expand: T.nilable(T::Array[String]), external_account: T.nilable(T.nilable(T.any(String, T.any(String, ::Stripe::AccountService::UpdateParams::BankAccount, ::Stripe::AccountService::UpdateParams::Card, ::Stripe::AccountService::UpdateParams::CardToken)))), groups: T.nilable(::Stripe::AccountService::UpdateParams::Groups), individual: T.nilable(::Stripe::AccountService::UpdateParams::Individual), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), risk_controls: T.nilable(::Stripe::AccountService::UpdateParams::RiskControls), settings: T.nilable(::Stripe::AccountService::UpdateParams::Settings), tos_acceptance: T.nilable(::Stripe::AccountService::UpdateParams::TosAcceptance)).void
}
def initialize(
account_token: nil,
business_profile: nil,
business_type: nil,
capabilities: nil,
company: nil,
default_currency: nil,
documents: nil,
email: nil,
expand: nil,
external_account: nil,
groups: nil,
individual: nil,
metadata: nil,
risk_controls: nil,
settings: nil,
tos_acceptance: nil
); end
end
class RetrieveCurrentParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return connected accounts that were created during the given date interval.
sig { returns(T.nilable(T.any(::Stripe::AccountService::ListParams::Created, Integer))) }
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(created: T.nilable(T.any(::Stripe::AccountService::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class BankAccount < Stripe::RequestParams
# Attribute for param field object
sig { returns(String) }
attr_accessor :object
# The name of the person or business that owns the bank account.This field is required when attaching the bank account to a `Customer` object.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_name
# The type of entity that holds the account. It can be `company` or `individual`. This field is required when attaching the bank account to a `Customer` object.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_type
# The account number for the bank account, in string form. Must be a checking account.
sig { returns(String) }
attr_accessor :account_number
# The country in which the bank account is located.
sig { returns(String) }
attr_accessor :country
# The currency the bank account is in. This must be a country/currency pairing that [Stripe supports.](docs/payouts)
sig { returns(T.nilable(String)) }
attr_accessor :currency
# The routing number, sort code, or other country-appropriate institution number for the bank account. For US bank accounts, this is required and should be the ACH routing number, not the wire routing number. If you are providing an IBAN for `account_number`, this field is not required.
sig { returns(T.nilable(String)) }
attr_accessor :routing_number
sig {
params(object: String, account_holder_name: T.nilable(String), account_holder_type: T.nilable(String), account_number: String, country: String, currency: T.nilable(String), routing_number: T.nilable(String)).void
}
def initialize(
object: nil,
account_holder_name: nil,
account_holder_type: nil,
account_number: nil,
country: nil,
currency: nil,
routing_number: nil
); end
end
class BusinessProfile < Stripe::RequestParams
class AnnualRevenue < Stripe::RequestParams
# A non-negative integer representing the amount in the [smallest currency unit](/currencies#zero-decimal).
sig { returns(Integer) }
attr_accessor :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).
sig { returns(String) }
attr_accessor :currency
# The close-out date of the preceding fiscal year in ISO 8601 format. E.g. 2023-12-31 for the 31st of December, 2023.
sig { returns(String) }
attr_accessor :fiscal_year_end
sig { params(amount: Integer, currency: String, fiscal_year_end: String).void }
def initialize(amount: nil, currency: nil, fiscal_year_end: nil); end
end
class MonthlyEstimatedRevenue < Stripe::RequestParams
# A non-negative integer representing how much to charge in the [smallest currency unit](/currencies#zero-decimal).
sig { returns(Integer) }
attr_accessor :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).
sig { returns(String) }
attr_accessor :currency
sig { params(amount: Integer, currency: String).void }
def initialize(amount: nil, currency: nil); end
end
class SupportAddress < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# The applicant's gross annual revenue for its preceding fiscal year.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::BusinessProfile::AnnualRevenue))
}
attr_accessor :annual_revenue
# An estimated upper bound of employees, contractors, vendors, etc. currently working for the business.
sig { returns(T.nilable(Integer)) }
attr_accessor :estimated_worker_count
# [The merchant category code for the account](/connect/setting-mcc). MCCs are used to classify businesses based on the goods or services they provide.
sig { returns(T.nilable(String)) }
attr_accessor :mcc
# Whether the business is a minority-owned, women-owned, and/or LGBTQI+-owned business.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :minority_owned_business_designation
# An estimate of the monthly revenue of the business. Only accepted for accounts in Brazil and India.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::BusinessProfile::MonthlyEstimatedRevenue))
}
attr_accessor :monthly_estimated_revenue
# The customer-facing business name.
sig { returns(T.nilable(String)) }
attr_accessor :name
# Internal-only description of the product sold by, or service provided by, the business. Used by Stripe for risk and underwriting purposes.
sig { returns(T.nilable(String)) }
attr_accessor :product_description
# A publicly available mailing address for sending support issues to.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::BusinessProfile::SupportAddress))
}
attr_accessor :support_address
# A publicly available email address for sending support issues to.
sig { returns(T.nilable(String)) }
attr_accessor :support_email
# A publicly available phone number to call with support issues.
sig { returns(T.nilable(String)) }
attr_accessor :support_phone
# A publicly available website for handling support issues.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :support_url
# The business's publicly available website.
sig { returns(T.nilable(String)) }
attr_accessor :url
sig {
params(annual_revenue: T.nilable(::Stripe::AccountService::CreateParams::BusinessProfile::AnnualRevenue), estimated_worker_count: T.nilable(Integer), mcc: T.nilable(String), minority_owned_business_designation: T.nilable(T::Array[String]), monthly_estimated_revenue: T.nilable(::Stripe::AccountService::CreateParams::BusinessProfile::MonthlyEstimatedRevenue), name: T.nilable(String), product_description: T.nilable(String), support_address: T.nilable(::Stripe::AccountService::CreateParams::BusinessProfile::SupportAddress), support_email: T.nilable(String), support_phone: T.nilable(String), support_url: T.nilable(T.nilable(String)), url: T.nilable(String)).void
}
def initialize(
annual_revenue: nil,
estimated_worker_count: nil,
mcc: nil,
minority_owned_business_designation: nil,
monthly_estimated_revenue: nil,
name: nil,
product_description: nil,
support_address: nil,
support_email: nil,
support_phone: nil,
support_url: nil,
url: nil
); end
end
class Capabilities < Stripe::RequestParams
class AcssDebitPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class AffirmPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class AfterpayClearpayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class AlmaPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class AmazonPayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class AuBecsDebitPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class AutomaticIndirectTax < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class BacsDebitPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class BancontactPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class BankTransferPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class BilliePayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class BlikPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class BoletoPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class CardIssuing < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class CardPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class CartesBancairesPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class CashappPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class EpsPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class FpxPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class GbBankTransferPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class GiropayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class GopayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class GrabpayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class IdBankTransferPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class IdBankTransferPaymentsBca < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class IdealPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class IndiaInternationalPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class JcbPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class JpBankTransferPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class KakaoPayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class KlarnaPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class KonbiniPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class KrCardPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class LegacyPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class LinkPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class MbWayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class MobilepayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class MultibancoPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class MxBankTransferPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class NaverPayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class NzBankAccountBecsDebitPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class OxxoPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class P24Payments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class PayByBankPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class PaycoPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class PaynowPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class PaypalPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class PaytoPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class PixPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class PromptpayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class QrisPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class RechnungPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class RevolutPayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class SamsungPayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class SatispayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class SepaBankTransferPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class SepaDebitPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class ShopeepayPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class SofortPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class StripeBalancePayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class SwishPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class TaxReportingUs1099K < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class TaxReportingUs1099Misc < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class Transfers < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class Treasury < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class TreasuryEvolve < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class TreasuryFifthThird < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class TreasuryGoldmanSachs < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class TwintPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class UsBankAccountAchPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class UsBankTransferPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class ZipPayments < Stripe::RequestParams
# Passing true requests the capability for the account, if it is not already requested. A requested capability may not immediately become active. Any requirements to activate the capability are returned in the `requirements` arrays.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
# The acss_debit_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::AcssDebitPayments))
}
attr_accessor :acss_debit_payments
# The affirm_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::AffirmPayments))
}
attr_accessor :affirm_payments
# The afterpay_clearpay_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::AfterpayClearpayPayments))
}
attr_accessor :afterpay_clearpay_payments
# The alma_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::AlmaPayments))
}
attr_accessor :alma_payments
# The amazon_pay_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::AmazonPayPayments))
}
attr_accessor :amazon_pay_payments
# The au_becs_debit_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::AuBecsDebitPayments))
}
attr_accessor :au_becs_debit_payments
# The automatic_indirect_tax capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::AutomaticIndirectTax))
}
attr_accessor :automatic_indirect_tax
# The bacs_debit_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::BacsDebitPayments))
}
attr_accessor :bacs_debit_payments
# The bancontact_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::BancontactPayments))
}
attr_accessor :bancontact_payments
# The bank_transfer_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::BankTransferPayments))
}
attr_accessor :bank_transfer_payments
# The billie_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::BilliePayments))
}
attr_accessor :billie_payments
# The blik_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::BlikPayments))
}
attr_accessor :blik_payments
# The boleto_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::BoletoPayments))
}
attr_accessor :boleto_payments
# The card_issuing capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::CardIssuing))
}
attr_accessor :card_issuing
# The card_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::CardPayments))
}
attr_accessor :card_payments
# The cartes_bancaires_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::CartesBancairesPayments))
}
attr_accessor :cartes_bancaires_payments
# The cashapp_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::CashappPayments))
}
attr_accessor :cashapp_payments
# The eps_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::EpsPayments))
}
attr_accessor :eps_payments
# The fpx_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::FpxPayments))
}
attr_accessor :fpx_payments
# The gb_bank_transfer_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::GbBankTransferPayments))
}
attr_accessor :gb_bank_transfer_payments
# The giropay_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::GiropayPayments))
}
attr_accessor :giropay_payments
# The gopay_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::GopayPayments))
}
attr_accessor :gopay_payments
# The grabpay_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::GrabpayPayments))
}
attr_accessor :grabpay_payments
# The id_bank_transfer_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::IdBankTransferPayments))
}
attr_accessor :id_bank_transfer_payments
# The id_bank_transfer_payments_bca capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::IdBankTransferPaymentsBca))
}
attr_accessor :id_bank_transfer_payments_bca
# The ideal_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::IdealPayments))
}
attr_accessor :ideal_payments
# The india_international_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::IndiaInternationalPayments))
}
attr_accessor :india_international_payments
# The jcb_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::JcbPayments))
}
attr_accessor :jcb_payments
# The jp_bank_transfer_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::JpBankTransferPayments))
}
attr_accessor :jp_bank_transfer_payments
# The kakao_pay_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::KakaoPayPayments))
}
attr_accessor :kakao_pay_payments
# The klarna_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::KlarnaPayments))
}
attr_accessor :klarna_payments
# The konbini_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::KonbiniPayments))
}
attr_accessor :konbini_payments
# The kr_card_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::KrCardPayments))
}
attr_accessor :kr_card_payments
# The legacy_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::LegacyPayments))
}
attr_accessor :legacy_payments
# The link_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::LinkPayments))
}
attr_accessor :link_payments
# The mb_way_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::MbWayPayments))
}
attr_accessor :mb_way_payments
# The mobilepay_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::MobilepayPayments))
}
attr_accessor :mobilepay_payments
# The multibanco_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::MultibancoPayments))
}
attr_accessor :multibanco_payments
# The mx_bank_transfer_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::MxBankTransferPayments))
}
attr_accessor :mx_bank_transfer_payments
# The naver_pay_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::NaverPayPayments))
}
attr_accessor :naver_pay_payments
# The nz_bank_account_becs_debit_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::NzBankAccountBecsDebitPayments))
}
attr_accessor :nz_bank_account_becs_debit_payments
# The oxxo_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::OxxoPayments))
}
attr_accessor :oxxo_payments
# The p24_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::P24Payments))
}
attr_accessor :p24_payments
# The pay_by_bank_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::PayByBankPayments))
}
attr_accessor :pay_by_bank_payments
# The payco_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::PaycoPayments))
}
attr_accessor :payco_payments
# The paynow_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::PaynowPayments))
}
attr_accessor :paynow_payments
# The paypal_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::PaypalPayments))
}
attr_accessor :paypal_payments
# The payto_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::PaytoPayments))
}
attr_accessor :payto_payments
# The pix_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::PixPayments))
}
attr_accessor :pix_payments
# The promptpay_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::PromptpayPayments))
}
attr_accessor :promptpay_payments
# The qris_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::QrisPayments))
}
attr_accessor :qris_payments
# The rechnung_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::RechnungPayments))
}
attr_accessor :rechnung_payments
# The revolut_pay_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::RevolutPayPayments))
}
attr_accessor :revolut_pay_payments
# The samsung_pay_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::SamsungPayPayments))
}
attr_accessor :samsung_pay_payments
# The satispay_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::SatispayPayments))
}
attr_accessor :satispay_payments
# The sepa_bank_transfer_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::SepaBankTransferPayments))
}
attr_accessor :sepa_bank_transfer_payments
# The sepa_debit_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::SepaDebitPayments))
}
attr_accessor :sepa_debit_payments
# The shopeepay_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::ShopeepayPayments))
}
attr_accessor :shopeepay_payments
# The sofort_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::SofortPayments))
}
attr_accessor :sofort_payments
# The stripe_balance_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::StripeBalancePayments))
}
attr_accessor :stripe_balance_payments
# The swish_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::SwishPayments))
}
attr_accessor :swish_payments
# The tax_reporting_us_1099_k capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::TaxReportingUs1099K))
}
attr_accessor :tax_reporting_us_1099_k
# The tax_reporting_us_1099_misc capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::TaxReportingUs1099Misc))
}
attr_accessor :tax_reporting_us_1099_misc
# The transfers capability.
sig { returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::Transfers)) }
attr_accessor :transfers
# The treasury capability.
sig { returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::Treasury)) }
attr_accessor :treasury
# The treasury_evolve capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::TreasuryEvolve))
}
attr_accessor :treasury_evolve
# The treasury_fifth_third capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::TreasuryFifthThird))
}
attr_accessor :treasury_fifth_third
# The treasury_goldman_sachs capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::TreasuryGoldmanSachs))
}
attr_accessor :treasury_goldman_sachs
# The twint_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::TwintPayments))
}
attr_accessor :twint_payments
# The us_bank_account_ach_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::UsBankAccountAchPayments))
}
attr_accessor :us_bank_account_ach_payments
# The us_bank_transfer_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::UsBankTransferPayments))
}
attr_accessor :us_bank_transfer_payments
# The zip_payments capability.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities::ZipPayments))
}
attr_accessor :zip_payments
sig {
params(acss_debit_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::AcssDebitPayments), affirm_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::AffirmPayments), afterpay_clearpay_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::AfterpayClearpayPayments), alma_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::AlmaPayments), amazon_pay_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::AmazonPayPayments), au_becs_debit_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::AuBecsDebitPayments), automatic_indirect_tax: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::AutomaticIndirectTax), bacs_debit_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::BacsDebitPayments), bancontact_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::BancontactPayments), bank_transfer_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::BankTransferPayments), billie_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::BilliePayments), blik_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::BlikPayments), boleto_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::BoletoPayments), card_issuing: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::CardIssuing), card_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::CardPayments), cartes_bancaires_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::CartesBancairesPayments), cashapp_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::CashappPayments), eps_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::EpsPayments), fpx_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::FpxPayments), gb_bank_transfer_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::GbBankTransferPayments), giropay_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::GiropayPayments), gopay_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::GopayPayments), grabpay_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::GrabpayPayments), id_bank_transfer_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::IdBankTransferPayments), id_bank_transfer_payments_bca: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::IdBankTransferPaymentsBca), ideal_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::IdealPayments), india_international_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::IndiaInternationalPayments), jcb_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::JcbPayments), jp_bank_transfer_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::JpBankTransferPayments), kakao_pay_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::KakaoPayPayments), klarna_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::KlarnaPayments), konbini_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::KonbiniPayments), kr_card_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::KrCardPayments), legacy_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::LegacyPayments), link_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::LinkPayments), mb_way_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::MbWayPayments), mobilepay_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::MobilepayPayments), multibanco_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::MultibancoPayments), mx_bank_transfer_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::MxBankTransferPayments), naver_pay_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::NaverPayPayments), nz_bank_account_becs_debit_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::NzBankAccountBecsDebitPayments), oxxo_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::OxxoPayments), p24_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::P24Payments), pay_by_bank_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::PayByBankPayments), payco_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::PaycoPayments), paynow_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::PaynowPayments), paypal_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::PaypalPayments), payto_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::PaytoPayments), pix_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::PixPayments), promptpay_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::PromptpayPayments), qris_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::QrisPayments), rechnung_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::RechnungPayments), revolut_pay_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::RevolutPayPayments), samsung_pay_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::SamsungPayPayments), satispay_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::SatispayPayments), sepa_bank_transfer_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::SepaBankTransferPayments), sepa_debit_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::SepaDebitPayments), shopeepay_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::ShopeepayPayments), sofort_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::SofortPayments), stripe_balance_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::StripeBalancePayments), swish_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::SwishPayments), tax_reporting_us_1099_k: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::TaxReportingUs1099K), tax_reporting_us_1099_misc: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::TaxReportingUs1099Misc), transfers: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::Transfers), treasury: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::Treasury), treasury_evolve: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::TreasuryEvolve), treasury_fifth_third: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::TreasuryFifthThird), treasury_goldman_sachs: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::TreasuryGoldmanSachs), twint_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::TwintPayments), us_bank_account_ach_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::UsBankAccountAchPayments), us_bank_transfer_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::UsBankTransferPayments), zip_payments: T.nilable(::Stripe::AccountService::CreateParams::Capabilities::ZipPayments)).void
}
def initialize(
acss_debit_payments: nil,
affirm_payments: nil,
afterpay_clearpay_payments: nil,
alma_payments: nil,
amazon_pay_payments: nil,
au_becs_debit_payments: nil,
automatic_indirect_tax: nil,
bacs_debit_payments: nil,
bancontact_payments: nil,
bank_transfer_payments: nil,
billie_payments: nil,
blik_payments: nil,
boleto_payments: nil,
card_issuing: nil,
card_payments: nil,
cartes_bancaires_payments: nil,
cashapp_payments: nil,
eps_payments: nil,
fpx_payments: nil,
gb_bank_transfer_payments: nil,
giropay_payments: nil,
gopay_payments: nil,
grabpay_payments: nil,
id_bank_transfer_payments: nil,
id_bank_transfer_payments_bca: nil,
ideal_payments: nil,
india_international_payments: nil,
jcb_payments: nil,
jp_bank_transfer_payments: nil,
kakao_pay_payments: nil,
klarna_payments: nil,
konbini_payments: nil,
kr_card_payments: nil,
legacy_payments: nil,
link_payments: nil,
mb_way_payments: nil,
mobilepay_payments: nil,
multibanco_payments: nil,
mx_bank_transfer_payments: nil,
naver_pay_payments: nil,
nz_bank_account_becs_debit_payments: nil,
oxxo_payments: nil,
p24_payments: nil,
pay_by_bank_payments: nil,
payco_payments: nil,
paynow_payments: nil,
paypal_payments: nil,
payto_payments: nil,
pix_payments: nil,
promptpay_payments: nil,
qris_payments: nil,
rechnung_payments: nil,
revolut_pay_payments: nil,
samsung_pay_payments: nil,
satispay_payments: nil,
sepa_bank_transfer_payments: nil,
sepa_debit_payments: nil,
shopeepay_payments: nil,
sofort_payments: nil,
stripe_balance_payments: nil,
swish_payments: nil,
tax_reporting_us_1099_k: nil,
tax_reporting_us_1099_misc: nil,
transfers: nil,
treasury: nil,
treasury_evolve: nil,
treasury_fifth_third: nil,
treasury_goldman_sachs: nil,
twint_payments: nil,
us_bank_account_ach_payments: nil,
us_bank_transfer_payments: nil,
zip_payments: nil
); end
end
class Card < Stripe::RequestParams
# Attribute for param field object
sig { returns(String) }
attr_accessor :object
# Attribute for param field address_city
sig { returns(T.nilable(String)) }
attr_accessor :address_city
# Attribute for param field address_country
sig { returns(T.nilable(String)) }
attr_accessor :address_country
# Attribute for param field address_line1
sig { returns(T.nilable(String)) }
attr_accessor :address_line1
# Attribute for param field address_line2
sig { returns(T.nilable(String)) }
attr_accessor :address_line2
# Attribute for param field address_state
sig { returns(T.nilable(String)) }
attr_accessor :address_state
# Attribute for param field address_zip
sig { returns(T.nilable(String)) }
attr_accessor :address_zip
# Attribute for param field currency
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Attribute for param field cvc
sig { returns(T.nilable(String)) }
attr_accessor :cvc
# Attribute for param field exp_month
sig { returns(Integer) }
attr_accessor :exp_month
# Attribute for param field exp_year
sig { returns(Integer) }
attr_accessor :exp_year
# Attribute for param field name
sig { returns(T.nilable(String)) }
attr_accessor :name
# Attribute for param field number
sig { returns(String) }
attr_accessor :number
# 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.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Attribute for param field default_for_currency
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :default_for_currency
sig {
params(object: String, address_city: T.nilable(String), address_country: T.nilable(String), address_line1: T.nilable(String), address_line2: T.nilable(String), address_state: T.nilable(String), address_zip: T.nilable(String), currency: T.nilable(String), cvc: T.nilable(String), exp_month: Integer, exp_year: Integer, name: T.nilable(String), number: String, metadata: T.nilable(T::Hash[String, String]), default_for_currency: T.nilable(T::Boolean)).void
}
def initialize(
object: nil,
address_city: nil,
address_country: nil,
address_line1: nil,
address_line2: nil,
address_state: nil,
address_zip: nil,
currency: nil,
cvc: nil,
exp_month: nil,
exp_year: nil,
name: nil,
number: nil,
metadata: nil,
default_for_currency: nil
); end
end
class CardToken < Stripe::RequestParams
# Attribute for param field object
sig { returns(String) }
attr_accessor :object
# Attribute for param field currency
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Attribute for param field token
sig { returns(String) }
attr_accessor :token
sig { params(object: String, currency: T.nilable(String), token: String).void }
def initialize(object: nil, currency: nil, token: nil); end
end
class Company < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class AddressKana < Stripe::RequestParams
# City or ward.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Block or building number.
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Building details.
sig { returns(T.nilable(String)) }
attr_accessor :line2
# Postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# Prefecture.
sig { returns(T.nilable(String)) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_accessor :town
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), town: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
class AddressKanji < Stripe::RequestParams
# City or ward.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Block or building number.
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Building details.
sig { returns(T.nilable(String)) }
attr_accessor :line2
# Postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# Prefecture.
sig { returns(T.nilable(String)) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_accessor :town
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), town: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
class DirectorshipDeclaration < Stripe::RequestParams
# The Unix timestamp marking when the directorship declaration attestation was made.
sig { returns(T.nilable(Integer)) }
attr_accessor :date
# The IP address from which the directorship declaration attestation was made.
sig { returns(T.nilable(String)) }
attr_accessor :ip
# The user agent of the browser from which the directorship declaration attestation was made.
sig { returns(T.nilable(String)) }
attr_accessor :user_agent
sig {
params(date: T.nilable(Integer), ip: T.nilable(String), user_agent: T.nilable(String)).void
}
def initialize(date: nil, ip: nil, user_agent: nil); end
end
class OwnershipDeclaration < Stripe::RequestParams
# The Unix timestamp marking when the beneficial owner attestation was made.
sig { returns(T.nilable(Integer)) }
attr_accessor :date
# The IP address from which the beneficial owner attestation was made.
sig { returns(T.nilable(String)) }
attr_accessor :ip
# The user agent of the browser from which the beneficial owner attestation was made.
sig { returns(T.nilable(String)) }
attr_accessor :user_agent
sig {
params(date: T.nilable(Integer), ip: T.nilable(String), user_agent: T.nilable(String)).void
}
def initialize(date: nil, ip: nil, user_agent: nil); end
end
class RegistrationDate < Stripe::RequestParams
# The day of registration, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of registration, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of registration.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
class Verification < Stripe::RequestParams
class Document < Stripe::RequestParams
# The back of a document returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `additional_verification`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :back
# The front of a document returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `additional_verification`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :front
sig { params(back: T.nilable(String), front: T.nilable(String)).void }
def initialize(back: nil, front: nil); end
end
# A document verifying the business.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Company::Verification::Document))
}
attr_accessor :document
sig {
params(document: T.nilable(::Stripe::AccountService::CreateParams::Company::Verification::Document)).void
}
def initialize(document: nil); end
end
# The company's primary address.
sig { returns(T.nilable(::Stripe::AccountService::CreateParams::Company::Address)) }
attr_accessor :address
# The Kana variation of the company's primary address (Japan only).
sig { returns(T.nilable(::Stripe::AccountService::CreateParams::Company::AddressKana)) }
attr_accessor :address_kana
# The Kanji variation of the company's primary address (Japan only).
sig { returns(T.nilable(::Stripe::AccountService::CreateParams::Company::AddressKanji)) }
attr_accessor :address_kanji
# Whether the company's directors have been provided. Set this Boolean to `true` after creating all the company's directors with [the Persons API](/api/persons) for accounts with a `relationship.director` requirement. This value is not automatically set to `true` after creating directors, so it needs to be updated to indicate all directors have been provided.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :directors_provided
# This hash is used to attest that the directors information provided to Stripe is both current and correct.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Company::DirectorshipDeclaration))
}
attr_accessor :directorship_declaration
# Whether the company's executives have been provided. Set this Boolean to `true` after creating all the company's executives with [the Persons API](/api/persons) for accounts with a `relationship.executive` requirement.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :executives_provided
# The export license ID number of the company, also referred as Import Export Code (India only).
sig { returns(T.nilable(String)) }
attr_accessor :export_license_id
# The purpose code to use for export transactions (India only).
sig { returns(T.nilable(String)) }
attr_accessor :export_purpose_code
# The company's legal name.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The Kana variation of the company's legal name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :name_kana
# The Kanji variation of the company's legal name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :name_kanji
# Whether the company's owners have been provided. Set this Boolean to `true` after creating all the company's owners with [the Persons API](/api/persons) for accounts with a `relationship.owner` requirement.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :owners_provided
# This hash is used to attest that the beneficial owner information provided to Stripe is both current and correct.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Company::OwnershipDeclaration))
}
attr_accessor :ownership_declaration
# This value is used to determine if a business is exempt from providing ultimate beneficial owners. See [this support article](https://support.stripe.com/questions/exemption-from-providing-ownership-details) and [changelog](https://docs.stripe.com/changelog/acacia/2025-01-27/ownership-exemption-reason-accounts-api) for more details.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :ownership_exemption_reason
# The company's phone number (used for verification).
sig { returns(T.nilable(String)) }
attr_accessor :phone
# Attribute for param field registration_date
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::AccountService::CreateParams::Company::RegistrationDate))))
}
attr_accessor :registration_date
# The identification number given to a company when it is registered or incorporated, if distinct from the identification number used for filing taxes. (Examples are the CIN for companies and LLP IN for partnerships in India, and the Company Registration Number in Hong Kong).
sig { returns(T.nilable(String)) }
attr_accessor :registration_number
# The category identifying the legal structure of the company or legal entity. See [Business structure](/connect/identity-verification#business-structure) for more details. Pass an empty string to unset this value.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :structure
# The business ID number of the company, as appropriate for the company’s country. (Examples are an Employer ID Number in the U.S., a Business Number in Canada, or a Company Number in the UK.)
sig { returns(T.nilable(String)) }
attr_accessor :tax_id
# The jurisdiction in which the `tax_id` is registered (Germany-based companies only).
sig { returns(T.nilable(String)) }
attr_accessor :tax_id_registrar
# The VAT number of the company.
sig { returns(T.nilable(String)) }
attr_accessor :vat_id
# Information on the verification state of the company.
sig { returns(T.nilable(::Stripe::AccountService::CreateParams::Company::Verification)) }
attr_accessor :verification
sig {
params(address: T.nilable(::Stripe::AccountService::CreateParams::Company::Address), address_kana: T.nilable(::Stripe::AccountService::CreateParams::Company::AddressKana), address_kanji: T.nilable(::Stripe::AccountService::CreateParams::Company::AddressKanji), directors_provided: T.nilable(T::Boolean), directorship_declaration: T.nilable(::Stripe::AccountService::CreateParams::Company::DirectorshipDeclaration), executives_provided: T.nilable(T::Boolean), export_license_id: T.nilable(String), export_purpose_code: T.nilable(String), name: T.nilable(String), name_kana: T.nilable(String), name_kanji: T.nilable(String), owners_provided: T.nilable(T::Boolean), ownership_declaration: T.nilable(::Stripe::AccountService::CreateParams::Company::OwnershipDeclaration), ownership_exemption_reason: T.nilable(T.nilable(T.any(String, String))), phone: T.nilable(String), registration_date: T.nilable(T.nilable(T.any(String, ::Stripe::AccountService::CreateParams::Company::RegistrationDate))), registration_number: T.nilable(String), structure: T.nilable(T.nilable(T.any(String, String))), tax_id: T.nilable(String), tax_id_registrar: T.nilable(String), vat_id: T.nilable(String), verification: T.nilable(::Stripe::AccountService::CreateParams::Company::Verification)).void
}
def initialize(
address: nil,
address_kana: nil,
address_kanji: nil,
directors_provided: nil,
directorship_declaration: nil,
executives_provided: nil,
export_license_id: nil,
export_purpose_code: nil,
name: nil,
name_kana: nil,
name_kanji: nil,
owners_provided: nil,
ownership_declaration: nil,
ownership_exemption_reason: nil,
phone: nil,
registration_date: nil,
registration_number: nil,
structure: nil,
tax_id: nil,
tax_id_registrar: nil,
vat_id: nil,
verification: nil
); end
end
class Controller < Stripe::RequestParams
class Application < Stripe::RequestParams
# Whether the controller is liable for losses on this account. For details, see [Understanding Connect Account Balances](https://stripe.com/docs/connect/account-balances).
sig { returns(T::Boolean) }
attr_accessor :loss_liable
# Whether the controller owns onboarding for this account.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :onboarding_owner
# Whether the controller has pricing controls for this account.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :pricing_controls
sig {
params(loss_liable: T::Boolean, onboarding_owner: T.nilable(T::Boolean), pricing_controls: T.nilable(T::Boolean)).void
}
def initialize(loss_liable: nil, onboarding_owner: nil, pricing_controls: nil); end
end
class Dashboard < Stripe::RequestParams
# Whether this account should have access to the full Stripe Dashboard (`full`), to the Express Dashboard (`express`), or to no Stripe-hosted dashboard (`none`). Defaults to `full`.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig { params(type: T.nilable(String)).void }
def initialize(type: nil); end
end
class Fees < Stripe::RequestParams
# A value indicating the responsible payer of Stripe fees on this account. Defaults to `account`. Learn more about [fee behavior on connected accounts](https://docs.stripe.com/connect/direct-charges-fee-payer-behavior).
sig { returns(T.nilable(String)) }
attr_accessor :payer
sig { params(payer: T.nilable(String)).void }
def initialize(payer: nil); end
end
class Losses < Stripe::RequestParams
# A value indicating who is liable when this account can't pay back negative balances resulting from payments. Defaults to `stripe`.
sig { returns(T.nilable(String)) }
attr_accessor :payments
sig { params(payments: T.nilable(String)).void }
def initialize(payments: nil); end
end
class StripeDashboard < Stripe::RequestParams
# Whether this account should have access to the full Stripe Dashboard (`full`), to the Express Dashboard (`express`), or to no Stripe-hosted dashboard (`none`). Defaults to `full`.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig { params(type: T.nilable(String)).void }
def initialize(type: nil); end
end
# A hash of configuration describing the Connect application that controls the account.
sig { returns(T.nilable(::Stripe::AccountService::CreateParams::Controller::Application)) }
attr_accessor :application
# Properties of the account's dashboard.
sig { returns(T.nilable(::Stripe::AccountService::CreateParams::Controller::Dashboard)) }
attr_accessor :dashboard
# A hash of configuration for who pays Stripe fees for product usage on this account.
sig { returns(T.nilable(::Stripe::AccountService::CreateParams::Controller::Fees)) }
attr_accessor :fees
# A hash of configuration for products that have negative balance liability, and whether Stripe or a Connect application is responsible for them.
sig { returns(T.nilable(::Stripe::AccountService::CreateParams::Controller::Losses)) }
attr_accessor :losses
# A value indicating responsibility for collecting updated information when requirements on the account are due or change. Defaults to `stripe`.
sig { returns(T.nilable(String)) }
attr_accessor :requirement_collection
# A hash of configuration for Stripe-hosted dashboards.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Controller::StripeDashboard))
}
attr_accessor :stripe_dashboard
sig {
params(application: T.nilable(::Stripe::AccountService::CreateParams::Controller::Application), dashboard: T.nilable(::Stripe::AccountService::CreateParams::Controller::Dashboard), fees: T.nilable(::Stripe::AccountService::CreateParams::Controller::Fees), losses: T.nilable(::Stripe::AccountService::CreateParams::Controller::Losses), requirement_collection: T.nilable(String), stripe_dashboard: T.nilable(::Stripe::AccountService::CreateParams::Controller::StripeDashboard)).void
}
def initialize(
application: nil,
dashboard: nil,
fees: nil,
losses: nil,
requirement_collection: nil,
stripe_dashboard: nil
); end
end
class Documents < Stripe::RequestParams
class BankAccountOwnershipVerification < Stripe::RequestParams
# One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :files
sig { params(files: T.nilable(T::Array[String])).void }
def initialize(files: nil); end
end
class CompanyLicense < Stripe::RequestParams
# One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :files
sig { params(files: T.nilable(T::Array[String])).void }
def initialize(files: nil); end
end
class CompanyMemorandumOfAssociation < Stripe::RequestParams
# One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :files
sig { params(files: T.nilable(T::Array[String])).void }
def initialize(files: nil); end
end
class CompanyMinisterialDecree < Stripe::RequestParams
# One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :files
sig { params(files: T.nilable(T::Array[String])).void }
def initialize(files: nil); end
end
class CompanyRegistrationVerification < Stripe::RequestParams
# One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :files
sig { params(files: T.nilable(T::Array[String])).void }
def initialize(files: nil); end
end
class CompanyTaxIdVerification < Stripe::RequestParams
# One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :files
sig { params(files: T.nilable(T::Array[String])).void }
def initialize(files: nil); end
end
class ProofOfRegistration < Stripe::RequestParams
# One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :files
sig { params(files: T.nilable(T::Array[String])).void }
def initialize(files: nil); end
end
class ProofOfUltimateBeneficialOwnership < Stripe::RequestParams
# One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :files
sig { params(files: T.nilable(T::Array[String])).void }
def initialize(files: nil); end
end
# One or more documents that support the [Bank account ownership verification](https://support.stripe.com/questions/bank-account-ownership-verification) requirement. Must be a document associated with the account’s primary active bank account that displays the last 4 digits of the account number, either a statement or a check.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Documents::BankAccountOwnershipVerification))
}
attr_accessor :bank_account_ownership_verification
# One or more documents that demonstrate proof of a company's license to operate.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Documents::CompanyLicense))
}
attr_accessor :company_license
# One or more documents showing the company's Memorandum of Association.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Documents::CompanyMemorandumOfAssociation))
}
attr_accessor :company_memorandum_of_association
# (Certain countries only) One or more documents showing the ministerial decree legalizing the company's establishment.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Documents::CompanyMinisterialDecree))
}
attr_accessor :company_ministerial_decree
# One or more documents that demonstrate proof of a company's registration with the appropriate local authorities.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Documents::CompanyRegistrationVerification))
}
attr_accessor :company_registration_verification
# One or more documents that demonstrate proof of a company's tax ID.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Documents::CompanyTaxIdVerification))
}
attr_accessor :company_tax_id_verification
# One or more documents showing the company’s proof of registration with the national business registry.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Documents::ProofOfRegistration))
}
attr_accessor :proof_of_registration
# One or more documents that demonstrate proof of ultimate beneficial ownership.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Documents::ProofOfUltimateBeneficialOwnership))
}
attr_accessor :proof_of_ultimate_beneficial_ownership
sig {
params(bank_account_ownership_verification: T.nilable(::Stripe::AccountService::CreateParams::Documents::BankAccountOwnershipVerification), company_license: T.nilable(::Stripe::AccountService::CreateParams::Documents::CompanyLicense), company_memorandum_of_association: T.nilable(::Stripe::AccountService::CreateParams::Documents::CompanyMemorandumOfAssociation), company_ministerial_decree: T.nilable(::Stripe::AccountService::CreateParams::Documents::CompanyMinisterialDecree), company_registration_verification: T.nilable(::Stripe::AccountService::CreateParams::Documents::CompanyRegistrationVerification), company_tax_id_verification: T.nilable(::Stripe::AccountService::CreateParams::Documents::CompanyTaxIdVerification), proof_of_registration: T.nilable(::Stripe::AccountService::CreateParams::Documents::ProofOfRegistration), proof_of_ultimate_beneficial_ownership: T.nilable(::Stripe::AccountService::CreateParams::Documents::ProofOfUltimateBeneficialOwnership)).void
}
def initialize(
bank_account_ownership_verification: nil,
company_license: nil,
company_memorandum_of_association: nil,
company_ministerial_decree: nil,
company_registration_verification: nil,
company_tax_id_verification: nil,
proof_of_registration: nil,
proof_of_ultimate_beneficial_ownership: nil
); end
end
class Groups < Stripe::RequestParams
# The group the account is in to determine their payments pricing, and null if the account is on customized pricing. [See the Platform pricing tool documentation](https://stripe.com/docs/connect/platform-pricing-tools) for details.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :payments_pricing
sig { params(payments_pricing: T.nilable(T.nilable(String))).void }
def initialize(payments_pricing: nil); end
end
class Individual < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class AddressKana < Stripe::RequestParams
# City or ward.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Block or building number.
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Building details.
sig { returns(T.nilable(String)) }
attr_accessor :line2
# Postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# Prefecture.
sig { returns(T.nilable(String)) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_accessor :town
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), town: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
class AddressKanji < Stripe::RequestParams
# City or ward.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Block or building number.
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Building details.
sig { returns(T.nilable(String)) }
attr_accessor :line2
# Postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# Prefecture.
sig { returns(T.nilable(String)) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_accessor :town
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), town: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
class Dob < Stripe::RequestParams
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
class RegisteredAddress < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class Relationship < Stripe::RequestParams
# Whether the person is a director of the account's legal entity. Directors are typically members of the governing board of the company, or responsible for ensuring the company meets its regulatory obligations.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :director
# Whether the person has significant responsibility to control, manage, or direct the organization.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :executive
# Whether the person is an owner of the account’s legal entity.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :owner
# The percent owned by the person of the account's legal entity.
sig { returns(T.nilable(T.nilable(T.any(String, Float)))) }
attr_accessor :percent_ownership
# The person's title (e.g., CEO, Support Engineer).
sig { returns(T.nilable(String)) }
attr_accessor :title
sig {
params(director: T.nilable(T::Boolean), executive: T.nilable(T::Boolean), owner: T.nilable(T::Boolean), percent_ownership: T.nilable(T.nilable(T.any(String, Float))), title: T.nilable(String)).void
}
def initialize(
director: nil,
executive: nil,
owner: nil,
percent_ownership: nil,
title: nil
); end
end
class Verification < Stripe::RequestParams
class AdditionalDocument < Stripe::RequestParams
# The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :back
# The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :front
sig { params(back: T.nilable(String), front: T.nilable(String)).void }
def initialize(back: nil, front: nil); end
end
class Document < Stripe::RequestParams
# The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :back
# The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :front
sig { params(back: T.nilable(String), front: T.nilable(String)).void }
def initialize(back: nil, front: nil); end
end
# A document showing address, either a passport, local ID card, or utility bill from a well-known utility company.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Individual::Verification::AdditionalDocument))
}
attr_accessor :additional_document
# An identifying document, either a passport or local ID card.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Individual::Verification::Document))
}
attr_accessor :document
sig {
params(additional_document: T.nilable(::Stripe::AccountService::CreateParams::Individual::Verification::AdditionalDocument), document: T.nilable(::Stripe::AccountService::CreateParams::Individual::Verification::Document)).void
}
def initialize(additional_document: nil, document: nil); end
end
# The individual's primary address.
sig { returns(T.nilable(::Stripe::AccountService::CreateParams::Individual::Address)) }
attr_accessor :address
# The Kana variation of the individual's primary address (Japan only).
sig { returns(T.nilable(::Stripe::AccountService::CreateParams::Individual::AddressKana)) }
attr_accessor :address_kana
# The Kanji variation of the individual's primary address (Japan only).
sig { returns(T.nilable(::Stripe::AccountService::CreateParams::Individual::AddressKanji)) }
attr_accessor :address_kanji
# The individual's date of birth.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::AccountService::CreateParams::Individual::Dob))))
}
attr_accessor :dob
# The individual's email address.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The individual's first name.
sig { returns(T.nilable(String)) }
attr_accessor :first_name
# The Kana variation of the individual's first name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :first_name_kana
# The Kanji variation of the individual's first name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :first_name_kanji
# A list of alternate names or aliases that the individual is known by.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :full_name_aliases
# The individual's gender
sig { returns(T.nilable(String)) }
attr_accessor :gender
# The government-issued ID number of the individual, as appropriate for the representative's country. (Examples are a Social Security Number in the U.S., or a Social Insurance Number in Canada). Instead of the number itself, you can also provide a [PII token created with Stripe.js](/js/tokens/create_token?type=pii).
sig { returns(T.nilable(String)) }
attr_accessor :id_number
# The government-issued secondary ID number of the individual, as appropriate for the representative's country, will be used for enhanced verification checks. In Thailand, this would be the laser code found on the back of an ID card. Instead of the number itself, you can also provide a [PII token created with Stripe.js](/js/tokens/create_token?type=pii).
sig { returns(T.nilable(String)) }
attr_accessor :id_number_secondary
# The individual's last name.
sig { returns(T.nilable(String)) }
attr_accessor :last_name
# The Kana variation of the individual's last name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :last_name_kana
# The Kanji variation of the individual's last name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :last_name_kanji
# The individual's maiden name.
sig { returns(T.nilable(String)) }
attr_accessor :maiden_name
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# The individual's phone number.
sig { returns(T.nilable(String)) }
attr_accessor :phone
# Indicates if the person or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction.
sig { returns(T.nilable(String)) }
attr_accessor :political_exposure
# The individual's registered address.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Individual::RegisteredAddress))
}
attr_accessor :registered_address
# Describes the person’s relationship to the account.
sig { returns(T.nilable(::Stripe::AccountService::CreateParams::Individual::Relationship)) }
attr_accessor :relationship
# The last four digits of the individual's Social Security Number (U.S. only).
sig { returns(T.nilable(String)) }
attr_accessor :ssn_last_4
# The individual's verification document information.
sig { returns(T.nilable(::Stripe::AccountService::CreateParams::Individual::Verification)) }
attr_accessor :verification
sig {
params(address: T.nilable(::Stripe::AccountService::CreateParams::Individual::Address), address_kana: T.nilable(::Stripe::AccountService::CreateParams::Individual::AddressKana), address_kanji: T.nilable(::Stripe::AccountService::CreateParams::Individual::AddressKanji), dob: T.nilable(T.nilable(T.any(String, ::Stripe::AccountService::CreateParams::Individual::Dob))), email: T.nilable(String), first_name: T.nilable(String), first_name_kana: T.nilable(String), first_name_kanji: T.nilable(String), full_name_aliases: T.nilable(T.nilable(T.any(String, T::Array[String]))), gender: T.nilable(String), id_number: T.nilable(String), id_number_secondary: T.nilable(String), last_name: T.nilable(String), last_name_kana: T.nilable(String), last_name_kanji: T.nilable(String), maiden_name: T.nilable(String), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), phone: T.nilable(String), political_exposure: T.nilable(String), registered_address: T.nilable(::Stripe::AccountService::CreateParams::Individual::RegisteredAddress), relationship: T.nilable(::Stripe::AccountService::CreateParams::Individual::Relationship), ssn_last_4: T.nilable(String), verification: T.nilable(::Stripe::AccountService::CreateParams::Individual::Verification)).void
}
def initialize(
address: nil,
address_kana: nil,
address_kanji: nil,
dob: nil,
email: nil,
first_name: nil,
first_name_kana: nil,
first_name_kanji: nil,
full_name_aliases: nil,
gender: nil,
id_number: nil,
id_number_secondary: nil,
last_name: nil,
last_name_kana: nil,
last_name_kanji: nil,
maiden_name: nil,
metadata: nil,
phone: nil,
political_exposure: nil,
registered_address: nil,
relationship: nil,
ssn_last_4: nil,
verification: nil
); end
end
class RiskControls < Stripe::RequestParams
class Charges < Stripe::RequestParams
# To request to pause a risk control, pass `true`. To request to unpause a risk control, pass `false`.
# There can be a delay before the risk control is paused or unpaused.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :pause_requested
sig { params(pause_requested: T.nilable(T::Boolean)).void }
def initialize(pause_requested: nil); end
end
class Payouts < Stripe::RequestParams
# To request to pause a risk control, pass `true`. To request to unpause a risk control, pass `false`.
# There can be a delay before the risk control is paused or unpaused.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :pause_requested
sig { params(pause_requested: T.nilable(T::Boolean)).void }
def initialize(pause_requested: nil); end
end
# Represents the risk control status of charges. Please see [this page for more details](https://stripe.com/docs/connect/pausing-payments-or-payouts-on-connected-accounts).
sig { returns(T.nilable(::Stripe::AccountService::CreateParams::RiskControls::Charges)) }
attr_accessor :charges
# Represents the risk control status of payouts. Please see [this page for more details](https://stripe.com/docs/connect/pausing-payments-or-payouts-on-connected-accounts).
sig { returns(T.nilable(::Stripe::AccountService::CreateParams::RiskControls::Payouts)) }
attr_accessor :payouts
sig {
params(charges: T.nilable(::Stripe::AccountService::CreateParams::RiskControls::Charges), payouts: T.nilable(::Stripe::AccountService::CreateParams::RiskControls::Payouts)).void
}
def initialize(charges: nil, payouts: nil); end
end
class Settings < Stripe::RequestParams
class BacsDebitPayments < Stripe::RequestParams
# The Bacs Direct Debit Display Name for this account. For payments made with Bacs Direct Debit, this name appears on the mandate as the statement descriptor. Mobile banking apps display it as the name of the business. To use custom branding, set the Bacs Direct Debit Display Name during or right after creation. Custom branding incurs an additional monthly fee for the platform. If you don't set the display name before requesting Bacs capability, it's automatically set as "Stripe" and the account is onboarded to Stripe branding, which is free.
sig { returns(T.nilable(String)) }
attr_accessor :display_name
sig { params(display_name: T.nilable(String)).void }
def initialize(display_name: nil); end
end
class BankBcaOnboarding < Stripe::RequestParams
# Bank BCA business account holder name
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_name
# Bank BCA business account number
sig { returns(T.nilable(String)) }
attr_accessor :business_account_number
sig {
params(account_holder_name: T.nilable(String), business_account_number: T.nilable(String)).void
}
def initialize(account_holder_name: nil, business_account_number: nil); end
end
class Branding < Stripe::RequestParams
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) An icon for the account. Must be square and at least 128px x 128px.
sig { returns(T.nilable(String)) }
attr_accessor :icon
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) A logo for the account that will be used in Checkout instead of the icon and without the account's name next to it if provided. Must be at least 128px x 128px.
sig { returns(T.nilable(String)) }
attr_accessor :logo
# A CSS hex color value representing the primary branding color for this account.
sig { returns(T.nilable(String)) }
attr_accessor :primary_color
# A CSS hex color value representing the secondary branding color for this account.
sig { returns(T.nilable(String)) }
attr_accessor :secondary_color
sig {
params(icon: T.nilable(String), logo: T.nilable(String), primary_color: T.nilable(String), secondary_color: T.nilable(String)).void
}
def initialize(icon: nil, logo: nil, primary_color: nil, secondary_color: nil); end
end
class Capital < Stripe::RequestParams
# Per-currency mapping of user-selected destination accounts used to pay out loans.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :payout_destination
# Per-currency mapping of all destination accounts eligible to receive Capital financing payouts.
sig { returns(T.nilable(T::Hash[String, T::Array[String]])) }
attr_accessor :payout_destination_selector
sig {
params(payout_destination: T.nilable(T::Hash[String, String]), payout_destination_selector: T.nilable(T::Hash[String, T::Array[String]])).void
}
def initialize(payout_destination: nil, payout_destination_selector: nil); end
end
class CardIssuing < Stripe::RequestParams
class TosAcceptance < Stripe::RequestParams
# The Unix timestamp marking when the account representative accepted the service agreement.
sig { returns(T.nilable(Integer)) }
attr_accessor :date
# The IP address from which the account representative accepted the service agreement.
sig { returns(T.nilable(String)) }
attr_accessor :ip
# The user agent of the browser from which the account representative accepted the service agreement.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :user_agent
sig {
params(date: T.nilable(Integer), ip: T.nilable(String), user_agent: T.nilable(T.nilable(String))).void
}
def initialize(date: nil, ip: nil, user_agent: nil); end
end
# Details on the account's acceptance of the [Stripe Issuing Terms and Disclosures](/issuing/connect/tos_acceptance).
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Settings::CardIssuing::TosAcceptance))
}
attr_accessor :tos_acceptance
sig {
params(tos_acceptance: T.nilable(::Stripe::AccountService::CreateParams::Settings::CardIssuing::TosAcceptance)).void
}
def initialize(tos_acceptance: nil); end
end
class CardPayments < Stripe::RequestParams
class DeclineOn < Stripe::RequestParams
# Whether Stripe automatically declines charges with an incorrect ZIP or postal code. This setting only applies when a ZIP or postal code is provided and they fail bank verification.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :avs_failure
# Whether Stripe automatically declines charges with an incorrect CVC. This setting only applies when a CVC is provided and it fails bank verification.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :cvc_failure
sig {
params(avs_failure: T.nilable(T::Boolean), cvc_failure: T.nilable(T::Boolean)).void
}
def initialize(avs_failure: nil, cvc_failure: nil); end
end
# Automatically declines certain charge types regardless of whether the card issuer accepted or declined the charge.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Settings::CardPayments::DeclineOn))
}
attr_accessor :decline_on
# The default text that appears on credit card statements when a charge is made. This field prefixes any dynamic `statement_descriptor` specified on the charge. `statement_descriptor_prefix` is useful for maximizing descriptor space for the dynamic portion.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor_prefix
# The Kana variation of the default text that appears on credit card statements when a charge is made (Japan only). This field prefixes any dynamic `statement_descriptor_suffix_kana` specified on the charge. `statement_descriptor_prefix_kana` is useful for maximizing descriptor space for the dynamic portion.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :statement_descriptor_prefix_kana
# The Kanji variation of the default text that appears on credit card statements when a charge is made (Japan only). This field prefixes any dynamic `statement_descriptor_suffix_kanji` specified on the charge. `statement_descriptor_prefix_kanji` is useful for maximizing descriptor space for the dynamic portion.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :statement_descriptor_prefix_kanji
sig {
params(decline_on: T.nilable(::Stripe::AccountService::CreateParams::Settings::CardPayments::DeclineOn), statement_descriptor_prefix: T.nilable(String), statement_descriptor_prefix_kana: T.nilable(T.nilable(String)), statement_descriptor_prefix_kanji: T.nilable(T.nilable(String))).void
}
def initialize(
decline_on: nil,
statement_descriptor_prefix: nil,
statement_descriptor_prefix_kana: nil,
statement_descriptor_prefix_kanji: nil
); end
end
class Invoices < Stripe::RequestParams
# Whether payment methods should be saved when a payment is completed for a one-time invoices on a hosted invoice page.
sig { returns(T.nilable(String)) }
attr_accessor :hosted_payment_method_save
sig { params(hosted_payment_method_save: T.nilable(String)).void }
def initialize(hosted_payment_method_save: nil); end
end
class Payments < Stripe::RequestParams
# The default text that appears on statements for non-card charges outside of Japan. For card charges, if you don't set a `statement_descriptor_prefix`, this text is also used as the statement descriptor prefix. In that case, if concatenating the statement descriptor suffix causes the combined statement descriptor to exceed 22 characters, we truncate the `statement_descriptor` text to limit the full descriptor to 22 characters. For more information about statement descriptors and their requirements, see the [account settings documentation](https://docs.stripe.com/get-started/account/statement-descriptors).
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
# The Kana variation of `statement_descriptor` used for charges in Japan. Japanese statement descriptors have [special requirements](https://docs.stripe.com/get-started/account/statement-descriptors#set-japanese-statement-descriptors).
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor_kana
# The Kanji variation of `statement_descriptor` used for charges in Japan. Japanese statement descriptors have [special requirements](https://docs.stripe.com/get-started/account/statement-descriptors#set-japanese-statement-descriptors).
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor_kanji
sig {
params(statement_descriptor: T.nilable(String), statement_descriptor_kana: T.nilable(String), statement_descriptor_kanji: T.nilable(String)).void
}
def initialize(
statement_descriptor: nil,
statement_descriptor_kana: nil,
statement_descriptor_kanji: nil
); end
end
class Payouts < Stripe::RequestParams
class Schedule < Stripe::RequestParams
# The number of days charge funds are held before being paid out. May also be set to `minimum`, representing the lowest available value for the account country. Default is `minimum`. The `delay_days` parameter remains at the last configured value if `interval` is `manual`. [Learn more about controlling payout delay days](/connect/manage-payout-schedule).
sig { returns(T.nilable(T.any(String, Integer))) }
attr_accessor :delay_days
# How frequently available funds are paid out. One of: `daily`, `manual`, `weekly`, or `monthly`. Default is `daily`.
sig { returns(T.nilable(String)) }
attr_accessor :interval
# The day of the month when available funds are paid out, specified as a number between 1--31. Payouts nominally scheduled between the 29th and 31st of the month are instead sent on the last day of a shorter month. Required and applicable only if `interval` is `monthly`.
sig { returns(T.nilable(Integer)) }
attr_accessor :monthly_anchor
# The day of the week when available funds are paid out, specified as `monday`, `tuesday`, etc. (required and applicable only if `interval` is `weekly`.)
sig { returns(T.nilable(String)) }
attr_accessor :weekly_anchor
sig {
params(delay_days: T.nilable(T.any(String, Integer)), interval: T.nilable(String), monthly_anchor: T.nilable(Integer), weekly_anchor: T.nilable(String)).void
}
def initialize(
delay_days: nil,
interval: nil,
monthly_anchor: nil,
weekly_anchor: nil
); end
end
# A Boolean indicating whether Stripe should try to reclaim negative balances from an attached bank account. For details, see [Understanding Connect Account Balances](/connect/account-balances).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :debit_negative_balances
# Details on when funds from charges are available, and when they are paid out to an external account. For details, see our [Setting Bank and Debit Card Payouts](/connect/bank-transfers#payout-information) documentation.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Settings::Payouts::Schedule))
}
attr_accessor :schedule
# The text that appears on the bank account statement for payouts. If not set, this defaults to the platform's bank descriptor as set in the Dashboard.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
sig {
params(debit_negative_balances: T.nilable(T::Boolean), schedule: T.nilable(::Stripe::AccountService::CreateParams::Settings::Payouts::Schedule), statement_descriptor: T.nilable(String)).void
}
def initialize(
debit_negative_balances: nil,
schedule: nil,
statement_descriptor: nil
); end
end
class TaxForms < Stripe::RequestParams
# Whether the account opted out of receiving their tax forms by postal delivery.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :consented_to_paperless_delivery
sig { params(consented_to_paperless_delivery: T.nilable(T::Boolean)).void }
def initialize(consented_to_paperless_delivery: nil); end
end
class Treasury < Stripe::RequestParams
class TosAcceptance < Stripe::RequestParams
# The Unix timestamp marking when the account representative accepted the service agreement.
sig { returns(T.nilable(Integer)) }
attr_accessor :date
# The IP address from which the account representative accepted the service agreement.
sig { returns(T.nilable(String)) }
attr_accessor :ip
# The user agent of the browser from which the account representative accepted the service agreement.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :user_agent
sig {
params(date: T.nilable(Integer), ip: T.nilable(String), user_agent: T.nilable(T.nilable(String))).void
}
def initialize(date: nil, ip: nil, user_agent: nil); end
end
# Details on the account's acceptance of the Stripe Treasury Services Agreement.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Settings::Treasury::TosAcceptance))
}
attr_accessor :tos_acceptance
sig {
params(tos_acceptance: T.nilable(::Stripe::AccountService::CreateParams::Settings::Treasury::TosAcceptance)).void
}
def initialize(tos_acceptance: nil); end
end
# Settings specific to Bacs Direct Debit.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Settings::BacsDebitPayments))
}
attr_accessor :bacs_debit_payments
# Settings specific to bank BCA onboarding for Indonesia bank transfers payments method.
sig {
returns(T.nilable(::Stripe::AccountService::CreateParams::Settings::BankBcaOnboarding))
}
attr_accessor :bank_bca_onboarding
# Settings used to apply the account's branding to email receipts, invoices, Checkout, and other products.
sig { returns(T.nilable(::Stripe::AccountService::CreateParams::Settings::Branding)) }
attr_accessor :branding
# Settings specific to the account's use of the Capital product.
sig { returns(T.nilable(::Stripe::AccountService::CreateParams::Settings::Capital)) }
attr_accessor :capital
# Settings specific to the account's use of the Card Issuing product.
sig { returns(T.nilable(::Stripe::AccountService::CreateParams::Settings::CardIssuing)) }
attr_accessor :card_issuing
# Settings specific to card charging on the account.
sig { returns(T.nilable(::Stripe::AccountService::CreateParams::Settings::CardPayments)) }
attr_accessor :card_payments
# Settings specific to the account’s use of Invoices.
sig { returns(T.nilable(::Stripe::AccountService::CreateParams::Settings::Invoices)) }
attr_accessor :invoices
# Settings that apply across payment methods for charging on the account.
sig { returns(T.nilable(::Stripe::AccountService::CreateParams::Settings::Payments)) }
attr_accessor :payments
# Settings specific to the account's payouts.
sig { returns(T.nilable(::Stripe::AccountService::CreateParams::Settings::Payouts)) }
attr_accessor :payouts
# Settings specific to the account's tax forms.
sig { returns(T.nilable(::Stripe::AccountService::CreateParams::Settings::TaxForms)) }
attr_accessor :tax_forms
# Settings specific to the account's Treasury FinancialAccounts.
sig { returns(T.nilable(::Stripe::AccountService::CreateParams::Settings::Treasury)) }
attr_accessor :treasury
sig {
params(bacs_debit_payments: T.nilable(::Stripe::AccountService::CreateParams::Settings::BacsDebitPayments), bank_bca_onboarding: T.nilable(::Stripe::AccountService::CreateParams::Settings::BankBcaOnboarding), branding: T.nilable(::Stripe::AccountService::CreateParams::Settings::Branding), capital: T.nilable(::Stripe::AccountService::CreateParams::Settings::Capital), card_issuing: T.nilable(::Stripe::AccountService::CreateParams::Settings::CardIssuing), card_payments: T.nilable(::Stripe::AccountService::CreateParams::Settings::CardPayments), invoices: T.nilable(::Stripe::AccountService::CreateParams::Settings::Invoices), payments: T.nilable(::Stripe::AccountService::CreateParams::Settings::Payments), payouts: T.nilable(::Stripe::AccountService::CreateParams::Settings::Payouts), tax_forms: T.nilable(::Stripe::AccountService::CreateParams::Settings::TaxForms), treasury: T.nilable(::Stripe::AccountService::CreateParams::Settings::Treasury)).void
}
def initialize(
bacs_debit_payments: nil,
bank_bca_onboarding: nil,
branding: nil,
capital: nil,
card_issuing: nil,
card_payments: nil,
invoices: nil,
payments: nil,
payouts: nil,
tax_forms: nil,
treasury: nil
); end
end
class TosAcceptance < Stripe::RequestParams
# The Unix timestamp marking when the account representative accepted their service agreement.
sig { returns(T.nilable(Integer)) }
attr_accessor :date
# The IP address from which the account representative accepted their service agreement.
sig { returns(T.nilable(String)) }
attr_accessor :ip
# The user's service agreement type.
sig { returns(T.nilable(String)) }
attr_accessor :service_agreement
# The user agent of the browser from which the account representative accepted their service agreement.
sig { returns(T.nilable(String)) }
attr_accessor :user_agent
sig {
params(date: T.nilable(Integer), ip: T.nilable(String), service_agreement: T.nilable(String), user_agent: T.nilable(String)).void
}
def initialize(date: nil, ip: nil, service_agreement: nil, user_agent: nil); end
end
# An [account token](https://stripe.com/docs/api#create_account_token), used to securely provide details to the account.
sig { returns(T.nilable(String)) }
attr_accessor :account_token
# Business information about the account.
sig { returns(T.nilable(::Stripe::AccountService::CreateParams::BusinessProfile)) }
attr_accessor :business_profile
# The business type. Once you create an [Account Link](/api/account_links) or [Account Session](/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.
sig { returns(T.nilable(String)) }
attr_accessor :business_type
# Each key of the dictionary represents a capability, and each capability
# maps to its settings (for example, whether it has been requested or not). Each
# capability is inactive until you have provided its specific
# requirements and Stripe has verified them. An account might have some
# of its requested capabilities be active and some be inactive.
#
# Required when [account.controller.stripe_dashboard.type](/api/accounts/create#create_account-controller-dashboard-type)
# is `none`, which includes Custom accounts.
sig { returns(T.nilable(::Stripe::AccountService::CreateParams::Capabilities)) }
attr_accessor :capabilities
# Information about the company or business. This field is available for any `business_type`. Once you create an [Account Link](/api/account_links) or [Account Session](/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.
sig { returns(T.nilable(::Stripe::AccountService::CreateParams::Company)) }
attr_accessor :company
# A hash of configuration describing the account controller's attributes.
sig { returns(T.nilable(::Stripe::AccountService::CreateParams::Controller)) }
attr_accessor :controller
# The country in which the account holder resides, or in which the business is legally established. This should be an ISO 3166-1 alpha-2 country code. For example, if you are in the United States and the business for which you're creating an account is legally represented in Canada, you would use `CA` as the country for the account being created. Available countries include [Stripe's global markets](https://stripe.com/global) as well as countries where [cross-border payouts](https://stripe.com/docs/connect/cross-border-payouts) are supported.
sig { returns(T.nilable(String)) }
attr_accessor :country
# Three-letter ISO currency code representing the default currency for the account. This must be a currency that [Stripe supports in the account's country](https://docs.stripe.com/payouts).
sig { returns(T.nilable(String)) }
attr_accessor :default_currency
# Documents that may be submitted to satisfy various informational requests.
sig { returns(T.nilable(::Stripe::AccountService::CreateParams::Documents)) }
attr_accessor :documents
# The email address of the account holder. This is only to make the account easier to identify to you. If [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts, Stripe doesn't email the account without your consent.
sig { returns(T.nilable(String)) }
attr_accessor :email
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A card or bank account to attach to the account for receiving [payouts](/connect/bank-debit-card-payouts) (you won’t be able to use it for top-ups). You can provide either a token, like the ones returned by [Stripe.js](/js), or a dictionary, as documented in the `external_account` parameter for [bank account](/api#account_create_bank_account) creation.
By default, providing an external account sets it as the new default external account for its currency, and deletes the old default if one exists. To add additional external accounts without replacing the existing default for the currency, use the [bank account](/api#account_create_bank_account) or [card creation](/api#account_create_card) APIs. After you create an [Account Link](/api/account_links) or [Account Session](/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.
sig {
returns(T.nilable(T.any(String, ::Stripe::AccountService::CreateParams::BankAccount, ::Stripe::AccountService::CreateParams::Card, ::Stripe::AccountService::CreateParams::CardToken)))
}
attr_accessor :external_account
# A hash of account group type to tokens. These are account groups this account should be added to.
sig { returns(T.nilable(::Stripe::AccountService::CreateParams::Groups)) }
attr_accessor :groups
# Information about the person represented by the account. This field is null unless `business_type` is set to `individual`. Once you create an [Account Link](/api/account_links) or [Account Session](/api/account_sessions), this property can only be updated for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts.
sig { returns(T.nilable(::Stripe::AccountService::CreateParams::Individual)) }
attr_accessor :individual
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# A hash to configure risk controls on the account. Please see [this page for more details](/connect/pausing-payments-or-payouts-on-connected-accounts).
sig { returns(T.nilable(::Stripe::AccountService::CreateParams::RiskControls)) }
attr_accessor :risk_controls
# Options for customizing how the account functions within Stripe.
sig { returns(T.nilable(::Stripe::AccountService::CreateParams::Settings)) }
attr_accessor :settings
# Details on the account's acceptance of the [Stripe Services Agreement](/connect/updating-accounts#tos-acceptance). This property can only be updated for accounts where [controller.requirement_collection](/api/accounts/object#account_object-controller-requirement_collection) is `application`, which includes Custom accounts. This property defaults to a `full` service agreement when empty.
sig { returns(T.nilable(::Stripe::AccountService::CreateParams::TosAcceptance)) }
attr_accessor :tos_acceptance
# The type of Stripe account to create. May be one of `custom`, `express` or `standard`.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(account_token: T.nilable(String), business_profile: T.nilable(::Stripe::AccountService::CreateParams::BusinessProfile), business_type: T.nilable(String), capabilities: T.nilable(::Stripe::AccountService::CreateParams::Capabilities), company: T.nilable(::Stripe::AccountService::CreateParams::Company), controller: T.nilable(::Stripe::AccountService::CreateParams::Controller), country: T.nilable(String), default_currency: T.nilable(String), documents: T.nilable(::Stripe::AccountService::CreateParams::Documents), email: T.nilable(String), expand: T.nilable(T::Array[String]), external_account: T.nilable(T.any(String, ::Stripe::AccountService::CreateParams::BankAccount, ::Stripe::AccountService::CreateParams::Card, ::Stripe::AccountService::CreateParams::CardToken)), groups: T.nilable(::Stripe::AccountService::CreateParams::Groups), individual: T.nilable(::Stripe::AccountService::CreateParams::Individual), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), risk_controls: T.nilable(::Stripe::AccountService::CreateParams::RiskControls), settings: T.nilable(::Stripe::AccountService::CreateParams::Settings), tos_acceptance: T.nilable(::Stripe::AccountService::CreateParams::TosAcceptance), type: T.nilable(String)).void
}
def initialize(
account_token: nil,
business_profile: nil,
business_type: nil,
capabilities: nil,
company: nil,
controller: nil,
country: nil,
default_currency: nil,
documents: nil,
email: nil,
expand: nil,
external_account: nil,
groups: nil,
individual: nil,
metadata: nil,
risk_controls: nil,
settings: nil,
tos_acceptance: nil,
type: nil
); end
end
class RejectParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The reason for rejecting the account. Can be `fraud`, `terms_of_service`, or `other`.
sig { returns(String) }
attr_accessor :reason
sig { params(expand: T.nilable(T::Array[String]), reason: String).void }
def initialize(expand: nil, reason: nil); end
end
# With [Connect](https://docs.stripe.com/docs/connect), you can create Stripe accounts for your users.
# To do this, you'll first need to [register your platform](https://dashboard.stripe.com/account/applications/settings).
#
# If you've already collected information for your connected accounts, you [can prefill that information](https://docs.stripe.com/docs/connect/best-practices#onboarding) when
# creating the account. Connect Onboarding won't ask for the prefilled information during account onboarding.
# You can prefill any information on the account.
sig {
params(params: T.any(::Stripe::AccountService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Account)
}
def create(params = {}, opts = {}); end
# With [Connect](https://docs.stripe.com/connect), you can delete accounts you manage.
#
# Test-mode accounts can be deleted at any time.
#
# Live-mode accounts where Stripe is responsible for negative account balances cannot be deleted, which includes Standard accounts. Live-mode accounts where your platform is liable for negative account balances, which includes Custom and Express accounts, can be deleted when all [balances](https://docs.stripe.com/api/balance/balance_object) are zero.
#
# If you want to delete your own account, use the [account information tab in your account settings](https://dashboard.stripe.com/settings/account) instead.
sig {
params(account: String, params: T.any(::Stripe::AccountService::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Account)
}
def delete(account, params = {}, opts = {}); end
# Returns a list of accounts connected to your platform via [Connect](https://docs.stripe.com/docs/connect). If you're not a platform, the list is empty.
sig {
params(params: T.any(::Stripe::AccountService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# With [Connect](https://docs.stripe.com/connect), you can reject accounts that you have flagged as suspicious.
#
# Only accounts where your platform is liable for negative account balances, which includes Custom and Express accounts, can be rejected. Test-mode accounts can be rejected at any time. Live-mode accounts can only be rejected after all balances are zero.
sig {
params(account: String, params: T.any(::Stripe::AccountService::RejectParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Account)
}
def reject(account, params = {}, opts = {}); end
# Retrieves the details of an account.
sig {
params(account: String, params: T.any(::Stripe::AccountService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Account)
}
def retrieve(account, params = {}, opts = {}); end
# Retrieves the details of an account.
sig {
params(params: T.any(::Stripe::AccountService::RetrieveCurrentParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Account)
}
def retrieve_current(params = {}, opts = {}); end
# Updates a [connected account](https://docs.stripe.com/connect/accounts) by setting the values of the parameters passed. Any parameters not provided are
# left unchanged.
#
# For accounts where [controller.requirement_collection](https://docs.stripe.com/api/accounts/object#account_object-controller-requirement_collection)
# is application, which includes Custom accounts, you can update any information on the account.
#
# For accounts where [controller.requirement_collection](https://docs.stripe.com/api/accounts/object#account_object-controller-requirement_collection)
# is stripe, which includes Standard and Express accounts, you can update all information until you create
# an [Account Link or Account Session](https://docs.stripe.com/api/account_links) to start Connect onboarding,
# after which some properties can no longer be updated.
#
# To update your own account, use the [Dashboard](https://dashboard.stripe.com/settings/account). Refer to our
# [Connect](https://docs.stripe.com/docs/connect/updating-accounts) documentation to learn more about updating accounts.
sig {
params(account: String, params: T.any(::Stripe::AccountService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Account)
}
def update(account, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class AccountCapabilityService < StripeService
class ListParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# To request a new capability for an account, pass true. There can be a delay before the requested capability becomes active. If the capability has any activation requirements, the response includes them in the `requirements` arrays.
#
# If a capability isn't permanent, you can remove it from the account by passing false. Some capabilities are permanent after they've been requested. Attempting to remove a permanent capability returns an error.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(expand: T.nilable(T::Array[String]), requested: T.nilable(T::Boolean)).void }
def initialize(expand: nil, requested: nil); end
end
# Returns a list of capabilities associated with the account. The capabilities are returned sorted by creation date, with the most recent capability appearing first.
sig {
params(account: String, params: T.any(::Stripe::AccountCapabilityService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(account, params = {}, opts = {}); end
# Retrieves information about the specified Account Capability.
sig {
params(account: String, capability: String, params: T.any(::Stripe::AccountCapabilityService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Capability)
}
def retrieve(account, capability, params = {}, opts = {}); end
# Updates an existing Account Capability. Request or remove a capability by updating its requested parameter.
sig {
params(account: String, capability: String, params: T.any(::Stripe::AccountCapabilityService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Capability)
}
def update(account, capability, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class AccountExternalAccountService < StripeService
class DeleteParams < Stripe::RequestParams; end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
class Documents < Stripe::RequestParams
class BankAccountOwnershipVerification < Stripe::RequestParams
# One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :files
sig { params(files: T.nilable(T::Array[String])).void }
def initialize(files: nil); end
end
# One or more documents that support the [Bank account ownership verification](https://support.stripe.com/questions/bank-account-ownership-verification) requirement. Must be a document associated with the bank account that displays the last 4 digits of the account number, either a statement or a check.
sig {
returns(T.nilable(::Stripe::AccountExternalAccountService::UpdateParams::Documents::BankAccountOwnershipVerification))
}
attr_accessor :bank_account_ownership_verification
sig {
params(bank_account_ownership_verification: T.nilable(::Stripe::AccountExternalAccountService::UpdateParams::Documents::BankAccountOwnershipVerification)).void
}
def initialize(bank_account_ownership_verification: nil); end
end
# The name of the person or business that owns the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_name
# The type of entity that holds the account. This can be either `individual` or `company`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :account_holder_type
# The bank account type. This can only be `checking` or `savings` in most countries. In Japan, this can only be `futsu` or `toza`.
sig { returns(T.nilable(String)) }
attr_accessor :account_type
# City/District/Suburb/Town/Village.
sig { returns(T.nilable(String)) }
attr_accessor :address_city
# Billing address country, if provided when creating card.
sig { returns(T.nilable(String)) }
attr_accessor :address_country
# Address line 1 (Street address/PO Box/Company name).
sig { returns(T.nilable(String)) }
attr_accessor :address_line1
# Address line 2 (Apartment/Suite/Unit/Building).
sig { returns(T.nilable(String)) }
attr_accessor :address_line2
# State/County/Province/Region.
sig { returns(T.nilable(String)) }
attr_accessor :address_state
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :address_zip
# When set to true, this becomes the default external account for its currency.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :default_for_currency
# Documents that may be submitted to satisfy various informational requests.
sig { returns(T.nilable(::Stripe::AccountExternalAccountService::UpdateParams::Documents)) }
attr_accessor :documents
# Two digit number representing the card’s expiration month.
sig { returns(T.nilable(String)) }
attr_accessor :exp_month
# Four digit number representing the card’s expiration year.
sig { returns(T.nilable(String)) }
attr_accessor :exp_year
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Cardholder name.
sig { returns(T.nilable(String)) }
attr_accessor :name
sig {
params(account_holder_name: T.nilable(String), account_holder_type: T.nilable(T.nilable(T.any(String, String))), account_type: T.nilable(String), address_city: T.nilable(String), address_country: T.nilable(String), address_line1: T.nilable(String), address_line2: T.nilable(String), address_state: T.nilable(String), address_zip: T.nilable(String), default_for_currency: T.nilable(T::Boolean), documents: T.nilable(::Stripe::AccountExternalAccountService::UpdateParams::Documents), exp_month: T.nilable(String), exp_year: T.nilable(String), expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), name: T.nilable(String)).void
}
def initialize(
account_holder_name: nil,
account_holder_type: nil,
account_type: nil,
address_city: nil,
address_country: nil,
address_line1: nil,
address_line2: nil,
address_state: nil,
address_zip: nil,
default_for_currency: nil,
documents: nil,
exp_month: nil,
exp_year: nil,
expand: nil,
metadata: nil,
name: nil
); end
end
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Filter external accounts according to a particular object type.
sig { returns(T.nilable(String)) }
attr_accessor :object
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), object: T.nilable(String), starting_after: T.nilable(String)).void
}
def initialize(
ending_before: nil,
expand: nil,
limit: nil,
object: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class BankAccount < Stripe::RequestParams
# Attribute for param field object
sig { returns(String) }
attr_accessor :object
# The name of the person or business that owns the bank account.This field is required when attaching the bank account to a `Customer` object.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_name
# The type of entity that holds the account. It can be `company` or `individual`. This field is required when attaching the bank account to a `Customer` object.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_type
# The account number for the bank account, in string form. Must be a checking account.
sig { returns(String) }
attr_accessor :account_number
# The country in which the bank account is located.
sig { returns(String) }
attr_accessor :country
# The currency the bank account is in. This must be a country/currency pairing that [Stripe supports.](docs/payouts)
sig { returns(T.nilable(String)) }
attr_accessor :currency
# The routing number, sort code, or other country-appropriate institution number for the bank account. For US bank accounts, this is required and should be the ACH routing number, not the wire routing number. If you are providing an IBAN for `account_number`, this field is not required.
sig { returns(T.nilable(String)) }
attr_accessor :routing_number
sig {
params(object: String, account_holder_name: T.nilable(String), account_holder_type: T.nilable(String), account_number: String, country: String, currency: T.nilable(String), routing_number: T.nilable(String)).void
}
def initialize(
object: nil,
account_holder_name: nil,
account_holder_type: nil,
account_number: nil,
country: nil,
currency: nil,
routing_number: nil
); end
end
class Card < Stripe::RequestParams
# Attribute for param field object
sig { returns(String) }
attr_accessor :object
# Attribute for param field address_city
sig { returns(T.nilable(String)) }
attr_accessor :address_city
# Attribute for param field address_country
sig { returns(T.nilable(String)) }
attr_accessor :address_country
# Attribute for param field address_line1
sig { returns(T.nilable(String)) }
attr_accessor :address_line1
# Attribute for param field address_line2
sig { returns(T.nilable(String)) }
attr_accessor :address_line2
# Attribute for param field address_state
sig { returns(T.nilable(String)) }
attr_accessor :address_state
# Attribute for param field address_zip
sig { returns(T.nilable(String)) }
attr_accessor :address_zip
# Attribute for param field currency
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Attribute for param field cvc
sig { returns(T.nilable(String)) }
attr_accessor :cvc
# Attribute for param field exp_month
sig { returns(Integer) }
attr_accessor :exp_month
# Attribute for param field exp_year
sig { returns(Integer) }
attr_accessor :exp_year
# Attribute for param field name
sig { returns(T.nilable(String)) }
attr_accessor :name
# Attribute for param field number
sig { returns(String) }
attr_accessor :number
# 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.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
sig {
params(object: String, address_city: T.nilable(String), address_country: T.nilable(String), address_line1: T.nilable(String), address_line2: T.nilable(String), address_state: T.nilable(String), address_zip: T.nilable(String), currency: T.nilable(String), cvc: T.nilable(String), exp_month: Integer, exp_year: Integer, name: T.nilable(String), number: String, metadata: T.nilable(T::Hash[String, String])).void
}
def initialize(
object: nil,
address_city: nil,
address_country: nil,
address_line1: nil,
address_line2: nil,
address_state: nil,
address_zip: nil,
currency: nil,
cvc: nil,
exp_month: nil,
exp_year: nil,
name: nil,
number: nil,
metadata: nil
); end
end
class CardToken < Stripe::RequestParams
# Attribute for param field object
sig { returns(String) }
attr_accessor :object
# Attribute for param field currency
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Attribute for param field token
sig { returns(String) }
attr_accessor :token
sig { params(object: String, currency: T.nilable(String), token: String).void }
def initialize(object: nil, currency: nil, token: nil); end
end
# When set to true, or if this is the first external account added in this currency, this account becomes the default external account for its currency.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :default_for_currency
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A token, like the ones returned by [Stripe.js](https://stripe.com/docs/js) or a dictionary containing a user's external account details (with the options shown below). Please refer to full [documentation](https://stripe.com/docs/api/external_accounts) instead.
sig {
returns(T.any(String, ::Stripe::AccountExternalAccountService::CreateParams::Card, ::Stripe::AccountExternalAccountService::CreateParams::BankAccount, ::Stripe::AccountExternalAccountService::CreateParams::CardToken))
}
attr_accessor :external_account
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
sig {
params(default_for_currency: T.nilable(T::Boolean), expand: T.nilable(T::Array[String]), external_account: T.any(String, ::Stripe::AccountExternalAccountService::CreateParams::Card, ::Stripe::AccountExternalAccountService::CreateParams::BankAccount, ::Stripe::AccountExternalAccountService::CreateParams::CardToken), metadata: T.nilable(T::Hash[String, String])).void
}
def initialize(
default_for_currency: nil,
expand: nil,
external_account: nil,
metadata: nil
); end
end
# Create an external account for a given account.
sig {
params(account: String, params: T.any(::Stripe::AccountExternalAccountService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(T.any(Stripe::BankAccount, Stripe::Card))
}
def create(account, params = {}, opts = {}); end
# Delete a specified external account for a given account.
sig {
params(account: String, id: String, params: T.any(::Stripe::AccountExternalAccountService::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(T.any(Stripe::BankAccount, Stripe::Card))
}
def delete(account, id, params = {}, opts = {}); end
# List external accounts for an account.
sig {
params(account: String, params: T.any(::Stripe::AccountExternalAccountService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(account, params = {}, opts = {}); end
# Retrieve a specified external account for a given account.
sig {
params(account: String, id: String, params: T.any(::Stripe::AccountExternalAccountService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(T.any(Stripe::BankAccount, Stripe::Card))
}
def retrieve(account, id, params = {}, opts = {}); end
# Updates the metadata, account holder name, account holder type of a bank account belonging to
# a connected account and optionally sets it as the default for its currency. Other bank account
# details are not editable by design.
#
# You can only update bank accounts when [account.controller.requirement_collection is application, which includes Custom accounts](https://docs.stripe.com/api/accounts/object#account_object-controller-requirement_collection).
#
# You can re-enable a disabled bank account by performing an update call without providing any
# arguments or changes.
sig {
params(account: String, id: String, params: T.any(::Stripe::AccountExternalAccountService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(T.any(Stripe::BankAccount, Stripe::Card))
}
def update(account, id, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class AccountLoginLinkService < StripeService
class CreateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Creates a login link for a connected account to access the Express Dashboard.
#
# You can only create login links for accounts that use the [Express Dashboard](https://docs.stripe.com/connect/express-dashboard) and are connected to your platform.
sig {
params(account: String, params: T.any(::Stripe::AccountLoginLinkService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::LoginLink)
}
def create(account, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class AccountPersonService < StripeService
class DeleteParams < Stripe::RequestParams; end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
class AdditionalTosAcceptances < Stripe::RequestParams
class Account < Stripe::RequestParams
# The Unix timestamp marking when the account representative accepted the service agreement.
sig { returns(T.nilable(Integer)) }
attr_accessor :date
# The IP address from which the account representative accepted the service agreement.
sig { returns(T.nilable(String)) }
attr_accessor :ip
# The user agent of the browser from which the account representative accepted the service agreement.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :user_agent
sig {
params(date: T.nilable(Integer), ip: T.nilable(String), user_agent: T.nilable(T.nilable(String))).void
}
def initialize(date: nil, ip: nil, user_agent: nil); end
end
# Details on the legal guardian's acceptance of the main Stripe service agreement.
sig {
returns(T.nilable(::Stripe::AccountPersonService::UpdateParams::AdditionalTosAcceptances::Account))
}
attr_accessor :account
sig {
params(account: T.nilable(::Stripe::AccountPersonService::UpdateParams::AdditionalTosAcceptances::Account)).void
}
def initialize(account: nil); end
end
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class AddressKana < Stripe::RequestParams
# City or ward.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Block or building number.
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Building details.
sig { returns(T.nilable(String)) }
attr_accessor :line2
# Postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# Prefecture.
sig { returns(T.nilable(String)) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_accessor :town
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), town: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
class AddressKanji < Stripe::RequestParams
# City or ward.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Block or building number.
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Building details.
sig { returns(T.nilable(String)) }
attr_accessor :line2
# Postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# Prefecture.
sig { returns(T.nilable(String)) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_accessor :town
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), town: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
class Dob < Stripe::RequestParams
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
class Documents < Stripe::RequestParams
class CompanyAuthorization < Stripe::RequestParams
# One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :files
sig { params(files: T.nilable(T::Array[String])).void }
def initialize(files: nil); end
end
class Passport < Stripe::RequestParams
# One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :files
sig { params(files: T.nilable(T::Array[String])).void }
def initialize(files: nil); end
end
class Visa < Stripe::RequestParams
# One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :files
sig { params(files: T.nilable(T::Array[String])).void }
def initialize(files: nil); end
end
# One or more documents that demonstrate proof that this person is authorized to represent the company.
sig {
returns(T.nilable(::Stripe::AccountPersonService::UpdateParams::Documents::CompanyAuthorization))
}
attr_accessor :company_authorization
# One or more documents showing the person's passport page with photo and personal data.
sig {
returns(T.nilable(::Stripe::AccountPersonService::UpdateParams::Documents::Passport))
}
attr_accessor :passport
# One or more documents showing the person's visa required for living in the country where they are residing.
sig { returns(T.nilable(::Stripe::AccountPersonService::UpdateParams::Documents::Visa)) }
attr_accessor :visa
sig {
params(company_authorization: T.nilable(::Stripe::AccountPersonService::UpdateParams::Documents::CompanyAuthorization), passport: T.nilable(::Stripe::AccountPersonService::UpdateParams::Documents::Passport), visa: T.nilable(::Stripe::AccountPersonService::UpdateParams::Documents::Visa)).void
}
def initialize(company_authorization: nil, passport: nil, visa: nil); end
end
class RegisteredAddress < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class Relationship < Stripe::RequestParams
# Whether the person is the authorizer of the account's representative.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :authorizer
# Whether the person is a director of the account's legal entity. Directors are typically members of the governing board of the company, or responsible for ensuring the company meets its regulatory obligations.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :director
# Whether the person has significant responsibility to control, manage, or direct the organization.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :executive
# Whether the person is the legal guardian of the account's representative.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :legal_guardian
# Whether the person is an owner of the account’s legal entity.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :owner
# The percent owned by the person of the account's legal entity.
sig { returns(T.nilable(T.nilable(T.any(String, Float)))) }
attr_accessor :percent_ownership
# Whether the person is authorized as the primary representative of the account. This is the person nominated by the business to provide information about themselves, and general information about the account. There can only be one representative at any given time. At the time the account is created, this person should be set to the person responsible for opening the account.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :representative
# The person's title (e.g., CEO, Support Engineer).
sig { returns(T.nilable(String)) }
attr_accessor :title
sig {
params(authorizer: T.nilable(T::Boolean), director: T.nilable(T::Boolean), executive: T.nilable(T::Boolean), legal_guardian: T.nilable(T::Boolean), owner: T.nilable(T::Boolean), percent_ownership: T.nilable(T.nilable(T.any(String, Float))), representative: T.nilable(T::Boolean), title: T.nilable(String)).void
}
def initialize(
authorizer: nil,
director: nil,
executive: nil,
legal_guardian: nil,
owner: nil,
percent_ownership: nil,
representative: nil,
title: nil
); end
end
class UsCfpbData < Stripe::RequestParams
class EthnicityDetails < Stripe::RequestParams
# The persons ethnicity
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :ethnicity
# Please specify your origin, when other is selected.
sig { returns(T.nilable(String)) }
attr_accessor :ethnicity_other
sig {
params(ethnicity: T.nilable(T::Array[String]), ethnicity_other: T.nilable(String)).void
}
def initialize(ethnicity: nil, ethnicity_other: nil); end
end
class RaceDetails < Stripe::RequestParams
# The persons race.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :race
# Please specify your race, when other is selected.
sig { returns(T.nilable(String)) }
attr_accessor :race_other
sig { params(race: T.nilable(T::Array[String]), race_other: T.nilable(String)).void }
def initialize(race: nil, race_other: nil); end
end
# The persons ethnicity details
sig {
returns(T.nilable(::Stripe::AccountPersonService::UpdateParams::UsCfpbData::EthnicityDetails))
}
attr_accessor :ethnicity_details
# The persons race details
sig {
returns(T.nilable(::Stripe::AccountPersonService::UpdateParams::UsCfpbData::RaceDetails))
}
attr_accessor :race_details
# The persons self-identified gender
sig { returns(T.nilable(String)) }
attr_accessor :self_identified_gender
sig {
params(ethnicity_details: T.nilable(::Stripe::AccountPersonService::UpdateParams::UsCfpbData::EthnicityDetails), race_details: T.nilable(::Stripe::AccountPersonService::UpdateParams::UsCfpbData::RaceDetails), self_identified_gender: T.nilable(String)).void
}
def initialize(ethnicity_details: nil, race_details: nil, self_identified_gender: nil); end
end
class Verification < Stripe::RequestParams
class AdditionalDocument < Stripe::RequestParams
# The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :back
# The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :front
sig { params(back: T.nilable(String), front: T.nilable(String)).void }
def initialize(back: nil, front: nil); end
end
class Document < Stripe::RequestParams
# The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :back
# The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :front
sig { params(back: T.nilable(String), front: T.nilable(String)).void }
def initialize(back: nil, front: nil); end
end
# A document showing address, either a passport, local ID card, or utility bill from a well-known utility company.
sig {
returns(T.nilable(::Stripe::AccountPersonService::UpdateParams::Verification::AdditionalDocument))
}
attr_accessor :additional_document
# An identifying document, either a passport or local ID card.
sig {
returns(T.nilable(::Stripe::AccountPersonService::UpdateParams::Verification::Document))
}
attr_accessor :document
sig {
params(additional_document: T.nilable(::Stripe::AccountPersonService::UpdateParams::Verification::AdditionalDocument), document: T.nilable(::Stripe::AccountPersonService::UpdateParams::Verification::Document)).void
}
def initialize(additional_document: nil, document: nil); end
end
# Details on the legal guardian's or authorizer's acceptance of the required Stripe agreements.
sig {
returns(T.nilable(::Stripe::AccountPersonService::UpdateParams::AdditionalTosAcceptances))
}
attr_accessor :additional_tos_acceptances
# The person's address.
sig { returns(T.nilable(::Stripe::AccountPersonService::UpdateParams::Address)) }
attr_accessor :address
# The Kana variation of the person's address (Japan only).
sig { returns(T.nilable(::Stripe::AccountPersonService::UpdateParams::AddressKana)) }
attr_accessor :address_kana
# The Kanji variation of the person's address (Japan only).
sig { returns(T.nilable(::Stripe::AccountPersonService::UpdateParams::AddressKanji)) }
attr_accessor :address_kanji
# The person's date of birth.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::AccountPersonService::UpdateParams::Dob))))
}
attr_accessor :dob
# Documents that may be submitted to satisfy various informational requests.
sig { returns(T.nilable(::Stripe::AccountPersonService::UpdateParams::Documents)) }
attr_accessor :documents
# The person's email address.
sig { returns(T.nilable(String)) }
attr_accessor :email
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The person's first name.
sig { returns(T.nilable(String)) }
attr_accessor :first_name
# The Kana variation of the person's first name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :first_name_kana
# The Kanji variation of the person's first name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :first_name_kanji
# A list of alternate names or aliases that the person is known by.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :full_name_aliases
# The person's gender (International regulations require either "male" or "female").
sig { returns(T.nilable(String)) }
attr_accessor :gender
# The person's ID number, as appropriate for their country. For example, a social security number in the U.S., social insurance number in Canada, etc. Instead of the number itself, you can also provide a [PII token provided by Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).
sig { returns(T.nilable(String)) }
attr_accessor :id_number
# The person's secondary ID number, as appropriate for their country, will be used for enhanced verification checks. In Thailand, this would be the laser code found on the back of an ID card. Instead of the number itself, you can also provide a [PII token provided by Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).
sig { returns(T.nilable(String)) }
attr_accessor :id_number_secondary
# The person's last name.
sig { returns(T.nilable(String)) }
attr_accessor :last_name
# The Kana variation of the person's last name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :last_name_kana
# The Kanji variation of the person's last name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :last_name_kanji
# The person's maiden name.
sig { returns(T.nilable(String)) }
attr_accessor :maiden_name
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# The country where the person is a national. Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)), or "XX" if unavailable.
sig { returns(T.nilable(String)) }
attr_accessor :nationality
# A [person token](https://docs.stripe.com/connect/account-tokens), used to securely provide details to the person.
sig { returns(T.nilable(String)) }
attr_accessor :person_token
# The person's phone number.
sig { returns(T.nilable(String)) }
attr_accessor :phone
# Indicates if the person or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction.
sig { returns(T.nilable(String)) }
attr_accessor :political_exposure
# The person's registered address.
sig { returns(T.nilable(::Stripe::AccountPersonService::UpdateParams::RegisteredAddress)) }
attr_accessor :registered_address
# The relationship that this person has with the account's legal entity.
sig { returns(T.nilable(::Stripe::AccountPersonService::UpdateParams::Relationship)) }
attr_accessor :relationship
# The last four digits of the person's Social Security number (U.S. only).
sig { returns(T.nilable(String)) }
attr_accessor :ssn_last_4
# Demographic data related to the person.
sig { returns(T.nilable(::Stripe::AccountPersonService::UpdateParams::UsCfpbData)) }
attr_accessor :us_cfpb_data
# The person's verification status.
sig { returns(T.nilable(::Stripe::AccountPersonService::UpdateParams::Verification)) }
attr_accessor :verification
sig {
params(additional_tos_acceptances: T.nilable(::Stripe::AccountPersonService::UpdateParams::AdditionalTosAcceptances), address: T.nilable(::Stripe::AccountPersonService::UpdateParams::Address), address_kana: T.nilable(::Stripe::AccountPersonService::UpdateParams::AddressKana), address_kanji: T.nilable(::Stripe::AccountPersonService::UpdateParams::AddressKanji), dob: T.nilable(T.nilable(T.any(String, ::Stripe::AccountPersonService::UpdateParams::Dob))), documents: T.nilable(::Stripe::AccountPersonService::UpdateParams::Documents), email: T.nilable(String), expand: T.nilable(T::Array[String]), first_name: T.nilable(String), first_name_kana: T.nilable(String), first_name_kanji: T.nilable(String), full_name_aliases: T.nilable(T.nilable(T.any(String, T::Array[String]))), gender: T.nilable(String), id_number: T.nilable(String), id_number_secondary: T.nilable(String), last_name: T.nilable(String), last_name_kana: T.nilable(String), last_name_kanji: T.nilable(String), maiden_name: T.nilable(String), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), nationality: T.nilable(String), person_token: T.nilable(String), phone: T.nilable(String), political_exposure: T.nilable(String), registered_address: T.nilable(::Stripe::AccountPersonService::UpdateParams::RegisteredAddress), relationship: T.nilable(::Stripe::AccountPersonService::UpdateParams::Relationship), ssn_last_4: T.nilable(String), us_cfpb_data: T.nilable(::Stripe::AccountPersonService::UpdateParams::UsCfpbData), verification: T.nilable(::Stripe::AccountPersonService::UpdateParams::Verification)).void
}
def initialize(
additional_tos_acceptances: nil,
address: nil,
address_kana: nil,
address_kanji: nil,
dob: nil,
documents: nil,
email: nil,
expand: nil,
first_name: nil,
first_name_kana: nil,
first_name_kanji: nil,
full_name_aliases: nil,
gender: nil,
id_number: nil,
id_number_secondary: nil,
last_name: nil,
last_name_kana: nil,
last_name_kanji: nil,
maiden_name: nil,
metadata: nil,
nationality: nil,
person_token: nil,
phone: nil,
political_exposure: nil,
registered_address: nil,
relationship: nil,
ssn_last_4: nil,
us_cfpb_data: nil,
verification: nil
); end
end
class ListParams < Stripe::RequestParams
class Relationship < Stripe::RequestParams
# A filter on the list of people returned based on whether these people are authorizers of the account's representative.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :authorizer
# A filter on the list of people returned based on whether these people are directors of the account's company.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :director
# A filter on the list of people returned based on whether these people are executives of the account's company.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :executive
# A filter on the list of people returned based on whether these people are legal guardians of the account's representative.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :legal_guardian
# A filter on the list of people returned based on whether these people are owners of the account's company.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :owner
# A filter on the list of people returned based on whether these people are the representative of the account's company.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :representative
sig {
params(authorizer: T.nilable(T::Boolean), director: T.nilable(T::Boolean), executive: T.nilable(T::Boolean), legal_guardian: T.nilable(T::Boolean), owner: T.nilable(T::Boolean), representative: T.nilable(T::Boolean)).void
}
def initialize(
authorizer: nil,
director: nil,
executive: nil,
legal_guardian: nil,
owner: nil,
representative: nil
); end
end
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Filters on the list of people returned based on the person's relationship to the account's company.
sig { returns(T.nilable(::Stripe::AccountPersonService::ListParams::Relationship)) }
attr_accessor :relationship
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), relationship: T.nilable(::Stripe::AccountPersonService::ListParams::Relationship), starting_after: T.nilable(String)).void
}
def initialize(
ending_before: nil,
expand: nil,
limit: nil,
relationship: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class AdditionalTosAcceptances < Stripe::RequestParams
class Account < Stripe::RequestParams
# The Unix timestamp marking when the account representative accepted the service agreement.
sig { returns(T.nilable(Integer)) }
attr_accessor :date
# The IP address from which the account representative accepted the service agreement.
sig { returns(T.nilable(String)) }
attr_accessor :ip
# The user agent of the browser from which the account representative accepted the service agreement.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :user_agent
sig {
params(date: T.nilable(Integer), ip: T.nilable(String), user_agent: T.nilable(T.nilable(String))).void
}
def initialize(date: nil, ip: nil, user_agent: nil); end
end
# Details on the legal guardian's acceptance of the main Stripe service agreement.
sig {
returns(T.nilable(::Stripe::AccountPersonService::CreateParams::AdditionalTosAcceptances::Account))
}
attr_accessor :account
sig {
params(account: T.nilable(::Stripe::AccountPersonService::CreateParams::AdditionalTosAcceptances::Account)).void
}
def initialize(account: nil); end
end
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class AddressKana < Stripe::RequestParams
# City or ward.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Block or building number.
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Building details.
sig { returns(T.nilable(String)) }
attr_accessor :line2
# Postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# Prefecture.
sig { returns(T.nilable(String)) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_accessor :town
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), town: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
class AddressKanji < Stripe::RequestParams
# City or ward.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Block or building number.
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Building details.
sig { returns(T.nilable(String)) }
attr_accessor :line2
# Postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# Prefecture.
sig { returns(T.nilable(String)) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_accessor :town
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), town: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
class Dob < Stripe::RequestParams
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
class Documents < Stripe::RequestParams
class CompanyAuthorization < Stripe::RequestParams
# One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :files
sig { params(files: T.nilable(T::Array[String])).void }
def initialize(files: nil); end
end
class Passport < Stripe::RequestParams
# One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :files
sig { params(files: T.nilable(T::Array[String])).void }
def initialize(files: nil); end
end
class Visa < Stripe::RequestParams
# One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :files
sig { params(files: T.nilable(T::Array[String])).void }
def initialize(files: nil); end
end
# One or more documents that demonstrate proof that this person is authorized to represent the company.
sig {
returns(T.nilable(::Stripe::AccountPersonService::CreateParams::Documents::CompanyAuthorization))
}
attr_accessor :company_authorization
# One or more documents showing the person's passport page with photo and personal data.
sig {
returns(T.nilable(::Stripe::AccountPersonService::CreateParams::Documents::Passport))
}
attr_accessor :passport
# One or more documents showing the person's visa required for living in the country where they are residing.
sig { returns(T.nilable(::Stripe::AccountPersonService::CreateParams::Documents::Visa)) }
attr_accessor :visa
sig {
params(company_authorization: T.nilable(::Stripe::AccountPersonService::CreateParams::Documents::CompanyAuthorization), passport: T.nilable(::Stripe::AccountPersonService::CreateParams::Documents::Passport), visa: T.nilable(::Stripe::AccountPersonService::CreateParams::Documents::Visa)).void
}
def initialize(company_authorization: nil, passport: nil, visa: nil); end
end
class RegisteredAddress < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class Relationship < Stripe::RequestParams
# Whether the person is the authorizer of the account's representative.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :authorizer
# Whether the person is a director of the account's legal entity. Directors are typically members of the governing board of the company, or responsible for ensuring the company meets its regulatory obligations.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :director
# Whether the person has significant responsibility to control, manage, or direct the organization.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :executive
# Whether the person is the legal guardian of the account's representative.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :legal_guardian
# Whether the person is an owner of the account’s legal entity.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :owner
# The percent owned by the person of the account's legal entity.
sig { returns(T.nilable(T.nilable(T.any(String, Float)))) }
attr_accessor :percent_ownership
# Whether the person is authorized as the primary representative of the account. This is the person nominated by the business to provide information about themselves, and general information about the account. There can only be one representative at any given time. At the time the account is created, this person should be set to the person responsible for opening the account.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :representative
# The person's title (e.g., CEO, Support Engineer).
sig { returns(T.nilable(String)) }
attr_accessor :title
sig {
params(authorizer: T.nilable(T::Boolean), director: T.nilable(T::Boolean), executive: T.nilable(T::Boolean), legal_guardian: T.nilable(T::Boolean), owner: T.nilable(T::Boolean), percent_ownership: T.nilable(T.nilable(T.any(String, Float))), representative: T.nilable(T::Boolean), title: T.nilable(String)).void
}
def initialize(
authorizer: nil,
director: nil,
executive: nil,
legal_guardian: nil,
owner: nil,
percent_ownership: nil,
representative: nil,
title: nil
); end
end
class UsCfpbData < Stripe::RequestParams
class EthnicityDetails < Stripe::RequestParams
# The persons ethnicity
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :ethnicity
# Please specify your origin, when other is selected.
sig { returns(T.nilable(String)) }
attr_accessor :ethnicity_other
sig {
params(ethnicity: T.nilable(T::Array[String]), ethnicity_other: T.nilable(String)).void
}
def initialize(ethnicity: nil, ethnicity_other: nil); end
end
class RaceDetails < Stripe::RequestParams
# The persons race.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :race
# Please specify your race, when other is selected.
sig { returns(T.nilable(String)) }
attr_accessor :race_other
sig { params(race: T.nilable(T::Array[String]), race_other: T.nilable(String)).void }
def initialize(race: nil, race_other: nil); end
end
# The persons ethnicity details
sig {
returns(T.nilable(::Stripe::AccountPersonService::CreateParams::UsCfpbData::EthnicityDetails))
}
attr_accessor :ethnicity_details
# The persons race details
sig {
returns(T.nilable(::Stripe::AccountPersonService::CreateParams::UsCfpbData::RaceDetails))
}
attr_accessor :race_details
# The persons self-identified gender
sig { returns(T.nilable(String)) }
attr_accessor :self_identified_gender
sig {
params(ethnicity_details: T.nilable(::Stripe::AccountPersonService::CreateParams::UsCfpbData::EthnicityDetails), race_details: T.nilable(::Stripe::AccountPersonService::CreateParams::UsCfpbData::RaceDetails), self_identified_gender: T.nilable(String)).void
}
def initialize(ethnicity_details: nil, race_details: nil, self_identified_gender: nil); end
end
class Verification < Stripe::RequestParams
class AdditionalDocument < Stripe::RequestParams
# The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :back
# The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :front
sig { params(back: T.nilable(String), front: T.nilable(String)).void }
def initialize(back: nil, front: nil); end
end
class Document < Stripe::RequestParams
# The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :back
# The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :front
sig { params(back: T.nilable(String), front: T.nilable(String)).void }
def initialize(back: nil, front: nil); end
end
# A document showing address, either a passport, local ID card, or utility bill from a well-known utility company.
sig {
returns(T.nilable(::Stripe::AccountPersonService::CreateParams::Verification::AdditionalDocument))
}
attr_accessor :additional_document
# An identifying document, either a passport or local ID card.
sig {
returns(T.nilable(::Stripe::AccountPersonService::CreateParams::Verification::Document))
}
attr_accessor :document
sig {
params(additional_document: T.nilable(::Stripe::AccountPersonService::CreateParams::Verification::AdditionalDocument), document: T.nilable(::Stripe::AccountPersonService::CreateParams::Verification::Document)).void
}
def initialize(additional_document: nil, document: nil); end
end
# Details on the legal guardian's or authorizer's acceptance of the required Stripe agreements.
sig {
returns(T.nilable(::Stripe::AccountPersonService::CreateParams::AdditionalTosAcceptances))
}
attr_accessor :additional_tos_acceptances
# The person's address.
sig { returns(T.nilable(::Stripe::AccountPersonService::CreateParams::Address)) }
attr_accessor :address
# The Kana variation of the person's address (Japan only).
sig { returns(T.nilable(::Stripe::AccountPersonService::CreateParams::AddressKana)) }
attr_accessor :address_kana
# The Kanji variation of the person's address (Japan only).
sig { returns(T.nilable(::Stripe::AccountPersonService::CreateParams::AddressKanji)) }
attr_accessor :address_kanji
# The person's date of birth.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::AccountPersonService::CreateParams::Dob))))
}
attr_accessor :dob
# Documents that may be submitted to satisfy various informational requests.
sig { returns(T.nilable(::Stripe::AccountPersonService::CreateParams::Documents)) }
attr_accessor :documents
# The person's email address.
sig { returns(T.nilable(String)) }
attr_accessor :email
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The person's first name.
sig { returns(T.nilable(String)) }
attr_accessor :first_name
# The Kana variation of the person's first name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :first_name_kana
# The Kanji variation of the person's first name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :first_name_kanji
# A list of alternate names or aliases that the person is known by.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :full_name_aliases
# The person's gender (International regulations require either "male" or "female").
sig { returns(T.nilable(String)) }
attr_accessor :gender
# The person's ID number, as appropriate for their country. For example, a social security number in the U.S., social insurance number in Canada, etc. Instead of the number itself, you can also provide a [PII token provided by Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).
sig { returns(T.nilable(String)) }
attr_accessor :id_number
# The person's secondary ID number, as appropriate for their country, will be used for enhanced verification checks. In Thailand, this would be the laser code found on the back of an ID card. Instead of the number itself, you can also provide a [PII token provided by Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).
sig { returns(T.nilable(String)) }
attr_accessor :id_number_secondary
# The person's last name.
sig { returns(T.nilable(String)) }
attr_accessor :last_name
# The Kana variation of the person's last name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :last_name_kana
# The Kanji variation of the person's last name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :last_name_kanji
# The person's maiden name.
sig { returns(T.nilable(String)) }
attr_accessor :maiden_name
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# The country where the person is a national. Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)), or "XX" if unavailable.
sig { returns(T.nilable(String)) }
attr_accessor :nationality
# A [person token](https://docs.stripe.com/connect/account-tokens), used to securely provide details to the person.
sig { returns(T.nilable(String)) }
attr_accessor :person_token
# The person's phone number.
sig { returns(T.nilable(String)) }
attr_accessor :phone
# Indicates if the person or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction.
sig { returns(T.nilable(String)) }
attr_accessor :political_exposure
# The person's registered address.
sig { returns(T.nilable(::Stripe::AccountPersonService::CreateParams::RegisteredAddress)) }
attr_accessor :registered_address
# The relationship that this person has with the account's legal entity.
sig { returns(T.nilable(::Stripe::AccountPersonService::CreateParams::Relationship)) }
attr_accessor :relationship
# The last four digits of the person's Social Security number (U.S. only).
sig { returns(T.nilable(String)) }
attr_accessor :ssn_last_4
# Demographic data related to the person.
sig { returns(T.nilable(::Stripe::AccountPersonService::CreateParams::UsCfpbData)) }
attr_accessor :us_cfpb_data
# The person's verification status.
sig { returns(T.nilable(::Stripe::AccountPersonService::CreateParams::Verification)) }
attr_accessor :verification
sig {
params(additional_tos_acceptances: T.nilable(::Stripe::AccountPersonService::CreateParams::AdditionalTosAcceptances), address: T.nilable(::Stripe::AccountPersonService::CreateParams::Address), address_kana: T.nilable(::Stripe::AccountPersonService::CreateParams::AddressKana), address_kanji: T.nilable(::Stripe::AccountPersonService::CreateParams::AddressKanji), dob: T.nilable(T.nilable(T.any(String, ::Stripe::AccountPersonService::CreateParams::Dob))), documents: T.nilable(::Stripe::AccountPersonService::CreateParams::Documents), email: T.nilable(String), expand: T.nilable(T::Array[String]), first_name: T.nilable(String), first_name_kana: T.nilable(String), first_name_kanji: T.nilable(String), full_name_aliases: T.nilable(T.nilable(T.any(String, T::Array[String]))), gender: T.nilable(String), id_number: T.nilable(String), id_number_secondary: T.nilable(String), last_name: T.nilable(String), last_name_kana: T.nilable(String), last_name_kanji: T.nilable(String), maiden_name: T.nilable(String), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), nationality: T.nilable(String), person_token: T.nilable(String), phone: T.nilable(String), political_exposure: T.nilable(String), registered_address: T.nilable(::Stripe::AccountPersonService::CreateParams::RegisteredAddress), relationship: T.nilable(::Stripe::AccountPersonService::CreateParams::Relationship), ssn_last_4: T.nilable(String), us_cfpb_data: T.nilable(::Stripe::AccountPersonService::CreateParams::UsCfpbData), verification: T.nilable(::Stripe::AccountPersonService::CreateParams::Verification)).void
}
def initialize(
additional_tos_acceptances: nil,
address: nil,
address_kana: nil,
address_kanji: nil,
dob: nil,
documents: nil,
email: nil,
expand: nil,
first_name: nil,
first_name_kana: nil,
first_name_kanji: nil,
full_name_aliases: nil,
gender: nil,
id_number: nil,
id_number_secondary: nil,
last_name: nil,
last_name_kana: nil,
last_name_kanji: nil,
maiden_name: nil,
metadata: nil,
nationality: nil,
person_token: nil,
phone: nil,
political_exposure: nil,
registered_address: nil,
relationship: nil,
ssn_last_4: nil,
us_cfpb_data: nil,
verification: nil
); end
end
# Creates a new person.
sig {
params(account: String, params: T.any(::Stripe::AccountPersonService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Person)
}
def create(account, params = {}, opts = {}); end
# Deletes an existing person's relationship to the account's legal entity. Any person with a relationship for an account can be deleted through the API, except if the person is the account_opener. If your integration is using the executive parameter, you cannot delete the only verified executive on file.
sig {
params(account: String, person: String, params: T.any(::Stripe::AccountPersonService::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Person)
}
def delete(account, person, params = {}, opts = {}); end
# Returns a list of people associated with the account's legal entity. The people are returned sorted by creation date, with the most recent people appearing first.
sig {
params(account: String, params: T.any(::Stripe::AccountPersonService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(account, params = {}, opts = {}); end
# Retrieves an existing person.
sig {
params(account: String, person: String, params: T.any(::Stripe::AccountPersonService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Person)
}
def retrieve(account, person, params = {}, opts = {}); end
# Updates an existing person.
sig {
params(account: String, person: String, params: T.any(::Stripe::AccountPersonService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Person)
}
def update(account, person, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class AccountLinkService < StripeService
class CreateParams < Stripe::RequestParams
class CollectionOptions < Stripe::RequestParams
# Specifies whether the platform collects only currently_due requirements (`currently_due`) or both currently_due and eventually_due requirements (`eventually_due`). If you don't specify `collection_options`, the default value is `currently_due`.
sig { returns(T.nilable(String)) }
attr_accessor :fields
# Specifies whether the platform collects future_requirements in addition to requirements in Connect Onboarding. The default value is `omit`.
sig { returns(T.nilable(String)) }
attr_accessor :future_requirements
sig { params(fields: T.nilable(String), future_requirements: T.nilable(String)).void }
def initialize(fields: nil, future_requirements: nil); end
end
# The identifier of the account to create an account link for.
sig { returns(String) }
attr_accessor :account
# The collect parameter is deprecated. Use `collection_options` instead.
sig { returns(T.nilable(String)) }
attr_accessor :collect
# Specifies the requirements that Stripe collects from connected accounts in the Connect Onboarding flow.
sig { returns(T.nilable(::Stripe::AccountLinkService::CreateParams::CollectionOptions)) }
attr_accessor :collection_options
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The URL the user will be redirected to if the account link is expired, has been previously-visited, or is otherwise invalid. The URL you specify should attempt to generate a new account link with the same parameters used to create the original account link, then redirect the user to the new account link's URL so they can continue with Connect Onboarding. If a new account link cannot be generated or the redirect fails you should display a useful error to the user.
sig { returns(T.nilable(String)) }
attr_accessor :refresh_url
# The URL that the user will be redirected to upon leaving or completing the linked flow.
sig { returns(T.nilable(String)) }
attr_accessor :return_url
# The type of account link the user is requesting. Possible values are `account_onboarding` or `account_update`.
sig { returns(String) }
attr_accessor :type
sig {
params(account: String, collect: T.nilable(String), collection_options: T.nilable(::Stripe::AccountLinkService::CreateParams::CollectionOptions), expand: T.nilable(T::Array[String]), refresh_url: T.nilable(String), return_url: T.nilable(String), type: String).void
}
def initialize(
account: nil,
collect: nil,
collection_options: nil,
expand: nil,
refresh_url: nil,
return_url: nil,
type: nil
); end
end
# Creates an AccountLink object that includes a single-use Stripe URL that the platform can redirect their user to in order to take them through the Connect Onboarding flow.
sig {
params(params: T.any(::Stripe::AccountLinkService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::AccountLink)
}
def create(params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class AccountNoticeService < StripeService
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Set to false to only return unsent AccountNotices.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :sent
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), sent: T.nilable(T::Boolean), starting_after: T.nilable(String)).void
}
def initialize(
ending_before: nil,
expand: nil,
limit: nil,
sent: nil,
starting_after: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
class Email < Stripe::RequestParams
# Content of the email in plain text. The copy must match exactly the language that Stripe Compliance has approved for use.
sig { returns(String) }
attr_accessor :plain_text
# Email address of the recipient.
sig { returns(String) }
attr_accessor :recipient
# Subject of the email.
sig { returns(String) }
attr_accessor :subject
sig { params(plain_text: String, recipient: String, subject: String).void }
def initialize(plain_text: nil, recipient: nil, subject: nil); end
end
# Information about the email you sent.
sig { returns(::Stripe::AccountNoticeService::UpdateParams::Email) }
attr_accessor :email
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Date when you sent the notice.
sig { returns(Integer) }
attr_accessor :sent_at
sig {
params(email: ::Stripe::AccountNoticeService::UpdateParams::Email, expand: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), sent_at: Integer).void
}
def initialize(email: nil, expand: nil, metadata: nil, sent_at: nil); end
end
# Retrieves a list of AccountNotice objects. The objects are sorted in descending order by creation date, with the most-recently-created object appearing first.
sig {
params(params: T.any(::Stripe::AccountNoticeService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves an AccountNotice object.
sig {
params(account_notice: String, params: T.any(::Stripe::AccountNoticeService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::AccountNotice)
}
def retrieve(account_notice, params = {}, opts = {}); end
# Updates an AccountNotice object.
sig {
params(account_notice: String, params: T.any(::Stripe::AccountNoticeService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::AccountNotice)
}
def update(account_notice, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class AccountSessionService < StripeService
class CreateParams < Stripe::RequestParams
class Components < Stripe::RequestParams
class AccountManagement < Stripe::RequestParams
class Features < Stripe::RequestParams
# Disables Stripe user authentication for this embedded component. This value can only be true for accounts where `controller.requirement_collection` is `application`. The default value is the opposite of the `external_account_collection` value. For example, if you don’t set `external_account_collection`, it defaults to true and `disable_stripe_user_authentication` defaults to false.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :disable_stripe_user_authentication
# Whether to allow platforms to control bank account collection for their connected accounts. This feature can only be false for accounts where you’re responsible for collecting updated information when requirements are due or change, like custom accounts. Otherwise, bank account collection is determined by compliance requirements. The default value for this feature is `true`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :external_account_collection
sig {
params(disable_stripe_user_authentication: T.nilable(T::Boolean), external_account_collection: T.nilable(T::Boolean)).void
}
def initialize(
disable_stripe_user_authentication: nil,
external_account_collection: nil
); end
end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::AccountManagement::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::AccountManagement::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class AccountOnboarding < Stripe::RequestParams
class Features < Stripe::RequestParams
# Disables Stripe user authentication for this embedded component. This value can only be true for accounts where `controller.requirement_collection` is `application`. The default value is the opposite of the `external_account_collection` value. For example, if you don’t set `external_account_collection`, it defaults to true and `disable_stripe_user_authentication` defaults to false.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :disable_stripe_user_authentication
# Whether to allow platforms to control bank account collection for their connected accounts. This feature can only be false for accounts where you’re responsible for collecting updated information when requirements are due or change, like custom accounts. Otherwise, bank account collection is determined by compliance requirements. The default value for this feature is `true`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :external_account_collection
sig {
params(disable_stripe_user_authentication: T.nilable(T::Boolean), external_account_collection: T.nilable(T::Boolean)).void
}
def initialize(
disable_stripe_user_authentication: nil,
external_account_collection: nil
); end
end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::AccountOnboarding::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::AccountOnboarding::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class AppInstall < Stripe::RequestParams
class Features < Stripe::RequestParams
# List of apps allowed to be enabled for this account session.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :allowed_apps
sig { params(allowed_apps: T.nilable(T.nilable(T.any(String, T::Array[String])))).void }
def initialize(allowed_apps: nil); end
end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::AppInstall::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::AppInstall::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class AppViewport < Stripe::RequestParams
class Features < Stripe::RequestParams
# List of apps allowed to be enabled for this account session.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :allowed_apps
sig { params(allowed_apps: T.nilable(T.nilable(T.any(String, T::Array[String])))).void }
def initialize(allowed_apps: nil); end
end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::AppViewport::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::AppViewport::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class Balances < Stripe::RequestParams
class Features < Stripe::RequestParams
# Disables Stripe user authentication for this embedded component. This value can only be true for accounts where `controller.requirement_collection` is `application`. The default value is the opposite of the `external_account_collection` value. For example, if you don’t set `external_account_collection`, it defaults to true and `disable_stripe_user_authentication` defaults to false.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :disable_stripe_user_authentication
# Whether to allow payout schedule to be changed. Default `true` when Stripe owns Loss Liability, default `false` otherwise.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :edit_payout_schedule
# Whether to allow platforms to control bank account collection for their connected accounts. This feature can only be false for accounts where you’re responsible for collecting updated information when requirements are due or change, like custom accounts. Otherwise, bank account collection is determined by compliance requirements. The default value for this feature is `true`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :external_account_collection
# Whether to allow creation of instant payouts. Default `true` when Stripe owns Loss Liability, default `false` otherwise.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :instant_payouts
# Whether to allow creation of standard payouts. Default `true` when Stripe owns Loss Liability, default `false` otherwise.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :standard_payouts
sig {
params(disable_stripe_user_authentication: T.nilable(T::Boolean), edit_payout_schedule: T.nilable(T::Boolean), external_account_collection: T.nilable(T::Boolean), instant_payouts: T.nilable(T::Boolean), standard_payouts: T.nilable(T::Boolean)).void
}
def initialize(
disable_stripe_user_authentication: nil,
edit_payout_schedule: nil,
external_account_collection: nil,
instant_payouts: nil,
standard_payouts: nil
); end
end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::Balances::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::Balances::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class CapitalFinancing < Stripe::RequestParams
class Features < Stripe::RequestParams; end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::CapitalFinancing::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::CapitalFinancing::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class CapitalFinancingApplication < Stripe::RequestParams
class Features < Stripe::RequestParams; end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::CapitalFinancingApplication::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::CapitalFinancingApplication::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class CapitalFinancingPromotion < Stripe::RequestParams
class Features < Stripe::RequestParams; end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::CapitalFinancingPromotion::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::CapitalFinancingPromotion::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class CapitalOverview < Stripe::RequestParams
class Features < Stripe::RequestParams; end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::CapitalOverview::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::CapitalOverview::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class DisputesList < Stripe::RequestParams
class Features < Stripe::RequestParams
# Whether to allow capturing and cancelling payment intents. This is `true` by default.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :capture_payments
# Whether to allow connected accounts to manage destination charges that are created on behalf of them. This is `false` by default.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :destination_on_behalf_of_charge_management
# Whether to allow responding to disputes, including submitting evidence and accepting disputes. This is `true` by default.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :dispute_management
# Whether to allow sending refunds. This is `true` by default.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :refund_management
sig {
params(capture_payments: T.nilable(T::Boolean), destination_on_behalf_of_charge_management: T.nilable(T::Boolean), dispute_management: T.nilable(T::Boolean), refund_management: T.nilable(T::Boolean)).void
}
def initialize(
capture_payments: nil,
destination_on_behalf_of_charge_management: nil,
dispute_management: nil,
refund_management: nil
); end
end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::DisputesList::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::DisputesList::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class Documents < Stripe::RequestParams
class Features < Stripe::RequestParams; end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::Documents::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::Documents::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class ExportTaxTransactions < Stripe::RequestParams
class Features < Stripe::RequestParams; end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::ExportTaxTransactions::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::ExportTaxTransactions::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class FinancialAccount < Stripe::RequestParams
class Features < Stripe::RequestParams
# Disables Stripe user authentication for this embedded component. This value can only be true for accounts where `controller.requirement_collection` is `application`. The default value is the opposite of the `external_account_collection` value. For example, if you don’t set `external_account_collection`, it defaults to true and `disable_stripe_user_authentication` defaults to false.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :disable_stripe_user_authentication
# Whether to allow external accounts to be linked for money transfer.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :external_account_collection
# Whether to allow sending money.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :send_money
# Whether to allow transferring balance.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :transfer_balance
sig {
params(disable_stripe_user_authentication: T.nilable(T::Boolean), external_account_collection: T.nilable(T::Boolean), send_money: T.nilable(T::Boolean), transfer_balance: T.nilable(T::Boolean)).void
}
def initialize(
disable_stripe_user_authentication: nil,
external_account_collection: nil,
send_money: nil,
transfer_balance: nil
); end
end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::FinancialAccount::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::FinancialAccount::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class FinancialAccountTransactions < Stripe::RequestParams
class Features < Stripe::RequestParams
# Whether to allow card spend dispute management features.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :card_spend_dispute_management
sig { params(card_spend_dispute_management: T.nilable(T::Boolean)).void }
def initialize(card_spend_dispute_management: nil); end
end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::FinancialAccountTransactions::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::FinancialAccountTransactions::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class IssuingCard < Stripe::RequestParams
class Features < Stripe::RequestParams
# Whether to allow card management features.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :card_management
# Whether to allow card spend dispute management features.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :card_spend_dispute_management
# Whether to allow cardholder management features.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :cardholder_management
# Whether to allow spend control management features.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :spend_control_management
sig {
params(card_management: T.nilable(T::Boolean), card_spend_dispute_management: T.nilable(T::Boolean), cardholder_management: T.nilable(T::Boolean), spend_control_management: T.nilable(T::Boolean)).void
}
def initialize(
card_management: nil,
card_spend_dispute_management: nil,
cardholder_management: nil,
spend_control_management: nil
); end
end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::IssuingCard::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::IssuingCard::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class IssuingCardsList < Stripe::RequestParams
class Features < Stripe::RequestParams
# Whether to allow card management features.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :card_management
# Whether to allow card spend dispute management features.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :card_spend_dispute_management
# Whether to allow cardholder management features.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :cardholder_management
# Disables Stripe user authentication for this embedded component. This feature can only be false for accounts where you’re responsible for collecting updated information when requirements are due or change, like custom accounts.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :disable_stripe_user_authentication
# Whether to allow spend control management features.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :spend_control_management
sig {
params(card_management: T.nilable(T::Boolean), card_spend_dispute_management: T.nilable(T::Boolean), cardholder_management: T.nilable(T::Boolean), disable_stripe_user_authentication: T.nilable(T::Boolean), spend_control_management: T.nilable(T::Boolean)).void
}
def initialize(
card_management: nil,
card_spend_dispute_management: nil,
cardholder_management: nil,
disable_stripe_user_authentication: nil,
spend_control_management: nil
); end
end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::IssuingCardsList::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::IssuingCardsList::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class NotificationBanner < Stripe::RequestParams
class Features < Stripe::RequestParams
# Disables Stripe user authentication for this embedded component. This value can only be true for accounts where `controller.requirement_collection` is `application`. The default value is the opposite of the `external_account_collection` value. For example, if you don’t set `external_account_collection`, it defaults to true and `disable_stripe_user_authentication` defaults to false.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :disable_stripe_user_authentication
# Whether to allow platforms to control bank account collection for their connected accounts. This feature can only be false for accounts where you’re responsible for collecting updated information when requirements are due or change, like custom accounts. Otherwise, bank account collection is determined by compliance requirements. The default value for this feature is `true`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :external_account_collection
sig {
params(disable_stripe_user_authentication: T.nilable(T::Boolean), external_account_collection: T.nilable(T::Boolean)).void
}
def initialize(
disable_stripe_user_authentication: nil,
external_account_collection: nil
); end
end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::NotificationBanner::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::NotificationBanner::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class PaymentDetails < Stripe::RequestParams
class Features < Stripe::RequestParams
# Whether to allow capturing and cancelling payment intents. This is `true` by default.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :capture_payments
# Whether to allow connected accounts to manage destination charges that are created on behalf of them. This is `false` by default.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :destination_on_behalf_of_charge_management
# Whether to allow responding to disputes, including submitting evidence and accepting disputes. This is `true` by default.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :dispute_management
# Whether to allow sending refunds. This is `true` by default.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :refund_management
sig {
params(capture_payments: T.nilable(T::Boolean), destination_on_behalf_of_charge_management: T.nilable(T::Boolean), dispute_management: T.nilable(T::Boolean), refund_management: T.nilable(T::Boolean)).void
}
def initialize(
capture_payments: nil,
destination_on_behalf_of_charge_management: nil,
dispute_management: nil,
refund_management: nil
); end
end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::PaymentDetails::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::PaymentDetails::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class PaymentDisputes < Stripe::RequestParams
class Features < Stripe::RequestParams
# Whether to allow connected accounts to manage destination charges that are created on behalf of them. This is `false` by default.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :destination_on_behalf_of_charge_management
# Whether to allow responding to disputes, including submitting evidence and accepting disputes. This is `true` by default.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :dispute_management
# Whether to allow sending refunds. This is `true` by default.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :refund_management
sig {
params(destination_on_behalf_of_charge_management: T.nilable(T::Boolean), dispute_management: T.nilable(T::Boolean), refund_management: T.nilable(T::Boolean)).void
}
def initialize(
destination_on_behalf_of_charge_management: nil,
dispute_management: nil,
refund_management: nil
); end
end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::PaymentDisputes::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::PaymentDisputes::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class PaymentMethodSettings < Stripe::RequestParams
class Features < Stripe::RequestParams; end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::PaymentMethodSettings::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::PaymentMethodSettings::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class Payments < Stripe::RequestParams
class Features < Stripe::RequestParams
# Whether to allow capturing and cancelling payment intents. This is `true` by default.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :capture_payments
# Whether to allow connected accounts to manage destination charges that are created on behalf of them. This is `false` by default.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :destination_on_behalf_of_charge_management
# Whether to allow responding to disputes, including submitting evidence and accepting disputes. This is `true` by default.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :dispute_management
# Whether to allow sending refunds. This is `true` by default.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :refund_management
sig {
params(capture_payments: T.nilable(T::Boolean), destination_on_behalf_of_charge_management: T.nilable(T::Boolean), dispute_management: T.nilable(T::Boolean), refund_management: T.nilable(T::Boolean)).void
}
def initialize(
capture_payments: nil,
destination_on_behalf_of_charge_management: nil,
dispute_management: nil,
refund_management: nil
); end
end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::Payments::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::Payments::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class Payouts < Stripe::RequestParams
class Features < Stripe::RequestParams
# Disables Stripe user authentication for this embedded component. This value can only be true for accounts where `controller.requirement_collection` is `application`. The default value is the opposite of the `external_account_collection` value. For example, if you don’t set `external_account_collection`, it defaults to true and `disable_stripe_user_authentication` defaults to false.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :disable_stripe_user_authentication
# Whether to allow payout schedule to be changed. Default `true` when Stripe owns Loss Liability, default `false` otherwise.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :edit_payout_schedule
# Whether to allow platforms to control bank account collection for their connected accounts. This feature can only be false for accounts where you’re responsible for collecting updated information when requirements are due or change, like custom accounts. Otherwise, bank account collection is determined by compliance requirements. The default value for this feature is `true`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :external_account_collection
# Whether to allow creation of instant payouts. Default `true` when Stripe owns Loss Liability, default `false` otherwise.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :instant_payouts
# Whether to allow creation of standard payouts. Default `true` when Stripe owns Loss Liability, default `false` otherwise.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :standard_payouts
sig {
params(disable_stripe_user_authentication: T.nilable(T::Boolean), edit_payout_schedule: T.nilable(T::Boolean), external_account_collection: T.nilable(T::Boolean), instant_payouts: T.nilable(T::Boolean), standard_payouts: T.nilable(T::Boolean)).void
}
def initialize(
disable_stripe_user_authentication: nil,
edit_payout_schedule: nil,
external_account_collection: nil,
instant_payouts: nil,
standard_payouts: nil
); end
end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::Payouts::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::Payouts::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class PayoutsList < Stripe::RequestParams
class Features < Stripe::RequestParams; end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::PayoutsList::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::PayoutsList::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class ProductTaxCodeSelector < Stripe::RequestParams
class Features < Stripe::RequestParams; end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::ProductTaxCodeSelector::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::ProductTaxCodeSelector::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class Recipients < Stripe::RequestParams
class Features < Stripe::RequestParams
# Whether to allow sending money.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :send_money
sig { params(send_money: T.nilable(T::Boolean)).void }
def initialize(send_money: nil); end
end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# Attribute for param field features
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::Recipients::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::Recipients::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class ReportingChart < Stripe::RequestParams
class Features < Stripe::RequestParams; end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::ReportingChart::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::ReportingChart::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class TaxRegistrations < Stripe::RequestParams
class Features < Stripe::RequestParams; end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::TaxRegistrations::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::TaxRegistrations::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class TaxSettings < Stripe::RequestParams
class Features < Stripe::RequestParams; end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::TaxSettings::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::TaxSettings::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class TaxThresholdMonitoring < Stripe::RequestParams
class Features < Stripe::RequestParams; end
# Whether the embedded component is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of features enabled in the embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::TaxThresholdMonitoring::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::TaxThresholdMonitoring::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
# Configuration for the account management embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::AccountManagement))
}
attr_accessor :account_management
# Configuration for the account onboarding embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::AccountOnboarding))
}
attr_accessor :account_onboarding
# Configuration for the app install component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::AppInstall))
}
attr_accessor :app_install
# Configuration for the app viewport component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::AppViewport))
}
attr_accessor :app_viewport
# Configuration for the balances embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::Balances))
}
attr_accessor :balances
# Configuration for the capital financing embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::CapitalFinancing))
}
attr_accessor :capital_financing
# Configuration for the capital financing application embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::CapitalFinancingApplication))
}
attr_accessor :capital_financing_application
# Configuration for the capital financing promotion embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::CapitalFinancingPromotion))
}
attr_accessor :capital_financing_promotion
# Configuration for the capital overview embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::CapitalOverview))
}
attr_accessor :capital_overview
# Configuration for the disputes list embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::DisputesList))
}
attr_accessor :disputes_list
# Configuration for the documents embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::Documents))
}
attr_accessor :documents
# Configuration for the export tax transactions embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::ExportTaxTransactions))
}
attr_accessor :export_tax_transactions
# Configuration for the financial account embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::FinancialAccount))
}
attr_accessor :financial_account
# Configuration for the financial account transactions embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::FinancialAccountTransactions))
}
attr_accessor :financial_account_transactions
# Configuration for the issuing card embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::IssuingCard))
}
attr_accessor :issuing_card
# Configuration for the issuing cards list embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::IssuingCardsList))
}
attr_accessor :issuing_cards_list
# Configuration for the notification banner embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::NotificationBanner))
}
attr_accessor :notification_banner
# Configuration for the payment details embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::PaymentDetails))
}
attr_accessor :payment_details
# Configuration for the payment disputes embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::PaymentDisputes))
}
attr_accessor :payment_disputes
# Configuration for the payment method settings embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::PaymentMethodSettings))
}
attr_accessor :payment_method_settings
# Configuration for the payments embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::Payments))
}
attr_accessor :payments
# Configuration for the payouts embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::Payouts))
}
attr_accessor :payouts
# Configuration for the payouts list embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::PayoutsList))
}
attr_accessor :payouts_list
# Configuration for the product tax code selector embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::ProductTaxCodeSelector))
}
attr_accessor :product_tax_code_selector
# Configuration for the recipients component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::Recipients))
}
attr_accessor :recipients
# Configuration for the reporting chart embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::ReportingChart))
}
attr_accessor :reporting_chart
# Configuration for the tax registrations embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::TaxRegistrations))
}
attr_accessor :tax_registrations
# Configuration for the tax settings embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::TaxSettings))
}
attr_accessor :tax_settings
# Configuration for the tax threshold monitoring embedded component.
sig {
returns(T.nilable(::Stripe::AccountSessionService::CreateParams::Components::TaxThresholdMonitoring))
}
attr_accessor :tax_threshold_monitoring
sig {
params(account_management: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::AccountManagement), account_onboarding: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::AccountOnboarding), app_install: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::AppInstall), app_viewport: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::AppViewport), balances: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::Balances), capital_financing: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::CapitalFinancing), capital_financing_application: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::CapitalFinancingApplication), capital_financing_promotion: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::CapitalFinancingPromotion), capital_overview: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::CapitalOverview), disputes_list: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::DisputesList), documents: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::Documents), export_tax_transactions: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::ExportTaxTransactions), financial_account: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::FinancialAccount), financial_account_transactions: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::FinancialAccountTransactions), issuing_card: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::IssuingCard), issuing_cards_list: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::IssuingCardsList), notification_banner: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::NotificationBanner), payment_details: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::PaymentDetails), payment_disputes: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::PaymentDisputes), payment_method_settings: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::PaymentMethodSettings), payments: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::Payments), payouts: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::Payouts), payouts_list: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::PayoutsList), product_tax_code_selector: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::ProductTaxCodeSelector), recipients: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::Recipients), reporting_chart: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::ReportingChart), tax_registrations: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::TaxRegistrations), tax_settings: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::TaxSettings), tax_threshold_monitoring: T.nilable(::Stripe::AccountSessionService::CreateParams::Components::TaxThresholdMonitoring)).void
}
def initialize(
account_management: nil,
account_onboarding: nil,
app_install: nil,
app_viewport: nil,
balances: nil,
capital_financing: nil,
capital_financing_application: nil,
capital_financing_promotion: nil,
capital_overview: nil,
disputes_list: nil,
documents: nil,
export_tax_transactions: nil,
financial_account: nil,
financial_account_transactions: nil,
issuing_card: nil,
issuing_cards_list: nil,
notification_banner: nil,
payment_details: nil,
payment_disputes: nil,
payment_method_settings: nil,
payments: nil,
payouts: nil,
payouts_list: nil,
product_tax_code_selector: nil,
recipients: nil,
reporting_chart: nil,
tax_registrations: nil,
tax_settings: nil,
tax_threshold_monitoring: nil
); end
end
# The identifier of the account to create an Account Session for.
sig { returns(String) }
attr_accessor :account
# Each key of the dictionary represents an embedded component, and each embedded component maps to its configuration (e.g. whether it has been enabled or not).
sig { returns(::Stripe::AccountSessionService::CreateParams::Components) }
attr_accessor :components
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig {
params(account: String, components: ::Stripe::AccountSessionService::CreateParams::Components, expand: T.nilable(T::Array[String])).void
}
def initialize(account: nil, components: nil, expand: nil); end
end
# Creates a AccountSession object that includes a single-use token that the platform can use on their front-end to grant client-side API access.
sig {
params(params: T.any(::Stripe::AccountSessionService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::AccountSession)
}
def create(params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class ApplePayDomainService < StripeService
class DeleteParams < Stripe::RequestParams; end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class ListParams < Stripe::RequestParams
# Attribute for param field domain_name
sig { returns(T.nilable(String)) }
attr_accessor :domain_name
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(domain_name: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
domain_name: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
# Attribute for param field domain_name
sig { returns(String) }
attr_accessor :domain_name
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(domain_name: String, expand: T.nilable(T::Array[String])).void }
def initialize(domain_name: nil, expand: nil); end
end
# Create an apple pay domain.
sig {
params(params: T.any(::Stripe::ApplePayDomainService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ApplePayDomain)
}
def create(params = {}, opts = {}); end
# Delete an apple pay domain.
sig {
params(domain: String, params: T.any(::Stripe::ApplePayDomainService::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ApplePayDomain)
}
def delete(domain, params = {}, opts = {}); end
# List apple pay domains.
sig {
params(params: T.any(::Stripe::ApplePayDomainService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieve an apple pay domain.
sig {
params(domain: String, params: T.any(::Stripe::ApplePayDomainService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ApplePayDomain)
}
def retrieve(domain, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class ApplicationFeeService < StripeService
attr_reader :refunds
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return application fees for the charge specified by this charge ID.
sig { returns(T.nilable(String)) }
attr_accessor :charge
# Only return applications fees that were created during the given date interval.
sig {
returns(T.nilable(T.any(::Stripe::ApplicationFeeService::ListParams::Created, Integer)))
}
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(charge: T.nilable(String), created: T.nilable(T.any(::Stripe::ApplicationFeeService::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
charge: nil,
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Returns a list of application fees you've previously collected. The application fees are returned in sorted order, with the most recent fees appearing first.
sig {
params(params: T.any(::Stripe::ApplicationFeeService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the details of an application fee that your account has collected. The same information is returned when refunding the application fee.
sig {
params(id: String, params: T.any(::Stripe::ApplicationFeeService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ApplicationFee)
}
def retrieve(id, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class ApplicationFeeRefundService < StripeService
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
sig {
params(expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String])))).void
}
def initialize(expand: nil, metadata: nil); end
end
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
class CreateParams < Stripe::RequestParams
# A positive integer, in _cents (or local equivalent)_, representing how much of this fee to refund. Can refund only up to the remaining unrefunded amount of the fee.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
sig {
params(amount: T.nilable(Integer), expand: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String])).void
}
def initialize(amount: nil, expand: nil, metadata: nil); end
end
# Refunds an application fee that has previously been collected but not yet refunded.
# Funds will be refunded to the Stripe account from which the fee was originally collected.
#
# You can optionally refund only part of an application fee.
# You can do so multiple times, until the entire fee has been refunded.
#
# Once entirely refunded, an application fee can't be refunded again.
# This method will raise an error when called on an already-refunded application fee,
# or when trying to refund more money than is left on an application fee.
sig {
params(id: String, params: T.any(::Stripe::ApplicationFeeRefundService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ApplicationFeeRefund)
}
def create(id, params = {}, opts = {}); end
# You can see a list of the refunds belonging to a specific application fee. Note that the 10 most recent refunds are always available by default on the application fee object. If you need more than those 10, you can use this API method and the limit and starting_after parameters to page through additional refunds.
sig {
params(id: String, params: T.any(::Stripe::ApplicationFeeRefundService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(id, params = {}, opts = {}); end
# By default, you can see the 10 most recent refunds stored directly on the application fee object, but you can also retrieve details about a specific refund stored on the application fee.
sig {
params(fee: String, id: String, params: T.any(::Stripe::ApplicationFeeRefundService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ApplicationFeeRefund)
}
def retrieve(fee, id, params = {}, opts = {}); end
# Updates the specified application fee refund by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
#
# This request only accepts metadata as an argument.
sig {
params(fee: String, id: String, params: T.any(::Stripe::ApplicationFeeRefundService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ApplicationFeeRefund)
}
def update(fee, id, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class AppsService < StripeService
attr_reader :secrets
end
end
# typed: true
module Stripe
module Apps
class SecretService < StripeService
class ListParams < Stripe::RequestParams
class Scope < Stripe::RequestParams
# The secret scope type.
sig { returns(String) }
attr_accessor :type
# The user ID. This field is required if `type` is set to `user`, and should not be provided if `type` is set to `account`.
sig { returns(T.nilable(String)) }
attr_accessor :user
sig { params(type: String, user: T.nilable(String)).void }
def initialize(type: nil, user: nil); end
end
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Specifies the scoping of the secret. Requests originating from UI extensions can only access account-scoped secrets or secrets scoped to their own user.
sig { returns(::Stripe::Apps::SecretService::ListParams::Scope) }
attr_accessor :scope
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), scope: ::Stripe::Apps::SecretService::ListParams::Scope, starting_after: T.nilable(String)).void
}
def initialize(
ending_before: nil,
expand: nil,
limit: nil,
scope: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class Scope < Stripe::RequestParams
# The secret scope type.
sig { returns(String) }
attr_accessor :type
# The user ID. This field is required if `type` is set to `user`, and should not be provided if `type` is set to `account`.
sig { returns(T.nilable(String)) }
attr_accessor :user
sig { params(type: String, user: T.nilable(String)).void }
def initialize(type: nil, user: nil); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The Unix timestamp for the expiry time of the secret, after which the secret deletes.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_at
# A name for the secret that's unique within the scope.
sig { returns(String) }
attr_accessor :name
# The plaintext secret value to be stored.
sig { returns(String) }
attr_accessor :payload
# Specifies the scoping of the secret. Requests originating from UI extensions can only access account-scoped secrets or secrets scoped to their own user.
sig { returns(::Stripe::Apps::SecretService::CreateParams::Scope) }
attr_accessor :scope
sig {
params(expand: T.nilable(T::Array[String]), expires_at: T.nilable(Integer), name: String, payload: String, scope: ::Stripe::Apps::SecretService::CreateParams::Scope).void
}
def initialize(expand: nil, expires_at: nil, name: nil, payload: nil, scope: nil); end
end
class FindParams < Stripe::RequestParams
class Scope < Stripe::RequestParams
# The secret scope type.
sig { returns(String) }
attr_accessor :type
# The user ID. This field is required if `type` is set to `user`, and should not be provided if `type` is set to `account`.
sig { returns(T.nilable(String)) }
attr_accessor :user
sig { params(type: String, user: T.nilable(String)).void }
def initialize(type: nil, user: nil); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A name for the secret that's unique within the scope.
sig { returns(String) }
attr_accessor :name
# Specifies the scoping of the secret. Requests originating from UI extensions can only access account-scoped secrets or secrets scoped to their own user.
sig { returns(::Stripe::Apps::SecretService::FindParams::Scope) }
attr_accessor :scope
sig {
params(expand: T.nilable(T::Array[String]), name: String, scope: ::Stripe::Apps::SecretService::FindParams::Scope).void
}
def initialize(expand: nil, name: nil, scope: nil); end
end
class DeleteWhereParams < Stripe::RequestParams
class Scope < Stripe::RequestParams
# The secret scope type.
sig { returns(String) }
attr_accessor :type
# The user ID. This field is required if `type` is set to `user`, and should not be provided if `type` is set to `account`.
sig { returns(T.nilable(String)) }
attr_accessor :user
sig { params(type: String, user: T.nilable(String)).void }
def initialize(type: nil, user: nil); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A name for the secret that's unique within the scope.
sig { returns(String) }
attr_accessor :name
# Specifies the scoping of the secret. Requests originating from UI extensions can only access account-scoped secrets or secrets scoped to their own user.
sig { returns(::Stripe::Apps::SecretService::DeleteWhereParams::Scope) }
attr_accessor :scope
sig {
params(expand: T.nilable(T::Array[String]), name: String, scope: ::Stripe::Apps::SecretService::DeleteWhereParams::Scope).void
}
def initialize(expand: nil, name: nil, scope: nil); end
end
# Create or replace a secret in the secret store.
sig {
params(params: T.any(::Stripe::Apps::SecretService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Apps::Secret)
}
def create(params = {}, opts = {}); end
# Deletes a secret from the secret store by name and scope.
sig {
params(params: T.any(::Stripe::Apps::SecretService::DeleteWhereParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Apps::Secret)
}
def delete_where(params = {}, opts = {}); end
# Finds a secret in the secret store by name and scope.
sig {
params(params: T.any(::Stripe::Apps::SecretService::FindParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Apps::Secret)
}
def find(params = {}, opts = {}); end
# List all secrets stored on the given scope.
sig {
params(params: T.any(::Stripe::Apps::SecretService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
class BalanceService < StripeService
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Retrieves the current account balance, based on the authentication that was used to make the request.
# For a sample request, see [Accounting for negative balances](https://docs.stripe.com/docs/connect/account-balances#accounting-for-negative-balances).
sig {
params(params: T.any(::Stripe::BalanceService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Balance)
}
def retrieve(params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class BalanceSettingsService < StripeService
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
class Payouts < Stripe::RequestParams
class Schedule < Stripe::RequestParams
# How frequently available funds are paid out. One of: `daily`, `manual`, `weekly`, or `monthly`. Default is `daily`.
sig { returns(T.nilable(String)) }
attr_accessor :interval
# The day of the month when available funds are paid out, specified as a number between 1--31. Payouts nominally scheduled between the 29th and 31st of the month are instead sent on the last day of a shorter month. Required and applicable only if `interval` is `monthly`.
sig { returns(T.nilable(Integer)) }
attr_accessor :monthly_anchor
# The day of the week when available funds are paid out (required and applicable only if `interval` is `weekly`.)
sig { returns(T.nilable(String)) }
attr_accessor :weekly_anchor
sig {
params(interval: T.nilable(String), monthly_anchor: T.nilable(Integer), weekly_anchor: T.nilable(String)).void
}
def initialize(interval: nil, monthly_anchor: nil, weekly_anchor: nil); end
end
# Details on when funds from charges are available, and when they are paid out to an external account. For details, see our [Setting Bank and Debit Card Payouts](/connect/bank-transfers#payout-information) documentation.
sig {
returns(T.nilable(::Stripe::BalanceSettingsService::UpdateParams::Payouts::Schedule))
}
attr_accessor :schedule
# The text that appears on the bank account statement for payouts. If not set, this defaults to the platform's bank descriptor as set in the Dashboard.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
sig {
params(schedule: T.nilable(::Stripe::BalanceSettingsService::UpdateParams::Payouts::Schedule), statement_descriptor: T.nilable(String)).void
}
def initialize(schedule: nil, statement_descriptor: nil); end
end
class SettlementTiming < Stripe::RequestParams
# The number of days charge funds are held before becoming available. May also be set to `minimum`, representing the lowest available value for the account country. Default is `minimum`. The `delay_days` parameter remains at the last configured value if `payouts.schedule.interval` is `manual`. [Learn more about controlling payout delay days](/connect/manage-payout-schedule).
sig { returns(T.nilable(Integer)) }
attr_accessor :delay_days
sig { params(delay_days: T.nilable(Integer)).void }
def initialize(delay_days: nil); end
end
# A Boolean indicating whether Stripe should try to reclaim negative balances from an attached bank account. For details, see [Understanding Connect Account Balances](/connect/account-balances).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :debit_negative_balances
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Settings specific to the account's payouts.
sig { returns(T.nilable(::Stripe::BalanceSettingsService::UpdateParams::Payouts)) }
attr_accessor :payouts
# Settings related to the account's balance settlement timing.
sig { returns(T.nilable(::Stripe::BalanceSettingsService::UpdateParams::SettlementTiming)) }
attr_accessor :settlement_timing
sig {
params(debit_negative_balances: T.nilable(T::Boolean), expand: T.nilable(T::Array[String]), payouts: T.nilable(::Stripe::BalanceSettingsService::UpdateParams::Payouts), settlement_timing: T.nilable(::Stripe::BalanceSettingsService::UpdateParams::SettlementTiming)).void
}
def initialize(
debit_negative_balances: nil,
expand: nil,
payouts: nil,
settlement_timing: nil
); end
end
# Retrieves balance settings for a given connected account.
# Related guide: [Making API calls for connected accounts](https://docs.stripe.com/connect/authentication)
sig {
params(params: T.any(::Stripe::BalanceSettingsService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::BalanceSettings)
}
def retrieve(params = {}, opts = {}); end
# Updates balance settings for a given connected account.
# Related guide: [Making API calls for connected accounts](https://docs.stripe.com/connect/authentication)
sig {
params(params: T.any(::Stripe::BalanceSettingsService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::BalanceSettings)
}
def update(params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class BalanceTransactionService < StripeService
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return transactions that were created during the given date interval.
sig {
returns(T.nilable(T.any(::Stripe::BalanceTransactionService::ListParams::Created, Integer)))
}
attr_accessor :created
# Only return transactions in a certain currency. 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).
sig { returns(T.nilable(String)) }
attr_accessor :currency
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# For automatic Stripe payouts only, only returns transactions that were paid out on the specified payout ID.
sig { returns(T.nilable(String)) }
attr_accessor :payout
# Only returns the original transaction.
sig { returns(T.nilable(String)) }
attr_accessor :source
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only returns transactions of the given type. One of: `adjustment`, `advance`, `advance_funding`, `anticipation_repayment`, `application_fee`, `application_fee_refund`, `charge`, `climate_order_purchase`, `climate_order_refund`, `connect_collection_transfer`, `contribution`, `issuing_authorization_hold`, `issuing_authorization_release`, `issuing_dispute`, `issuing_transaction`, `obligation_outbound`, `obligation_reversal_inbound`, `payment`, `payment_failure_refund`, `payment_network_reserve_hold`, `payment_network_reserve_release`, `payment_refund`, `payment_reversal`, `payment_unreconciled`, `payout`, `payout_cancel`, `payout_failure`, `payout_minimum_balance_hold`, `payout_minimum_balance_release`, `refund`, `refund_failure`, `reserve_transaction`, `reserved_funds`, `stripe_fee`, `stripe_fx_fee`, `stripe_balance_payment_debit`, `stripe_balance_payment_debit_reversal`, `tax_fee`, `topup`, `topup_reversal`, `transfer`, `transfer_cancel`, `transfer_failure`, or `transfer_refund`.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(created: T.nilable(T.any(::Stripe::BalanceTransactionService::ListParams::Created, Integer)), currency: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), payout: T.nilable(String), source: T.nilable(String), starting_after: T.nilable(String), type: T.nilable(String)).void
}
def initialize(
created: nil,
currency: nil,
ending_before: nil,
expand: nil,
limit: nil,
payout: nil,
source: nil,
starting_after: nil,
type: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Returns a list of transactions that have contributed to the Stripe account balance (e.g., charges, transfers, and so forth). The transactions are returned in sorted order, with the most recent transactions appearing first.
#
# Note that this endpoint was previously called “Balance history” and used the path /v1/balance/history.
sig {
params(params: T.any(::Stripe::BalanceTransactionService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the balance transaction with the given ID.
#
# Note that this endpoint previously used the path /v1/balance/history/:id.
sig {
params(id: String, params: T.any(::Stripe::BalanceTransactionService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::BalanceTransaction)
}
def retrieve(id, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class BillingService < StripeService
attr_reader :alerts
attr_reader :credit_balance_summary
attr_reader :credit_balance_transactions
attr_reader :credit_grants
attr_reader :meters
attr_reader :meter_events
attr_reader :meter_event_adjustments
end
end
# typed: true
module Stripe
module Billing
class AlertService < StripeService
class ListParams < Stripe::RequestParams
# Filter results to only include this type of alert.
sig { returns(T.nilable(String)) }
attr_accessor :alert_type
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Filter results to only include alerts with the given meter.
sig { returns(T.nilable(String)) }
attr_accessor :meter
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(alert_type: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), meter: T.nilable(String), starting_after: T.nilable(String)).void
}
def initialize(
alert_type: nil,
ending_before: nil,
expand: nil,
limit: nil,
meter: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class UsageThreshold < Stripe::RequestParams
class Filter < Stripe::RequestParams
# Limit the scope to this usage alert only to this customer.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# What type of filter is being applied to this usage alert.
sig { returns(String) }
attr_accessor :type
sig { params(customer: T.nilable(String), type: String).void }
def initialize(customer: nil, type: nil); end
end
# The filters allows limiting the scope of this usage alert. You can only specify up to one filter at this time.
sig {
returns(T.nilable(T::Array[::Stripe::Billing::AlertService::CreateParams::UsageThreshold::Filter]))
}
attr_accessor :filters
# Defines at which value the alert will fire.
sig { returns(Integer) }
attr_accessor :gte
# The [Billing Meter](/api/billing/meter) ID whose usage is monitored.
sig { returns(String) }
attr_accessor :meter
# Whether the alert should only fire only once, or once per billing cycle.
sig { returns(String) }
attr_accessor :recurrence
sig {
params(filters: T.nilable(T::Array[::Stripe::Billing::AlertService::CreateParams::UsageThreshold::Filter]), gte: Integer, meter: String, recurrence: String).void
}
def initialize(filters: nil, gte: nil, meter: nil, recurrence: nil); end
end
# The type of alert to create.
sig { returns(String) }
attr_accessor :alert_type
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The title of the alert.
sig { returns(String) }
attr_accessor :title
# The configuration of the usage threshold.
sig { returns(T.nilable(::Stripe::Billing::AlertService::CreateParams::UsageThreshold)) }
attr_accessor :usage_threshold
sig {
params(alert_type: String, expand: T.nilable(T::Array[String]), title: String, usage_threshold: T.nilable(::Stripe::Billing::AlertService::CreateParams::UsageThreshold)).void
}
def initialize(alert_type: nil, expand: nil, title: nil, usage_threshold: nil); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class ActivateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class ArchiveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class DeactivateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Reactivates this alert, allowing it to trigger again.
sig {
params(id: String, params: T.any(::Stripe::Billing::AlertService::ActivateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Billing::Alert)
}
def activate(id, params = {}, opts = {}); end
# Archives this alert, removing it from the list view and APIs. This is non-reversible.
sig {
params(id: String, params: T.any(::Stripe::Billing::AlertService::ArchiveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Billing::Alert)
}
def archive(id, params = {}, opts = {}); end
# Creates a billing alert
sig {
params(params: T.any(::Stripe::Billing::AlertService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Billing::Alert)
}
def create(params = {}, opts = {}); end
# Deactivates this alert, preventing it from triggering.
sig {
params(id: String, params: T.any(::Stripe::Billing::AlertService::DeactivateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Billing::Alert)
}
def deactivate(id, params = {}, opts = {}); end
# Lists billing active and inactive alerts
sig {
params(params: T.any(::Stripe::Billing::AlertService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves a billing alert given an ID
sig {
params(id: String, params: T.any(::Stripe::Billing::AlertService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Billing::Alert)
}
def retrieve(id, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Billing
class CreditBalanceSummaryService < StripeService
class RetrieveParams < Stripe::RequestParams
class Filter < Stripe::RequestParams
class ApplicabilityScope < Stripe::RequestParams
class Price < Stripe::RequestParams
# The price ID this credit grant should apply to.
sig { returns(String) }
attr_accessor :id
sig { params(id: String).void }
def initialize(id: nil); end
end
# The price type that credit grants can apply to. We currently only support the `metered` price type. Cannot be used in combination with `prices`.
sig { returns(T.nilable(String)) }
attr_accessor :price_type
# A list of prices that the credit grant can apply to. We currently only support the `metered` prices. Cannot be used in combination with `price_type`.
sig {
returns(T.nilable(T::Array[::Stripe::Billing::CreditBalanceSummaryService::RetrieveParams::Filter::ApplicabilityScope::Price]))
}
attr_accessor :prices
sig {
params(price_type: T.nilable(String), prices: T.nilable(T::Array[::Stripe::Billing::CreditBalanceSummaryService::RetrieveParams::Filter::ApplicabilityScope::Price])).void
}
def initialize(price_type: nil, prices: nil); end
end
# The billing credit applicability scope for which to fetch credit balance summary.
sig {
returns(T.nilable(::Stripe::Billing::CreditBalanceSummaryService::RetrieveParams::Filter::ApplicabilityScope))
}
attr_accessor :applicability_scope
# The credit grant for which to fetch credit balance summary.
sig { returns(T.nilable(String)) }
attr_accessor :credit_grant
# Specify the type of this filter.
sig { returns(String) }
attr_accessor :type
sig {
params(applicability_scope: T.nilable(::Stripe::Billing::CreditBalanceSummaryService::RetrieveParams::Filter::ApplicabilityScope), credit_grant: T.nilable(String), type: String).void
}
def initialize(applicability_scope: nil, credit_grant: nil, type: nil); end
end
# The customer for which to fetch credit balance summary.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# The account for which to fetch credit balance summary.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The filter criteria for the credit balance summary.
sig { returns(::Stripe::Billing::CreditBalanceSummaryService::RetrieveParams::Filter) }
attr_accessor :filter
sig {
params(customer: T.nilable(String), customer_account: T.nilable(String), expand: T.nilable(T::Array[String]), filter: ::Stripe::Billing::CreditBalanceSummaryService::RetrieveParams::Filter).void
}
def initialize(customer: nil, customer_account: nil, expand: nil, filter: nil); end
end
# Retrieves the credit balance summary for a customer.
sig {
params(params: T.any(::Stripe::Billing::CreditBalanceSummaryService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Billing::CreditBalanceSummary)
}
def retrieve(params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Billing
class CreditBalanceTransactionService < StripeService
class ListParams < Stripe::RequestParams
# The credit grant for which to fetch credit balance transactions.
sig { returns(T.nilable(String)) }
attr_accessor :credit_grant
# The customer for which to fetch credit balance transactions.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# The account for which to fetch credit balance transactions.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(credit_grant: T.nilable(String), customer: T.nilable(String), customer_account: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
credit_grant: nil,
customer: nil,
customer_account: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Retrieve a list of credit balance transactions.
sig {
params(params: T.any(::Stripe::Billing::CreditBalanceTransactionService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves a credit balance transaction.
sig {
params(id: String, params: T.any(::Stripe::Billing::CreditBalanceTransactionService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Billing::CreditBalanceTransaction)
}
def retrieve(id, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Billing
class CreditGrantService < StripeService
class ListParams < Stripe::RequestParams
# Only return credit grants for this customer.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# Only return credit grants for this account.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(customer: T.nilable(String), customer_account: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
customer: nil,
customer_account: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class Amount < Stripe::RequestParams
class Monetary < Stripe::RequestParams
# Three-letter [ISO code for the currency](https://stripe.com/docs/currencies) of the `value` parameter.
sig { returns(String) }
attr_accessor :currency
# A positive integer representing the amount of the credit grant.
sig { returns(Integer) }
attr_accessor :value
sig { params(currency: String, value: Integer).void }
def initialize(currency: nil, value: nil); end
end
# The monetary amount.
sig {
returns(T.nilable(::Stripe::Billing::CreditGrantService::CreateParams::Amount::Monetary))
}
attr_accessor :monetary
# Specify the type of this amount. We currently only support `monetary` billing credits.
sig { returns(String) }
attr_accessor :type
sig {
params(monetary: T.nilable(::Stripe::Billing::CreditGrantService::CreateParams::Amount::Monetary), type: String).void
}
def initialize(monetary: nil, type: nil); end
end
class ApplicabilityConfig < Stripe::RequestParams
class Scope < Stripe::RequestParams
class Price < Stripe::RequestParams
# The price ID this credit grant should apply to.
sig { returns(String) }
attr_accessor :id
sig { params(id: String).void }
def initialize(id: nil); end
end
# The price type that credit grants can apply to. We currently only support the `metered` price type. Cannot be used in combination with `prices`.
sig { returns(T.nilable(String)) }
attr_accessor :price_type
# A list of prices that the credit grant can apply to. We currently only support the `metered` prices. Cannot be used in combination with `price_type`.
sig {
returns(T.nilable(T::Array[::Stripe::Billing::CreditGrantService::CreateParams::ApplicabilityConfig::Scope::Price]))
}
attr_accessor :prices
sig {
params(price_type: T.nilable(String), prices: T.nilable(T::Array[::Stripe::Billing::CreditGrantService::CreateParams::ApplicabilityConfig::Scope::Price])).void
}
def initialize(price_type: nil, prices: nil); end
end
# Specify the scope of this applicability config.
sig {
returns(::Stripe::Billing::CreditGrantService::CreateParams::ApplicabilityConfig::Scope)
}
attr_accessor :scope
sig {
params(scope: ::Stripe::Billing::CreditGrantService::CreateParams::ApplicabilityConfig::Scope).void
}
def initialize(scope: nil); end
end
# Amount of this credit grant.
sig { returns(::Stripe::Billing::CreditGrantService::CreateParams::Amount) }
attr_accessor :amount
# Configuration specifying what this credit grant applies to. We currently only support `metered` prices that have a [Billing Meter](https://docs.stripe.com/api/billing/meter) attached to them.
sig { returns(::Stripe::Billing::CreditGrantService::CreateParams::ApplicabilityConfig) }
attr_accessor :applicability_config
# The category of this credit grant.
sig { returns(String) }
attr_accessor :category
# ID of the customer to receive the billing credits.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# ID of the account to receive the billing credits.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# The time when the billing credits become effective-when they're eligible for use. It defaults to the current timestamp if not specified.
sig { returns(T.nilable(Integer)) }
attr_accessor :effective_at
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The time when the billing credits expire. If not specified, the billing credits don't expire.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_at
# Set of key-value pairs that you can attach to an object. You can use this to store additional information about the object (for example, cost basis) in a structured format.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# A descriptive name shown in the Dashboard.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The desired priority for applying this credit grant. If not specified, it will be set to the default value of 50. The highest priority is 0 and the lowest is 100.
sig { returns(T.nilable(Integer)) }
attr_accessor :priority
sig {
params(amount: ::Stripe::Billing::CreditGrantService::CreateParams::Amount, applicability_config: ::Stripe::Billing::CreditGrantService::CreateParams::ApplicabilityConfig, category: String, customer: T.nilable(String), customer_account: T.nilable(String), effective_at: T.nilable(Integer), expand: T.nilable(T::Array[String]), expires_at: T.nilable(Integer), metadata: T.nilable(T::Hash[String, String]), name: T.nilable(String), priority: T.nilable(Integer)).void
}
def initialize(
amount: nil,
applicability_config: nil,
category: nil,
customer: nil,
customer_account: nil,
effective_at: nil,
expand: nil,
expires_at: nil,
metadata: nil,
name: nil,
priority: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The time when the billing credits created by this credit grant expire. If set to empty, the billing credits never expire.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :expires_at
# Set of key-value pairs you can attach to an object. You can use this to store additional information about the object (for example, cost basis) in a structured format.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
sig {
params(expand: T.nilable(T::Array[String]), expires_at: T.nilable(T.nilable(T.any(String, Integer))), metadata: T.nilable(T::Hash[String, String])).void
}
def initialize(expand: nil, expires_at: nil, metadata: nil); end
end
class ExpireParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class VoidGrantParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Creates a credit grant.
sig {
params(params: T.any(::Stripe::Billing::CreditGrantService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Billing::CreditGrant)
}
def create(params = {}, opts = {}); end
# Expires a credit grant.
sig {
params(id: String, params: T.any(::Stripe::Billing::CreditGrantService::ExpireParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Billing::CreditGrant)
}
def expire(id, params = {}, opts = {}); end
# Retrieve a list of credit grants.
sig {
params(params: T.any(::Stripe::Billing::CreditGrantService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves a credit grant.
sig {
params(id: String, params: T.any(::Stripe::Billing::CreditGrantService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Billing::CreditGrant)
}
def retrieve(id, params = {}, opts = {}); end
# Updates a credit grant.
sig {
params(id: String, params: T.any(::Stripe::Billing::CreditGrantService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Billing::CreditGrant)
}
def update(id, params = {}, opts = {}); end
# Voids a credit grant.
sig {
params(id: String, params: T.any(::Stripe::Billing::CreditGrantService::VoidGrantParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Billing::CreditGrant)
}
def void_grant(id, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Billing
class MeterService < StripeService
attr_reader :event_summaries
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Filter results to only include meters with the given status.
sig { returns(T.nilable(String)) }
attr_accessor :status
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String), status: T.nilable(String)).void
}
def initialize(
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil,
status: nil
); end
end
class CreateParams < Stripe::RequestParams
class CustomerMapping < Stripe::RequestParams
# The key in the meter event payload to use for mapping the event to a customer.
sig { returns(String) }
attr_accessor :event_payload_key
# The method for mapping a meter event to a customer. Must be `by_id`.
sig { returns(String) }
attr_accessor :type
sig { params(event_payload_key: String, type: String).void }
def initialize(event_payload_key: nil, type: nil); end
end
class DefaultAggregation < Stripe::RequestParams
# Specifies how events are aggregated. Allowed values are `count` to count the number of events, `sum` to sum each event's value and `last` to take the last event's value in the window.
sig { returns(String) }
attr_accessor :formula
sig { params(formula: String).void }
def initialize(formula: nil); end
end
class ValueSettings < Stripe::RequestParams
# The key in the usage event payload to use as the value for this meter. For example, if the event payload contains usage on a `bytes_used` field, then set the event_payload_key to "bytes_used".
sig { returns(String) }
attr_accessor :event_payload_key
sig { params(event_payload_key: String).void }
def initialize(event_payload_key: nil); end
end
# Fields that specify how to map a meter event to a customer.
sig { returns(T.nilable(::Stripe::Billing::MeterService::CreateParams::CustomerMapping)) }
attr_accessor :customer_mapping
# The default settings to aggregate a meter's events with.
sig { returns(::Stripe::Billing::MeterService::CreateParams::DefaultAggregation) }
attr_accessor :default_aggregation
# The meter’s name. Not visible to the customer.
sig { returns(String) }
attr_accessor :display_name
# The name of the meter event to record usage for. Corresponds with the `event_name` field on meter events.
sig { returns(String) }
attr_accessor :event_name
# The time window to pre-aggregate meter events for, if any.
sig { returns(T.nilable(String)) }
attr_accessor :event_time_window
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Fields that specify how to calculate a meter event's value.
sig { returns(T.nilable(::Stripe::Billing::MeterService::CreateParams::ValueSettings)) }
attr_accessor :value_settings
sig {
params(customer_mapping: T.nilable(::Stripe::Billing::MeterService::CreateParams::CustomerMapping), default_aggregation: ::Stripe::Billing::MeterService::CreateParams::DefaultAggregation, display_name: String, event_name: String, event_time_window: T.nilable(String), expand: T.nilable(T::Array[String]), value_settings: T.nilable(::Stripe::Billing::MeterService::CreateParams::ValueSettings)).void
}
def initialize(
customer_mapping: nil,
default_aggregation: nil,
display_name: nil,
event_name: nil,
event_time_window: nil,
expand: nil,
value_settings: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
# The meter’s name. Not visible to the customer.
sig { returns(T.nilable(String)) }
attr_accessor :display_name
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(display_name: T.nilable(String), expand: T.nilable(T::Array[String])).void }
def initialize(display_name: nil, expand: nil); end
end
class DeactivateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class ReactivateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Creates a billing meter.
sig {
params(params: T.any(::Stripe::Billing::MeterService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Billing::Meter)
}
def create(params = {}, opts = {}); end
# When a meter is deactivated, no more meter events will be accepted for this meter. You can't attach a deactivated meter to a price.
sig {
params(id: String, params: T.any(::Stripe::Billing::MeterService::DeactivateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Billing::Meter)
}
def deactivate(id, params = {}, opts = {}); end
# Retrieve a list of billing meters.
sig {
params(params: T.any(::Stripe::Billing::MeterService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# When a meter is reactivated, events for this meter can be accepted and you can attach the meter to a price.
sig {
params(id: String, params: T.any(::Stripe::Billing::MeterService::ReactivateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Billing::Meter)
}
def reactivate(id, params = {}, opts = {}); end
# Retrieves a billing meter given an ID.
sig {
params(id: String, params: T.any(::Stripe::Billing::MeterService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Billing::Meter)
}
def retrieve(id, params = {}, opts = {}); end
# Updates a billing meter.
sig {
params(id: String, params: T.any(::Stripe::Billing::MeterService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Billing::Meter)
}
def update(id, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Billing
class MeterEventSummaryService < StripeService
class ListParams < Stripe::RequestParams
# The customer for which to fetch event summaries.
sig { returns(String) }
attr_accessor :customer
# The timestamp from when to stop aggregating meter events (exclusive). Must be aligned with minute boundaries.
sig { returns(Integer) }
attr_accessor :end_time
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# The timestamp from when to start aggregating meter events (inclusive). Must be aligned with minute boundaries.
sig { returns(Integer) }
attr_accessor :start_time
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Specifies what granularity to use when generating event summaries. If not specified, a single event summary would be returned for the specified time range. For hourly granularity, start and end times must align with hour boundaries (e.g., 00:00, 01:00, ..., 23:00). For daily granularity, start and end times must align with UTC day boundaries (00:00 UTC).
sig { returns(T.nilable(String)) }
attr_accessor :value_grouping_window
sig {
params(customer: String, end_time: Integer, ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), start_time: Integer, starting_after: T.nilable(String), value_grouping_window: T.nilable(String)).void
}
def initialize(
customer: nil,
end_time: nil,
ending_before: nil,
expand: nil,
limit: nil,
start_time: nil,
starting_after: nil,
value_grouping_window: nil
); end
end
# Retrieve a list of billing meter event summaries.
sig {
params(id: String, params: T.any(::Stripe::Billing::MeterEventSummaryService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(id, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Billing
class MeterEventService < StripeService
class CreateParams < Stripe::RequestParams
# The name of the meter event. Corresponds with the `event_name` field on a meter.
sig { returns(String) }
attr_accessor :event_name
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A unique identifier for the event. If not provided, one is generated. We recommend using UUID-like identifiers. We will enforce uniqueness within a rolling period of at least 24 hours. The enforcement of uniqueness primarily addresses issues arising from accidental retries or other problems occurring within extremely brief time intervals. This approach helps prevent duplicate entries and ensures data integrity in high-frequency operations.
sig { returns(T.nilable(String)) }
attr_accessor :identifier
# The payload of the event. This must contain the fields corresponding to a meter's `customer_mapping.event_payload_key` (default is `stripe_customer_id`) and `value_settings.event_payload_key` (default is `value`). Read more about the [payload](https://docs.stripe.com/billing/subscriptions/usage-based/recording-usage#payload-key-overrides).
sig { returns(T::Hash[String, String]) }
attr_accessor :payload
# The time of the event. Measured in seconds since the Unix epoch. Must be within the past 35 calendar days or up to 5 minutes in the future. Defaults to current timestamp if not specified.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
sig {
params(event_name: String, expand: T.nilable(T::Array[String]), identifier: T.nilable(String), payload: T::Hash[String, String], timestamp: T.nilable(Integer)).void
}
def initialize(
event_name: nil,
expand: nil,
identifier: nil,
payload: nil,
timestamp: nil
); end
end
# Creates a billing meter event.
sig {
params(params: T.any(::Stripe::Billing::MeterEventService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Billing::MeterEvent)
}
def create(params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Billing
class MeterEventAdjustmentService < StripeService
class CreateParams < Stripe::RequestParams
class Cancel < Stripe::RequestParams
# Unique identifier for the event. You can only cancel events within 24 hours of Stripe receiving them.
sig { returns(T.nilable(String)) }
attr_accessor :identifier
sig { params(identifier: T.nilable(String)).void }
def initialize(identifier: nil); end
end
# Specifies which event to cancel.
sig {
returns(T.nilable(::Stripe::Billing::MeterEventAdjustmentService::CreateParams::Cancel))
}
attr_accessor :cancel
# The name of the meter event. Corresponds with the `event_name` field on a meter.
sig { returns(String) }
attr_accessor :event_name
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Specifies whether to cancel a single event or a range of events for a time period. Time period cancellation is not supported yet.
sig { returns(String) }
attr_accessor :type
sig {
params(cancel: T.nilable(::Stripe::Billing::MeterEventAdjustmentService::CreateParams::Cancel), event_name: String, expand: T.nilable(T::Array[String]), type: String).void
}
def initialize(cancel: nil, event_name: nil, expand: nil, type: nil); end
end
# Creates a billing meter event adjustment.
sig {
params(params: T.any(::Stripe::Billing::MeterEventAdjustmentService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Billing::MeterEventAdjustment)
}
def create(params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
class BillingPortalService < StripeService
attr_reader :configurations
attr_reader :sessions
end
end
# typed: true
module Stripe
module BillingPortal
class ConfigurationService < StripeService
class ListParams < Stripe::RequestParams
# Only return configurations that are active or inactive (e.g., pass `true` to only list active configurations).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Only return the default or non-default configurations (e.g., pass `true` to only list the default configuration).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :is_default
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(active: T.nilable(T::Boolean), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), is_default: T.nilable(T::Boolean), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
active: nil,
ending_before: nil,
expand: nil,
is_default: nil,
limit: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class BusinessProfile < Stripe::RequestParams
# The messaging shown to customers in the portal.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :headline
# A link to the business’s publicly available privacy policy.
sig { returns(T.nilable(String)) }
attr_accessor :privacy_policy_url
# A link to the business’s publicly available terms of service.
sig { returns(T.nilable(String)) }
attr_accessor :terms_of_service_url
sig {
params(headline: T.nilable(T.nilable(String)), privacy_policy_url: T.nilable(String), terms_of_service_url: T.nilable(String)).void
}
def initialize(headline: nil, privacy_policy_url: nil, terms_of_service_url: nil); end
end
class Features < Stripe::RequestParams
class CustomerUpdate < Stripe::RequestParams
# The types of customer updates that are supported. When empty, customers are not updateable.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :allowed_updates
# Whether the feature is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
sig {
params(allowed_updates: T.nilable(T.nilable(T.any(String, T::Array[String]))), enabled: T::Boolean).void
}
def initialize(allowed_updates: nil, enabled: nil); end
end
class InvoiceHistory < Stripe::RequestParams
# Whether the feature is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
sig { params(enabled: T::Boolean).void }
def initialize(enabled: nil); end
end
class PaymentMethodUpdate < Stripe::RequestParams
# Whether the feature is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
sig { params(enabled: T::Boolean).void }
def initialize(enabled: nil); end
end
class SubscriptionCancel < Stripe::RequestParams
class CancellationReason < Stripe::RequestParams
# Whether the feature is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# Which cancellation reasons will be given as options to the customer.
sig { returns(T.nilable(T.any(String, T::Array[String]))) }
attr_accessor :options
sig {
params(enabled: T::Boolean, options: T.nilable(T.any(String, T::Array[String]))).void
}
def initialize(enabled: nil, options: nil); end
end
# Whether the cancellation reasons will be collected in the portal and which options are exposed to the customer
sig {
returns(T.nilable(::Stripe::BillingPortal::ConfigurationService::CreateParams::Features::SubscriptionCancel::CancellationReason))
}
attr_accessor :cancellation_reason
# Whether the feature is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# Whether to cancel subscriptions immediately or at the end of the billing period.
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Whether to create prorations when canceling subscriptions. Possible values are `none` and `create_prorations`, which is only compatible with `mode=immediately`. Passing `always_invoice` will result in an error. No prorations are generated when canceling a subscription at the end of its natural billing period.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
sig {
params(cancellation_reason: T.nilable(::Stripe::BillingPortal::ConfigurationService::CreateParams::Features::SubscriptionCancel::CancellationReason), enabled: T::Boolean, mode: T.nilable(String), proration_behavior: T.nilable(String)).void
}
def initialize(
cancellation_reason: nil,
enabled: nil,
mode: nil,
proration_behavior: nil
); end
end
class SubscriptionUpdate < Stripe::RequestParams
class Product < Stripe::RequestParams
# The list of price IDs for the product that a subscription can be updated to.
sig { returns(T::Array[String]) }
attr_accessor :prices
# The product id.
sig { returns(String) }
attr_accessor :product
sig { params(prices: T::Array[String], product: String).void }
def initialize(prices: nil, product: nil); end
end
class ScheduleAtPeriodEnd < Stripe::RequestParams
class Condition < Stripe::RequestParams
# The type of condition.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
# List of conditions. When any condition is true, the update will be scheduled at the end of the current period.
sig {
returns(T.nilable(T::Array[::Stripe::BillingPortal::ConfigurationService::CreateParams::Features::SubscriptionUpdate::ScheduleAtPeriodEnd::Condition]))
}
attr_accessor :conditions
sig {
params(conditions: T.nilable(T::Array[::Stripe::BillingPortal::ConfigurationService::CreateParams::Features::SubscriptionUpdate::ScheduleAtPeriodEnd::Condition])).void
}
def initialize(conditions: nil); end
end
# The types of subscription updates that are supported. When empty, subscriptions are not updateable.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :default_allowed_updates
# Whether the feature is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The list of up to 10 products that support subscription updates.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::BillingPortal::ConfigurationService::CreateParams::Features::SubscriptionUpdate::Product]))))
}
attr_accessor :products
# Determines how to handle prorations resulting from subscription updates. Valid values are `none`, `create_prorations`, and `always_invoice`.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
# Setting to control when an update should be scheduled at the end of the period instead of applying immediately.
sig {
returns(T.nilable(::Stripe::BillingPortal::ConfigurationService::CreateParams::Features::SubscriptionUpdate::ScheduleAtPeriodEnd))
}
attr_accessor :schedule_at_period_end
sig {
params(default_allowed_updates: T.nilable(T.nilable(T.any(String, T::Array[String]))), enabled: T::Boolean, products: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::BillingPortal::ConfigurationService::CreateParams::Features::SubscriptionUpdate::Product]))), proration_behavior: T.nilable(String), schedule_at_period_end: T.nilable(::Stripe::BillingPortal::ConfigurationService::CreateParams::Features::SubscriptionUpdate::ScheduleAtPeriodEnd)).void
}
def initialize(
default_allowed_updates: nil,
enabled: nil,
products: nil,
proration_behavior: nil,
schedule_at_period_end: nil
); end
end
# Information about updating the customer details in the portal.
sig {
returns(T.nilable(::Stripe::BillingPortal::ConfigurationService::CreateParams::Features::CustomerUpdate))
}
attr_accessor :customer_update
# Information about showing the billing history in the portal.
sig {
returns(T.nilable(::Stripe::BillingPortal::ConfigurationService::CreateParams::Features::InvoiceHistory))
}
attr_accessor :invoice_history
# Information about updating payment methods in the portal.
sig {
returns(T.nilable(::Stripe::BillingPortal::ConfigurationService::CreateParams::Features::PaymentMethodUpdate))
}
attr_accessor :payment_method_update
# Information about canceling subscriptions in the portal.
sig {
returns(T.nilable(::Stripe::BillingPortal::ConfigurationService::CreateParams::Features::SubscriptionCancel))
}
attr_accessor :subscription_cancel
# Information about updating subscriptions in the portal.
sig {
returns(T.nilable(::Stripe::BillingPortal::ConfigurationService::CreateParams::Features::SubscriptionUpdate))
}
attr_accessor :subscription_update
sig {
params(customer_update: T.nilable(::Stripe::BillingPortal::ConfigurationService::CreateParams::Features::CustomerUpdate), invoice_history: T.nilable(::Stripe::BillingPortal::ConfigurationService::CreateParams::Features::InvoiceHistory), payment_method_update: T.nilable(::Stripe::BillingPortal::ConfigurationService::CreateParams::Features::PaymentMethodUpdate), subscription_cancel: T.nilable(::Stripe::BillingPortal::ConfigurationService::CreateParams::Features::SubscriptionCancel), subscription_update: T.nilable(::Stripe::BillingPortal::ConfigurationService::CreateParams::Features::SubscriptionUpdate)).void
}
def initialize(
customer_update: nil,
invoice_history: nil,
payment_method_update: nil,
subscription_cancel: nil,
subscription_update: nil
); end
end
class LoginPage < Stripe::RequestParams
# Set to `true` to generate a shareable URL [`login_page.url`](https://stripe.com/docs/api/customer_portal/configuration#portal_configuration_object-login_page-url) that will take your customers to a hosted login page for the customer portal.
sig { returns(T::Boolean) }
attr_accessor :enabled
sig { params(enabled: T::Boolean).void }
def initialize(enabled: nil); end
end
# The business information shown to customers in the portal.
sig {
returns(T.nilable(::Stripe::BillingPortal::ConfigurationService::CreateParams::BusinessProfile))
}
attr_accessor :business_profile
# The default URL to redirect customers to when they click on the portal's link to return to your website. This can be [overriden](https://stripe.com/docs/api/customer_portal/sessions/create#create_portal_session-return_url) when creating the session.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :default_return_url
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Information about the features available in the portal.
sig { returns(::Stripe::BillingPortal::ConfigurationService::CreateParams::Features) }
attr_accessor :features
# The hosted login page for this configuration. Learn more about the portal login page in our [integration docs](https://stripe.com/docs/billing/subscriptions/integrating-customer-portal#share).
sig {
returns(T.nilable(::Stripe::BillingPortal::ConfigurationService::CreateParams::LoginPage))
}
attr_accessor :login_page
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
sig {
params(business_profile: T.nilable(::Stripe::BillingPortal::ConfigurationService::CreateParams::BusinessProfile), default_return_url: T.nilable(T.nilable(String)), expand: T.nilable(T::Array[String]), features: ::Stripe::BillingPortal::ConfigurationService::CreateParams::Features, login_page: T.nilable(::Stripe::BillingPortal::ConfigurationService::CreateParams::LoginPage), metadata: T.nilable(T::Hash[String, String])).void
}
def initialize(
business_profile: nil,
default_return_url: nil,
expand: nil,
features: nil,
login_page: nil,
metadata: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
class BusinessProfile < Stripe::RequestParams
# The messaging shown to customers in the portal.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :headline
# A link to the business’s publicly available privacy policy.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :privacy_policy_url
# A link to the business’s publicly available terms of service.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :terms_of_service_url
sig {
params(headline: T.nilable(T.nilable(String)), privacy_policy_url: T.nilable(T.nilable(String)), terms_of_service_url: T.nilable(T.nilable(String))).void
}
def initialize(headline: nil, privacy_policy_url: nil, terms_of_service_url: nil); end
end
class Features < Stripe::RequestParams
class CustomerUpdate < Stripe::RequestParams
# The types of customer updates that are supported. When empty, customers are not updateable.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :allowed_updates
# Whether the feature is enabled.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :enabled
sig {
params(allowed_updates: T.nilable(T.nilable(T.any(String, T::Array[String]))), enabled: T.nilable(T::Boolean)).void
}
def initialize(allowed_updates: nil, enabled: nil); end
end
class InvoiceHistory < Stripe::RequestParams
# Whether the feature is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
sig { params(enabled: T::Boolean).void }
def initialize(enabled: nil); end
end
class PaymentMethodUpdate < Stripe::RequestParams
# Whether the feature is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
sig { params(enabled: T::Boolean).void }
def initialize(enabled: nil); end
end
class SubscriptionCancel < Stripe::RequestParams
class CancellationReason < Stripe::RequestParams
# Whether the feature is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# Which cancellation reasons will be given as options to the customer.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :options
sig {
params(enabled: T::Boolean, options: T.nilable(T.nilable(T.any(String, T::Array[String])))).void
}
def initialize(enabled: nil, options: nil); end
end
# Whether the cancellation reasons will be collected in the portal and which options are exposed to the customer
sig {
returns(T.nilable(::Stripe::BillingPortal::ConfigurationService::UpdateParams::Features::SubscriptionCancel::CancellationReason))
}
attr_accessor :cancellation_reason
# Whether the feature is enabled.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :enabled
# Whether to cancel subscriptions immediately or at the end of the billing period.
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Whether to create prorations when canceling subscriptions. Possible values are `none` and `create_prorations`, which is only compatible with `mode=immediately`. Passing `always_invoice` will result in an error. No prorations are generated when canceling a subscription at the end of its natural billing period.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
sig {
params(cancellation_reason: T.nilable(::Stripe::BillingPortal::ConfigurationService::UpdateParams::Features::SubscriptionCancel::CancellationReason), enabled: T.nilable(T::Boolean), mode: T.nilable(String), proration_behavior: T.nilable(String)).void
}
def initialize(
cancellation_reason: nil,
enabled: nil,
mode: nil,
proration_behavior: nil
); end
end
class SubscriptionUpdate < Stripe::RequestParams
class Product < Stripe::RequestParams
# The list of price IDs for the product that a subscription can be updated to.
sig { returns(T::Array[String]) }
attr_accessor :prices
# The product id.
sig { returns(String) }
attr_accessor :product
sig { params(prices: T::Array[String], product: String).void }
def initialize(prices: nil, product: nil); end
end
class ScheduleAtPeriodEnd < Stripe::RequestParams
class Condition < Stripe::RequestParams
# The type of condition.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
# List of conditions. When any condition is true, the update will be scheduled at the end of the current period.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::BillingPortal::ConfigurationService::UpdateParams::Features::SubscriptionUpdate::ScheduleAtPeriodEnd::Condition]))))
}
attr_accessor :conditions
sig {
params(conditions: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::BillingPortal::ConfigurationService::UpdateParams::Features::SubscriptionUpdate::ScheduleAtPeriodEnd::Condition])))).void
}
def initialize(conditions: nil); end
end
# The types of subscription updates that are supported. When empty, subscriptions are not updateable.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :default_allowed_updates
# Whether the feature is enabled.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :enabled
# The list of up to 10 products that support subscription updates.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::BillingPortal::ConfigurationService::UpdateParams::Features::SubscriptionUpdate::Product]))))
}
attr_accessor :products
# Determines how to handle prorations resulting from subscription updates. Valid values are `none`, `create_prorations`, and `always_invoice`.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
# Setting to control when an update should be scheduled at the end of the period instead of applying immediately.
sig {
returns(T.nilable(::Stripe::BillingPortal::ConfigurationService::UpdateParams::Features::SubscriptionUpdate::ScheduleAtPeriodEnd))
}
attr_accessor :schedule_at_period_end
sig {
params(default_allowed_updates: T.nilable(T.nilable(T.any(String, T::Array[String]))), enabled: T.nilable(T::Boolean), products: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::BillingPortal::ConfigurationService::UpdateParams::Features::SubscriptionUpdate::Product]))), proration_behavior: T.nilable(String), schedule_at_period_end: T.nilable(::Stripe::BillingPortal::ConfigurationService::UpdateParams::Features::SubscriptionUpdate::ScheduleAtPeriodEnd)).void
}
def initialize(
default_allowed_updates: nil,
enabled: nil,
products: nil,
proration_behavior: nil,
schedule_at_period_end: nil
); end
end
# Information about updating the customer details in the portal.
sig {
returns(T.nilable(::Stripe::BillingPortal::ConfigurationService::UpdateParams::Features::CustomerUpdate))
}
attr_accessor :customer_update
# Information about showing the billing history in the portal.
sig {
returns(T.nilable(::Stripe::BillingPortal::ConfigurationService::UpdateParams::Features::InvoiceHistory))
}
attr_accessor :invoice_history
# Information about updating payment methods in the portal.
sig {
returns(T.nilable(::Stripe::BillingPortal::ConfigurationService::UpdateParams::Features::PaymentMethodUpdate))
}
attr_accessor :payment_method_update
# Information about canceling subscriptions in the portal.
sig {
returns(T.nilable(::Stripe::BillingPortal::ConfigurationService::UpdateParams::Features::SubscriptionCancel))
}
attr_accessor :subscription_cancel
# Information about updating subscriptions in the portal.
sig {
returns(T.nilable(::Stripe::BillingPortal::ConfigurationService::UpdateParams::Features::SubscriptionUpdate))
}
attr_accessor :subscription_update
sig {
params(customer_update: T.nilable(::Stripe::BillingPortal::ConfigurationService::UpdateParams::Features::CustomerUpdate), invoice_history: T.nilable(::Stripe::BillingPortal::ConfigurationService::UpdateParams::Features::InvoiceHistory), payment_method_update: T.nilable(::Stripe::BillingPortal::ConfigurationService::UpdateParams::Features::PaymentMethodUpdate), subscription_cancel: T.nilable(::Stripe::BillingPortal::ConfigurationService::UpdateParams::Features::SubscriptionCancel), subscription_update: T.nilable(::Stripe::BillingPortal::ConfigurationService::UpdateParams::Features::SubscriptionUpdate)).void
}
def initialize(
customer_update: nil,
invoice_history: nil,
payment_method_update: nil,
subscription_cancel: nil,
subscription_update: nil
); end
end
class LoginPage < Stripe::RequestParams
# Set to `true` to generate a shareable URL [`login_page.url`](https://stripe.com/docs/api/customer_portal/configuration#portal_configuration_object-login_page-url) that will take your customers to a hosted login page for the customer portal.
#
# Set to `false` to deactivate the `login_page.url`.
sig { returns(T::Boolean) }
attr_accessor :enabled
sig { params(enabled: T::Boolean).void }
def initialize(enabled: nil); end
end
# Whether the configuration is active and can be used to create portal sessions.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# The business information shown to customers in the portal.
sig {
returns(T.nilable(::Stripe::BillingPortal::ConfigurationService::UpdateParams::BusinessProfile))
}
attr_accessor :business_profile
# The default URL to redirect customers to when they click on the portal's link to return to your website. This can be [overriden](https://stripe.com/docs/api/customer_portal/sessions/create#create_portal_session-return_url) when creating the session.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :default_return_url
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Information about the features available in the portal.
sig {
returns(T.nilable(::Stripe::BillingPortal::ConfigurationService::UpdateParams::Features))
}
attr_accessor :features
# The hosted login page for this configuration. Learn more about the portal login page in our [integration docs](https://stripe.com/docs/billing/subscriptions/integrating-customer-portal#share).
sig {
returns(T.nilable(::Stripe::BillingPortal::ConfigurationService::UpdateParams::LoginPage))
}
attr_accessor :login_page
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
sig {
params(active: T.nilable(T::Boolean), business_profile: T.nilable(::Stripe::BillingPortal::ConfigurationService::UpdateParams::BusinessProfile), default_return_url: T.nilable(T.nilable(String)), expand: T.nilable(T::Array[String]), features: T.nilable(::Stripe::BillingPortal::ConfigurationService::UpdateParams::Features), login_page: T.nilable(::Stripe::BillingPortal::ConfigurationService::UpdateParams::LoginPage), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String])))).void
}
def initialize(
active: nil,
business_profile: nil,
default_return_url: nil,
expand: nil,
features: nil,
login_page: nil,
metadata: nil
); end
end
# Creates a configuration that describes the functionality and behavior of a PortalSession
sig {
params(params: T.any(::Stripe::BillingPortal::ConfigurationService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::BillingPortal::Configuration)
}
def create(params = {}, opts = {}); end
# Returns a list of configurations that describe the functionality of the customer portal.
sig {
params(params: T.any(::Stripe::BillingPortal::ConfigurationService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves a configuration that describes the functionality of the customer portal.
sig {
params(configuration: String, params: T.any(::Stripe::BillingPortal::ConfigurationService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::BillingPortal::Configuration)
}
def retrieve(configuration, params = {}, opts = {}); end
# Updates a configuration that describes the functionality of the customer portal.
sig {
params(configuration: String, params: T.any(::Stripe::BillingPortal::ConfigurationService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::BillingPortal::Configuration)
}
def update(configuration, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module BillingPortal
class SessionService < StripeService
class CreateParams < Stripe::RequestParams
class FlowData < Stripe::RequestParams
class AfterCompletion < Stripe::RequestParams
class HostedConfirmation < Stripe::RequestParams
# A custom message to display to the customer after the flow is completed.
sig { returns(T.nilable(String)) }
attr_accessor :custom_message
sig { params(custom_message: T.nilable(String)).void }
def initialize(custom_message: nil); end
end
class Redirect < Stripe::RequestParams
# The URL the customer will be redirected to after the flow is completed.
sig { returns(String) }
attr_accessor :return_url
sig { params(return_url: String).void }
def initialize(return_url: nil); end
end
# Configuration when `after_completion.type=hosted_confirmation`.
sig {
returns(T.nilable(::Stripe::BillingPortal::SessionService::CreateParams::FlowData::AfterCompletion::HostedConfirmation))
}
attr_accessor :hosted_confirmation
# Configuration when `after_completion.type=redirect`.
sig {
returns(T.nilable(::Stripe::BillingPortal::SessionService::CreateParams::FlowData::AfterCompletion::Redirect))
}
attr_accessor :redirect
# The specified behavior after the flow is completed.
sig { returns(String) }
attr_accessor :type
sig {
params(hosted_confirmation: T.nilable(::Stripe::BillingPortal::SessionService::CreateParams::FlowData::AfterCompletion::HostedConfirmation), redirect: T.nilable(::Stripe::BillingPortal::SessionService::CreateParams::FlowData::AfterCompletion::Redirect), type: String).void
}
def initialize(hosted_confirmation: nil, redirect: nil, type: nil); end
end
class SubscriptionCancel < Stripe::RequestParams
class Retention < Stripe::RequestParams
class CouponOffer < Stripe::RequestParams
# The ID of the coupon to be offered.
sig { returns(String) }
attr_accessor :coupon
sig { params(coupon: String).void }
def initialize(coupon: nil); end
end
# Configuration when `retention.type=coupon_offer`.
sig {
returns(::Stripe::BillingPortal::SessionService::CreateParams::FlowData::SubscriptionCancel::Retention::CouponOffer)
}
attr_accessor :coupon_offer
# Type of retention strategy to use with the customer.
sig { returns(String) }
attr_accessor :type
sig {
params(coupon_offer: ::Stripe::BillingPortal::SessionService::CreateParams::FlowData::SubscriptionCancel::Retention::CouponOffer, type: String).void
}
def initialize(coupon_offer: nil, type: nil); end
end
# Specify a retention strategy to be used in the cancellation flow.
sig {
returns(T.nilable(::Stripe::BillingPortal::SessionService::CreateParams::FlowData::SubscriptionCancel::Retention))
}
attr_accessor :retention
# The ID of the subscription to be canceled.
sig { returns(String) }
attr_accessor :subscription
sig {
params(retention: T.nilable(::Stripe::BillingPortal::SessionService::CreateParams::FlowData::SubscriptionCancel::Retention), subscription: String).void
}
def initialize(retention: nil, subscription: nil); end
end
class SubscriptionUpdate < Stripe::RequestParams
# The ID of the subscription to be updated.
sig { returns(String) }
attr_accessor :subscription
sig { params(subscription: String).void }
def initialize(subscription: nil); end
end
class SubscriptionUpdateConfirm < Stripe::RequestParams
class Discount < Stripe::RequestParams
# The ID of the coupon to apply to this subscription update.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# The ID of a promotion code to apply to this subscription update.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig { params(coupon: T.nilable(String), promotion_code: T.nilable(String)).void }
def initialize(coupon: nil, promotion_code: nil); end
end
class Item < Stripe::RequestParams
# The ID of the [subscription item](https://stripe.com/docs/api/subscriptions/object#subscription_object-items-data-id) to be updated.
sig { returns(String) }
attr_accessor :id
# The price the customer should subscribe to through this flow. The price must also be included in the configuration's [`features.subscription_update.products`](https://stripe.com/docs/api/customer_portal/configuration#portal_configuration_object-features-subscription_update-products).
sig { returns(T.nilable(String)) }
attr_accessor :price
# [Quantity](https://stripe.com/docs/subscriptions/quantities) for this item that the customer should subscribe to through this flow.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
sig {
params(id: String, price: T.nilable(String), quantity: T.nilable(Integer)).void
}
def initialize(id: nil, price: nil, quantity: nil); end
end
# The coupon or promotion code to apply to this subscription update. Currently, only up to one may be specified.
sig {
returns(T.nilable(T::Array[::Stripe::BillingPortal::SessionService::CreateParams::FlowData::SubscriptionUpdateConfirm::Discount]))
}
attr_accessor :discounts
# The [subscription item](https://stripe.com/docs/api/subscription_items) to be updated through this flow. Currently, only up to one may be specified and subscriptions with multiple items are not updatable.
sig {
returns(T::Array[::Stripe::BillingPortal::SessionService::CreateParams::FlowData::SubscriptionUpdateConfirm::Item])
}
attr_accessor :items
# The ID of the subscription to be updated.
sig { returns(String) }
attr_accessor :subscription
sig {
params(discounts: T.nilable(T::Array[::Stripe::BillingPortal::SessionService::CreateParams::FlowData::SubscriptionUpdateConfirm::Discount]), items: T::Array[::Stripe::BillingPortal::SessionService::CreateParams::FlowData::SubscriptionUpdateConfirm::Item], subscription: String).void
}
def initialize(discounts: nil, items: nil, subscription: nil); end
end
# Behavior after the flow is completed.
sig {
returns(T.nilable(::Stripe::BillingPortal::SessionService::CreateParams::FlowData::AfterCompletion))
}
attr_accessor :after_completion
# Configuration when `flow_data.type=subscription_cancel`.
sig {
returns(T.nilable(::Stripe::BillingPortal::SessionService::CreateParams::FlowData::SubscriptionCancel))
}
attr_accessor :subscription_cancel
# Configuration when `flow_data.type=subscription_update`.
sig {
returns(T.nilable(::Stripe::BillingPortal::SessionService::CreateParams::FlowData::SubscriptionUpdate))
}
attr_accessor :subscription_update
# Configuration when `flow_data.type=subscription_update_confirm`.
sig {
returns(T.nilable(::Stripe::BillingPortal::SessionService::CreateParams::FlowData::SubscriptionUpdateConfirm))
}
attr_accessor :subscription_update_confirm
# Type of flow that the customer will go through.
sig { returns(String) }
attr_accessor :type
sig {
params(after_completion: T.nilable(::Stripe::BillingPortal::SessionService::CreateParams::FlowData::AfterCompletion), subscription_cancel: T.nilable(::Stripe::BillingPortal::SessionService::CreateParams::FlowData::SubscriptionCancel), subscription_update: T.nilable(::Stripe::BillingPortal::SessionService::CreateParams::FlowData::SubscriptionUpdate), subscription_update_confirm: T.nilable(::Stripe::BillingPortal::SessionService::CreateParams::FlowData::SubscriptionUpdateConfirm), type: String).void
}
def initialize(
after_completion: nil,
subscription_cancel: nil,
subscription_update: nil,
subscription_update_confirm: nil,
type: nil
); end
end
# The ID of an existing [configuration](https://stripe.com/docs/api/customer_portal/configuration) to use for this session, describing its functionality and features. If not specified, the session uses the default configuration.
sig { returns(T.nilable(String)) }
attr_accessor :configuration
# The ID of an existing customer.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# The ID of an existing account.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Information about a specific flow for the customer to go through. See the [docs](https://stripe.com/docs/customer-management/portal-deep-links) to learn more about using customer portal deep links and flows.
sig { returns(T.nilable(::Stripe::BillingPortal::SessionService::CreateParams::FlowData)) }
attr_accessor :flow_data
# The IETF language tag of the locale customer portal is displayed in. If blank or auto, the customer’s `preferred_locales` or browser’s locale is used.
sig { returns(T.nilable(String)) }
attr_accessor :locale
# The `on_behalf_of` account to use for this session. When specified, only subscriptions and invoices with this `on_behalf_of` account appear in the portal. For more information, see the [docs](https://stripe.com/docs/connect/separate-charges-and-transfers#settlement-merchant). Use the [Accounts API](https://stripe.com/docs/api/accounts/object#account_object-settings-branding) to modify the `on_behalf_of` account's branding settings, which the portal displays.
sig { returns(T.nilable(String)) }
attr_accessor :on_behalf_of
# The default URL to redirect customers to when they click on the portal's link to return to your website.
sig { returns(T.nilable(String)) }
attr_accessor :return_url
sig {
params(configuration: T.nilable(String), customer: T.nilable(String), customer_account: T.nilable(String), expand: T.nilable(T::Array[String]), flow_data: T.nilable(::Stripe::BillingPortal::SessionService::CreateParams::FlowData), locale: T.nilable(String), on_behalf_of: T.nilable(String), return_url: T.nilable(String)).void
}
def initialize(
configuration: nil,
customer: nil,
customer_account: nil,
expand: nil,
flow_data: nil,
locale: nil,
on_behalf_of: nil,
return_url: nil
); end
end
# Creates a session of the customer portal.
sig {
params(params: T.any(::Stripe::BillingPortal::SessionService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::BillingPortal::Session)
}
def create(params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
class CapitalService < StripeService
attr_reader :financing_offers
attr_reader :financing_summary
attr_reader :financing_transactions
end
end
# typed: true
module Stripe
module Capital
class FinancingOfferService < StripeService
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# limit list to offers belonging to given connected account
sig { returns(T.nilable(String)) }
attr_accessor :connected_account
# Only return offers that were created during the given date interval.
sig {
returns(T.nilable(T.any(::Stripe::Capital::FinancingOfferService::ListParams::Created, Integer)))
}
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# limit list to offers with given status
sig { returns(T.nilable(String)) }
attr_accessor :status
sig {
params(connected_account: T.nilable(String), created: T.nilable(T.any(::Stripe::Capital::FinancingOfferService::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String), status: T.nilable(String)).void
}
def initialize(
connected_account: nil,
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil,
status: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class MarkDeliveredParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Retrieves the financing offers available for Connected accounts that belong to your platform.
sig {
params(params: T.any(::Stripe::Capital::FinancingOfferService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Acknowledges that platform has received and delivered the financing_offer to
# the intended merchant recipient.
sig {
params(financing_offer: String, params: T.any(::Stripe::Capital::FinancingOfferService::MarkDeliveredParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Capital::FinancingOffer)
}
def mark_delivered(financing_offer, params = {}, opts = {}); end
# Get the details of the financing offer
sig {
params(financing_offer: String, params: T.any(::Stripe::Capital::FinancingOfferService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Capital::FinancingOffer)
}
def retrieve(financing_offer, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Capital
class FinancingSummaryService < StripeService
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Retrieve the financing state for the account that was authenticated in the request.
sig {
params(params: T.any(::Stripe::Capital::FinancingSummaryService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Capital::FinancingSummary)
}
def retrieve(params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Capital
class FinancingTransactionService < StripeService
class ListParams < Stripe::RequestParams
# For transactions of type `paydown` and reason `automatic_withholding` only, only returns transactions that were created as a result of this charge.
sig { returns(T.nilable(String)) }
attr_accessor :charge
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Returns transactions that were created that apply to this financing offer ID.
sig { returns(T.nilable(String)) }
attr_accessor :financing_offer
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Only returns transactions that are responsible for reversing this financing transaction ID.
sig { returns(T.nilable(String)) }
attr_accessor :reversed_transaction
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# For transactions of type `paydown` and reason `automatic_withholding` only, only returns transactions that were created as a result of this Treasury Transaction.
sig { returns(T.nilable(String)) }
attr_accessor :treasury_transaction
sig {
params(charge: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), financing_offer: T.nilable(String), limit: T.nilable(Integer), reversed_transaction: T.nilable(String), starting_after: T.nilable(String), treasury_transaction: T.nilable(String)).void
}
def initialize(
charge: nil,
ending_before: nil,
expand: nil,
financing_offer: nil,
limit: nil,
reversed_transaction: nil,
starting_after: nil,
treasury_transaction: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Returns a list of financing transactions. The transactions are returned in sorted order,
# with the most recent transactions appearing first.
sig {
params(params: T.any(::Stripe::Capital::FinancingTransactionService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves a financing transaction for a financing offer.
sig {
params(financing_transaction: String, params: T.any(::Stripe::Capital::FinancingTransactionService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Capital::FinancingTransaction)
}
def retrieve(financing_transaction, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
class ChargeService < StripeService
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return charges that were created during the given date interval.
sig { returns(T.nilable(T.any(::Stripe::ChargeService::ListParams::Created, Integer))) }
attr_accessor :created
# Only return charges for the customer specified by this customer ID.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Only return charges that were created by the PaymentIntent specified by this PaymentIntent ID.
sig { returns(T.nilable(String)) }
attr_accessor :payment_intent
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return charges for this transfer group, limited to 100.
sig { returns(T.nilable(String)) }
attr_accessor :transfer_group
sig {
params(created: T.nilable(T.any(::Stripe::ChargeService::ListParams::Created, Integer)), customer: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), payment_intent: T.nilable(String), starting_after: T.nilable(String), transfer_group: T.nilable(String)).void
}
def initialize(
created: nil,
customer: nil,
ending_before: nil,
expand: nil,
limit: nil,
payment_intent: nil,
starting_after: nil,
transfer_group: nil
); end
end
class CreateParams < Stripe::RequestParams
class Destination < Stripe::RequestParams
# ID of an existing, connected Stripe account.
sig { returns(String) }
attr_accessor :account
# The amount to transfer to the destination account without creating an `Application Fee` object. Cannot be combined with the `application_fee` parameter. Must be less than or equal to the charge amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
sig { params(account: String, amount: T.nilable(Integer)).void }
def initialize(account: nil, amount: nil); end
end
class RadarOptions < Stripe::RequestParams
# A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
sig { returns(T.nilable(String)) }
attr_accessor :session
sig { params(session: T.nilable(String)).void }
def initialize(session: nil); end
end
class Shipping < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Shipping address.
sig { returns(::Stripe::ChargeService::CreateParams::Shipping::Address) }
attr_accessor :address
# The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
sig { returns(T.nilable(String)) }
attr_accessor :carrier
# Recipient name.
sig { returns(String) }
attr_accessor :name
# Recipient phone (including extension).
sig { returns(T.nilable(String)) }
attr_accessor :phone
# The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
sig { returns(T.nilable(String)) }
attr_accessor :tracking_number
sig {
params(address: ::Stripe::ChargeService::CreateParams::Shipping::Address, carrier: T.nilable(String), name: String, phone: T.nilable(String), tracking_number: T.nilable(String)).void
}
def initialize(address: nil, carrier: nil, name: nil, phone: nil, tracking_number: nil); end
end
class TransferData < Stripe::RequestParams
# The amount transferred to the destination account, if specified. By default, the entire charge amount is transferred to the destination account.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# ID of an existing, connected Stripe account.
sig { returns(String) }
attr_accessor :destination
sig { params(amount: T.nilable(Integer), destination: String).void }
def initialize(amount: nil, destination: nil); end
end
# Amount intended to be collected by this payment. A positive integer representing how much to charge in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is $0.50 US or [equivalent in charge currency](https://stripe.com/docs/currencies#minimum-and-maximum-charge-amounts). The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99).
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# Attribute for param field application_fee
sig { returns(T.nilable(Integer)) }
attr_accessor :application_fee
# A fee in cents (or local equivalent) that will be applied to the charge 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/connect/direct-charges#collect-fees).
sig { returns(T.nilable(Integer)) }
attr_accessor :application_fee_amount
# Whether to immediately capture the charge. Defaults to `true`. When `false`, the charge issues an authorization (or pre-authorization), and will need to be [captured](https://stripe.com/docs/api#capture_charge) later. Uncaptured charges expire after a set number of days (7 by default). For more information, see the [authorizing charges and settling later](https://stripe.com/docs/charges/placing-a-hold) documentation.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :capture
# 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).
sig { returns(T.nilable(String)) }
attr_accessor :currency
# The ID of an existing customer that will be charged in this request.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# An arbitrary string which you can attach to a `Charge` object. It is displayed when in the web interface alongside the charge. Note that if you use Stripe to send automatic email receipts to your customers, your receipt emails will include the `description` of the charge(s) that they are describing.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Attribute for param field destination
sig { returns(T.nilable(::Stripe::ChargeService::CreateParams::Destination)) }
attr_accessor :destination
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# The Stripe account ID for which these funds are intended. Automatically set if you use the `destination` parameter. For details, see [Creating Separate Charges and Transfers](https://stripe.com/docs/connect/separate-charges-and-transfers#settlement-merchant).
sig { returns(T.nilable(String)) }
attr_accessor :on_behalf_of
# Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
sig { returns(T.nilable(::Stripe::ChargeService::CreateParams::RadarOptions)) }
attr_accessor :radar_options
# The email address to which this charge's [receipt](https://stripe.com/docs/dashboard/receipts) will be sent. The receipt will not be sent until the charge is paid, and no receipts will be sent for test mode charges. If this charge is for a [Customer](https://stripe.com/docs/api/customers/object), the email address specified here will override the customer's email address. If `receipt_email` is specified for a charge in live mode, a receipt will be sent regardless of your [email settings](https://dashboard.stripe.com/account/emails).
sig { returns(T.nilable(String)) }
attr_accessor :receipt_email
# Shipping information for the charge. Helps prevent fraud on charges for physical goods.
sig { returns(T.nilable(::Stripe::ChargeService::CreateParams::Shipping)) }
attr_accessor :shipping
# A payment source to be charged. This can be the ID of a [card](https://stripe.com/docs/api#cards) (i.e., credit or debit card), a [bank account](https://stripe.com/docs/api#bank_accounts), a [source](https://stripe.com/docs/api#sources), a [token](https://stripe.com/docs/api#tokens), or a [connected account](https://stripe.com/docs/connect/account-debits#charging-a-connected-account). For certain sources---namely, [cards](https://stripe.com/docs/api#cards), [bank accounts](https://stripe.com/docs/api#bank_accounts), and attached [sources](https://stripe.com/docs/api#sources)---you must also pass the ID of the associated customer.
sig { returns(T.nilable(String)) }
attr_accessor :source
# For a non-card charge, text that appears on the customer's statement as the statement descriptor. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
#
# For a card charge, this value is ignored unless you don't specify a `statement_descriptor_suffix`, in which case this value is used as the suffix.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
# Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement. If the account has no prefix value, the suffix is concatenated to the account's statement descriptor.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor_suffix
# An optional dictionary including the account to automatically transfer to as part of a destination charge. [See the Connect documentation](https://stripe.com/docs/connect/destination-charges) for details.
sig { returns(T.nilable(::Stripe::ChargeService::CreateParams::TransferData)) }
attr_accessor :transfer_data
# A string that identifies this transaction as part of a group. For details, see [Grouping transactions](https://stripe.com/docs/connect/separate-charges-and-transfers#transfer-options).
sig { returns(T.nilable(String)) }
attr_accessor :transfer_group
sig {
params(amount: T.nilable(Integer), application_fee: T.nilable(Integer), application_fee_amount: T.nilable(Integer), capture: T.nilable(T::Boolean), currency: T.nilable(String), customer: T.nilable(String), description: T.nilable(String), destination: T.nilable(::Stripe::ChargeService::CreateParams::Destination), expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), on_behalf_of: T.nilable(String), radar_options: T.nilable(::Stripe::ChargeService::CreateParams::RadarOptions), receipt_email: T.nilable(String), shipping: T.nilable(::Stripe::ChargeService::CreateParams::Shipping), source: T.nilable(String), statement_descriptor: T.nilable(String), statement_descriptor_suffix: T.nilable(String), transfer_data: T.nilable(::Stripe::ChargeService::CreateParams::TransferData), transfer_group: T.nilable(String)).void
}
def initialize(
amount: nil,
application_fee: nil,
application_fee_amount: nil,
capture: nil,
currency: nil,
customer: nil,
description: nil,
destination: nil,
expand: nil,
metadata: nil,
on_behalf_of: nil,
radar_options: nil,
receipt_email: nil,
shipping: nil,
source: nil,
statement_descriptor: nil,
statement_descriptor_suffix: nil,
transfer_data: nil,
transfer_group: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
class FraudDetails < Stripe::RequestParams
# Either `safe` or `fraudulent`.
sig { returns(T.nilable(T.any(String, String))) }
attr_accessor :user_report
sig { params(user_report: T.nilable(T.any(String, String))).void }
def initialize(user_report: nil); end
end
class PaymentDetails < Stripe::RequestParams
class CarRental < Stripe::RequestParams
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::CarRental::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::CarRental::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
class Distance < Stripe::RequestParams
# Distance traveled.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# Unit of measurement for the distance traveled. One of `miles` or `kilometers`.
sig { returns(T.nilable(String)) }
attr_accessor :unit
sig { params(amount: T.nilable(Integer), unit: T.nilable(String)).void }
def initialize(amount: nil, unit: nil); end
end
class Driver < Stripe::RequestParams
# Driver's identification number.
sig { returns(T.nilable(String)) }
attr_accessor :driver_identification_number
# Driver's tax number.
sig { returns(T.nilable(String)) }
attr_accessor :driver_tax_number
# Full name of the person or entity on the car reservation.
sig { returns(String) }
attr_accessor :name
sig {
params(driver_identification_number: T.nilable(String), driver_tax_number: T.nilable(String), name: String).void
}
def initialize(
driver_identification_number: nil,
driver_tax_number: nil,
name: nil
); end
end
class PickupAddress < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class ReturnAddress < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::CarRental::Affiliate))
}
attr_accessor :affiliate
# The booking number associated with the car rental.
sig { returns(String) }
attr_accessor :booking_number
# Class code of the car.
sig { returns(T.nilable(String)) }
attr_accessor :car_class_code
# Make of the car.
sig { returns(T.nilable(String)) }
attr_accessor :car_make
# Model of the car.
sig { returns(T.nilable(String)) }
attr_accessor :car_model
# The name of the rental car company.
sig { returns(T.nilable(String)) }
attr_accessor :company
# The customer service phone number of the car rental company.
sig { returns(T.nilable(String)) }
attr_accessor :customer_service_phone_number
# Number of days the car is being rented.
sig { returns(Integer) }
attr_accessor :days_rented
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::CarRental::Delivery))
}
attr_accessor :delivery
# The details of the distance traveled during the rental period.
sig {
returns(T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::CarRental::Distance))
}
attr_accessor :distance
# The details of the passengers in the travel reservation
sig {
returns(T.nilable(T::Array[::Stripe::ChargeService::UpdateParams::PaymentDetails::CarRental::Driver]))
}
attr_accessor :drivers
# List of additional charges being billed.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :extra_charges
# Indicates if the customer did not keep nor cancel their booking.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :no_show
# Car pick-up address.
sig {
returns(T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::CarRental::PickupAddress))
}
attr_accessor :pickup_address
# Car pick-up time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :pickup_at
# Name of the pickup location.
sig { returns(T.nilable(String)) }
attr_accessor :pickup_location_name
# Rental rate.
sig { returns(T.nilable(Integer)) }
attr_accessor :rate_amount
# The frequency at which the rate amount is applied. One of `day`, `week` or `month`
sig { returns(T.nilable(String)) }
attr_accessor :rate_interval
# The name of the person or entity renting the car.
sig { returns(T.nilable(String)) }
attr_accessor :renter_name
# Car return address.
sig {
returns(T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::CarRental::ReturnAddress))
}
attr_accessor :return_address
# Car return time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :return_at
# Name of the return location.
sig { returns(T.nilable(String)) }
attr_accessor :return_location_name
# Indicates whether the goods or services are tax-exempt or tax is not collected.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :tax_exempt
# The vehicle identification number.
sig { returns(T.nilable(String)) }
attr_accessor :vehicle_identification_number
sig {
params(affiliate: T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::CarRental::Affiliate), booking_number: String, car_class_code: T.nilable(String), car_make: T.nilable(String), car_model: T.nilable(String), company: T.nilable(String), customer_service_phone_number: T.nilable(String), days_rented: Integer, delivery: T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::CarRental::Delivery), distance: T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::CarRental::Distance), drivers: T.nilable(T::Array[::Stripe::ChargeService::UpdateParams::PaymentDetails::CarRental::Driver]), extra_charges: T.nilable(T::Array[String]), no_show: T.nilable(T::Boolean), pickup_address: T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::CarRental::PickupAddress), pickup_at: Integer, pickup_location_name: T.nilable(String), rate_amount: T.nilable(Integer), rate_interval: T.nilable(String), renter_name: T.nilable(String), return_address: T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::CarRental::ReturnAddress), return_at: Integer, return_location_name: T.nilable(String), tax_exempt: T.nilable(T::Boolean), vehicle_identification_number: T.nilable(String)).void
}
def initialize(
affiliate: nil,
booking_number: nil,
car_class_code: nil,
car_make: nil,
car_model: nil,
company: nil,
customer_service_phone_number: nil,
days_rented: nil,
delivery: nil,
distance: nil,
drivers: nil,
extra_charges: nil,
no_show: nil,
pickup_address: nil,
pickup_at: nil,
pickup_location_name: nil,
rate_amount: nil,
rate_interval: nil,
renter_name: nil,
return_address: nil,
return_at: nil,
return_location_name: nil,
tax_exempt: nil,
vehicle_identification_number: nil
); end
end
class EventDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::EventDetails::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::EventDetails::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
# Indicates if the tickets are digitally checked when entering the venue.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :access_controlled_venue
# The event location's address.
sig {
returns(T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::EventDetails::Address))
}
attr_accessor :address
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::EventDetails::Affiliate))
}
attr_accessor :affiliate
# The name of the company
sig { returns(T.nilable(String)) }
attr_accessor :company
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::EventDetails::Delivery))
}
attr_accessor :delivery
# Event end time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :ends_at
# Type of the event entertainment (concert, sports event etc)
sig { returns(T.nilable(String)) }
attr_accessor :genre
# The name of the event.
sig { returns(String) }
attr_accessor :name
# Event start time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :starts_at
sig {
params(access_controlled_venue: T.nilable(T::Boolean), address: T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::EventDetails::Address), affiliate: T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::EventDetails::Affiliate), company: T.nilable(String), delivery: T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::EventDetails::Delivery), ends_at: T.nilable(Integer), genre: T.nilable(String), name: String, starts_at: T.nilable(Integer)).void
}
def initialize(
access_controlled_venue: nil,
address: nil,
affiliate: nil,
company: nil,
delivery: nil,
ends_at: nil,
genre: nil,
name: nil,
starts_at: nil
); end
end
class Flight < Stripe::RequestParams
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::Flight::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::Flight::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
class Passenger < Stripe::RequestParams
# Full name of the person or entity on the flight reservation.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Segment < Stripe::RequestParams
# The flight segment amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# The International Air Transport Association (IATA) airport code for the arrival airport.
sig { returns(T.nilable(String)) }
attr_accessor :arrival_airport
# The arrival time for the flight segment. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :arrives_at
# The International Air Transport Association (IATA) carrier code of the carrier operating the flight segment.
sig { returns(T.nilable(String)) }
attr_accessor :carrier
# The departure time for the flight segment. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :departs_at
# The International Air Transport Association (IATA) airport code for the departure airport.
sig { returns(T.nilable(String)) }
attr_accessor :departure_airport
# The flight number associated with the segment
sig { returns(T.nilable(String)) }
attr_accessor :flight_number
# The fare class for the segment.
sig { returns(T.nilable(String)) }
attr_accessor :service_class
sig {
params(amount: T.nilable(Integer), arrival_airport: T.nilable(String), arrives_at: T.nilable(Integer), carrier: T.nilable(String), departs_at: Integer, departure_airport: T.nilable(String), flight_number: T.nilable(String), service_class: T.nilable(String)).void
}
def initialize(
amount: nil,
arrival_airport: nil,
arrives_at: nil,
carrier: nil,
departs_at: nil,
departure_airport: nil,
flight_number: nil,
service_class: nil
); end
end
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::Flight::Affiliate))
}
attr_accessor :affiliate
# The agency number (i.e. International Air Transport Association (IATA) agency number) of the travel agency that made the booking.
sig { returns(T.nilable(String)) }
attr_accessor :agency_number
# The International Air Transport Association (IATA) carrier code of the carrier that issued the ticket.
sig { returns(T.nilable(String)) }
attr_accessor :carrier
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::Flight::Delivery))
}
attr_accessor :delivery
# The name of the person or entity on the reservation.
sig { returns(T.nilable(String)) }
attr_accessor :passenger_name
# The details of the passengers in the travel reservation.
sig {
returns(T.nilable(T::Array[::Stripe::ChargeService::UpdateParams::PaymentDetails::Flight::Passenger]))
}
attr_accessor :passengers
# The individual flight segments associated with the trip.
sig {
returns(T::Array[::Stripe::ChargeService::UpdateParams::PaymentDetails::Flight::Segment])
}
attr_accessor :segments
# The ticket number associated with the travel reservation.
sig { returns(T.nilable(String)) }
attr_accessor :ticket_number
sig {
params(affiliate: T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::Flight::Affiliate), agency_number: T.nilable(String), carrier: T.nilable(String), delivery: T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::Flight::Delivery), passenger_name: T.nilable(String), passengers: T.nilable(T::Array[::Stripe::ChargeService::UpdateParams::PaymentDetails::Flight::Passenger]), segments: T::Array[::Stripe::ChargeService::UpdateParams::PaymentDetails::Flight::Segment], ticket_number: T.nilable(String)).void
}
def initialize(
affiliate: nil,
agency_number: nil,
carrier: nil,
delivery: nil,
passenger_name: nil,
passengers: nil,
segments: nil,
ticket_number: nil
); end
end
class Lodging < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::Lodging::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::Lodging::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
class Passenger < Stripe::RequestParams
# Full name of the person or entity on the lodging reservation.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
# The lodging location's address.
sig {
returns(T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::Lodging::Address))
}
attr_accessor :address
# The number of adults on the booking
sig { returns(T.nilable(Integer)) }
attr_accessor :adults
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::Lodging::Affiliate))
}
attr_accessor :affiliate
# The booking number associated with the lodging reservation.
sig { returns(T.nilable(String)) }
attr_accessor :booking_number
# The lodging category
sig { returns(T.nilable(String)) }
attr_accessor :category
# Lodging check-in time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :checkin_at
# Lodging check-out time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :checkout_at
# The customer service phone number of the lodging company.
sig { returns(T.nilable(String)) }
attr_accessor :customer_service_phone_number
# The daily lodging room rate.
sig { returns(T.nilable(Integer)) }
attr_accessor :daily_room_rate_amount
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::Lodging::Delivery))
}
attr_accessor :delivery
# List of additional charges being billed.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :extra_charges
# Indicates whether the lodging location is compliant with the Fire Safety Act.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :fire_safety_act_compliance
# The name of the lodging location.
sig { returns(T.nilable(String)) }
attr_accessor :name
# Indicates if the customer did not keep their booking while failing to cancel the reservation.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :no_show
# The number of rooms on the booking
sig { returns(T.nilable(Integer)) }
attr_accessor :number_of_rooms
# The details of the passengers in the travel reservation
sig {
returns(T.nilable(T::Array[::Stripe::ChargeService::UpdateParams::PaymentDetails::Lodging::Passenger]))
}
attr_accessor :passengers
# The phone number of the lodging location.
sig { returns(T.nilable(String)) }
attr_accessor :property_phone_number
# The room class for this purchase.
sig { returns(T.nilable(String)) }
attr_accessor :room_class
# The number of room nights
sig { returns(T.nilable(Integer)) }
attr_accessor :room_nights
# The total tax amount associating with the room reservation.
sig { returns(T.nilable(Integer)) }
attr_accessor :total_room_tax_amount
# The total tax amount
sig { returns(T.nilable(Integer)) }
attr_accessor :total_tax_amount
sig {
params(address: T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::Lodging::Address), adults: T.nilable(Integer), affiliate: T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::Lodging::Affiliate), booking_number: T.nilable(String), category: T.nilable(String), checkin_at: Integer, checkout_at: Integer, customer_service_phone_number: T.nilable(String), daily_room_rate_amount: T.nilable(Integer), delivery: T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::Lodging::Delivery), extra_charges: T.nilable(T::Array[String]), fire_safety_act_compliance: T.nilable(T::Boolean), name: T.nilable(String), no_show: T.nilable(T::Boolean), number_of_rooms: T.nilable(Integer), passengers: T.nilable(T::Array[::Stripe::ChargeService::UpdateParams::PaymentDetails::Lodging::Passenger]), property_phone_number: T.nilable(String), room_class: T.nilable(String), room_nights: T.nilable(Integer), total_room_tax_amount: T.nilable(Integer), total_tax_amount: T.nilable(Integer)).void
}
def initialize(
address: nil,
adults: nil,
affiliate: nil,
booking_number: nil,
category: nil,
checkin_at: nil,
checkout_at: nil,
customer_service_phone_number: nil,
daily_room_rate_amount: nil,
delivery: nil,
extra_charges: nil,
fire_safety_act_compliance: nil,
name: nil,
no_show: nil,
number_of_rooms: nil,
passengers: nil,
property_phone_number: nil,
room_class: nil,
room_nights: nil,
total_room_tax_amount: nil,
total_tax_amount: nil
); end
end
class Subscription < Stripe::RequestParams
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class BillingInterval < Stripe::RequestParams
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :count
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
sig { params(count: Integer, interval: String).void }
def initialize(count: nil, interval: nil); end
end
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::Subscription::Affiliate))
}
attr_accessor :affiliate
# Info whether the subscription will be auto renewed upon expiry.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :auto_renewal
# Subscription billing details for this purchase.
sig {
returns(T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::Subscription::BillingInterval))
}
attr_accessor :billing_interval
# Subscription end time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :ends_at
# Name of the product on subscription. e.g. Apple Music Subscription
sig { returns(String) }
attr_accessor :name
# Subscription start time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :starts_at
sig {
params(affiliate: T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::Subscription::Affiliate), auto_renewal: T.nilable(T::Boolean), billing_interval: T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::Subscription::BillingInterval), ends_at: T.nilable(Integer), name: String, starts_at: T.nilable(Integer)).void
}
def initialize(
affiliate: nil,
auto_renewal: nil,
billing_interval: nil,
ends_at: nil,
name: nil,
starts_at: nil
); end
end
# Car rental details for this PaymentIntent.
sig { returns(T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::CarRental)) }
attr_accessor :car_rental
# Some customers might be required by their company or organization to provide this information. If so, provide this value. Otherwise you can ignore this field.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :customer_reference
# Event details for this PaymentIntent
sig {
returns(T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::EventDetails))
}
attr_accessor :event_details
# Flight reservation details for this PaymentIntent
sig { returns(T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::Flight)) }
attr_accessor :flight
# Lodging reservation details for this PaymentIntent
sig { returns(T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::Lodging)) }
attr_accessor :lodging
# A unique value assigned by the business to identify the transaction.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :order_reference
# Subscription details for this PaymentIntent
sig {
returns(T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::Subscription))
}
attr_accessor :subscription
sig {
params(car_rental: T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::CarRental), customer_reference: T.nilable(T.nilable(String)), event_details: T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::EventDetails), flight: T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::Flight), lodging: T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::Lodging), order_reference: T.nilable(T.nilable(String)), subscription: T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails::Subscription)).void
}
def initialize(
car_rental: nil,
customer_reference: nil,
event_details: nil,
flight: nil,
lodging: nil,
order_reference: nil,
subscription: nil
); end
end
class Shipping < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Shipping address.
sig { returns(::Stripe::ChargeService::UpdateParams::Shipping::Address) }
attr_accessor :address
# The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
sig { returns(T.nilable(String)) }
attr_accessor :carrier
# Recipient name.
sig { returns(String) }
attr_accessor :name
# Recipient phone (including extension).
sig { returns(T.nilable(String)) }
attr_accessor :phone
# The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
sig { returns(T.nilable(String)) }
attr_accessor :tracking_number
sig {
params(address: ::Stripe::ChargeService::UpdateParams::Shipping::Address, carrier: T.nilable(String), name: String, phone: T.nilable(String), tracking_number: T.nilable(String)).void
}
def initialize(address: nil, carrier: nil, name: nil, phone: nil, tracking_number: nil); end
end
# The ID of an existing customer that will be associated with this request. This field may only be updated if there is no existing associated customer with this charge.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# An arbitrary string which you can attach to a charge object. It is displayed when in the web interface alongside the charge. Note that if you use Stripe to send automatic email receipts to your customers, your receipt emails will include the `description` of the charge(s) that they are describing.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A set of key-value pairs you can attach to a charge giving information about its riskiness. If you believe a charge is fraudulent, include a `user_report` key with a value of `fraudulent`. If you believe a charge is safe, include a `user_report` key with a value of `safe`. Stripe will use the information you send to improve our fraud detection algorithms.
sig { returns(T.nilable(::Stripe::ChargeService::UpdateParams::FraudDetails)) }
attr_accessor :fraud_details
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Provides industry-specific information about the charge.
sig { returns(T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails)) }
attr_accessor :payment_details
# This is the email address that the receipt for this charge will be sent to. If this field is updated, then a new email receipt will be sent to the updated address.
sig { returns(T.nilable(String)) }
attr_accessor :receipt_email
# Shipping information for the charge. Helps prevent fraud on charges for physical goods.
sig { returns(T.nilable(::Stripe::ChargeService::UpdateParams::Shipping)) }
attr_accessor :shipping
# A string that identifies this transaction as part of a group. `transfer_group` may only be provided if it has not been set. See the [Connect documentation](https://stripe.com/docs/connect/separate-charges-and-transfers#transfer-options) for details.
sig { returns(T.nilable(String)) }
attr_accessor :transfer_group
sig {
params(customer: T.nilable(String), description: T.nilable(String), expand: T.nilable(T::Array[String]), fraud_details: T.nilable(::Stripe::ChargeService::UpdateParams::FraudDetails), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), payment_details: T.nilable(::Stripe::ChargeService::UpdateParams::PaymentDetails), receipt_email: T.nilable(String), shipping: T.nilable(::Stripe::ChargeService::UpdateParams::Shipping), transfer_group: T.nilable(String)).void
}
def initialize(
customer: nil,
description: nil,
expand: nil,
fraud_details: nil,
metadata: nil,
payment_details: nil,
receipt_email: nil,
shipping: nil,
transfer_group: nil
); end
end
class SearchParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for pagination across multiple pages of results. Don't include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.
sig { returns(T.nilable(String)) }
attr_accessor :page
# The search query string. See [search query language](https://stripe.com/docs/search#search-query-language) and the list of supported [query fields for charges](https://stripe.com/docs/search#query-fields-for-charges).
sig { returns(String) }
attr_accessor :query
sig {
params(expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), page: T.nilable(String), query: String).void
}
def initialize(expand: nil, limit: nil, page: nil, query: nil); end
end
class CaptureParams < Stripe::RequestParams
class PaymentDetails < Stripe::RequestParams
class CarRental < Stripe::RequestParams
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::CarRental::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::CarRental::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
class Distance < Stripe::RequestParams
# Distance traveled.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# Unit of measurement for the distance traveled. One of `miles` or `kilometers`.
sig { returns(T.nilable(String)) }
attr_accessor :unit
sig { params(amount: T.nilable(Integer), unit: T.nilable(String)).void }
def initialize(amount: nil, unit: nil); end
end
class Driver < Stripe::RequestParams
# Driver's identification number.
sig { returns(T.nilable(String)) }
attr_accessor :driver_identification_number
# Driver's tax number.
sig { returns(T.nilable(String)) }
attr_accessor :driver_tax_number
# Full name of the person or entity on the car reservation.
sig { returns(String) }
attr_accessor :name
sig {
params(driver_identification_number: T.nilable(String), driver_tax_number: T.nilable(String), name: String).void
}
def initialize(
driver_identification_number: nil,
driver_tax_number: nil,
name: nil
); end
end
class PickupAddress < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class ReturnAddress < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::CarRental::Affiliate))
}
attr_accessor :affiliate
# The booking number associated with the car rental.
sig { returns(String) }
attr_accessor :booking_number
# Class code of the car.
sig { returns(T.nilable(String)) }
attr_accessor :car_class_code
# Make of the car.
sig { returns(T.nilable(String)) }
attr_accessor :car_make
# Model of the car.
sig { returns(T.nilable(String)) }
attr_accessor :car_model
# The name of the rental car company.
sig { returns(T.nilable(String)) }
attr_accessor :company
# The customer service phone number of the car rental company.
sig { returns(T.nilable(String)) }
attr_accessor :customer_service_phone_number
# Number of days the car is being rented.
sig { returns(Integer) }
attr_accessor :days_rented
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::CarRental::Delivery))
}
attr_accessor :delivery
# The details of the distance traveled during the rental period.
sig {
returns(T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::CarRental::Distance))
}
attr_accessor :distance
# The details of the passengers in the travel reservation
sig {
returns(T.nilable(T::Array[::Stripe::ChargeService::CaptureParams::PaymentDetails::CarRental::Driver]))
}
attr_accessor :drivers
# List of additional charges being billed.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :extra_charges
# Indicates if the customer did not keep nor cancel their booking.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :no_show
# Car pick-up address.
sig {
returns(T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::CarRental::PickupAddress))
}
attr_accessor :pickup_address
# Car pick-up time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :pickup_at
# Name of the pickup location.
sig { returns(T.nilable(String)) }
attr_accessor :pickup_location_name
# Rental rate.
sig { returns(T.nilable(Integer)) }
attr_accessor :rate_amount
# The frequency at which the rate amount is applied. One of `day`, `week` or `month`
sig { returns(T.nilable(String)) }
attr_accessor :rate_interval
# The name of the person or entity renting the car.
sig { returns(T.nilable(String)) }
attr_accessor :renter_name
# Car return address.
sig {
returns(T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::CarRental::ReturnAddress))
}
attr_accessor :return_address
# Car return time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :return_at
# Name of the return location.
sig { returns(T.nilable(String)) }
attr_accessor :return_location_name
# Indicates whether the goods or services are tax-exempt or tax is not collected.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :tax_exempt
# The vehicle identification number.
sig { returns(T.nilable(String)) }
attr_accessor :vehicle_identification_number
sig {
params(affiliate: T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::CarRental::Affiliate), booking_number: String, car_class_code: T.nilable(String), car_make: T.nilable(String), car_model: T.nilable(String), company: T.nilable(String), customer_service_phone_number: T.nilable(String), days_rented: Integer, delivery: T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::CarRental::Delivery), distance: T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::CarRental::Distance), drivers: T.nilable(T::Array[::Stripe::ChargeService::CaptureParams::PaymentDetails::CarRental::Driver]), extra_charges: T.nilable(T::Array[String]), no_show: T.nilable(T::Boolean), pickup_address: T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::CarRental::PickupAddress), pickup_at: Integer, pickup_location_name: T.nilable(String), rate_amount: T.nilable(Integer), rate_interval: T.nilable(String), renter_name: T.nilable(String), return_address: T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::CarRental::ReturnAddress), return_at: Integer, return_location_name: T.nilable(String), tax_exempt: T.nilable(T::Boolean), vehicle_identification_number: T.nilable(String)).void
}
def initialize(
affiliate: nil,
booking_number: nil,
car_class_code: nil,
car_make: nil,
car_model: nil,
company: nil,
customer_service_phone_number: nil,
days_rented: nil,
delivery: nil,
distance: nil,
drivers: nil,
extra_charges: nil,
no_show: nil,
pickup_address: nil,
pickup_at: nil,
pickup_location_name: nil,
rate_amount: nil,
rate_interval: nil,
renter_name: nil,
return_address: nil,
return_at: nil,
return_location_name: nil,
tax_exempt: nil,
vehicle_identification_number: nil
); end
end
class EventDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::EventDetails::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::EventDetails::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
# Indicates if the tickets are digitally checked when entering the venue.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :access_controlled_venue
# The event location's address.
sig {
returns(T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::EventDetails::Address))
}
attr_accessor :address
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::EventDetails::Affiliate))
}
attr_accessor :affiliate
# The name of the company
sig { returns(T.nilable(String)) }
attr_accessor :company
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::EventDetails::Delivery))
}
attr_accessor :delivery
# Event end time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :ends_at
# Type of the event entertainment (concert, sports event etc)
sig { returns(T.nilable(String)) }
attr_accessor :genre
# The name of the event.
sig { returns(String) }
attr_accessor :name
# Event start time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :starts_at
sig {
params(access_controlled_venue: T.nilable(T::Boolean), address: T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::EventDetails::Address), affiliate: T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::EventDetails::Affiliate), company: T.nilable(String), delivery: T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::EventDetails::Delivery), ends_at: T.nilable(Integer), genre: T.nilable(String), name: String, starts_at: T.nilable(Integer)).void
}
def initialize(
access_controlled_venue: nil,
address: nil,
affiliate: nil,
company: nil,
delivery: nil,
ends_at: nil,
genre: nil,
name: nil,
starts_at: nil
); end
end
class Flight < Stripe::RequestParams
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::Flight::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::Flight::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
class Passenger < Stripe::RequestParams
# Full name of the person or entity on the flight reservation.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Segment < Stripe::RequestParams
# The flight segment amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# The International Air Transport Association (IATA) airport code for the arrival airport.
sig { returns(T.nilable(String)) }
attr_accessor :arrival_airport
# The arrival time for the flight segment. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :arrives_at
# The International Air Transport Association (IATA) carrier code of the carrier operating the flight segment.
sig { returns(T.nilable(String)) }
attr_accessor :carrier
# The departure time for the flight segment. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :departs_at
# The International Air Transport Association (IATA) airport code for the departure airport.
sig { returns(T.nilable(String)) }
attr_accessor :departure_airport
# The flight number associated with the segment
sig { returns(T.nilable(String)) }
attr_accessor :flight_number
# The fare class for the segment.
sig { returns(T.nilable(String)) }
attr_accessor :service_class
sig {
params(amount: T.nilable(Integer), arrival_airport: T.nilable(String), arrives_at: T.nilable(Integer), carrier: T.nilable(String), departs_at: Integer, departure_airport: T.nilable(String), flight_number: T.nilable(String), service_class: T.nilable(String)).void
}
def initialize(
amount: nil,
arrival_airport: nil,
arrives_at: nil,
carrier: nil,
departs_at: nil,
departure_airport: nil,
flight_number: nil,
service_class: nil
); end
end
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::Flight::Affiliate))
}
attr_accessor :affiliate
# The agency number (i.e. International Air Transport Association (IATA) agency number) of the travel agency that made the booking.
sig { returns(T.nilable(String)) }
attr_accessor :agency_number
# The International Air Transport Association (IATA) carrier code of the carrier that issued the ticket.
sig { returns(T.nilable(String)) }
attr_accessor :carrier
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::Flight::Delivery))
}
attr_accessor :delivery
# The name of the person or entity on the reservation.
sig { returns(T.nilable(String)) }
attr_accessor :passenger_name
# The details of the passengers in the travel reservation.
sig {
returns(T.nilable(T::Array[::Stripe::ChargeService::CaptureParams::PaymentDetails::Flight::Passenger]))
}
attr_accessor :passengers
# The individual flight segments associated with the trip.
sig {
returns(T::Array[::Stripe::ChargeService::CaptureParams::PaymentDetails::Flight::Segment])
}
attr_accessor :segments
# The ticket number associated with the travel reservation.
sig { returns(T.nilable(String)) }
attr_accessor :ticket_number
sig {
params(affiliate: T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::Flight::Affiliate), agency_number: T.nilable(String), carrier: T.nilable(String), delivery: T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::Flight::Delivery), passenger_name: T.nilable(String), passengers: T.nilable(T::Array[::Stripe::ChargeService::CaptureParams::PaymentDetails::Flight::Passenger]), segments: T::Array[::Stripe::ChargeService::CaptureParams::PaymentDetails::Flight::Segment], ticket_number: T.nilable(String)).void
}
def initialize(
affiliate: nil,
agency_number: nil,
carrier: nil,
delivery: nil,
passenger_name: nil,
passengers: nil,
segments: nil,
ticket_number: nil
); end
end
class Lodging < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::Lodging::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::Lodging::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
class Passenger < Stripe::RequestParams
# Full name of the person or entity on the lodging reservation.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
# The lodging location's address.
sig {
returns(T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::Lodging::Address))
}
attr_accessor :address
# The number of adults on the booking
sig { returns(T.nilable(Integer)) }
attr_accessor :adults
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::Lodging::Affiliate))
}
attr_accessor :affiliate
# The booking number associated with the lodging reservation.
sig { returns(T.nilable(String)) }
attr_accessor :booking_number
# The lodging category
sig { returns(T.nilable(String)) }
attr_accessor :category
# Lodging check-in time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :checkin_at
# Lodging check-out time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :checkout_at
# The customer service phone number of the lodging company.
sig { returns(T.nilable(String)) }
attr_accessor :customer_service_phone_number
# The daily lodging room rate.
sig { returns(T.nilable(Integer)) }
attr_accessor :daily_room_rate_amount
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::Lodging::Delivery))
}
attr_accessor :delivery
# List of additional charges being billed.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :extra_charges
# Indicates whether the lodging location is compliant with the Fire Safety Act.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :fire_safety_act_compliance
# The name of the lodging location.
sig { returns(T.nilable(String)) }
attr_accessor :name
# Indicates if the customer did not keep their booking while failing to cancel the reservation.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :no_show
# The number of rooms on the booking
sig { returns(T.nilable(Integer)) }
attr_accessor :number_of_rooms
# The details of the passengers in the travel reservation
sig {
returns(T.nilable(T::Array[::Stripe::ChargeService::CaptureParams::PaymentDetails::Lodging::Passenger]))
}
attr_accessor :passengers
# The phone number of the lodging location.
sig { returns(T.nilable(String)) }
attr_accessor :property_phone_number
# The room class for this purchase.
sig { returns(T.nilable(String)) }
attr_accessor :room_class
# The number of room nights
sig { returns(T.nilable(Integer)) }
attr_accessor :room_nights
# The total tax amount associating with the room reservation.
sig { returns(T.nilable(Integer)) }
attr_accessor :total_room_tax_amount
# The total tax amount
sig { returns(T.nilable(Integer)) }
attr_accessor :total_tax_amount
sig {
params(address: T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::Lodging::Address), adults: T.nilable(Integer), affiliate: T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::Lodging::Affiliate), booking_number: T.nilable(String), category: T.nilable(String), checkin_at: Integer, checkout_at: Integer, customer_service_phone_number: T.nilable(String), daily_room_rate_amount: T.nilable(Integer), delivery: T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::Lodging::Delivery), extra_charges: T.nilable(T::Array[String]), fire_safety_act_compliance: T.nilable(T::Boolean), name: T.nilable(String), no_show: T.nilable(T::Boolean), number_of_rooms: T.nilable(Integer), passengers: T.nilable(T::Array[::Stripe::ChargeService::CaptureParams::PaymentDetails::Lodging::Passenger]), property_phone_number: T.nilable(String), room_class: T.nilable(String), room_nights: T.nilable(Integer), total_room_tax_amount: T.nilable(Integer), total_tax_amount: T.nilable(Integer)).void
}
def initialize(
address: nil,
adults: nil,
affiliate: nil,
booking_number: nil,
category: nil,
checkin_at: nil,
checkout_at: nil,
customer_service_phone_number: nil,
daily_room_rate_amount: nil,
delivery: nil,
extra_charges: nil,
fire_safety_act_compliance: nil,
name: nil,
no_show: nil,
number_of_rooms: nil,
passengers: nil,
property_phone_number: nil,
room_class: nil,
room_nights: nil,
total_room_tax_amount: nil,
total_tax_amount: nil
); end
end
class Subscription < Stripe::RequestParams
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class BillingInterval < Stripe::RequestParams
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :count
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
sig { params(count: Integer, interval: String).void }
def initialize(count: nil, interval: nil); end
end
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::Subscription::Affiliate))
}
attr_accessor :affiliate
# Info whether the subscription will be auto renewed upon expiry.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :auto_renewal
# Subscription billing details for this purchase.
sig {
returns(T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::Subscription::BillingInterval))
}
attr_accessor :billing_interval
# Subscription end time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :ends_at
# Name of the product on subscription. e.g. Apple Music Subscription
sig { returns(String) }
attr_accessor :name
# Subscription start time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :starts_at
sig {
params(affiliate: T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::Subscription::Affiliate), auto_renewal: T.nilable(T::Boolean), billing_interval: T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::Subscription::BillingInterval), ends_at: T.nilable(Integer), name: String, starts_at: T.nilable(Integer)).void
}
def initialize(
affiliate: nil,
auto_renewal: nil,
billing_interval: nil,
ends_at: nil,
name: nil,
starts_at: nil
); end
end
# Car rental details for this PaymentIntent.
sig {
returns(T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::CarRental))
}
attr_accessor :car_rental
# Some customers might be required by their company or organization to provide this information. If so, provide this value. Otherwise you can ignore this field.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :customer_reference
# Event details for this PaymentIntent
sig {
returns(T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::EventDetails))
}
attr_accessor :event_details
# Flight reservation details for this PaymentIntent
sig { returns(T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::Flight)) }
attr_accessor :flight
# Lodging reservation details for this PaymentIntent
sig { returns(T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::Lodging)) }
attr_accessor :lodging
# A unique value assigned by the business to identify the transaction.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :order_reference
# Subscription details for this PaymentIntent
sig {
returns(T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::Subscription))
}
attr_accessor :subscription
sig {
params(car_rental: T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::CarRental), customer_reference: T.nilable(T.nilable(String)), event_details: T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::EventDetails), flight: T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::Flight), lodging: T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::Lodging), order_reference: T.nilable(T.nilable(String)), subscription: T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails::Subscription)).void
}
def initialize(
car_rental: nil,
customer_reference: nil,
event_details: nil,
flight: nil,
lodging: nil,
order_reference: nil,
subscription: nil
); end
end
class TransferData < Stripe::RequestParams
# The amount transferred to the destination account, if specified. By default, the entire charge amount is transferred to the destination account.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
sig { params(amount: T.nilable(Integer)).void }
def initialize(amount: nil); end
end
# The amount to capture, which must be less than or equal to the original amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# An application fee to add on to this charge.
sig { returns(T.nilable(Integer)) }
attr_accessor :application_fee
# An application fee amount to add on to this charge, which must be less than or equal to the original amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :application_fee_amount
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Provides industry-specific information about the charge.
sig { returns(T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails)) }
attr_accessor :payment_details
# The email address to send this charge's receipt to. This will override the previously-specified email address for this charge, if one was set. Receipts will not be sent in test mode.
sig { returns(T.nilable(String)) }
attr_accessor :receipt_email
# For a non-card charge, text that appears on the customer's statement as the statement descriptor. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
#
# For a card charge, this value is ignored unless you don't specify a `statement_descriptor_suffix`, in which case this value is used as the suffix.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
# Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement. If the account has no prefix value, the suffix is concatenated to the account's statement descriptor.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor_suffix
# An optional dictionary including the account to automatically transfer to as part of a destination charge. [See the Connect documentation](https://stripe.com/docs/connect/destination-charges) for details.
sig { returns(T.nilable(::Stripe::ChargeService::CaptureParams::TransferData)) }
attr_accessor :transfer_data
# A string that identifies this transaction as part of a group. `transfer_group` may only be provided if it has not been set. See the [Connect documentation](https://stripe.com/docs/connect/separate-charges-and-transfers#transfer-options) for details.
sig { returns(T.nilable(String)) }
attr_accessor :transfer_group
sig {
params(amount: T.nilable(Integer), application_fee: T.nilable(Integer), application_fee_amount: T.nilable(Integer), expand: T.nilable(T::Array[String]), payment_details: T.nilable(::Stripe::ChargeService::CaptureParams::PaymentDetails), receipt_email: T.nilable(String), statement_descriptor: T.nilable(String), statement_descriptor_suffix: T.nilable(String), transfer_data: T.nilable(::Stripe::ChargeService::CaptureParams::TransferData), transfer_group: T.nilable(String)).void
}
def initialize(
amount: nil,
application_fee: nil,
application_fee_amount: nil,
expand: nil,
payment_details: nil,
receipt_email: nil,
statement_descriptor: nil,
statement_descriptor_suffix: nil,
transfer_data: nil,
transfer_group: nil
); end
end
# Capture the payment of an existing, uncaptured charge that was created with the capture option set to false.
#
# Uncaptured payments expire a set number of days after they are created ([7 by default](https://docs.stripe.com/docs/charges/placing-a-hold)), after which they are marked as refunded and capture attempts will fail.
#
# Don't use this method to capture a PaymentIntent-initiated charge. Use [Capture a PaymentIntent](https://docs.stripe.com/docs/api/payment_intents/capture).
sig {
params(charge: String, params: T.any(::Stripe::ChargeService::CaptureParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Charge)
}
def capture(charge, params = {}, opts = {}); end
# This method is no longer recommended—use the [Payment Intents API](https://docs.stripe.com/docs/api/payment_intents)
# to initiate a new payment instead. Confirmation of the PaymentIntent creates the Charge
# object used to request payment.
sig {
params(params: T.any(::Stripe::ChargeService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Charge)
}
def create(params = {}, opts = {}); end
# Returns a list of charges you've previously created. The charges are returned in sorted order, with the most recent charges appearing first.
sig {
params(params: T.any(::Stripe::ChargeService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the details of a charge that has previously been created. Supply the unique charge ID that was returned from your previous request, and Stripe will return the corresponding charge information. The same information is returned when creating or refunding the charge.
sig {
params(charge: String, params: T.any(::Stripe::ChargeService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Charge)
}
def retrieve(charge, params = {}, opts = {}); end
# Search for charges you've previously created using Stripe's [Search Query Language](https://docs.stripe.com/docs/search#search-query-language).
# Don't use search in read-after-write flows where strict consistency is necessary. Under normal operating
# conditions, data is searchable in less than a minute. Occasionally, propagation of new or updated data can be up
# to an hour behind during outages. Search functionality is not available to merchants in India.
sig {
params(params: T.any(::Stripe::ChargeService::SearchParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SearchResultObject)
}
def search(params = {}, opts = {}); end
# Updates the specified charge by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
sig {
params(charge: String, params: T.any(::Stripe::ChargeService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Charge)
}
def update(charge, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class CheckoutService < StripeService
attr_reader :sessions
end
end
# typed: true
module Stripe
module Checkout
class SessionService < StripeService
attr_reader :line_items
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
class CustomerDetails < Stripe::RequestParams
# Customer's email address.
sig { returns(String) }
attr_accessor :email
sig { params(email: String).void }
def initialize(email: nil); end
end
# Only return Checkout Sessions that were created during the given date interval.
sig {
returns(T.nilable(T.any(::Stripe::Checkout::SessionService::ListParams::Created, Integer)))
}
attr_accessor :created
# Only return the Checkout Sessions for the Customer specified.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# Only return the Checkout Sessions for the Account specified.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# Only return the Checkout Sessions for the Customer details specified.
sig { returns(T.nilable(::Stripe::Checkout::SessionService::ListParams::CustomerDetails)) }
attr_accessor :customer_details
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Only return the Checkout Session for the PaymentIntent specified.
sig { returns(T.nilable(String)) }
attr_accessor :payment_intent
# Only return the Checkout Sessions for the Payment Link specified.
sig { returns(T.nilable(String)) }
attr_accessor :payment_link
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return the Checkout Sessions matching the given status.
sig { returns(T.nilable(String)) }
attr_accessor :status
# Only return the Checkout Session for the subscription specified.
sig { returns(T.nilable(String)) }
attr_accessor :subscription
sig {
params(created: T.nilable(T.any(::Stripe::Checkout::SessionService::ListParams::Created, Integer)), customer: T.nilable(String), customer_account: T.nilable(String), customer_details: T.nilable(::Stripe::Checkout::SessionService::ListParams::CustomerDetails), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), payment_intent: T.nilable(String), payment_link: T.nilable(String), starting_after: T.nilable(String), status: T.nilable(String), subscription: T.nilable(String)).void
}
def initialize(
created: nil,
customer: nil,
customer_account: nil,
customer_details: nil,
ending_before: nil,
expand: nil,
limit: nil,
payment_intent: nil,
payment_link: nil,
starting_after: nil,
status: nil,
subscription: nil
); end
end
class CreateParams < Stripe::RequestParams
class AdaptivePricing < Stripe::RequestParams
# Set to `true` to enable [Adaptive Pricing](https://docs.stripe.com/payments/checkout/adaptive-pricing). Defaults to your [dashboard setting](https://dashboard.stripe.com/settings/adaptive-pricing).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :enabled
sig { params(enabled: T.nilable(T::Boolean)).void }
def initialize(enabled: nil); end
end
class AfterExpiration < Stripe::RequestParams
class Recovery < Stripe::RequestParams
# Enables user redeemable promotion codes on the recovered Checkout Sessions. Defaults to `false`
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :allow_promotion_codes
# If `true`, a recovery URL will be generated to recover this Checkout Session if it
# expires before a successful transaction is completed. It will be attached to the
# Checkout Session object upon expiration.
sig { returns(T::Boolean) }
attr_accessor :enabled
sig { params(allow_promotion_codes: T.nilable(T::Boolean), enabled: T::Boolean).void }
def initialize(allow_promotion_codes: nil, enabled: nil); end
end
# Configure a Checkout Session that can be used to recover an expired session.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::AfterExpiration::Recovery))
}
attr_accessor :recovery
sig {
params(recovery: T.nilable(::Stripe::Checkout::SessionService::CreateParams::AfterExpiration::Recovery)).void
}
def initialize(recovery: nil); end
end
class AutomaticTax < Stripe::RequestParams
class Liability < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# Set to `true` to [calculate tax automatically](https://docs.stripe.com/tax) using the customer's location.
#
# Enabling this parameter causes Checkout to collect any billing address information necessary for tax calculation.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::AutomaticTax::Liability))
}
attr_accessor :liability
sig {
params(enabled: T::Boolean, liability: T.nilable(::Stripe::Checkout::SessionService::CreateParams::AutomaticTax::Liability)).void
}
def initialize(enabled: nil, liability: nil); end
end
class ConsentCollection < Stripe::RequestParams
class PaymentMethodReuseAgreement < Stripe::RequestParams
# Determines the position and visibility of the payment method reuse agreement in the UI. When set to `auto`, Stripe's
# defaults will be used. When set to `hidden`, the payment method reuse agreement text will always be hidden in the UI.
sig { returns(String) }
attr_accessor :position
sig { params(position: String).void }
def initialize(position: nil); end
end
# Determines the display of payment method reuse agreement text in the UI. If set to `hidden`, it will hide legal text related to the reuse of a payment method.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::ConsentCollection::PaymentMethodReuseAgreement))
}
attr_accessor :payment_method_reuse_agreement
# If set to `auto`, enables the collection of customer consent for promotional communications. The Checkout
# Session will determine whether to display an option to opt into promotional communication
# from the merchant depending on the customer's locale. Only available to US merchants.
sig { returns(T.nilable(String)) }
attr_accessor :promotions
# If set to `required`, it requires customers to check a terms of service checkbox before being able to pay.
# There must be a valid terms of service URL set in your [Dashboard settings](https://dashboard.stripe.com/settings/public).
sig { returns(T.nilable(String)) }
attr_accessor :terms_of_service
sig {
params(payment_method_reuse_agreement: T.nilable(::Stripe::Checkout::SessionService::CreateParams::ConsentCollection::PaymentMethodReuseAgreement), promotions: T.nilable(String), terms_of_service: T.nilable(String)).void
}
def initialize(
payment_method_reuse_agreement: nil,
promotions: nil,
terms_of_service: nil
); end
end
class CustomField < Stripe::RequestParams
class Dropdown < Stripe::RequestParams
class Option < Stripe::RequestParams
# The label for the option, displayed to the customer. Up to 100 characters.
sig { returns(String) }
attr_accessor :label
# The value for this option, not displayed to the customer, used by your integration to reconcile the option selected by the customer. Must be unique to this option, alphanumeric, and up to 100 characters.
sig { returns(String) }
attr_accessor :value
sig { params(label: String, value: String).void }
def initialize(label: nil, value: nil); end
end
# The value that will pre-fill the field on the payment page.Must match a `value` in the `options` array.
sig { returns(T.nilable(String)) }
attr_accessor :default_value
# The options available for the customer to select. Up to 200 options allowed.
sig {
returns(T::Array[::Stripe::Checkout::SessionService::CreateParams::CustomField::Dropdown::Option])
}
attr_accessor :options
sig {
params(default_value: T.nilable(String), options: T::Array[::Stripe::Checkout::SessionService::CreateParams::CustomField::Dropdown::Option]).void
}
def initialize(default_value: nil, options: nil); end
end
class Label < Stripe::RequestParams
# Custom text for the label, displayed to the customer. Up to 50 characters.
sig { returns(String) }
attr_accessor :custom
# The type of the label.
sig { returns(String) }
attr_accessor :type
sig { params(custom: String, type: String).void }
def initialize(custom: nil, type: nil); end
end
class Numeric < Stripe::RequestParams
# The value that will pre-fill the field on the payment page.
sig { returns(T.nilable(String)) }
attr_accessor :default_value
# The maximum character length constraint for the customer's input.
sig { returns(T.nilable(Integer)) }
attr_accessor :maximum_length
# The minimum character length requirement for the customer's input.
sig { returns(T.nilable(Integer)) }
attr_accessor :minimum_length
sig {
params(default_value: T.nilable(String), maximum_length: T.nilable(Integer), minimum_length: T.nilable(Integer)).void
}
def initialize(default_value: nil, maximum_length: nil, minimum_length: nil); end
end
class Text < Stripe::RequestParams
# The value that will pre-fill the field on the payment page.
sig { returns(T.nilable(String)) }
attr_accessor :default_value
# The maximum character length constraint for the customer's input.
sig { returns(T.nilable(Integer)) }
attr_accessor :maximum_length
# The minimum character length requirement for the customer's input.
sig { returns(T.nilable(Integer)) }
attr_accessor :minimum_length
sig {
params(default_value: T.nilable(String), maximum_length: T.nilable(Integer), minimum_length: T.nilable(Integer)).void
}
def initialize(default_value: nil, maximum_length: nil, minimum_length: nil); end
end
# Configuration for `type=dropdown` fields.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::CustomField::Dropdown))
}
attr_accessor :dropdown
# String of your choice that your integration can use to reconcile this field. Must be unique to this field, alphanumeric, and up to 200 characters.
sig { returns(String) }
attr_accessor :key
# The label for the field, displayed to the customer.
sig { returns(::Stripe::Checkout::SessionService::CreateParams::CustomField::Label) }
attr_accessor :label
# Configuration for `type=numeric` fields.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::CustomField::Numeric))
}
attr_accessor :numeric
# Whether the customer is required to complete the field before completing the Checkout Session. Defaults to `false`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :optional
# Configuration for `type=text` fields.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::CustomField::Text))
}
attr_accessor :text
# The type of the field.
sig { returns(String) }
attr_accessor :type
sig {
params(dropdown: T.nilable(::Stripe::Checkout::SessionService::CreateParams::CustomField::Dropdown), key: String, label: ::Stripe::Checkout::SessionService::CreateParams::CustomField::Label, numeric: T.nilable(::Stripe::Checkout::SessionService::CreateParams::CustomField::Numeric), optional: T.nilable(T::Boolean), text: T.nilable(::Stripe::Checkout::SessionService::CreateParams::CustomField::Text), type: String).void
}
def initialize(
dropdown: nil,
key: nil,
label: nil,
numeric: nil,
optional: nil,
text: nil,
type: nil
); end
end
class CustomText < Stripe::RequestParams
class AfterSubmit < Stripe::RequestParams
# Text may be up to 1200 characters in length.
sig { returns(String) }
attr_accessor :message
sig { params(message: String).void }
def initialize(message: nil); end
end
class ShippingAddress < Stripe::RequestParams
# Text may be up to 1200 characters in length.
sig { returns(String) }
attr_accessor :message
sig { params(message: String).void }
def initialize(message: nil); end
end
class Submit < Stripe::RequestParams
# Text may be up to 1200 characters in length.
sig { returns(String) }
attr_accessor :message
sig { params(message: String).void }
def initialize(message: nil); end
end
class TermsOfServiceAcceptance < Stripe::RequestParams
# Text may be up to 1200 characters in length.
sig { returns(String) }
attr_accessor :message
sig { params(message: String).void }
def initialize(message: nil); end
end
# Custom text that should be displayed after the payment confirmation button.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Checkout::SessionService::CreateParams::CustomText::AfterSubmit))))
}
attr_accessor :after_submit
# Custom text that should be displayed alongside shipping address collection.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Checkout::SessionService::CreateParams::CustomText::ShippingAddress))))
}
attr_accessor :shipping_address
# Custom text that should be displayed alongside the payment confirmation button.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Checkout::SessionService::CreateParams::CustomText::Submit))))
}
attr_accessor :submit
# Custom text that should be displayed in place of the default terms of service agreement text.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Checkout::SessionService::CreateParams::CustomText::TermsOfServiceAcceptance))))
}
attr_accessor :terms_of_service_acceptance
sig {
params(after_submit: T.nilable(T.nilable(T.any(String, ::Stripe::Checkout::SessionService::CreateParams::CustomText::AfterSubmit))), shipping_address: T.nilable(T.nilable(T.any(String, ::Stripe::Checkout::SessionService::CreateParams::CustomText::ShippingAddress))), submit: T.nilable(T.nilable(T.any(String, ::Stripe::Checkout::SessionService::CreateParams::CustomText::Submit))), terms_of_service_acceptance: T.nilable(T.nilable(T.any(String, ::Stripe::Checkout::SessionService::CreateParams::CustomText::TermsOfServiceAcceptance)))).void
}
def initialize(
after_submit: nil,
shipping_address: nil,
submit: nil,
terms_of_service_acceptance: nil
); end
end
class CustomerUpdate < Stripe::RequestParams
# Describes whether Checkout saves the billing address onto `customer.address`.
# To always collect a full billing address, use `billing_address_collection`. Defaults to `never`.
sig { returns(T.nilable(String)) }
attr_accessor :address
# Describes whether Checkout saves the name onto `customer.name`. Defaults to `never`.
sig { returns(T.nilable(String)) }
attr_accessor :name
# Describes whether Checkout saves shipping information onto `customer.shipping`.
# To collect shipping information, use `shipping_address_collection`. Defaults to `never`.
sig { returns(T.nilable(String)) }
attr_accessor :shipping
sig {
params(address: T.nilable(String), name: T.nilable(String), shipping: T.nilable(String)).void
}
def initialize(address: nil, name: nil, shipping: nil); end
end
class Discount < Stripe::RequestParams
# The ID of the coupon to apply to this Session.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# The ID of a promotion code to apply to this Session.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig { params(coupon: T.nilable(String), promotion_code: T.nilable(String)).void }
def initialize(coupon: nil, promotion_code: nil); end
end
class InvoiceCreation < Stripe::RequestParams
class InvoiceData < Stripe::RequestParams
class CustomField < Stripe::RequestParams
# The name of the custom field. This may be up to 40 characters.
sig { returns(String) }
attr_accessor :name
# The value of the custom field. This may be up to 140 characters.
sig { returns(String) }
attr_accessor :value
sig { params(name: String, value: String).void }
def initialize(name: nil, value: nil); end
end
class Issuer < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
class RenderingOptions < Stripe::RequestParams
# How line-item prices and amounts will be displayed with respect to tax on invoice PDFs. One of `exclude_tax` or `include_inclusive_tax`. `include_inclusive_tax` will include inclusive tax (and exclude exclusive tax) in invoice PDF amounts. `exclude_tax` will exclude all tax (inclusive and exclusive alike) from invoice PDF amounts.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :amount_tax_display
sig { params(amount_tax_display: T.nilable(T.nilable(T.any(String, String)))).void }
def initialize(amount_tax_display: nil); end
end
# The account tax IDs associated with the invoice.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :account_tax_ids
# Default custom fields to be displayed on invoices for this customer.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Checkout::SessionService::CreateParams::InvoiceCreation::InvoiceData::CustomField]))))
}
attr_accessor :custom_fields
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Default footer to be displayed on invoices for this customer.
sig { returns(T.nilable(String)) }
attr_accessor :footer
# The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::InvoiceCreation::InvoiceData::Issuer))
}
attr_accessor :issuer
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Default options for invoice PDF rendering for this customer.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Checkout::SessionService::CreateParams::InvoiceCreation::InvoiceData::RenderingOptions))))
}
attr_accessor :rendering_options
sig {
params(account_tax_ids: T.nilable(T.nilable(T.any(String, T::Array[String]))), custom_fields: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Checkout::SessionService::CreateParams::InvoiceCreation::InvoiceData::CustomField]))), description: T.nilable(String), footer: T.nilable(String), issuer: T.nilable(::Stripe::Checkout::SessionService::CreateParams::InvoiceCreation::InvoiceData::Issuer), metadata: T.nilable(T::Hash[String, String]), rendering_options: T.nilable(T.nilable(T.any(String, ::Stripe::Checkout::SessionService::CreateParams::InvoiceCreation::InvoiceData::RenderingOptions)))).void
}
def initialize(
account_tax_ids: nil,
custom_fields: nil,
description: nil,
footer: nil,
issuer: nil,
metadata: nil,
rendering_options: nil
); end
end
# Set to `true` to enable invoice creation.
sig { returns(T::Boolean) }
attr_accessor :enabled
# Parameters passed when creating invoices for payment-mode Checkout Sessions.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::InvoiceCreation::InvoiceData))
}
attr_accessor :invoice_data
sig {
params(enabled: T::Boolean, invoice_data: T.nilable(::Stripe::Checkout::SessionService::CreateParams::InvoiceCreation::InvoiceData)).void
}
def initialize(enabled: nil, invoice_data: nil); end
end
class LineItem < Stripe::RequestParams
class AdjustableQuantity < Stripe::RequestParams
# Set to true if the quantity can be adjusted to any non-negative integer.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The maximum quantity the customer can purchase for the Checkout Session. By default this value is 99. You can specify a value up to 999999.
sig { returns(T.nilable(Integer)) }
attr_accessor :maximum
# The minimum quantity the customer must purchase for the Checkout Session. By default this value is 0.
sig { returns(T.nilable(Integer)) }
attr_accessor :minimum
sig {
params(enabled: T::Boolean, maximum: T.nilable(Integer), minimum: T.nilable(Integer)).void
}
def initialize(enabled: nil, maximum: nil, minimum: nil); end
end
class PriceData < Stripe::RequestParams
class ProductData < Stripe::RequestParams
# The product's description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes.
sig { returns(T.nilable(String)) }
attr_accessor :description
# A list of up to 8 URLs of images for this product, meant to be displayable to the customer.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :images
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The product's name, meant to be displayable to the customer.
sig { returns(String) }
attr_accessor :name
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
sig { returns(T.nilable(String)) }
attr_accessor :tax_code
sig {
params(description: T.nilable(String), images: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), name: String, tax_code: T.nilable(String)).void
}
def initialize(
description: nil,
images: nil,
metadata: nil,
name: nil,
tax_code: nil
); end
end
class Recurring < Stripe::RequestParams
# Specifies billing frequency. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: T.nilable(Integer)).void }
def initialize(interval: nil, interval_count: nil); end
end
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to. One of `product` or `product_data` is required.
sig { returns(T.nilable(String)) }
attr_accessor :product
# Data used to generate a new [Product](https://docs.stripe.com/api/products) object inline. One of `product` or `product_data` is required.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::LineItem::PriceData::ProductData))
}
attr_accessor :product_data
# The recurring components of a price such as `interval` and `interval_count`.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::LineItem::PriceData::Recurring))
}
attr_accessor :recurring
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A non-negative integer in cents (or local equivalent) representing how much to charge. One of `unit_amount` or `unit_amount_decimal` is required.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, product: T.nilable(String), product_data: T.nilable(::Stripe::Checkout::SessionService::CreateParams::LineItem::PriceData::ProductData), recurring: T.nilable(::Stripe::Checkout::SessionService::CreateParams::LineItem::PriceData::Recurring), tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
product_data: nil,
recurring: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
# When set, provides configuration for this item’s quantity to be adjusted by the customer during Checkout.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::LineItem::AdjustableQuantity))
}
attr_accessor :adjustable_quantity
# The [tax rates](https://stripe.com/docs/api/tax_rates) that will be applied to this line item depending on the customer's billing/shipping address. We currently support the following countries: US, GB, AU, and all countries in the EU.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :dynamic_tax_rates
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The ID of the [Price](https://stripe.com/docs/api/prices) or [Plan](https://stripe.com/docs/api/plans) object. One of `price` or `price_data` is required.
sig { returns(T.nilable(String)) }
attr_accessor :price
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::LineItem::PriceData))
}
attr_accessor :price_data
# The quantity of the line item being purchased. Quantity should not be defined when `recurring.usage_type=metered`.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# The [tax rates](https://stripe.com/docs/api/tax_rates) which apply to this line item.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :tax_rates
sig {
params(adjustable_quantity: T.nilable(::Stripe::Checkout::SessionService::CreateParams::LineItem::AdjustableQuantity), dynamic_tax_rates: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), price: T.nilable(String), price_data: T.nilable(::Stripe::Checkout::SessionService::CreateParams::LineItem::PriceData), quantity: T.nilable(Integer), tax_rates: T.nilable(T::Array[String])).void
}
def initialize(
adjustable_quantity: nil,
dynamic_tax_rates: nil,
metadata: nil,
price: nil,
price_data: nil,
quantity: nil,
tax_rates: nil
); end
end
class OptionalItem < Stripe::RequestParams
class AdjustableQuantity < Stripe::RequestParams
# Set to true if the quantity can be adjusted to any non-negative integer.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The maximum quantity of this item the customer can purchase. By default this value is 99. You can specify a value up to 999999.
sig { returns(T.nilable(Integer)) }
attr_accessor :maximum
# The minimum quantity of this item the customer must purchase, if they choose to purchase it. Because this item is optional, the customer will always be able to remove it from their order, even if the `minimum` configured here is greater than 0. By default this value is 0.
sig { returns(T.nilable(Integer)) }
attr_accessor :minimum
sig {
params(enabled: T::Boolean, maximum: T.nilable(Integer), minimum: T.nilable(Integer)).void
}
def initialize(enabled: nil, maximum: nil, minimum: nil); end
end
# When set, provides configuration for the customer to adjust the quantity of the line item created when a customer chooses to add this optional item to their order.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::OptionalItem::AdjustableQuantity))
}
attr_accessor :adjustable_quantity
# The ID of the [Price](https://stripe.com/docs/api/prices) or [Plan](https://stripe.com/docs/api/plans) object.
sig { returns(String) }
attr_accessor :price
# The initial quantity of the line item created when a customer chooses to add this optional item to their order.
sig { returns(Integer) }
attr_accessor :quantity
sig {
params(adjustable_quantity: T.nilable(::Stripe::Checkout::SessionService::CreateParams::OptionalItem::AdjustableQuantity), price: String, quantity: Integer).void
}
def initialize(adjustable_quantity: nil, price: nil, quantity: nil); end
end
class PaymentIntentData < Stripe::RequestParams
class Shipping < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(String) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: String, line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Shipping address.
sig {
returns(::Stripe::Checkout::SessionService::CreateParams::PaymentIntentData::Shipping::Address)
}
attr_accessor :address
# The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
sig { returns(T.nilable(String)) }
attr_accessor :carrier
# Recipient name.
sig { returns(String) }
attr_accessor :name
# Recipient phone (including extension).
sig { returns(T.nilable(String)) }
attr_accessor :phone
# The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
sig { returns(T.nilable(String)) }
attr_accessor :tracking_number
sig {
params(address: ::Stripe::Checkout::SessionService::CreateParams::PaymentIntentData::Shipping::Address, carrier: T.nilable(String), name: String, phone: T.nilable(String), tracking_number: T.nilable(String)).void
}
def initialize(
address: nil,
carrier: nil,
name: nil,
phone: nil,
tracking_number: nil
); end
end
class TransferData < Stripe::RequestParams
# The amount that will be transferred automatically when a charge succeeds.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# If specified, successful charges will be attributed to the destination
# account for tax reporting, and the funds from charges will be transferred
# to the destination account. The ID of the resulting transfer will be
# returned on the successful charge's `transfer` field.
sig { returns(String) }
attr_accessor :destination
sig { params(amount: T.nilable(Integer), destination: String).void }
def initialize(amount: nil, destination: nil); end
end
# The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. The amount of the application fee collected will be capped at the total amount captured. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
sig { returns(T.nilable(Integer)) }
attr_accessor :application_fee_amount
# Controls when the funds will be captured from the customer's account.
sig { returns(T.nilable(String)) }
attr_accessor :capture_method
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The Stripe account ID for which these funds are intended. For details,
# see the PaymentIntents [use case for connected
# accounts](/docs/payments/connected-accounts).
sig { returns(T.nilable(String)) }
attr_accessor :on_behalf_of
# Email address that the receipt for the resulting payment will be sent to. If `receipt_email` is specified for a payment in live mode, a receipt will be sent regardless of your [email settings](https://dashboard.stripe.com/account/emails).
sig { returns(T.nilable(String)) }
attr_accessor :receipt_email
# Indicates that you intend to [make future payments](https://stripe.com/docs/payments/payment-intents#future-usage) with the payment
# method collected by this Checkout Session.
#
# When setting this to `on_session`, Checkout will show a notice to the
# customer that their payment details will be saved.
#
# When setting this to `off_session`, Checkout will show a notice to the
# customer that their payment details will be saved and used for future
# payments.
#
# If a Customer has been provided or Checkout creates a new Customer,
# Checkout will attach the payment method to the Customer.
#
# If Checkout does not create a Customer, the payment method is not attached
# to a Customer. To reuse the payment method, you can retrieve it from the
# Checkout Session's PaymentIntent.
#
# When processing card payments, Checkout also uses `setup_future_usage`
# to dynamically optimize your payment flow and comply with regional
# legislation and network rules, such as SCA.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
# Shipping information for this payment.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentIntentData::Shipping))
}
attr_accessor :shipping
# Text that appears on the customer's statement as the statement descriptor for a non-card charge. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
#
# Setting this value for a card charge returns an error. For card charges, set the [statement_descriptor_suffix](https://docs.stripe.com/get-started/account/statement-descriptors#dynamic) instead.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
# Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor_suffix
# The parameters used to automatically create a Transfer when the payment succeeds.
# For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentIntentData::TransferData))
}
attr_accessor :transfer_data
# A string that identifies the resulting payment as part of a group. See the PaymentIntents [use case for connected accounts](https://stripe.com/docs/connect/separate-charges-and-transfers) for details.
sig { returns(T.nilable(String)) }
attr_accessor :transfer_group
sig {
params(application_fee_amount: T.nilable(Integer), capture_method: T.nilable(String), description: T.nilable(String), metadata: T.nilable(T::Hash[String, String]), on_behalf_of: T.nilable(String), receipt_email: T.nilable(String), setup_future_usage: T.nilable(String), shipping: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentIntentData::Shipping), statement_descriptor: T.nilable(String), statement_descriptor_suffix: T.nilable(String), transfer_data: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentIntentData::TransferData), transfer_group: T.nilable(String)).void
}
def initialize(
application_fee_amount: nil,
capture_method: nil,
description: nil,
metadata: nil,
on_behalf_of: nil,
receipt_email: nil,
setup_future_usage: nil,
shipping: nil,
statement_descriptor: nil,
statement_descriptor_suffix: nil,
transfer_data: nil,
transfer_group: nil
); end
end
class PaymentMethodData < Stripe::RequestParams
# Allow redisplay will be set on the payment method on confirmation and indicates whether this payment method can be shown again to the customer in a checkout flow. Only set this field if you wish to override the allow_redisplay value determined by Checkout.
sig { returns(T.nilable(String)) }
attr_accessor :allow_redisplay
sig { params(allow_redisplay: T.nilable(String)).void }
def initialize(allow_redisplay: nil); end
end
class PaymentMethodOptions < Stripe::RequestParams
class AcssDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# A URL for custom mandate text to render during confirmation step.
# The URL will be rendered with additional GET parameters `payment_intent` and `payment_intent_client_secret` when confirming a Payment Intent,
# or `setup_intent` and `setup_intent_client_secret` when confirming a Setup Intent.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :custom_mandate_url
# List of Stripe products where this mandate can be selected automatically. Only usable in `setup` mode.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :default_for
# Description of the mandate interval. Only required if 'payment_schedule' parameter is 'interval' or 'combined'.
sig { returns(T.nilable(String)) }
attr_accessor :interval_description
# Payment schedule for the mandate.
sig { returns(T.nilable(String)) }
attr_accessor :payment_schedule
# Transaction type of the mandate.
sig { returns(T.nilable(String)) }
attr_accessor :transaction_type
sig {
params(custom_mandate_url: T.nilable(T.nilable(String)), default_for: T.nilable(T::Array[String]), interval_description: T.nilable(String), payment_schedule: T.nilable(String), transaction_type: T.nilable(String)).void
}
def initialize(
custom_mandate_url: nil,
default_for: nil,
interval_description: nil,
payment_schedule: nil,
transaction_type: nil
); end
end
# 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). This is only accepted for Checkout Sessions in `setup` mode.
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::AcssDebit::MandateOptions))
}
attr_accessor :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
# Verification method for the intent
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(currency: T.nilable(String), mandate_options: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::AcssDebit::MandateOptions), setup_future_usage: T.nilable(String), target_date: T.nilable(String), verification_method: T.nilable(String)).void
}
def initialize(
currency: nil,
mandate_options: nil,
setup_future_usage: nil,
target_date: nil,
verification_method: nil
); end
end
class Affirm < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class AfterpayClearpay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Alipay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class AmazonPay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class AuBecsDebit < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
sig {
params(setup_future_usage: T.nilable(String), target_date: T.nilable(String)).void
}
def initialize(setup_future_usage: nil, target_date: nil); end
end
class BacsDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'DDIC' or 'STRIPE'.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :reference_prefix
sig { params(reference_prefix: T.nilable(T.nilable(String))).void }
def initialize(reference_prefix: nil); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::BacsDebit::MandateOptions))
}
attr_accessor :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
sig {
params(mandate_options: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::BacsDebit::MandateOptions), setup_future_usage: T.nilable(String), target_date: T.nilable(String)).void
}
def initialize(mandate_options: nil, setup_future_usage: nil, target_date: nil); end
end
class Bancontact < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Boleto < Stripe::RequestParams
# The number of calendar days before a Boleto voucher expires. For example, if you create a Boleto voucher on Monday and you set expires_after_days to 2, the Boleto invoice will expire on Wednesday at 23:59 America/Sao_Paulo time.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_after_days
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(expires_after_days: T.nilable(Integer), setup_future_usage: T.nilable(String)).void
}
def initialize(expires_after_days: nil, setup_future_usage: nil); end
end
class Card < Stripe::RequestParams
class Installments < Stripe::RequestParams
# Setting to true enables installments for this Checkout Session.
# Setting to false will prevent any installment plan from applying to a payment.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :enabled
sig { params(enabled: T.nilable(T::Boolean)).void }
def initialize(enabled: nil); end
end
class Restrictions < Stripe::RequestParams
# Specify the card brands to block in the Checkout Session. If a customer enters or selects a card belonging to a blocked brand, they can't complete the Session.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :brands_blocked
sig { params(brands_blocked: T.nilable(T::Array[String])).void }
def initialize(brands_blocked: nil); end
end
# Installment options for card payments
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Card::Installments))
}
attr_accessor :installments
# Request ability to [capture beyond the standard authorization validity window](/payments/extended-authorization) for this CheckoutSession.
sig { returns(T.nilable(String)) }
attr_accessor :request_decremental_authorization
# Request ability to [capture beyond the standard authorization validity window](/payments/extended-authorization) for this CheckoutSession.
sig { returns(T.nilable(String)) }
attr_accessor :request_extended_authorization
# Request ability to [increment the authorization](/payments/incremental-authorization) for this CheckoutSession.
sig { returns(T.nilable(String)) }
attr_accessor :request_incremental_authorization
# Request ability to make [multiple captures](/payments/multicapture) for this CheckoutSession.
sig { returns(T.nilable(String)) }
attr_accessor :request_multicapture
# Request ability to [overcapture](/payments/overcapture) for this CheckoutSession.
sig { returns(T.nilable(String)) }
attr_accessor :request_overcapture
# We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. If not provided, this value defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
sig { returns(T.nilable(String)) }
attr_accessor :request_three_d_secure
# Restrictions to apply to the card payment method. For example, you can block specific card brands.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Card::Restrictions))
}
attr_accessor :restrictions
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
# Provides information about a card payment that customers see on their statements. Concatenated with the Kana prefix (shortened Kana descriptor) or Kana statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 22 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 22 characters.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor_suffix_kana
# Provides information about a card payment that customers see on their statements. Concatenated with the Kanji prefix (shortened Kanji descriptor) or Kanji statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 17 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 17 characters.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor_suffix_kanji
sig {
params(installments: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Card::Installments), request_decremental_authorization: T.nilable(String), request_extended_authorization: T.nilable(String), request_incremental_authorization: T.nilable(String), request_multicapture: T.nilable(String), request_overcapture: T.nilable(String), request_three_d_secure: T.nilable(String), restrictions: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Card::Restrictions), setup_future_usage: T.nilable(String), statement_descriptor_suffix_kana: T.nilable(String), statement_descriptor_suffix_kanji: T.nilable(String)).void
}
def initialize(
installments: nil,
request_decremental_authorization: nil,
request_extended_authorization: nil,
request_incremental_authorization: nil,
request_multicapture: nil,
request_overcapture: nil,
request_three_d_secure: nil,
restrictions: nil,
setup_future_usage: nil,
statement_descriptor_suffix_kana: nil,
statement_descriptor_suffix_kanji: nil
); end
end
class Cashapp < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class CustomerBalance < Stripe::RequestParams
class BankTransfer < Stripe::RequestParams
class EuBankTransfer < Stripe::RequestParams
# The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
sig { returns(String) }
attr_accessor :country
sig { params(country: String).void }
def initialize(country: nil); end
end
# Configuration for eu_bank_transfer funding type.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::CustomerBalance::BankTransfer::EuBankTransfer))
}
attr_accessor :eu_bank_transfer
# List of address types that should be returned in the financial_addresses response. If not specified, all valid types will be returned.
#
# Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :requested_address_types
# The list of bank transfer types that this PaymentIntent is allowed to use for funding.
sig { returns(String) }
attr_accessor :type
sig {
params(eu_bank_transfer: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::CustomerBalance::BankTransfer::EuBankTransfer), requested_address_types: T.nilable(T::Array[String]), type: String).void
}
def initialize(eu_bank_transfer: nil, requested_address_types: nil, type: nil); end
end
# Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::CustomerBalance::BankTransfer))
}
attr_accessor :bank_transfer
# The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
sig { returns(T.nilable(String)) }
attr_accessor :funding_type
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(bank_transfer: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::CustomerBalance::BankTransfer), funding_type: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(bank_transfer: nil, funding_type: nil, setup_future_usage: nil); end
end
class Eps < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Fpx < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Giropay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Grabpay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Ideal < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class KakaoPay < Stripe::RequestParams
# Controls when the funds will be captured from the customer's account.
sig { returns(T.nilable(String)) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class Klarna < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Konbini < Stripe::RequestParams
# The number of calendar days (between 1 and 60) after which Konbini payment instructions will expire. For example, if a PaymentIntent is confirmed with Konbini and `expires_after_days` set to 2 on Monday JST, the instructions will expire on Wednesday 23:59:59 JST. Defaults to 3 days.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_after_days
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(expires_after_days: T.nilable(Integer), setup_future_usage: T.nilable(String)).void
}
def initialize(expires_after_days: nil, setup_future_usage: nil); end
end
class KrCard < Stripe::RequestParams
# Controls when the funds will be captured from the customer's account.
sig { returns(T.nilable(String)) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class Link < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Mobilepay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Multibanco < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class NaverPay < Stripe::RequestParams
# Controls when the funds will be captured from the customer's account.
sig { returns(T.nilable(String)) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class Oxxo < Stripe::RequestParams
# The number of calendar days before an OXXO voucher expires. For example, if you create an OXXO voucher on Monday and you set expires_after_days to 2, the OXXO invoice will expire on Wednesday at 23:59 America/Mexico_City time.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_after_days
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(expires_after_days: T.nilable(Integer), setup_future_usage: T.nilable(String)).void
}
def initialize(expires_after_days: nil, setup_future_usage: nil); end
end
class P24 < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
# Confirm that the payer has accepted the P24 terms and conditions.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :tos_shown_and_accepted
sig {
params(setup_future_usage: T.nilable(String), tos_shown_and_accepted: T.nilable(T::Boolean)).void
}
def initialize(setup_future_usage: nil, tos_shown_and_accepted: nil); end
end
class PayByBank < Stripe::RequestParams; end
class Payco < Stripe::RequestParams
# Controls when the funds will be captured from the customer's account.
sig { returns(T.nilable(String)) }
attr_accessor :capture_method
sig { params(capture_method: T.nilable(String)).void }
def initialize(capture_method: nil); end
end
class Paynow < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Paypal < Stripe::RequestParams
# Controls when the funds will be captured from the customer's account.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# [Preferred locale](https://stripe.com/docs/payments/paypal/supported-locales) of the PayPal checkout page that the customer is redirected to.
sig { returns(T.nilable(String)) }
attr_accessor :preferred_locale
# A reference of the PayPal transaction visible to customer which is mapped to PayPal's invoice ID. This must be a globally unique ID if you have configured in your PayPal settings to block multiple payments per invoice ID.
sig { returns(T.nilable(String)) }
attr_accessor :reference
# A reference of the PayPal transaction visible to customer which is mapped to PayPal's invoice ID. This must be a globally unique ID if you have configured in your PayPal settings to block multiple payments per invoice ID.
sig { returns(T.nilable(String)) }
attr_accessor :reference_id
# The risk correlation ID for an on-session payment using a saved PayPal payment method.
sig { returns(T.nilable(String)) }
attr_accessor :risk_correlation_id
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# The Stripe connected account IDs of the sellers on the platform for this transaction (optional). Only allowed when [separate charges and transfers](https://stripe.com/docs/connect/separate-charges-and-transfers) are used.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :subsellers
sig {
params(capture_method: T.nilable(T.nilable(String)), preferred_locale: T.nilable(String), reference: T.nilable(String), reference_id: T.nilable(String), risk_correlation_id: T.nilable(String), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), subsellers: T.nilable(T::Array[String])).void
}
def initialize(
capture_method: nil,
preferred_locale: nil,
reference: nil,
reference_id: nil,
risk_correlation_id: nil,
setup_future_usage: nil,
subsellers: nil
); end
end
class Payto < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Amount that will be collected. It is required when `amount_type` is `fixed`.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# The type of amount that will be collected. The amount charged must be exact or up to the value of `amount` param for `fixed` or `maximum` type respectively.
sig { returns(T.nilable(String)) }
attr_accessor :amount_type
# Date, in YYYY-MM-DD format, after which payments will not be collected. Defaults to no end date.
sig { returns(T.nilable(String)) }
attr_accessor :end_date
# The periodicity at which payments will be collected.
sig { returns(T.nilable(String)) }
attr_accessor :payment_schedule
# The number of payments that will be made during a payment period. Defaults to 1 except for when `payment_schedule` is `adhoc`. In that case, it defaults to no limit.
sig { returns(T.nilable(Integer)) }
attr_accessor :payments_per_period
# The purpose for which payments are made. Defaults to retail.
sig { returns(T.nilable(String)) }
attr_accessor :purpose
# Date, in YYYY-MM-DD format, from which payments will be collected. Defaults to confirmation time.
sig { returns(T.nilable(String)) }
attr_accessor :start_date
sig {
params(amount: T.nilable(Integer), amount_type: T.nilable(String), end_date: T.nilable(String), payment_schedule: T.nilable(String), payments_per_period: T.nilable(Integer), purpose: T.nilable(String), start_date: T.nilable(String)).void
}
def initialize(
amount: nil,
amount_type: nil,
end_date: nil,
payment_schedule: nil,
payments_per_period: nil,
purpose: nil,
start_date: nil
); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Payto::MandateOptions))
}
attr_accessor :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(mandate_options: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Payto::MandateOptions), setup_future_usage: T.nilable(String)).void
}
def initialize(mandate_options: nil, setup_future_usage: nil); end
end
class Pix < Stripe::RequestParams
# The number of seconds (between 10 and 1209600) after which Pix payment will expire. Defaults to 86400 seconds.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_after_seconds
sig { params(expires_after_seconds: T.nilable(Integer)).void }
def initialize(expires_after_seconds: nil); end
end
class RevolutPay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class SamsungPay < Stripe::RequestParams
# Controls when the funds will be captured from the customer's account.
sig { returns(T.nilable(String)) }
attr_accessor :capture_method
sig { params(capture_method: T.nilable(String)).void }
def initialize(capture_method: nil); end
end
class SepaDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'STRIPE'.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :reference_prefix
sig { params(reference_prefix: T.nilable(T.nilable(String))).void }
def initialize(reference_prefix: nil); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::SepaDebit::MandateOptions))
}
attr_accessor :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
sig {
params(mandate_options: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::SepaDebit::MandateOptions), setup_future_usage: T.nilable(String), target_date: T.nilable(String)).void
}
def initialize(mandate_options: nil, setup_future_usage: nil, target_date: nil); end
end
class Sofort < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Swish < Stripe::RequestParams
# The order reference that will be displayed to customers in the Swish application. Defaults to the `id` of the Payment Intent.
sig { returns(T.nilable(String)) }
attr_accessor :reference
sig { params(reference: T.nilable(String)).void }
def initialize(reference: nil); end
end
class UsBankAccount < Stripe::RequestParams
class FinancialConnections < Stripe::RequestParams
# The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :permissions
# List of data features that you would like to retrieve upon account creation.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :prefetch
sig {
params(permissions: T.nilable(T::Array[String]), prefetch: T.nilable(T::Array[String])).void
}
def initialize(permissions: nil, prefetch: nil); end
end
# Additional fields for Financial Connections Session creation
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections))
}
attr_accessor :financial_connections
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
# Verification method for the intent
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(financial_connections: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections), setup_future_usage: T.nilable(String), target_date: T.nilable(String), verification_method: T.nilable(String)).void
}
def initialize(
financial_connections: nil,
setup_future_usage: nil,
target_date: nil,
verification_method: nil
); end
end
class WechatPay < Stripe::RequestParams
# The app ID registered with WeChat Pay. Only required when client is ios or android.
sig { returns(T.nilable(String)) }
attr_accessor :app_id
# The client type that the end customer will pay from
sig { returns(String) }
attr_accessor :client
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(app_id: T.nilable(String), client: String, setup_future_usage: T.nilable(String)).void
}
def initialize(app_id: nil, client: nil, setup_future_usage: nil); end
end
# contains details about the ACSS Debit payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::AcssDebit))
}
attr_accessor :acss_debit
# contains details about the Affirm payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Affirm))
}
attr_accessor :affirm
# contains details about the Afterpay Clearpay payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::AfterpayClearpay))
}
attr_accessor :afterpay_clearpay
# contains details about the Alipay payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Alipay))
}
attr_accessor :alipay
# contains details about the AmazonPay payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::AmazonPay))
}
attr_accessor :amazon_pay
# contains details about the AU Becs Debit payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::AuBecsDebit))
}
attr_accessor :au_becs_debit
# contains details about the Bacs Debit payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::BacsDebit))
}
attr_accessor :bacs_debit
# contains details about the Bancontact payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Bancontact))
}
attr_accessor :bancontact
# contains details about the Boleto payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Boleto))
}
attr_accessor :boleto
# contains details about the Card payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Card))
}
attr_accessor :card
# contains details about the Cashapp Pay payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Cashapp))
}
attr_accessor :cashapp
# contains details about the Customer Balance payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::CustomerBalance))
}
attr_accessor :customer_balance
# contains details about the EPS payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Eps))
}
attr_accessor :eps
# contains details about the FPX payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Fpx))
}
attr_accessor :fpx
# contains details about the Giropay payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Giropay))
}
attr_accessor :giropay
# contains details about the Grabpay payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Grabpay))
}
attr_accessor :grabpay
# contains details about the Ideal payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Ideal))
}
attr_accessor :ideal
# contains details about the Kakao Pay payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::KakaoPay))
}
attr_accessor :kakao_pay
# contains details about the Klarna payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Klarna))
}
attr_accessor :klarna
# contains details about the Konbini payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Konbini))
}
attr_accessor :konbini
# contains details about the Korean card payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::KrCard))
}
attr_accessor :kr_card
# contains details about the Link payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Link))
}
attr_accessor :link
# contains details about the Mobilepay payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Mobilepay))
}
attr_accessor :mobilepay
# contains details about the Multibanco payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Multibanco))
}
attr_accessor :multibanco
# contains details about the Naver Pay payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::NaverPay))
}
attr_accessor :naver_pay
# contains details about the OXXO payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Oxxo))
}
attr_accessor :oxxo
# contains details about the P24 payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::P24))
}
attr_accessor :p24
# contains details about the Pay By Bank payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::PayByBank))
}
attr_accessor :pay_by_bank
# contains details about the PAYCO payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Payco))
}
attr_accessor :payco
# contains details about the PayNow payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Paynow))
}
attr_accessor :paynow
# contains details about the PayPal payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Paypal))
}
attr_accessor :paypal
# contains details about the PayTo payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Payto))
}
attr_accessor :payto
# contains details about the Pix payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Pix))
}
attr_accessor :pix
# contains details about the RevolutPay payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::RevolutPay))
}
attr_accessor :revolut_pay
# contains details about the Samsung Pay payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::SamsungPay))
}
attr_accessor :samsung_pay
# contains details about the Sepa Debit payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::SepaDebit))
}
attr_accessor :sepa_debit
# contains details about the Sofort payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Sofort))
}
attr_accessor :sofort
# contains details about the Swish payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Swish))
}
attr_accessor :swish
# contains details about the Us Bank Account payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::UsBankAccount))
}
attr_accessor :us_bank_account
# contains details about the WeChat Pay payment method options.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::WechatPay))
}
attr_accessor :wechat_pay
sig {
params(acss_debit: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::AcssDebit), affirm: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Affirm), afterpay_clearpay: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::AfterpayClearpay), alipay: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Alipay), amazon_pay: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::AmazonPay), au_becs_debit: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::AuBecsDebit), bacs_debit: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::BacsDebit), bancontact: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Bancontact), boleto: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Boleto), card: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Card), cashapp: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Cashapp), customer_balance: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::CustomerBalance), eps: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Eps), fpx: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Fpx), giropay: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Giropay), grabpay: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Grabpay), ideal: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Ideal), kakao_pay: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::KakaoPay), klarna: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Klarna), konbini: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Konbini), kr_card: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::KrCard), link: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Link), mobilepay: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Mobilepay), multibanco: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Multibanco), naver_pay: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::NaverPay), oxxo: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Oxxo), p24: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::P24), pay_by_bank: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::PayByBank), payco: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Payco), paynow: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Paynow), paypal: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Paypal), payto: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Payto), pix: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Pix), revolut_pay: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::RevolutPay), samsung_pay: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::SamsungPay), sepa_debit: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::SepaDebit), sofort: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Sofort), swish: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::Swish), us_bank_account: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::UsBankAccount), wechat_pay: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions::WechatPay)).void
}
def initialize(
acss_debit: nil,
affirm: nil,
afterpay_clearpay: nil,
alipay: nil,
amazon_pay: nil,
au_becs_debit: nil,
bacs_debit: nil,
bancontact: nil,
boleto: nil,
card: nil,
cashapp: nil,
customer_balance: nil,
eps: nil,
fpx: nil,
giropay: nil,
grabpay: nil,
ideal: nil,
kakao_pay: nil,
klarna: nil,
konbini: nil,
kr_card: nil,
link: nil,
mobilepay: nil,
multibanco: nil,
naver_pay: nil,
oxxo: nil,
p24: nil,
pay_by_bank: nil,
payco: nil,
paynow: nil,
paypal: nil,
payto: nil,
pix: nil,
revolut_pay: nil,
samsung_pay: nil,
sepa_debit: nil,
sofort: nil,
swish: nil,
us_bank_account: nil,
wechat_pay: nil
); end
end
class Permissions < Stripe::RequestParams
class Update < Stripe::RequestParams
# Determines which entity is allowed to update the line items.
#
# Default is `client_only`. Stripe Checkout client will automatically update the line items. If set to `server_only`, only your server is allowed to update the line items.
#
# When set to `server_only`, you must add the onLineItemsChange event handler when initializing the Stripe Checkout client and manually update the line items from your server using the Stripe API.
sig { returns(T.nilable(String)) }
attr_accessor :line_items
# Determines which entity is allowed to update the shipping details.
#
# Default is `client_only`. Stripe Checkout client will automatically update the shipping details. If set to `server_only`, only your server is allowed to update the shipping details.
#
# When set to `server_only`, you must add the onShippingDetailsChange event handler when initializing the Stripe Checkout client and manually update the shipping details from your server using the Stripe API.
sig { returns(T.nilable(String)) }
attr_accessor :shipping_details
sig { params(line_items: T.nilable(String), shipping_details: T.nilable(String)).void }
def initialize(line_items: nil, shipping_details: nil); end
end
# Permissions for updating the Checkout Session.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::Permissions::Update))
}
attr_accessor :update
# Determines which entity is allowed to update the line items.
#
# Default is `client_only`. Stripe Checkout client will automatically update the line items. If set to `server_only`, only your server is allowed to update the line items.
#
# When set to `server_only`, you must add the onLineItemsChange event handler when initializing the Stripe Checkout client and manually update the line items from your server using the Stripe API.
sig { returns(T.nilable(String)) }
attr_accessor :update_line_items
# Determines which entity is allowed to update the shipping details.
#
# Default is `client_only`. Stripe Checkout client will automatically update the shipping details. If set to `server_only`, only your server is allowed to update the shipping details.
#
# When set to `server_only`, you must add the onShippingDetailsChange event handler when initializing the Stripe Checkout client and manually update the shipping details from your server using the Stripe API.
sig { returns(T.nilable(String)) }
attr_accessor :update_shipping_details
sig {
params(update: T.nilable(::Stripe::Checkout::SessionService::CreateParams::Permissions::Update), update_line_items: T.nilable(String), update_shipping_details: T.nilable(String)).void
}
def initialize(update: nil, update_line_items: nil, update_shipping_details: nil); end
end
class PhoneNumberCollection < Stripe::RequestParams
# Set to `true` to enable phone number collection.
#
# Can only be set in `payment` and `subscription` mode.
sig { returns(T::Boolean) }
attr_accessor :enabled
sig { params(enabled: T::Boolean).void }
def initialize(enabled: nil); end
end
class SavedPaymentMethodOptions < Stripe::RequestParams
# Uses the `allow_redisplay` value of each saved payment method to filter the set presented to a returning customer. By default, only saved payment methods with ’allow_redisplay: ‘always’ are shown in Checkout.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :allow_redisplay_filters
# Enable customers to choose if they wish to remove their saved payment methods. Disabled by default.
sig { returns(T.nilable(String)) }
attr_accessor :payment_method_remove
# Enable customers to choose if they wish to save their payment method for future use. Disabled by default.
sig { returns(T.nilable(String)) }
attr_accessor :payment_method_save
sig {
params(allow_redisplay_filters: T.nilable(T::Array[String]), payment_method_remove: T.nilable(String), payment_method_save: T.nilable(String)).void
}
def initialize(
allow_redisplay_filters: nil,
payment_method_remove: nil,
payment_method_save: nil
); end
end
class SetupIntentData < Stripe::RequestParams
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The Stripe account for which the setup is intended.
sig { returns(T.nilable(String)) }
attr_accessor :on_behalf_of
sig {
params(description: T.nilable(String), metadata: T.nilable(T::Hash[String, String]), on_behalf_of: T.nilable(String)).void
}
def initialize(description: nil, metadata: nil, on_behalf_of: nil); end
end
class ShippingAddressCollection < Stripe::RequestParams
# An array of two-letter ISO country codes representing which countries Checkout should provide as options for
# shipping locations.
sig { returns(T::Array[String]) }
attr_accessor :allowed_countries
sig { params(allowed_countries: T::Array[String]).void }
def initialize(allowed_countries: nil); end
end
class ShippingOption < Stripe::RequestParams
class ShippingRateData < Stripe::RequestParams
class DeliveryEstimate < Stripe::RequestParams
class Maximum < Stripe::RequestParams
# A unit of time.
sig { returns(String) }
attr_accessor :unit
# Must be greater than 0.
sig { returns(Integer) }
attr_accessor :value
sig { params(unit: String, value: Integer).void }
def initialize(unit: nil, value: nil); end
end
class Minimum < Stripe::RequestParams
# A unit of time.
sig { returns(String) }
attr_accessor :unit
# Must be greater than 0.
sig { returns(Integer) }
attr_accessor :value
sig { params(unit: String, value: Integer).void }
def initialize(unit: nil, value: nil); end
end
# The upper bound of the estimated range. If empty, represents no upper bound i.e., infinite.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::ShippingOption::ShippingRateData::DeliveryEstimate::Maximum))
}
attr_accessor :maximum
# The lower bound of the estimated range. If empty, represents no lower bound.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::ShippingOption::ShippingRateData::DeliveryEstimate::Minimum))
}
attr_accessor :minimum
sig {
params(maximum: T.nilable(::Stripe::Checkout::SessionService::CreateParams::ShippingOption::ShippingRateData::DeliveryEstimate::Maximum), minimum: T.nilable(::Stripe::Checkout::SessionService::CreateParams::ShippingOption::ShippingRateData::DeliveryEstimate::Minimum)).void
}
def initialize(maximum: nil, minimum: nil); end
end
class FixedAmount < Stripe::RequestParams
class CurrencyOptions < Stripe::RequestParams
# A non-negative integer in cents representing how much to charge.
sig { returns(Integer) }
attr_accessor :amount
# Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
sig { params(amount: Integer, tax_behavior: T.nilable(String)).void }
def initialize(amount: nil, tax_behavior: nil); end
end
# A non-negative integer in cents representing how much to charge.
sig { returns(Integer) }
attr_accessor :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).
sig { returns(String) }
attr_accessor :currency
# Shipping rates defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
sig {
returns(T.nilable(T::Hash[String, ::Stripe::Checkout::SessionService::CreateParams::ShippingOption::ShippingRateData::FixedAmount::CurrencyOptions]))
}
attr_accessor :currency_options
sig {
params(amount: Integer, currency: String, currency_options: T.nilable(T::Hash[String, ::Stripe::Checkout::SessionService::CreateParams::ShippingOption::ShippingRateData::FixedAmount::CurrencyOptions])).void
}
def initialize(amount: nil, currency: nil, currency_options: nil); end
end
# The estimated range for how long shipping will take, meant to be displayable to the customer. This will appear on CheckoutSessions.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::ShippingOption::ShippingRateData::DeliveryEstimate))
}
attr_accessor :delivery_estimate
# The name of the shipping rate, meant to be displayable to the customer. This will appear on CheckoutSessions.
sig { returns(String) }
attr_accessor :display_name
# Describes a fixed amount to charge for shipping. Must be present if type is `fixed_amount`.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::ShippingOption::ShippingRateData::FixedAmount))
}
attr_accessor :fixed_amount
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID. The Shipping tax code is `txcd_92010001`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_code
# The type of calculation to use on the shipping rate.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(delivery_estimate: T.nilable(::Stripe::Checkout::SessionService::CreateParams::ShippingOption::ShippingRateData::DeliveryEstimate), display_name: String, fixed_amount: T.nilable(::Stripe::Checkout::SessionService::CreateParams::ShippingOption::ShippingRateData::FixedAmount), metadata: T.nilable(T::Hash[String, String]), tax_behavior: T.nilable(String), tax_code: T.nilable(String), type: T.nilable(String)).void
}
def initialize(
delivery_estimate: nil,
display_name: nil,
fixed_amount: nil,
metadata: nil,
tax_behavior: nil,
tax_code: nil,
type: nil
); end
end
# The ID of the Shipping Rate to use for this shipping option.
sig { returns(T.nilable(String)) }
attr_accessor :shipping_rate
# Parameters to be passed to Shipping Rate creation for this shipping option.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::ShippingOption::ShippingRateData))
}
attr_accessor :shipping_rate_data
sig {
params(shipping_rate: T.nilable(String), shipping_rate_data: T.nilable(::Stripe::Checkout::SessionService::CreateParams::ShippingOption::ShippingRateData)).void
}
def initialize(shipping_rate: nil, shipping_rate_data: nil); end
end
class SubscriptionData < Stripe::RequestParams
class InvoiceSettings < Stripe::RequestParams
class Issuer < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::SubscriptionData::InvoiceSettings::Issuer))
}
attr_accessor :issuer
sig {
params(issuer: T.nilable(::Stripe::Checkout::SessionService::CreateParams::SubscriptionData::InvoiceSettings::Issuer)).void
}
def initialize(issuer: nil); end
end
class TransferData < Stripe::RequestParams
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
sig { returns(T.nilable(Float)) }
attr_accessor :amount_percent
# ID of an existing, connected Stripe account.
sig { returns(String) }
attr_accessor :destination
sig { params(amount_percent: T.nilable(Float), destination: String).void }
def initialize(amount_percent: nil, destination: nil); end
end
class TrialSettings < Stripe::RequestParams
class EndBehavior < Stripe::RequestParams
# Indicates how the subscription should change when the trial ends if the user did not provide a payment method.
sig { returns(String) }
attr_accessor :missing_payment_method
sig { params(missing_payment_method: String).void }
def initialize(missing_payment_method: nil); end
end
# Defines how the subscription should behave when the user's free trial ends.
sig {
returns(::Stripe::Checkout::SessionService::CreateParams::SubscriptionData::TrialSettings::EndBehavior)
}
attr_accessor :end_behavior
sig {
params(end_behavior: ::Stripe::Checkout::SessionService::CreateParams::SubscriptionData::TrialSettings::EndBehavior).void
}
def initialize(end_behavior: nil); end
end
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. To use an application fee percent, the request must be made on behalf of another account, using the `Stripe-Account` header or an OAuth key. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).
sig { returns(T.nilable(Float)) }
attr_accessor :application_fee_percent
# A future timestamp to anchor the subscription's billing cycle for new subscriptions.
sig { returns(T.nilable(Integer)) }
attr_accessor :billing_cycle_anchor
# Controls how prorations and invoices for subscriptions are calculated and orchestrated.
sig { returns(T.nilable(String)) }
attr_accessor :billing_mode
# The tax rates that will apply to any subscription item that does not have
# `tax_rates` set. Invoices created will have their `default_tax_rates` populated
# from the subscription.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :default_tax_rates
# The subscription's description, meant to be displayable to the customer.
# Use this field to optionally store an explanation of the subscription
# for rendering in the [customer portal](https://stripe.com/docs/customer-management).
sig { returns(T.nilable(String)) }
attr_accessor :description
# All invoices will be billed using the specified settings.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::SubscriptionData::InvoiceSettings))
}
attr_accessor :invoice_settings
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The account on behalf of which to charge, for each of the subscription's invoices.
sig { returns(T.nilable(String)) }
attr_accessor :on_behalf_of
# Determines how to handle prorations resulting from the `billing_cycle_anchor`. If no value is passed, the default is `create_prorations`.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
# If specified, the funds from the subscription's invoices will be transferred to the destination and the ID of the resulting transfers will be found on the resulting charges.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::SubscriptionData::TransferData))
}
attr_accessor :transfer_data
# Unix timestamp representing the end of the trial period the customer
# will get before being charged for the first time. Has to be at least
# 48 hours in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :trial_end
# Integer representing the number of trial period days before the
# customer is charged for the first time. Has to be at least 1.
sig { returns(T.nilable(Integer)) }
attr_accessor :trial_period_days
# Settings related to subscription trials.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::SubscriptionData::TrialSettings))
}
attr_accessor :trial_settings
sig {
params(application_fee_percent: T.nilable(Float), billing_cycle_anchor: T.nilable(Integer), billing_mode: T.nilable(String), default_tax_rates: T.nilable(T::Array[String]), description: T.nilable(String), invoice_settings: T.nilable(::Stripe::Checkout::SessionService::CreateParams::SubscriptionData::InvoiceSettings), metadata: T.nilable(T::Hash[String, String]), on_behalf_of: T.nilable(String), proration_behavior: T.nilable(String), transfer_data: T.nilable(::Stripe::Checkout::SessionService::CreateParams::SubscriptionData::TransferData), trial_end: T.nilable(Integer), trial_period_days: T.nilable(Integer), trial_settings: T.nilable(::Stripe::Checkout::SessionService::CreateParams::SubscriptionData::TrialSettings)).void
}
def initialize(
application_fee_percent: nil,
billing_cycle_anchor: nil,
billing_mode: nil,
default_tax_rates: nil,
description: nil,
invoice_settings: nil,
metadata: nil,
on_behalf_of: nil,
proration_behavior: nil,
transfer_data: nil,
trial_end: nil,
trial_period_days: nil,
trial_settings: nil
); end
end
class TaxIdCollection < Stripe::RequestParams
# Enable tax ID collection during checkout. Defaults to `false`.
sig { returns(T::Boolean) }
attr_accessor :enabled
# Describes whether a tax ID is required during checkout. Defaults to `never`.
sig { returns(T.nilable(String)) }
attr_accessor :required
sig { params(enabled: T::Boolean, required: T.nilable(String)).void }
def initialize(enabled: nil, required: nil); end
end
class WalletOptions < Stripe::RequestParams
class Link < Stripe::RequestParams
# Specifies whether Checkout should display Link as a payment option. By default, Checkout will display all the supported wallets that the Checkout Session was created with. This is the `auto` behavior, and it is the default choice.
sig { returns(T.nilable(String)) }
attr_accessor :display
sig { params(display: T.nilable(String)).void }
def initialize(display: nil); end
end
# contains details about the Link wallet options.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::WalletOptions::Link))
}
attr_accessor :link
sig {
params(link: T.nilable(::Stripe::Checkout::SessionService::CreateParams::WalletOptions::Link)).void
}
def initialize(link: nil); end
end
# Settings for price localization with [Adaptive Pricing](https://docs.stripe.com/payments/checkout/adaptive-pricing).
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::AdaptivePricing))
}
attr_accessor :adaptive_pricing
# Configure actions after a Checkout Session has expired.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::AfterExpiration))
}
attr_accessor :after_expiration
# Enables user redeemable promotion codes.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :allow_promotion_codes
# Settings for automatic tax lookup for this session and resulting payments, invoices, and subscriptions.
sig { returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::AutomaticTax)) }
attr_accessor :automatic_tax
# Specify whether Checkout should collect the customer's billing address. Defaults to `auto`.
sig { returns(T.nilable(String)) }
attr_accessor :billing_address_collection
# If set, Checkout displays a back button and customers will be directed to this URL if they decide to cancel payment and return to your website. This parameter is not allowed if ui_mode is `embedded` or `custom`.
sig { returns(T.nilable(String)) }
attr_accessor :cancel_url
# A unique string to reference the Checkout Session. This can be a
# customer ID, a cart ID, or similar, and can be used to reconcile the
# session with your internal systems.
sig { returns(T.nilable(String)) }
attr_accessor :client_reference_id
# Configure fields for the Checkout Session to gather active consent from customers.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::ConsentCollection))
}
attr_accessor :consent_collection
# 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). Required in `setup` mode when `payment_method_types` is not set.
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Collect additional information from your customer using custom fields. Up to 3 fields are supported.
sig {
returns(T.nilable(T::Array[::Stripe::Checkout::SessionService::CreateParams::CustomField]))
}
attr_accessor :custom_fields
# Display additional text for your customers using custom text.
sig { returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::CustomText)) }
attr_accessor :custom_text
# ID of an existing Customer, if one exists. In `payment` mode, the customer’s most recently saved card
# payment method will be used to prefill the email, name, card details, and billing address
# on the Checkout page. In `subscription` mode, the customer’s [default payment method](https://stripe.com/docs/api/customers/update#update_customer-invoice_settings-default_payment_method)
# will be used if it’s a card, otherwise the most recently saved card will be used. A valid billing address, billing name and billing email are required on the payment method for Checkout to prefill the customer's card details.
#
# If the Customer already has a valid [email](https://stripe.com/docs/api/customers/object#customer_object-email) set, the email will be prefilled and not editable in Checkout.
# If the Customer does not have a valid `email`, Checkout will set the email entered during the session on the Customer.
#
# If blank for Checkout Sessions in `subscription` mode or with `customer_creation` set as `always` in `payment` mode, Checkout will create a new Customer object based on information provided during the payment flow.
#
# You can set [`payment_intent_data.setup_future_usage`](https://stripe.com/docs/api/checkout/sessions/create#create_checkout_session-payment_intent_data-setup_future_usage) to have Checkout automatically attach the payment method to the Customer you pass in for future reuse.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# ID of an existing Account, if one exists. Has the same behavior as `customer`.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# Configure whether a Checkout Session creates a [Customer](https://stripe.com/docs/api/customers) during Session confirmation.
#
# When a Customer is not created, you can still retrieve email, address, and other customer data entered in Checkout
# with [customer_details](https://stripe.com/docs/api/checkout/sessions/object#checkout_session_object-customer_details).
#
# Sessions that don't create Customers instead are grouped by [guest customers](https://stripe.com/docs/payments/checkout/guest-customers)
# in the Dashboard. Promotion codes limited to first time customers will return invalid for these Sessions.
#
# Can only be set in `payment` and `setup` mode.
sig { returns(T.nilable(String)) }
attr_accessor :customer_creation
# If provided, this value will be used when the Customer object is created.
# If not provided, customers will be asked to enter their email address.
# Use this parameter to prefill customer data if you already have an email
# on file. To access information about the customer once a session is
# complete, use the `customer` field.
sig { returns(T.nilable(String)) }
attr_accessor :customer_email
# Controls what fields on Customer can be updated by the Checkout Session. Can only be provided when `customer` is provided.
sig { returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::CustomerUpdate)) }
attr_accessor :customer_update
# The coupon or promotion code to apply to this Session. Currently, only up to one may be specified.
sig {
returns(T.nilable(T::Array[::Stripe::Checkout::SessionService::CreateParams::Discount]))
}
attr_accessor :discounts
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The Epoch time in seconds at which the Checkout Session will expire. It can be anywhere from 30 minutes to 24 hours after Checkout Session creation. By default, this value is 24 hours from creation.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_at
# Generate a post-purchase Invoice for one-time payments.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::InvoiceCreation))
}
attr_accessor :invoice_creation
# A list of items the customer is purchasing. Use this parameter to pass one-time or recurring [Prices](https://stripe.com/docs/api/prices).
#
# For `payment` mode, there is a maximum of 100 line items, however it is recommended to consolidate line items if there are more than a few dozen.
#
# For `subscription` mode, there is a maximum of 20 line items with recurring Prices and 20 line items with one-time Prices. Line items with one-time Prices will be on the initial invoice only.
sig {
returns(T.nilable(T::Array[::Stripe::Checkout::SessionService::CreateParams::LineItem]))
}
attr_accessor :line_items
# The IETF language tag of the locale Checkout is displayed in. If blank or `auto`, the browser's locale is used.
sig { returns(T.nilable(String)) }
attr_accessor :locale
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The mode of the Checkout Session. Pass `subscription` if the Checkout Session includes at least one recurring item.
sig { returns(T.nilable(String)) }
attr_accessor :mode
# A list of optional items the customer can add to their order at checkout. Use this parameter to pass one-time or recurring [Prices](https://stripe.com/docs/api/prices).
#
# There is a maximum of 10 optional items allowed on a Checkout Session, and the existing limits on the number of line items allowed on a Checkout Session apply to the combined number of line items and optional items.
#
# For `payment` mode, there is a maximum of 100 combined line items and optional items, however it is recommended to consolidate items if there are more than a few dozen.
#
# For `subscription` mode, there is a maximum of 20 line items and optional items with recurring Prices and 20 line items and optional items with one-time Prices.
sig {
returns(T.nilable(T::Array[::Stripe::Checkout::SessionService::CreateParams::OptionalItem]))
}
attr_accessor :optional_items
# A subset of parameters to be passed to PaymentIntent creation for Checkout Sessions in `payment` mode.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentIntentData))
}
attr_accessor :payment_intent_data
# Specify whether Checkout should collect a payment method. When set to `if_required`, Checkout will not collect a payment method when the total due for the session is 0.
# This may occur if the Checkout Session includes a free trial or a discount.
#
# Can only be set in `subscription` mode. Defaults to `always`.
#
# If you'd like information on how to collect a payment method outside of Checkout, read the guide on configuring [subscriptions with a free trial](https://stripe.com/docs/payments/checkout/free-trials).
sig { returns(T.nilable(String)) }
attr_accessor :payment_method_collection
# The ID of the payment method configuration to use with this Checkout session.
sig { returns(T.nilable(String)) }
attr_accessor :payment_method_configuration
# This parameter allows you to set some attributes on the payment method created during a Checkout session.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodData))
}
attr_accessor :payment_method_data
# Payment-method-specific configuration.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions))
}
attr_accessor :payment_method_options
# A list of the types of payment methods (e.g., `card`) this Checkout Session can accept.
#
# You can omit this attribute to manage your payment methods from the [Stripe Dashboard](https://dashboard.stripe.com/settings/payment_methods).
# See [Dynamic Payment Methods](https://stripe.com/docs/payments/payment-methods/integration-options#using-dynamic-payment-methods) for more details.
#
# Read more about the supported payment methods and their requirements in our [payment
# method details guide](/docs/payments/checkout/payment-methods).
#
# If multiple payment methods are passed, Checkout will dynamically reorder them to
# prioritize the most relevant payment methods based on the customer's location and
# other characteristics.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :payment_method_types
# This property is used to set up permissions for various actions (e.g., update) on the CheckoutSession object. Can only be set when creating `embedded` or `custom` sessions.
#
# For specific permissions, please refer to their dedicated subsections, such as `permissions.update_shipping_details`.
sig { returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::Permissions)) }
attr_accessor :permissions
# Controls phone number collection settings for the session.
#
# We recommend that you review your privacy policy and check with your legal contacts
# before using this feature. Learn more about [collecting phone numbers with Checkout](https://stripe.com/docs/payments/checkout/phone-numbers).
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::PhoneNumberCollection))
}
attr_accessor :phone_number_collection
# This parameter applies to `ui_mode: embedded`. Learn more about the [redirect behavior](https://stripe.com/docs/payments/checkout/custom-success-page?payment-ui=embedded-form) of embedded sessions. Defaults to `always`.
sig { returns(T.nilable(String)) }
attr_accessor :redirect_on_completion
# The URL to redirect your customer back to after they authenticate or cancel their payment on the
# payment method's app or site. This parameter is required if `ui_mode` is `embedded` or `custom`
# and redirect-based payment methods are enabled on the session.
sig { returns(T.nilable(String)) }
attr_accessor :return_url
# Controls saved payment method settings for the session. Only available in `payment` and `subscription` mode.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::SavedPaymentMethodOptions))
}
attr_accessor :saved_payment_method_options
# A subset of parameters to be passed to SetupIntent creation for Checkout Sessions in `setup` mode.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::SetupIntentData))
}
attr_accessor :setup_intent_data
# When set, provides configuration for Checkout to collect a shipping address from a customer.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::ShippingAddressCollection))
}
attr_accessor :shipping_address_collection
# The shipping rate options to apply to this Session. Up to a maximum of 5.
sig {
returns(T.nilable(T::Array[::Stripe::Checkout::SessionService::CreateParams::ShippingOption]))
}
attr_accessor :shipping_options
# Describes the type of transaction being performed by Checkout in order
# to customize relevant text on the page, such as the submit button.
# `submit_type` can only be specified on Checkout Sessions in
# `payment` or `subscription` mode. If blank or `auto`, `pay` is used.
sig { returns(T.nilable(String)) }
attr_accessor :submit_type
# A subset of parameters to be passed to subscription creation for Checkout Sessions in `subscription` mode.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::SubscriptionData))
}
attr_accessor :subscription_data
# The URL to which Stripe should send customers when payment or setup
# is complete.
# This parameter is not allowed if ui_mode is `embedded` or `custom`. If you'd like to use
# information from the successful Checkout Session on your page, read the
# guide on [customizing your success page](https://stripe.com/docs/payments/checkout/custom-success-page).
sig { returns(T.nilable(String)) }
attr_accessor :success_url
# Controls tax ID collection during checkout.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::TaxIdCollection))
}
attr_accessor :tax_id_collection
# The UI mode of the Session. Defaults to `hosted`.
sig { returns(T.nilable(String)) }
attr_accessor :ui_mode
# Wallet-specific configuration.
sig { returns(T.nilable(::Stripe::Checkout::SessionService::CreateParams::WalletOptions)) }
attr_accessor :wallet_options
sig {
params(adaptive_pricing: T.nilable(::Stripe::Checkout::SessionService::CreateParams::AdaptivePricing), after_expiration: T.nilable(::Stripe::Checkout::SessionService::CreateParams::AfterExpiration), allow_promotion_codes: T.nilable(T::Boolean), automatic_tax: T.nilable(::Stripe::Checkout::SessionService::CreateParams::AutomaticTax), billing_address_collection: T.nilable(String), cancel_url: T.nilable(String), client_reference_id: T.nilable(String), consent_collection: T.nilable(::Stripe::Checkout::SessionService::CreateParams::ConsentCollection), currency: T.nilable(String), custom_fields: T.nilable(T::Array[::Stripe::Checkout::SessionService::CreateParams::CustomField]), custom_text: T.nilable(::Stripe::Checkout::SessionService::CreateParams::CustomText), customer: T.nilable(String), customer_account: T.nilable(String), customer_creation: T.nilable(String), customer_email: T.nilable(String), customer_update: T.nilable(::Stripe::Checkout::SessionService::CreateParams::CustomerUpdate), discounts: T.nilable(T::Array[::Stripe::Checkout::SessionService::CreateParams::Discount]), expand: T.nilable(T::Array[String]), expires_at: T.nilable(Integer), invoice_creation: T.nilable(::Stripe::Checkout::SessionService::CreateParams::InvoiceCreation), line_items: T.nilable(T::Array[::Stripe::Checkout::SessionService::CreateParams::LineItem]), locale: T.nilable(String), metadata: T.nilable(T::Hash[String, String]), mode: T.nilable(String), optional_items: T.nilable(T::Array[::Stripe::Checkout::SessionService::CreateParams::OptionalItem]), payment_intent_data: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentIntentData), payment_method_collection: T.nilable(String), payment_method_configuration: T.nilable(String), payment_method_data: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodData), payment_method_options: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PaymentMethodOptions), payment_method_types: T.nilable(T::Array[String]), permissions: T.nilable(::Stripe::Checkout::SessionService::CreateParams::Permissions), phone_number_collection: T.nilable(::Stripe::Checkout::SessionService::CreateParams::PhoneNumberCollection), redirect_on_completion: T.nilable(String), return_url: T.nilable(String), saved_payment_method_options: T.nilable(::Stripe::Checkout::SessionService::CreateParams::SavedPaymentMethodOptions), setup_intent_data: T.nilable(::Stripe::Checkout::SessionService::CreateParams::SetupIntentData), shipping_address_collection: T.nilable(::Stripe::Checkout::SessionService::CreateParams::ShippingAddressCollection), shipping_options: T.nilable(T::Array[::Stripe::Checkout::SessionService::CreateParams::ShippingOption]), submit_type: T.nilable(String), subscription_data: T.nilable(::Stripe::Checkout::SessionService::CreateParams::SubscriptionData), success_url: T.nilable(String), tax_id_collection: T.nilable(::Stripe::Checkout::SessionService::CreateParams::TaxIdCollection), ui_mode: T.nilable(String), wallet_options: T.nilable(::Stripe::Checkout::SessionService::CreateParams::WalletOptions)).void
}
def initialize(
adaptive_pricing: nil,
after_expiration: nil,
allow_promotion_codes: nil,
automatic_tax: nil,
billing_address_collection: nil,
cancel_url: nil,
client_reference_id: nil,
consent_collection: nil,
currency: nil,
custom_fields: nil,
custom_text: nil,
customer: nil,
customer_account: nil,
customer_creation: nil,
customer_email: nil,
customer_update: nil,
discounts: nil,
expand: nil,
expires_at: nil,
invoice_creation: nil,
line_items: nil,
locale: nil,
metadata: nil,
mode: nil,
optional_items: nil,
payment_intent_data: nil,
payment_method_collection: nil,
payment_method_configuration: nil,
payment_method_data: nil,
payment_method_options: nil,
payment_method_types: nil,
permissions: nil,
phone_number_collection: nil,
redirect_on_completion: nil,
return_url: nil,
saved_payment_method_options: nil,
setup_intent_data: nil,
shipping_address_collection: nil,
shipping_options: nil,
submit_type: nil,
subscription_data: nil,
success_url: nil,
tax_id_collection: nil,
ui_mode: nil,
wallet_options: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
class CollectedInformation < Stripe::RequestParams
class ShippingDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(String) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(String) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: String, line1: String, line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# The address of the customer
sig {
returns(::Stripe::Checkout::SessionService::UpdateParams::CollectedInformation::ShippingDetails::Address)
}
attr_accessor :address
# The name of customer
sig { returns(String) }
attr_accessor :name
sig {
params(address: ::Stripe::Checkout::SessionService::UpdateParams::CollectedInformation::ShippingDetails::Address, name: String).void
}
def initialize(address: nil, name: nil); end
end
# The shipping details to apply to this Session.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::UpdateParams::CollectedInformation::ShippingDetails))
}
attr_accessor :shipping_details
sig {
params(shipping_details: T.nilable(::Stripe::Checkout::SessionService::UpdateParams::CollectedInformation::ShippingDetails)).void
}
def initialize(shipping_details: nil); end
end
class LineItem < Stripe::RequestParams
class AdjustableQuantity < Stripe::RequestParams
# Set to true if the quantity can be adjusted to any positive integer. Setting to false will remove any previously specified constraints on quantity.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The maximum quantity the customer can purchase for the Checkout Session. By default this value is 99. You can specify a value up to 999999.
sig { returns(T.nilable(Integer)) }
attr_accessor :maximum
# The minimum quantity the customer must purchase for the Checkout Session. By default this value is 0.
sig { returns(T.nilable(Integer)) }
attr_accessor :minimum
sig {
params(enabled: T::Boolean, maximum: T.nilable(Integer), minimum: T.nilable(Integer)).void
}
def initialize(enabled: nil, maximum: nil, minimum: nil); end
end
class PriceData < Stripe::RequestParams
class ProductData < Stripe::RequestParams
# The product's description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes.
sig { returns(T.nilable(String)) }
attr_accessor :description
# A list of up to 8 URLs of images for this product, meant to be displayable to the customer.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :images
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The product's name, meant to be displayable to the customer.
sig { returns(String) }
attr_accessor :name
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
sig { returns(T.nilable(String)) }
attr_accessor :tax_code
sig {
params(description: T.nilable(String), images: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), name: String, tax_code: T.nilable(String)).void
}
def initialize(
description: nil,
images: nil,
metadata: nil,
name: nil,
tax_code: nil
); end
end
class Recurring < Stripe::RequestParams
# Specifies billing frequency. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: T.nilable(Integer)).void }
def initialize(interval: nil, interval_count: nil); end
end
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to. One of `product` or `product_data` is required.
sig { returns(T.nilable(String)) }
attr_accessor :product
# Data used to generate a new [Product](https://docs.stripe.com/api/products) object inline. One of `product` or `product_data` is required.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::UpdateParams::LineItem::PriceData::ProductData))
}
attr_accessor :product_data
# The recurring components of a price such as `interval` and `interval_count`.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::UpdateParams::LineItem::PriceData::Recurring))
}
attr_accessor :recurring
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A non-negative integer in cents (or local equivalent) representing how much to charge. One of `unit_amount` or `unit_amount_decimal` is required.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, product: T.nilable(String), product_data: T.nilable(::Stripe::Checkout::SessionService::UpdateParams::LineItem::PriceData::ProductData), recurring: T.nilable(::Stripe::Checkout::SessionService::UpdateParams::LineItem::PriceData::Recurring), tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
product_data: nil,
recurring: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
# When set, provides configuration for this item’s quantity to be adjusted by the customer during Checkout.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::UpdateParams::LineItem::AdjustableQuantity))
}
attr_accessor :adjustable_quantity
# ID of an existing line item.
sig { returns(T.nilable(String)) }
attr_accessor :id
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# The ID of the [Price](https://stripe.com/docs/api/prices). One of `price` or `price_data` is required when creating a new line item.
sig { returns(T.nilable(String)) }
attr_accessor :price
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required when creating a new line item.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::UpdateParams::LineItem::PriceData))
}
attr_accessor :price_data
# The quantity of the line item being purchased. Quantity should not be defined when `recurring.usage_type=metered`.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# The [tax rates](https://stripe.com/docs/api/tax_rates) which apply to this line item.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
sig {
params(adjustable_quantity: T.nilable(::Stripe::Checkout::SessionService::UpdateParams::LineItem::AdjustableQuantity), id: T.nilable(String), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), price: T.nilable(String), price_data: T.nilable(::Stripe::Checkout::SessionService::UpdateParams::LineItem::PriceData), quantity: T.nilable(Integer), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String])))).void
}
def initialize(
adjustable_quantity: nil,
id: nil,
metadata: nil,
price: nil,
price_data: nil,
quantity: nil,
tax_rates: nil
); end
end
class ShippingOption < Stripe::RequestParams
class ShippingRateData < Stripe::RequestParams
class DeliveryEstimate < Stripe::RequestParams
class Maximum < Stripe::RequestParams
# A unit of time.
sig { returns(String) }
attr_accessor :unit
# Must be greater than 0.
sig { returns(Integer) }
attr_accessor :value
sig { params(unit: String, value: Integer).void }
def initialize(unit: nil, value: nil); end
end
class Minimum < Stripe::RequestParams
# A unit of time.
sig { returns(String) }
attr_accessor :unit
# Must be greater than 0.
sig { returns(Integer) }
attr_accessor :value
sig { params(unit: String, value: Integer).void }
def initialize(unit: nil, value: nil); end
end
# The upper bound of the estimated range. If empty, represents no upper bound i.e., infinite.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::UpdateParams::ShippingOption::ShippingRateData::DeliveryEstimate::Maximum))
}
attr_accessor :maximum
# The lower bound of the estimated range. If empty, represents no lower bound.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::UpdateParams::ShippingOption::ShippingRateData::DeliveryEstimate::Minimum))
}
attr_accessor :minimum
sig {
params(maximum: T.nilable(::Stripe::Checkout::SessionService::UpdateParams::ShippingOption::ShippingRateData::DeliveryEstimate::Maximum), minimum: T.nilable(::Stripe::Checkout::SessionService::UpdateParams::ShippingOption::ShippingRateData::DeliveryEstimate::Minimum)).void
}
def initialize(maximum: nil, minimum: nil); end
end
class FixedAmount < Stripe::RequestParams
class CurrencyOptions < Stripe::RequestParams
# A non-negative integer in cents representing how much to charge.
sig { returns(Integer) }
attr_accessor :amount
# Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
sig { params(amount: Integer, tax_behavior: T.nilable(String)).void }
def initialize(amount: nil, tax_behavior: nil); end
end
# A non-negative integer in cents representing how much to charge.
sig { returns(Integer) }
attr_accessor :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).
sig { returns(String) }
attr_accessor :currency
# Shipping rates defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
sig {
returns(T.nilable(T::Hash[String, ::Stripe::Checkout::SessionService::UpdateParams::ShippingOption::ShippingRateData::FixedAmount::CurrencyOptions]))
}
attr_accessor :currency_options
sig {
params(amount: Integer, currency: String, currency_options: T.nilable(T::Hash[String, ::Stripe::Checkout::SessionService::UpdateParams::ShippingOption::ShippingRateData::FixedAmount::CurrencyOptions])).void
}
def initialize(amount: nil, currency: nil, currency_options: nil); end
end
# The estimated range for how long shipping will take, meant to be displayable to the customer. This will appear on CheckoutSessions.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::UpdateParams::ShippingOption::ShippingRateData::DeliveryEstimate))
}
attr_accessor :delivery_estimate
# The name of the shipping rate, meant to be displayable to the customer. This will appear on CheckoutSessions.
sig { returns(String) }
attr_accessor :display_name
# Describes a fixed amount to charge for shipping. Must be present if type is `fixed_amount`.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::UpdateParams::ShippingOption::ShippingRateData::FixedAmount))
}
attr_accessor :fixed_amount
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID. The Shipping tax code is `txcd_92010001`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_code
# The type of calculation to use on the shipping rate.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(delivery_estimate: T.nilable(::Stripe::Checkout::SessionService::UpdateParams::ShippingOption::ShippingRateData::DeliveryEstimate), display_name: String, fixed_amount: T.nilable(::Stripe::Checkout::SessionService::UpdateParams::ShippingOption::ShippingRateData::FixedAmount), metadata: T.nilable(T::Hash[String, String]), tax_behavior: T.nilable(String), tax_code: T.nilable(String), type: T.nilable(String)).void
}
def initialize(
delivery_estimate: nil,
display_name: nil,
fixed_amount: nil,
metadata: nil,
tax_behavior: nil,
tax_code: nil,
type: nil
); end
end
# The ID of the Shipping Rate to use for this shipping option.
sig { returns(T.nilable(String)) }
attr_accessor :shipping_rate
# Parameters to be passed to Shipping Rate creation for this shipping option.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::UpdateParams::ShippingOption::ShippingRateData))
}
attr_accessor :shipping_rate_data
sig {
params(shipping_rate: T.nilable(String), shipping_rate_data: T.nilable(::Stripe::Checkout::SessionService::UpdateParams::ShippingOption::ShippingRateData)).void
}
def initialize(shipping_rate: nil, shipping_rate_data: nil); end
end
# Information about the customer collected within the Checkout Session. Can only be set when updating `embedded` or `custom` sessions.
sig {
returns(T.nilable(::Stripe::Checkout::SessionService::UpdateParams::CollectedInformation))
}
attr_accessor :collected_information
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A list of items the customer is purchasing.
#
# When updating line items, you must retransmit the entire array of line items.
#
# To retain an existing line item, specify its `id`.
#
# To update an existing line item, specify its `id` along with the new values of the fields to update.
#
# To add a new line item, specify one of `price` or `price_data` and `quantity`.
#
# To remove an existing line item, omit the line item's ID from the retransmitted array.
#
# To reorder a line item, specify it at the desired position in the retransmitted array.
sig {
returns(T.nilable(T::Array[::Stripe::Checkout::SessionService::UpdateParams::LineItem]))
}
attr_accessor :line_items
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# The shipping rate options to apply to this Session. Up to a maximum of 5.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Checkout::SessionService::UpdateParams::ShippingOption]))))
}
attr_accessor :shipping_options
sig {
params(collected_information: T.nilable(::Stripe::Checkout::SessionService::UpdateParams::CollectedInformation), expand: T.nilable(T::Array[String]), line_items: T.nilable(T::Array[::Stripe::Checkout::SessionService::UpdateParams::LineItem]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), shipping_options: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::Checkout::SessionService::UpdateParams::ShippingOption])))).void
}
def initialize(
collected_information: nil,
expand: nil,
line_items: nil,
metadata: nil,
shipping_options: nil
); end
end
class ExpireParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Creates a Checkout Session object.
sig {
params(params: T.any(::Stripe::Checkout::SessionService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Checkout::Session)
}
def create(params = {}, opts = {}); end
# A Checkout Session can be expired when it is in one of these statuses: open
#
# After it expires, a customer can't complete a Checkout Session and customers loading the Checkout Session see a message saying the Checkout Session is expired.
sig {
params(session: String, params: T.any(::Stripe::Checkout::SessionService::ExpireParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Checkout::Session)
}
def expire(session, params = {}, opts = {}); end
# Returns a list of Checkout Sessions.
sig {
params(params: T.any(::Stripe::Checkout::SessionService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves a Checkout Session object.
sig {
params(session: String, params: T.any(::Stripe::Checkout::SessionService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Checkout::Session)
}
def retrieve(session, params = {}, opts = {}); end
# Updates a Checkout Session object.
#
# Related guide: [Dynamically update Checkout](https://docs.stripe.com/payments/checkout/dynamic-updates)
sig {
params(session: String, params: T.any(::Stripe::Checkout::SessionService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Checkout::Session)
}
def update(session, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Checkout
class SessionLineItemService < StripeService
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
# When retrieving a Checkout Session, there is an includable line_items property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items.
sig {
params(session: String, params: T.any(::Stripe::Checkout::SessionLineItemService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(session, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
class ClimateService < StripeService
attr_reader :orders
attr_reader :products
attr_reader :suppliers
end
end
# typed: true
module Stripe
module Climate
class OrderService < StripeService
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
class CreateParams < Stripe::RequestParams
class Beneficiary < Stripe::RequestParams
# Publicly displayable name for the end beneficiary of carbon removal.
sig { returns(String) }
attr_accessor :public_name
sig { params(public_name: String).void }
def initialize(public_name: nil); end
end
# Requested amount of carbon removal units. Either this or `metric_tons` must be specified.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# Publicly sharable reference for the end beneficiary of carbon removal. Assumed to be the Stripe account if not set.
sig { returns(T.nilable(::Stripe::Climate::OrderService::CreateParams::Beneficiary)) }
attr_accessor :beneficiary
# Request currency for the order as a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a supported [settlement currency for your account](https://stripe.com/docs/currencies). If omitted, the account's default currency will be used.
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Requested number of tons for the order. Either this or `amount` must be specified.
sig { returns(T.nilable(String)) }
attr_accessor :metric_tons
# Unique identifier of the Climate product.
sig { returns(String) }
attr_accessor :product
sig {
params(amount: T.nilable(Integer), beneficiary: T.nilable(::Stripe::Climate::OrderService::CreateParams::Beneficiary), currency: T.nilable(String), expand: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), metric_tons: T.nilable(String), product: String).void
}
def initialize(
amount: nil,
beneficiary: nil,
currency: nil,
expand: nil,
metadata: nil,
metric_tons: nil,
product: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
class Beneficiary < Stripe::RequestParams
# Publicly displayable name for the end beneficiary of carbon removal.
sig { returns(T.nilable(String)) }
attr_accessor :public_name
sig { params(public_name: T.nilable(String)).void }
def initialize(public_name: nil); end
end
# Publicly sharable reference for the end beneficiary of carbon removal. Assumed to be the Stripe account if not set.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Climate::OrderService::UpdateParams::Beneficiary))))
}
attr_accessor :beneficiary
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
sig {
params(beneficiary: T.nilable(T.nilable(T.any(String, ::Stripe::Climate::OrderService::UpdateParams::Beneficiary))), expand: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String])).void
}
def initialize(beneficiary: nil, expand: nil, metadata: nil); end
end
class CancelParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Cancels a Climate order. You can cancel an order within 24 hours of creation. Stripe refunds the
# reservation amount_subtotal, but not the amount_fees for user-triggered cancellations. Frontier
# might cancel reservations if suppliers fail to deliver. If Frontier cancels the reservation, Stripe
# provides 90 days advance notice and refunds the amount_total.
sig {
params(order: String, params: T.any(::Stripe::Climate::OrderService::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Climate::Order)
}
def cancel(order, params = {}, opts = {}); end
# Creates a Climate order object for a given Climate product. The order will be processed immediately
# after creation and payment will be deducted your Stripe balance.
sig {
params(params: T.any(::Stripe::Climate::OrderService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Climate::Order)
}
def create(params = {}, opts = {}); end
# Lists all Climate order objects. The orders are returned sorted by creation date, with the
# most recently created orders appearing first.
sig {
params(params: T.any(::Stripe::Climate::OrderService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the details of a Climate order object with the given ID.
sig {
params(order: String, params: T.any(::Stripe::Climate::OrderService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Climate::Order)
}
def retrieve(order, params = {}, opts = {}); end
# Updates the specified order by setting the values of the parameters passed.
sig {
params(order: String, params: T.any(::Stripe::Climate::OrderService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Climate::Order)
}
def update(order, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Climate
class ProductService < StripeService
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Lists all available Climate product objects.
sig {
params(params: T.any(::Stripe::Climate::ProductService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the details of a Climate product with the given ID.
sig {
params(product: String, params: T.any(::Stripe::Climate::ProductService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Climate::Product)
}
def retrieve(product, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Climate
class SupplierService < StripeService
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Lists all available Climate supplier objects.
sig {
params(params: T.any(::Stripe::Climate::SupplierService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves a Climate supplier object.
sig {
params(supplier: String, params: T.any(::Stripe::Climate::SupplierService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Climate::Supplier)
}
def retrieve(supplier, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
class ConfirmationTokenService < StripeService
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Retrieves an existing ConfirmationToken object
sig {
params(confirmation_token: String, params: T.any(::Stripe::ConfirmationTokenService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ConfirmationToken)
}
def retrieve(confirmation_token, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class TestHelpersService < StripeService
attr_reader :confirmation_tokens
attr_reader :customers
attr_reader :issuing
attr_reader :refunds
attr_reader :terminal
attr_reader :test_clocks
attr_reader :treasury
end
end
# typed: true
module Stripe
module TestHelpers
class ConfirmationTokenService < StripeService
class CreateParams < Stripe::RequestParams
class PaymentMethodData < Stripe::RequestParams
class AcssDebit < Stripe::RequestParams
# Customer's bank account number.
sig { returns(String) }
attr_accessor :account_number
# Institution number of the customer's bank.
sig { returns(String) }
attr_accessor :institution_number
# Transit number of the customer's bank.
sig { returns(String) }
attr_accessor :transit_number
sig {
params(account_number: String, institution_number: String, transit_number: String).void
}
def initialize(account_number: nil, institution_number: nil, transit_number: nil); end
end
class Affirm < Stripe::RequestParams; end
class AfterpayClearpay < Stripe::RequestParams; end
class Alipay < Stripe::RequestParams; end
class Alma < Stripe::RequestParams; end
class AmazonPay < Stripe::RequestParams; end
class AuBecsDebit < Stripe::RequestParams
# The account number for the bank account.
sig { returns(String) }
attr_accessor :account_number
# Bank-State-Branch number of the bank account.
sig { returns(String) }
attr_accessor :bsb_number
sig { params(account_number: String, bsb_number: String).void }
def initialize(account_number: nil, bsb_number: nil); end
end
class BacsDebit < Stripe::RequestParams
# Account number of the bank account that the funds will be debited from.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Sort code of the bank account. (e.g., `10-20-30`)
sig { returns(T.nilable(String)) }
attr_accessor :sort_code
sig { params(account_number: T.nilable(String), sort_code: T.nilable(String)).void }
def initialize(account_number: nil, sort_code: nil); end
end
class Bancontact < Stripe::RequestParams; end
class Billie < Stripe::RequestParams; end
class BillingDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Billing address.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::BillingDetails::Address))))
}
attr_accessor :address
# Email address.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :email
# Full name.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :name
# Billing phone number (including extension).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :phone
# Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
sig { returns(T.nilable(String)) }
attr_accessor :tax_id
sig {
params(address: T.nilable(T.nilable(T.any(String, ::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::BillingDetails::Address))), email: T.nilable(T.nilable(String)), name: T.nilable(T.nilable(String)), phone: T.nilable(T.nilable(String)), tax_id: T.nilable(String)).void
}
def initialize(address: nil, email: nil, name: nil, phone: nil, tax_id: nil); end
end
class Blik < Stripe::RequestParams; end
class Boleto < Stripe::RequestParams
# The tax ID of the customer (CPF for individual consumers or CNPJ for businesses consumers)
sig { returns(String) }
attr_accessor :tax_id
sig { params(tax_id: String).void }
def initialize(tax_id: nil); end
end
class Cashapp < Stripe::RequestParams; end
class CustomerBalance < Stripe::RequestParams; end
class Eps < Stripe::RequestParams
# The customer's bank.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class Fpx < Stripe::RequestParams
# Account holder type for FPX transaction
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_type
# The customer's bank.
sig { returns(String) }
attr_accessor :bank
sig { params(account_holder_type: T.nilable(String), bank: String).void }
def initialize(account_holder_type: nil, bank: nil); end
end
class Giropay < Stripe::RequestParams; end
class Gopay < Stripe::RequestParams; end
class Grabpay < Stripe::RequestParams; end
class IdBankTransfer < Stripe::RequestParams
# Bank where the account is held.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class Ideal < Stripe::RequestParams
# The customer's bank. Only use this parameter for existing customers. Don't use it for new customers.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class InteracPresent < Stripe::RequestParams; end
class KakaoPay < Stripe::RequestParams; end
class Klarna < Stripe::RequestParams
class Dob < Stripe::RequestParams
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
# Customer's date of birth
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Klarna::Dob))
}
attr_accessor :dob
sig {
params(dob: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Klarna::Dob)).void
}
def initialize(dob: nil); end
end
class Konbini < Stripe::RequestParams; end
class KrCard < Stripe::RequestParams; end
class Link < Stripe::RequestParams; end
class MbWay < Stripe::RequestParams; end
class Mobilepay < Stripe::RequestParams; end
class Multibanco < Stripe::RequestParams; end
class NaverPay < Stripe::RequestParams
# Whether to use Naver Pay points or a card to fund this transaction. If not provided, this defaults to `card`.
sig { returns(T.nilable(String)) }
attr_accessor :funding
sig { params(funding: T.nilable(String)).void }
def initialize(funding: nil); end
end
class NzBankAccount < Stripe::RequestParams
# The name on the bank account. Only required if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod’s billing details.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_name
# The account number for the bank account.
sig { returns(String) }
attr_accessor :account_number
# The numeric code for the bank account's bank.
sig { returns(String) }
attr_accessor :bank_code
# The numeric code for the bank account's bank branch.
sig { returns(String) }
attr_accessor :branch_code
# Attribute for param field reference
sig { returns(T.nilable(String)) }
attr_accessor :reference
# The suffix of the bank account number.
sig { returns(String) }
attr_accessor :suffix
sig {
params(account_holder_name: T.nilable(String), account_number: String, bank_code: String, branch_code: String, reference: T.nilable(String), suffix: String).void
}
def initialize(
account_holder_name: nil,
account_number: nil,
bank_code: nil,
branch_code: nil,
reference: nil,
suffix: nil
); end
end
class Oxxo < Stripe::RequestParams; end
class P24 < Stripe::RequestParams
# The customer's bank.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class PayByBank < Stripe::RequestParams; end
class Payco < Stripe::RequestParams; end
class Paynow < Stripe::RequestParams; end
class Paypal < Stripe::RequestParams; end
class Payto < Stripe::RequestParams
# The account number for the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Bank-State-Branch number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :bsb_number
# The PayID alias for the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :pay_id
sig {
params(account_number: T.nilable(String), bsb_number: T.nilable(String), pay_id: T.nilable(String)).void
}
def initialize(account_number: nil, bsb_number: nil, pay_id: nil); end
end
class Pix < Stripe::RequestParams; end
class Promptpay < Stripe::RequestParams; end
class Qris < Stripe::RequestParams; end
class RadarOptions < Stripe::RequestParams
# A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
sig { returns(T.nilable(String)) }
attr_accessor :session
sig { params(session: T.nilable(String)).void }
def initialize(session: nil); end
end
class Rechnung < Stripe::RequestParams
class Dob < Stripe::RequestParams
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
# Customer's date of birth
sig {
returns(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Rechnung::Dob)
}
attr_accessor :dob
sig {
params(dob: ::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Rechnung::Dob).void
}
def initialize(dob: nil); end
end
class RevolutPay < Stripe::RequestParams; end
class SamsungPay < Stripe::RequestParams; end
class Satispay < Stripe::RequestParams; end
class SepaDebit < Stripe::RequestParams
# IBAN of the bank account.
sig { returns(String) }
attr_accessor :iban
sig { params(iban: String).void }
def initialize(iban: nil); end
end
class Shopeepay < Stripe::RequestParams; end
class Sofort < Stripe::RequestParams
# Two-letter ISO code representing the country the bank account is located in.
sig { returns(String) }
attr_accessor :country
sig { params(country: String).void }
def initialize(country: nil); end
end
class StripeBalance < Stripe::RequestParams
# The connected account ID whose Stripe balance to use as the source of payment
sig { returns(T.nilable(String)) }
attr_accessor :account
# The [source_type](https://docs.stripe.com/api/balance/balance_object#balance_object-available-source_types) of the balance
sig { returns(T.nilable(String)) }
attr_accessor :source_type
sig { params(account: T.nilable(String), source_type: T.nilable(String)).void }
def initialize(account: nil, source_type: nil); end
end
class Swish < Stripe::RequestParams; end
class Twint < Stripe::RequestParams; end
class UsBankAccount < Stripe::RequestParams
# Account holder type: individual or company.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_type
# Account number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Account type: checkings or savings. Defaults to checking if omitted.
sig { returns(T.nilable(String)) }
attr_accessor :account_type
# The ID of a Financial Connections Account to use as a payment method.
sig { returns(T.nilable(String)) }
attr_accessor :financial_connections_account
# Routing number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :routing_number
sig {
params(account_holder_type: T.nilable(String), account_number: T.nilable(String), account_type: T.nilable(String), financial_connections_account: T.nilable(String), routing_number: T.nilable(String)).void
}
def initialize(
account_holder_type: nil,
account_number: nil,
account_type: nil,
financial_connections_account: nil,
routing_number: nil
); end
end
class WechatPay < Stripe::RequestParams; end
class Zip < Stripe::RequestParams; end
# If this is an `acss_debit` PaymentMethod, this hash contains details about the ACSS Debit payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::AcssDebit))
}
attr_accessor :acss_debit
# If this is an `affirm` PaymentMethod, this hash contains details about the Affirm payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Affirm))
}
attr_accessor :affirm
# If this is an `AfterpayClearpay` PaymentMethod, this hash contains details about the AfterpayClearpay payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::AfterpayClearpay))
}
attr_accessor :afterpay_clearpay
# If this is an `Alipay` PaymentMethod, this hash contains details about the Alipay payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Alipay))
}
attr_accessor :alipay
# This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :allow_redisplay
# If this is a Alma PaymentMethod, this hash contains details about the Alma payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Alma))
}
attr_accessor :alma
# If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::AmazonPay))
}
attr_accessor :amazon_pay
# If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::AuBecsDebit))
}
attr_accessor :au_becs_debit
# If this is a `bacs_debit` PaymentMethod, this hash contains details about the Bacs Direct Debit bank account.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::BacsDebit))
}
attr_accessor :bacs_debit
# If this is a `bancontact` PaymentMethod, this hash contains details about the Bancontact payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Bancontact))
}
attr_accessor :bancontact
# If this is a `billie` PaymentMethod, this hash contains details about the Billie payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Billie))
}
attr_accessor :billie
# Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::BillingDetails))
}
attr_accessor :billing_details
# If this is a `blik` PaymentMethod, this hash contains details about the BLIK payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Blik))
}
attr_accessor :blik
# If this is a `boleto` PaymentMethod, this hash contains details about the Boleto payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Boleto))
}
attr_accessor :boleto
# If this is a `cashapp` PaymentMethod, this hash contains details about the Cash App Pay payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Cashapp))
}
attr_accessor :cashapp
# If this is a `customer_balance` PaymentMethod, this hash contains details about the CustomerBalance payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::CustomerBalance))
}
attr_accessor :customer_balance
# If this is an `eps` PaymentMethod, this hash contains details about the EPS payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Eps))
}
attr_accessor :eps
# If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Fpx))
}
attr_accessor :fpx
# If this is a `giropay` PaymentMethod, this hash contains details about the Giropay payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Giropay))
}
attr_accessor :giropay
# If this is a Gopay PaymentMethod, this hash contains details about the Gopay payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Gopay))
}
attr_accessor :gopay
# If this is a `grabpay` PaymentMethod, this hash contains details about the GrabPay payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Grabpay))
}
attr_accessor :grabpay
# If this is an `IdBankTransfer` PaymentMethod, this hash contains details about the IdBankTransfer payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::IdBankTransfer))
}
attr_accessor :id_bank_transfer
# If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Ideal))
}
attr_accessor :ideal
# If this is an `interac_present` PaymentMethod, this hash contains details about the Interac Present payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::InteracPresent))
}
attr_accessor :interac_present
# If this is a `kakao_pay` PaymentMethod, this hash contains details about the Kakao Pay payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::KakaoPay))
}
attr_accessor :kakao_pay
# If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Klarna))
}
attr_accessor :klarna
# If this is a `konbini` PaymentMethod, this hash contains details about the Konbini payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Konbini))
}
attr_accessor :konbini
# If this is a `kr_card` PaymentMethod, this hash contains details about the Korean Card payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::KrCard))
}
attr_accessor :kr_card
# If this is an `Link` PaymentMethod, this hash contains details about the Link payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Link))
}
attr_accessor :link
# If this is a MB WAY PaymentMethod, this hash contains details about the MB WAY payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::MbWay))
}
attr_accessor :mb_way
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# If this is a `mobilepay` PaymentMethod, this hash contains details about the MobilePay payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Mobilepay))
}
attr_accessor :mobilepay
# If this is a `multibanco` PaymentMethod, this hash contains details about the Multibanco payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Multibanco))
}
attr_accessor :multibanco
# If this is a `naver_pay` PaymentMethod, this hash contains details about the Naver Pay payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::NaverPay))
}
attr_accessor :naver_pay
# If this is an nz_bank_account PaymentMethod, this hash contains details about the nz_bank_account payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::NzBankAccount))
}
attr_accessor :nz_bank_account
# If this is an `oxxo` PaymentMethod, this hash contains details about the OXXO payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Oxxo))
}
attr_accessor :oxxo
# If this is a `p24` PaymentMethod, this hash contains details about the P24 payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::P24))
}
attr_accessor :p24
# If this is a `pay_by_bank` PaymentMethod, this hash contains details about the PayByBank payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::PayByBank))
}
attr_accessor :pay_by_bank
# If this is a `payco` PaymentMethod, this hash contains details about the PAYCO payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Payco))
}
attr_accessor :payco
# If this is a `paynow` PaymentMethod, this hash contains details about the PayNow payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Paynow))
}
attr_accessor :paynow
# If this is a `paypal` PaymentMethod, this hash contains details about the PayPal payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Paypal))
}
attr_accessor :paypal
# If this is a `payto` PaymentMethod, this hash contains details about the PayTo payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Payto))
}
attr_accessor :payto
# If this is a `pix` PaymentMethod, this hash contains details about the Pix payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Pix))
}
attr_accessor :pix
# If this is a `promptpay` PaymentMethod, this hash contains details about the PromptPay payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Promptpay))
}
attr_accessor :promptpay
# If this is a `qris` PaymentMethod, this hash contains details about the QRIS payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Qris))
}
attr_accessor :qris
# Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::RadarOptions))
}
attr_accessor :radar_options
# If this is a `rechnung` PaymentMethod, this hash contains details about the Rechnung payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Rechnung))
}
attr_accessor :rechnung
# If this is a `revolut_pay` PaymentMethod, this hash contains details about the Revolut Pay payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::RevolutPay))
}
attr_accessor :revolut_pay
# If this is a `samsung_pay` PaymentMethod, this hash contains details about the SamsungPay payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::SamsungPay))
}
attr_accessor :samsung_pay
# If this is a `satispay` PaymentMethod, this hash contains details about the Satispay payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Satispay))
}
attr_accessor :satispay
# If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::SepaDebit))
}
attr_accessor :sepa_debit
# If this is a Shopeepay PaymentMethod, this hash contains details about the Shopeepay payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Shopeepay))
}
attr_accessor :shopeepay
# If this is a `sofort` PaymentMethod, this hash contains details about the SOFORT payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Sofort))
}
attr_accessor :sofort
# This hash contains details about the Stripe balance payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::StripeBalance))
}
attr_accessor :stripe_balance
# If this is a `swish` PaymentMethod, this hash contains details about the Swish payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Swish))
}
attr_accessor :swish
# If this is a TWINT PaymentMethod, this hash contains details about the TWINT payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Twint))
}
attr_accessor :twint
# The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
sig { returns(String) }
attr_accessor :type
# If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::UsBankAccount))
}
attr_accessor :us_bank_account
# If this is an `wechat_pay` PaymentMethod, this hash contains details about the wechat_pay payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::WechatPay))
}
attr_accessor :wechat_pay
# If this is a `zip` PaymentMethod, this hash contains details about the Zip payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Zip))
}
attr_accessor :zip
sig {
params(acss_debit: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::AcssDebit), affirm: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Affirm), afterpay_clearpay: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::AfterpayClearpay), alipay: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Alipay), allow_redisplay: T.nilable(String), alma: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Alma), amazon_pay: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::AmazonPay), au_becs_debit: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::AuBecsDebit), bacs_debit: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::BacsDebit), bancontact: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Bancontact), billie: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Billie), billing_details: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::BillingDetails), blik: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Blik), boleto: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Boleto), cashapp: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Cashapp), customer_balance: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::CustomerBalance), eps: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Eps), fpx: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Fpx), giropay: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Giropay), gopay: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Gopay), grabpay: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Grabpay), id_bank_transfer: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::IdBankTransfer), ideal: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Ideal), interac_present: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::InteracPresent), kakao_pay: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::KakaoPay), klarna: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Klarna), konbini: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Konbini), kr_card: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::KrCard), link: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Link), mb_way: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::MbWay), metadata: T.nilable(T::Hash[String, String]), mobilepay: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Mobilepay), multibanco: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Multibanco), naver_pay: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::NaverPay), nz_bank_account: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::NzBankAccount), oxxo: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Oxxo), p24: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::P24), pay_by_bank: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::PayByBank), payco: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Payco), paynow: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Paynow), paypal: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Paypal), payto: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Payto), pix: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Pix), promptpay: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Promptpay), qris: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Qris), radar_options: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::RadarOptions), rechnung: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Rechnung), revolut_pay: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::RevolutPay), samsung_pay: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::SamsungPay), satispay: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Satispay), sepa_debit: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::SepaDebit), shopeepay: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Shopeepay), sofort: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Sofort), stripe_balance: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::StripeBalance), swish: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Swish), twint: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Twint), type: String, us_bank_account: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::UsBankAccount), wechat_pay: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::WechatPay), zip: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData::Zip)).void
}
def initialize(
acss_debit: nil,
affirm: nil,
afterpay_clearpay: nil,
alipay: nil,
allow_redisplay: nil,
alma: nil,
amazon_pay: nil,
au_becs_debit: nil,
bacs_debit: nil,
bancontact: nil,
billie: nil,
billing_details: nil,
blik: nil,
boleto: nil,
cashapp: nil,
customer_balance: nil,
eps: nil,
fpx: nil,
giropay: nil,
gopay: nil,
grabpay: nil,
id_bank_transfer: nil,
ideal: nil,
interac_present: nil,
kakao_pay: nil,
klarna: nil,
konbini: nil,
kr_card: nil,
link: nil,
mb_way: nil,
metadata: nil,
mobilepay: nil,
multibanco: nil,
naver_pay: nil,
nz_bank_account: nil,
oxxo: nil,
p24: nil,
pay_by_bank: nil,
payco: nil,
paynow: nil,
paypal: nil,
payto: nil,
pix: nil,
promptpay: nil,
qris: nil,
radar_options: nil,
rechnung: nil,
revolut_pay: nil,
samsung_pay: nil,
satispay: nil,
sepa_debit: nil,
shopeepay: nil,
sofort: nil,
stripe_balance: nil,
swish: nil,
twint: nil,
type: nil,
us_bank_account: nil,
wechat_pay: nil,
zip: nil
); end
end
class PaymentMethodOptions < Stripe::RequestParams
class Card < Stripe::RequestParams
class Installments < Stripe::RequestParams
class Plan < Stripe::RequestParams
# For `fixed_count` installment plans, this is required. It represents the number of installment payments your customer will make to their credit card.
sig { returns(T.nilable(Integer)) }
attr_accessor :count
# For `fixed_count` installment plans, this is required. It represents the interval between installment payments your customer will make to their credit card.
# One of `month`.
sig { returns(T.nilable(String)) }
attr_accessor :interval
# Type of installment plan, one of `fixed_count`.
sig { returns(String) }
attr_accessor :type
sig {
params(count: T.nilable(Integer), interval: T.nilable(String), type: String).void
}
def initialize(count: nil, interval: nil, type: nil); end
end
# The selected installment plan to use for this payment attempt.
# This parameter can only be provided during confirmation.
sig {
returns(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodOptions::Card::Installments::Plan)
}
attr_accessor :plan
sig {
params(plan: ::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodOptions::Card::Installments::Plan).void
}
def initialize(plan: nil); end
end
# Installment configuration for payments confirmed using this ConfirmationToken.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodOptions::Card::Installments))
}
attr_accessor :installments
sig {
params(installments: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodOptions::Card::Installments)).void
}
def initialize(installments: nil); end
end
# Configuration for any card payments confirmed using this ConfirmationToken.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodOptions::Card))
}
attr_accessor :card
sig {
params(card: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodOptions::Card)).void
}
def initialize(card: nil); end
end
class Shipping < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Shipping address
sig {
returns(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::Shipping::Address)
}
attr_accessor :address
# Recipient name.
sig { returns(String) }
attr_accessor :name
# Recipient phone (including extension)
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :phone
sig {
params(address: ::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::Shipping::Address, name: String, phone: T.nilable(T.nilable(String))).void
}
def initialize(address: nil, name: nil, phone: nil); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# ID of an existing PaymentMethod.
sig { returns(T.nilable(String)) }
attr_accessor :payment_method
# If provided, this hash will be used to create a PaymentMethod.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData))
}
attr_accessor :payment_method_data
# Payment-method-specific configuration for this ConfirmationToken.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodOptions))
}
attr_accessor :payment_method_options
# Return URL used to confirm the Intent.
sig { returns(T.nilable(String)) }
attr_accessor :return_url
# Indicates that you intend to make future payments with this ConfirmationToken's payment method.
#
# The presence of this property will [attach the payment method](https://stripe.com/docs/payments/save-during-payment) to the PaymentIntent's Customer, if present, after the PaymentIntent is confirmed and any required actions from the user are complete.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
# Shipping information for this ConfirmationToken.
sig {
returns(T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::Shipping))
}
attr_accessor :shipping
sig {
params(expand: T.nilable(T::Array[String]), payment_method: T.nilable(String), payment_method_data: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodData), payment_method_options: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::PaymentMethodOptions), return_url: T.nilable(String), setup_future_usage: T.nilable(String), shipping: T.nilable(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams::Shipping)).void
}
def initialize(
expand: nil,
payment_method: nil,
payment_method_data: nil,
payment_method_options: nil,
return_url: nil,
setup_future_usage: nil,
shipping: nil
); end
end
# Creates a test mode Confirmation Token server side for your integration tests.
sig {
params(params: T.any(::Stripe::TestHelpers::ConfirmationTokenService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ConfirmationToken)
}
def create(params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module TestHelpers
class CustomerService < StripeService
class FundCashBalanceParams < Stripe::RequestParams
# Amount to be used for this test cash balance transaction. A positive integer representing how much to fund in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to fund $1.00 or 100 to fund ¥100, a zero-decimal currency).
sig { returns(Integer) }
attr_accessor :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).
sig { returns(String) }
attr_accessor :currency
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A description of the test funding. This simulates free-text references supplied by customers when making bank transfers to their cash balance. You can use this to test how Stripe's [reconciliation algorithm](https://stripe.com/docs/payments/customer-balance/reconciliation) applies to different user inputs.
sig { returns(T.nilable(String)) }
attr_accessor :reference
sig {
params(amount: Integer, currency: String, expand: T.nilable(T::Array[String]), reference: T.nilable(String)).void
}
def initialize(amount: nil, currency: nil, expand: nil, reference: nil); end
end
# Create an incoming testmode bank transfer
sig {
params(customer: String, params: T.any(::Stripe::TestHelpers::CustomerService::FundCashBalanceParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::CustomerCashBalanceTransaction)
}
def fund_cash_balance(customer, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module TestHelpers
class IssuingService < StripeService
attr_reader :authorizations
attr_reader :cards
attr_reader :personalization_designs
attr_reader :transactions
end
end
end
# typed: true
module Stripe
module TestHelpers
module Issuing
class AuthorizationService < StripeService
class CreateParams < Stripe::RequestParams
class AmountDetails < Stripe::RequestParams
# The ATM withdrawal fee.
sig { returns(T.nilable(Integer)) }
attr_accessor :atm_fee
# The amount of cash requested by the cardholder.
sig { returns(T.nilable(Integer)) }
attr_accessor :cashback_amount
sig { params(atm_fee: T.nilable(Integer), cashback_amount: T.nilable(Integer)).void }
def initialize(atm_fee: nil, cashback_amount: nil); end
end
class Fleet < Stripe::RequestParams
class CardholderPromptData < Stripe::RequestParams
# Driver ID.
sig { returns(T.nilable(String)) }
attr_accessor :driver_id
# Odometer reading.
sig { returns(T.nilable(Integer)) }
attr_accessor :odometer
# An alphanumeric ID. This field is used when a vehicle ID, driver ID, or generic ID is entered by the cardholder, but the merchant or card network did not specify the prompt type.
sig { returns(T.nilable(String)) }
attr_accessor :unspecified_id
# User ID.
sig { returns(T.nilable(String)) }
attr_accessor :user_id
# Vehicle number.
sig { returns(T.nilable(String)) }
attr_accessor :vehicle_number
sig {
params(driver_id: T.nilable(String), odometer: T.nilable(Integer), unspecified_id: T.nilable(String), user_id: T.nilable(String), vehicle_number: T.nilable(String)).void
}
def initialize(
driver_id: nil,
odometer: nil,
unspecified_id: nil,
user_id: nil,
vehicle_number: nil
); end
end
class ReportedBreakdown < Stripe::RequestParams
class Fuel < Stripe::RequestParams
# Gross fuel amount that should equal Fuel Volume multipled by Fuel Unit Cost, inclusive of taxes.
sig { returns(T.nilable(String)) }
attr_accessor :gross_amount_decimal
sig { params(gross_amount_decimal: T.nilable(String)).void }
def initialize(gross_amount_decimal: nil); end
end
class NonFuel < Stripe::RequestParams
# Gross non-fuel amount that should equal the sum of the line items, inclusive of taxes.
sig { returns(T.nilable(String)) }
attr_accessor :gross_amount_decimal
sig { params(gross_amount_decimal: T.nilable(String)).void }
def initialize(gross_amount_decimal: nil); end
end
class Tax < Stripe::RequestParams
# Amount of state or provincial Sales Tax included in the transaction amount. Null if not reported by merchant or not subject to tax.
sig { returns(T.nilable(String)) }
attr_accessor :local_amount_decimal
# Amount of national Sales Tax or VAT included in the transaction amount. Null if not reported by merchant or not subject to tax.
sig { returns(T.nilable(String)) }
attr_accessor :national_amount_decimal
sig {
params(local_amount_decimal: T.nilable(String), national_amount_decimal: T.nilable(String)).void
}
def initialize(local_amount_decimal: nil, national_amount_decimal: nil); end
end
# Breakdown of fuel portion of the purchase.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::CreateParams::Fleet::ReportedBreakdown::Fuel))
}
attr_accessor :fuel
# Breakdown of non-fuel portion of the purchase.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::CreateParams::Fleet::ReportedBreakdown::NonFuel))
}
attr_accessor :non_fuel
# Information about tax included in this transaction.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::CreateParams::Fleet::ReportedBreakdown::Tax))
}
attr_accessor :tax
sig {
params(fuel: T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::CreateParams::Fleet::ReportedBreakdown::Fuel), non_fuel: T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::CreateParams::Fleet::ReportedBreakdown::NonFuel), tax: T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::CreateParams::Fleet::ReportedBreakdown::Tax)).void
}
def initialize(fuel: nil, non_fuel: nil, tax: nil); end
end
# Answers to prompts presented to the cardholder at the point of sale. Prompted fields vary depending on the configuration of your physical fleet cards. Typical points of sale support only numeric entry.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::CreateParams::Fleet::CardholderPromptData))
}
attr_accessor :cardholder_prompt_data
# The type of purchase. One of `fuel_purchase`, `non_fuel_purchase`, or `fuel_and_non_fuel_purchase`.
sig { returns(T.nilable(String)) }
attr_accessor :purchase_type
# More information about the total amount. This information is not guaranteed to be accurate as some merchants may provide unreliable data.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::CreateParams::Fleet::ReportedBreakdown))
}
attr_accessor :reported_breakdown
# The type of fuel service. One of `non_fuel_transaction`, `full_service`, or `self_service`.
sig { returns(T.nilable(String)) }
attr_accessor :service_type
sig {
params(cardholder_prompt_data: T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::CreateParams::Fleet::CardholderPromptData), purchase_type: T.nilable(String), reported_breakdown: T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::CreateParams::Fleet::ReportedBreakdown), service_type: T.nilable(String)).void
}
def initialize(
cardholder_prompt_data: nil,
purchase_type: nil,
reported_breakdown: nil,
service_type: nil
); end
end
class Fuel < Stripe::RequestParams
# [Conexxus Payment System Product Code](https://www.conexxus.org/conexxus-payment-system-product-codes) identifying the primary fuel product purchased.
sig { returns(T.nilable(String)) }
attr_accessor :industry_product_code
# The quantity of `unit`s of fuel that was dispensed, represented as a decimal string with at most 12 decimal places.
sig { returns(T.nilable(String)) }
attr_accessor :quantity_decimal
# The type of fuel that was purchased. One of `diesel`, `unleaded_plus`, `unleaded_regular`, `unleaded_super`, or `other`.
sig { returns(T.nilable(String)) }
attr_accessor :type
# The units for `quantity_decimal`. One of `charging_minute`, `imperial_gallon`, `kilogram`, `kilowatt_hour`, `liter`, `pound`, `us_gallon`, or `other`.
sig { returns(T.nilable(String)) }
attr_accessor :unit
# The cost in cents per each unit of fuel, represented as a decimal string with at most 12 decimal places.
sig { returns(T.nilable(String)) }
attr_accessor :unit_cost_decimal
sig {
params(industry_product_code: T.nilable(String), quantity_decimal: T.nilable(String), type: T.nilable(String), unit: T.nilable(String), unit_cost_decimal: T.nilable(String)).void
}
def initialize(
industry_product_code: nil,
quantity_decimal: nil,
type: nil,
unit: nil,
unit_cost_decimal: nil
); end
end
class MerchantData < Stripe::RequestParams
# A categorization of the seller's type of business. See our [merchant categories guide](https://stripe.com/docs/issuing/merchant-categories) for a list of possible values.
sig { returns(T.nilable(String)) }
attr_accessor :category
# City where the seller is located
sig { returns(T.nilable(String)) }
attr_accessor :city
# Country where the seller is located
sig { returns(T.nilable(String)) }
attr_accessor :country
# Name of the seller
sig { returns(T.nilable(String)) }
attr_accessor :name
# Identifier assigned to the seller by the card network. Different card networks may assign different network_id fields to the same merchant.
sig { returns(T.nilable(String)) }
attr_accessor :network_id
# Postal code where the seller is located
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State where the seller is located
sig { returns(T.nilable(String)) }
attr_accessor :state
# An ID assigned by the seller to the location of the sale.
sig { returns(T.nilable(String)) }
attr_accessor :terminal_id
# URL provided by the merchant on a 3DS request
sig { returns(T.nilable(String)) }
attr_accessor :url
sig {
params(category: T.nilable(String), city: T.nilable(String), country: T.nilable(String), name: T.nilable(String), network_id: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), terminal_id: T.nilable(String), url: T.nilable(String)).void
}
def initialize(
category: nil,
city: nil,
country: nil,
name: nil,
network_id: nil,
postal_code: nil,
state: nil,
terminal_id: nil,
url: nil
); end
end
class NetworkData < Stripe::RequestParams
# Identifier assigned to the acquirer by the card network.
sig { returns(T.nilable(String)) }
attr_accessor :acquiring_institution_id
sig { params(acquiring_institution_id: T.nilable(String)).void }
def initialize(acquiring_institution_id: nil); end
end
class VerificationData < Stripe::RequestParams
class AuthenticationExemption < Stripe::RequestParams
# The entity that requested the exemption, either the acquiring merchant or the Issuing user.
sig { returns(String) }
attr_accessor :claimed_by
# The specific exemption claimed for this authorization.
sig { returns(String) }
attr_accessor :type
sig { params(claimed_by: String, type: String).void }
def initialize(claimed_by: nil, type: nil); end
end
class ThreeDSecure < Stripe::RequestParams
# The outcome of the 3D Secure authentication request.
sig { returns(String) }
attr_accessor :result
sig { params(result: String).void }
def initialize(result: nil); end
end
# Whether the cardholder provided an address first line and if it matched the cardholder’s `billing.address.line1`.
sig { returns(T.nilable(String)) }
attr_accessor :address_line1_check
# Whether the cardholder provided a postal code and if it matched the cardholder’s `billing.address.postal_code`.
sig { returns(T.nilable(String)) }
attr_accessor :address_postal_code_check
# The exemption applied to this authorization.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::CreateParams::VerificationData::AuthenticationExemption))
}
attr_accessor :authentication_exemption
# Whether the cardholder provided a CVC and if it matched Stripe’s record.
sig { returns(T.nilable(String)) }
attr_accessor :cvc_check
# Whether the cardholder provided an expiry date and if it matched Stripe’s record.
sig { returns(T.nilable(String)) }
attr_accessor :expiry_check
# 3D Secure details.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::CreateParams::VerificationData::ThreeDSecure))
}
attr_accessor :three_d_secure
sig {
params(address_line1_check: T.nilable(String), address_postal_code_check: T.nilable(String), authentication_exemption: T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::CreateParams::VerificationData::AuthenticationExemption), cvc_check: T.nilable(String), expiry_check: T.nilable(String), three_d_secure: T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::CreateParams::VerificationData::ThreeDSecure)).void
}
def initialize(
address_line1_check: nil,
address_postal_code_check: nil,
authentication_exemption: nil,
cvc_check: nil,
expiry_check: nil,
three_d_secure: nil
); end
end
# The total amount to attempt to authorize. This amount is in the provided currency, or defaults to the card's currency, and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# Detailed breakdown of amount components. These amounts are denominated in `currency` and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::CreateParams::AmountDetails))
}
attr_accessor :amount_details
# How the card details were provided. Defaults to online.
sig { returns(T.nilable(String)) }
attr_accessor :authorization_method
# Card associated with this authorization.
sig { returns(String) }
attr_accessor :card
# The currency of the authorization. If not provided, defaults to the currency of the card. 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).
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Fleet-specific information for authorizations using Fleet cards.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::CreateParams::Fleet))
}
attr_accessor :fleet
# Information about fuel that was purchased with this transaction.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::CreateParams::Fuel))
}
attr_accessor :fuel
# If set `true`, you may provide [amount](https://stripe.com/docs/api/issuing/authorizations/approve#approve_issuing_authorization-amount) to control how much to hold for the authorization.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :is_amount_controllable
# The total amount to attempt to authorize. This amount is in the provided merchant currency, and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(T.nilable(Integer)) }
attr_accessor :merchant_amount
# The currency of the authorization. If not provided, defaults to the currency of the card. 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).
sig { returns(T.nilable(String)) }
attr_accessor :merchant_currency
# Details about the seller (grocery store, e-commerce website, etc.) where the card authorization happened.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::CreateParams::MerchantData))
}
attr_accessor :merchant_data
# Details about the authorization, such as identifiers, set by the card network.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::CreateParams::NetworkData))
}
attr_accessor :network_data
# Verifications that Stripe performed on information that the cardholder provided to the merchant.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::CreateParams::VerificationData))
}
attr_accessor :verification_data
# The digital wallet used for this transaction. One of `apple_pay`, `google_pay`, or `samsung_pay`. Will populate as `null` when no digital wallet was utilized.
sig { returns(T.nilable(String)) }
attr_accessor :wallet
sig {
params(amount: T.nilable(Integer), amount_details: T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::CreateParams::AmountDetails), authorization_method: T.nilable(String), card: String, currency: T.nilable(String), expand: T.nilable(T::Array[String]), fleet: T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::CreateParams::Fleet), fuel: T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::CreateParams::Fuel), is_amount_controllable: T.nilable(T::Boolean), merchant_amount: T.nilable(Integer), merchant_currency: T.nilable(String), merchant_data: T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::CreateParams::MerchantData), network_data: T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::CreateParams::NetworkData), verification_data: T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::CreateParams::VerificationData), wallet: T.nilable(String)).void
}
def initialize(
amount: nil,
amount_details: nil,
authorization_method: nil,
card: nil,
currency: nil,
expand: nil,
fleet: nil,
fuel: nil,
is_amount_controllable: nil,
merchant_amount: nil,
merchant_currency: nil,
merchant_data: nil,
network_data: nil,
verification_data: nil,
wallet: nil
); end
end
class CaptureParams < Stripe::RequestParams
class PurchaseDetails < Stripe::RequestParams
class Fleet < Stripe::RequestParams
class CardholderPromptData < Stripe::RequestParams
# Driver ID.
sig { returns(T.nilable(String)) }
attr_accessor :driver_id
# Odometer reading.
sig { returns(T.nilable(Integer)) }
attr_accessor :odometer
# An alphanumeric ID. This field is used when a vehicle ID, driver ID, or generic ID is entered by the cardholder, but the merchant or card network did not specify the prompt type.
sig { returns(T.nilable(String)) }
attr_accessor :unspecified_id
# User ID.
sig { returns(T.nilable(String)) }
attr_accessor :user_id
# Vehicle number.
sig { returns(T.nilable(String)) }
attr_accessor :vehicle_number
sig {
params(driver_id: T.nilable(String), odometer: T.nilable(Integer), unspecified_id: T.nilable(String), user_id: T.nilable(String), vehicle_number: T.nilable(String)).void
}
def initialize(
driver_id: nil,
odometer: nil,
unspecified_id: nil,
user_id: nil,
vehicle_number: nil
); end
end
class ReportedBreakdown < Stripe::RequestParams
class Fuel < Stripe::RequestParams
# Gross fuel amount that should equal Fuel Volume multipled by Fuel Unit Cost, inclusive of taxes.
sig { returns(T.nilable(String)) }
attr_accessor :gross_amount_decimal
sig { params(gross_amount_decimal: T.nilable(String)).void }
def initialize(gross_amount_decimal: nil); end
end
class NonFuel < Stripe::RequestParams
# Gross non-fuel amount that should equal the sum of the line items, inclusive of taxes.
sig { returns(T.nilable(String)) }
attr_accessor :gross_amount_decimal
sig { params(gross_amount_decimal: T.nilable(String)).void }
def initialize(gross_amount_decimal: nil); end
end
class Tax < Stripe::RequestParams
# Amount of state or provincial Sales Tax included in the transaction amount. Null if not reported by merchant or not subject to tax.
sig { returns(T.nilable(String)) }
attr_accessor :local_amount_decimal
# Amount of national Sales Tax or VAT included in the transaction amount. Null if not reported by merchant or not subject to tax.
sig { returns(T.nilable(String)) }
attr_accessor :national_amount_decimal
sig {
params(local_amount_decimal: T.nilable(String), national_amount_decimal: T.nilable(String)).void
}
def initialize(local_amount_decimal: nil, national_amount_decimal: nil); end
end
# Breakdown of fuel portion of the purchase.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::CaptureParams::PurchaseDetails::Fleet::ReportedBreakdown::Fuel))
}
attr_accessor :fuel
# Breakdown of non-fuel portion of the purchase.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::CaptureParams::PurchaseDetails::Fleet::ReportedBreakdown::NonFuel))
}
attr_accessor :non_fuel
# Information about tax included in this transaction.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::CaptureParams::PurchaseDetails::Fleet::ReportedBreakdown::Tax))
}
attr_accessor :tax
sig {
params(fuel: T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::CaptureParams::PurchaseDetails::Fleet::ReportedBreakdown::Fuel), non_fuel: T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::CaptureParams::PurchaseDetails::Fleet::ReportedBreakdown::NonFuel), tax: T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::CaptureParams::PurchaseDetails::Fleet::ReportedBreakdown::Tax)).void
}
def initialize(fuel: nil, non_fuel: nil, tax: nil); end
end
# Answers to prompts presented to the cardholder at the point of sale. Prompted fields vary depending on the configuration of your physical fleet cards. Typical points of sale support only numeric entry.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::CaptureParams::PurchaseDetails::Fleet::CardholderPromptData))
}
attr_accessor :cardholder_prompt_data
# The type of purchase. One of `fuel_purchase`, `non_fuel_purchase`, or `fuel_and_non_fuel_purchase`.
sig { returns(T.nilable(String)) }
attr_accessor :purchase_type
# More information about the total amount. This information is not guaranteed to be accurate as some merchants may provide unreliable data.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::CaptureParams::PurchaseDetails::Fleet::ReportedBreakdown))
}
attr_accessor :reported_breakdown
# The type of fuel service. One of `non_fuel_transaction`, `full_service`, or `self_service`.
sig { returns(T.nilable(String)) }
attr_accessor :service_type
sig {
params(cardholder_prompt_data: T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::CaptureParams::PurchaseDetails::Fleet::CardholderPromptData), purchase_type: T.nilable(String), reported_breakdown: T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::CaptureParams::PurchaseDetails::Fleet::ReportedBreakdown), service_type: T.nilable(String)).void
}
def initialize(
cardholder_prompt_data: nil,
purchase_type: nil,
reported_breakdown: nil,
service_type: nil
); end
end
class Flight < Stripe::RequestParams
class Segment < Stripe::RequestParams
# The three-letter IATA airport code of the flight's destination.
sig { returns(T.nilable(String)) }
attr_accessor :arrival_airport_code
# The airline carrier code.
sig { returns(T.nilable(String)) }
attr_accessor :carrier
# The three-letter IATA airport code that the flight departed from.
sig { returns(T.nilable(String)) }
attr_accessor :departure_airport_code
# The flight number.
sig { returns(T.nilable(String)) }
attr_accessor :flight_number
# The flight's service class.
sig { returns(T.nilable(String)) }
attr_accessor :service_class
# Whether a stopover is allowed on this flight.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :stopover_allowed
sig {
params(arrival_airport_code: T.nilable(String), carrier: T.nilable(String), departure_airport_code: T.nilable(String), flight_number: T.nilable(String), service_class: T.nilable(String), stopover_allowed: T.nilable(T::Boolean)).void
}
def initialize(
arrival_airport_code: nil,
carrier: nil,
departure_airport_code: nil,
flight_number: nil,
service_class: nil,
stopover_allowed: nil
); end
end
# The time that the flight departed.
sig { returns(T.nilable(Integer)) }
attr_accessor :departure_at
# The name of the passenger.
sig { returns(T.nilable(String)) }
attr_accessor :passenger_name
# Whether the ticket is refundable.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :refundable
# The legs of the trip.
sig {
returns(T.nilable(T::Array[::Stripe::TestHelpers::Issuing::AuthorizationService::CaptureParams::PurchaseDetails::Flight::Segment]))
}
attr_accessor :segments
# The travel agency that issued the ticket.
sig { returns(T.nilable(String)) }
attr_accessor :travel_agency
sig {
params(departure_at: T.nilable(Integer), passenger_name: T.nilable(String), refundable: T.nilable(T::Boolean), segments: T.nilable(T::Array[::Stripe::TestHelpers::Issuing::AuthorizationService::CaptureParams::PurchaseDetails::Flight::Segment]), travel_agency: T.nilable(String)).void
}
def initialize(
departure_at: nil,
passenger_name: nil,
refundable: nil,
segments: nil,
travel_agency: nil
); end
end
class Fuel < Stripe::RequestParams
# [Conexxus Payment System Product Code](https://www.conexxus.org/conexxus-payment-system-product-codes) identifying the primary fuel product purchased.
sig { returns(T.nilable(String)) }
attr_accessor :industry_product_code
# The quantity of `unit`s of fuel that was dispensed, represented as a decimal string with at most 12 decimal places.
sig { returns(T.nilable(String)) }
attr_accessor :quantity_decimal
# The type of fuel that was purchased. One of `diesel`, `unleaded_plus`, `unleaded_regular`, `unleaded_super`, or `other`.
sig { returns(T.nilable(String)) }
attr_accessor :type
# The units for `quantity_decimal`. One of `charging_minute`, `imperial_gallon`, `kilogram`, `kilowatt_hour`, `liter`, `pound`, `us_gallon`, or `other`.
sig { returns(T.nilable(String)) }
attr_accessor :unit
# The cost in cents per each unit of fuel, represented as a decimal string with at most 12 decimal places.
sig { returns(T.nilable(String)) }
attr_accessor :unit_cost_decimal
sig {
params(industry_product_code: T.nilable(String), quantity_decimal: T.nilable(String), type: T.nilable(String), unit: T.nilable(String), unit_cost_decimal: T.nilable(String)).void
}
def initialize(
industry_product_code: nil,
quantity_decimal: nil,
type: nil,
unit: nil,
unit_cost_decimal: nil
); end
end
class Lodging < Stripe::RequestParams
# The time of checking into the lodging.
sig { returns(T.nilable(Integer)) }
attr_accessor :check_in_at
# The number of nights stayed at the lodging.
sig { returns(T.nilable(Integer)) }
attr_accessor :nights
sig { params(check_in_at: T.nilable(Integer), nights: T.nilable(Integer)).void }
def initialize(check_in_at: nil, nights: nil); end
end
class Receipt < Stripe::RequestParams
# Attribute for param field description
sig { returns(T.nilable(String)) }
attr_accessor :description
# Attribute for param field quantity
sig { returns(T.nilable(String)) }
attr_accessor :quantity
# Attribute for param field total
sig { returns(T.nilable(Integer)) }
attr_accessor :total
# Attribute for param field unit_cost
sig { returns(T.nilable(Integer)) }
attr_accessor :unit_cost
sig {
params(description: T.nilable(String), quantity: T.nilable(String), total: T.nilable(Integer), unit_cost: T.nilable(Integer)).void
}
def initialize(description: nil, quantity: nil, total: nil, unit_cost: nil); end
end
# Fleet-specific information for transactions using Fleet cards.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::CaptureParams::PurchaseDetails::Fleet))
}
attr_accessor :fleet
# Information about the flight that was purchased with this transaction.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::CaptureParams::PurchaseDetails::Flight))
}
attr_accessor :flight
# Information about fuel that was purchased with this transaction.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::CaptureParams::PurchaseDetails::Fuel))
}
attr_accessor :fuel
# Information about lodging that was purchased with this transaction.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::CaptureParams::PurchaseDetails::Lodging))
}
attr_accessor :lodging
# The line items in the purchase.
sig {
returns(T.nilable(T::Array[::Stripe::TestHelpers::Issuing::AuthorizationService::CaptureParams::PurchaseDetails::Receipt]))
}
attr_accessor :receipt
# A merchant-specific order number.
sig { returns(T.nilable(String)) }
attr_accessor :reference
sig {
params(fleet: T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::CaptureParams::PurchaseDetails::Fleet), flight: T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::CaptureParams::PurchaseDetails::Flight), fuel: T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::CaptureParams::PurchaseDetails::Fuel), lodging: T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::CaptureParams::PurchaseDetails::Lodging), receipt: T.nilable(T::Array[::Stripe::TestHelpers::Issuing::AuthorizationService::CaptureParams::PurchaseDetails::Receipt]), reference: T.nilable(String)).void
}
def initialize(
fleet: nil,
flight: nil,
fuel: nil,
lodging: nil,
receipt: nil,
reference: nil
); end
end
# The amount to capture from the authorization. If not provided, the full amount of the authorization will be captured. This amount is in the authorization currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(T.nilable(Integer)) }
attr_accessor :capture_amount
# Whether to close the authorization after capture. Defaults to true. Set to false to enable multi-capture flows.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :close_authorization
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Additional purchase information that is optionally provided by the merchant.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::CaptureParams::PurchaseDetails))
}
attr_accessor :purchase_details
sig {
params(capture_amount: T.nilable(Integer), close_authorization: T.nilable(T::Boolean), expand: T.nilable(T::Array[String]), purchase_details: T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::CaptureParams::PurchaseDetails)).void
}
def initialize(
capture_amount: nil,
close_authorization: nil,
expand: nil,
purchase_details: nil
); end
end
class ExpireParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class FinalizeAmountParams < Stripe::RequestParams
class Fleet < Stripe::RequestParams
class CardholderPromptData < Stripe::RequestParams
# Driver ID.
sig { returns(T.nilable(String)) }
attr_accessor :driver_id
# Odometer reading.
sig { returns(T.nilable(Integer)) }
attr_accessor :odometer
# An alphanumeric ID. This field is used when a vehicle ID, driver ID, or generic ID is entered by the cardholder, but the merchant or card network did not specify the prompt type.
sig { returns(T.nilable(String)) }
attr_accessor :unspecified_id
# User ID.
sig { returns(T.nilable(String)) }
attr_accessor :user_id
# Vehicle number.
sig { returns(T.nilable(String)) }
attr_accessor :vehicle_number
sig {
params(driver_id: T.nilable(String), odometer: T.nilable(Integer), unspecified_id: T.nilable(String), user_id: T.nilable(String), vehicle_number: T.nilable(String)).void
}
def initialize(
driver_id: nil,
odometer: nil,
unspecified_id: nil,
user_id: nil,
vehicle_number: nil
); end
end
class ReportedBreakdown < Stripe::RequestParams
class Fuel < Stripe::RequestParams
# Gross fuel amount that should equal Fuel Volume multipled by Fuel Unit Cost, inclusive of taxes.
sig { returns(T.nilable(String)) }
attr_accessor :gross_amount_decimal
sig { params(gross_amount_decimal: T.nilable(String)).void }
def initialize(gross_amount_decimal: nil); end
end
class NonFuel < Stripe::RequestParams
# Gross non-fuel amount that should equal the sum of the line items, inclusive of taxes.
sig { returns(T.nilable(String)) }
attr_accessor :gross_amount_decimal
sig { params(gross_amount_decimal: T.nilable(String)).void }
def initialize(gross_amount_decimal: nil); end
end
class Tax < Stripe::RequestParams
# Amount of state or provincial Sales Tax included in the transaction amount. Null if not reported by merchant or not subject to tax.
sig { returns(T.nilable(String)) }
attr_accessor :local_amount_decimal
# Amount of national Sales Tax or VAT included in the transaction amount. Null if not reported by merchant or not subject to tax.
sig { returns(T.nilable(String)) }
attr_accessor :national_amount_decimal
sig {
params(local_amount_decimal: T.nilable(String), national_amount_decimal: T.nilable(String)).void
}
def initialize(local_amount_decimal: nil, national_amount_decimal: nil); end
end
# Breakdown of fuel portion of the purchase.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::FinalizeAmountParams::Fleet::ReportedBreakdown::Fuel))
}
attr_accessor :fuel
# Breakdown of non-fuel portion of the purchase.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::FinalizeAmountParams::Fleet::ReportedBreakdown::NonFuel))
}
attr_accessor :non_fuel
# Information about tax included in this transaction.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::FinalizeAmountParams::Fleet::ReportedBreakdown::Tax))
}
attr_accessor :tax
sig {
params(fuel: T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::FinalizeAmountParams::Fleet::ReportedBreakdown::Fuel), non_fuel: T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::FinalizeAmountParams::Fleet::ReportedBreakdown::NonFuel), tax: T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::FinalizeAmountParams::Fleet::ReportedBreakdown::Tax)).void
}
def initialize(fuel: nil, non_fuel: nil, tax: nil); end
end
# Answers to prompts presented to the cardholder at the point of sale. Prompted fields vary depending on the configuration of your physical fleet cards. Typical points of sale support only numeric entry.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::FinalizeAmountParams::Fleet::CardholderPromptData))
}
attr_accessor :cardholder_prompt_data
# The type of purchase. One of `fuel_purchase`, `non_fuel_purchase`, or `fuel_and_non_fuel_purchase`.
sig { returns(T.nilable(String)) }
attr_accessor :purchase_type
# More information about the total amount. This information is not guaranteed to be accurate as some merchants may provide unreliable data.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::FinalizeAmountParams::Fleet::ReportedBreakdown))
}
attr_accessor :reported_breakdown
# The type of fuel service. One of `non_fuel_transaction`, `full_service`, or `self_service`.
sig { returns(T.nilable(String)) }
attr_accessor :service_type
sig {
params(cardholder_prompt_data: T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::FinalizeAmountParams::Fleet::CardholderPromptData), purchase_type: T.nilable(String), reported_breakdown: T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::FinalizeAmountParams::Fleet::ReportedBreakdown), service_type: T.nilable(String)).void
}
def initialize(
cardholder_prompt_data: nil,
purchase_type: nil,
reported_breakdown: nil,
service_type: nil
); end
end
class Fuel < Stripe::RequestParams
# [Conexxus Payment System Product Code](https://www.conexxus.org/conexxus-payment-system-product-codes) identifying the primary fuel product purchased.
sig { returns(T.nilable(String)) }
attr_accessor :industry_product_code
# The quantity of `unit`s of fuel that was dispensed, represented as a decimal string with at most 12 decimal places.
sig { returns(T.nilable(String)) }
attr_accessor :quantity_decimal
# The type of fuel that was purchased. One of `diesel`, `unleaded_plus`, `unleaded_regular`, `unleaded_super`, or `other`.
sig { returns(T.nilable(String)) }
attr_accessor :type
# The units for `quantity_decimal`. One of `charging_minute`, `imperial_gallon`, `kilogram`, `kilowatt_hour`, `liter`, `pound`, `us_gallon`, or `other`.
sig { returns(T.nilable(String)) }
attr_accessor :unit
# The cost in cents per each unit of fuel, represented as a decimal string with at most 12 decimal places.
sig { returns(T.nilable(String)) }
attr_accessor :unit_cost_decimal
sig {
params(industry_product_code: T.nilable(String), quantity_decimal: T.nilable(String), type: T.nilable(String), unit: T.nilable(String), unit_cost_decimal: T.nilable(String)).void
}
def initialize(
industry_product_code: nil,
quantity_decimal: nil,
type: nil,
unit: nil,
unit_cost_decimal: nil
); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The final authorization amount that will be captured by the merchant. This amount is in the authorization currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(Integer) }
attr_accessor :final_amount
# Fleet-specific information for authorizations using Fleet cards.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::FinalizeAmountParams::Fleet))
}
attr_accessor :fleet
# Information about fuel that was purchased with this transaction.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::FinalizeAmountParams::Fuel))
}
attr_accessor :fuel
sig {
params(expand: T.nilable(T::Array[String]), final_amount: Integer, fleet: T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::FinalizeAmountParams::Fleet), fuel: T.nilable(::Stripe::TestHelpers::Issuing::AuthorizationService::FinalizeAmountParams::Fuel)).void
}
def initialize(expand: nil, final_amount: nil, fleet: nil, fuel: nil); end
end
class RespondParams < Stripe::RequestParams
# Whether to simulate the user confirming that the transaction was legitimate (true) or telling Stripe that it was fraudulent (false).
sig { returns(T::Boolean) }
attr_accessor :confirmed
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(confirmed: T::Boolean, expand: T.nilable(T::Array[String])).void }
def initialize(confirmed: nil, expand: nil); end
end
class IncrementParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The amount to increment the authorization by. This amount is in the authorization currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(Integer) }
attr_accessor :increment_amount
# If set `true`, you may provide [amount](https://stripe.com/docs/api/issuing/authorizations/approve#approve_issuing_authorization-amount) to control how much to hold for the authorization.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :is_amount_controllable
sig {
params(expand: T.nilable(T::Array[String]), increment_amount: Integer, is_amount_controllable: T.nilable(T::Boolean)).void
}
def initialize(expand: nil, increment_amount: nil, is_amount_controllable: nil); end
end
class ReverseParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The amount to reverse from the authorization. If not provided, the full amount of the authorization will be reversed. This amount is in the authorization currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(T.nilable(Integer)) }
attr_accessor :reverse_amount
sig {
params(expand: T.nilable(T::Array[String]), reverse_amount: T.nilable(Integer)).void
}
def initialize(expand: nil, reverse_amount: nil); end
end
# Capture a test-mode authorization.
sig {
params(authorization: String, params: T.any(::Stripe::TestHelpers::Issuing::AuthorizationService::CaptureParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Authorization)
}
def capture(authorization, params = {}, opts = {}); end
# Create a test-mode authorization.
sig {
params(params: T.any(::Stripe::TestHelpers::Issuing::AuthorizationService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Authorization)
}
def create(params = {}, opts = {}); end
# Expire a test-mode Authorization.
sig {
params(authorization: String, params: T.any(::Stripe::TestHelpers::Issuing::AuthorizationService::ExpireParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Authorization)
}
def expire(authorization, params = {}, opts = {}); end
# Finalize the amount on an Authorization prior to capture, when the initial authorization was for an estimated amount.
sig {
params(authorization: String, params: T.any(::Stripe::TestHelpers::Issuing::AuthorizationService::FinalizeAmountParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Authorization)
}
def finalize_amount(authorization, params = {}, opts = {}); end
# Increment a test-mode Authorization.
sig {
params(authorization: String, params: T.any(::Stripe::TestHelpers::Issuing::AuthorizationService::IncrementParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Authorization)
}
def increment(authorization, params = {}, opts = {}); end
# Respond to a fraud challenge on a testmode Issuing authorization, simulating either a confirmation of fraud or a correction of legitimacy.
sig {
params(authorization: String, params: T.any(::Stripe::TestHelpers::Issuing::AuthorizationService::RespondParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Authorization)
}
def respond(authorization, params = {}, opts = {}); end
# Reverse a test-mode Authorization.
sig {
params(authorization: String, params: T.any(::Stripe::TestHelpers::Issuing::AuthorizationService::ReverseParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Authorization)
}
def reverse(authorization, params = {}, opts = {}); end
end
end
end
end
# typed: true
module Stripe
module TestHelpers
module Issuing
class CardService < StripeService
class DeliverCardParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class FailCardParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class ReturnCardParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class ShipCardParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class SubmitCardParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Updates the shipping status of the specified Issuing Card object to delivered.
sig {
params(card: String, params: T.any(::Stripe::TestHelpers::Issuing::CardService::DeliverCardParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Card)
}
def deliver_card(card, params = {}, opts = {}); end
# Updates the shipping status of the specified Issuing Card object to failure.
sig {
params(card: String, params: T.any(::Stripe::TestHelpers::Issuing::CardService::FailCardParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Card)
}
def fail_card(card, params = {}, opts = {}); end
# Updates the shipping status of the specified Issuing Card object to returned.
sig {
params(card: String, params: T.any(::Stripe::TestHelpers::Issuing::CardService::ReturnCardParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Card)
}
def return_card(card, params = {}, opts = {}); end
# Updates the shipping status of the specified Issuing Card object to shipped.
sig {
params(card: String, params: T.any(::Stripe::TestHelpers::Issuing::CardService::ShipCardParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Card)
}
def ship_card(card, params = {}, opts = {}); end
# Updates the shipping status of the specified Issuing Card object to submitted. This method requires Stripe Version ‘2024-09-30.acacia' or later.
sig {
params(card: String, params: T.any(::Stripe::TestHelpers::Issuing::CardService::SubmitCardParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Card)
}
def submit_card(card, params = {}, opts = {}); end
end
end
end
end
# typed: true
module Stripe
module TestHelpers
module Issuing
class PersonalizationDesignService < StripeService
class ActivateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class DeactivateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class RejectParams < Stripe::RequestParams
class RejectionReasons < Stripe::RequestParams
# The reason(s) the card logo was rejected.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :card_logo
# The reason(s) the carrier text was rejected.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :carrier_text
sig {
params(card_logo: T.nilable(T::Array[String]), carrier_text: T.nilable(T::Array[String])).void
}
def initialize(card_logo: nil, carrier_text: nil); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The reason(s) the personalization design was rejected.
sig {
returns(::Stripe::TestHelpers::Issuing::PersonalizationDesignService::RejectParams::RejectionReasons)
}
attr_accessor :rejection_reasons
sig {
params(expand: T.nilable(T::Array[String]), rejection_reasons: ::Stripe::TestHelpers::Issuing::PersonalizationDesignService::RejectParams::RejectionReasons).void
}
def initialize(expand: nil, rejection_reasons: nil); end
end
# Updates the status of the specified testmode personalization design object to active.
sig {
params(personalization_design: String, params: T.any(::Stripe::TestHelpers::Issuing::PersonalizationDesignService::ActivateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::PersonalizationDesign)
}
def activate(personalization_design, params = {}, opts = {}); end
# Updates the status of the specified testmode personalization design object to inactive.
sig {
params(personalization_design: String, params: T.any(::Stripe::TestHelpers::Issuing::PersonalizationDesignService::DeactivateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::PersonalizationDesign)
}
def deactivate(personalization_design, params = {}, opts = {}); end
# Updates the status of the specified testmode personalization design object to rejected.
sig {
params(personalization_design: String, params: T.any(::Stripe::TestHelpers::Issuing::PersonalizationDesignService::RejectParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::PersonalizationDesign)
}
def reject(personalization_design, params = {}, opts = {}); end
end
end
end
end
# typed: true
module Stripe
module TestHelpers
module Issuing
class TransactionService < StripeService
class RefundParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The total amount to attempt to refund. This amount is in the provided currency, or defaults to the cards currency, and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(T.nilable(Integer)) }
attr_accessor :refund_amount
sig {
params(expand: T.nilable(T::Array[String]), refund_amount: T.nilable(Integer)).void
}
def initialize(expand: nil, refund_amount: nil); end
end
class CreateForceCaptureParams < Stripe::RequestParams
class MerchantData < Stripe::RequestParams
# A categorization of the seller's type of business. See our [merchant categories guide](https://stripe.com/docs/issuing/merchant-categories) for a list of possible values.
sig { returns(T.nilable(String)) }
attr_accessor :category
# City where the seller is located
sig { returns(T.nilable(String)) }
attr_accessor :city
# Country where the seller is located
sig { returns(T.nilable(String)) }
attr_accessor :country
# Name of the seller
sig { returns(T.nilable(String)) }
attr_accessor :name
# Identifier assigned to the seller by the card network. Different card networks may assign different network_id fields to the same merchant.
sig { returns(T.nilable(String)) }
attr_accessor :network_id
# Postal code where the seller is located
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State where the seller is located
sig { returns(T.nilable(String)) }
attr_accessor :state
# An ID assigned by the seller to the location of the sale.
sig { returns(T.nilable(String)) }
attr_accessor :terminal_id
# URL provided by the merchant on a 3DS request
sig { returns(T.nilable(String)) }
attr_accessor :url
sig {
params(category: T.nilable(String), city: T.nilable(String), country: T.nilable(String), name: T.nilable(String), network_id: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), terminal_id: T.nilable(String), url: T.nilable(String)).void
}
def initialize(
category: nil,
city: nil,
country: nil,
name: nil,
network_id: nil,
postal_code: nil,
state: nil,
terminal_id: nil,
url: nil
); end
end
class PurchaseDetails < Stripe::RequestParams
class Fleet < Stripe::RequestParams
class CardholderPromptData < Stripe::RequestParams
# Driver ID.
sig { returns(T.nilable(String)) }
attr_accessor :driver_id
# Odometer reading.
sig { returns(T.nilable(Integer)) }
attr_accessor :odometer
# An alphanumeric ID. This field is used when a vehicle ID, driver ID, or generic ID is entered by the cardholder, but the merchant or card network did not specify the prompt type.
sig { returns(T.nilable(String)) }
attr_accessor :unspecified_id
# User ID.
sig { returns(T.nilable(String)) }
attr_accessor :user_id
# Vehicle number.
sig { returns(T.nilable(String)) }
attr_accessor :vehicle_number
sig {
params(driver_id: T.nilable(String), odometer: T.nilable(Integer), unspecified_id: T.nilable(String), user_id: T.nilable(String), vehicle_number: T.nilable(String)).void
}
def initialize(
driver_id: nil,
odometer: nil,
unspecified_id: nil,
user_id: nil,
vehicle_number: nil
); end
end
class ReportedBreakdown < Stripe::RequestParams
class Fuel < Stripe::RequestParams
# Gross fuel amount that should equal Fuel Volume multipled by Fuel Unit Cost, inclusive of taxes.
sig { returns(T.nilable(String)) }
attr_accessor :gross_amount_decimal
sig { params(gross_amount_decimal: T.nilable(String)).void }
def initialize(gross_amount_decimal: nil); end
end
class NonFuel < Stripe::RequestParams
# Gross non-fuel amount that should equal the sum of the line items, inclusive of taxes.
sig { returns(T.nilable(String)) }
attr_accessor :gross_amount_decimal
sig { params(gross_amount_decimal: T.nilable(String)).void }
def initialize(gross_amount_decimal: nil); end
end
class Tax < Stripe::RequestParams
# Amount of state or provincial Sales Tax included in the transaction amount. Null if not reported by merchant or not subject to tax.
sig { returns(T.nilable(String)) }
attr_accessor :local_amount_decimal
# Amount of national Sales Tax or VAT included in the transaction amount. Null if not reported by merchant or not subject to tax.
sig { returns(T.nilable(String)) }
attr_accessor :national_amount_decimal
sig {
params(local_amount_decimal: T.nilable(String), national_amount_decimal: T.nilable(String)).void
}
def initialize(local_amount_decimal: nil, national_amount_decimal: nil); end
end
# Breakdown of fuel portion of the purchase.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::TransactionService::CreateForceCaptureParams::PurchaseDetails::Fleet::ReportedBreakdown::Fuel))
}
attr_accessor :fuel
# Breakdown of non-fuel portion of the purchase.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::TransactionService::CreateForceCaptureParams::PurchaseDetails::Fleet::ReportedBreakdown::NonFuel))
}
attr_accessor :non_fuel
# Information about tax included in this transaction.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::TransactionService::CreateForceCaptureParams::PurchaseDetails::Fleet::ReportedBreakdown::Tax))
}
attr_accessor :tax
sig {
params(fuel: T.nilable(::Stripe::TestHelpers::Issuing::TransactionService::CreateForceCaptureParams::PurchaseDetails::Fleet::ReportedBreakdown::Fuel), non_fuel: T.nilable(::Stripe::TestHelpers::Issuing::TransactionService::CreateForceCaptureParams::PurchaseDetails::Fleet::ReportedBreakdown::NonFuel), tax: T.nilable(::Stripe::TestHelpers::Issuing::TransactionService::CreateForceCaptureParams::PurchaseDetails::Fleet::ReportedBreakdown::Tax)).void
}
def initialize(fuel: nil, non_fuel: nil, tax: nil); end
end
# Answers to prompts presented to the cardholder at the point of sale. Prompted fields vary depending on the configuration of your physical fleet cards. Typical points of sale support only numeric entry.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::TransactionService::CreateForceCaptureParams::PurchaseDetails::Fleet::CardholderPromptData))
}
attr_accessor :cardholder_prompt_data
# The type of purchase. One of `fuel_purchase`, `non_fuel_purchase`, or `fuel_and_non_fuel_purchase`.
sig { returns(T.nilable(String)) }
attr_accessor :purchase_type
# More information about the total amount. This information is not guaranteed to be accurate as some merchants may provide unreliable data.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::TransactionService::CreateForceCaptureParams::PurchaseDetails::Fleet::ReportedBreakdown))
}
attr_accessor :reported_breakdown
# The type of fuel service. One of `non_fuel_transaction`, `full_service`, or `self_service`.
sig { returns(T.nilable(String)) }
attr_accessor :service_type
sig {
params(cardholder_prompt_data: T.nilable(::Stripe::TestHelpers::Issuing::TransactionService::CreateForceCaptureParams::PurchaseDetails::Fleet::CardholderPromptData), purchase_type: T.nilable(String), reported_breakdown: T.nilable(::Stripe::TestHelpers::Issuing::TransactionService::CreateForceCaptureParams::PurchaseDetails::Fleet::ReportedBreakdown), service_type: T.nilable(String)).void
}
def initialize(
cardholder_prompt_data: nil,
purchase_type: nil,
reported_breakdown: nil,
service_type: nil
); end
end
class Flight < Stripe::RequestParams
class Segment < Stripe::RequestParams
# The three-letter IATA airport code of the flight's destination.
sig { returns(T.nilable(String)) }
attr_accessor :arrival_airport_code
# The airline carrier code.
sig { returns(T.nilable(String)) }
attr_accessor :carrier
# The three-letter IATA airport code that the flight departed from.
sig { returns(T.nilable(String)) }
attr_accessor :departure_airport_code
# The flight number.
sig { returns(T.nilable(String)) }
attr_accessor :flight_number
# The flight's service class.
sig { returns(T.nilable(String)) }
attr_accessor :service_class
# Whether a stopover is allowed on this flight.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :stopover_allowed
sig {
params(arrival_airport_code: T.nilable(String), carrier: T.nilable(String), departure_airport_code: T.nilable(String), flight_number: T.nilable(String), service_class: T.nilable(String), stopover_allowed: T.nilable(T::Boolean)).void
}
def initialize(
arrival_airport_code: nil,
carrier: nil,
departure_airport_code: nil,
flight_number: nil,
service_class: nil,
stopover_allowed: nil
); end
end
# The time that the flight departed.
sig { returns(T.nilable(Integer)) }
attr_accessor :departure_at
# The name of the passenger.
sig { returns(T.nilable(String)) }
attr_accessor :passenger_name
# Whether the ticket is refundable.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :refundable
# The legs of the trip.
sig {
returns(T.nilable(T::Array[::Stripe::TestHelpers::Issuing::TransactionService::CreateForceCaptureParams::PurchaseDetails::Flight::Segment]))
}
attr_accessor :segments
# The travel agency that issued the ticket.
sig { returns(T.nilable(String)) }
attr_accessor :travel_agency
sig {
params(departure_at: T.nilable(Integer), passenger_name: T.nilable(String), refundable: T.nilable(T::Boolean), segments: T.nilable(T::Array[::Stripe::TestHelpers::Issuing::TransactionService::CreateForceCaptureParams::PurchaseDetails::Flight::Segment]), travel_agency: T.nilable(String)).void
}
def initialize(
departure_at: nil,
passenger_name: nil,
refundable: nil,
segments: nil,
travel_agency: nil
); end
end
class Fuel < Stripe::RequestParams
# [Conexxus Payment System Product Code](https://www.conexxus.org/conexxus-payment-system-product-codes) identifying the primary fuel product purchased.
sig { returns(T.nilable(String)) }
attr_accessor :industry_product_code
# The quantity of `unit`s of fuel that was dispensed, represented as a decimal string with at most 12 decimal places.
sig { returns(T.nilable(String)) }
attr_accessor :quantity_decimal
# The type of fuel that was purchased. One of `diesel`, `unleaded_plus`, `unleaded_regular`, `unleaded_super`, or `other`.
sig { returns(T.nilable(String)) }
attr_accessor :type
# The units for `quantity_decimal`. One of `charging_minute`, `imperial_gallon`, `kilogram`, `kilowatt_hour`, `liter`, `pound`, `us_gallon`, or `other`.
sig { returns(T.nilable(String)) }
attr_accessor :unit
# The cost in cents per each unit of fuel, represented as a decimal string with at most 12 decimal places.
sig { returns(T.nilable(String)) }
attr_accessor :unit_cost_decimal
sig {
params(industry_product_code: T.nilable(String), quantity_decimal: T.nilable(String), type: T.nilable(String), unit: T.nilable(String), unit_cost_decimal: T.nilable(String)).void
}
def initialize(
industry_product_code: nil,
quantity_decimal: nil,
type: nil,
unit: nil,
unit_cost_decimal: nil
); end
end
class Lodging < Stripe::RequestParams
# The time of checking into the lodging.
sig { returns(T.nilable(Integer)) }
attr_accessor :check_in_at
# The number of nights stayed at the lodging.
sig { returns(T.nilable(Integer)) }
attr_accessor :nights
sig { params(check_in_at: T.nilable(Integer), nights: T.nilable(Integer)).void }
def initialize(check_in_at: nil, nights: nil); end
end
class Receipt < Stripe::RequestParams
# Attribute for param field description
sig { returns(T.nilable(String)) }
attr_accessor :description
# Attribute for param field quantity
sig { returns(T.nilable(String)) }
attr_accessor :quantity
# Attribute for param field total
sig { returns(T.nilable(Integer)) }
attr_accessor :total
# Attribute for param field unit_cost
sig { returns(T.nilable(Integer)) }
attr_accessor :unit_cost
sig {
params(description: T.nilable(String), quantity: T.nilable(String), total: T.nilable(Integer), unit_cost: T.nilable(Integer)).void
}
def initialize(description: nil, quantity: nil, total: nil, unit_cost: nil); end
end
# Fleet-specific information for transactions using Fleet cards.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::TransactionService::CreateForceCaptureParams::PurchaseDetails::Fleet))
}
attr_accessor :fleet
# Information about the flight that was purchased with this transaction.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::TransactionService::CreateForceCaptureParams::PurchaseDetails::Flight))
}
attr_accessor :flight
# Information about fuel that was purchased with this transaction.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::TransactionService::CreateForceCaptureParams::PurchaseDetails::Fuel))
}
attr_accessor :fuel
# Information about lodging that was purchased with this transaction.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::TransactionService::CreateForceCaptureParams::PurchaseDetails::Lodging))
}
attr_accessor :lodging
# The line items in the purchase.
sig {
returns(T.nilable(T::Array[::Stripe::TestHelpers::Issuing::TransactionService::CreateForceCaptureParams::PurchaseDetails::Receipt]))
}
attr_accessor :receipt
# A merchant-specific order number.
sig { returns(T.nilable(String)) }
attr_accessor :reference
sig {
params(fleet: T.nilable(::Stripe::TestHelpers::Issuing::TransactionService::CreateForceCaptureParams::PurchaseDetails::Fleet), flight: T.nilable(::Stripe::TestHelpers::Issuing::TransactionService::CreateForceCaptureParams::PurchaseDetails::Flight), fuel: T.nilable(::Stripe::TestHelpers::Issuing::TransactionService::CreateForceCaptureParams::PurchaseDetails::Fuel), lodging: T.nilable(::Stripe::TestHelpers::Issuing::TransactionService::CreateForceCaptureParams::PurchaseDetails::Lodging), receipt: T.nilable(T::Array[::Stripe::TestHelpers::Issuing::TransactionService::CreateForceCaptureParams::PurchaseDetails::Receipt]), reference: T.nilable(String)).void
}
def initialize(
fleet: nil,
flight: nil,
fuel: nil,
lodging: nil,
receipt: nil,
reference: nil
); end
end
# The total amount to attempt to capture. This amount is in the provided currency, or defaults to the cards currency, and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(Integer) }
attr_accessor :amount
# Card associated with this transaction.
sig { returns(String) }
attr_accessor :card
# The currency of the capture. If not provided, defaults to the currency of the card. 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).
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Details about the seller (grocery store, e-commerce website, etc.) where the card authorization happened.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::TransactionService::CreateForceCaptureParams::MerchantData))
}
attr_accessor :merchant_data
# Additional purchase information that is optionally provided by the merchant.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::TransactionService::CreateForceCaptureParams::PurchaseDetails))
}
attr_accessor :purchase_details
sig {
params(amount: Integer, card: String, currency: T.nilable(String), expand: T.nilable(T::Array[String]), merchant_data: T.nilable(::Stripe::TestHelpers::Issuing::TransactionService::CreateForceCaptureParams::MerchantData), purchase_details: T.nilable(::Stripe::TestHelpers::Issuing::TransactionService::CreateForceCaptureParams::PurchaseDetails)).void
}
def initialize(
amount: nil,
card: nil,
currency: nil,
expand: nil,
merchant_data: nil,
purchase_details: nil
); end
end
class CreateUnlinkedRefundParams < Stripe::RequestParams
class MerchantData < Stripe::RequestParams
# A categorization of the seller's type of business. See our [merchant categories guide](https://stripe.com/docs/issuing/merchant-categories) for a list of possible values.
sig { returns(T.nilable(String)) }
attr_accessor :category
# City where the seller is located
sig { returns(T.nilable(String)) }
attr_accessor :city
# Country where the seller is located
sig { returns(T.nilable(String)) }
attr_accessor :country
# Name of the seller
sig { returns(T.nilable(String)) }
attr_accessor :name
# Identifier assigned to the seller by the card network. Different card networks may assign different network_id fields to the same merchant.
sig { returns(T.nilable(String)) }
attr_accessor :network_id
# Postal code where the seller is located
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State where the seller is located
sig { returns(T.nilable(String)) }
attr_accessor :state
# An ID assigned by the seller to the location of the sale.
sig { returns(T.nilable(String)) }
attr_accessor :terminal_id
# URL provided by the merchant on a 3DS request
sig { returns(T.nilable(String)) }
attr_accessor :url
sig {
params(category: T.nilable(String), city: T.nilable(String), country: T.nilable(String), name: T.nilable(String), network_id: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), terminal_id: T.nilable(String), url: T.nilable(String)).void
}
def initialize(
category: nil,
city: nil,
country: nil,
name: nil,
network_id: nil,
postal_code: nil,
state: nil,
terminal_id: nil,
url: nil
); end
end
class PurchaseDetails < Stripe::RequestParams
class Fleet < Stripe::RequestParams
class CardholderPromptData < Stripe::RequestParams
# Driver ID.
sig { returns(T.nilable(String)) }
attr_accessor :driver_id
# Odometer reading.
sig { returns(T.nilable(Integer)) }
attr_accessor :odometer
# An alphanumeric ID. This field is used when a vehicle ID, driver ID, or generic ID is entered by the cardholder, but the merchant or card network did not specify the prompt type.
sig { returns(T.nilable(String)) }
attr_accessor :unspecified_id
# User ID.
sig { returns(T.nilable(String)) }
attr_accessor :user_id
# Vehicle number.
sig { returns(T.nilable(String)) }
attr_accessor :vehicle_number
sig {
params(driver_id: T.nilable(String), odometer: T.nilable(Integer), unspecified_id: T.nilable(String), user_id: T.nilable(String), vehicle_number: T.nilable(String)).void
}
def initialize(
driver_id: nil,
odometer: nil,
unspecified_id: nil,
user_id: nil,
vehicle_number: nil
); end
end
class ReportedBreakdown < Stripe::RequestParams
class Fuel < Stripe::RequestParams
# Gross fuel amount that should equal Fuel Volume multipled by Fuel Unit Cost, inclusive of taxes.
sig { returns(T.nilable(String)) }
attr_accessor :gross_amount_decimal
sig { params(gross_amount_decimal: T.nilable(String)).void }
def initialize(gross_amount_decimal: nil); end
end
class NonFuel < Stripe::RequestParams
# Gross non-fuel amount that should equal the sum of the line items, inclusive of taxes.
sig { returns(T.nilable(String)) }
attr_accessor :gross_amount_decimal
sig { params(gross_amount_decimal: T.nilable(String)).void }
def initialize(gross_amount_decimal: nil); end
end
class Tax < Stripe::RequestParams
# Amount of state or provincial Sales Tax included in the transaction amount. Null if not reported by merchant or not subject to tax.
sig { returns(T.nilable(String)) }
attr_accessor :local_amount_decimal
# Amount of national Sales Tax or VAT included in the transaction amount. Null if not reported by merchant or not subject to tax.
sig { returns(T.nilable(String)) }
attr_accessor :national_amount_decimal
sig {
params(local_amount_decimal: T.nilable(String), national_amount_decimal: T.nilable(String)).void
}
def initialize(local_amount_decimal: nil, national_amount_decimal: nil); end
end
# Breakdown of fuel portion of the purchase.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::TransactionService::CreateUnlinkedRefundParams::PurchaseDetails::Fleet::ReportedBreakdown::Fuel))
}
attr_accessor :fuel
# Breakdown of non-fuel portion of the purchase.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::TransactionService::CreateUnlinkedRefundParams::PurchaseDetails::Fleet::ReportedBreakdown::NonFuel))
}
attr_accessor :non_fuel
# Information about tax included in this transaction.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::TransactionService::CreateUnlinkedRefundParams::PurchaseDetails::Fleet::ReportedBreakdown::Tax))
}
attr_accessor :tax
sig {
params(fuel: T.nilable(::Stripe::TestHelpers::Issuing::TransactionService::CreateUnlinkedRefundParams::PurchaseDetails::Fleet::ReportedBreakdown::Fuel), non_fuel: T.nilable(::Stripe::TestHelpers::Issuing::TransactionService::CreateUnlinkedRefundParams::PurchaseDetails::Fleet::ReportedBreakdown::NonFuel), tax: T.nilable(::Stripe::TestHelpers::Issuing::TransactionService::CreateUnlinkedRefundParams::PurchaseDetails::Fleet::ReportedBreakdown::Tax)).void
}
def initialize(fuel: nil, non_fuel: nil, tax: nil); end
end
# Answers to prompts presented to the cardholder at the point of sale. Prompted fields vary depending on the configuration of your physical fleet cards. Typical points of sale support only numeric entry.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::TransactionService::CreateUnlinkedRefundParams::PurchaseDetails::Fleet::CardholderPromptData))
}
attr_accessor :cardholder_prompt_data
# The type of purchase. One of `fuel_purchase`, `non_fuel_purchase`, or `fuel_and_non_fuel_purchase`.
sig { returns(T.nilable(String)) }
attr_accessor :purchase_type
# More information about the total amount. This information is not guaranteed to be accurate as some merchants may provide unreliable data.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::TransactionService::CreateUnlinkedRefundParams::PurchaseDetails::Fleet::ReportedBreakdown))
}
attr_accessor :reported_breakdown
# The type of fuel service. One of `non_fuel_transaction`, `full_service`, or `self_service`.
sig { returns(T.nilable(String)) }
attr_accessor :service_type
sig {
params(cardholder_prompt_data: T.nilable(::Stripe::TestHelpers::Issuing::TransactionService::CreateUnlinkedRefundParams::PurchaseDetails::Fleet::CardholderPromptData), purchase_type: T.nilable(String), reported_breakdown: T.nilable(::Stripe::TestHelpers::Issuing::TransactionService::CreateUnlinkedRefundParams::PurchaseDetails::Fleet::ReportedBreakdown), service_type: T.nilable(String)).void
}
def initialize(
cardholder_prompt_data: nil,
purchase_type: nil,
reported_breakdown: nil,
service_type: nil
); end
end
class Flight < Stripe::RequestParams
class Segment < Stripe::RequestParams
# The three-letter IATA airport code of the flight's destination.
sig { returns(T.nilable(String)) }
attr_accessor :arrival_airport_code
# The airline carrier code.
sig { returns(T.nilable(String)) }
attr_accessor :carrier
# The three-letter IATA airport code that the flight departed from.
sig { returns(T.nilable(String)) }
attr_accessor :departure_airport_code
# The flight number.
sig { returns(T.nilable(String)) }
attr_accessor :flight_number
# The flight's service class.
sig { returns(T.nilable(String)) }
attr_accessor :service_class
# Whether a stopover is allowed on this flight.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :stopover_allowed
sig {
params(arrival_airport_code: T.nilable(String), carrier: T.nilable(String), departure_airport_code: T.nilable(String), flight_number: T.nilable(String), service_class: T.nilable(String), stopover_allowed: T.nilable(T::Boolean)).void
}
def initialize(
arrival_airport_code: nil,
carrier: nil,
departure_airport_code: nil,
flight_number: nil,
service_class: nil,
stopover_allowed: nil
); end
end
# The time that the flight departed.
sig { returns(T.nilable(Integer)) }
attr_accessor :departure_at
# The name of the passenger.
sig { returns(T.nilable(String)) }
attr_accessor :passenger_name
# Whether the ticket is refundable.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :refundable
# The legs of the trip.
sig {
returns(T.nilable(T::Array[::Stripe::TestHelpers::Issuing::TransactionService::CreateUnlinkedRefundParams::PurchaseDetails::Flight::Segment]))
}
attr_accessor :segments
# The travel agency that issued the ticket.
sig { returns(T.nilable(String)) }
attr_accessor :travel_agency
sig {
params(departure_at: T.nilable(Integer), passenger_name: T.nilable(String), refundable: T.nilable(T::Boolean), segments: T.nilable(T::Array[::Stripe::TestHelpers::Issuing::TransactionService::CreateUnlinkedRefundParams::PurchaseDetails::Flight::Segment]), travel_agency: T.nilable(String)).void
}
def initialize(
departure_at: nil,
passenger_name: nil,
refundable: nil,
segments: nil,
travel_agency: nil
); end
end
class Fuel < Stripe::RequestParams
# [Conexxus Payment System Product Code](https://www.conexxus.org/conexxus-payment-system-product-codes) identifying the primary fuel product purchased.
sig { returns(T.nilable(String)) }
attr_accessor :industry_product_code
# The quantity of `unit`s of fuel that was dispensed, represented as a decimal string with at most 12 decimal places.
sig { returns(T.nilable(String)) }
attr_accessor :quantity_decimal
# The type of fuel that was purchased. One of `diesel`, `unleaded_plus`, `unleaded_regular`, `unleaded_super`, or `other`.
sig { returns(T.nilable(String)) }
attr_accessor :type
# The units for `quantity_decimal`. One of `charging_minute`, `imperial_gallon`, `kilogram`, `kilowatt_hour`, `liter`, `pound`, `us_gallon`, or `other`.
sig { returns(T.nilable(String)) }
attr_accessor :unit
# The cost in cents per each unit of fuel, represented as a decimal string with at most 12 decimal places.
sig { returns(T.nilable(String)) }
attr_accessor :unit_cost_decimal
sig {
params(industry_product_code: T.nilable(String), quantity_decimal: T.nilable(String), type: T.nilable(String), unit: T.nilable(String), unit_cost_decimal: T.nilable(String)).void
}
def initialize(
industry_product_code: nil,
quantity_decimal: nil,
type: nil,
unit: nil,
unit_cost_decimal: nil
); end
end
class Lodging < Stripe::RequestParams
# The time of checking into the lodging.
sig { returns(T.nilable(Integer)) }
attr_accessor :check_in_at
# The number of nights stayed at the lodging.
sig { returns(T.nilable(Integer)) }
attr_accessor :nights
sig { params(check_in_at: T.nilable(Integer), nights: T.nilable(Integer)).void }
def initialize(check_in_at: nil, nights: nil); end
end
class Receipt < Stripe::RequestParams
# Attribute for param field description
sig { returns(T.nilable(String)) }
attr_accessor :description
# Attribute for param field quantity
sig { returns(T.nilable(String)) }
attr_accessor :quantity
# Attribute for param field total
sig { returns(T.nilable(Integer)) }
attr_accessor :total
# Attribute for param field unit_cost
sig { returns(T.nilable(Integer)) }
attr_accessor :unit_cost
sig {
params(description: T.nilable(String), quantity: T.nilable(String), total: T.nilable(Integer), unit_cost: T.nilable(Integer)).void
}
def initialize(description: nil, quantity: nil, total: nil, unit_cost: nil); end
end
# Fleet-specific information for transactions using Fleet cards.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::TransactionService::CreateUnlinkedRefundParams::PurchaseDetails::Fleet))
}
attr_accessor :fleet
# Information about the flight that was purchased with this transaction.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::TransactionService::CreateUnlinkedRefundParams::PurchaseDetails::Flight))
}
attr_accessor :flight
# Information about fuel that was purchased with this transaction.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::TransactionService::CreateUnlinkedRefundParams::PurchaseDetails::Fuel))
}
attr_accessor :fuel
# Information about lodging that was purchased with this transaction.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::TransactionService::CreateUnlinkedRefundParams::PurchaseDetails::Lodging))
}
attr_accessor :lodging
# The line items in the purchase.
sig {
returns(T.nilable(T::Array[::Stripe::TestHelpers::Issuing::TransactionService::CreateUnlinkedRefundParams::PurchaseDetails::Receipt]))
}
attr_accessor :receipt
# A merchant-specific order number.
sig { returns(T.nilable(String)) }
attr_accessor :reference
sig {
params(fleet: T.nilable(::Stripe::TestHelpers::Issuing::TransactionService::CreateUnlinkedRefundParams::PurchaseDetails::Fleet), flight: T.nilable(::Stripe::TestHelpers::Issuing::TransactionService::CreateUnlinkedRefundParams::PurchaseDetails::Flight), fuel: T.nilable(::Stripe::TestHelpers::Issuing::TransactionService::CreateUnlinkedRefundParams::PurchaseDetails::Fuel), lodging: T.nilable(::Stripe::TestHelpers::Issuing::TransactionService::CreateUnlinkedRefundParams::PurchaseDetails::Lodging), receipt: T.nilable(T::Array[::Stripe::TestHelpers::Issuing::TransactionService::CreateUnlinkedRefundParams::PurchaseDetails::Receipt]), reference: T.nilable(String)).void
}
def initialize(
fleet: nil,
flight: nil,
fuel: nil,
lodging: nil,
receipt: nil,
reference: nil
); end
end
# The total amount to attempt to refund. This amount is in the provided currency, or defaults to the cards currency, and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(Integer) }
attr_accessor :amount
# Card associated with this unlinked refund transaction.
sig { returns(String) }
attr_accessor :card
# The currency of the unlinked refund. If not provided, defaults to the currency of the card. 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).
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Details about the seller (grocery store, e-commerce website, etc.) where the card authorization happened.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::TransactionService::CreateUnlinkedRefundParams::MerchantData))
}
attr_accessor :merchant_data
# Additional purchase information that is optionally provided by the merchant.
sig {
returns(T.nilable(::Stripe::TestHelpers::Issuing::TransactionService::CreateUnlinkedRefundParams::PurchaseDetails))
}
attr_accessor :purchase_details
sig {
params(amount: Integer, card: String, currency: T.nilable(String), expand: T.nilable(T::Array[String]), merchant_data: T.nilable(::Stripe::TestHelpers::Issuing::TransactionService::CreateUnlinkedRefundParams::MerchantData), purchase_details: T.nilable(::Stripe::TestHelpers::Issuing::TransactionService::CreateUnlinkedRefundParams::PurchaseDetails)).void
}
def initialize(
amount: nil,
card: nil,
currency: nil,
expand: nil,
merchant_data: nil,
purchase_details: nil
); end
end
# Allows the user to capture an arbitrary amount, also known as a forced capture.
sig {
params(params: T.any(::Stripe::TestHelpers::Issuing::TransactionService::CreateForceCaptureParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Transaction)
}
def create_force_capture(params = {}, opts = {}); end
# Allows the user to refund an arbitrary amount, also known as a unlinked refund.
sig {
params(params: T.any(::Stripe::TestHelpers::Issuing::TransactionService::CreateUnlinkedRefundParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Transaction)
}
def create_unlinked_refund(params = {}, opts = {}); end
# Refund a test-mode Transaction.
sig {
params(transaction: String, params: T.any(::Stripe::TestHelpers::Issuing::TransactionService::RefundParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Transaction)
}
def refund(transaction, params = {}, opts = {}); end
end
end
end
end
# typed: true
module Stripe
module TestHelpers
class RefundService < StripeService
class ExpireParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Expire a refund with a status of requires_action.
sig {
params(refund: String, params: T.any(::Stripe::TestHelpers::RefundService::ExpireParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Refund)
}
def expire(refund, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module TestHelpers
class TerminalService < StripeService
attr_reader :readers
end
end
end
# typed: true
module Stripe
module TestHelpers
module Terminal
class ReaderService < StripeService
class PresentPaymentMethodParams < Stripe::RequestParams
class CardPresent < Stripe::RequestParams
# The card number, as a string without any separators.
sig { returns(T.nilable(String)) }
attr_accessor :number
sig { params(number: T.nilable(String)).void }
def initialize(number: nil); end
end
class InteracPresent < Stripe::RequestParams
# Card Number
sig { returns(T.nilable(String)) }
attr_accessor :number
sig { params(number: T.nilable(String)).void }
def initialize(number: nil); end
end
# Simulated on-reader tip amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount_tip
# Simulated data for the card_present payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::Terminal::ReaderService::PresentPaymentMethodParams::CardPresent))
}
attr_accessor :card_present
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Simulated data for the interac_present payment method.
sig {
returns(T.nilable(::Stripe::TestHelpers::Terminal::ReaderService::PresentPaymentMethodParams::InteracPresent))
}
attr_accessor :interac_present
# Simulated payment type.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(amount_tip: T.nilable(Integer), card_present: T.nilable(::Stripe::TestHelpers::Terminal::ReaderService::PresentPaymentMethodParams::CardPresent), expand: T.nilable(T::Array[String]), interac_present: T.nilable(::Stripe::TestHelpers::Terminal::ReaderService::PresentPaymentMethodParams::InteracPresent), type: T.nilable(String)).void
}
def initialize(
amount_tip: nil,
card_present: nil,
expand: nil,
interac_present: nil,
type: nil
); end
end
class SucceedInputCollectionParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# This parameter defines the skip behavior for input collection.
sig { returns(T.nilable(String)) }
attr_accessor :skip_non_required_inputs
sig {
params(expand: T.nilable(T::Array[String]), skip_non_required_inputs: T.nilable(String)).void
}
def initialize(expand: nil, skip_non_required_inputs: nil); end
end
class TimeoutInputCollectionParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Presents a payment method on a simulated reader. Can be used to simulate accepting a payment, saving a card or refunding a transaction.
sig {
params(reader: String, params: T.any(::Stripe::TestHelpers::Terminal::ReaderService::PresentPaymentMethodParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Reader)
}
def present_payment_method(reader, params = {}, opts = {}); end
# Use this endpoint to trigger a successful input collection on a simulated reader.
sig {
params(reader: String, params: T.any(::Stripe::TestHelpers::Terminal::ReaderService::SucceedInputCollectionParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Reader)
}
def succeed_input_collection(reader, params = {}, opts = {}); end
# Use this endpoint to complete an input collection with a timeout error on a simulated reader.
sig {
params(reader: String, params: T.any(::Stripe::TestHelpers::Terminal::ReaderService::TimeoutInputCollectionParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Reader)
}
def timeout_input_collection(reader, params = {}, opts = {}); end
end
end
end
end
# typed: true
module Stripe
module TestHelpers
class TestClockService < StripeService
class DeleteParams < Stripe::RequestParams; end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
class CreateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The initial frozen time for this test clock.
sig { returns(Integer) }
attr_accessor :frozen_time
# The name for this test clock.
sig { returns(T.nilable(String)) }
attr_accessor :name
sig {
params(expand: T.nilable(T::Array[String]), frozen_time: Integer, name: T.nilable(String)).void
}
def initialize(expand: nil, frozen_time: nil, name: nil); end
end
class AdvanceParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The time to advance the test clock. Must be after the test clock's current frozen time. Cannot be more than two intervals in the future from the shortest subscription in this test clock. If there are no subscriptions in this test clock, it cannot be more than two years in the future.
sig { returns(Integer) }
attr_accessor :frozen_time
sig { params(expand: T.nilable(T::Array[String]), frozen_time: Integer).void }
def initialize(expand: nil, frozen_time: nil); end
end
# Starts advancing a test clock to a specified time in the future. Advancement is done when status changes to Ready.
sig {
params(test_clock: String, params: T.any(::Stripe::TestHelpers::TestClockService::AdvanceParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::TestHelpers::TestClock)
}
def advance(test_clock, params = {}, opts = {}); end
# Creates a new test clock that can be attached to new customers and quotes.
sig {
params(params: T.any(::Stripe::TestHelpers::TestClockService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::TestHelpers::TestClock)
}
def create(params = {}, opts = {}); end
# Deletes a test clock.
sig {
params(test_clock: String, params: T.any(::Stripe::TestHelpers::TestClockService::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::TestHelpers::TestClock)
}
def delete(test_clock, params = {}, opts = {}); end
# Returns a list of your test clocks.
sig {
params(params: T.any(::Stripe::TestHelpers::TestClockService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves a test clock.
sig {
params(test_clock: String, params: T.any(::Stripe::TestHelpers::TestClockService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::TestHelpers::TestClock)
}
def retrieve(test_clock, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module TestHelpers
class TreasuryService < StripeService
attr_reader :inbound_transfers
attr_reader :outbound_payments
attr_reader :outbound_transfers
attr_reader :received_credits
attr_reader :received_debits
end
end
end
# typed: true
module Stripe
module TestHelpers
module Treasury
class InboundTransferService < StripeService
class FailParams < Stripe::RequestParams
class FailureDetails < Stripe::RequestParams
# Reason for the failure.
sig { returns(T.nilable(String)) }
attr_accessor :code
sig { params(code: T.nilable(String)).void }
def initialize(code: nil); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Details about a failed InboundTransfer.
sig {
returns(T.nilable(::Stripe::TestHelpers::Treasury::InboundTransferService::FailParams::FailureDetails))
}
attr_accessor :failure_details
sig {
params(expand: T.nilable(T::Array[String]), failure_details: T.nilable(::Stripe::TestHelpers::Treasury::InboundTransferService::FailParams::FailureDetails)).void
}
def initialize(expand: nil, failure_details: nil); end
end
class ReturnInboundTransferParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class SucceedParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Transitions a test mode created InboundTransfer to the failed status. The InboundTransfer must already be in the processing state.
sig {
params(id: String, params: T.any(::Stripe::TestHelpers::Treasury::InboundTransferService::FailParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::InboundTransfer)
}
def fail(id, params = {}, opts = {}); end
# Marks the test mode InboundTransfer object as returned and links the InboundTransfer to a ReceivedDebit. The InboundTransfer must already be in the succeeded state.
sig {
params(id: String, params: T.any(::Stripe::TestHelpers::Treasury::InboundTransferService::ReturnInboundTransferParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::InboundTransfer)
}
def return_inbound_transfer(id, params = {}, opts = {}); end
# Transitions a test mode created InboundTransfer to the succeeded status. The InboundTransfer must already be in the processing state.
sig {
params(id: String, params: T.any(::Stripe::TestHelpers::Treasury::InboundTransferService::SucceedParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::InboundTransfer)
}
def succeed(id, params = {}, opts = {}); end
end
end
end
end
# typed: true
module Stripe
module TestHelpers
module Treasury
class OutboundPaymentService < StripeService
class UpdateParams < Stripe::RequestParams
class TrackingDetails < Stripe::RequestParams
class Ach < Stripe::RequestParams
# ACH trace ID for funds sent over the `ach` network.
sig { returns(String) }
attr_accessor :trace_id
sig { params(trace_id: String).void }
def initialize(trace_id: nil); end
end
class UsDomesticWire < Stripe::RequestParams
# CHIPS System Sequence Number (SSN) for funds sent over the `us_domestic_wire` network.
sig { returns(T.nilable(String)) }
attr_accessor :chips
# IMAD for funds sent over the `us_domestic_wire` network.
sig { returns(T.nilable(String)) }
attr_accessor :imad
# OMAD for funds sent over the `us_domestic_wire` network.
sig { returns(T.nilable(String)) }
attr_accessor :omad
sig {
params(chips: T.nilable(String), imad: T.nilable(String), omad: T.nilable(String)).void
}
def initialize(chips: nil, imad: nil, omad: nil); end
end
# ACH network tracking details.
sig {
returns(T.nilable(::Stripe::TestHelpers::Treasury::OutboundPaymentService::UpdateParams::TrackingDetails::Ach))
}
attr_accessor :ach
# The US bank account network used to send funds.
sig { returns(String) }
attr_accessor :type
# US domestic wire network tracking details.
sig {
returns(T.nilable(::Stripe::TestHelpers::Treasury::OutboundPaymentService::UpdateParams::TrackingDetails::UsDomesticWire))
}
attr_accessor :us_domestic_wire
sig {
params(ach: T.nilable(::Stripe::TestHelpers::Treasury::OutboundPaymentService::UpdateParams::TrackingDetails::Ach), type: String, us_domestic_wire: T.nilable(::Stripe::TestHelpers::Treasury::OutboundPaymentService::UpdateParams::TrackingDetails::UsDomesticWire)).void
}
def initialize(ach: nil, type: nil, us_domestic_wire: nil); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Details about network-specific tracking information.
sig {
returns(::Stripe::TestHelpers::Treasury::OutboundPaymentService::UpdateParams::TrackingDetails)
}
attr_accessor :tracking_details
sig {
params(expand: T.nilable(T::Array[String]), tracking_details: ::Stripe::TestHelpers::Treasury::OutboundPaymentService::UpdateParams::TrackingDetails).void
}
def initialize(expand: nil, tracking_details: nil); end
end
class FailParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class PostParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class ReturnOutboundPaymentParams < Stripe::RequestParams
class ReturnedDetails < Stripe::RequestParams
# The return code to be set on the OutboundPayment object.
sig { returns(T.nilable(String)) }
attr_accessor :code
sig { params(code: T.nilable(String)).void }
def initialize(code: nil); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Optional hash to set the return code.
sig {
returns(T.nilable(::Stripe::TestHelpers::Treasury::OutboundPaymentService::ReturnOutboundPaymentParams::ReturnedDetails))
}
attr_accessor :returned_details
sig {
params(expand: T.nilable(T::Array[String]), returned_details: T.nilable(::Stripe::TestHelpers::Treasury::OutboundPaymentService::ReturnOutboundPaymentParams::ReturnedDetails)).void
}
def initialize(expand: nil, returned_details: nil); end
end
# Transitions a test mode created OutboundPayment to the failed status. The OutboundPayment must already be in the processing state.
sig {
params(id: String, params: T.any(::Stripe::TestHelpers::Treasury::OutboundPaymentService::FailParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::OutboundPayment)
}
def fail(id, params = {}, opts = {}); end
# Transitions a test mode created OutboundPayment to the posted status. The OutboundPayment must already be in the processing state.
sig {
params(id: String, params: T.any(::Stripe::TestHelpers::Treasury::OutboundPaymentService::PostParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::OutboundPayment)
}
def post(id, params = {}, opts = {}); end
# Transitions a test mode created OutboundPayment to the returned status. The OutboundPayment must already be in the processing state.
sig {
params(id: String, params: T.any(::Stripe::TestHelpers::Treasury::OutboundPaymentService::ReturnOutboundPaymentParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::OutboundPayment)
}
def return_outbound_payment(id, params = {}, opts = {}); end
# Updates a test mode created OutboundPayment with tracking details. The OutboundPayment must not be cancelable, and cannot be in the canceled or failed states.
sig {
params(id: String, params: T.any(::Stripe::TestHelpers::Treasury::OutboundPaymentService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::OutboundPayment)
}
def update(id, params = {}, opts = {}); end
end
end
end
end
# typed: true
module Stripe
module TestHelpers
module Treasury
class OutboundTransferService < StripeService
class UpdateParams < Stripe::RequestParams
class TrackingDetails < Stripe::RequestParams
class Ach < Stripe::RequestParams
# ACH trace ID for funds sent over the `ach` network.
sig { returns(String) }
attr_accessor :trace_id
sig { params(trace_id: String).void }
def initialize(trace_id: nil); end
end
class UsDomesticWire < Stripe::RequestParams
# CHIPS System Sequence Number (SSN) for funds sent over the `us_domestic_wire` network.
sig { returns(T.nilable(String)) }
attr_accessor :chips
# IMAD for funds sent over the `us_domestic_wire` network.
sig { returns(T.nilable(String)) }
attr_accessor :imad
# OMAD for funds sent over the `us_domestic_wire` network.
sig { returns(T.nilable(String)) }
attr_accessor :omad
sig {
params(chips: T.nilable(String), imad: T.nilable(String), omad: T.nilable(String)).void
}
def initialize(chips: nil, imad: nil, omad: nil); end
end
# ACH network tracking details.
sig {
returns(T.nilable(::Stripe::TestHelpers::Treasury::OutboundTransferService::UpdateParams::TrackingDetails::Ach))
}
attr_accessor :ach
# The US bank account network used to send funds.
sig { returns(String) }
attr_accessor :type
# US domestic wire network tracking details.
sig {
returns(T.nilable(::Stripe::TestHelpers::Treasury::OutboundTransferService::UpdateParams::TrackingDetails::UsDomesticWire))
}
attr_accessor :us_domestic_wire
sig {
params(ach: T.nilable(::Stripe::TestHelpers::Treasury::OutboundTransferService::UpdateParams::TrackingDetails::Ach), type: String, us_domestic_wire: T.nilable(::Stripe::TestHelpers::Treasury::OutboundTransferService::UpdateParams::TrackingDetails::UsDomesticWire)).void
}
def initialize(ach: nil, type: nil, us_domestic_wire: nil); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Details about network-specific tracking information.
sig {
returns(::Stripe::TestHelpers::Treasury::OutboundTransferService::UpdateParams::TrackingDetails)
}
attr_accessor :tracking_details
sig {
params(expand: T.nilable(T::Array[String]), tracking_details: ::Stripe::TestHelpers::Treasury::OutboundTransferService::UpdateParams::TrackingDetails).void
}
def initialize(expand: nil, tracking_details: nil); end
end
class FailParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class PostParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class ReturnOutboundTransferParams < Stripe::RequestParams
class ReturnedDetails < Stripe::RequestParams
# Reason for the return.
sig { returns(T.nilable(String)) }
attr_accessor :code
sig { params(code: T.nilable(String)).void }
def initialize(code: nil); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Details about a returned OutboundTransfer.
sig {
returns(T.nilable(::Stripe::TestHelpers::Treasury::OutboundTransferService::ReturnOutboundTransferParams::ReturnedDetails))
}
attr_accessor :returned_details
sig {
params(expand: T.nilable(T::Array[String]), returned_details: T.nilable(::Stripe::TestHelpers::Treasury::OutboundTransferService::ReturnOutboundTransferParams::ReturnedDetails)).void
}
def initialize(expand: nil, returned_details: nil); end
end
# Transitions a test mode created OutboundTransfer to the failed status. The OutboundTransfer must already be in the processing state.
sig {
params(outbound_transfer: String, params: T.any(::Stripe::TestHelpers::Treasury::OutboundTransferService::FailParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::OutboundTransfer)
}
def fail(outbound_transfer, params = {}, opts = {}); end
# Transitions a test mode created OutboundTransfer to the posted status. The OutboundTransfer must already be in the processing state.
sig {
params(outbound_transfer: String, params: T.any(::Stripe::TestHelpers::Treasury::OutboundTransferService::PostParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::OutboundTransfer)
}
def post(outbound_transfer, params = {}, opts = {}); end
# Transitions a test mode created OutboundTransfer to the returned status. The OutboundTransfer must already be in the processing state.
sig {
params(outbound_transfer: String, params: T.any(::Stripe::TestHelpers::Treasury::OutboundTransferService::ReturnOutboundTransferParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::OutboundTransfer)
}
def return_outbound_transfer(outbound_transfer, params = {}, opts = {}); end
# Updates a test mode created OutboundTransfer with tracking details. The OutboundTransfer must not be cancelable, and cannot be in the canceled or failed states.
sig {
params(outbound_transfer: String, params: T.any(::Stripe::TestHelpers::Treasury::OutboundTransferService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::OutboundTransfer)
}
def update(outbound_transfer, params = {}, opts = {}); end
end
end
end
end
# typed: true
module Stripe
module TestHelpers
module Treasury
class ReceivedCreditService < StripeService
class CreateParams < Stripe::RequestParams
class InitiatingPaymentMethodDetails < Stripe::RequestParams
class UsBankAccount < Stripe::RequestParams
# The bank account holder's name.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_name
# The bank account number.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# The bank account's routing number.
sig { returns(T.nilable(String)) }
attr_accessor :routing_number
sig {
params(account_holder_name: T.nilable(String), account_number: T.nilable(String), routing_number: T.nilable(String)).void
}
def initialize(
account_holder_name: nil,
account_number: nil,
routing_number: nil
); end
end
# The source type.
sig { returns(String) }
attr_accessor :type
# Optional fields for `us_bank_account`.
sig {
returns(T.nilable(::Stripe::TestHelpers::Treasury::ReceivedCreditService::CreateParams::InitiatingPaymentMethodDetails::UsBankAccount))
}
attr_accessor :us_bank_account
sig {
params(type: String, us_bank_account: T.nilable(::Stripe::TestHelpers::Treasury::ReceivedCreditService::CreateParams::InitiatingPaymentMethodDetails::UsBankAccount)).void
}
def initialize(type: nil, us_bank_account: nil); end
end
class NetworkDetails < Stripe::RequestParams
class Ach < Stripe::RequestParams
# ACH Addenda record
sig { returns(T.nilable(String)) }
attr_accessor :addenda
sig { params(addenda: T.nilable(String)).void }
def initialize(addenda: nil); end
end
# Optional fields for `ach`.
sig {
returns(T.nilable(::Stripe::TestHelpers::Treasury::ReceivedCreditService::CreateParams::NetworkDetails::Ach))
}
attr_accessor :ach
# The type of flow that originated the ReceivedCredit.
sig { returns(String) }
attr_accessor :type
sig {
params(ach: T.nilable(::Stripe::TestHelpers::Treasury::ReceivedCreditService::CreateParams::NetworkDetails::Ach), type: String).void
}
def initialize(ach: nil, type: nil); end
end
# Amount (in cents) to be transferred.
sig { returns(Integer) }
attr_accessor :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).
sig { returns(String) }
attr_accessor :currency
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The FinancialAccount to send funds to.
sig { returns(String) }
attr_accessor :financial_account
# Initiating payment method details for the object.
sig {
returns(T.nilable(::Stripe::TestHelpers::Treasury::ReceivedCreditService::CreateParams::InitiatingPaymentMethodDetails))
}
attr_accessor :initiating_payment_method_details
# Specifies the network rails to be used. If not set, will default to the PaymentMethod's preferred network. See the [docs](https://stripe.com/docs/treasury/money-movement/timelines) to learn more about money movement timelines for each network type.
sig { returns(String) }
attr_accessor :network
# Details about the network used for the ReceivedCredit.
sig {
returns(T.nilable(::Stripe::TestHelpers::Treasury::ReceivedCreditService::CreateParams::NetworkDetails))
}
attr_accessor :network_details
sig {
params(amount: Integer, currency: String, description: T.nilable(String), expand: T.nilable(T::Array[String]), financial_account: String, initiating_payment_method_details: T.nilable(::Stripe::TestHelpers::Treasury::ReceivedCreditService::CreateParams::InitiatingPaymentMethodDetails), network: String, network_details: T.nilable(::Stripe::TestHelpers::Treasury::ReceivedCreditService::CreateParams::NetworkDetails)).void
}
def initialize(
amount: nil,
currency: nil,
description: nil,
expand: nil,
financial_account: nil,
initiating_payment_method_details: nil,
network: nil,
network_details: nil
); end
end
# Use this endpoint to simulate a test mode ReceivedCredit initiated by a third party. In live mode, you can't directly create ReceivedCredits initiated by third parties.
sig {
params(params: T.any(::Stripe::TestHelpers::Treasury::ReceivedCreditService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::ReceivedCredit)
}
def create(params = {}, opts = {}); end
end
end
end
end
# typed: true
module Stripe
module TestHelpers
module Treasury
class ReceivedDebitService < StripeService
class CreateParams < Stripe::RequestParams
class InitiatingPaymentMethodDetails < Stripe::RequestParams
class UsBankAccount < Stripe::RequestParams
# The bank account holder's name.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_name
# The bank account number.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# The bank account's routing number.
sig { returns(T.nilable(String)) }
attr_accessor :routing_number
sig {
params(account_holder_name: T.nilable(String), account_number: T.nilable(String), routing_number: T.nilable(String)).void
}
def initialize(
account_holder_name: nil,
account_number: nil,
routing_number: nil
); end
end
# The source type.
sig { returns(String) }
attr_accessor :type
# Optional fields for `us_bank_account`.
sig {
returns(T.nilable(::Stripe::TestHelpers::Treasury::ReceivedDebitService::CreateParams::InitiatingPaymentMethodDetails::UsBankAccount))
}
attr_accessor :us_bank_account
sig {
params(type: String, us_bank_account: T.nilable(::Stripe::TestHelpers::Treasury::ReceivedDebitService::CreateParams::InitiatingPaymentMethodDetails::UsBankAccount)).void
}
def initialize(type: nil, us_bank_account: nil); end
end
class NetworkDetails < Stripe::RequestParams
class Ach < Stripe::RequestParams
# Addenda record data associated with this ReceivedDebit.
sig { returns(T.nilable(String)) }
attr_accessor :addenda
sig { params(addenda: T.nilable(String)).void }
def initialize(addenda: nil); end
end
# Optional fields for `ach`.
sig {
returns(T.nilable(::Stripe::TestHelpers::Treasury::ReceivedDebitService::CreateParams::NetworkDetails::Ach))
}
attr_accessor :ach
# The type of flow that originated the ReceivedDebit.
sig { returns(String) }
attr_accessor :type
sig {
params(ach: T.nilable(::Stripe::TestHelpers::Treasury::ReceivedDebitService::CreateParams::NetworkDetails::Ach), type: String).void
}
def initialize(ach: nil, type: nil); end
end
# Amount (in cents) to be transferred.
sig { returns(Integer) }
attr_accessor :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).
sig { returns(String) }
attr_accessor :currency
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The FinancialAccount to pull funds from.
sig { returns(String) }
attr_accessor :financial_account
# Initiating payment method details for the object.
sig {
returns(T.nilable(::Stripe::TestHelpers::Treasury::ReceivedDebitService::CreateParams::InitiatingPaymentMethodDetails))
}
attr_accessor :initiating_payment_method_details
# Specifies the network rails to be used. If not set, will default to the PaymentMethod's preferred network. See the [docs](https://stripe.com/docs/treasury/money-movement/timelines) to learn more about money movement timelines for each network type.
sig { returns(String) }
attr_accessor :network
# Details about the network used for the ReceivedDebit.
sig {
returns(T.nilable(::Stripe::TestHelpers::Treasury::ReceivedDebitService::CreateParams::NetworkDetails))
}
attr_accessor :network_details
sig {
params(amount: Integer, currency: String, description: T.nilable(String), expand: T.nilable(T::Array[String]), financial_account: String, initiating_payment_method_details: T.nilable(::Stripe::TestHelpers::Treasury::ReceivedDebitService::CreateParams::InitiatingPaymentMethodDetails), network: String, network_details: T.nilable(::Stripe::TestHelpers::Treasury::ReceivedDebitService::CreateParams::NetworkDetails)).void
}
def initialize(
amount: nil,
currency: nil,
description: nil,
expand: nil,
financial_account: nil,
initiating_payment_method_details: nil,
network: nil,
network_details: nil
); end
end
# Use this endpoint to simulate a test mode ReceivedDebit initiated by a third party. In live mode, you can't directly create ReceivedDebits initiated by third parties.
sig {
params(params: T.any(::Stripe::TestHelpers::Treasury::ReceivedDebitService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::ReceivedDebit)
}
def create(params = {}, opts = {}); end
end
end
end
end
# typed: true
module Stripe
class CountrySpecService < StripeService
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Lists all Country Spec objects available in the API.
sig {
params(params: T.any(::Stripe::CountrySpecService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Returns a Country Spec for a given Country code.
sig {
params(country: String, params: T.any(::Stripe::CountrySpecService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::CountrySpec)
}
def retrieve(country, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class CouponService < StripeService
class DeleteParams < Stripe::RequestParams; end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
class CurrencyOptions < Stripe::RequestParams
# A positive integer representing the amount to subtract from an invoice total.
sig { returns(Integer) }
attr_accessor :amount_off
sig { params(amount_off: Integer).void }
def initialize(amount_off: nil); end
end
# Coupons defined in each available currency option (only supported if the coupon is amount-based). Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
sig {
returns(T.nilable(T::Hash[String, ::Stripe::CouponService::UpdateParams::CurrencyOptions]))
}
attr_accessor :currency_options
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Name of the coupon displayed to customers on, for instance invoices, or receipts. By default the `id` is shown if `name` is not set.
sig { returns(T.nilable(String)) }
attr_accessor :name
sig {
params(currency_options: T.nilable(T::Hash[String, ::Stripe::CouponService::UpdateParams::CurrencyOptions]), expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), name: T.nilable(String)).void
}
def initialize(currency_options: nil, expand: nil, metadata: nil, name: nil); end
end
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.
sig { returns(T.nilable(T.any(::Stripe::CouponService::ListParams::Created, Integer))) }
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(created: T.nilable(T.any(::Stripe::CouponService::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class AppliesTo < Stripe::RequestParams
# An array of Product IDs that this Coupon will apply to.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :products
sig { params(products: T.nilable(T::Array[String])).void }
def initialize(products: nil); end
end
class CurrencyOptions < Stripe::RequestParams
# A positive integer representing the amount to subtract from an invoice total.
sig { returns(Integer) }
attr_accessor :amount_off
sig { params(amount_off: Integer).void }
def initialize(amount_off: nil); end
end
class Script < Stripe::RequestParams
# The configuration values of the script. The keys and values are specific to the script implementation.
sig { returns(T::Hash[String, T.untyped]) }
attr_accessor :configuration
# The script implementation ID for this coupon.
sig { returns(String) }
attr_accessor :id
sig { params(configuration: T::Hash[String, T.untyped], id: String).void }
def initialize(configuration: nil, id: nil); end
end
# A positive integer representing the amount to subtract from an invoice total (required if `percent_off` is not passed).
sig { returns(T.nilable(Integer)) }
attr_accessor :amount_off
# A hash containing directions for what this Coupon will apply discounts to.
sig { returns(T.nilable(::Stripe::CouponService::CreateParams::AppliesTo)) }
attr_accessor :applies_to
# Three-letter [ISO code for the currency](https://stripe.com/docs/currencies) of the `amount_off` parameter (required if `amount_off` is passed).
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Coupons defined in each available currency option (only supported if `amount_off` is passed). Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
sig {
returns(T.nilable(T::Hash[String, ::Stripe::CouponService::CreateParams::CurrencyOptions]))
}
attr_accessor :currency_options
# Specifies how long the discount will be in effect if used on a subscription. Defaults to `once`.
sig { returns(T.nilable(String)) }
attr_accessor :duration
# Required only if `duration` is `repeating`, in which case it must be a positive integer that specifies the number of months the discount will be in effect.
sig { returns(T.nilable(Integer)) }
attr_accessor :duration_in_months
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Unique string of your choice that will be used to identify this coupon when applying it to a customer. If you don't want to specify a particular code, you can leave the ID blank and we'll generate a random code for you.
sig { returns(T.nilable(String)) }
attr_accessor :id
# A positive integer specifying the number of times the coupon can be redeemed before it's no longer valid. For example, you might have a 50% off coupon that the first 20 readers of your blog can use.
sig { returns(T.nilable(Integer)) }
attr_accessor :max_redemptions
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Name of the coupon displayed to customers on, for instance invoices, or receipts. By default the `id` is shown if `name` is not set.
sig { returns(T.nilable(String)) }
attr_accessor :name
# A positive float larger than 0, and smaller or equal to 100, that represents the discount the coupon will apply (required if `amount_off` is not passed).
sig { returns(T.nilable(Float)) }
attr_accessor :percent_off
# Unix timestamp specifying the last time at which the coupon can be redeemed. After the redeem_by date, the coupon can no longer be applied to new customers.
sig { returns(T.nilable(Integer)) }
attr_accessor :redeem_by
# Configuration of the [script](https://docs.stripe.com/billing/subscriptions/script-coupons) used to calculate the discount.
sig { returns(T.nilable(::Stripe::CouponService::CreateParams::Script)) }
attr_accessor :script
sig {
params(amount_off: T.nilable(Integer), applies_to: T.nilable(::Stripe::CouponService::CreateParams::AppliesTo), currency: T.nilable(String), currency_options: T.nilable(T::Hash[String, ::Stripe::CouponService::CreateParams::CurrencyOptions]), duration: T.nilable(String), duration_in_months: T.nilable(Integer), expand: T.nilable(T::Array[String]), id: T.nilable(String), max_redemptions: T.nilable(Integer), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), name: T.nilable(String), percent_off: T.nilable(Float), redeem_by: T.nilable(Integer), script: T.nilable(::Stripe::CouponService::CreateParams::Script)).void
}
def initialize(
amount_off: nil,
applies_to: nil,
currency: nil,
currency_options: nil,
duration: nil,
duration_in_months: nil,
expand: nil,
id: nil,
max_redemptions: nil,
metadata: nil,
name: nil,
percent_off: nil,
redeem_by: nil,
script: nil
); end
end
# You can create coupons easily via the [coupon management](https://dashboard.stripe.com/coupons) page of the Stripe dashboard. Coupon creation is also accessible via the API if you need to create coupons on the fly.
#
# A coupon has either a percent_off or an amount_off and currency. If you set an amount_off, that amount will be subtracted from any invoice's subtotal. For example, an invoice with a subtotal of 100 will have a final total of 0 if a coupon with an amount_off of 200 is applied to it and an invoice with a subtotal of 300 will have a final total of 100 if a coupon with an amount_off of 200 is applied to it.
sig {
params(params: T.any(::Stripe::CouponService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Coupon)
}
def create(params = {}, opts = {}); end
# You can delete coupons via the [coupon management](https://dashboard.stripe.com/coupons) page of the Stripe dashboard. However, deleting a coupon does not affect any customers who have already applied the coupon; it means that new customers can't redeem the coupon. You can also delete coupons via the API.
sig {
params(coupon: String, params: T.any(::Stripe::CouponService::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Coupon)
}
def delete(coupon, params = {}, opts = {}); end
# Returns a list of your coupons.
sig {
params(params: T.any(::Stripe::CouponService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the coupon with the given ID.
sig {
params(coupon: String, params: T.any(::Stripe::CouponService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Coupon)
}
def retrieve(coupon, params = {}, opts = {}); end
# Updates the metadata of a coupon. Other coupon details (currency, duration, amount_off) are, by design, not editable.
sig {
params(coupon: String, params: T.any(::Stripe::CouponService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Coupon)
}
def update(coupon, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class CreditNoteService < StripeService
attr_reader :line_items
attr_reader :preview_lines
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return credit notes that were created during the given date interval.
sig { returns(T.nilable(T.any(::Stripe::CreditNoteService::ListParams::Created, Integer))) }
attr_accessor :created
# Only return credit notes for the customer specified by this customer ID.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# Only return credit notes for the account specified by this account ID.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Only return credit notes for the invoice specified by this invoice ID.
sig { returns(T.nilable(String)) }
attr_accessor :invoice
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(created: T.nilable(T.any(::Stripe::CreditNoteService::ListParams::Created, Integer)), customer: T.nilable(String), customer_account: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), invoice: T.nilable(String), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
created: nil,
customer: nil,
customer_account: nil,
ending_before: nil,
expand: nil,
invoice: nil,
limit: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class Line < Stripe::RequestParams
class TaxAmount < Stripe::RequestParams
# The amount, in cents (or local equivalent), of the tax.
sig { returns(Integer) }
attr_accessor :amount
# The id of the tax rate for this tax amount. The tax rate must have been automatically created by Stripe.
sig { returns(String) }
attr_accessor :tax_rate
# The amount on which tax is calculated, in cents (or local equivalent).
sig { returns(Integer) }
attr_accessor :taxable_amount
sig { params(amount: Integer, tax_rate: String, taxable_amount: Integer).void }
def initialize(amount: nil, tax_rate: nil, taxable_amount: nil); end
end
# The line item amount to credit. Only valid when `type` is `invoice_line_item`. If invoice is set up with `automatic_tax[enabled]=true`, this amount is tax exclusive
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# The description of the credit note line item. Only valid when the `type` is `custom_line_item`.
sig { returns(T.nilable(String)) }
attr_accessor :description
# The invoice line item to credit. Only valid when the `type` is `invoice_line_item`.
sig { returns(T.nilable(String)) }
attr_accessor :invoice_line_item
# The line item quantity to credit.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# A list of up to 10 tax amounts for the credit note line item. Cannot be mixed with `tax_rates`.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::CreditNoteService::CreateParams::Line::TaxAmount]))))
}
attr_accessor :tax_amounts
# The tax rates which apply to the credit note line item. Only valid when the `type` is `custom_line_item` and cannot be mixed with `tax_amounts`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
# Type of the credit note line item, one of `invoice_line_item` or `custom_line_item`
sig { returns(String) }
attr_accessor :type
# The integer unit amount in cents (or local equivalent) of the credit note line item. This `unit_amount` will be multiplied by the quantity to get the full amount to credit for this line item. Only valid when `type` is `custom_line_item`.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(amount: T.nilable(Integer), description: T.nilable(String), invoice_line_item: T.nilable(String), quantity: T.nilable(Integer), tax_amounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::CreditNoteService::CreateParams::Line::TaxAmount]))), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String]))), type: String, unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
amount: nil,
description: nil,
invoice_line_item: nil,
quantity: nil,
tax_amounts: nil,
tax_rates: nil,
type: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
class Refund < Stripe::RequestParams
# Amount of the refund that applies to this credit note, in cents (or local equivalent). Defaults to the entire refund amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount_refunded
# ID of an existing refund to link this credit note to.
sig { returns(T.nilable(String)) }
attr_accessor :refund
sig { params(amount_refunded: T.nilable(Integer), refund: T.nilable(String)).void }
def initialize(amount_refunded: nil, refund: nil); end
end
class ShippingCost < Stripe::RequestParams
# The ID of the shipping rate to use for this order.
sig { returns(T.nilable(String)) }
attr_accessor :shipping_rate
sig { params(shipping_rate: T.nilable(String)).void }
def initialize(shipping_rate: nil); end
end
# The integer amount in cents (or local equivalent) representing the total amount of the credit note.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# The integer amount in cents (or local equivalent) representing the amount to credit the customer's balance, which will be automatically applied to their next invoice.
sig { returns(T.nilable(Integer)) }
attr_accessor :credit_amount
# The date when this credit note is in effect. Same as `created` unless overwritten. When defined, this value replaces the system-generated 'Date of issue' printed on the credit note PDF.
sig { returns(T.nilable(Integer)) }
attr_accessor :effective_at
# Type of email to send to the customer, one of `credit_note` or `none` and the default is `credit_note`.
sig { returns(T.nilable(String)) }
attr_accessor :email_type
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# ID of the invoice.
sig { returns(String) }
attr_accessor :invoice
# Line items that make up the credit note.
sig { returns(T.nilable(T::Array[::Stripe::CreditNoteService::CreateParams::Line])) }
attr_accessor :lines
# The credit note's memo appears on the credit note PDF.
sig { returns(T.nilable(String)) }
attr_accessor :memo
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The integer amount in cents (or local equivalent) representing the amount that is credited outside of Stripe.
sig { returns(T.nilable(Integer)) }
attr_accessor :out_of_band_amount
# Reason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory`
sig { returns(T.nilable(String)) }
attr_accessor :reason
# The integer amount in cents (or local equivalent) representing the amount to refund. If set, a refund will be created for the charge associated with the invoice.
sig { returns(T.nilable(Integer)) }
attr_accessor :refund_amount
# Refunds to link to this credit note.
sig { returns(T.nilable(T::Array[::Stripe::CreditNoteService::CreateParams::Refund])) }
attr_accessor :refunds
# When shipping_cost contains the shipping_rate from the invoice, the shipping_cost is included in the credit note.
sig { returns(T.nilable(::Stripe::CreditNoteService::CreateParams::ShippingCost)) }
attr_accessor :shipping_cost
sig {
params(amount: T.nilable(Integer), credit_amount: T.nilable(Integer), effective_at: T.nilable(Integer), email_type: T.nilable(String), expand: T.nilable(T::Array[String]), invoice: String, lines: T.nilable(T::Array[::Stripe::CreditNoteService::CreateParams::Line]), memo: T.nilable(String), metadata: T.nilable(T::Hash[String, String]), out_of_band_amount: T.nilable(Integer), reason: T.nilable(String), refund_amount: T.nilable(Integer), refunds: T.nilable(T::Array[::Stripe::CreditNoteService::CreateParams::Refund]), shipping_cost: T.nilable(::Stripe::CreditNoteService::CreateParams::ShippingCost)).void
}
def initialize(
amount: nil,
credit_amount: nil,
effective_at: nil,
email_type: nil,
expand: nil,
invoice: nil,
lines: nil,
memo: nil,
metadata: nil,
out_of_band_amount: nil,
reason: nil,
refund_amount: nil,
refunds: nil,
shipping_cost: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Credit note memo.
sig { returns(T.nilable(String)) }
attr_accessor :memo
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
sig {
params(expand: T.nilable(T::Array[String]), memo: T.nilable(String), metadata: T.nilable(T::Hash[String, String])).void
}
def initialize(expand: nil, memo: nil, metadata: nil); end
end
class PreviewParams < Stripe::RequestParams
class Line < Stripe::RequestParams
class TaxAmount < Stripe::RequestParams
# The amount, in cents (or local equivalent), of the tax.
sig { returns(Integer) }
attr_accessor :amount
# The id of the tax rate for this tax amount. The tax rate must have been automatically created by Stripe.
sig { returns(String) }
attr_accessor :tax_rate
# The amount on which tax is calculated, in cents (or local equivalent).
sig { returns(Integer) }
attr_accessor :taxable_amount
sig { params(amount: Integer, tax_rate: String, taxable_amount: Integer).void }
def initialize(amount: nil, tax_rate: nil, taxable_amount: nil); end
end
# The line item amount to credit. Only valid when `type` is `invoice_line_item`. If invoice is set up with `automatic_tax[enabled]=true`, this amount is tax exclusive
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# The description of the credit note line item. Only valid when the `type` is `custom_line_item`.
sig { returns(T.nilable(String)) }
attr_accessor :description
# The invoice line item to credit. Only valid when the `type` is `invoice_line_item`.
sig { returns(T.nilable(String)) }
attr_accessor :invoice_line_item
# The line item quantity to credit.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# A list of up to 10 tax amounts for the credit note line item. Cannot be mixed with `tax_rates`.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::CreditNoteService::PreviewParams::Line::TaxAmount]))))
}
attr_accessor :tax_amounts
# The tax rates which apply to the credit note line item. Only valid when the `type` is `custom_line_item` and cannot be mixed with `tax_amounts`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
# Type of the credit note line item, one of `invoice_line_item` or `custom_line_item`
sig { returns(String) }
attr_accessor :type
# The integer unit amount in cents (or local equivalent) of the credit note line item. This `unit_amount` will be multiplied by the quantity to get the full amount to credit for this line item. Only valid when `type` is `custom_line_item`.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(amount: T.nilable(Integer), description: T.nilable(String), invoice_line_item: T.nilable(String), quantity: T.nilable(Integer), tax_amounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::CreditNoteService::PreviewParams::Line::TaxAmount]))), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String]))), type: String, unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
amount: nil,
description: nil,
invoice_line_item: nil,
quantity: nil,
tax_amounts: nil,
tax_rates: nil,
type: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
class Refund < Stripe::RequestParams
# Amount of the refund that applies to this credit note, in cents (or local equivalent). Defaults to the entire refund amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount_refunded
# ID of an existing refund to link this credit note to.
sig { returns(T.nilable(String)) }
attr_accessor :refund
sig { params(amount_refunded: T.nilable(Integer), refund: T.nilable(String)).void }
def initialize(amount_refunded: nil, refund: nil); end
end
class ShippingCost < Stripe::RequestParams
# The ID of the shipping rate to use for this order.
sig { returns(T.nilable(String)) }
attr_accessor :shipping_rate
sig { params(shipping_rate: T.nilable(String)).void }
def initialize(shipping_rate: nil); end
end
# The integer amount in cents (or local equivalent) representing the total amount of the credit note.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# The integer amount in cents (or local equivalent) representing the amount to credit the customer's balance, which will be automatically applied to their next invoice.
sig { returns(T.nilable(Integer)) }
attr_accessor :credit_amount
# The date when this credit note is in effect. Same as `created` unless overwritten. When defined, this value replaces the system-generated 'Date of issue' printed on the credit note PDF.
sig { returns(T.nilable(Integer)) }
attr_accessor :effective_at
# Type of email to send to the customer, one of `credit_note` or `none` and the default is `credit_note`.
sig { returns(T.nilable(String)) }
attr_accessor :email_type
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# ID of the invoice.
sig { returns(String) }
attr_accessor :invoice
# Line items that make up the credit note.
sig { returns(T.nilable(T::Array[::Stripe::CreditNoteService::PreviewParams::Line])) }
attr_accessor :lines
# The credit note's memo appears on the credit note PDF.
sig { returns(T.nilable(String)) }
attr_accessor :memo
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The integer amount in cents (or local equivalent) representing the amount that is credited outside of Stripe.
sig { returns(T.nilable(Integer)) }
attr_accessor :out_of_band_amount
# Reason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory`
sig { returns(T.nilable(String)) }
attr_accessor :reason
# The integer amount in cents (or local equivalent) representing the amount to refund. If set, a refund will be created for the charge associated with the invoice.
sig { returns(T.nilable(Integer)) }
attr_accessor :refund_amount
# Refunds to link to this credit note.
sig { returns(T.nilable(T::Array[::Stripe::CreditNoteService::PreviewParams::Refund])) }
attr_accessor :refunds
# When shipping_cost contains the shipping_rate from the invoice, the shipping_cost is included in the credit note.
sig { returns(T.nilable(::Stripe::CreditNoteService::PreviewParams::ShippingCost)) }
attr_accessor :shipping_cost
sig {
params(amount: T.nilable(Integer), credit_amount: T.nilable(Integer), effective_at: T.nilable(Integer), email_type: T.nilable(String), expand: T.nilable(T::Array[String]), invoice: String, lines: T.nilable(T::Array[::Stripe::CreditNoteService::PreviewParams::Line]), memo: T.nilable(String), metadata: T.nilable(T::Hash[String, String]), out_of_band_amount: T.nilable(Integer), reason: T.nilable(String), refund_amount: T.nilable(Integer), refunds: T.nilable(T::Array[::Stripe::CreditNoteService::PreviewParams::Refund]), shipping_cost: T.nilable(::Stripe::CreditNoteService::PreviewParams::ShippingCost)).void
}
def initialize(
amount: nil,
credit_amount: nil,
effective_at: nil,
email_type: nil,
expand: nil,
invoice: nil,
lines: nil,
memo: nil,
metadata: nil,
out_of_band_amount: nil,
reason: nil,
refund_amount: nil,
refunds: nil,
shipping_cost: nil
); end
end
class VoidCreditNoteParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Issue a credit note to adjust the amount of a finalized invoice. A credit note will first reduce the invoice's amount_remaining (and amount_due), but not below zero.
# This amount is indicated by the credit note's pre_payment_amount. The excess amount is indicated by post_payment_amount, and it can result in any combination of the following:
#
#
# Refunds: create a new refund (using refund_amount) or link existing refunds (using refunds).
# Customer balance credit: credit the customer's balance (using credit_amount) which will be automatically applied to their next invoice when it's finalized.
# Outside of Stripe credit: record the amount that is or will be credited outside of Stripe (using out_of_band_amount).
#
#
# The sum of refunds, customer balance credits, and outside of Stripe credits must equal the post_payment_amount.
#
# You may issue multiple credit notes for an invoice. Each credit note may increment the invoice's pre_payment_credit_notes_amount,
# post_payment_credit_notes_amount, or both, depending on the invoice's amount_remaining at the time of credit note creation.
sig {
params(params: T.any(::Stripe::CreditNoteService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::CreditNote)
}
def create(params = {}, opts = {}); end
# Returns a list of credit notes.
sig {
params(params: T.any(::Stripe::CreditNoteService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Get a preview of a credit note without creating it.
sig {
params(params: T.any(::Stripe::CreditNoteService::PreviewParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::CreditNote)
}
def preview(params = {}, opts = {}); end
# Retrieves the credit note object with the given identifier.
sig {
params(id: String, params: T.any(::Stripe::CreditNoteService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::CreditNote)
}
def retrieve(id, params = {}, opts = {}); end
# Updates an existing credit note.
sig {
params(id: String, params: T.any(::Stripe::CreditNoteService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::CreditNote)
}
def update(id, params = {}, opts = {}); end
# Marks a credit note as void. Learn more about [voiding credit notes](https://docs.stripe.com/docs/billing/invoices/credit-notes#voiding).
sig {
params(id: String, params: T.any(::Stripe::CreditNoteService::VoidCreditNoteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::CreditNote)
}
def void_credit_note(id, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class CreditNoteLineItemService < StripeService
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
# When retrieving a credit note, you'll get a lines property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items.
sig {
params(credit_note: String, params: T.any(::Stripe::CreditNoteLineItemService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(credit_note, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class CreditNotePreviewLinesService < StripeService
class ListParams < Stripe::RequestParams
class Line < Stripe::RequestParams
class TaxAmount < Stripe::RequestParams
# The amount, in cents (or local equivalent), of the tax.
sig { returns(Integer) }
attr_accessor :amount
# The id of the tax rate for this tax amount. The tax rate must have been automatically created by Stripe.
sig { returns(String) }
attr_accessor :tax_rate
# The amount on which tax is calculated, in cents (or local equivalent).
sig { returns(Integer) }
attr_accessor :taxable_amount
sig { params(amount: Integer, tax_rate: String, taxable_amount: Integer).void }
def initialize(amount: nil, tax_rate: nil, taxable_amount: nil); end
end
# The line item amount to credit. Only valid when `type` is `invoice_line_item`. If invoice is set up with `automatic_tax[enabled]=true`, this amount is tax exclusive
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# The description of the credit note line item. Only valid when the `type` is `custom_line_item`.
sig { returns(T.nilable(String)) }
attr_accessor :description
# The invoice line item to credit. Only valid when the `type` is `invoice_line_item`.
sig { returns(T.nilable(String)) }
attr_accessor :invoice_line_item
# The line item quantity to credit.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# A list of up to 10 tax amounts for the credit note line item. Cannot be mixed with `tax_rates`.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::CreditNotePreviewLinesService::ListParams::Line::TaxAmount]))))
}
attr_accessor :tax_amounts
# The tax rates which apply to the credit note line item. Only valid when the `type` is `custom_line_item` and cannot be mixed with `tax_amounts`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
# Type of the credit note line item, one of `invoice_line_item` or `custom_line_item`
sig { returns(String) }
attr_accessor :type
# The integer unit amount in cents (or local equivalent) of the credit note line item. This `unit_amount` will be multiplied by the quantity to get the full amount to credit for this line item. Only valid when `type` is `custom_line_item`.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(amount: T.nilable(Integer), description: T.nilable(String), invoice_line_item: T.nilable(String), quantity: T.nilable(Integer), tax_amounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::CreditNotePreviewLinesService::ListParams::Line::TaxAmount]))), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String]))), type: String, unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
amount: nil,
description: nil,
invoice_line_item: nil,
quantity: nil,
tax_amounts: nil,
tax_rates: nil,
type: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
class Refund < Stripe::RequestParams
# Amount of the refund that applies to this credit note, in cents (or local equivalent). Defaults to the entire refund amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount_refunded
# ID of an existing refund to link this credit note to.
sig { returns(T.nilable(String)) }
attr_accessor :refund
sig { params(amount_refunded: T.nilable(Integer), refund: T.nilable(String)).void }
def initialize(amount_refunded: nil, refund: nil); end
end
class ShippingCost < Stripe::RequestParams
# The ID of the shipping rate to use for this order.
sig { returns(T.nilable(String)) }
attr_accessor :shipping_rate
sig { params(shipping_rate: T.nilable(String)).void }
def initialize(shipping_rate: nil); end
end
# The integer amount in cents (or local equivalent) representing the total amount of the credit note.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# The integer amount in cents (or local equivalent) representing the amount to credit the customer's balance, which will be automatically applied to their next invoice.
sig { returns(T.nilable(Integer)) }
attr_accessor :credit_amount
# The date when this credit note is in effect. Same as `created` unless overwritten. When defined, this value replaces the system-generated 'Date of issue' printed on the credit note PDF.
sig { returns(T.nilable(Integer)) }
attr_accessor :effective_at
# Type of email to send to the customer, one of `credit_note` or `none` and the default is `credit_note`.
sig { returns(T.nilable(String)) }
attr_accessor :email_type
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# ID of the invoice.
sig { returns(String) }
attr_accessor :invoice
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Line items that make up the credit note.
sig {
returns(T.nilable(T::Array[::Stripe::CreditNotePreviewLinesService::ListParams::Line]))
}
attr_accessor :lines
# The credit note's memo appears on the credit note PDF.
sig { returns(T.nilable(String)) }
attr_accessor :memo
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The integer amount in cents (or local equivalent) representing the amount that is credited outside of Stripe.
sig { returns(T.nilable(Integer)) }
attr_accessor :out_of_band_amount
# Reason for issuing this credit note, one of `duplicate`, `fraudulent`, `order_change`, or `product_unsatisfactory`
sig { returns(T.nilable(String)) }
attr_accessor :reason
# The integer amount in cents (or local equivalent) representing the amount to refund. If set, a refund will be created for the charge associated with the invoice.
sig { returns(T.nilable(Integer)) }
attr_accessor :refund_amount
# Refunds to link to this credit note.
sig {
returns(T.nilable(T::Array[::Stripe::CreditNotePreviewLinesService::ListParams::Refund]))
}
attr_accessor :refunds
# When shipping_cost contains the shipping_rate from the invoice, the shipping_cost is included in the credit note.
sig { returns(T.nilable(::Stripe::CreditNotePreviewLinesService::ListParams::ShippingCost)) }
attr_accessor :shipping_cost
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(amount: T.nilable(Integer), credit_amount: T.nilable(Integer), effective_at: T.nilable(Integer), email_type: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), invoice: String, limit: T.nilable(Integer), lines: T.nilable(T::Array[::Stripe::CreditNotePreviewLinesService::ListParams::Line]), memo: T.nilable(String), metadata: T.nilable(T::Hash[String, String]), out_of_band_amount: T.nilable(Integer), reason: T.nilable(String), refund_amount: T.nilable(Integer), refunds: T.nilable(T::Array[::Stripe::CreditNotePreviewLinesService::ListParams::Refund]), shipping_cost: T.nilable(::Stripe::CreditNotePreviewLinesService::ListParams::ShippingCost), starting_after: T.nilable(String)).void
}
def initialize(
amount: nil,
credit_amount: nil,
effective_at: nil,
email_type: nil,
ending_before: nil,
expand: nil,
invoice: nil,
limit: nil,
lines: nil,
memo: nil,
metadata: nil,
out_of_band_amount: nil,
reason: nil,
refund_amount: nil,
refunds: nil,
shipping_cost: nil,
starting_after: nil
); end
end
# When retrieving a credit note preview, you'll get a lines property containing the first handful of those items. This URL you can retrieve the full (paginated) list of line items.
sig {
params(params: T.any(::Stripe::CreditNotePreviewLinesService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class CustomerService < StripeService
attr_reader :cash_balance
attr_reader :balance_transactions
attr_reader :cash_balance_transactions
attr_reader :payment_sources
attr_reader :tax_ids
attr_reader :payment_methods
attr_reader :funding_instructions
class DeleteParams < Stripe::RequestParams; end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# A freeform text field for the country. However, in order to activate some tax features, the format should be a two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class CashBalance < Stripe::RequestParams
class Settings < Stripe::RequestParams
# Controls how funds transferred by the customer are applied to payment intents and invoices. Valid options are `automatic`, `manual`, or `merchant_default`. For more information about these reconciliation modes, see [Reconciliation](https://stripe.com/docs/payments/customer-balance/reconciliation).
sig { returns(T.nilable(String)) }
attr_accessor :reconciliation_mode
sig { params(reconciliation_mode: T.nilable(String)).void }
def initialize(reconciliation_mode: nil); end
end
# Settings controlling the behavior of the customer's cash balance,
# such as reconciliation of funds received.
sig { returns(T.nilable(::Stripe::CustomerService::UpdateParams::CashBalance::Settings)) }
attr_accessor :settings
sig {
params(settings: T.nilable(::Stripe::CustomerService::UpdateParams::CashBalance::Settings)).void
}
def initialize(settings: nil); end
end
class InvoiceSettings < Stripe::RequestParams
class CustomField < Stripe::RequestParams
# The name of the custom field. This may be up to 40 characters.
sig { returns(String) }
attr_accessor :name
# The value of the custom field. This may be up to 140 characters.
sig { returns(String) }
attr_accessor :value
sig { params(name: String, value: String).void }
def initialize(name: nil, value: nil); end
end
class RenderingOptions < Stripe::RequestParams
# How line-item prices and amounts will be displayed with respect to tax on invoice PDFs. One of `exclude_tax` or `include_inclusive_tax`. `include_inclusive_tax` will include inclusive tax (and exclude exclusive tax) in invoice PDF amounts. `exclude_tax` will exclude all tax (inclusive and exclusive alike) from invoice PDF amounts.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :amount_tax_display
# ID of the invoice rendering template to use for future invoices.
sig { returns(T.nilable(String)) }
attr_accessor :template
sig {
params(amount_tax_display: T.nilable(T.nilable(T.any(String, String))), template: T.nilable(String)).void
}
def initialize(amount_tax_display: nil, template: nil); end
end
# The list of up to 4 default custom fields to be displayed on invoices for this customer. When updating, pass an empty string to remove previously-defined fields.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::CustomerService::UpdateParams::InvoiceSettings::CustomField]))))
}
attr_accessor :custom_fields
# ID of a payment method that's attached to the customer, to be used as the customer's default payment method for subscriptions and invoices.
sig { returns(T.nilable(String)) }
attr_accessor :default_payment_method
# Default footer to be displayed on invoices for this customer.
sig { returns(T.nilable(String)) }
attr_accessor :footer
# Default options for invoice PDF rendering for this customer.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::CustomerService::UpdateParams::InvoiceSettings::RenderingOptions))))
}
attr_accessor :rendering_options
sig {
params(custom_fields: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::CustomerService::UpdateParams::InvoiceSettings::CustomField]))), default_payment_method: T.nilable(String), footer: T.nilable(String), rendering_options: T.nilable(T.nilable(T.any(String, ::Stripe::CustomerService::UpdateParams::InvoiceSettings::RenderingOptions)))).void
}
def initialize(
custom_fields: nil,
default_payment_method: nil,
footer: nil,
rendering_options: nil
); end
end
class Shipping < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# A freeform text field for the country. However, in order to activate some tax features, the format should be a two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Customer shipping address.
sig { returns(::Stripe::CustomerService::UpdateParams::Shipping::Address) }
attr_accessor :address
# Customer name.
sig { returns(String) }
attr_accessor :name
# Customer phone (including extension).
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(address: ::Stripe::CustomerService::UpdateParams::Shipping::Address, name: String, phone: T.nilable(String)).void
}
def initialize(address: nil, name: nil, phone: nil); end
end
class Tax < Stripe::RequestParams
# 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.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :ip_address
# A flag that indicates when Stripe should validate the customer tax location. Defaults to `auto`.
sig { returns(T.nilable(String)) }
attr_accessor :validate_location
sig {
params(ip_address: T.nilable(T.nilable(String)), validate_location: T.nilable(String)).void
}
def initialize(ip_address: nil, validate_location: nil); end
end
# The customer's address.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::CustomerService::UpdateParams::Address))))
}
attr_accessor :address
# An integer amount in cents (or local equivalent) that represents the customer's current balance, which affect the customer's future invoices. A negative amount represents a credit that decreases the amount due on an invoice; a positive amount increases the amount due on an invoice.
sig { returns(T.nilable(Integer)) }
attr_accessor :balance
# Balance information and default balance settings for this customer.
sig { returns(T.nilable(::Stripe::CustomerService::UpdateParams::CashBalance)) }
attr_accessor :cash_balance
# If you are using payment methods created via the PaymentMethods API, see the [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/update#update_customer-invoice_settings-default_payment_method) parameter.
#
# Provide the ID of a payment source already attached to this customer to make it this customer's default payment source.
#
# If you want to add a new payment source and make it the default, see the [source](https://stripe.com/docs/api/customers/update#update_customer-source) property.
sig { returns(T.nilable(String)) }
attr_accessor :default_source
# An arbitrary string that you can attach to a customer object. It is displayed alongside the customer in the dashboard.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Customer's email address. It's displayed alongside the customer in your dashboard and can be useful for searching and tracking. This may be up to *512 characters*.
sig { returns(T.nilable(String)) }
attr_accessor :email
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The prefix for the customer used to generate unique invoice numbers. Must be 3–12 uppercase letters or numbers.
sig { returns(T.nilable(String)) }
attr_accessor :invoice_prefix
# Default invoice settings for this customer.
sig { returns(T.nilable(::Stripe::CustomerService::UpdateParams::InvoiceSettings)) }
attr_accessor :invoice_settings
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# The customer's full name or business name.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The sequence to be used on the customer's next invoice. Defaults to 1.
sig { returns(T.nilable(Integer)) }
attr_accessor :next_invoice_sequence
# The customer's phone number.
sig { returns(T.nilable(String)) }
attr_accessor :phone
# Customer's preferred languages, ordered by preference.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :preferred_locales
# The customer's shipping information. Appears on invoices emailed to this customer.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::CustomerService::UpdateParams::Shipping))))
}
attr_accessor :shipping
# Attribute for param field source
sig { returns(T.nilable(String)) }
attr_accessor :source
# Tax details about the customer.
sig { returns(T.nilable(::Stripe::CustomerService::UpdateParams::Tax)) }
attr_accessor :tax
# The customer's tax exemption. One of `none`, `exempt`, or `reverse`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :tax_exempt
# Attribute for param field validate
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :validate
sig {
params(address: T.nilable(T.nilable(T.any(String, ::Stripe::CustomerService::UpdateParams::Address))), balance: T.nilable(Integer), cash_balance: T.nilable(::Stripe::CustomerService::UpdateParams::CashBalance), default_source: T.nilable(String), description: T.nilable(String), email: T.nilable(String), expand: T.nilable(T::Array[String]), invoice_prefix: T.nilable(String), invoice_settings: T.nilable(::Stripe::CustomerService::UpdateParams::InvoiceSettings), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), name: T.nilable(String), next_invoice_sequence: T.nilable(Integer), phone: T.nilable(String), preferred_locales: T.nilable(T::Array[String]), shipping: T.nilable(T.nilable(T.any(String, ::Stripe::CustomerService::UpdateParams::Shipping))), source: T.nilable(String), tax: T.nilable(::Stripe::CustomerService::UpdateParams::Tax), tax_exempt: T.nilable(T.nilable(T.any(String, String))), validate: T.nilable(T::Boolean)).void
}
def initialize(
address: nil,
balance: nil,
cash_balance: nil,
default_source: nil,
description: nil,
email: nil,
expand: nil,
invoice_prefix: nil,
invoice_settings: nil,
metadata: nil,
name: nil,
next_invoice_sequence: nil,
phone: nil,
preferred_locales: nil,
shipping: nil,
source: nil,
tax: nil,
tax_exempt: nil,
validate: nil
); end
end
class DeleteDiscountParams < Stripe::RequestParams; end
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return customers that were created during the given date interval.
sig { returns(T.nilable(T.any(::Stripe::CustomerService::ListParams::Created, Integer))) }
attr_accessor :created
# A case-sensitive filter on the list based on the customer's `email` field. The value must be a string.
sig { returns(T.nilable(String)) }
attr_accessor :email
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Provides a list of customers that are associated with the specified test clock. The response will not include customers with test clocks if this parameter is not set.
sig { returns(T.nilable(String)) }
attr_accessor :test_clock
sig {
params(created: T.nilable(T.any(::Stripe::CustomerService::ListParams::Created, Integer)), email: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String), test_clock: T.nilable(String)).void
}
def initialize(
created: nil,
email: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil,
test_clock: nil
); end
end
class CreateParams < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# A freeform text field for the country. However, in order to activate some tax features, the format should be a two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class CashBalance < Stripe::RequestParams
class Settings < Stripe::RequestParams
# Controls how funds transferred by the customer are applied to payment intents and invoices. Valid options are `automatic`, `manual`, or `merchant_default`. For more information about these reconciliation modes, see [Reconciliation](https://stripe.com/docs/payments/customer-balance/reconciliation).
sig { returns(T.nilable(String)) }
attr_accessor :reconciliation_mode
sig { params(reconciliation_mode: T.nilable(String)).void }
def initialize(reconciliation_mode: nil); end
end
# Settings controlling the behavior of the customer's cash balance,
# such as reconciliation of funds received.
sig { returns(T.nilable(::Stripe::CustomerService::CreateParams::CashBalance::Settings)) }
attr_accessor :settings
sig {
params(settings: T.nilable(::Stripe::CustomerService::CreateParams::CashBalance::Settings)).void
}
def initialize(settings: nil); end
end
class InvoiceSettings < Stripe::RequestParams
class CustomField < Stripe::RequestParams
# The name of the custom field. This may be up to 40 characters.
sig { returns(String) }
attr_accessor :name
# The value of the custom field. This may be up to 140 characters.
sig { returns(String) }
attr_accessor :value
sig { params(name: String, value: String).void }
def initialize(name: nil, value: nil); end
end
class RenderingOptions < Stripe::RequestParams
# How line-item prices and amounts will be displayed with respect to tax on invoice PDFs. One of `exclude_tax` or `include_inclusive_tax`. `include_inclusive_tax` will include inclusive tax (and exclude exclusive tax) in invoice PDF amounts. `exclude_tax` will exclude all tax (inclusive and exclusive alike) from invoice PDF amounts.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :amount_tax_display
# ID of the invoice rendering template to use for future invoices.
sig { returns(T.nilable(String)) }
attr_accessor :template
sig {
params(amount_tax_display: T.nilable(T.nilable(T.any(String, String))), template: T.nilable(String)).void
}
def initialize(amount_tax_display: nil, template: nil); end
end
# The list of up to 4 default custom fields to be displayed on invoices for this customer. When updating, pass an empty string to remove previously-defined fields.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::CustomerService::CreateParams::InvoiceSettings::CustomField]))))
}
attr_accessor :custom_fields
# ID of a payment method that's attached to the customer, to be used as the customer's default payment method for subscriptions and invoices.
sig { returns(T.nilable(String)) }
attr_accessor :default_payment_method
# Default footer to be displayed on invoices for this customer.
sig { returns(T.nilable(String)) }
attr_accessor :footer
# Default options for invoice PDF rendering for this customer.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::CustomerService::CreateParams::InvoiceSettings::RenderingOptions))))
}
attr_accessor :rendering_options
sig {
params(custom_fields: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::CustomerService::CreateParams::InvoiceSettings::CustomField]))), default_payment_method: T.nilable(String), footer: T.nilable(String), rendering_options: T.nilable(T.nilable(T.any(String, ::Stripe::CustomerService::CreateParams::InvoiceSettings::RenderingOptions)))).void
}
def initialize(
custom_fields: nil,
default_payment_method: nil,
footer: nil,
rendering_options: nil
); end
end
class Shipping < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# A freeform text field for the country. However, in order to activate some tax features, the format should be a two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Customer shipping address.
sig { returns(::Stripe::CustomerService::CreateParams::Shipping::Address) }
attr_accessor :address
# Customer name.
sig { returns(String) }
attr_accessor :name
# Customer phone (including extension).
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(address: ::Stripe::CustomerService::CreateParams::Shipping::Address, name: String, phone: T.nilable(String)).void
}
def initialize(address: nil, name: nil, phone: nil); end
end
class Tax < Stripe::RequestParams
# 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.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :ip_address
# A flag that indicates when Stripe should validate the customer tax location. Defaults to `deferred`.
sig { returns(T.nilable(String)) }
attr_accessor :validate_location
sig {
params(ip_address: T.nilable(T.nilable(String)), validate_location: T.nilable(String)).void
}
def initialize(ip_address: nil, validate_location: nil); end
end
class TaxIdDatum < Stripe::RequestParams
# Type of the tax ID, one of `ad_nrt`, `ae_trn`, `al_tin`, `am_tin`, `ao_tin`, `ar_cuit`, `au_abn`, `au_arn`, `aw_tin`, `az_tin`, `ba_tin`, `bb_tin`, `bd_bin`, `bf_ifu`, `bg_uic`, `bh_vat`, `bj_ifu`, `bo_tin`, `br_cnpj`, `br_cpf`, `bs_tin`, `by_tin`, `ca_bn`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `ca_qst`, `cd_nif`, `ch_uid`, `ch_vat`, `cl_tin`, `cm_niu`, `cn_tin`, `co_nit`, `cr_tin`, `cv_nif`, `de_stn`, `do_rcn`, `ec_ruc`, `eg_tin`, `es_cif`, `et_tin`, `eu_oss_vat`, `eu_vat`, `gb_vat`, `ge_vat`, `gn_nif`, `hk_br`, `hr_oib`, `hu_tin`, `id_npwp`, `il_vat`, `in_gst`, `is_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `ke_pin`, `kg_tin`, `kh_tin`, `kr_brn`, `kz_bin`, `la_tin`, `li_uid`, `li_vat`, `ma_vat`, `md_vat`, `me_pib`, `mk_vat`, `mr_nif`, `mx_rfc`, `my_frp`, `my_itn`, `my_sst`, `ng_tin`, `no_vat`, `no_voec`, `np_pan`, `nz_gst`, `om_vat`, `pe_ruc`, `ph_tin`, `ro_tin`, `rs_pib`, `ru_inn`, `ru_kpp`, `sa_vat`, `sg_gst`, `sg_uen`, `si_tin`, `sn_ninea`, `sr_fin`, `sv_nit`, `th_vat`, `tj_tin`, `tr_tin`, `tw_vat`, `tz_vat`, `ua_vat`, `ug_tin`, `us_ein`, `uy_ruc`, `uz_tin`, `uz_vat`, `ve_rif`, `vn_tin`, `za_vat`, `zm_tin`, or `zw_tin`
sig { returns(String) }
attr_accessor :type
# Value of the tax ID.
sig { returns(String) }
attr_accessor :value
sig { params(type: String, value: String).void }
def initialize(type: nil, value: nil); end
end
# The customer's address.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::CustomerService::CreateParams::Address))))
}
attr_accessor :address
# An integer amount in cents (or local equivalent) that represents the customer's current balance, which affect the customer's future invoices. A negative amount represents a credit that decreases the amount due on an invoice; a positive amount increases the amount due on an invoice.
sig { returns(T.nilable(Integer)) }
attr_accessor :balance
# Balance information and default balance settings for this customer.
sig { returns(T.nilable(::Stripe::CustomerService::CreateParams::CashBalance)) }
attr_accessor :cash_balance
# An arbitrary string that you can attach to a customer object. It is displayed alongside the customer in the dashboard.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Customer's email address. It's displayed alongside the customer in your dashboard and can be useful for searching and tracking. This may be up to *512 characters*.
sig { returns(T.nilable(String)) }
attr_accessor :email
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The prefix for the customer used to generate unique invoice numbers. Must be 3–12 uppercase letters or numbers.
sig { returns(T.nilable(String)) }
attr_accessor :invoice_prefix
# Default invoice settings for this customer.
sig { returns(T.nilable(::Stripe::CustomerService::CreateParams::InvoiceSettings)) }
attr_accessor :invoice_settings
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# The customer's full name or business name.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The sequence to be used on the customer's next invoice. Defaults to 1.
sig { returns(T.nilable(Integer)) }
attr_accessor :next_invoice_sequence
# Attribute for param field payment_method
sig { returns(T.nilable(String)) }
attr_accessor :payment_method
# The customer's phone number.
sig { returns(T.nilable(String)) }
attr_accessor :phone
# Customer's preferred languages, ordered by preference.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :preferred_locales
# The customer's shipping information. Appears on invoices emailed to this customer.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::CustomerService::CreateParams::Shipping))))
}
attr_accessor :shipping
# Attribute for param field source
sig { returns(T.nilable(String)) }
attr_accessor :source
# Tax details about the customer.
sig { returns(T.nilable(::Stripe::CustomerService::CreateParams::Tax)) }
attr_accessor :tax
# The customer's tax exemption. One of `none`, `exempt`, or `reverse`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :tax_exempt
# The customer's tax IDs.
sig { returns(T.nilable(T::Array[::Stripe::CustomerService::CreateParams::TaxIdDatum])) }
attr_accessor :tax_id_data
# ID of the test clock to attach to the customer.
sig { returns(T.nilable(String)) }
attr_accessor :test_clock
# Attribute for param field validate
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :validate
sig {
params(address: T.nilable(T.nilable(T.any(String, ::Stripe::CustomerService::CreateParams::Address))), balance: T.nilable(Integer), cash_balance: T.nilable(::Stripe::CustomerService::CreateParams::CashBalance), description: T.nilable(String), email: T.nilable(String), expand: T.nilable(T::Array[String]), invoice_prefix: T.nilable(String), invoice_settings: T.nilable(::Stripe::CustomerService::CreateParams::InvoiceSettings), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), name: T.nilable(String), next_invoice_sequence: T.nilable(Integer), payment_method: T.nilable(String), phone: T.nilable(String), preferred_locales: T.nilable(T::Array[String]), shipping: T.nilable(T.nilable(T.any(String, ::Stripe::CustomerService::CreateParams::Shipping))), source: T.nilable(String), tax: T.nilable(::Stripe::CustomerService::CreateParams::Tax), tax_exempt: T.nilable(T.nilable(T.any(String, String))), tax_id_data: T.nilable(T::Array[::Stripe::CustomerService::CreateParams::TaxIdDatum]), test_clock: T.nilable(String), validate: T.nilable(T::Boolean)).void
}
def initialize(
address: nil,
balance: nil,
cash_balance: nil,
description: nil,
email: nil,
expand: nil,
invoice_prefix: nil,
invoice_settings: nil,
metadata: nil,
name: nil,
next_invoice_sequence: nil,
payment_method: nil,
phone: nil,
preferred_locales: nil,
shipping: nil,
source: nil,
tax: nil,
tax_exempt: nil,
tax_id_data: nil,
test_clock: nil,
validate: nil
); end
end
class SearchParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for pagination across multiple pages of results. Don't include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.
sig { returns(T.nilable(String)) }
attr_accessor :page
# The search query string. See [search query language](https://stripe.com/docs/search#search-query-language) and the list of supported [query fields for customers](https://stripe.com/docs/search#query-fields-for-customers).
sig { returns(String) }
attr_accessor :query
sig {
params(expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), page: T.nilable(String), query: String).void
}
def initialize(expand: nil, limit: nil, page: nil, query: nil); end
end
# Creates a new customer object.
sig {
params(params: T.any(::Stripe::CustomerService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Customer)
}
def create(params = {}, opts = {}); end
# Permanently deletes a customer. It cannot be undone. Also immediately cancels any active subscriptions on the customer.
sig {
params(customer: String, params: T.any(::Stripe::CustomerService::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Customer)
}
def delete(customer, params = {}, opts = {}); end
# Removes the currently applied discount on a customer.
sig {
params(customer: String, params: T.any(::Stripe::CustomerService::DeleteDiscountParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Discount)
}
def delete_discount(customer, params = {}, opts = {}); end
# Returns a list of your customers. The customers are returned sorted by creation date, with the most recent customers appearing first.
sig {
params(params: T.any(::Stripe::CustomerService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves a Customer object.
sig {
params(customer: String, params: T.any(::Stripe::CustomerService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Customer)
}
def retrieve(customer, params = {}, opts = {}); end
# Search for customers you've previously created using Stripe's [Search Query Language](https://docs.stripe.com/docs/search#search-query-language).
# Don't use search in read-after-write flows where strict consistency is necessary. Under normal operating
# conditions, data is searchable in less than a minute. Occasionally, propagation of new or updated data can be up
# to an hour behind during outages. Search functionality is not available to merchants in India.
sig {
params(params: T.any(::Stripe::CustomerService::SearchParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SearchResultObject)
}
def search(params = {}, opts = {}); end
# Updates the specified customer by setting the values of the parameters passed. Any parameters not provided will be left unchanged. For example, if you pass the source parameter, that becomes the customer's active source (e.g., a card) to be used for all charges in the future. When you update a customer to a new valid card source by passing the source parameter: for each of the customer's current subscriptions, if the subscription bills automatically and is in the past_due state, then the latest open invoice for the subscription with automatic collection enabled will be retried. This retry will not count as an automatic retry, and will not affect the next regularly scheduled payment for the invoice. Changing the default_source for a customer will not trigger this behavior.
#
# This request accepts mostly the same arguments as the customer creation call.
sig {
params(customer: String, params: T.any(::Stripe::CustomerService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Customer)
}
def update(customer, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class CustomerCashBalanceService < StripeService
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
class Settings < Stripe::RequestParams
# Controls how funds transferred by the customer are applied to payment intents and invoices. Valid options are `automatic`, `manual`, or `merchant_default`. For more information about these reconciliation modes, see [Reconciliation](https://stripe.com/docs/payments/customer-balance/reconciliation).
sig { returns(T.nilable(String)) }
attr_accessor :reconciliation_mode
sig { params(reconciliation_mode: T.nilable(String)).void }
def initialize(reconciliation_mode: nil); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A hash of settings for this cash balance.
sig { returns(T.nilable(::Stripe::CustomerCashBalanceService::UpdateParams::Settings)) }
attr_accessor :settings
sig {
params(expand: T.nilable(T::Array[String]), settings: T.nilable(::Stripe::CustomerCashBalanceService::UpdateParams::Settings)).void
}
def initialize(expand: nil, settings: nil); end
end
# Retrieves a customer's cash balance.
sig {
params(customer: String, params: T.any(::Stripe::CustomerCashBalanceService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::CashBalance)
}
def retrieve(customer, params = {}, opts = {}); end
# Changes the settings on a customer's cash balance.
sig {
params(customer: String, params: T.any(::Stripe::CustomerCashBalanceService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::CashBalance)
}
def update(customer, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class CustomerBalanceTransactionService < StripeService
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
class CreateParams < Stripe::RequestParams
# The integer amount in **cents (or local equivalent)** to apply to the customer's credit balance.
sig { returns(Integer) }
attr_accessor :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). Specifies the [`invoice_credit_balance`](https://stripe.com/docs/api/customers/object#customer_object-invoice_credit_balance) that this transaction will apply to. If the customer's `currency` is not set, it will be updated to this value.
sig { returns(String) }
attr_accessor :currency
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
sig {
params(amount: Integer, currency: String, description: T.nilable(String), expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String])))).void
}
def initialize(amount: nil, currency: nil, description: nil, expand: nil, metadata: nil); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
sig {
params(description: T.nilable(String), expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String])))).void
}
def initialize(description: nil, expand: nil, metadata: nil); end
end
# Creates an immutable transaction that updates the customer's credit [balance](https://docs.stripe.com/docs/billing/customer/balance).
sig {
params(customer: String, params: T.any(::Stripe::CustomerBalanceTransactionService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::CustomerBalanceTransaction)
}
def create(customer, params = {}, opts = {}); end
# Returns a list of transactions that updated the customer's [balances](https://docs.stripe.com/docs/billing/customer/balance).
sig {
params(customer: String, params: T.any(::Stripe::CustomerBalanceTransactionService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(customer, params = {}, opts = {}); end
# Retrieves a specific customer balance transaction that updated the customer's [balances](https://docs.stripe.com/docs/billing/customer/balance).
sig {
params(customer: String, transaction: String, params: T.any(::Stripe::CustomerBalanceTransactionService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::CustomerBalanceTransaction)
}
def retrieve(customer, transaction, params = {}, opts = {}); end
# Most credit balance transaction fields are immutable, but you may update its description and metadata.
sig {
params(customer: String, transaction: String, params: T.any(::Stripe::CustomerBalanceTransactionService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::CustomerBalanceTransaction)
}
def update(customer, transaction, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class CustomerCashBalanceTransactionService < StripeService
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Returns a list of transactions that modified the customer's [cash balance](https://docs.stripe.com/docs/payments/customer-balance).
sig {
params(customer: String, params: T.any(::Stripe::CustomerCashBalanceTransactionService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(customer, params = {}, opts = {}); end
# Retrieves a specific cash balance transaction, which updated the customer's [cash balance](https://docs.stripe.com/docs/payments/customer-balance).
sig {
params(customer: String, transaction: String, params: T.any(::Stripe::CustomerCashBalanceTransactionService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::CustomerCashBalanceTransaction)
}
def retrieve(customer, transaction, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class CustomerPaymentSourceService < StripeService
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Filter sources according to a particular object type.
sig { returns(T.nilable(String)) }
attr_accessor :object
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), object: T.nilable(String), starting_after: T.nilable(String)).void
}
def initialize(
ending_before: nil,
expand: nil,
limit: nil,
object: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Please refer to full [documentation](https://stripe.com/docs/api) instead.
sig { returns(String) }
attr_accessor :source
# Attribute for param field validate
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :validate
sig {
params(expand: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), source: String, validate: T.nilable(T::Boolean)).void
}
def initialize(expand: nil, metadata: nil, source: nil, validate: nil); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
class Owner < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Owner's address.
sig {
returns(T.nilable(::Stripe::CustomerPaymentSourceService::UpdateParams::Owner::Address))
}
attr_accessor :address
# Owner's email address.
sig { returns(T.nilable(String)) }
attr_accessor :email
# Owner's full name.
sig { returns(T.nilable(String)) }
attr_accessor :name
# Owner's phone number.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(address: T.nilable(::Stripe::CustomerPaymentSourceService::UpdateParams::Owner::Address), email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(address: nil, email: nil, name: nil, phone: nil); end
end
# The name of the person or business that owns the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_name
# The type of entity that holds the account. This can be either `individual` or `company`.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_type
# City/District/Suburb/Town/Village.
sig { returns(T.nilable(String)) }
attr_accessor :address_city
# Billing address country, if provided when creating card.
sig { returns(T.nilable(String)) }
attr_accessor :address_country
# Address line 1 (Street address/PO Box/Company name).
sig { returns(T.nilable(String)) }
attr_accessor :address_line1
# Address line 2 (Apartment/Suite/Unit/Building).
sig { returns(T.nilable(String)) }
attr_accessor :address_line2
# State/County/Province/Region.
sig { returns(T.nilable(String)) }
attr_accessor :address_state
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :address_zip
# Two digit number representing the card’s expiration month.
sig { returns(T.nilable(String)) }
attr_accessor :exp_month
# Four digit number representing the card’s expiration year.
sig { returns(T.nilable(String)) }
attr_accessor :exp_year
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Cardholder name.
sig { returns(T.nilable(String)) }
attr_accessor :name
# Attribute for param field owner
sig { returns(T.nilable(::Stripe::CustomerPaymentSourceService::UpdateParams::Owner)) }
attr_accessor :owner
sig {
params(account_holder_name: T.nilable(String), account_holder_type: T.nilable(String), address_city: T.nilable(String), address_country: T.nilable(String), address_line1: T.nilable(String), address_line2: T.nilable(String), address_state: T.nilable(String), address_zip: T.nilable(String), exp_month: T.nilable(String), exp_year: T.nilable(String), expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), name: T.nilable(String), owner: T.nilable(::Stripe::CustomerPaymentSourceService::UpdateParams::Owner)).void
}
def initialize(
account_holder_name: nil,
account_holder_type: nil,
address_city: nil,
address_country: nil,
address_line1: nil,
address_line2: nil,
address_state: nil,
address_zip: nil,
exp_month: nil,
exp_year: nil,
expand: nil,
metadata: nil,
name: nil,
owner: nil
); end
end
class DeleteParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class VerifyParams < Stripe::RequestParams
# Two positive integers, in *cents*, equal to the values of the microdeposits sent to the bank account.
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :amounts
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig {
params(amounts: T.nilable(T::Array[Integer]), expand: T.nilable(T::Array[String])).void
}
def initialize(amounts: nil, expand: nil); end
end
# When you create a new credit card, you must specify a customer or recipient on which to create it.
#
# If the card's owner has no default card, then the new card will become the default.
# However, if the owner already has a default, then it will not change.
# To change the default, you should [update the customer](https://docs.stripe.com/docs/api#update_customer) to have a new default_source.
sig {
params(customer: String, params: T.any(::Stripe::CustomerPaymentSourceService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(T.any(Stripe::Account, Stripe::BankAccount, Stripe::Card, Stripe::Source))
}
def create(customer, params = {}, opts = {}); end
# Delete a specified source for a given customer.
sig {
params(customer: String, id: String, params: T.any(::Stripe::CustomerPaymentSourceService::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(T.any(Stripe::Account, Stripe::BankAccount, Stripe::Card, Stripe::Source))
}
def delete(customer, id, params = {}, opts = {}); end
# List sources for a specified customer.
sig {
params(customer: String, params: T.any(::Stripe::CustomerPaymentSourceService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(customer, params = {}, opts = {}); end
# Retrieve a specified source for a given customer.
sig {
params(customer: String, id: String, params: T.any(::Stripe::CustomerPaymentSourceService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(T.any(Stripe::Account, Stripe::BankAccount, Stripe::Card, Stripe::Source))
}
def retrieve(customer, id, params = {}, opts = {}); end
# Update a specified source for a given customer.
sig {
params(customer: String, id: String, params: T.any(::Stripe::CustomerPaymentSourceService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(T.any(Stripe::Account, Stripe::BankAccount, Stripe::Card, Stripe::Source))
}
def update(customer, id, params = {}, opts = {}); end
# Verify a specified bank account for a given customer.
sig {
params(customer: String, id: String, params: T.any(::Stripe::CustomerPaymentSourceService::VerifyParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::BankAccount)
}
def verify(customer, id, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class CustomerTaxIdService < StripeService
class DeleteParams < Stripe::RequestParams; end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
class CreateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Type of the tax ID, one of `ad_nrt`, `ae_trn`, `al_tin`, `am_tin`, `ao_tin`, `ar_cuit`, `au_abn`, `au_arn`, `aw_tin`, `az_tin`, `ba_tin`, `bb_tin`, `bd_bin`, `bf_ifu`, `bg_uic`, `bh_vat`, `bj_ifu`, `bo_tin`, `br_cnpj`, `br_cpf`, `bs_tin`, `by_tin`, `ca_bn`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `ca_qst`, `cd_nif`, `ch_uid`, `ch_vat`, `cl_tin`, `cm_niu`, `cn_tin`, `co_nit`, `cr_tin`, `cv_nif`, `de_stn`, `do_rcn`, `ec_ruc`, `eg_tin`, `es_cif`, `et_tin`, `eu_oss_vat`, `eu_vat`, `gb_vat`, `ge_vat`, `gn_nif`, `hk_br`, `hr_oib`, `hu_tin`, `id_npwp`, `il_vat`, `in_gst`, `is_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `ke_pin`, `kg_tin`, `kh_tin`, `kr_brn`, `kz_bin`, `la_tin`, `li_uid`, `li_vat`, `ma_vat`, `md_vat`, `me_pib`, `mk_vat`, `mr_nif`, `mx_rfc`, `my_frp`, `my_itn`, `my_sst`, `ng_tin`, `no_vat`, `no_voec`, `np_pan`, `nz_gst`, `om_vat`, `pe_ruc`, `ph_tin`, `ro_tin`, `rs_pib`, `ru_inn`, `ru_kpp`, `sa_vat`, `sg_gst`, `sg_uen`, `si_tin`, `sn_ninea`, `sr_fin`, `sv_nit`, `th_vat`, `tj_tin`, `tr_tin`, `tw_vat`, `tz_vat`, `ua_vat`, `ug_tin`, `us_ein`, `uy_ruc`, `uz_tin`, `uz_vat`, `ve_rif`, `vn_tin`, `za_vat`, `zm_tin`, or `zw_tin`
sig { returns(String) }
attr_accessor :type
# Value of the tax ID.
sig { returns(String) }
attr_accessor :value
sig { params(expand: T.nilable(T::Array[String]), type: String, value: String).void }
def initialize(expand: nil, type: nil, value: nil); end
end
# Creates a new tax_id object for a customer.
sig {
params(customer: String, params: T.any(::Stripe::CustomerTaxIdService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::TaxId)
}
def create(customer, params = {}, opts = {}); end
# Deletes an existing tax_id object.
sig {
params(customer: String, id: String, params: T.any(::Stripe::CustomerTaxIdService::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::TaxId)
}
def delete(customer, id, params = {}, opts = {}); end
# Returns a list of tax IDs for a customer.
sig {
params(customer: String, params: T.any(::Stripe::CustomerTaxIdService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(customer, params = {}, opts = {}); end
# Retrieves the tax_id object with the given identifier.
sig {
params(customer: String, id: String, params: T.any(::Stripe::CustomerTaxIdService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::TaxId)
}
def retrieve(customer, id, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class CustomerPaymentMethodService < StripeService
class ListParams < Stripe::RequestParams
# This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow.
sig { returns(T.nilable(String)) }
attr_accessor :allow_redisplay
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# An optional filter on the list, based on the object `type` field. Without the filter, the list includes all current and future payment method types. If your integration expects only one type of payment method in the response, make sure to provide a type value in the request.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(allow_redisplay: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String), type: T.nilable(String)).void
}
def initialize(
allow_redisplay: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil,
type: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Returns a list of PaymentMethods for a given Customer
sig {
params(customer: String, params: T.any(::Stripe::CustomerPaymentMethodService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(customer, params = {}, opts = {}); end
# Retrieves a PaymentMethod object for a given Customer.
sig {
params(customer: String, payment_method: String, params: T.any(::Stripe::CustomerPaymentMethodService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentMethod)
}
def retrieve(customer, payment_method, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class CustomerFundingInstructionsService < StripeService
class CreateParams < Stripe::RequestParams
class BankTransfer < Stripe::RequestParams
class EuBankTransfer < Stripe::RequestParams
# The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
sig { returns(String) }
attr_accessor :country
sig { params(country: String).void }
def initialize(country: nil); end
end
# Configuration for eu_bank_transfer funding type.
sig {
returns(T.nilable(::Stripe::CustomerFundingInstructionsService::CreateParams::BankTransfer::EuBankTransfer))
}
attr_accessor :eu_bank_transfer
# List of address types that should be returned in the financial_addresses response. If not specified, all valid types will be returned.
#
# Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :requested_address_types
# The type of the `bank_transfer`
sig { returns(String) }
attr_accessor :type
sig {
params(eu_bank_transfer: T.nilable(::Stripe::CustomerFundingInstructionsService::CreateParams::BankTransfer::EuBankTransfer), requested_address_types: T.nilable(T::Array[String]), type: String).void
}
def initialize(eu_bank_transfer: nil, requested_address_types: nil, type: nil); end
end
# Additional parameters for `bank_transfer` funding types
sig { returns(::Stripe::CustomerFundingInstructionsService::CreateParams::BankTransfer) }
attr_accessor :bank_transfer
# 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).
sig { returns(String) }
attr_accessor :currency
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The `funding_type` to get the instructions for.
sig { returns(String) }
attr_accessor :funding_type
sig {
params(bank_transfer: ::Stripe::CustomerFundingInstructionsService::CreateParams::BankTransfer, currency: String, expand: T.nilable(T::Array[String]), funding_type: String).void
}
def initialize(bank_transfer: nil, currency: nil, expand: nil, funding_type: nil); end
end
# Retrieve funding instructions for a customer cash balance. If funding instructions do not yet exist for the customer, new
# funding instructions will be created. If funding instructions have already been created for a given customer, the same
# funding instructions will be retrieved. In other words, we will return the same funding instructions each time.
sig {
params(customer: String, params: T.any(::Stripe::CustomerFundingInstructionsService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::FundingInstructions)
}
def create(customer, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class CustomerSessionService < StripeService
class CreateParams < Stripe::RequestParams
class Components < Stripe::RequestParams
class BuyButton < Stripe::RequestParams
# Whether the buy button is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
sig { params(enabled: T::Boolean).void }
def initialize(enabled: nil); end
end
class PaymentElement < Stripe::RequestParams
class Features < Stripe::RequestParams
# A list of [`allow_redisplay`](https://docs.stripe.com/api/payment_methods/object#payment_method_object-allow_redisplay) values that controls which saved payment methods the Payment Element displays by filtering to only show payment methods with an `allow_redisplay` value that is present in this list.
#
# If not specified, defaults to ["always"]. In order to display all saved payment methods, specify ["always", "limited", "unspecified"].
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :payment_method_allow_redisplay_filters
# Controls whether or not the Payment Element shows saved payment methods. This parameter defaults to `disabled`.
sig { returns(T.nilable(String)) }
attr_accessor :payment_method_redisplay
# Determines the max number of saved payment methods for the Payment Element to display. This parameter defaults to `3`.
sig { returns(T.nilable(Integer)) }
attr_accessor :payment_method_redisplay_limit
# Controls whether the Payment Element displays the option to remove a saved payment method. This parameter defaults to `disabled`.
#
# Allowing buyers to remove their saved payment methods impacts subscriptions that depend on that payment method. Removing the payment method detaches the [`customer` object](https://docs.stripe.com/api/payment_methods/object#payment_method_object-customer) from that [PaymentMethod](https://docs.stripe.com/api/payment_methods).
sig { returns(T.nilable(String)) }
attr_accessor :payment_method_remove
# Controls whether the Payment Element displays a checkbox offering to save a new payment method. This parameter defaults to `disabled`.
#
# If a customer checks the box, the [`allow_redisplay`](https://docs.stripe.com/api/payment_methods/object#payment_method_object-allow_redisplay) value on the PaymentMethod is set to `'always'` at confirmation time. For PaymentIntents, the [`setup_future_usage`](https://docs.stripe.com/api/payment_intents/object#payment_intent_object-setup_future_usage) value is also set to the value defined in `payment_method_save_usage`.
sig { returns(T.nilable(String)) }
attr_accessor :payment_method_save
# When using PaymentIntents and the customer checks the save checkbox, this field determines the [`setup_future_usage`](https://docs.stripe.com/api/payment_intents/object#payment_intent_object-setup_future_usage) value used to confirm the PaymentIntent.
#
# When using SetupIntents, directly configure the [`usage`](https://docs.stripe.com/api/setup_intents/object#setup_intent_object-usage) value on SetupIntent creation.
sig { returns(T.nilable(String)) }
attr_accessor :payment_method_save_usage
sig {
params(payment_method_allow_redisplay_filters: T.nilable(T::Array[String]), payment_method_redisplay: T.nilable(String), payment_method_redisplay_limit: T.nilable(Integer), payment_method_remove: T.nilable(String), payment_method_save: T.nilable(String), payment_method_save_usage: T.nilable(String)).void
}
def initialize(
payment_method_allow_redisplay_filters: nil,
payment_method_redisplay: nil,
payment_method_redisplay_limit: nil,
payment_method_remove: nil,
payment_method_save: nil,
payment_method_save_usage: nil
); end
end
# Whether the Payment Element is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
# This hash defines whether the Payment Element supports certain features.
sig {
returns(T.nilable(::Stripe::CustomerSessionService::CreateParams::Components::PaymentElement::Features))
}
attr_accessor :features
sig {
params(enabled: T::Boolean, features: T.nilable(::Stripe::CustomerSessionService::CreateParams::Components::PaymentElement::Features)).void
}
def initialize(enabled: nil, features: nil); end
end
class PricingTable < Stripe::RequestParams
# Whether the pricing table is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
sig { params(enabled: T::Boolean).void }
def initialize(enabled: nil); end
end
# Configuration for buy button.
sig {
returns(T.nilable(::Stripe::CustomerSessionService::CreateParams::Components::BuyButton))
}
attr_accessor :buy_button
# Configuration for the Payment Element.
sig {
returns(T.nilable(::Stripe::CustomerSessionService::CreateParams::Components::PaymentElement))
}
attr_accessor :payment_element
# Configuration for the pricing table.
sig {
returns(T.nilable(::Stripe::CustomerSessionService::CreateParams::Components::PricingTable))
}
attr_accessor :pricing_table
sig {
params(buy_button: T.nilable(::Stripe::CustomerSessionService::CreateParams::Components::BuyButton), payment_element: T.nilable(::Stripe::CustomerSessionService::CreateParams::Components::PaymentElement), pricing_table: T.nilable(::Stripe::CustomerSessionService::CreateParams::Components::PricingTable)).void
}
def initialize(buy_button: nil, payment_element: nil, pricing_table: nil); end
end
# Configuration for each component. Exactly 1 component must be enabled.
sig { returns(::Stripe::CustomerSessionService::CreateParams::Components) }
attr_accessor :components
# The ID of an existing customer for which to create the Customer Session.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# The ID of an existing Account for which to create the Customer Session.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig {
params(components: ::Stripe::CustomerSessionService::CreateParams::Components, customer: T.nilable(String), customer_account: T.nilable(String), expand: T.nilable(T::Array[String])).void
}
def initialize(components: nil, customer: nil, customer_account: nil, expand: nil); end
end
# Creates a Customer Session object that includes a single-use client secret that you can use on your front-end to grant client-side API access for certain customer resources.
sig {
params(params: T.any(::Stripe::CustomerSessionService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::CustomerSession)
}
def create(params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class DisputeService < StripeService
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return disputes associated to the charge specified by this charge ID.
sig { returns(T.nilable(String)) }
attr_accessor :charge
# Only return disputes that were created during the given date interval.
sig { returns(T.nilable(T.any(::Stripe::DisputeService::ListParams::Created, Integer))) }
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Only return disputes associated to the PaymentIntent specified by this PaymentIntent ID.
sig { returns(T.nilable(String)) }
attr_accessor :payment_intent
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(charge: T.nilable(String), created: T.nilable(T.any(::Stripe::DisputeService::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), payment_intent: T.nilable(String), starting_after: T.nilable(String)).void
}
def initialize(
charge: nil,
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
payment_intent: nil,
starting_after: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
class Evidence < Stripe::RequestParams
class EnhancedEvidence < Stripe::RequestParams
class VisaCompellingEvidence3 < Stripe::RequestParams
class DisputedTransaction < Stripe::RequestParams
class ShippingAddress < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :state
sig {
params(city: T.nilable(T.nilable(String)), country: T.nilable(T.nilable(String)), line1: T.nilable(T.nilable(String)), line2: T.nilable(T.nilable(String)), postal_code: T.nilable(T.nilable(String)), state: T.nilable(T.nilable(String))).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# User Account ID used to log into business platform. Must be recognizable by the user.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :customer_account_id
# Unique identifier of the cardholder’s device derived from a combination of at least two hardware and software attributes. Must be at least 20 characters.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :customer_device_fingerprint
# Unique identifier of the cardholder’s device such as a device serial number (e.g., International Mobile Equipment Identity [IMEI]). Must be at least 15 characters.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :customer_device_id
# The email address of the customer.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :customer_email_address
# The IP address that the customer used when making the purchase.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :customer_purchase_ip
# Categorization of disputed payment.
sig { returns(T.nilable(String)) }
attr_accessor :merchandise_or_services
# A description of the product or service that was sold.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :product_description
# The address to which a physical product was shipped. All fields are required for Visa Compelling Evidence 3.0 evidence submission.
sig {
returns(T.nilable(::Stripe::DisputeService::UpdateParams::Evidence::EnhancedEvidence::VisaCompellingEvidence3::DisputedTransaction::ShippingAddress))
}
attr_accessor :shipping_address
sig {
params(customer_account_id: T.nilable(T.nilable(String)), customer_device_fingerprint: T.nilable(T.nilable(String)), customer_device_id: T.nilable(T.nilable(String)), customer_email_address: T.nilable(T.nilable(String)), customer_purchase_ip: T.nilable(T.nilable(String)), merchandise_or_services: T.nilable(String), product_description: T.nilable(T.nilable(String)), shipping_address: T.nilable(::Stripe::DisputeService::UpdateParams::Evidence::EnhancedEvidence::VisaCompellingEvidence3::DisputedTransaction::ShippingAddress)).void
}
def initialize(
customer_account_id: nil,
customer_device_fingerprint: nil,
customer_device_id: nil,
customer_email_address: nil,
customer_purchase_ip: nil,
merchandise_or_services: nil,
product_description: nil,
shipping_address: nil
); end
end
class PriorUndisputedTransaction < Stripe::RequestParams
class ShippingAddress < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :state
sig {
params(city: T.nilable(T.nilable(String)), country: T.nilable(T.nilable(String)), line1: T.nilable(T.nilable(String)), line2: T.nilable(T.nilable(String)), postal_code: T.nilable(T.nilable(String)), state: T.nilable(T.nilable(String))).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Stripe charge ID for the Visa Compelling Evidence 3.0 eligible prior charge.
sig { returns(String) }
attr_accessor :charge
# User Account ID used to log into business platform. Must be recognizable by the user.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :customer_account_id
# Unique identifier of the cardholder’s device derived from a combination of at least two hardware and software attributes. Must be at least 20 characters.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :customer_device_fingerprint
# Unique identifier of the cardholder’s device such as a device serial number (e.g., International Mobile Equipment Identity [IMEI]). Must be at least 15 characters.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :customer_device_id
# The email address of the customer.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :customer_email_address
# The IP address that the customer used when making the purchase.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :customer_purchase_ip
# A description of the product or service that was sold.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :product_description
# The address to which a physical product was shipped. All fields are required for Visa Compelling Evidence 3.0 evidence submission.
sig {
returns(T.nilable(::Stripe::DisputeService::UpdateParams::Evidence::EnhancedEvidence::VisaCompellingEvidence3::PriorUndisputedTransaction::ShippingAddress))
}
attr_accessor :shipping_address
sig {
params(charge: String, customer_account_id: T.nilable(T.nilable(String)), customer_device_fingerprint: T.nilable(T.nilable(String)), customer_device_id: T.nilable(T.nilable(String)), customer_email_address: T.nilable(T.nilable(String)), customer_purchase_ip: T.nilable(T.nilable(String)), product_description: T.nilable(T.nilable(String)), shipping_address: T.nilable(::Stripe::DisputeService::UpdateParams::Evidence::EnhancedEvidence::VisaCompellingEvidence3::PriorUndisputedTransaction::ShippingAddress)).void
}
def initialize(
charge: nil,
customer_account_id: nil,
customer_device_fingerprint: nil,
customer_device_id: nil,
customer_email_address: nil,
customer_purchase_ip: nil,
product_description: nil,
shipping_address: nil
); end
end
# Disputed transaction details for Visa Compelling Evidence 3.0 evidence submission.
sig {
returns(T.nilable(::Stripe::DisputeService::UpdateParams::Evidence::EnhancedEvidence::VisaCompellingEvidence3::DisputedTransaction))
}
attr_accessor :disputed_transaction
# List of exactly two prior undisputed transaction objects for Visa Compelling Evidence 3.0 evidence submission.
sig {
returns(T.nilable(T::Array[::Stripe::DisputeService::UpdateParams::Evidence::EnhancedEvidence::VisaCompellingEvidence3::PriorUndisputedTransaction]))
}
attr_accessor :prior_undisputed_transactions
sig {
params(disputed_transaction: T.nilable(::Stripe::DisputeService::UpdateParams::Evidence::EnhancedEvidence::VisaCompellingEvidence3::DisputedTransaction), prior_undisputed_transactions: T.nilable(T::Array[::Stripe::DisputeService::UpdateParams::Evidence::EnhancedEvidence::VisaCompellingEvidence3::PriorUndisputedTransaction])).void
}
def initialize(disputed_transaction: nil, prior_undisputed_transactions: nil); end
end
class VisaCompliance < Stripe::RequestParams
# A field acknowledging the fee incurred when countering a Visa compliance dispute. If this field is set to true, evidence can be submitted for the compliance dispute. Stripe collects a 500 USD (or local equivalent) amount to cover the network costs associated with resolving compliance disputes. Stripe refunds the 500 USD network fee if you win the dispute.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :fee_acknowledged
sig { params(fee_acknowledged: T.nilable(T::Boolean)).void }
def initialize(fee_acknowledged: nil); end
end
# Evidence provided for Visa Compelling Evidence 3.0 evidence submission.
sig {
returns(T.nilable(::Stripe::DisputeService::UpdateParams::Evidence::EnhancedEvidence::VisaCompellingEvidence3))
}
attr_accessor :visa_compelling_evidence_3
# Evidence provided for Visa compliance evidence submission.
sig {
returns(T.nilable(::Stripe::DisputeService::UpdateParams::Evidence::EnhancedEvidence::VisaCompliance))
}
attr_accessor :visa_compliance
sig {
params(visa_compelling_evidence_3: T.nilable(::Stripe::DisputeService::UpdateParams::Evidence::EnhancedEvidence::VisaCompellingEvidence3), visa_compliance: T.nilable(::Stripe::DisputeService::UpdateParams::Evidence::EnhancedEvidence::VisaCompliance)).void
}
def initialize(visa_compelling_evidence_3: nil, visa_compliance: nil); end
end
# Any server or activity logs showing proof that the customer accessed or downloaded the purchased digital product. This information should include IP addresses, corresponding timestamps, and any detailed recorded activity. Has a maximum character count of 20,000.
sig { returns(T.nilable(String)) }
attr_accessor :access_activity_log
# The billing address provided by the customer.
sig { returns(T.nilable(String)) }
attr_accessor :billing_address
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Your subscription cancellation policy, as shown to the customer.
sig { returns(T.nilable(String)) }
attr_accessor :cancellation_policy
# An explanation of how and when the customer was shown your refund policy prior to purchase. Has a maximum character count of 20,000.
sig { returns(T.nilable(String)) }
attr_accessor :cancellation_policy_disclosure
# A justification for why the customer's subscription was not canceled. Has a maximum character count of 20,000.
sig { returns(T.nilable(String)) }
attr_accessor :cancellation_rebuttal
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Any communication with the customer that you feel is relevant to your case. Examples include emails proving that the customer received the product or service, or demonstrating their use of or satisfaction with the product or service.
sig { returns(T.nilable(String)) }
attr_accessor :customer_communication
# The email address of the customer.
sig { returns(T.nilable(String)) }
attr_accessor :customer_email_address
# The name of the customer.
sig { returns(T.nilable(String)) }
attr_accessor :customer_name
# The IP address that the customer used when making the purchase.
sig { returns(T.nilable(String)) }
attr_accessor :customer_purchase_ip
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) A relevant document or contract showing the customer's signature.
sig { returns(T.nilable(String)) }
attr_accessor :customer_signature
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Documentation for the prior charge that can uniquely identify the charge, such as a receipt, shipping label, work order, etc. This document should be paired with a similar document from the disputed payment that proves the two payments are separate.
sig { returns(T.nilable(String)) }
attr_accessor :duplicate_charge_documentation
# An explanation of the difference between the disputed charge versus the prior charge that appears to be a duplicate. Has a maximum character count of 20,000.
sig { returns(T.nilable(String)) }
attr_accessor :duplicate_charge_explanation
# The Stripe ID for the prior charge which appears to be a duplicate of the disputed charge.
sig { returns(T.nilable(String)) }
attr_accessor :duplicate_charge_id
# Additional evidence for qualifying evidence programs.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::DisputeService::UpdateParams::Evidence::EnhancedEvidence))))
}
attr_accessor :enhanced_evidence
# A description of the product or service that was sold. Has a maximum character count of 20,000.
sig { returns(T.nilable(String)) }
attr_accessor :product_description
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Any receipt or message sent to the customer notifying them of the charge.
sig { returns(T.nilable(String)) }
attr_accessor :receipt
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Your refund policy, as shown to the customer.
sig { returns(T.nilable(String)) }
attr_accessor :refund_policy
# Documentation demonstrating that the customer was shown your refund policy prior to purchase. Has a maximum character count of 20,000.
sig { returns(T.nilable(String)) }
attr_accessor :refund_policy_disclosure
# A justification for why the customer is not entitled to a refund. Has a maximum character count of 20,000.
sig { returns(T.nilable(String)) }
attr_accessor :refund_refusal_explanation
# The date on which the customer received or began receiving the purchased service, in a clear human-readable format.
sig { returns(T.nilable(String)) }
attr_accessor :service_date
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Documentation showing proof that a service was provided to the customer. This could include a copy of a signed contract, work order, or other form of written agreement.
sig { returns(T.nilable(String)) }
attr_accessor :service_documentation
# The address to which a physical product was shipped. You should try to include as complete address information as possible.
sig { returns(T.nilable(String)) }
attr_accessor :shipping_address
# The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc. If multiple carriers were used for this purchase, please separate them with commas.
sig { returns(T.nilable(String)) }
attr_accessor :shipping_carrier
# The date on which a physical product began its route to the shipping address, in a clear human-readable format.
sig { returns(T.nilable(String)) }
attr_accessor :shipping_date
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Documentation showing proof that a product was shipped to the customer at the same address the customer provided to you. This could include a copy of the shipment receipt, shipping label, etc. It should show the customer's full shipping address, if possible.
sig { returns(T.nilable(String)) }
attr_accessor :shipping_documentation
# The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
sig { returns(T.nilable(String)) }
attr_accessor :shipping_tracking_number
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Any additional evidence or statements.
sig { returns(T.nilable(String)) }
attr_accessor :uncategorized_file
# Any additional evidence or statements. Has a maximum character count of 20,000.
sig { returns(T.nilable(String)) }
attr_accessor :uncategorized_text
sig {
params(access_activity_log: T.nilable(String), billing_address: T.nilable(String), cancellation_policy: T.nilable(String), cancellation_policy_disclosure: T.nilable(String), cancellation_rebuttal: T.nilable(String), customer_communication: T.nilable(String), customer_email_address: T.nilable(String), customer_name: T.nilable(String), customer_purchase_ip: T.nilable(String), customer_signature: T.nilable(String), duplicate_charge_documentation: T.nilable(String), duplicate_charge_explanation: T.nilable(String), duplicate_charge_id: T.nilable(String), enhanced_evidence: T.nilable(T.nilable(T.any(String, ::Stripe::DisputeService::UpdateParams::Evidence::EnhancedEvidence))), product_description: T.nilable(String), receipt: T.nilable(String), refund_policy: T.nilable(String), refund_policy_disclosure: T.nilable(String), refund_refusal_explanation: T.nilable(String), service_date: T.nilable(String), service_documentation: T.nilable(String), shipping_address: T.nilable(String), shipping_carrier: T.nilable(String), shipping_date: T.nilable(String), shipping_documentation: T.nilable(String), shipping_tracking_number: T.nilable(String), uncategorized_file: T.nilable(String), uncategorized_text: T.nilable(String)).void
}
def initialize(
access_activity_log: nil,
billing_address: nil,
cancellation_policy: nil,
cancellation_policy_disclosure: nil,
cancellation_rebuttal: nil,
customer_communication: nil,
customer_email_address: nil,
customer_name: nil,
customer_purchase_ip: nil,
customer_signature: nil,
duplicate_charge_documentation: nil,
duplicate_charge_explanation: nil,
duplicate_charge_id: nil,
enhanced_evidence: nil,
product_description: nil,
receipt: nil,
refund_policy: nil,
refund_policy_disclosure: nil,
refund_refusal_explanation: nil,
service_date: nil,
service_documentation: nil,
shipping_address: nil,
shipping_carrier: nil,
shipping_date: nil,
shipping_documentation: nil,
shipping_tracking_number: nil,
uncategorized_file: nil,
uncategorized_text: nil
); end
end
# Evidence to upload, to respond to a dispute. Updating any field in the hash will submit all fields in the hash for review. The combined character count of all fields is limited to 150,000.
sig { returns(T.nilable(::Stripe::DisputeService::UpdateParams::Evidence)) }
attr_accessor :evidence
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Whether to immediately submit evidence to the bank. If `false`, evidence is staged on the dispute. Staged evidence is visible in the API and Dashboard, and can be submitted to the bank by making another request with this attribute set to `true` (the default).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :submit
sig {
params(evidence: T.nilable(::Stripe::DisputeService::UpdateParams::Evidence), expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), submit: T.nilable(T::Boolean)).void
}
def initialize(evidence: nil, expand: nil, metadata: nil, submit: nil); end
end
class CloseParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Closing the dispute for a charge indicates that you do not have any evidence to submit and are essentially dismissing the dispute, acknowledging it as lost.
#
# The status of the dispute will change from needs_response to lost. Closing a dispute is irreversible.
sig {
params(dispute: String, params: T.any(::Stripe::DisputeService::CloseParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Dispute)
}
def close(dispute, params = {}, opts = {}); end
# Returns a list of your disputes.
sig {
params(params: T.any(::Stripe::DisputeService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the dispute with the given ID.
sig {
params(dispute: String, params: T.any(::Stripe::DisputeService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Dispute)
}
def retrieve(dispute, params = {}, opts = {}); end
# When you get a dispute, contacting your customer is always the best first step. If that doesn't work, you can submit evidence to help us resolve the dispute in your favor. You can do this in your [dashboard](https://dashboard.stripe.com/disputes), but if you prefer, you can use the API to submit evidence programmatically.
#
# Depending on your dispute type, different evidence fields will give you a better chance of winning your dispute. To figure out which evidence fields to provide, see our [guide to dispute types](https://docs.stripe.com/docs/disputes/categories).
sig {
params(dispute: String, params: T.any(::Stripe::DisputeService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Dispute)
}
def update(dispute, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class EntitlementsService < StripeService
attr_reader :active_entitlements
attr_reader :features
end
end
# typed: true
module Stripe
module Entitlements
class ActiveEntitlementService < StripeService
class ListParams < Stripe::RequestParams
# The ID of the customer.
sig { returns(String) }
attr_accessor :customer
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(customer: String, ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
customer: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Retrieve a list of active entitlements for a customer
sig {
params(params: T.any(::Stripe::Entitlements::ActiveEntitlementService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieve an active entitlement
sig {
params(id: String, params: T.any(::Stripe::Entitlements::ActiveEntitlementService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Entitlements::ActiveEntitlement)
}
def retrieve(id, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Entitlements
class FeatureService < StripeService
class ListParams < Stripe::RequestParams
# If set, filter results to only include features with the given archive status.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :archived
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# If set, filter results to only include features with the given lookup_key.
sig { returns(T.nilable(String)) }
attr_accessor :lookup_key
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(archived: T.nilable(T::Boolean), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), lookup_key: T.nilable(String), starting_after: T.nilable(String)).void
}
def initialize(
archived: nil,
ending_before: nil,
expand: nil,
limit: nil,
lookup_key: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A unique key you provide as your own system identifier. This may be up to 80 characters.
sig { returns(String) }
attr_accessor :lookup_key
# Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The feature's name, for your own purpose, not meant to be displayable to the customer.
sig { returns(String) }
attr_accessor :name
sig {
params(expand: T.nilable(T::Array[String]), lookup_key: String, metadata: T.nilable(T::Hash[String, String]), name: String).void
}
def initialize(expand: nil, lookup_key: nil, metadata: nil, name: nil); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
# Inactive features cannot be attached to new products and will not be returned from the features list endpoint.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# The feature's name, for your own purpose, not meant to be displayable to the customer.
sig { returns(T.nilable(String)) }
attr_accessor :name
sig {
params(active: T.nilable(T::Boolean), expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), name: T.nilable(String)).void
}
def initialize(active: nil, expand: nil, metadata: nil, name: nil); end
end
# Creates a feature
sig {
params(params: T.any(::Stripe::Entitlements::FeatureService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Entitlements::Feature)
}
def create(params = {}, opts = {}); end
# Retrieve a list of features
sig {
params(params: T.any(::Stripe::Entitlements::FeatureService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves a feature
sig {
params(id: String, params: T.any(::Stripe::Entitlements::FeatureService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Entitlements::Feature)
}
def retrieve(id, params = {}, opts = {}); end
# Update a feature's metadata or permanently deactivate it.
sig {
params(id: String, params: T.any(::Stripe::Entitlements::FeatureService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Entitlements::Feature)
}
def update(id, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
class EphemeralKeyService < StripeService
class DeleteParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class CreateParams < Stripe::RequestParams
# The ID of the Customer you'd like to modify using the resulting ephemeral key.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The ID of the Issuing Card you'd like to access using the resulting ephemeral key.
sig { returns(T.nilable(String)) }
attr_accessor :issuing_card
# A single-use token, created by Stripe.js, used for creating ephemeral keys for Issuing Cards without exchanging sensitive information.
sig { returns(T.nilable(String)) }
attr_accessor :nonce
# The ID of the Identity VerificationSession you'd like to access using the resulting ephemeral key
sig { returns(T.nilable(String)) }
attr_accessor :verification_session
sig {
params(customer: T.nilable(String), expand: T.nilable(T::Array[String]), issuing_card: T.nilable(String), nonce: T.nilable(String), verification_session: T.nilable(String)).void
}
def initialize(
customer: nil,
expand: nil,
issuing_card: nil,
nonce: nil,
verification_session: nil
); end
end
# Creates a short-lived API key for a given resource.
sig {
params(params: T.any(::Stripe::EphemeralKeyService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::EphemeralKey)
}
def create(params = {}, opts = {}); end
# Invalidates a short-lived API key for a given resource.
sig {
params(key: String, params: T.any(::Stripe::EphemeralKeyService::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::EphemeralKey)
}
def delete(key, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class EventService < StripeService
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return events that were created during the given date interval.
sig { returns(T.nilable(T.any(::Stripe::EventService::ListParams::Created, Integer))) }
attr_accessor :created
# Filter events by whether all webhooks were successfully delivered. If false, events which are still pending or have failed all delivery attempts to a webhook endpoint will be returned.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :delivery_success
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# A string containing a specific event name, or group of events using * as a wildcard. The list will be filtered to include only events with a matching event property.
sig { returns(T.nilable(String)) }
attr_accessor :type
# An array of up to 20 strings containing specific event names. The list will be filtered to include only events with a matching event property. You may pass either `type` or `types`, but not both.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :types
sig {
params(created: T.nilable(T.any(::Stripe::EventService::ListParams::Created, Integer)), delivery_success: T.nilable(T::Boolean), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String), type: T.nilable(String), types: T.nilable(T::Array[String])).void
}
def initialize(
created: nil,
delivery_success: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil,
type: nil,
types: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# List events, going back up to 30 days. Each event data is rendered according to Stripe API version at its creation time, specified in [event object](https://docs.stripe.com/api/events/object) api_version attribute (not according to your current Stripe API version or Stripe-Version header).
sig {
params(params: T.any(::Stripe::EventService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the details of an event if it was created in the last 30 days. Supply the unique identifier of the event, which you might have received in a webhook.
sig {
params(id: String, params: T.any(::Stripe::EventService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Event)
}
def retrieve(id, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class ExchangeRateService < StripeService
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is the currency that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with the exchange rate for currency X your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and total number of supported payout currencies, and the default is the max.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is the currency that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with the exchange rate for currency X, your subsequent call can include `starting_after=X` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Returns a list of objects that contain the rates at which foreign currencies are converted to one another. Only shows the currencies for which Stripe supports.
sig {
params(params: T.any(::Stripe::ExchangeRateService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the exchange rates from the given currency to every supported currency.
sig {
params(rate_id: String, params: T.any(::Stripe::ExchangeRateService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ExchangeRate)
}
def retrieve(rate_id, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class FileService < StripeService
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return files that were created during the given date interval.
sig { returns(T.nilable(T.any(::Stripe::FileService::ListParams::Created, Integer))) }
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Filter queries by the file purpose. If you don't provide a purpose, the queries return unfiltered files.
sig { returns(T.nilable(String)) }
attr_accessor :purpose
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(created: T.nilable(T.any(::Stripe::FileService::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), purpose: T.nilable(String), starting_after: T.nilable(String)).void
}
def initialize(
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
purpose: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class FileLinkData < Stripe::RequestParams
# Set this to `true` to create a file link for the newly created file. Creating a link is only possible when the file's `purpose` is one of the following: `business_icon`, `business_logo`, `customer_signature`, `dispute_evidence`, `issuing_regulatory_reporting`, `pci_document`, `tax_document_user_upload`, or `terminal_reader_splashscreen`.
sig { returns(T::Boolean) }
attr_accessor :create
# The link isn't available after this future timestamp.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_at
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
sig {
params(create: T::Boolean, expires_at: T.nilable(Integer), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String])))).void
}
def initialize(create: nil, expires_at: nil, metadata: nil); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A file to upload. Make sure that the specifications follow RFC 2388, which defines file transfers for the `multipart/form-data` protocol.
sig { returns(T.untyped) }
attr_accessor :file
# Optional parameters that automatically create a [file link](https://stripe.com/docs/api#file_links) for the newly created file.
sig { returns(T.nilable(::Stripe::FileService::CreateParams::FileLinkData)) }
attr_accessor :file_link_data
# The [purpose](https://stripe.com/docs/file-upload#uploading-a-file) of the uploaded file.
sig { returns(String) }
attr_accessor :purpose
sig {
params(expand: T.nilable(T::Array[String]), file: T.untyped, file_link_data: T.nilable(::Stripe::FileService::CreateParams::FileLinkData), purpose: String).void
}
def initialize(expand: nil, file: nil, file_link_data: nil, purpose: nil); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# To upload a file to Stripe, you need to send a request of type multipart/form-data. Include the file you want to upload in the request, and the parameters for creating a file.
#
# All of Stripe's officially supported Client libraries support sending multipart/form-data.
sig {
params(params: T.any(::Stripe::FileService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::File)
}
def create(params = {}, opts = {}); end
# Returns a list of the files that your account has access to. Stripe sorts and returns the files by their creation dates, placing the most recently created files at the top.
sig {
params(params: T.any(::Stripe::FileService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the details of an existing file object. After you supply a unique file ID, Stripe returns the corresponding file object. Learn how to [access file contents](https://docs.stripe.com/docs/file-upload#download-file-contents).
sig {
params(file: String, params: T.any(::Stripe::FileService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::File)
}
def retrieve(file, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class FileLinkService < StripeService
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return links that were created during the given date interval.
sig { returns(T.nilable(T.any(::Stripe::FileLinkService::ListParams::Created, Integer))) }
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Filter links by their expiration status. By default, Stripe returns all links.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :expired
# Only return links for the given file.
sig { returns(T.nilable(String)) }
attr_accessor :file
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(created: T.nilable(T.any(::Stripe::FileLinkService::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), expired: T.nilable(T::Boolean), file: T.nilable(String), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
created: nil,
ending_before: nil,
expand: nil,
expired: nil,
file: nil,
limit: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The link isn't usable after this future timestamp.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_at
# The ID of the file. The file's `purpose` must be one of the following: `business_icon`, `business_logo`, `customer_signature`, `dispute_evidence`, `finance_report_run`, `financial_account_statement`, `identity_document_downloadable`, `issuing_regulatory_reporting`, `pci_document`, `selfie`, `sigma_scheduled_query`, `tax_document_user_upload`, or `terminal_reader_splashscreen`.
sig { returns(String) }
attr_accessor :file
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
sig {
params(expand: T.nilable(T::Array[String]), expires_at: T.nilable(Integer), file: String, metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String])))).void
}
def initialize(expand: nil, expires_at: nil, file: nil, metadata: nil); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A future timestamp after which the link will no longer be usable, or `now` to expire the link immediately.
sig { returns(T.nilable(T.nilable(T.any(String, T.any(String, Integer))))) }
attr_accessor :expires_at
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
sig {
params(expand: T.nilable(T::Array[String]), expires_at: T.nilable(T.nilable(T.any(String, T.any(String, Integer)))), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String])))).void
}
def initialize(expand: nil, expires_at: nil, metadata: nil); end
end
# Creates a new file link object.
sig {
params(params: T.any(::Stripe::FileLinkService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::FileLink)
}
def create(params = {}, opts = {}); end
# Returns a list of file links.
sig {
params(params: T.any(::Stripe::FileLinkService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the file link with the given ID.
sig {
params(link: String, params: T.any(::Stripe::FileLinkService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::FileLink)
}
def retrieve(link, params = {}, opts = {}); end
# Updates an existing file link object. Expired links can no longer be updated.
sig {
params(link: String, params: T.any(::Stripe::FileLinkService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::FileLink)
}
def update(link, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class FinancialConnectionsService < StripeService
attr_reader :accounts
attr_reader :institutions
attr_reader :sessions
attr_reader :transactions
end
end
# typed: true
module Stripe
module FinancialConnections
class AccountService < StripeService
attr_reader :inferred_balances
attr_reader :owners
class ListParams < Stripe::RequestParams
class AccountHolder < Stripe::RequestParams
# The ID of the Stripe account whose accounts will be retrieved.
sig { returns(T.nilable(String)) }
attr_accessor :account
# The ID of the Stripe customer whose accounts will be retrieved.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# The Account ID of the Stripe customer whose accounts will be retrieved.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
sig {
params(account: T.nilable(String), customer: T.nilable(String), customer_account: T.nilable(String)).void
}
def initialize(account: nil, customer: nil, customer_account: nil); end
end
# If present, only return accounts that belong to the specified account holder. `account_holder[customer]` and `account_holder[account]` are mutually exclusive.
sig {
returns(T.nilable(::Stripe::FinancialConnections::AccountService::ListParams::AccountHolder))
}
attr_accessor :account_holder
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# If present, only return accounts that were collected as part of the given session.
sig { returns(T.nilable(String)) }
attr_accessor :session
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(account_holder: T.nilable(::Stripe::FinancialConnections::AccountService::ListParams::AccountHolder), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), session: T.nilable(String), starting_after: T.nilable(String)).void
}
def initialize(
account_holder: nil,
ending_before: nil,
expand: nil,
limit: nil,
session: nil,
starting_after: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class DisconnectParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class RefreshParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The list of account features that you would like to refresh.
sig { returns(T::Array[String]) }
attr_accessor :features
sig { params(expand: T.nilable(T::Array[String]), features: T::Array[String]).void }
def initialize(expand: nil, features: nil); end
end
class SubscribeParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The list of account features to which you would like to subscribe.
sig { returns(T::Array[String]) }
attr_accessor :features
sig { params(expand: T.nilable(T::Array[String]), features: T::Array[String]).void }
def initialize(expand: nil, features: nil); end
end
class UnsubscribeParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The list of account features from which you would like to unsubscribe.
sig { returns(T::Array[String]) }
attr_accessor :features
sig { params(expand: T.nilable(T::Array[String]), features: T::Array[String]).void }
def initialize(expand: nil, features: nil); end
end
# Disables your access to a Financial Connections Account. You will no longer be able to access data associated with the account (e.g. balances, transactions).
sig {
params(account: String, params: T.any(::Stripe::FinancialConnections::AccountService::DisconnectParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::FinancialConnections::Account)
}
def disconnect(account, params = {}, opts = {}); end
# Returns a list of Financial Connections Account objects.
sig {
params(params: T.any(::Stripe::FinancialConnections::AccountService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Refreshes the data associated with a Financial Connections Account.
sig {
params(account: String, params: T.any(::Stripe::FinancialConnections::AccountService::RefreshParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::FinancialConnections::Account)
}
def refresh(account, params = {}, opts = {}); end
# Retrieves the details of an Financial Connections Account.
sig {
params(account: String, params: T.any(::Stripe::FinancialConnections::AccountService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::FinancialConnections::Account)
}
def retrieve(account, params = {}, opts = {}); end
# Subscribes to periodic refreshes of data associated with a Financial Connections Account.
sig {
params(account: String, params: T.any(::Stripe::FinancialConnections::AccountService::SubscribeParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::FinancialConnections::Account)
}
def subscribe(account, params = {}, opts = {}); end
# Unsubscribes from periodic refreshes of data associated with a Financial Connections Account.
sig {
params(account: String, params: T.any(::Stripe::FinancialConnections::AccountService::UnsubscribeParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::FinancialConnections::Account)
}
def unsubscribe(account, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module FinancialConnections
class AccountInferredBalanceService < StripeService
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
# Lists the recorded inferred balances for a Financial Connections Account.
sig {
params(account: String, params: T.any(::Stripe::FinancialConnections::AccountInferredBalanceService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(account, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module FinancialConnections
class AccountOwnerService < StripeService
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# The ID of the ownership object to fetch owners from.
sig { returns(String) }
attr_accessor :ownership
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), ownership: String, starting_after: T.nilable(String)).void
}
def initialize(
ending_before: nil,
expand: nil,
limit: nil,
ownership: nil,
starting_after: nil
); end
end
# Lists all owners for a given Account
sig {
params(account: String, params: T.any(::Stripe::FinancialConnections::AccountOwnerService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(account, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module FinancialConnections
class InstitutionService < StripeService
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Returns a list of Financial Connections Institution objects.
sig {
params(params: T.any(::Stripe::FinancialConnections::InstitutionService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the details of a Financial Connections Institution.
sig {
params(institution: String, params: T.any(::Stripe::FinancialConnections::InstitutionService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::FinancialConnections::Institution)
}
def retrieve(institution, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module FinancialConnections
class SessionService < StripeService
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class CreateParams < Stripe::RequestParams
class AccountHolder < Stripe::RequestParams
# The ID of the Stripe account whose accounts will be retrieved. Should only be present if `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# The ID of the Stripe customer whose accounts will be retrieved. Should only be present if `type` is `customer`.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# The ID of the Stripe customer Account whose accounts will be retrieved. Should only be present if `type` is `customer`.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# Type of account holder to collect accounts for.
sig { returns(String) }
attr_accessor :type
sig {
params(account: T.nilable(String), customer: T.nilable(String), customer_account: T.nilable(String), type: String).void
}
def initialize(account: nil, customer: nil, customer_account: nil, type: nil); end
end
class Filters < Stripe::RequestParams
# Restricts the Session to subcategories of accounts that can be linked. Valid subcategories are: `checking`, `savings`, `mortgage`, `line_of_credit`, `credit_card`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :account_subcategories
# List of countries from which to collect accounts.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :countries
# Stripe ID of the institution with which the customer should be directed to log in.
sig { returns(T.nilable(String)) }
attr_accessor :institution
sig {
params(account_subcategories: T.nilable(T::Array[String]), countries: T.nilable(T::Array[String]), institution: T.nilable(String)).void
}
def initialize(account_subcategories: nil, countries: nil, institution: nil); end
end
class Limits < Stripe::RequestParams
# The number of accounts that can be linked in this Session.
sig { returns(Integer) }
attr_accessor :accounts
sig { params(accounts: Integer).void }
def initialize(accounts: nil); end
end
class ManualEntry < Stripe::RequestParams
# Whether manual entry will be handled by Stripe during the Session.
sig { returns(T.nilable(String)) }
attr_accessor :mode
sig { params(mode: T.nilable(String)).void }
def initialize(mode: nil); end
end
# The account holder to link accounts for.
sig { returns(::Stripe::FinancialConnections::SessionService::CreateParams::AccountHolder) }
attr_accessor :account_holder
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Filters to restrict the kinds of accounts to collect.
sig {
returns(T.nilable(::Stripe::FinancialConnections::SessionService::CreateParams::Filters))
}
attr_accessor :filters
# Settings for configuring Session-specific limits.
sig {
returns(T.nilable(::Stripe::FinancialConnections::SessionService::CreateParams::Limits))
}
attr_accessor :limits
# Customize manual entry behavior
sig {
returns(T.nilable(::Stripe::FinancialConnections::SessionService::CreateParams::ManualEntry))
}
attr_accessor :manual_entry
# List of data features that you would like to request access to.
#
# Possible values are `balances`, `transactions`, `ownership`, and `payment_method`.
sig { returns(T::Array[String]) }
attr_accessor :permissions
# List of data features that you would like to retrieve upon account creation.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :prefetch
# For webview integrations only. Upon completing OAuth login in the native browser, the user will be redirected to this URL to return to your app.
sig { returns(T.nilable(String)) }
attr_accessor :return_url
sig {
params(account_holder: ::Stripe::FinancialConnections::SessionService::CreateParams::AccountHolder, expand: T.nilable(T::Array[String]), filters: T.nilable(::Stripe::FinancialConnections::SessionService::CreateParams::Filters), limits: T.nilable(::Stripe::FinancialConnections::SessionService::CreateParams::Limits), manual_entry: T.nilable(::Stripe::FinancialConnections::SessionService::CreateParams::ManualEntry), permissions: T::Array[String], prefetch: T.nilable(T::Array[String]), return_url: T.nilable(String)).void
}
def initialize(
account_holder: nil,
expand: nil,
filters: nil,
limits: nil,
manual_entry: nil,
permissions: nil,
prefetch: nil,
return_url: nil
); end
end
# To launch the Financial Connections authorization flow, create a Session. The session's client_secret can be used to launch the flow using Stripe.js.
sig {
params(params: T.any(::Stripe::FinancialConnections::SessionService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::FinancialConnections::Session)
}
def create(params = {}, opts = {}); end
# Retrieves the details of a Financial Connections Session
sig {
params(session: String, params: T.any(::Stripe::FinancialConnections::SessionService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::FinancialConnections::Session)
}
def retrieve(session, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module FinancialConnections
class TransactionService < StripeService
class ListParams < Stripe::RequestParams
class TransactedAt < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
class TransactionRefresh < Stripe::RequestParams
# Return results where the transactions were created or updated by a refresh that took place after this refresh (non-inclusive).
sig { returns(String) }
attr_accessor :after
sig { params(after: String).void }
def initialize(after: nil); end
end
# The ID of the Financial Connections Account whose transactions will be retrieved.
sig { returns(String) }
attr_accessor :account
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# A filter on the list based on the object `transacted_at` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with the following options:
sig {
returns(T.nilable(T.any(::Stripe::FinancialConnections::TransactionService::ListParams::TransactedAt, Integer)))
}
attr_accessor :transacted_at
# A filter on the list based on the object `transaction_refresh` field. The value can be a dictionary with the following options:
sig {
returns(T.nilable(::Stripe::FinancialConnections::TransactionService::ListParams::TransactionRefresh))
}
attr_accessor :transaction_refresh
sig {
params(account: String, ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String), transacted_at: T.nilable(T.any(::Stripe::FinancialConnections::TransactionService::ListParams::TransactedAt, Integer)), transaction_refresh: T.nilable(::Stripe::FinancialConnections::TransactionService::ListParams::TransactionRefresh)).void
}
def initialize(
account: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil,
transacted_at: nil,
transaction_refresh: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Returns a list of Financial Connections Transaction objects.
sig {
params(params: T.any(::Stripe::FinancialConnections::TransactionService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the details of a Financial Connections Transaction
sig {
params(transaction: String, params: T.any(::Stripe::FinancialConnections::TransactionService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::FinancialConnections::Transaction)
}
def retrieve(transaction, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
class ForwardingService < StripeService
attr_reader :requests
end
end
# typed: true
module Stripe
module Forwarding
class RequestService < StripeService
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Return results where the `created` field is greater than this value.
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Return results where the `created` field is greater than or equal to this value.
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Return results where the `created` field is less than this value.
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Return results where the `created` field is less than or equal to this value.
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Similar to other List endpoints, filters results based on created timestamp. You can pass gt, gte, lt, and lte timestamp values.
sig { returns(T.nilable(::Stripe::Forwarding::RequestService::ListParams::Created)) }
attr_accessor :created
# A pagination cursor to fetch the previous page of the list. The value must be a ForwardingRequest ID.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A pagination cursor to fetch the next page of the list. The value must be a ForwardingRequest ID.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(created: T.nilable(::Stripe::Forwarding::RequestService::ListParams::Created), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class Request < Stripe::RequestParams
class Header < Stripe::RequestParams
# The header name.
sig { returns(String) }
attr_accessor :name
# The header value.
sig { returns(String) }
attr_accessor :value
sig { params(name: String, value: String).void }
def initialize(name: nil, value: nil); end
end
# The body payload to send to the destination endpoint.
sig { returns(T.nilable(String)) }
attr_accessor :body
# The headers to include in the forwarded request. Can be omitted if no additional headers (excluding Stripe-generated ones such as the Content-Type header) should be included.
sig {
returns(T.nilable(T::Array[::Stripe::Forwarding::RequestService::CreateParams::Request::Header]))
}
attr_accessor :headers
sig {
params(body: T.nilable(String), headers: T.nilable(T::Array[::Stripe::Forwarding::RequestService::CreateParams::Request::Header])).void
}
def initialize(body: nil, headers: nil); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The PaymentMethod to insert into the forwarded request. Forwarding previously consumed PaymentMethods is allowed.
sig { returns(String) }
attr_accessor :payment_method
# The field kinds to be replaced in the forwarded request.
sig { returns(T::Array[String]) }
attr_accessor :replacements
# The request body and headers to be sent to the destination endpoint.
sig { returns(::Stripe::Forwarding::RequestService::CreateParams::Request) }
attr_accessor :request
# The destination URL for the forwarded request. Must be supported by the config.
sig { returns(String) }
attr_accessor :url
sig {
params(expand: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), payment_method: String, replacements: T::Array[String], request: ::Stripe::Forwarding::RequestService::CreateParams::Request, url: String).void
}
def initialize(
expand: nil,
metadata: nil,
payment_method: nil,
replacements: nil,
request: nil,
url: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Creates a ForwardingRequest object.
sig {
params(params: T.any(::Stripe::Forwarding::RequestService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Forwarding::Request)
}
def create(params = {}, opts = {}); end
# Lists all ForwardingRequest objects.
sig {
params(params: T.any(::Stripe::Forwarding::RequestService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves a ForwardingRequest object.
sig {
params(id: String, params: T.any(::Stripe::Forwarding::RequestService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Forwarding::Request)
}
def retrieve(id, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
class FxQuoteService < StripeService
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
class CreateParams < Stripe::RequestParams
class Usage < Stripe::RequestParams
class Payment < Stripe::RequestParams
# The Stripe account ID that the funds will be transferred to.
#
# This field should match the account ID that would be used in the PaymentIntent’s transfer_data[destination] field.
sig { returns(T.nilable(String)) }
attr_accessor :destination
# The Stripe account ID that these funds are intended for.
#
# This field should match the account ID that would be used in the PaymentIntent’s on_behalf_of field.
sig { returns(T.nilable(String)) }
attr_accessor :on_behalf_of
sig { params(destination: T.nilable(String), on_behalf_of: T.nilable(String)).void }
def initialize(destination: nil, on_behalf_of: nil); end
end
class Transfer < Stripe::RequestParams
# The Stripe account ID that the funds will be transferred to.
#
# This field should match the account ID that would be used in the Transfer’s destination field.
sig { returns(String) }
attr_accessor :destination
sig { params(destination: String).void }
def initialize(destination: nil); end
end
# The payment transaction details that are intended for the FX Quote.
sig { returns(T.nilable(::Stripe::FxQuoteService::CreateParams::Usage::Payment)) }
attr_accessor :payment
# The transfer transaction details that are intended for the FX Quote.
sig { returns(T.nilable(::Stripe::FxQuoteService::CreateParams::Usage::Transfer)) }
attr_accessor :transfer
# Which transaction the FX Quote will be used for
#
# Can be “payment” | “transfer”
sig { returns(String) }
attr_accessor :type
sig {
params(payment: T.nilable(::Stripe::FxQuoteService::CreateParams::Usage::Payment), transfer: T.nilable(::Stripe::FxQuoteService::CreateParams::Usage::Transfer), type: String).void
}
def initialize(payment: nil, transfer: nil, type: nil); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A list of three letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be [supported currencies](https://stripe.com/docs/currencies).
sig { returns(T::Array[String]) }
attr_accessor :from_currencies
# The duration that you wish the quote to be locked for. The quote will be usable for the duration specified. The default is `none`. The maximum is 1 day.
sig { returns(String) }
attr_accessor :lock_duration
# 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).
sig { returns(String) }
attr_accessor :to_currency
# The usage specific information for the quote.
sig { returns(T.nilable(::Stripe::FxQuoteService::CreateParams::Usage)) }
attr_accessor :usage
sig {
params(expand: T.nilable(T::Array[String]), from_currencies: T::Array[String], lock_duration: String, to_currency: String, usage: T.nilable(::Stripe::FxQuoteService::CreateParams::Usage)).void
}
def initialize(
expand: nil,
from_currencies: nil,
lock_duration: nil,
to_currency: nil,
usage: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Creates an FX Quote object
sig {
params(params: T.any(::Stripe::FxQuoteService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::FxQuote)
}
def create(params = {}, opts = {}); end
# Returns a list of FX quotes that have been issued. The FX quotes are returned in sorted order, with the most recent FX quotes appearing first.
sig {
params(params: T.any(::Stripe::FxQuoteService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieve an FX Quote object
sig {
params(id: String, params: T.any(::Stripe::FxQuoteService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::FxQuote)
}
def retrieve(id, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class IdentityService < StripeService
attr_reader :verification_reports
attr_reader :verification_sessions
end
end
# typed: true
module Stripe
module Identity
class VerificationReportService < StripeService
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# A string to reference this user. This can be a customer ID, a session ID, or similar, and can be used to reconcile this verification with your internal systems.
sig { returns(T.nilable(String)) }
attr_accessor :client_reference_id
# Only return VerificationReports that were created during the given date interval.
sig {
returns(T.nilable(T.any(::Stripe::Identity::VerificationReportService::ListParams::Created, Integer)))
}
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return VerificationReports of this type
sig { returns(T.nilable(String)) }
attr_accessor :type
# Only return VerificationReports created by this VerificationSession ID. It is allowed to provide a VerificationIntent ID.
sig { returns(T.nilable(String)) }
attr_accessor :verification_session
sig {
params(client_reference_id: T.nilable(String), created: T.nilable(T.any(::Stripe::Identity::VerificationReportService::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String), type: T.nilable(String), verification_session: T.nilable(String)).void
}
def initialize(
client_reference_id: nil,
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil,
type: nil,
verification_session: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# List all verification reports.
sig {
params(params: T.any(::Stripe::Identity::VerificationReportService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves an existing VerificationReport
sig {
params(report: String, params: T.any(::Stripe::Identity::VerificationReportService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Identity::VerificationReport)
}
def retrieve(report, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Identity
class VerificationSessionService < StripeService
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# A string to reference this user. This can be a customer ID, a session ID, or similar, and can be used to reconcile this verification with your internal systems.
sig { returns(T.nilable(String)) }
attr_accessor :client_reference_id
# Only return VerificationSessions that were created during the given date interval.
sig {
returns(T.nilable(T.any(::Stripe::Identity::VerificationSessionService::ListParams::Created, Integer)))
}
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Attribute for param field related_customer
sig { returns(T.nilable(String)) }
attr_accessor :related_customer
# Attribute for param field related_customer_account
sig { returns(T.nilable(String)) }
attr_accessor :related_customer_account
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return VerificationSessions with this status. [Learn more about the lifecycle of sessions](https://stripe.com/docs/identity/how-sessions-work).
sig { returns(T.nilable(String)) }
attr_accessor :status
sig {
params(client_reference_id: T.nilable(String), created: T.nilable(T.any(::Stripe::Identity::VerificationSessionService::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), related_customer: T.nilable(String), related_customer_account: T.nilable(String), starting_after: T.nilable(String), status: T.nilable(String)).void
}
def initialize(
client_reference_id: nil,
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
related_customer: nil,
related_customer_account: nil,
starting_after: nil,
status: nil
); end
end
class CreateParams < Stripe::RequestParams
class Options < Stripe::RequestParams
class Document < Stripe::RequestParams
# Array of strings of allowed identity document types. If the provided identity document isn’t one of the allowed types, the verification check will fail with a document_type_not_allowed error code.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :allowed_types
# Collect an ID number and perform an [ID number check](https://stripe.com/docs/identity/verification-checks?type=id-number) with the document’s extracted name and date of birth.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :require_id_number
# Disable image uploads, identity document images have to be captured using the device’s camera.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :require_live_capture
# Capture a face image and perform a [selfie check](https://stripe.com/docs/identity/verification-checks?type=selfie) comparing a photo ID and a picture of your user’s face. [Learn more](https://stripe.com/docs/identity/selfie).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :require_matching_selfie
sig {
params(allowed_types: T.nilable(T::Array[String]), require_id_number: T.nilable(T::Boolean), require_live_capture: T.nilable(T::Boolean), require_matching_selfie: T.nilable(T::Boolean)).void
}
def initialize(
allowed_types: nil,
require_id_number: nil,
require_live_capture: nil,
require_matching_selfie: nil
); end
end
# Options that apply to the [document check](https://stripe.com/docs/identity/verification-checks?type=document).
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Identity::VerificationSessionService::CreateParams::Options::Document))))
}
attr_accessor :document
sig {
params(document: T.nilable(T.nilable(T.any(String, ::Stripe::Identity::VerificationSessionService::CreateParams::Options::Document)))).void
}
def initialize(document: nil); end
end
class ProvidedDetails < Stripe::RequestParams
# Email of user being verified
sig { returns(T.nilable(String)) }
attr_accessor :email
# Phone number of user being verified
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig { params(email: T.nilable(String), phone: T.nilable(String)).void }
def initialize(email: nil, phone: nil); end
end
# A string to reference this user. This can be a customer ID, a session ID, or similar, and can be used to reconcile this verification with your internal systems.
sig { returns(T.nilable(String)) }
attr_accessor :client_reference_id
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# A set of options for the session’s verification checks.
sig {
returns(T.nilable(::Stripe::Identity::VerificationSessionService::CreateParams::Options))
}
attr_accessor :options
# Details provided about the user being verified. These details may be shown to the user.
sig {
returns(T.nilable(::Stripe::Identity::VerificationSessionService::CreateParams::ProvidedDetails))
}
attr_accessor :provided_details
# Customer ID
sig { returns(T.nilable(String)) }
attr_accessor :related_customer
# Token referencing a Customer Account resource.
sig { returns(T.nilable(String)) }
attr_accessor :related_customer_account
# The URL that the user will be redirected to upon completing the verification flow.
sig { returns(T.nilable(String)) }
attr_accessor :return_url
# The type of [verification check](https://stripe.com/docs/identity/verification-checks) to be performed. You must provide a `type` if not passing `verification_flow`.
sig { returns(T.nilable(String)) }
attr_accessor :type
# The ID of a verification flow from the Dashboard. See https://docs.stripe.com/identity/verification-flows.
sig { returns(T.nilable(String)) }
attr_accessor :verification_flow
sig {
params(client_reference_id: T.nilable(String), expand: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), options: T.nilable(::Stripe::Identity::VerificationSessionService::CreateParams::Options), provided_details: T.nilable(::Stripe::Identity::VerificationSessionService::CreateParams::ProvidedDetails), related_customer: T.nilable(String), related_customer_account: T.nilable(String), return_url: T.nilable(String), type: T.nilable(String), verification_flow: T.nilable(String)).void
}
def initialize(
client_reference_id: nil,
expand: nil,
metadata: nil,
options: nil,
provided_details: nil,
related_customer: nil,
related_customer_account: nil,
return_url: nil,
type: nil,
verification_flow: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
class Options < Stripe::RequestParams
class Document < Stripe::RequestParams
# Array of strings of allowed identity document types. If the provided identity document isn’t one of the allowed types, the verification check will fail with a document_type_not_allowed error code.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :allowed_types
# Collect an ID number and perform an [ID number check](https://stripe.com/docs/identity/verification-checks?type=id-number) with the document’s extracted name and date of birth.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :require_id_number
# Disable image uploads, identity document images have to be captured using the device’s camera.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :require_live_capture
# Capture a face image and perform a [selfie check](https://stripe.com/docs/identity/verification-checks?type=selfie) comparing a photo ID and a picture of your user’s face. [Learn more](https://stripe.com/docs/identity/selfie).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :require_matching_selfie
sig {
params(allowed_types: T.nilable(T::Array[String]), require_id_number: T.nilable(T::Boolean), require_live_capture: T.nilable(T::Boolean), require_matching_selfie: T.nilable(T::Boolean)).void
}
def initialize(
allowed_types: nil,
require_id_number: nil,
require_live_capture: nil,
require_matching_selfie: nil
); end
end
# Options that apply to the [document check](https://stripe.com/docs/identity/verification-checks?type=document).
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Identity::VerificationSessionService::UpdateParams::Options::Document))))
}
attr_accessor :document
sig {
params(document: T.nilable(T.nilable(T.any(String, ::Stripe::Identity::VerificationSessionService::UpdateParams::Options::Document)))).void
}
def initialize(document: nil); end
end
class ProvidedDetails < Stripe::RequestParams
# Email of user being verified
sig { returns(T.nilable(String)) }
attr_accessor :email
# Phone number of user being verified
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig { params(email: T.nilable(String), phone: T.nilable(String)).void }
def initialize(email: nil, phone: nil); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# A set of options for the session’s verification checks.
sig {
returns(T.nilable(::Stripe::Identity::VerificationSessionService::UpdateParams::Options))
}
attr_accessor :options
# Details provided about the user being verified. These details may be shown to the user.
sig {
returns(T.nilable(::Stripe::Identity::VerificationSessionService::UpdateParams::ProvidedDetails))
}
attr_accessor :provided_details
# The type of [verification check](https://stripe.com/docs/identity/verification-checks) to be performed.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(expand: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), options: T.nilable(::Stripe::Identity::VerificationSessionService::UpdateParams::Options), provided_details: T.nilable(::Stripe::Identity::VerificationSessionService::UpdateParams::ProvidedDetails), type: T.nilable(String)).void
}
def initialize(
expand: nil,
metadata: nil,
options: nil,
provided_details: nil,
type: nil
); end
end
class CancelParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class RedactParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# A VerificationSession object can be canceled when it is in requires_input [status](https://docs.stripe.com/docs/identity/how-sessions-work).
#
# Once canceled, future submission attempts are disabled. This cannot be undone. [Learn more](https://docs.stripe.com/docs/identity/verification-sessions#cancel).
sig {
params(session: String, params: T.any(::Stripe::Identity::VerificationSessionService::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Identity::VerificationSession)
}
def cancel(session, params = {}, opts = {}); end
# Creates a VerificationSession object.
#
# After the VerificationSession is created, display a verification modal using the session client_secret or send your users to the session's url.
#
# If your API key is in test mode, verification checks won't actually process, though everything else will occur as if in live mode.
#
# Related guide: [Verify your users' identity documents](https://docs.stripe.com/docs/identity/verify-identity-documents)
sig {
params(params: T.any(::Stripe::Identity::VerificationSessionService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Identity::VerificationSession)
}
def create(params = {}, opts = {}); end
# Returns a list of VerificationSessions
sig {
params(params: T.any(::Stripe::Identity::VerificationSessionService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Redact a VerificationSession to remove all collected information from Stripe. This will redact
# the VerificationSession and all objects related to it, including VerificationReports, Events,
# request logs, etc.
#
# A VerificationSession object can be redacted when it is in requires_input or verified
# [status](https://docs.stripe.com/docs/identity/how-sessions-work). Redacting a VerificationSession in requires_action
# state will automatically cancel it.
#
# The redaction process may take up to four days. When the redaction process is in progress, the
# VerificationSession's redaction.status field will be set to processing; when the process is
# finished, it will change to redacted and an identity.verification_session.redacted event
# will be emitted.
#
# Redaction is irreversible. Redacted objects are still accessible in the Stripe API, but all the
# fields that contain personal data will be replaced by the string [redacted] or a similar
# placeholder. The metadata field will also be erased. Redacted objects cannot be updated or
# used for any purpose.
#
# [Learn more](https://docs.stripe.com/docs/identity/verification-sessions#redact).
sig {
params(session: String, params: T.any(::Stripe::Identity::VerificationSessionService::RedactParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Identity::VerificationSession)
}
def redact(session, params = {}, opts = {}); end
# Retrieves the details of a VerificationSession that was previously created.
#
# When the session status is requires_input, you can use this method to retrieve a valid
# client_secret or url to allow re-submission.
sig {
params(session: String, params: T.any(::Stripe::Identity::VerificationSessionService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Identity::VerificationSession)
}
def retrieve(session, params = {}, opts = {}); end
# Updates a VerificationSession object.
#
# When the session status is requires_input, you can use this method to update the
# verification check and options.
sig {
params(session: String, params: T.any(::Stripe::Identity::VerificationSessionService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Identity::VerificationSession)
}
def update(session, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
class InvoiceService < StripeService
attr_reader :line_items
class DeleteParams < Stripe::RequestParams; end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
class AmountsDue < Stripe::RequestParams
# The amount in cents (or local equivalent).
sig { returns(Integer) }
attr_accessor :amount
# Number of days from when invoice is finalized until the payment is due.
sig { returns(T.nilable(Integer)) }
attr_accessor :days_until_due
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(String) }
attr_accessor :description
# Date on which a payment plan’s payment is due.
sig { returns(T.nilable(Integer)) }
attr_accessor :due_date
sig {
params(amount: Integer, days_until_due: T.nilable(Integer), description: String, due_date: T.nilable(Integer)).void
}
def initialize(amount: nil, days_until_due: nil, description: nil, due_date: nil); end
end
class AutomaticTax < Stripe::RequestParams
class Liability < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# 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.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
sig { returns(T.nilable(::Stripe::InvoiceService::UpdateParams::AutomaticTax::Liability)) }
attr_accessor :liability
sig {
params(enabled: T::Boolean, liability: T.nilable(::Stripe::InvoiceService::UpdateParams::AutomaticTax::Liability)).void
}
def initialize(enabled: nil, liability: nil); end
end
class CustomField < Stripe::RequestParams
# The name of the custom field. This may be up to 40 characters.
sig { returns(String) }
attr_accessor :name
# The value of the custom field. This may be up to 140 characters.
sig { returns(String) }
attr_accessor :value
sig { params(name: String, value: String).void }
def initialize(name: nil, value: nil); end
end
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::InvoiceService::UpdateParams::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::InvoiceService::UpdateParams::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig { returns(T.nilable(::Stripe::InvoiceService::UpdateParams::Discount::DiscountEnd)) }
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::InvoiceService::UpdateParams::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class Issuer < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
class PaymentSettings < Stripe::RequestParams
class PaymentMethodOptions < Stripe::RequestParams
class AcssDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Transaction type of the mandate.
sig { returns(T.nilable(String)) }
attr_accessor :transaction_type
sig { params(transaction_type: T.nilable(String)).void }
def initialize(transaction_type: nil); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::InvoiceService::UpdateParams::PaymentSettings::PaymentMethodOptions::AcssDebit::MandateOptions))
}
attr_accessor :mandate_options
# Verification method for the intent
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(mandate_options: T.nilable(::Stripe::InvoiceService::UpdateParams::PaymentSettings::PaymentMethodOptions::AcssDebit::MandateOptions), verification_method: T.nilable(String)).void
}
def initialize(mandate_options: nil, verification_method: nil); end
end
class Bancontact < Stripe::RequestParams
# Preferred language of the Bancontact authorization page that the customer is redirected to.
sig { returns(T.nilable(String)) }
attr_accessor :preferred_language
sig { params(preferred_language: T.nilable(String)).void }
def initialize(preferred_language: nil); end
end
class Card < Stripe::RequestParams
class Installments < Stripe::RequestParams
class Plan < Stripe::RequestParams
# For `fixed_count` installment plans, this is required. It represents the number of installment payments your customer will make to their credit card.
sig { returns(T.nilable(Integer)) }
attr_accessor :count
# For `fixed_count` installment plans, this is required. It represents the interval between installment payments your customer will make to their credit card.
# One of `month`.
sig { returns(T.nilable(String)) }
attr_accessor :interval
# Type of installment plan, one of `fixed_count`.
sig { returns(String) }
attr_accessor :type
sig {
params(count: T.nilable(Integer), interval: T.nilable(String), type: String).void
}
def initialize(count: nil, interval: nil, type: nil); end
end
# Setting to true enables installments for this invoice.
# Setting to false will prevent any selected plan from applying to a payment.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :enabled
# The selected installment plan to use for this invoice.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::UpdateParams::PaymentSettings::PaymentMethodOptions::Card::Installments::Plan))))
}
attr_accessor :plan
sig {
params(enabled: T.nilable(T::Boolean), plan: T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::UpdateParams::PaymentSettings::PaymentMethodOptions::Card::Installments::Plan)))).void
}
def initialize(enabled: nil, plan: nil); end
end
# Installment configuration for payments attempted on this invoice (Mexico Only).
#
# For more information, see the [installments integration guide](https://stripe.com/docs/payments/installments).
sig {
returns(T.nilable(::Stripe::InvoiceService::UpdateParams::PaymentSettings::PaymentMethodOptions::Card::Installments))
}
attr_accessor :installments
# We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
sig { returns(T.nilable(String)) }
attr_accessor :request_three_d_secure
sig {
params(installments: T.nilable(::Stripe::InvoiceService::UpdateParams::PaymentSettings::PaymentMethodOptions::Card::Installments), request_three_d_secure: T.nilable(String)).void
}
def initialize(installments: nil, request_three_d_secure: nil); end
end
class CustomerBalance < Stripe::RequestParams
class BankTransfer < Stripe::RequestParams
class EuBankTransfer < Stripe::RequestParams
# The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
sig { returns(String) }
attr_accessor :country
sig { params(country: String).void }
def initialize(country: nil); end
end
# Configuration for eu_bank_transfer funding type.
sig {
returns(T.nilable(::Stripe::InvoiceService::UpdateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance::BankTransfer::EuBankTransfer))
}
attr_accessor :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`, `mx_bank_transfer`, or `us_bank_transfer`.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(eu_bank_transfer: T.nilable(::Stripe::InvoiceService::UpdateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance::BankTransfer::EuBankTransfer), type: T.nilable(String)).void
}
def initialize(eu_bank_transfer: nil, type: nil); end
end
# Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
sig {
returns(T.nilable(::Stripe::InvoiceService::UpdateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance::BankTransfer))
}
attr_accessor :bank_transfer
# The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
sig { returns(T.nilable(String)) }
attr_accessor :funding_type
sig {
params(bank_transfer: T.nilable(::Stripe::InvoiceService::UpdateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance::BankTransfer), funding_type: T.nilable(String)).void
}
def initialize(bank_transfer: nil, funding_type: nil); end
end
class IdBankTransfer < Stripe::RequestParams; end
class Konbini < Stripe::RequestParams; end
class SepaDebit < Stripe::RequestParams; end
class UsBankAccount < Stripe::RequestParams
class FinancialConnections < Stripe::RequestParams
class Filters < Stripe::RequestParams
# The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :account_subcategories
# ID of the institution to use to filter for selectable accounts.
sig { returns(T.nilable(String)) }
attr_accessor :institution
sig {
params(account_subcategories: T.nilable(T::Array[String]), institution: T.nilable(String)).void
}
def initialize(account_subcategories: nil, institution: nil); end
end
# Provide filters for the linked accounts that the customer can select for the payment method.
sig {
returns(T.nilable(::Stripe::InvoiceService::UpdateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount::FinancialConnections::Filters))
}
attr_accessor :filters
# The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :permissions
# List of data features that you would like to retrieve upon account creation.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :prefetch
sig {
params(filters: T.nilable(::Stripe::InvoiceService::UpdateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount::FinancialConnections::Filters), permissions: T.nilable(T::Array[String]), prefetch: T.nilable(T::Array[String])).void
}
def initialize(filters: nil, permissions: nil, prefetch: nil); end
end
# Additional fields for Financial Connections Session creation
sig {
returns(T.nilable(::Stripe::InvoiceService::UpdateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount::FinancialConnections))
}
attr_accessor :financial_connections
# Verification method for the intent
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(financial_connections: T.nilable(::Stripe::InvoiceService::UpdateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount::FinancialConnections), verification_method: T.nilable(String)).void
}
def initialize(financial_connections: nil, verification_method: nil); end
end
# If paying by `acss_debit`, this sub-hash contains details about the Canadian pre-authorized debit payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::UpdateParams::PaymentSettings::PaymentMethodOptions::AcssDebit))))
}
attr_accessor :acss_debit
# If paying by `bancontact`, this sub-hash contains details about the Bancontact payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::UpdateParams::PaymentSettings::PaymentMethodOptions::Bancontact))))
}
attr_accessor :bancontact
# If paying by `card`, this sub-hash contains details about the Card payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::UpdateParams::PaymentSettings::PaymentMethodOptions::Card))))
}
attr_accessor :card
# If paying by `customer_balance`, this sub-hash contains details about the Bank transfer payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::UpdateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance))))
}
attr_accessor :customer_balance
# If paying by `id_bank_transfer`, this sub-hash contains details about the Indonesia bank transfer payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::UpdateParams::PaymentSettings::PaymentMethodOptions::IdBankTransfer))))
}
attr_accessor :id_bank_transfer
# If paying by `konbini`, this sub-hash contains details about the Konbini payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::UpdateParams::PaymentSettings::PaymentMethodOptions::Konbini))))
}
attr_accessor :konbini
# If paying by `sepa_debit`, this sub-hash contains details about the SEPA Direct Debit payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::UpdateParams::PaymentSettings::PaymentMethodOptions::SepaDebit))))
}
attr_accessor :sepa_debit
# If paying by `us_bank_account`, this sub-hash contains details about the ACH direct debit payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::UpdateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount))))
}
attr_accessor :us_bank_account
sig {
params(acss_debit: T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::UpdateParams::PaymentSettings::PaymentMethodOptions::AcssDebit))), bancontact: T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::UpdateParams::PaymentSettings::PaymentMethodOptions::Bancontact))), card: T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::UpdateParams::PaymentSettings::PaymentMethodOptions::Card))), customer_balance: T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::UpdateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance))), id_bank_transfer: T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::UpdateParams::PaymentSettings::PaymentMethodOptions::IdBankTransfer))), konbini: T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::UpdateParams::PaymentSettings::PaymentMethodOptions::Konbini))), sepa_debit: T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::UpdateParams::PaymentSettings::PaymentMethodOptions::SepaDebit))), us_bank_account: T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::UpdateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount)))).void
}
def initialize(
acss_debit: nil,
bancontact: nil,
card: nil,
customer_balance: nil,
id_bank_transfer: nil,
konbini: nil,
sepa_debit: nil,
us_bank_account: nil
); end
end
# ID of the mandate to be used for this invoice. It must correspond to the payment method used to pay the invoice, including the invoice's default_payment_method or default_source, if set.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :default_mandate
# Payment-method-specific configuration to provide to the invoice’s PaymentIntent.
sig {
returns(T.nilable(::Stripe::InvoiceService::UpdateParams::PaymentSettings::PaymentMethodOptions))
}
attr_accessor :payment_method_options
# The list of payment method types (e.g. card) to provide to the invoice’s PaymentIntent. If not set, Stripe attempts to automatically determine the types to use by looking at the invoice’s default payment method, the subscription’s default payment method, the customer’s default payment method, and your [invoice template settings](https://dashboard.stripe.com/settings/billing/invoice). Should not be specified with payment_method_configuration
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :payment_method_types
sig {
params(default_mandate: T.nilable(T.nilable(String)), payment_method_options: T.nilable(::Stripe::InvoiceService::UpdateParams::PaymentSettings::PaymentMethodOptions), payment_method_types: T.nilable(T.nilable(T.any(String, T::Array[String])))).void
}
def initialize(
default_mandate: nil,
payment_method_options: nil,
payment_method_types: nil
); end
end
class Rendering < Stripe::RequestParams
class Pdf < Stripe::RequestParams
# Page size for invoice PDF. Can be set to `a4`, `letter`, or `auto`.
# If set to `auto`, invoice PDF page size defaults to `a4` for customers with
# Japanese locale and `letter` for customers with other locales.
sig { returns(T.nilable(String)) }
attr_accessor :page_size
sig { params(page_size: T.nilable(String)).void }
def initialize(page_size: nil); end
end
# How line-item prices and amounts will be displayed with respect to tax on invoice PDFs. One of `exclude_tax` or `include_inclusive_tax`. `include_inclusive_tax` will include inclusive tax (and exclude exclusive tax) in invoice PDF amounts. `exclude_tax` will exclude all tax (inclusive and exclusive alike) from invoice PDF amounts.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :amount_tax_display
# Invoice pdf rendering options
sig { returns(T.nilable(::Stripe::InvoiceService::UpdateParams::Rendering::Pdf)) }
attr_accessor :pdf
# ID of the invoice rendering template to use for this invoice.
sig { returns(T.nilable(String)) }
attr_accessor :template
# The specific version of invoice rendering template to use for this invoice.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :template_version
sig {
params(amount_tax_display: T.nilable(T.nilable(T.any(String, String))), pdf: T.nilable(::Stripe::InvoiceService::UpdateParams::Rendering::Pdf), template: T.nilable(String), template_version: T.nilable(T.nilable(T.any(String, Integer)))).void
}
def initialize(amount_tax_display: nil, pdf: nil, template: nil, template_version: nil); end
end
class ShippingCost < Stripe::RequestParams
class ShippingRateData < Stripe::RequestParams
class DeliveryEstimate < Stripe::RequestParams
class Maximum < Stripe::RequestParams
# A unit of time.
sig { returns(String) }
attr_accessor :unit
# Must be greater than 0.
sig { returns(Integer) }
attr_accessor :value
sig { params(unit: String, value: Integer).void }
def initialize(unit: nil, value: nil); end
end
class Minimum < Stripe::RequestParams
# A unit of time.
sig { returns(String) }
attr_accessor :unit
# Must be greater than 0.
sig { returns(Integer) }
attr_accessor :value
sig { params(unit: String, value: Integer).void }
def initialize(unit: nil, value: nil); end
end
# The upper bound of the estimated range. If empty, represents no upper bound i.e., infinite.
sig {
returns(T.nilable(::Stripe::InvoiceService::UpdateParams::ShippingCost::ShippingRateData::DeliveryEstimate::Maximum))
}
attr_accessor :maximum
# The lower bound of the estimated range. If empty, represents no lower bound.
sig {
returns(T.nilable(::Stripe::InvoiceService::UpdateParams::ShippingCost::ShippingRateData::DeliveryEstimate::Minimum))
}
attr_accessor :minimum
sig {
params(maximum: T.nilable(::Stripe::InvoiceService::UpdateParams::ShippingCost::ShippingRateData::DeliveryEstimate::Maximum), minimum: T.nilable(::Stripe::InvoiceService::UpdateParams::ShippingCost::ShippingRateData::DeliveryEstimate::Minimum)).void
}
def initialize(maximum: nil, minimum: nil); end
end
class FixedAmount < Stripe::RequestParams
class CurrencyOptions < Stripe::RequestParams
# A non-negative integer in cents representing how much to charge.
sig { returns(Integer) }
attr_accessor :amount
# Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
sig { params(amount: Integer, tax_behavior: T.nilable(String)).void }
def initialize(amount: nil, tax_behavior: nil); end
end
# A non-negative integer in cents representing how much to charge.
sig { returns(Integer) }
attr_accessor :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).
sig { returns(String) }
attr_accessor :currency
# Shipping rates defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
sig {
returns(T.nilable(T::Hash[String, ::Stripe::InvoiceService::UpdateParams::ShippingCost::ShippingRateData::FixedAmount::CurrencyOptions]))
}
attr_accessor :currency_options
sig {
params(amount: Integer, currency: String, currency_options: T.nilable(T::Hash[String, ::Stripe::InvoiceService::UpdateParams::ShippingCost::ShippingRateData::FixedAmount::CurrencyOptions])).void
}
def initialize(amount: nil, currency: nil, currency_options: nil); end
end
# The estimated range for how long shipping will take, meant to be displayable to the customer. This will appear on CheckoutSessions.
sig {
returns(T.nilable(::Stripe::InvoiceService::UpdateParams::ShippingCost::ShippingRateData::DeliveryEstimate))
}
attr_accessor :delivery_estimate
# The name of the shipping rate, meant to be displayable to the customer. This will appear on CheckoutSessions.
sig { returns(String) }
attr_accessor :display_name
# Describes a fixed amount to charge for shipping. Must be present if type is `fixed_amount`.
sig {
returns(T.nilable(::Stripe::InvoiceService::UpdateParams::ShippingCost::ShippingRateData::FixedAmount))
}
attr_accessor :fixed_amount
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID. The Shipping tax code is `txcd_92010001`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_code
# The type of calculation to use on the shipping rate.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(delivery_estimate: T.nilable(::Stripe::InvoiceService::UpdateParams::ShippingCost::ShippingRateData::DeliveryEstimate), display_name: String, fixed_amount: T.nilable(::Stripe::InvoiceService::UpdateParams::ShippingCost::ShippingRateData::FixedAmount), metadata: T.nilable(T::Hash[String, String]), tax_behavior: T.nilable(String), tax_code: T.nilable(String), type: T.nilable(String)).void
}
def initialize(
delivery_estimate: nil,
display_name: nil,
fixed_amount: nil,
metadata: nil,
tax_behavior: nil,
tax_code: nil,
type: nil
); end
end
# The ID of the shipping rate to use for this order.
sig { returns(T.nilable(String)) }
attr_accessor :shipping_rate
# Parameters to create a new ad-hoc shipping rate for this order.
sig {
returns(T.nilable(::Stripe::InvoiceService::UpdateParams::ShippingCost::ShippingRateData))
}
attr_accessor :shipping_rate_data
sig {
params(shipping_rate: T.nilable(String), shipping_rate_data: T.nilable(::Stripe::InvoiceService::UpdateParams::ShippingCost::ShippingRateData)).void
}
def initialize(shipping_rate: nil, shipping_rate_data: nil); end
end
class ShippingDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Shipping address
sig { returns(::Stripe::InvoiceService::UpdateParams::ShippingDetails::Address) }
attr_accessor :address
# Recipient name.
sig { returns(String) }
attr_accessor :name
# Recipient phone (including extension)
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :phone
sig {
params(address: ::Stripe::InvoiceService::UpdateParams::ShippingDetails::Address, name: String, phone: T.nilable(T.nilable(String))).void
}
def initialize(address: nil, name: nil, phone: nil); end
end
class TransferData < Stripe::RequestParams
# The amount that will be transferred automatically when the invoice is paid. If no amount is set, the full amount is transferred.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# ID of an existing, connected Stripe account.
sig { returns(String) }
attr_accessor :destination
sig { params(amount: T.nilable(Integer), destination: String).void }
def initialize(amount: nil, destination: nil); end
end
# The account tax IDs associated with the invoice. Only editable when the invoice is a draft.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :account_tax_ids
# List of expected payments and corresponding due dates. Valid only for invoices where `collection_method=send_invoice`.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceService::UpdateParams::AmountsDue]))))
}
attr_accessor :amounts_due
# 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).
sig { returns(T.nilable(Integer)) }
attr_accessor :application_fee_amount
# Controls whether Stripe performs [automatic collection](https://stripe.com/docs/invoicing/integration/automatic-advancement-collection) of the invoice.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :auto_advance
# Settings for automatic tax lookup for this invoice.
sig { returns(T.nilable(::Stripe::InvoiceService::UpdateParams::AutomaticTax)) }
attr_accessor :automatic_tax
# The time when this invoice should be scheduled to finalize. The invoice will be finalized at this time if it is still in draft state. To turn off automatic finalization, set `auto_advance` to false.
sig { returns(T.nilable(Integer)) }
attr_accessor :automatically_finalizes_at
# Either `charge_automatically` or `send_invoice`. This field can be updated only on `draft` invoices.
sig { returns(T.nilable(String)) }
attr_accessor :collection_method
# 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.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceService::UpdateParams::CustomField]))))
}
attr_accessor :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.
sig { returns(T.nilable(Integer)) }
attr_accessor :days_until_due
# The ids of the margins to apply to the invoice. Can be overridden by line item `margins`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :default_margins
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :default_payment_method
# ID of the default payment source for the invoice. It must belong to the customer associated with the invoice and be in a chargeable state. If not set, defaults to the subscription's default source, if any, or to the customer's default source.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :default_source
# The tax rates that will apply to any line item that does not have `tax_rates` set. Pass an empty string to remove previously-defined tax rates.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :default_tax_rates
# An arbitrary string attached to the object. Often useful for displaying to users. Referenced as 'memo' in the Dashboard.
sig { returns(T.nilable(String)) }
attr_accessor :description
# The discounts that will apply to the invoice. Pass an empty string to remove previously-defined discounts.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceService::UpdateParams::Discount]))))
}
attr_accessor :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.
sig { returns(T.nilable(Integer)) }
attr_accessor :due_date
# The date when this invoice is in effect. Same as `finalized_at` unless overwritten. When defined, this value replaces the system-generated 'Date of issue' printed on the invoice PDF and receipt.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :effective_at
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Footer to be displayed on the invoice.
sig { returns(T.nilable(String)) }
attr_accessor :footer
# The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
sig { returns(T.nilable(::Stripe::InvoiceService::UpdateParams::Issuer)) }
attr_accessor :issuer
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Set the number for this invoice. If no number is present then a number will be assigned automatically when the invoice is finalized. In many markets, regulations require invoices to be unique, sequential and / or gapless. You are responsible for ensuring this is true across all your different invoicing systems in the event that you edit the invoice number using our API. If you use only Stripe for your invoices and do not change invoice numbers, Stripe handles this aspect of compliance for you automatically.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :number
# The account (if any) for which the funds of the invoice payment are intended. If set, the invoice will be presented with the branding and support information of the specified account. See the [Invoices with Connect](https://stripe.com/docs/billing/invoices/connect) documentation for details.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :on_behalf_of
# Configuration settings for the PaymentIntent that is generated when the invoice is finalized.
sig { returns(T.nilable(::Stripe::InvoiceService::UpdateParams::PaymentSettings)) }
attr_accessor :payment_settings
# The rendering-related settings that control how the invoice is displayed on customer-facing surfaces such as PDF and Hosted Invoice Page.
sig { returns(T.nilable(::Stripe::InvoiceService::UpdateParams::Rendering)) }
attr_accessor :rendering
# Settings for the cost of shipping for this invoice.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::UpdateParams::ShippingCost))))
}
attr_accessor :shipping_cost
# Shipping details for the invoice. The Invoice PDF will use the `shipping_details` value if it is set, otherwise the PDF will render the shipping address from the customer.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::UpdateParams::ShippingDetails))))
}
attr_accessor :shipping_details
# Extra information about a charge for the customer's credit card statement. It must contain at least one letter. If not specified and this invoice is part of a subscription, the default `statement_descriptor` will be set to the first subscription item's product's `statement_descriptor`.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
# 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.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::UpdateParams::TransferData))))
}
attr_accessor :transfer_data
sig {
params(account_tax_ids: T.nilable(T.nilable(T.any(String, T::Array[String]))), amounts_due: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceService::UpdateParams::AmountsDue]))), application_fee_amount: T.nilable(Integer), auto_advance: T.nilable(T::Boolean), automatic_tax: T.nilable(::Stripe::InvoiceService::UpdateParams::AutomaticTax), automatically_finalizes_at: T.nilable(Integer), collection_method: T.nilable(String), custom_fields: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceService::UpdateParams::CustomField]))), days_until_due: T.nilable(Integer), default_margins: T.nilable(T.nilable(T.any(String, T::Array[String]))), default_payment_method: T.nilable(String), default_source: T.nilable(T.nilable(String)), default_tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String]))), description: T.nilable(String), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceService::UpdateParams::Discount]))), due_date: T.nilable(Integer), effective_at: T.nilable(T.nilable(T.any(String, Integer))), expand: T.nilable(T::Array[String]), footer: T.nilable(String), issuer: T.nilable(::Stripe::InvoiceService::UpdateParams::Issuer), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), number: T.nilable(T.nilable(String)), on_behalf_of: T.nilable(T.nilable(String)), payment_settings: T.nilable(::Stripe::InvoiceService::UpdateParams::PaymentSettings), rendering: T.nilable(::Stripe::InvoiceService::UpdateParams::Rendering), shipping_cost: T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::UpdateParams::ShippingCost))), shipping_details: T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::UpdateParams::ShippingDetails))), statement_descriptor: T.nilable(String), transfer_data: T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::UpdateParams::TransferData)))).void
}
def initialize(
account_tax_ids: nil,
amounts_due: nil,
application_fee_amount: nil,
auto_advance: nil,
automatic_tax: nil,
automatically_finalizes_at: nil,
collection_method: nil,
custom_fields: nil,
days_until_due: nil,
default_margins: nil,
default_payment_method: nil,
default_source: nil,
default_tax_rates: nil,
description: nil,
discounts: nil,
due_date: nil,
effective_at: nil,
expand: nil,
footer: nil,
issuer: nil,
metadata: nil,
number: nil,
on_behalf_of: nil,
payment_settings: nil,
rendering: nil,
shipping_cost: nil,
shipping_details: nil,
statement_descriptor: nil,
transfer_data: nil
); end
end
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
class DueDate < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# The collection method of the invoice to retrieve. Either `charge_automatically` or `send_invoice`.
sig { returns(T.nilable(String)) }
attr_accessor :collection_method
# Only return invoices that were created during the given date interval.
sig { returns(T.nilable(T.any(::Stripe::InvoiceService::ListParams::Created, Integer))) }
attr_accessor :created
# Only return invoices for the customer specified by this customer ID.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# Only return invoices for the account specified by this account ID.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# Attribute for param field due_date
sig { returns(T.nilable(T.any(::Stripe::InvoiceService::ListParams::DueDate, Integer))) }
attr_accessor :due_date
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# The status of the invoice, one of `draft`, `open`, `paid`, `uncollectible`, or `void`. [Learn more](https://stripe.com/docs/billing/invoices/workflow#workflow-overview)
sig { returns(T.nilable(String)) }
attr_accessor :status
# Only return invoices for the subscription specified by this subscription ID.
sig { returns(T.nilable(String)) }
attr_accessor :subscription
sig {
params(collection_method: T.nilable(String), created: T.nilable(T.any(::Stripe::InvoiceService::ListParams::Created, Integer)), customer: T.nilable(String), customer_account: T.nilable(String), due_date: T.nilable(T.any(::Stripe::InvoiceService::ListParams::DueDate, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String), status: T.nilable(String), subscription: T.nilable(String)).void
}
def initialize(
collection_method: nil,
created: nil,
customer: nil,
customer_account: nil,
due_date: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil,
status: nil,
subscription: nil
); end
end
class CreateParams < Stripe::RequestParams
class AmountsDue < Stripe::RequestParams
# The amount in cents (or local equivalent).
sig { returns(Integer) }
attr_accessor :amount
# Number of days from when invoice is finalized until the payment is due.
sig { returns(T.nilable(Integer)) }
attr_accessor :days_until_due
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(String) }
attr_accessor :description
# Date on which a payment plan’s payment is due.
sig { returns(T.nilable(Integer)) }
attr_accessor :due_date
sig {
params(amount: Integer, days_until_due: T.nilable(Integer), description: String, due_date: T.nilable(Integer)).void
}
def initialize(amount: nil, days_until_due: nil, description: nil, due_date: nil); end
end
class AutomaticTax < Stripe::RequestParams
class Liability < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# 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.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
sig { returns(T.nilable(::Stripe::InvoiceService::CreateParams::AutomaticTax::Liability)) }
attr_accessor :liability
sig {
params(enabled: T::Boolean, liability: T.nilable(::Stripe::InvoiceService::CreateParams::AutomaticTax::Liability)).void
}
def initialize(enabled: nil, liability: nil); end
end
class CustomField < Stripe::RequestParams
# The name of the custom field. This may be up to 40 characters.
sig { returns(String) }
attr_accessor :name
# The value of the custom field. This may be up to 140 characters.
sig { returns(String) }
attr_accessor :value
sig { params(name: String, value: String).void }
def initialize(name: nil, value: nil); end
end
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreateParams::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::InvoiceService::CreateParams::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig { returns(T.nilable(::Stripe::InvoiceService::CreateParams::Discount::DiscountEnd)) }
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::InvoiceService::CreateParams::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class FromInvoice < Stripe::RequestParams
# The relation between the new invoice and the original invoice. Currently, only 'revision' is permitted
sig { returns(String) }
attr_accessor :action
# The `id` of the invoice that will be cloned.
sig { returns(String) }
attr_accessor :invoice
sig { params(action: String, invoice: String).void }
def initialize(action: nil, invoice: nil); end
end
class Issuer < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
class PaymentSettings < Stripe::RequestParams
class PaymentMethodOptions < Stripe::RequestParams
class AcssDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Transaction type of the mandate.
sig { returns(T.nilable(String)) }
attr_accessor :transaction_type
sig { params(transaction_type: T.nilable(String)).void }
def initialize(transaction_type: nil); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::InvoiceService::CreateParams::PaymentSettings::PaymentMethodOptions::AcssDebit::MandateOptions))
}
attr_accessor :mandate_options
# Verification method for the intent
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(mandate_options: T.nilable(::Stripe::InvoiceService::CreateParams::PaymentSettings::PaymentMethodOptions::AcssDebit::MandateOptions), verification_method: T.nilable(String)).void
}
def initialize(mandate_options: nil, verification_method: nil); end
end
class Bancontact < Stripe::RequestParams
# Preferred language of the Bancontact authorization page that the customer is redirected to.
sig { returns(T.nilable(String)) }
attr_accessor :preferred_language
sig { params(preferred_language: T.nilable(String)).void }
def initialize(preferred_language: nil); end
end
class Card < Stripe::RequestParams
class Installments < Stripe::RequestParams
class Plan < Stripe::RequestParams
# For `fixed_count` installment plans, this is required. It represents the number of installment payments your customer will make to their credit card.
sig { returns(T.nilable(Integer)) }
attr_accessor :count
# For `fixed_count` installment plans, this is required. It represents the interval between installment payments your customer will make to their credit card.
# One of `month`.
sig { returns(T.nilable(String)) }
attr_accessor :interval
# Type of installment plan, one of `fixed_count`.
sig { returns(String) }
attr_accessor :type
sig {
params(count: T.nilable(Integer), interval: T.nilable(String), type: String).void
}
def initialize(count: nil, interval: nil, type: nil); end
end
# Setting to true enables installments for this invoice.
# Setting to false will prevent any selected plan from applying to a payment.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :enabled
# The selected installment plan to use for this invoice.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::CreateParams::PaymentSettings::PaymentMethodOptions::Card::Installments::Plan))))
}
attr_accessor :plan
sig {
params(enabled: T.nilable(T::Boolean), plan: T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::CreateParams::PaymentSettings::PaymentMethodOptions::Card::Installments::Plan)))).void
}
def initialize(enabled: nil, plan: nil); end
end
# Installment configuration for payments attempted on this invoice (Mexico Only).
#
# For more information, see the [installments integration guide](https://stripe.com/docs/payments/installments).
sig {
returns(T.nilable(::Stripe::InvoiceService::CreateParams::PaymentSettings::PaymentMethodOptions::Card::Installments))
}
attr_accessor :installments
# We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
sig { returns(T.nilable(String)) }
attr_accessor :request_three_d_secure
sig {
params(installments: T.nilable(::Stripe::InvoiceService::CreateParams::PaymentSettings::PaymentMethodOptions::Card::Installments), request_three_d_secure: T.nilable(String)).void
}
def initialize(installments: nil, request_three_d_secure: nil); end
end
class CustomerBalance < Stripe::RequestParams
class BankTransfer < Stripe::RequestParams
class EuBankTransfer < Stripe::RequestParams
# The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
sig { returns(String) }
attr_accessor :country
sig { params(country: String).void }
def initialize(country: nil); end
end
# Configuration for eu_bank_transfer funding type.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance::BankTransfer::EuBankTransfer))
}
attr_accessor :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`, `mx_bank_transfer`, or `us_bank_transfer`.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(eu_bank_transfer: T.nilable(::Stripe::InvoiceService::CreateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance::BankTransfer::EuBankTransfer), type: T.nilable(String)).void
}
def initialize(eu_bank_transfer: nil, type: nil); end
end
# Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance::BankTransfer))
}
attr_accessor :bank_transfer
# The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
sig { returns(T.nilable(String)) }
attr_accessor :funding_type
sig {
params(bank_transfer: T.nilable(::Stripe::InvoiceService::CreateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance::BankTransfer), funding_type: T.nilable(String)).void
}
def initialize(bank_transfer: nil, funding_type: nil); end
end
class IdBankTransfer < Stripe::RequestParams; end
class Konbini < Stripe::RequestParams; end
class SepaDebit < Stripe::RequestParams; end
class UsBankAccount < Stripe::RequestParams
class FinancialConnections < Stripe::RequestParams
class Filters < Stripe::RequestParams
# The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :account_subcategories
# ID of the institution to use to filter for selectable accounts.
sig { returns(T.nilable(String)) }
attr_accessor :institution
sig {
params(account_subcategories: T.nilable(T::Array[String]), institution: T.nilable(String)).void
}
def initialize(account_subcategories: nil, institution: nil); end
end
# Provide filters for the linked accounts that the customer can select for the payment method.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount::FinancialConnections::Filters))
}
attr_accessor :filters
# The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :permissions
# List of data features that you would like to retrieve upon account creation.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :prefetch
sig {
params(filters: T.nilable(::Stripe::InvoiceService::CreateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount::FinancialConnections::Filters), permissions: T.nilable(T::Array[String]), prefetch: T.nilable(T::Array[String])).void
}
def initialize(filters: nil, permissions: nil, prefetch: nil); end
end
# Additional fields for Financial Connections Session creation
sig {
returns(T.nilable(::Stripe::InvoiceService::CreateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount::FinancialConnections))
}
attr_accessor :financial_connections
# Verification method for the intent
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(financial_connections: T.nilable(::Stripe::InvoiceService::CreateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount::FinancialConnections), verification_method: T.nilable(String)).void
}
def initialize(financial_connections: nil, verification_method: nil); end
end
# If paying by `acss_debit`, this sub-hash contains details about the Canadian pre-authorized debit payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::CreateParams::PaymentSettings::PaymentMethodOptions::AcssDebit))))
}
attr_accessor :acss_debit
# If paying by `bancontact`, this sub-hash contains details about the Bancontact payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::CreateParams::PaymentSettings::PaymentMethodOptions::Bancontact))))
}
attr_accessor :bancontact
# If paying by `card`, this sub-hash contains details about the Card payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::CreateParams::PaymentSettings::PaymentMethodOptions::Card))))
}
attr_accessor :card
# If paying by `customer_balance`, this sub-hash contains details about the Bank transfer payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::CreateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance))))
}
attr_accessor :customer_balance
# If paying by `id_bank_transfer`, this sub-hash contains details about the Indonesia bank transfer payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::CreateParams::PaymentSettings::PaymentMethodOptions::IdBankTransfer))))
}
attr_accessor :id_bank_transfer
# If paying by `konbini`, this sub-hash contains details about the Konbini payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::CreateParams::PaymentSettings::PaymentMethodOptions::Konbini))))
}
attr_accessor :konbini
# If paying by `sepa_debit`, this sub-hash contains details about the SEPA Direct Debit payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::CreateParams::PaymentSettings::PaymentMethodOptions::SepaDebit))))
}
attr_accessor :sepa_debit
# If paying by `us_bank_account`, this sub-hash contains details about the ACH direct debit payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::CreateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount))))
}
attr_accessor :us_bank_account
sig {
params(acss_debit: T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::CreateParams::PaymentSettings::PaymentMethodOptions::AcssDebit))), bancontact: T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::CreateParams::PaymentSettings::PaymentMethodOptions::Bancontact))), card: T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::CreateParams::PaymentSettings::PaymentMethodOptions::Card))), customer_balance: T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::CreateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance))), id_bank_transfer: T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::CreateParams::PaymentSettings::PaymentMethodOptions::IdBankTransfer))), konbini: T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::CreateParams::PaymentSettings::PaymentMethodOptions::Konbini))), sepa_debit: T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::CreateParams::PaymentSettings::PaymentMethodOptions::SepaDebit))), us_bank_account: T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::CreateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount)))).void
}
def initialize(
acss_debit: nil,
bancontact: nil,
card: nil,
customer_balance: nil,
id_bank_transfer: nil,
konbini: nil,
sepa_debit: nil,
us_bank_account: nil
); end
end
# ID of the mandate to be used for this invoice. It must correspond to the payment method used to pay the invoice, including the invoice's default_payment_method or default_source, if set.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :default_mandate
# Payment-method-specific configuration to provide to the invoice’s PaymentIntent.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreateParams::PaymentSettings::PaymentMethodOptions))
}
attr_accessor :payment_method_options
# The list of payment method types (e.g. card) to provide to the invoice’s PaymentIntent. If not set, Stripe attempts to automatically determine the types to use by looking at the invoice’s default payment method, the subscription’s default payment method, the customer’s default payment method, and your [invoice template settings](https://dashboard.stripe.com/settings/billing/invoice). Should not be specified with payment_method_configuration
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :payment_method_types
sig {
params(default_mandate: T.nilable(T.nilable(String)), payment_method_options: T.nilable(::Stripe::InvoiceService::CreateParams::PaymentSettings::PaymentMethodOptions), payment_method_types: T.nilable(T.nilable(T.any(String, T::Array[String])))).void
}
def initialize(
default_mandate: nil,
payment_method_options: nil,
payment_method_types: nil
); end
end
class Rendering < Stripe::RequestParams
class Pdf < Stripe::RequestParams
# Page size for invoice PDF. Can be set to `a4`, `letter`, or `auto`.
# If set to `auto`, invoice PDF page size defaults to `a4` for customers with
# Japanese locale and `letter` for customers with other locales.
sig { returns(T.nilable(String)) }
attr_accessor :page_size
sig { params(page_size: T.nilable(String)).void }
def initialize(page_size: nil); end
end
# How line-item prices and amounts will be displayed with respect to tax on invoice PDFs. One of `exclude_tax` or `include_inclusive_tax`. `include_inclusive_tax` will include inclusive tax (and exclude exclusive tax) in invoice PDF amounts. `exclude_tax` will exclude all tax (inclusive and exclusive alike) from invoice PDF amounts.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :amount_tax_display
# Invoice pdf rendering options
sig { returns(T.nilable(::Stripe::InvoiceService::CreateParams::Rendering::Pdf)) }
attr_accessor :pdf
# ID of the invoice rendering template to use for this invoice.
sig { returns(T.nilable(String)) }
attr_accessor :template
# The specific version of invoice rendering template to use for this invoice.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :template_version
sig {
params(amount_tax_display: T.nilable(T.nilable(T.any(String, String))), pdf: T.nilable(::Stripe::InvoiceService::CreateParams::Rendering::Pdf), template: T.nilable(String), template_version: T.nilable(T.nilable(T.any(String, Integer)))).void
}
def initialize(amount_tax_display: nil, pdf: nil, template: nil, template_version: nil); end
end
class ShippingCost < Stripe::RequestParams
class ShippingRateData < Stripe::RequestParams
class DeliveryEstimate < Stripe::RequestParams
class Maximum < Stripe::RequestParams
# A unit of time.
sig { returns(String) }
attr_accessor :unit
# Must be greater than 0.
sig { returns(Integer) }
attr_accessor :value
sig { params(unit: String, value: Integer).void }
def initialize(unit: nil, value: nil); end
end
class Minimum < Stripe::RequestParams
# A unit of time.
sig { returns(String) }
attr_accessor :unit
# Must be greater than 0.
sig { returns(Integer) }
attr_accessor :value
sig { params(unit: String, value: Integer).void }
def initialize(unit: nil, value: nil); end
end
# The upper bound of the estimated range. If empty, represents no upper bound i.e., infinite.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreateParams::ShippingCost::ShippingRateData::DeliveryEstimate::Maximum))
}
attr_accessor :maximum
# The lower bound of the estimated range. If empty, represents no lower bound.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreateParams::ShippingCost::ShippingRateData::DeliveryEstimate::Minimum))
}
attr_accessor :minimum
sig {
params(maximum: T.nilable(::Stripe::InvoiceService::CreateParams::ShippingCost::ShippingRateData::DeliveryEstimate::Maximum), minimum: T.nilable(::Stripe::InvoiceService::CreateParams::ShippingCost::ShippingRateData::DeliveryEstimate::Minimum)).void
}
def initialize(maximum: nil, minimum: nil); end
end
class FixedAmount < Stripe::RequestParams
class CurrencyOptions < Stripe::RequestParams
# A non-negative integer in cents representing how much to charge.
sig { returns(Integer) }
attr_accessor :amount
# Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
sig { params(amount: Integer, tax_behavior: T.nilable(String)).void }
def initialize(amount: nil, tax_behavior: nil); end
end
# A non-negative integer in cents representing how much to charge.
sig { returns(Integer) }
attr_accessor :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).
sig { returns(String) }
attr_accessor :currency
# Shipping rates defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
sig {
returns(T.nilable(T::Hash[String, ::Stripe::InvoiceService::CreateParams::ShippingCost::ShippingRateData::FixedAmount::CurrencyOptions]))
}
attr_accessor :currency_options
sig {
params(amount: Integer, currency: String, currency_options: T.nilable(T::Hash[String, ::Stripe::InvoiceService::CreateParams::ShippingCost::ShippingRateData::FixedAmount::CurrencyOptions])).void
}
def initialize(amount: nil, currency: nil, currency_options: nil); end
end
# The estimated range for how long shipping will take, meant to be displayable to the customer. This will appear on CheckoutSessions.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreateParams::ShippingCost::ShippingRateData::DeliveryEstimate))
}
attr_accessor :delivery_estimate
# The name of the shipping rate, meant to be displayable to the customer. This will appear on CheckoutSessions.
sig { returns(String) }
attr_accessor :display_name
# Describes a fixed amount to charge for shipping. Must be present if type is `fixed_amount`.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreateParams::ShippingCost::ShippingRateData::FixedAmount))
}
attr_accessor :fixed_amount
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID. The Shipping tax code is `txcd_92010001`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_code
# The type of calculation to use on the shipping rate.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(delivery_estimate: T.nilable(::Stripe::InvoiceService::CreateParams::ShippingCost::ShippingRateData::DeliveryEstimate), display_name: String, fixed_amount: T.nilable(::Stripe::InvoiceService::CreateParams::ShippingCost::ShippingRateData::FixedAmount), metadata: T.nilable(T::Hash[String, String]), tax_behavior: T.nilable(String), tax_code: T.nilable(String), type: T.nilable(String)).void
}
def initialize(
delivery_estimate: nil,
display_name: nil,
fixed_amount: nil,
metadata: nil,
tax_behavior: nil,
tax_code: nil,
type: nil
); end
end
# The ID of the shipping rate to use for this order.
sig { returns(T.nilable(String)) }
attr_accessor :shipping_rate
# Parameters to create a new ad-hoc shipping rate for this order.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreateParams::ShippingCost::ShippingRateData))
}
attr_accessor :shipping_rate_data
sig {
params(shipping_rate: T.nilable(String), shipping_rate_data: T.nilable(::Stripe::InvoiceService::CreateParams::ShippingCost::ShippingRateData)).void
}
def initialize(shipping_rate: nil, shipping_rate_data: nil); end
end
class ShippingDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Shipping address
sig { returns(::Stripe::InvoiceService::CreateParams::ShippingDetails::Address) }
attr_accessor :address
# Recipient name.
sig { returns(String) }
attr_accessor :name
# Recipient phone (including extension)
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :phone
sig {
params(address: ::Stripe::InvoiceService::CreateParams::ShippingDetails::Address, name: String, phone: T.nilable(T.nilable(String))).void
}
def initialize(address: nil, name: nil, phone: nil); end
end
class TransferData < Stripe::RequestParams
# The amount that will be transferred automatically when the invoice is paid. If no amount is set, the full amount is transferred.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# ID of an existing, connected Stripe account.
sig { returns(String) }
attr_accessor :destination
sig { params(amount: T.nilable(Integer), destination: String).void }
def initialize(amount: nil, destination: nil); end
end
# The account tax IDs associated with the invoice. Only editable when the invoice is a draft.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :account_tax_ids
# List of expected payments and corresponding due dates. Valid only for invoices where `collection_method=send_invoice`.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceService::CreateParams::AmountsDue]))))
}
attr_accessor :amounts_due
# 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).
sig { returns(T.nilable(Integer)) }
attr_accessor :application_fee_amount
# Controls whether Stripe performs [automatic collection](https://stripe.com/docs/invoicing/integration/automatic-advancement-collection) of the invoice. If `false`, the invoice's state doesn't automatically advance without an explicit action.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :auto_advance
# Settings for automatic tax lookup for this invoice.
sig { returns(T.nilable(::Stripe::InvoiceService::CreateParams::AutomaticTax)) }
attr_accessor :automatic_tax
# The time when this invoice should be scheduled to finalize. The invoice will be finalized at this time if it is still in draft state.
sig { returns(T.nilable(Integer)) }
attr_accessor :automatically_finalizes_at
# 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`.
sig { returns(T.nilable(String)) }
attr_accessor :collection_method
# The currency to create this invoice in. Defaults to that of `customer` if not specified.
sig { returns(T.nilable(String)) }
attr_accessor :currency
# A list of up to 4 custom fields to be displayed on the invoice.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceService::CreateParams::CustomField]))))
}
attr_accessor :custom_fields
# The ID of the customer who will be billed.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# The ID of the account who will be billed.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# The number of days from when the invoice is created until it is due. Valid only for invoices where `collection_method=send_invoice`.
sig { returns(T.nilable(Integer)) }
attr_accessor :days_until_due
# The ids of the margins to apply to the invoice. Can be overridden by line item `margins`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :default_margins
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :default_payment_method
# ID of the default payment source for the invoice. It must belong to the customer associated with the invoice and be in a chargeable state. If not set, defaults to the subscription's default source, if any, or to the customer's default source.
sig { returns(T.nilable(String)) }
attr_accessor :default_source
# The tax rates that will apply to any line item that does not have `tax_rates` set.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :default_tax_rates
# An arbitrary string attached to the object. Often useful for displaying to users. Referenced as 'memo' in the Dashboard.
sig { returns(T.nilable(String)) }
attr_accessor :description
# The coupons and promotion codes 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.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceService::CreateParams::Discount]))))
}
attr_accessor :discounts
# The date on which payment for this invoice is due. Valid only for invoices where `collection_method=send_invoice`.
sig { returns(T.nilable(Integer)) }
attr_accessor :due_date
# The date when this invoice is in effect. Same as `finalized_at` unless overwritten. When defined, this value replaces the system-generated 'Date of issue' printed on the invoice PDF and receipt.
sig { returns(T.nilable(Integer)) }
attr_accessor :effective_at
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Footer to be displayed on the invoice.
sig { returns(T.nilable(String)) }
attr_accessor :footer
# 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.
sig { returns(T.nilable(::Stripe::InvoiceService::CreateParams::FromInvoice)) }
attr_accessor :from_invoice
# The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
sig { returns(T.nilable(::Stripe::InvoiceService::CreateParams::Issuer)) }
attr_accessor :issuer
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Set the number for this invoice. If no number is present then a number will be assigned automatically when the invoice is finalized. In many markets, regulations require invoices to be unique, sequential and / or gapless. You are responsible for ensuring this is true across all your different invoicing systems in the event that you edit the invoice number using our API. If you use only Stripe for your invoices and do not change invoice numbers, Stripe handles this aspect of compliance for you automatically.
sig { returns(T.nilable(String)) }
attr_accessor :number
# The account (if any) for which the funds of the invoice payment are intended. If set, the invoice will be presented with the branding and support information of the specified account. See the [Invoices with Connect](https://stripe.com/docs/billing/invoices/connect) documentation for details.
sig { returns(T.nilable(String)) }
attr_accessor :on_behalf_of
# Configuration settings for the PaymentIntent that is generated when the invoice is finalized.
sig { returns(T.nilable(::Stripe::InvoiceService::CreateParams::PaymentSettings)) }
attr_accessor :payment_settings
# How to handle pending invoice items on invoice creation. Defaults to `exclude` if the parameter is omitted.
sig { returns(T.nilable(String)) }
attr_accessor :pending_invoice_items_behavior
# The rendering-related settings that control how the invoice is displayed on customer-facing surfaces such as PDF and Hosted Invoice Page.
sig { returns(T.nilable(::Stripe::InvoiceService::CreateParams::Rendering)) }
attr_accessor :rendering
# Settings for the cost of shipping for this invoice.
sig { returns(T.nilable(::Stripe::InvoiceService::CreateParams::ShippingCost)) }
attr_accessor :shipping_cost
# Shipping details for the invoice. The Invoice PDF will use the `shipping_details` value if it is set, otherwise the PDF will render the shipping address from the customer.
sig { returns(T.nilable(::Stripe::InvoiceService::CreateParams::ShippingDetails)) }
attr_accessor :shipping_details
# Extra information about a charge for the customer's credit card statement. It must contain at least one letter. If not specified and this invoice is part of a subscription, the default `statement_descriptor` will be set to the first subscription item's product's `statement_descriptor`.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
# The ID of the subscription to invoice, if any. If set, the created invoice will only include pending invoice items for that subscription. The subscription's billing cycle and regular subscription events won't be affected.
sig { returns(T.nilable(String)) }
attr_accessor :subscription
# 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.
sig { returns(T.nilable(::Stripe::InvoiceService::CreateParams::TransferData)) }
attr_accessor :transfer_data
sig {
params(account_tax_ids: T.nilable(T.nilable(T.any(String, T::Array[String]))), amounts_due: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceService::CreateParams::AmountsDue]))), application_fee_amount: T.nilable(Integer), auto_advance: T.nilable(T::Boolean), automatic_tax: T.nilable(::Stripe::InvoiceService::CreateParams::AutomaticTax), automatically_finalizes_at: T.nilable(Integer), collection_method: T.nilable(String), currency: T.nilable(String), custom_fields: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceService::CreateParams::CustomField]))), customer: T.nilable(String), customer_account: T.nilable(String), days_until_due: T.nilable(Integer), default_margins: T.nilable(T::Array[String]), default_payment_method: T.nilable(String), default_source: T.nilable(String), default_tax_rates: T.nilable(T::Array[String]), description: T.nilable(String), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceService::CreateParams::Discount]))), due_date: T.nilable(Integer), effective_at: T.nilable(Integer), expand: T.nilable(T::Array[String]), footer: T.nilable(String), from_invoice: T.nilable(::Stripe::InvoiceService::CreateParams::FromInvoice), issuer: T.nilable(::Stripe::InvoiceService::CreateParams::Issuer), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), number: T.nilable(String), on_behalf_of: T.nilable(String), payment_settings: T.nilable(::Stripe::InvoiceService::CreateParams::PaymentSettings), pending_invoice_items_behavior: T.nilable(String), rendering: T.nilable(::Stripe::InvoiceService::CreateParams::Rendering), shipping_cost: T.nilable(::Stripe::InvoiceService::CreateParams::ShippingCost), shipping_details: T.nilable(::Stripe::InvoiceService::CreateParams::ShippingDetails), statement_descriptor: T.nilable(String), subscription: T.nilable(String), transfer_data: T.nilable(::Stripe::InvoiceService::CreateParams::TransferData)).void
}
def initialize(
account_tax_ids: nil,
amounts_due: nil,
application_fee_amount: nil,
auto_advance: nil,
automatic_tax: nil,
automatically_finalizes_at: nil,
collection_method: nil,
currency: nil,
custom_fields: nil,
customer: nil,
customer_account: nil,
days_until_due: nil,
default_margins: nil,
default_payment_method: nil,
default_source: nil,
default_tax_rates: nil,
description: nil,
discounts: nil,
due_date: nil,
effective_at: nil,
expand: nil,
footer: nil,
from_invoice: nil,
issuer: nil,
metadata: nil,
number: nil,
on_behalf_of: nil,
payment_settings: nil,
pending_invoice_items_behavior: nil,
rendering: nil,
shipping_cost: nil,
shipping_details: nil,
statement_descriptor: nil,
subscription: nil,
transfer_data: nil
); end
end
class SearchParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for pagination across multiple pages of results. Don't include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.
sig { returns(T.nilable(String)) }
attr_accessor :page
# The search query string. See [search query language](https://stripe.com/docs/search#search-query-language) and the list of supported [query fields for invoices](https://stripe.com/docs/search#query-fields-for-invoices).
sig { returns(String) }
attr_accessor :query
sig {
params(expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), page: T.nilable(String), query: String).void
}
def initialize(expand: nil, limit: nil, page: nil, query: nil); end
end
class AddLinesParams < Stripe::RequestParams
class Line < Stripe::RequestParams
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::InvoiceService::AddLinesParams::Line::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::InvoiceService::AddLinesParams::Line::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::InvoiceService::AddLinesParams::Line::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::InvoiceService::AddLinesParams::Line::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class Period < Stripe::RequestParams
# The end of the period, which must be greater than or equal to the start. This value is inclusive.
sig { returns(Integer) }
attr_accessor :end
# The start of the period. This value is inclusive.
sig { returns(Integer) }
attr_accessor :start
sig { params(end_: Integer, start: Integer).void }
def initialize(end_: nil, start: nil); end
end
class PriceData < Stripe::RequestParams
class ProductData < Stripe::RequestParams
# The product's description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes.
sig { returns(T.nilable(String)) }
attr_accessor :description
# A list of up to 8 URLs of images for this product, meant to be displayable to the customer.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :images
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The product's name, meant to be displayable to the customer.
sig { returns(String) }
attr_accessor :name
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
sig { returns(T.nilable(String)) }
attr_accessor :tax_code
sig {
params(description: T.nilable(String), images: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), name: String, tax_code: T.nilable(String)).void
}
def initialize(
description: nil,
images: nil,
metadata: nil,
name: nil,
tax_code: nil
); end
end
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to. One of `product` or `product_data` is required.
sig { returns(T.nilable(String)) }
attr_accessor :product
# Data used to generate a new [Product](https://docs.stripe.com/api/products) object inline. One of `product` or `product_data` is required.
sig {
returns(T.nilable(::Stripe::InvoiceService::AddLinesParams::Line::PriceData::ProductData))
}
attr_accessor :product_data
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A non-negative integer in cents (or local equivalent) representing how much to charge. One of `unit_amount` or `unit_amount_decimal` is required.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, product: T.nilable(String), product_data: T.nilable(::Stripe::InvoiceService::AddLinesParams::Line::PriceData::ProductData), tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
product_data: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
class Pricing < Stripe::RequestParams
# The ID of the price object.
sig { returns(T.nilable(String)) }
attr_accessor :price
sig { params(price: T.nilable(String)).void }
def initialize(price: nil); end
end
class TaxAmount < Stripe::RequestParams
class TaxRateData < Stripe::RequestParams
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# An arbitrary string attached to the tax rate for your internal use only. It will not be visible to your customers.
sig { returns(T.nilable(String)) }
attr_accessor :description
# The display name of the tax rate, which will be shown to users.
sig { returns(String) }
attr_accessor :display_name
# This specifies if the tax rate is inclusive or exclusive.
sig { returns(T::Boolean) }
attr_accessor :inclusive
# The jurisdiction for the tax rate. You can use this label field for tax reporting purposes. It also appears on your customer’s invoice.
sig { returns(T.nilable(String)) }
attr_accessor :jurisdiction
# The level of the jurisdiction that imposes this tax rate.
sig { returns(T.nilable(String)) }
attr_accessor :jurisdiction_level
# The statutory tax rate percent. This field accepts decimal values between 0 and 100 inclusive with at most 4 decimal places. To accommodate fixed-amount taxes, set the percentage to zero. Stripe will not display zero percentages on the invoice unless the `amount` of the tax is also zero.
sig { returns(Float) }
attr_accessor :percentage
# [ISO 3166-2 subdivision code](https://en.wikipedia.org/wiki/ISO_3166-2:US), without country prefix. For example, "NY" for New York, United States.
sig { returns(T.nilable(String)) }
attr_accessor :state
# The high-level tax type, such as `vat` or `sales_tax`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_type
sig {
params(country: T.nilable(String), description: T.nilable(String), display_name: String, inclusive: T::Boolean, jurisdiction: T.nilable(String), jurisdiction_level: T.nilable(String), percentage: Float, state: T.nilable(String), tax_type: T.nilable(String)).void
}
def initialize(
country: nil,
description: nil,
display_name: nil,
inclusive: nil,
jurisdiction: nil,
jurisdiction_level: nil,
percentage: nil,
state: nil,
tax_type: nil
); end
end
# The amount, in cents (or local equivalent), of the tax.
sig { returns(Integer) }
attr_accessor :amount
# Data to find or create a TaxRate object.
#
# Stripe automatically creates or reuses a TaxRate object for each tax amount. If the `tax_rate_data` exactly matches a previous value, Stripe will reuse the TaxRate object. TaxRate objects created automatically by Stripe are immediately archived, do not appear in the line item’s `tax_rates`, and cannot be directly added to invoices, payments, or line items.
sig { returns(::Stripe::InvoiceService::AddLinesParams::Line::TaxAmount::TaxRateData) }
attr_accessor :tax_rate_data
# The reasoning behind this tax, for example, if the product is tax exempt.
sig { returns(T.nilable(String)) }
attr_accessor :taxability_reason
# The amount on which tax is calculated, in cents (or local equivalent).
sig { returns(Integer) }
attr_accessor :taxable_amount
sig {
params(amount: Integer, tax_rate_data: ::Stripe::InvoiceService::AddLinesParams::Line::TaxAmount::TaxRateData, taxability_reason: T.nilable(String), taxable_amount: Integer).void
}
def initialize(
amount: nil,
tax_rate_data: nil,
taxability_reason: nil,
taxable_amount: nil
); end
end
# The integer amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. If you want to apply a credit to the customer's account, pass a negative amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# An arbitrary string which you can attach to the invoice item. The description is displayed in the invoice for easy tracking.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Controls whether discounts apply to this line item. Defaults to false for prorations or negative line items, and true for all other line items. Cannot be set to true for prorations.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :discountable
# The coupons, promotion codes & existing discounts which apply to the line item. Item discounts are applied before invoice discounts. Pass an empty string to remove previously-defined discounts.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceService::AddLinesParams::Line::Discount]))))
}
attr_accessor :discounts
# ID of an unassigned invoice item to assign to this invoice. If not provided, a new item will be created.
sig { returns(T.nilable(String)) }
attr_accessor :invoice_item
# The IDs of the margins to apply to the line item. When set, the `default_margins` on the invoice do not apply to this line item.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :margins
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :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.
sig { returns(T.nilable(::Stripe::InvoiceService::AddLinesParams::Line::Period)) }
attr_accessor :period
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
sig { returns(T.nilable(::Stripe::InvoiceService::AddLinesParams::Line::PriceData)) }
attr_accessor :price_data
# The pricing information for the invoice item.
sig { returns(T.nilable(::Stripe::InvoiceService::AddLinesParams::Line::Pricing)) }
attr_accessor :pricing
# Non-negative integer. The quantity of units for the line item.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# A list of up to 10 tax amounts for this line item. This can be useful if you calculate taxes on your own or use a third-party to calculate them. You cannot set tax amounts if any line item has [tax_rates](https://stripe.com/docs/api/invoices/line_item#invoice_line_item_object-tax_rates) or if the invoice has [default_tax_rates](https://stripe.com/docs/api/invoices/object#invoice_object-default_tax_rates) or uses [automatic tax](https://stripe.com/docs/tax/invoicing). Pass an empty string to remove previously defined tax amounts.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceService::AddLinesParams::Line::TaxAmount]))))
}
attr_accessor :tax_amounts
# The tax rates which apply to the line item. When set, the `default_tax_rates` on the invoice do not apply to this line item. Pass an empty string to remove previously-defined tax rates.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
sig {
params(amount: T.nilable(Integer), description: T.nilable(String), discountable: T.nilable(T::Boolean), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceService::AddLinesParams::Line::Discount]))), invoice_item: T.nilable(String), margins: T.nilable(T.nilable(T.any(String, T::Array[String]))), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), period: T.nilable(::Stripe::InvoiceService::AddLinesParams::Line::Period), price_data: T.nilable(::Stripe::InvoiceService::AddLinesParams::Line::PriceData), pricing: T.nilable(::Stripe::InvoiceService::AddLinesParams::Line::Pricing), quantity: T.nilable(Integer), tax_amounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceService::AddLinesParams::Line::TaxAmount]))), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String])))).void
}
def initialize(
amount: nil,
description: nil,
discountable: nil,
discounts: nil,
invoice_item: nil,
margins: nil,
metadata: nil,
period: nil,
price_data: nil,
pricing: nil,
quantity: nil,
tax_amounts: nil,
tax_rates: nil
); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :invoice_metadata
# The line items to add.
sig { returns(T::Array[::Stripe::InvoiceService::AddLinesParams::Line]) }
attr_accessor :lines
sig {
params(expand: T.nilable(T::Array[String]), invoice_metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), lines: T::Array[::Stripe::InvoiceService::AddLinesParams::Line]).void
}
def initialize(expand: nil, invoice_metadata: nil, lines: nil); end
end
class AttachPaymentParams < Stripe::RequestParams
class PaymentRecordData < Stripe::RequestParams
# The amount that was paid out of band.
sig { returns(Integer) }
attr_accessor :amount
# The currency that was paid out of band.
sig { returns(String) }
attr_accessor :currency
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# The type of money movement for this out of band payment record.
sig { returns(String) }
attr_accessor :money_movement_type
# The timestamp when this out of band payment was paid.
sig { returns(T.nilable(Integer)) }
attr_accessor :paid_at
# The reference for this out of band payment record.
sig { returns(T.nilable(String)) }
attr_accessor :payment_reference
sig {
params(amount: Integer, currency: String, metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), money_movement_type: String, paid_at: T.nilable(Integer), payment_reference: T.nilable(String)).void
}
def initialize(
amount: nil,
currency: nil,
metadata: nil,
money_movement_type: nil,
paid_at: nil,
payment_reference: nil
); end
end
# The portion of the `amount` on the PaymentIntent or out of band payment to apply to this invoice. It defaults to the entire amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount_requested
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The ID of the PaymentIntent to attach to the invoice.
sig { returns(T.nilable(String)) }
attr_accessor :payment_intent
# The ID of the PaymentRecord to attach to the invoice.
sig { returns(T.nilable(String)) }
attr_accessor :payment_record
# The PaymentRecord data for attaching an out of band payment to the invoice.
sig { returns(T.nilable(::Stripe::InvoiceService::AttachPaymentParams::PaymentRecordData)) }
attr_accessor :payment_record_data
sig {
params(amount_requested: T.nilable(Integer), expand: T.nilable(T::Array[String]), payment_intent: T.nilable(String), payment_record: T.nilable(String), payment_record_data: T.nilable(::Stripe::InvoiceService::AttachPaymentParams::PaymentRecordData)).void
}
def initialize(
amount_requested: nil,
expand: nil,
payment_intent: nil,
payment_record: nil,
payment_record_data: nil
); end
end
class FinalizeInvoiceParams < Stripe::RequestParams
# Controls whether Stripe performs [automatic collection](https://stripe.com/docs/invoicing/integration/automatic-advancement-collection) of the invoice. If `false`, the invoice's state doesn't automatically advance without an explicit action.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :auto_advance
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(auto_advance: T.nilable(T::Boolean), expand: T.nilable(T::Array[String])).void }
def initialize(auto_advance: nil, expand: nil); end
end
class MarkUncollectibleParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class PayParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# In cases where the source used to pay the invoice has insufficient funds, passing `forgive=true` controls whether a charge should be attempted for the full amount available on the source, up to the amount to fully pay the invoice. This effectively forgives the difference between the amount available on the source and the amount due.
#
# Passing `forgive=false` will fail the charge if the source hasn't been pre-funded with the right amount. An example for this case is with ACH Credit Transfers and wires: if the amount wired is less than the amount due by a small amount, you might want to forgive the difference. Defaults to `false`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :forgive
# ID of the mandate to be used for this invoice. It must correspond to the payment method used to pay the invoice, including the payment_method param or the invoice's default_payment_method or default_source, if set.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :mandate
# Indicates if a customer is on or off-session while an invoice payment is attempted. Defaults to `true` (off-session).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :off_session
# Boolean representing whether an invoice is paid outside of Stripe. This will result in no charge being made. Defaults to `false`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :paid_out_of_band
# A PaymentMethod to be charged. The PaymentMethod must be the ID of a PaymentMethod belonging to the customer associated with the invoice being paid.
sig { returns(T.nilable(String)) }
attr_accessor :payment_method
# A payment source to be charged. The source must be the ID of a source belonging to the customer associated with the invoice being paid.
sig { returns(T.nilable(String)) }
attr_accessor :source
sig {
params(expand: T.nilable(T::Array[String]), forgive: T.nilable(T::Boolean), mandate: T.nilable(T.nilable(String)), off_session: T.nilable(T::Boolean), paid_out_of_band: T.nilable(T::Boolean), payment_method: T.nilable(String), source: T.nilable(String)).void
}
def initialize(
expand: nil,
forgive: nil,
mandate: nil,
off_session: nil,
paid_out_of_band: nil,
payment_method: nil,
source: nil
); end
end
class RemoveLinesParams < Stripe::RequestParams
class Line < Stripe::RequestParams
# Either `delete` or `unassign`. Deleted line items are permanently deleted. Unassigned line items can be reassigned to an invoice.
sig { returns(String) }
attr_accessor :behavior
# ID of an existing line item to remove from this invoice.
sig { returns(String) }
attr_accessor :id
sig { params(behavior: String, id: String).void }
def initialize(behavior: nil, id: nil); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :invoice_metadata
# The line items to remove.
sig { returns(T::Array[::Stripe::InvoiceService::RemoveLinesParams::Line]) }
attr_accessor :lines
sig {
params(expand: T.nilable(T::Array[String]), invoice_metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), lines: T::Array[::Stripe::InvoiceService::RemoveLinesParams::Line]).void
}
def initialize(expand: nil, invoice_metadata: nil, lines: nil); end
end
class SendInvoiceParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateLinesParams < Stripe::RequestParams
class Line < Stripe::RequestParams
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::InvoiceService::UpdateLinesParams::Line::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::InvoiceService::UpdateLinesParams::Line::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::InvoiceService::UpdateLinesParams::Line::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::InvoiceService::UpdateLinesParams::Line::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class Period < Stripe::RequestParams
# The end of the period, which must be greater than or equal to the start. This value is inclusive.
sig { returns(Integer) }
attr_accessor :end
# The start of the period. This value is inclusive.
sig { returns(Integer) }
attr_accessor :start
sig { params(end_: Integer, start: Integer).void }
def initialize(end_: nil, start: nil); end
end
class PriceData < Stripe::RequestParams
class ProductData < Stripe::RequestParams
# The product's description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes.
sig { returns(T.nilable(String)) }
attr_accessor :description
# A list of up to 8 URLs of images for this product, meant to be displayable to the customer.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :images
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The product's name, meant to be displayable to the customer.
sig { returns(String) }
attr_accessor :name
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
sig { returns(T.nilable(String)) }
attr_accessor :tax_code
sig {
params(description: T.nilable(String), images: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), name: String, tax_code: T.nilable(String)).void
}
def initialize(
description: nil,
images: nil,
metadata: nil,
name: nil,
tax_code: nil
); end
end
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to. One of `product` or `product_data` is required.
sig { returns(T.nilable(String)) }
attr_accessor :product
# Data used to generate a new [Product](https://docs.stripe.com/api/products) object inline. One of `product` or `product_data` is required.
sig {
returns(T.nilable(::Stripe::InvoiceService::UpdateLinesParams::Line::PriceData::ProductData))
}
attr_accessor :product_data
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A non-negative integer in cents (or local equivalent) representing how much to charge. One of `unit_amount` or `unit_amount_decimal` is required.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, product: T.nilable(String), product_data: T.nilable(::Stripe::InvoiceService::UpdateLinesParams::Line::PriceData::ProductData), tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
product_data: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
class Pricing < Stripe::RequestParams
# The ID of the price object.
sig { returns(T.nilable(String)) }
attr_accessor :price
sig { params(price: T.nilable(String)).void }
def initialize(price: nil); end
end
class TaxAmount < Stripe::RequestParams
class TaxRateData < Stripe::RequestParams
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# An arbitrary string attached to the tax rate for your internal use only. It will not be visible to your customers.
sig { returns(T.nilable(String)) }
attr_accessor :description
# The display name of the tax rate, which will be shown to users.
sig { returns(String) }
attr_accessor :display_name
# This specifies if the tax rate is inclusive or exclusive.
sig { returns(T::Boolean) }
attr_accessor :inclusive
# The jurisdiction for the tax rate. You can use this label field for tax reporting purposes. It also appears on your customer’s invoice.
sig { returns(T.nilable(String)) }
attr_accessor :jurisdiction
# The level of the jurisdiction that imposes this tax rate.
sig { returns(T.nilable(String)) }
attr_accessor :jurisdiction_level
# The statutory tax rate percent. This field accepts decimal values between 0 and 100 inclusive with at most 4 decimal places. To accommodate fixed-amount taxes, set the percentage to zero. Stripe will not display zero percentages on the invoice unless the `amount` of the tax is also zero.
sig { returns(Float) }
attr_accessor :percentage
# [ISO 3166-2 subdivision code](https://en.wikipedia.org/wiki/ISO_3166-2:US), without country prefix. For example, "NY" for New York, United States.
sig { returns(T.nilable(String)) }
attr_accessor :state
# The high-level tax type, such as `vat` or `sales_tax`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_type
sig {
params(country: T.nilable(String), description: T.nilable(String), display_name: String, inclusive: T::Boolean, jurisdiction: T.nilable(String), jurisdiction_level: T.nilable(String), percentage: Float, state: T.nilable(String), tax_type: T.nilable(String)).void
}
def initialize(
country: nil,
description: nil,
display_name: nil,
inclusive: nil,
jurisdiction: nil,
jurisdiction_level: nil,
percentage: nil,
state: nil,
tax_type: nil
); end
end
# The amount, in cents (or local equivalent), of the tax.
sig { returns(Integer) }
attr_accessor :amount
# Data to find or create a TaxRate object.
#
# Stripe automatically creates or reuses a TaxRate object for each tax amount. If the `tax_rate_data` exactly matches a previous value, Stripe will reuse the TaxRate object. TaxRate objects created automatically by Stripe are immediately archived, do not appear in the line item’s `tax_rates`, and cannot be directly added to invoices, payments, or line items.
sig { returns(::Stripe::InvoiceService::UpdateLinesParams::Line::TaxAmount::TaxRateData) }
attr_accessor :tax_rate_data
# The reasoning behind this tax, for example, if the product is tax exempt.
sig { returns(T.nilable(String)) }
attr_accessor :taxability_reason
# The amount on which tax is calculated, in cents (or local equivalent).
sig { returns(Integer) }
attr_accessor :taxable_amount
sig {
params(amount: Integer, tax_rate_data: ::Stripe::InvoiceService::UpdateLinesParams::Line::TaxAmount::TaxRateData, taxability_reason: T.nilable(String), taxable_amount: Integer).void
}
def initialize(
amount: nil,
tax_rate_data: nil,
taxability_reason: nil,
taxable_amount: nil
); end
end
# The integer amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. If you want to apply a credit to the customer's account, pass a negative amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# An arbitrary string which you can attach to the invoice item. The description is displayed in the invoice for easy tracking.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Controls whether discounts apply to this line item. Defaults to false for prorations or negative line items, and true for all other line items. Cannot be set to true for prorations.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :discountable
# The coupons, promotion codes & existing discounts which apply to the line item. Item discounts are applied before invoice discounts. Pass an empty string to remove previously-defined discounts.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceService::UpdateLinesParams::Line::Discount]))))
}
attr_accessor :discounts
# ID of an existing line item on the invoice.
sig { returns(String) }
attr_accessor :id
# The IDs of the margins to apply to the line item. When set, the `default_margins` on the invoice do not apply to this line item.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :margins
# 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`. For [type=subscription](https://stripe.com/docs/api/invoices/line_item#invoice_line_item_object-type) line items, the incoming metadata specified on the request is directly used to set this value, in contrast to [type=invoiceitem](api/invoices/line_item#invoice_line_item_object-type) line items, where any existing metadata on the invoice line is merged with the incoming data.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :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.
sig { returns(T.nilable(::Stripe::InvoiceService::UpdateLinesParams::Line::Period)) }
attr_accessor :period
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
sig { returns(T.nilable(::Stripe::InvoiceService::UpdateLinesParams::Line::PriceData)) }
attr_accessor :price_data
# The pricing information for the invoice item.
sig { returns(T.nilable(::Stripe::InvoiceService::UpdateLinesParams::Line::Pricing)) }
attr_accessor :pricing
# Non-negative integer. The quantity of units for the line item.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# A list of up to 10 tax amounts for this line item. This can be useful if you calculate taxes on your own or use a third-party to calculate them. You cannot set tax amounts if any line item has [tax_rates](https://stripe.com/docs/api/invoices/line_item#invoice_line_item_object-tax_rates) or if the invoice has [default_tax_rates](https://stripe.com/docs/api/invoices/object#invoice_object-default_tax_rates) or uses [automatic tax](https://stripe.com/docs/tax/invoicing). Pass an empty string to remove previously defined tax amounts.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceService::UpdateLinesParams::Line::TaxAmount]))))
}
attr_accessor :tax_amounts
# The tax rates which apply to the line item. When set, the `default_tax_rates` on the invoice do not apply to this line item. Pass an empty string to remove previously-defined tax rates.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
sig {
params(amount: T.nilable(Integer), description: T.nilable(String), discountable: T.nilable(T::Boolean), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceService::UpdateLinesParams::Line::Discount]))), id: String, margins: T.nilable(T.nilable(T.any(String, T::Array[String]))), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), period: T.nilable(::Stripe::InvoiceService::UpdateLinesParams::Line::Period), price_data: T.nilable(::Stripe::InvoiceService::UpdateLinesParams::Line::PriceData), pricing: T.nilable(::Stripe::InvoiceService::UpdateLinesParams::Line::Pricing), quantity: T.nilable(Integer), tax_amounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceService::UpdateLinesParams::Line::TaxAmount]))), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String])))).void
}
def initialize(
amount: nil,
description: nil,
discountable: nil,
discounts: nil,
id: nil,
margins: nil,
metadata: nil,
period: nil,
price_data: nil,
pricing: nil,
quantity: nil,
tax_amounts: nil,
tax_rates: nil
); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`. For [type=subscription](https://stripe.com/docs/api/invoices/line_item#invoice_line_item_object-type) line items, the incoming metadata specified on the request is directly used to set this value, in contrast to [type=invoiceitem](api/invoices/line_item#invoice_line_item_object-type) line items, where any existing metadata on the invoice line is merged with the incoming data.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :invoice_metadata
# The line items to update.
sig { returns(T::Array[::Stripe::InvoiceService::UpdateLinesParams::Line]) }
attr_accessor :lines
sig {
params(expand: T.nilable(T::Array[String]), invoice_metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), lines: T::Array[::Stripe::InvoiceService::UpdateLinesParams::Line]).void
}
def initialize(expand: nil, invoice_metadata: nil, lines: nil); end
end
class VoidInvoiceParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class CreatePreviewParams < Stripe::RequestParams
class AutomaticTax < Stripe::RequestParams
class Liability < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# 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.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::AutomaticTax::Liability))
}
attr_accessor :liability
sig {
params(enabled: T::Boolean, liability: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::AutomaticTax::Liability)).void
}
def initialize(enabled: nil, liability: nil); end
end
class CustomerDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class Shipping < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# A freeform text field for the country. However, in order to activate some tax features, the format should be a two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Customer shipping address.
sig {
returns(::Stripe::InvoiceService::CreatePreviewParams::CustomerDetails::Shipping::Address)
}
attr_accessor :address
# Customer name.
sig { returns(String) }
attr_accessor :name
# Customer phone (including extension).
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(address: ::Stripe::InvoiceService::CreatePreviewParams::CustomerDetails::Shipping::Address, name: String, phone: T.nilable(String)).void
}
def initialize(address: nil, name: nil, phone: nil); end
end
class Tax < Stripe::RequestParams
# 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.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :ip_address
sig { params(ip_address: T.nilable(T.nilable(String))).void }
def initialize(ip_address: nil); end
end
class TaxId < Stripe::RequestParams
# Type of the tax ID, one of `ad_nrt`, `ae_trn`, `al_tin`, `am_tin`, `ao_tin`, `ar_cuit`, `au_abn`, `au_arn`, `aw_tin`, `az_tin`, `ba_tin`, `bb_tin`, `bd_bin`, `bf_ifu`, `bg_uic`, `bh_vat`, `bj_ifu`, `bo_tin`, `br_cnpj`, `br_cpf`, `bs_tin`, `by_tin`, `ca_bn`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `ca_qst`, `cd_nif`, `ch_uid`, `ch_vat`, `cl_tin`, `cm_niu`, `cn_tin`, `co_nit`, `cr_tin`, `cv_nif`, `de_stn`, `do_rcn`, `ec_ruc`, `eg_tin`, `es_cif`, `et_tin`, `eu_oss_vat`, `eu_vat`, `gb_vat`, `ge_vat`, `gn_nif`, `hk_br`, `hr_oib`, `hu_tin`, `id_npwp`, `il_vat`, `in_gst`, `is_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `ke_pin`, `kg_tin`, `kh_tin`, `kr_brn`, `kz_bin`, `la_tin`, `li_uid`, `li_vat`, `ma_vat`, `md_vat`, `me_pib`, `mk_vat`, `mr_nif`, `mx_rfc`, `my_frp`, `my_itn`, `my_sst`, `ng_tin`, `no_vat`, `no_voec`, `np_pan`, `nz_gst`, `om_vat`, `pe_ruc`, `ph_tin`, `ro_tin`, `rs_pib`, `ru_inn`, `ru_kpp`, `sa_vat`, `sg_gst`, `sg_uen`, `si_tin`, `sn_ninea`, `sr_fin`, `sv_nit`, `th_vat`, `tj_tin`, `tr_tin`, `tw_vat`, `tz_vat`, `ua_vat`, `ug_tin`, `us_ein`, `uy_ruc`, `uz_tin`, `uz_vat`, `ve_rif`, `vn_tin`, `za_vat`, `zm_tin`, or `zw_tin`
sig { returns(String) }
attr_accessor :type
# Value of the tax ID.
sig { returns(String) }
attr_accessor :value
sig { params(type: String, value: String).void }
def initialize(type: nil, value: nil); end
end
# The customer's address.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::CreatePreviewParams::CustomerDetails::Address))))
}
attr_accessor :address
# The customer's shipping information. Appears on invoices emailed to this customer.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::CreatePreviewParams::CustomerDetails::Shipping))))
}
attr_accessor :shipping
# Tax details about the customer.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::CustomerDetails::Tax))
}
attr_accessor :tax
# The customer's tax exemption. One of `none`, `exempt`, or `reverse`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :tax_exempt
# The customer's tax IDs.
sig {
returns(T.nilable(T::Array[::Stripe::InvoiceService::CreatePreviewParams::CustomerDetails::TaxId]))
}
attr_accessor :tax_ids
sig {
params(address: T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::CreatePreviewParams::CustomerDetails::Address))), shipping: T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::CreatePreviewParams::CustomerDetails::Shipping))), tax: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::CustomerDetails::Tax), tax_exempt: T.nilable(T.nilable(T.any(String, String))), tax_ids: T.nilable(T::Array[::Stripe::InvoiceService::CreatePreviewParams::CustomerDetails::TaxId])).void
}
def initialize(address: nil, shipping: nil, tax: nil, tax_exempt: nil, tax_ids: nil); end
end
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class InvoiceItem < Stripe::RequestParams
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::InvoiceItem::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::InvoiceItem::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::InvoiceItem::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::InvoiceItem::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class Period < Stripe::RequestParams
# The end of the period, which must be greater than or equal to the start. This value is inclusive.
sig { returns(Integer) }
attr_accessor :end
# The start of the period. This value is inclusive.
sig { returns(Integer) }
attr_accessor :start
sig { params(end_: Integer, start: Integer).void }
def initialize(end_: nil, start: nil); end
end
class PriceData < Stripe::RequestParams
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
sig { returns(String) }
attr_accessor :product
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, product: String, tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
# The integer amount in cents (or local equivalent) of previewed invoice item.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :currency
# An arbitrary string which you can attach to the invoice item. The description is displayed in the invoice for easy tracking.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Explicitly controls whether discounts apply to this invoice item. Defaults to true, except for negative invoice items.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :discountable
# The coupons to redeem into discounts for the invoice item in the preview.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceService::CreatePreviewParams::InvoiceItem::Discount]))))
}
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :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.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::InvoiceItem::Period))
}
attr_accessor :period
# The ID of the price object. One of `price` or `price_data` is required.
sig { returns(T.nilable(String)) }
attr_accessor :price
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::InvoiceItem::PriceData))
}
attr_accessor :price_data
# Non-negative integer. The quantity of units for the invoice item.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :tax_code
# The tax rates that apply to the item. When set, any `default_tax_rates` do not apply to this item.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :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.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(amount: T.nilable(Integer), currency: T.nilable(String), description: T.nilable(String), discountable: T.nilable(T::Boolean), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceService::CreatePreviewParams::InvoiceItem::Discount]))), invoiceitem: T.nilable(String), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), period: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::InvoiceItem::Period), price: T.nilable(String), price_data: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::InvoiceItem::PriceData), quantity: T.nilable(Integer), tax_behavior: T.nilable(String), tax_code: T.nilable(T.nilable(String)), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String]))), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
amount: nil,
currency: nil,
description: nil,
discountable: nil,
discounts: nil,
invoiceitem: nil,
metadata: nil,
period: nil,
price: nil,
price_data: nil,
quantity: nil,
tax_behavior: nil,
tax_code: nil,
tax_rates: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
class Issuer < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
class ScheduleDetails < Stripe::RequestParams
class Amendment < Stripe::RequestParams
class AmendmentEnd < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
# The ID of a specific discount.
sig { returns(String) }
attr_accessor :discount
sig { params(discount: String).void }
def initialize(discount: nil); end
end
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Use the `end` time of a given discount.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::AmendmentEnd::DiscountEnd))
}
attr_accessor :discount_end
# Time span for the amendment starting from the `amendment_start`.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::AmendmentEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the amendment to end. Must be after the `amendment_start`.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# Select one of three ways to pass the `amendment_end`.
sig { returns(String) }
attr_accessor :type
sig {
params(discount_end: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::AmendmentEnd::DiscountEnd), duration: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::AmendmentEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(discount_end: nil, duration: nil, timestamp: nil, type: nil); end
end
class AmendmentStart < Stripe::RequestParams
class AmendmentEnd < Stripe::RequestParams
# The position of the previous amendment in the `amendments` array after which this amendment should begin. Indexes start from 0 and must be less than the index of the current amendment in the array.
sig { returns(Integer) }
attr_accessor :index
sig { params(index: Integer).void }
def initialize(index: nil); end
end
class DiscountEnd < Stripe::RequestParams
# The ID of a specific discount.
sig { returns(String) }
attr_accessor :discount
sig { params(discount: String).void }
def initialize(discount: nil); end
end
# Details of another amendment in the same array, immediately after which this amendment should begin.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::AmendmentStart::AmendmentEnd))
}
attr_accessor :amendment_end
# Use the `end` time of a given discount.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::AmendmentStart::DiscountEnd))
}
attr_accessor :discount_end
# A precise Unix timestamp for the amendment to start.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# Select one of three ways to pass the `amendment_start`.
sig { returns(String) }
attr_accessor :type
sig {
params(amendment_end: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::AmendmentStart::AmendmentEnd), discount_end: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::AmendmentStart::DiscountEnd), timestamp: T.nilable(Integer), type: String).void
}
def initialize(amendment_end: nil, discount_end: nil, timestamp: nil, type: nil); end
end
class DiscountAction < Stripe::RequestParams
class Add < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
# The coupon code to redeem.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# An ID of an existing discount for a coupon that was already redeemed.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::DiscountAction::Add::DiscountEnd))
}
attr_accessor :discount_end
# The index, starting at 0, at which to position the new discount. When not supplied, Stripe defaults to appending the discount to the end of the `discounts` array.
sig { returns(T.nilable(Integer)) }
attr_accessor :index
# The promotion code to redeem.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::DiscountAction::Add::DiscountEnd), index: T.nilable(Integer), promotion_code: T.nilable(String)).void
}
def initialize(
coupon: nil,
discount: nil,
discount_end: nil,
index: nil,
promotion_code: nil
); end
end
class Remove < Stripe::RequestParams
# The coupon code to remove from the `discounts` array.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# The ID of a discount to remove from the `discounts` array.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# The ID of a promotion code to remove from the `discounts` array.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, promotion_code: nil); end
end
class Set < Stripe::RequestParams
# The coupon code to replace the `discounts` array with.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# An ID of an existing discount to replace the `discounts` array with.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# An ID of an existing promotion code to replace the `discounts` array with.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, promotion_code: nil); end
end
# Details of the discount to add.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::DiscountAction::Add))
}
attr_accessor :add
# Details of the discount to remove.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::DiscountAction::Remove))
}
attr_accessor :remove
# Details of the discount to replace the existing discounts with.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::DiscountAction::Set))
}
attr_accessor :set
# Determines the type of discount action.
sig { returns(String) }
attr_accessor :type
sig {
params(add: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::DiscountAction::Add), remove: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::DiscountAction::Remove), set: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::DiscountAction::Set), type: String).void
}
def initialize(add: nil, remove: nil, set: nil, type: nil); end
end
class ItemAction < Stripe::RequestParams
class Add < Stripe::RequestParams
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction::Add::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction::Add::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction::Add::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction::Add::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(
coupon: nil,
discount: nil,
discount_end: nil,
promotion_code: nil
); end
end
class Trial < Stripe::RequestParams
# List of price IDs which, if present on the subscription following a paid trial, constitute opting-in to the paid trial. Currently only supports at most 1 price ID.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :converts_to
# Determines the type of trial for this item.
sig { returns(String) }
attr_accessor :type
sig { params(converts_to: T.nilable(T::Array[String]), type: String).void }
def initialize(converts_to: nil, type: nil); end
end
# The discounts applied to the item. Subscription item discounts are applied before subscription discounts.
sig {
returns(T.nilable(T::Array[::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction::Add::Discount]))
}
attr_accessor :discounts
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The ID of the price object.
sig { returns(String) }
attr_accessor :price
# Quantity for this item.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# The tax rates that apply to this subscription item. When set, the `default_tax_rates` on the subscription do not apply to this `subscription_item`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :tax_rates
# Options that configure the trial on the subscription item.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction::Add::Trial))
}
attr_accessor :trial
sig {
params(discounts: T.nilable(T::Array[::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction::Add::Discount]), metadata: T.nilable(T::Hash[String, String]), price: String, quantity: T.nilable(Integer), tax_rates: T.nilable(T::Array[String]), trial: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction::Add::Trial)).void
}
def initialize(
discounts: nil,
metadata: nil,
price: nil,
quantity: nil,
tax_rates: nil,
trial: nil
); end
end
class Remove < Stripe::RequestParams
# ID of a price to remove.
sig { returns(String) }
attr_accessor :price
sig { params(price: String).void }
def initialize(price: nil); end
end
class Set < Stripe::RequestParams
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction::Set::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction::Set::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction::Set::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction::Set::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(
coupon: nil,
discount: nil,
discount_end: nil,
promotion_code: nil
); end
end
class Trial < Stripe::RequestParams
# List of price IDs which, if present on the subscription following a paid trial, constitute opting-in to the paid trial. Currently only supports at most 1 price ID.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :converts_to
# Determines the type of trial for this item.
sig { returns(String) }
attr_accessor :type
sig { params(converts_to: T.nilable(T::Array[String]), type: String).void }
def initialize(converts_to: nil, type: nil); end
end
# If an item with the `price` already exists, passing this will override the `discounts` array on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `discounts`.
sig {
returns(T.nilable(T::Array[::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction::Set::Discount]))
}
attr_accessor :discounts
# If an item with the `price` already exists, passing this will override the `metadata` on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `metadata`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The ID of the price object.
sig { returns(String) }
attr_accessor :price
# If an item with the `price` already exists, passing this will override the quantity on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `quantity`.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# If an item with the `price` already exists, passing this will override the `tax_rates` array on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `tax_rates`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :tax_rates
# If an item with the `price` already exists, passing this will override the `trial` configuration on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `trial`.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction::Set::Trial))
}
attr_accessor :trial
sig {
params(discounts: T.nilable(T::Array[::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction::Set::Discount]), metadata: T.nilable(T::Hash[String, String]), price: String, quantity: T.nilable(Integer), tax_rates: T.nilable(T::Array[String]), trial: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction::Set::Trial)).void
}
def initialize(
discounts: nil,
metadata: nil,
price: nil,
quantity: nil,
tax_rates: nil,
trial: nil
); end
end
# Details of the subscription item to add. If an item with the same `price` exists, it will be replaced by this new item. Otherwise, it adds the new item.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction::Add))
}
attr_accessor :add
# Details of the subscription item to remove.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction::Remove))
}
attr_accessor :remove
# Details of the subscription item to replace the existing items with. If an item with the `set[price]` already exists, the `items` array is not cleared. Instead, all of the other `set` properties that are passed in this request will replace the existing values for the configuration item.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction::Set))
}
attr_accessor :set
# Determines the type of item action.
sig { returns(String) }
attr_accessor :type
sig {
params(add: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction::Add), remove: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction::Remove), set: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction::Set), type: String).void
}
def initialize(add: nil, remove: nil, set: nil, type: nil); end
end
class MetadataAction < Stripe::RequestParams
# Key-value pairs to add to schedule phase metadata. These values will merge with existing schedule phase metadata.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :add
# Keys to remove from schedule phase metadata.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :remove
# Key-value pairs to set as schedule phase metadata. Existing schedule phase metadata will be overwritten.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :set
# Select one of three ways to update phase-level `metadata` on subscription schedules.
sig { returns(String) }
attr_accessor :type
sig {
params(add: T.nilable(T::Hash[String, String]), remove: T.nilable(T::Array[String]), set: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), type: String).void
}
def initialize(add: nil, remove: nil, set: nil, type: nil); end
end
class SetPauseCollection < Stripe::RequestParams
class Set < Stripe::RequestParams
# The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`.
sig { returns(String) }
attr_accessor :behavior
sig { params(behavior: String).void }
def initialize(behavior: nil); end
end
# Details of the pause_collection behavior to apply to the amendment.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::SetPauseCollection::Set))
}
attr_accessor :set
# Determines the type of the pause_collection amendment.
sig { returns(String) }
attr_accessor :type
sig {
params(set: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::SetPauseCollection::Set), type: String).void
}
def initialize(set: nil, type: nil); end
end
class TrialSettings < Stripe::RequestParams
class EndBehavior < Stripe::RequestParams
# Configure how an opt-in following a paid trial is billed when using `billing_behavior: prorate_up_front`.
sig { returns(T.nilable(String)) }
attr_accessor :prorate_up_front
sig { params(prorate_up_front: T.nilable(String)).void }
def initialize(prorate_up_front: nil); end
end
# Defines how the subscription should behave when a trial ends.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::TrialSettings::EndBehavior))
}
attr_accessor :end_behavior
sig {
params(end_behavior: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::TrialSettings::EndBehavior)).void
}
def initialize(end_behavior: nil); end
end
# Details to identify the end of the time range modified by the proposed change. If not supplied, the amendment is considered a point-in-time operation that only affects the exact timestamp at `amendment_start`, and a restricted set of attributes is supported on the amendment.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::AmendmentEnd))
}
attr_accessor :amendment_end
# Details to identify the earliest timestamp where the proposed change should take effect.
sig {
returns(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::AmendmentStart)
}
attr_accessor :amendment_start
# For point-in-time amendments (having no `amendment_end`), this attribute lets you set or remove whether the subscription's billing cycle anchor is reset at the `amendment_start` timestamp.For time-span based amendments (having both `amendment_start` and `amendment_end`), the only value valid is `automatic`, which removes any previously configured billing cycle anchor resets scheduled to occur during the window of time spanned by the amendment.
sig { returns(T.nilable(String)) }
attr_accessor :billing_cycle_anchor
# Changes to the coupons being redeemed or discounts being applied during the amendment time span.
sig {
returns(T.nilable(T::Array[::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::DiscountAction]))
}
attr_accessor :discount_actions
# Changes to the subscription items during the amendment time span.
sig {
returns(T.nilable(T::Array[::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction]))
}
attr_accessor :item_actions
# Instructions for how to modify phase metadata
sig {
returns(T.nilable(T::Array[::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::MetadataAction]))
}
attr_accessor :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`.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
# Defines how to pause collection for the underlying subscription throughout the duration of the amendment.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::SetPauseCollection))
}
attr_accessor :set_pause_collection
# Ends the subscription schedule early as dictated by either the accompanying amendment's start or end.
sig { returns(T.nilable(String)) }
attr_accessor :set_schedule_end
# Settings related to subscription trials.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::TrialSettings))
}
attr_accessor :trial_settings
sig {
params(amendment_end: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::AmendmentEnd), amendment_start: ::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::AmendmentStart, billing_cycle_anchor: T.nilable(String), discount_actions: T.nilable(T::Array[::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::DiscountAction]), item_actions: T.nilable(T::Array[::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::ItemAction]), metadata_actions: T.nilable(T::Array[::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::MetadataAction]), proration_behavior: T.nilable(String), set_pause_collection: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::SetPauseCollection), set_schedule_end: T.nilable(String), trial_settings: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment::TrialSettings)).void
}
def initialize(
amendment_end: nil,
amendment_start: nil,
billing_cycle_anchor: nil,
discount_actions: nil,
item_actions: nil,
metadata_actions: nil,
proration_behavior: nil,
set_pause_collection: nil,
set_schedule_end: nil,
trial_settings: nil
); end
end
class Phase < Stripe::RequestParams
class AddInvoiceItem < Stripe::RequestParams
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::AddInvoiceItem::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::AddInvoiceItem::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::AddInvoiceItem::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::AddInvoiceItem::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(
coupon: nil,
discount: nil,
discount_end: nil,
promotion_code: nil
); end
end
class PriceData < Stripe::RequestParams
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
sig { returns(String) }
attr_accessor :product
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge or a negative integer representing the amount to credit to the customer.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, product: String, tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
# The coupons to redeem into discounts for the item.
sig {
returns(T.nilable(T::Array[::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::AddInvoiceItem::Discount]))
}
attr_accessor :discounts
# The ID of the price object. One of `price` or `price_data` is required.
sig { returns(T.nilable(String)) }
attr_accessor :price
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::AddInvoiceItem::PriceData))
}
attr_accessor :price_data
# Quantity for this item. Defaults to 1.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# The tax rates which apply to the item. When set, the `default_tax_rates` do not apply to this item.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
sig {
params(discounts: T.nilable(T::Array[::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::AddInvoiceItem::Discount]), price: T.nilable(String), price_data: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::AddInvoiceItem::PriceData), quantity: T.nilable(Integer), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String])))).void
}
def initialize(
discounts: nil,
price: nil,
price_data: nil,
quantity: nil,
tax_rates: nil
); end
end
class AutomaticTax < Stripe::RequestParams
class Liability < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# Enabled automatic tax calculation which will automatically compute tax rates on all invoices generated by the subscription.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::AutomaticTax::Liability))
}
attr_accessor :liability
sig {
params(enabled: T::Boolean, liability: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::AutomaticTax::Liability)).void
}
def initialize(enabled: nil, liability: nil); end
end
class BillingThresholds < Stripe::RequestParams
# Monetary threshold that triggers the subscription to advance to a new billing period
sig { returns(T.nilable(Integer)) }
attr_accessor :amount_gte
# Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :reset_billing_cycle_anchor
sig {
params(amount_gte: T.nilable(Integer), reset_billing_cycle_anchor: T.nilable(T::Boolean)).void
}
def initialize(amount_gte: nil, reset_billing_cycle_anchor: nil); end
end
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class InvoiceSettings < Stripe::RequestParams
class Issuer < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# The account tax IDs associated with this phase of the subscription schedule. Will be set on invoices generated by this phase of the subscription schedule.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :account_tax_ids
# Number of days within which a customer must pay invoices generated by this subscription schedule. This value will be `null` for subscription schedules where `billing=charge_automatically`.
sig { returns(T.nilable(Integer)) }
attr_accessor :days_until_due
# The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::InvoiceSettings::Issuer))
}
attr_accessor :issuer
sig {
params(account_tax_ids: T.nilable(T.nilable(T.any(String, T::Array[String]))), days_until_due: T.nilable(Integer), issuer: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::InvoiceSettings::Issuer)).void
}
def initialize(account_tax_ids: nil, days_until_due: nil, issuer: nil); end
end
class Item < Stripe::RequestParams
class BillingThresholds < Stripe::RequestParams
# Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))
sig { returns(Integer) }
attr_accessor :usage_gte
sig { params(usage_gte: Integer).void }
def initialize(usage_gte: nil); end
end
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::Item::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::Item::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::Item::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::Item::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(
coupon: nil,
discount: nil,
discount_end: nil,
promotion_code: nil
); end
end
class PriceData < Stripe::RequestParams
class Recurring < Stripe::RequestParams
# Specifies billing frequency. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: T.nilable(Integer)).void }
def initialize(interval: nil, interval_count: nil); end
end
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
sig { returns(String) }
attr_accessor :product
# The recurring components of a price such as `interval` and `interval_count`.
sig {
returns(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::Item::PriceData::Recurring)
}
attr_accessor :recurring
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, product: String, recurring: ::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::Item::PriceData::Recurring, tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
recurring: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
class Trial < Stripe::RequestParams
# List of price IDs which, if present on the subscription following a paid trial, constitute opting-in to the paid trial. Currently only supports at most 1 price ID.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :converts_to
# Determines the type of trial for this item.
sig { returns(String) }
attr_accessor :type
sig { params(converts_to: T.nilable(T::Array[String]), type: String).void }
def initialize(converts_to: nil, type: nil); end
end
# Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::Item::BillingThresholds))))
}
attr_accessor :billing_thresholds
# The coupons to redeem into discounts for the subscription item.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::Item::Discount]))))
}
attr_accessor :discounts
# Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to a configuration item. Metadata on a configuration item will update the underlying subscription item's `metadata` when the phase is entered, adding new keys and replacing existing keys. Individual keys in the subscription item's `metadata` can be unset by posting an empty value to them in the configuration item's `metadata`. To unset all keys in the subscription item's `metadata`, update the subscription item directly or unset every key individually from the configuration item's `metadata`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The plan ID to subscribe to. You may specify the same ID in `plan` and `price`.
sig { returns(T.nilable(String)) }
attr_accessor :plan
# The ID of the price object.
sig { returns(T.nilable(String)) }
attr_accessor :price
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::Item::PriceData))
}
attr_accessor :price_data
# Quantity for the given price. Can be set only if the price's `usage_type` is `licensed` and not `metered`.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
# Options that configure the trial on the subscription item.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::Item::Trial))
}
attr_accessor :trial
sig {
params(billing_thresholds: T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::Item::BillingThresholds))), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::Item::Discount]))), metadata: T.nilable(T::Hash[String, String]), plan: T.nilable(String), price: T.nilable(String), price_data: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::Item::PriceData), quantity: T.nilable(Integer), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String]))), trial: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::Item::Trial)).void
}
def initialize(
billing_thresholds: nil,
discounts: nil,
metadata: nil,
plan: nil,
price: nil,
price_data: nil,
quantity: nil,
tax_rates: nil,
trial: nil
); end
end
class PauseCollection < Stripe::RequestParams
# The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`.
sig { returns(String) }
attr_accessor :behavior
sig { params(behavior: String).void }
def initialize(behavior: nil); end
end
class TransferData < Stripe::RequestParams
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
sig { returns(T.nilable(Float)) }
attr_accessor :amount_percent
# ID of an existing, connected Stripe account.
sig { returns(String) }
attr_accessor :destination
sig { params(amount_percent: T.nilable(Float), destination: String).void }
def initialize(amount_percent: nil, destination: nil); end
end
class TrialSettings < Stripe::RequestParams
class EndBehavior < Stripe::RequestParams
# Configure how an opt-in following a paid trial is billed when using `billing_behavior: prorate_up_front`.
sig { returns(T.nilable(String)) }
attr_accessor :prorate_up_front
sig { params(prorate_up_front: T.nilable(String)).void }
def initialize(prorate_up_front: nil); end
end
# Defines how the subscription should behave when a trial ends.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::TrialSettings::EndBehavior))
}
attr_accessor :end_behavior
sig {
params(end_behavior: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::TrialSettings::EndBehavior)).void
}
def initialize(end_behavior: nil); end
end
# A list of prices and quantities that will generate invoice items appended to the next invoice for this phase. You may pass up to 20 items.
sig {
returns(T.nilable(T::Array[::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::AddInvoiceItem]))
}
attr_accessor :add_invoice_items
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).
sig { returns(T.nilable(Float)) }
attr_accessor :application_fee_percent
# Automatic tax settings for this phase.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::AutomaticTax))
}
attr_accessor :automatic_tax
# Can be set to `phase_start` to set the anchor to the start of the phase or `automatic` to automatically change it if needed. Cannot be set to `phase_start` if this phase specifies a trial. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).
sig { returns(T.nilable(String)) }
attr_accessor :billing_cycle_anchor
# Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::BillingThresholds))))
}
attr_accessor :billing_thresholds
# Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically` on creation.
sig { returns(T.nilable(String)) }
attr_accessor :collection_method
# 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).
sig { returns(T.nilable(String)) }
attr_accessor :currency
# ID of the default payment method for the subscription schedule. It must belong to the customer associated with the subscription schedule. If not set, invoices will use the default payment method in the customer's invoice settings.
sig { returns(T.nilable(String)) }
attr_accessor :default_payment_method
# A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will set the Subscription's [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates), which means they will be the Invoice's [`default_tax_rates`](https://stripe.com/docs/api/invoices/create#create_invoice-default_tax_rates) for any Invoices issued by the Subscription during this Phase.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :default_tax_rates
# Subscription description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :description
# The coupons to redeem into discounts for the schedule phase. If not specified, inherits the discount from the subscription's customer. Pass an empty string to avoid inheriting any discounts.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::Discount]))))
}
attr_accessor :discounts
# The date at which this phase of the subscription schedule ends. If set, `iterations` must not be set.
sig { returns(T.nilable(T.any(Integer, String))) }
attr_accessor :end_date
# All invoices will be billed using the specified settings.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::InvoiceSettings))
}
attr_accessor :invoice_settings
# List of configuration items, each with an attached price, to apply during this phase of the subscription schedule.
sig {
returns(T::Array[::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::Item])
}
attr_accessor :items
# Integer representing the multiplier applied to the price interval. For example, `iterations=2` applied to a price with `interval=month` and `interval_count=3` results in a phase of duration `2 * 3 months = 6 months`. If set, `end_date` must not be set.
sig { returns(T.nilable(Integer)) }
attr_accessor :iterations
# Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to a phase. Metadata on a schedule's phase will update the underlying subscription's `metadata` when the phase is entered, adding new keys and replacing existing keys in the subscription's `metadata`. Individual keys in the subscription's `metadata` can be unset by posting an empty value to them in the phase's `metadata`. To unset all keys in the subscription's `metadata`, update the subscription directly or unset every key individually from the phase's `metadata`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The account on behalf of which to charge, for each of the associated subscription's invoices.
sig { returns(T.nilable(String)) }
attr_accessor :on_behalf_of
# If specified, payment collection for this subscription will be paused. Note that the subscription status will be unchanged and will not be updated to `paused`. Learn more about [pausing collection](https://stripe.com/docs/billing/subscriptions/pause-payment).
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::PauseCollection))
}
attr_accessor :pause_collection
# Controls whether the subscription schedule should create [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when transitioning to this phase if there is a difference in billing configuration. 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 (item price, quantity, etc.) of the current phase.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
# The date at which this phase of the subscription schedule starts or `now`. Must be set on the first phase.
sig { returns(T.nilable(T.any(Integer, String))) }
attr_accessor :start_date
# The data with which to automatically create a Transfer for each of the associated subscription's invoices.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::TransferData))
}
attr_accessor :transfer_data
# If set to true the entire phase is counted as a trial and the customer will not be charged for any fees.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :trial
# Specify trial behavior when crossing phase boundaries
sig { returns(T.nilable(String)) }
attr_accessor :trial_continuation
# Sets the phase to trialing from the start date to this date. Must be before the phase end date, can not be combined with `trial`
sig { returns(T.nilable(T.any(Integer, String))) }
attr_accessor :trial_end
# Settings related to subscription trials.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::TrialSettings))
}
attr_accessor :trial_settings
sig {
params(add_invoice_items: T.nilable(T::Array[::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::AddInvoiceItem]), application_fee_percent: T.nilable(Float), automatic_tax: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::AutomaticTax), billing_cycle_anchor: T.nilable(String), billing_thresholds: T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::BillingThresholds))), collection_method: T.nilable(String), currency: T.nilable(String), default_payment_method: T.nilable(String), default_tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String]))), description: T.nilable(T.nilable(String)), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::Discount]))), end_date: T.nilable(T.any(Integer, String)), invoice_settings: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::InvoiceSettings), items: T::Array[::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::Item], iterations: T.nilable(Integer), metadata: T.nilable(T::Hash[String, String]), on_behalf_of: T.nilable(String), pause_collection: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::PauseCollection), proration_behavior: T.nilable(String), start_date: T.nilable(T.any(Integer, String)), transfer_data: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::TransferData), trial: T.nilable(T::Boolean), trial_continuation: T.nilable(String), trial_end: T.nilable(T.any(Integer, String)), trial_settings: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase::TrialSettings)).void
}
def initialize(
add_invoice_items: nil,
application_fee_percent: nil,
automatic_tax: nil,
billing_cycle_anchor: nil,
billing_thresholds: nil,
collection_method: nil,
currency: nil,
default_payment_method: nil,
default_tax_rates: nil,
description: nil,
discounts: nil,
end_date: nil,
invoice_settings: nil,
items: nil,
iterations: nil,
metadata: nil,
on_behalf_of: nil,
pause_collection: nil,
proration_behavior: nil,
start_date: nil,
transfer_data: nil,
trial: nil,
trial_continuation: nil,
trial_end: nil,
trial_settings: nil
); end
end
class Prebilling < Stripe::RequestParams
class BillUntil < Stripe::RequestParams
class AmendmentEnd < Stripe::RequestParams
# The position of the amendment in the `amendments` array at which prebilling should end. Indexes start from 0 and must be less than the total number of supplied amendments.
sig { returns(Integer) }
attr_accessor :index
sig { params(index: Integer).void }
def initialize(index: nil); end
end
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# End the prebilled period when a specified amendment ends.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Prebilling::BillUntil::AmendmentEnd))
}
attr_accessor :amendment_end
# Time span for prebilling, starting from `bill_from`.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Prebilling::BillUntil::Duration))
}
attr_accessor :duration
# End the prebilled period at a precise integer timestamp, starting from the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# Select one of several ways to pass the `bill_until` value.
sig { returns(String) }
attr_accessor :type
sig {
params(amendment_end: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Prebilling::BillUntil::AmendmentEnd), duration: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Prebilling::BillUntil::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(amendment_end: nil, duration: nil, timestamp: nil, type: nil); end
end
# The end of the prebilled time period.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Prebilling::BillUntil))
}
attr_accessor :bill_until
# This is used to determine the number of billing cycles to prebill.
sig { returns(T.nilable(Integer)) }
attr_accessor :iterations
sig {
params(bill_until: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Prebilling::BillUntil), iterations: T.nilable(Integer)).void
}
def initialize(bill_until: nil, iterations: nil); end
end
# Changes to apply to the phases of the subscription schedule, in the order provided.
sig {
returns(T.nilable(T::Array[::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment]))
}
attr_accessor :amendments
# Configures when the subscription schedule generates prorations for phase transitions. Possible values are `prorate_on_next_phase` or `prorate_up_front` with the default being `prorate_on_next_phase`. `prorate_on_next_phase` will apply phase changes and generate prorations at transition time. `prorate_up_front` will bill for all phases within the current billing cycle up front.
sig { returns(T.nilable(String)) }
attr_accessor :billing_behavior
# Controls how prorations and invoices for subscriptions are calculated and orchestrated.
sig { returns(T.nilable(String)) }
attr_accessor :billing_mode
# Behavior of the subscription schedule and underlying subscription when it ends. Possible values are `release` or `cancel` with the default being `release`. `release` will end the subscription schedule and keep the underlying subscription running. `cancel` will end the subscription schedule and cancel the underlying subscription.
sig { returns(T.nilable(String)) }
attr_accessor :end_behavior
# List representing phases of the subscription schedule. Each phase can be customized to have different durations, plans, and coupons. If there are multiple phases, the `end_date` of one phase will always equal the `start_date` of the next phase.
sig {
returns(T.nilable(T::Array[::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase]))
}
attr_accessor :phases
# Provide any time periods to bill in advance.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Prebilling]))))
}
attr_accessor :prebilling
# In cases where the `schedule_details` params update the currently active phase, specifies if and how to prorate at the time of the request.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
sig {
params(amendments: T.nilable(T::Array[::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Amendment]), billing_behavior: T.nilable(String), billing_mode: T.nilable(String), end_behavior: T.nilable(String), phases: T.nilable(T::Array[::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Phase]), prebilling: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails::Prebilling]))), proration_behavior: T.nilable(String)).void
}
def initialize(
amendments: nil,
billing_behavior: nil,
billing_mode: nil,
end_behavior: nil,
phases: nil,
prebilling: nil,
proration_behavior: nil
); end
end
class SubscriptionDetails < Stripe::RequestParams
class Item < Stripe::RequestParams
class BillingThresholds < Stripe::RequestParams
# Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))
sig { returns(Integer) }
attr_accessor :usage_gte
sig { params(usage_gte: Integer).void }
def initialize(usage_gte: nil); end
end
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::SubscriptionDetails::Item::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::SubscriptionDetails::Item::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::SubscriptionDetails::Item::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::SubscriptionDetails::Item::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class PriceData < Stripe::RequestParams
class Recurring < Stripe::RequestParams
# Specifies billing frequency. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: T.nilable(Integer)).void }
def initialize(interval: nil, interval_count: nil); end
end
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
sig { returns(String) }
attr_accessor :product
# The recurring components of a price such as `interval` and `interval_count`.
sig {
returns(::Stripe::InvoiceService::CreatePreviewParams::SubscriptionDetails::Item::PriceData::Recurring)
}
attr_accessor :recurring
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, product: String, recurring: ::Stripe::InvoiceService::CreatePreviewParams::SubscriptionDetails::Item::PriceData::Recurring, tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
recurring: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
# Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::CreatePreviewParams::SubscriptionDetails::Item::BillingThresholds))))
}
attr_accessor :billing_thresholds
# Delete all usage for a given subscription item. You must pass this when deleting a usage records subscription item. `clear_usage` has no effect if the plan has a billing meter attached.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :clear_usage
# A flag that, if set to `true`, will delete the specified item.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :deleted
# The coupons to redeem into discounts for the subscription item.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceService::CreatePreviewParams::SubscriptionDetails::Item::Discount]))))
}
attr_accessor :discounts
# Subscription item to update.
sig { returns(T.nilable(String)) }
attr_accessor :id
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Plan ID for this item, as a string.
sig { returns(T.nilable(String)) }
attr_accessor :plan
# The ID of the price object. One of `price` or `price_data` is required. When changing a subscription item's price, `quantity` is set to 1 unless a `quantity` parameter is provided.
sig { returns(T.nilable(String)) }
attr_accessor :price
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::SubscriptionDetails::Item::PriceData))
}
attr_accessor :price_data
# Quantity for this item.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
sig {
params(billing_thresholds: T.nilable(T.nilable(T.any(String, ::Stripe::InvoiceService::CreatePreviewParams::SubscriptionDetails::Item::BillingThresholds))), clear_usage: T.nilable(T::Boolean), deleted: T.nilable(T::Boolean), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceService::CreatePreviewParams::SubscriptionDetails::Item::Discount]))), id: T.nilable(String), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), plan: T.nilable(String), price: T.nilable(String), price_data: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::SubscriptionDetails::Item::PriceData), quantity: T.nilable(Integer), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String])))).void
}
def initialize(
billing_thresholds: nil,
clear_usage: nil,
deleted: nil,
discounts: nil,
id: nil,
metadata: nil,
plan: nil,
price: nil,
price_data: nil,
quantity: nil,
tax_rates: nil
); end
end
class Prebilling < Stripe::RequestParams
# This is used to determine the number of billing cycles to prebill.
sig { returns(Integer) }
attr_accessor :iterations
sig { params(iterations: Integer).void }
def initialize(iterations: nil); end
end
# 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`.
sig { returns(T.nilable(T.any(String, Integer))) }
attr_accessor :billing_cycle_anchor
# Controls how prorations and invoices for subscriptions are calculated and orchestrated.
sig { returns(T.nilable(String)) }
attr_accessor :billing_mode
# A timestamp at which the subscription should cancel. If set to a date before the current period ends, this will cause a proration if prorations have been enabled using `proration_behavior`. If set during a future period, this will always cause a proration for that period.
sig { returns(T.nilable(T.nilable(T.any(String, T.any(Integer, String))))) }
attr_accessor :cancel_at
# Indicate whether this subscription should cancel at the end of the current period (`current_period_end`). Defaults to `false`. This param will be removed in a future API version. Please use `cancel_at` instead.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :cancel_at_period_end
# This simulates the subscription being canceled or expired immediately.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :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.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :default_tax_rates
# A list of up to 20 subscription items, each with an attached price.
sig {
returns(T.nilable(T::Array[::Stripe::InvoiceService::CreatePreviewParams::SubscriptionDetails::Item]))
}
attr_accessor :items
# The pre-billing to apply to the subscription as a preview.
sig {
returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::SubscriptionDetails::Prebilling))
}
attr_accessor :prebilling
# Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/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`.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
# If previewing an update to a subscription, and doing proration, `subscription_details.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_details.items`, or `subscription_details.trial_end` are required. Also, `subscription_details.proration_behavior` cannot be set to 'none'.
sig { returns(T.nilable(Integer)) }
attr_accessor :proration_date
# For paused subscriptions, setting `subscription_details.resume_at` to `now` will preview the invoice that will be generated if the subscription is resumed.
sig { returns(T.nilable(String)) }
attr_accessor :resume_at
# Date a subscription is intended to start (can be future or past).
sig { returns(T.nilable(Integer)) }
attr_accessor :start_date
# If provided, the invoice returned will preview updating or creating a subscription with that trial end. If set, one of `subscription_details.items` or `subscription` is required.
sig { returns(T.nilable(T.any(String, Integer))) }
attr_accessor :trial_end
sig {
params(billing_cycle_anchor: T.nilable(T.any(String, Integer)), billing_mode: T.nilable(String), cancel_at: T.nilable(T.nilable(T.any(String, T.any(Integer, String)))), cancel_at_period_end: T.nilable(T::Boolean), cancel_now: T.nilable(T::Boolean), default_tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String]))), items: T.nilable(T::Array[::Stripe::InvoiceService::CreatePreviewParams::SubscriptionDetails::Item]), prebilling: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::SubscriptionDetails::Prebilling), proration_behavior: T.nilable(String), proration_date: T.nilable(Integer), resume_at: T.nilable(String), start_date: T.nilable(Integer), trial_end: T.nilable(T.any(String, Integer))).void
}
def initialize(
billing_cycle_anchor: nil,
billing_mode: nil,
cancel_at: nil,
cancel_at_period_end: nil,
cancel_now: nil,
default_tax_rates: nil,
items: nil,
prebilling: nil,
proration_behavior: nil,
proration_date: nil,
resume_at: nil,
start_date: nil,
trial_end: nil
); end
end
# Settings for automatic tax lookup for this invoice preview.
sig { returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::AutomaticTax)) }
attr_accessor :automatic_tax
# The currency to preview this invoice in. Defaults to that of `customer` if not specified.
sig { returns(T.nilable(String)) }
attr_accessor :currency
# The identifier of the customer whose upcoming invoice you'd like to retrieve. If `automatic_tax` is enabled then one of `customer`, `customer_details`, `subscription`, or `schedule` must be set.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# The identifier of the account whose upcoming invoice you'd like to retrieve. If `automatic_tax` is enabled then one of `customer`, `customer_account`, `customer_details`, `subscription`, or `schedule` must be set.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# Details about the customer you want to invoice or overrides for an existing customer. If `automatic_tax` is enabled then one of `customer`, `customer_details`, `subscription`, or `schedule` must be set.
sig { returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::CustomerDetails)) }
attr_accessor :customer_details
# The coupons to redeem into discounts for the invoice preview. If not specified, inherits the discount from the subscription or customer. This works for both coupons directly applied to an invoice and coupons applied to a subscription. Pass an empty string to avoid inheriting any discounts.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceService::CreatePreviewParams::Discount]))))
}
attr_accessor :discounts
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# List of invoice items to add or update in the upcoming invoice preview (up to 250).
sig {
returns(T.nilable(T::Array[::Stripe::InvoiceService::CreatePreviewParams::InvoiceItem]))
}
attr_accessor :invoice_items
# The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
sig { returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::Issuer)) }
attr_accessor :issuer
# The account (if any) for which the funds of the invoice payment are intended. If set, the invoice will be presented with the branding and support information of the specified account. See the [Invoices with Connect](https://stripe.com/docs/billing/invoices/connect) documentation for details.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :on_behalf_of
# Customizes the types of values to include when calculating the invoice. Defaults to `next` if unspecified.
sig { returns(T.nilable(String)) }
attr_accessor :preview_mode
# The identifier of the schedule whose upcoming invoice you'd like to retrieve. Cannot be used with subscription or subscription fields.
sig { returns(T.nilable(String)) }
attr_accessor :schedule
# The schedule creation or modification params to apply as a preview. Cannot be used with `subscription` or `subscription_` prefixed fields.
sig { returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails)) }
attr_accessor :schedule_details
# The identifier of the subscription for which you'd like to retrieve the upcoming invoice. If not provided, but a `subscription_details.items` is provided, you will preview creating a subscription with those items. If neither `subscription` nor `subscription_details.items` is provided, you will retrieve the next upcoming invoice from among the customer's subscriptions.
sig { returns(T.nilable(String)) }
attr_accessor :subscription
# The subscription creation or modification params to apply as a preview. Cannot be used with `schedule` or `schedule_details` fields.
sig { returns(T.nilable(::Stripe::InvoiceService::CreatePreviewParams::SubscriptionDetails)) }
attr_accessor :subscription_details
sig {
params(automatic_tax: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::AutomaticTax), currency: T.nilable(String), customer: T.nilable(String), customer_account: T.nilable(String), customer_details: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::CustomerDetails), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceService::CreatePreviewParams::Discount]))), expand: T.nilable(T::Array[String]), invoice_items: T.nilable(T::Array[::Stripe::InvoiceService::CreatePreviewParams::InvoiceItem]), issuer: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::Issuer), on_behalf_of: T.nilable(T.nilable(String)), preview_mode: T.nilable(String), schedule: T.nilable(String), schedule_details: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::ScheduleDetails), subscription: T.nilable(String), subscription_details: T.nilable(::Stripe::InvoiceService::CreatePreviewParams::SubscriptionDetails)).void
}
def initialize(
automatic_tax: nil,
currency: nil,
customer: nil,
customer_account: nil,
customer_details: nil,
discounts: nil,
expand: nil,
invoice_items: nil,
issuer: nil,
on_behalf_of: nil,
preview_mode: nil,
schedule: nil,
schedule_details: nil,
subscription: nil,
subscription_details: nil
); end
end
# Adds multiple line items to an invoice. This is only possible when an invoice is still a draft.
sig {
params(invoice: String, params: T.any(::Stripe::InvoiceService::AddLinesParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Invoice)
}
def add_lines(invoice, params = {}, opts = {}); end
# Attaches a PaymentIntent or an Out of Band Payment to the invoice, adding it to the list of payments.
#
# For the PaymentIntent, when the PaymentIntent's status changes to succeeded, the payment is credited
# to the invoice, increasing its amount_paid. When the invoice is fully paid, the
# invoice's status becomes paid.
#
# If the PaymentIntent's status is already succeeded when it's attached, it's
# credited to the invoice immediately.
#
# See: [Partial payments](https://docs.stripe.com/docs/invoicing/partial-payments) to learn more.
sig {
params(invoice: String, params: T.any(::Stripe::InvoiceService::AttachPaymentParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Invoice)
}
def attach_payment(invoice, params = {}, opts = {}); end
# 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://docs.stripe.com/api#finalize_invoice) the invoice to your customers.
sig {
params(params: T.any(::Stripe::InvoiceService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Invoice)
}
def create(params = {}, opts = {}); end
# At any time, you can preview the upcoming invoice for a subscription or subscription schedule. 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.
#
# You can also preview the effects of creating or updating a subscription or subscription schedule, including a preview of any prorations that will take place. To ensure that the actual proration is calculated exactly the same as the previewed proration, you should pass the subscription_details.proration_date parameter when doing the actual subscription update.
#
# The recommended way to get only the prorations being previewed on the invoice is to consider line items where parent.subscription_item_details.proration is true.
#
# 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.
#
# Note: Currency conversion calculations use the latest exchange rates. Exchange rates may vary between the time of the preview and the time of the actual invoice creation. [Learn more](https://docs.stripe.com/currencies/conversions)
sig {
params(params: T.any(::Stripe::InvoiceService::CreatePreviewParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Invoice)
}
def create_preview(params = {}, opts = {}); end
# Permanently deletes a one-off invoice draft. This cannot be undone. Attempts to delete invoices that are no longer in a draft state will fail; once an invoice has been finalized or if an invoice is for a subscription, it must be [voided](https://docs.stripe.com/api#void_invoice).
sig {
params(invoice: String, params: T.any(::Stripe::InvoiceService::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Invoice)
}
def delete(invoice, params = {}, opts = {}); end
# Stripe automatically finalizes drafts before sending and attempting payment on invoices. However, if you'd like to finalize a draft invoice manually, you can do so using this method.
sig {
params(invoice: String, params: T.any(::Stripe::InvoiceService::FinalizeInvoiceParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Invoice)
}
def finalize_invoice(invoice, params = {}, opts = {}); end
# 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.
sig {
params(params: T.any(::Stripe::InvoiceService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Marking an invoice as uncollectible is useful for keeping track of bad debts that can be written off for accounting purposes.
sig {
params(invoice: String, params: T.any(::Stripe::InvoiceService::MarkUncollectibleParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Invoice)
}
def mark_uncollectible(invoice, params = {}, opts = {}); end
# 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.
sig {
params(invoice: String, params: T.any(::Stripe::InvoiceService::PayParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Invoice)
}
def pay(invoice, params = {}, opts = {}); end
# Removes multiple line items from an invoice. This is only possible when an invoice is still a draft.
sig {
params(invoice: String, params: T.any(::Stripe::InvoiceService::RemoveLinesParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Invoice)
}
def remove_lines(invoice, params = {}, opts = {}); end
# Retrieves the invoice with the given ID.
sig {
params(invoice: String, params: T.any(::Stripe::InvoiceService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Invoice)
}
def retrieve(invoice, params = {}, opts = {}); end
# Search for invoices you've previously created using Stripe's [Search Query Language](https://docs.stripe.com/docs/search#search-query-language).
# Don't use search in read-after-write flows where strict consistency is necessary. Under normal operating
# conditions, data is searchable in less than a minute. Occasionally, propagation of new or updated data can be up
# to an hour behind during outages. Search functionality is not available to merchants in India.
sig {
params(params: T.any(::Stripe::InvoiceService::SearchParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SearchResultObject)
}
def search(params = {}, opts = {}); end
# 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.
sig {
params(invoice: String, params: T.any(::Stripe::InvoiceService::SendInvoiceParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Invoice)
}
def send_invoice(invoice, params = {}, opts = {}); end
# Draft invoices are fully editable. Once an invoice is [finalized](https://docs.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://docs.stripe.com/docs/billing/invoices/reconciliation) invoices, pass
# auto_advance=false.
sig {
params(invoice: String, params: T.any(::Stripe::InvoiceService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Invoice)
}
def update(invoice, params = {}, opts = {}); end
# Updates multiple line items on an invoice. This is only possible when an invoice is still a draft.
sig {
params(invoice: String, params: T.any(::Stripe::InvoiceService::UpdateLinesParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Invoice)
}
def update_lines(invoice, params = {}, opts = {}); end
# Mark a finalized invoice as void. This cannot be undone. Voiding an invoice is similar to [deletion](https://docs.stripe.com/api#delete_invoice), however it only applies to finalized invoices and maintains a papertrail where the invoice can still be found.
#
# Consult with local regulations to determine whether and how an invoice might be amended, canceled, or voided in the jurisdiction you're doing business in. You might need to [issue another invoice or credit note](https://docs.stripe.com/api#create_invoice) instead. Stripe recommends that you consult with your legal counsel for advice specific to your business.
sig {
params(invoice: String, params: T.any(::Stripe::InvoiceService::VoidInvoiceParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Invoice)
}
def void_invoice(invoice, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class InvoiceLineItemService < StripeService
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
class UpdateParams < Stripe::RequestParams
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::InvoiceLineItemService::UpdateParams::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::InvoiceLineItemService::UpdateParams::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::InvoiceLineItemService::UpdateParams::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::InvoiceLineItemService::UpdateParams::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class Period < Stripe::RequestParams
# The end of the period, which must be greater than or equal to the start. This value is inclusive.
sig { returns(Integer) }
attr_accessor :end
# The start of the period. This value is inclusive.
sig { returns(Integer) }
attr_accessor :start
sig { params(end_: Integer, start: Integer).void }
def initialize(end_: nil, start: nil); end
end
class PriceData < Stripe::RequestParams
class ProductData < Stripe::RequestParams
# The product's description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes.
sig { returns(T.nilable(String)) }
attr_accessor :description
# A list of up to 8 URLs of images for this product, meant to be displayable to the customer.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :images
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The product's name, meant to be displayable to the customer.
sig { returns(String) }
attr_accessor :name
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
sig { returns(T.nilable(String)) }
attr_accessor :tax_code
sig {
params(description: T.nilable(String), images: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), name: String, tax_code: T.nilable(String)).void
}
def initialize(
description: nil,
images: nil,
metadata: nil,
name: nil,
tax_code: nil
); end
end
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to. One of `product` or `product_data` is required.
sig { returns(T.nilable(String)) }
attr_accessor :product
# Data used to generate a new [Product](https://docs.stripe.com/api/products) object inline. One of `product` or `product_data` is required.
sig {
returns(T.nilable(::Stripe::InvoiceLineItemService::UpdateParams::PriceData::ProductData))
}
attr_accessor :product_data
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A non-negative integer in cents (or local equivalent) representing how much to charge. One of `unit_amount` or `unit_amount_decimal` is required.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, product: T.nilable(String), product_data: T.nilable(::Stripe::InvoiceLineItemService::UpdateParams::PriceData::ProductData), tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
product_data: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
class Pricing < Stripe::RequestParams
# The ID of the price object.
sig { returns(T.nilable(String)) }
attr_accessor :price
sig { params(price: T.nilable(String)).void }
def initialize(price: nil); end
end
class TaxAmount < Stripe::RequestParams
class TaxRateData < Stripe::RequestParams
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# An arbitrary string attached to the tax rate for your internal use only. It will not be visible to your customers.
sig { returns(T.nilable(String)) }
attr_accessor :description
# The display name of the tax rate, which will be shown to users.
sig { returns(String) }
attr_accessor :display_name
# This specifies if the tax rate is inclusive or exclusive.
sig { returns(T::Boolean) }
attr_accessor :inclusive
# The jurisdiction for the tax rate. You can use this label field for tax reporting purposes. It also appears on your customer’s invoice.
sig { returns(T.nilable(String)) }
attr_accessor :jurisdiction
# The level of the jurisdiction that imposes this tax rate.
sig { returns(T.nilable(String)) }
attr_accessor :jurisdiction_level
# The statutory tax rate percent. This field accepts decimal values between 0 and 100 inclusive with at most 4 decimal places. To accommodate fixed-amount taxes, set the percentage to zero. Stripe will not display zero percentages on the invoice unless the `amount` of the tax is also zero.
sig { returns(Float) }
attr_accessor :percentage
# [ISO 3166-2 subdivision code](https://en.wikipedia.org/wiki/ISO_3166-2:US), without country prefix. For example, "NY" for New York, United States.
sig { returns(T.nilable(String)) }
attr_accessor :state
# The high-level tax type, such as `vat` or `sales_tax`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_type
sig {
params(country: T.nilable(String), description: T.nilable(String), display_name: String, inclusive: T::Boolean, jurisdiction: T.nilable(String), jurisdiction_level: T.nilable(String), percentage: Float, state: T.nilable(String), tax_type: T.nilable(String)).void
}
def initialize(
country: nil,
description: nil,
display_name: nil,
inclusive: nil,
jurisdiction: nil,
jurisdiction_level: nil,
percentage: nil,
state: nil,
tax_type: nil
); end
end
# The amount, in cents (or local equivalent), of the tax.
sig { returns(Integer) }
attr_accessor :amount
# Data to find or create a TaxRate object.
#
# Stripe automatically creates or reuses a TaxRate object for each tax amount. If the `tax_rate_data` exactly matches a previous value, Stripe will reuse the TaxRate object. TaxRate objects created automatically by Stripe are immediately archived, do not appear in the line item’s `tax_rates`, and cannot be directly added to invoices, payments, or line items.
sig { returns(::Stripe::InvoiceLineItemService::UpdateParams::TaxAmount::TaxRateData) }
attr_accessor :tax_rate_data
# The reasoning behind this tax, for example, if the product is tax exempt.
sig { returns(T.nilable(String)) }
attr_accessor :taxability_reason
# The amount on which tax is calculated, in cents (or local equivalent).
sig { returns(Integer) }
attr_accessor :taxable_amount
sig {
params(amount: Integer, tax_rate_data: ::Stripe::InvoiceLineItemService::UpdateParams::TaxAmount::TaxRateData, taxability_reason: T.nilable(String), taxable_amount: Integer).void
}
def initialize(
amount: nil,
tax_rate_data: nil,
taxability_reason: nil,
taxable_amount: nil
); end
end
# The integer amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. If you want to apply a credit to the customer's account, pass a negative amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# An arbitrary string which you can attach to the invoice item. The description is displayed in the invoice for easy tracking.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Controls whether discounts apply to this line item. Defaults to false for prorations or negative line items, and true for all other line items. Cannot be set to true for prorations.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :discountable
# The coupons, promotion codes & existing discounts which apply to the line item. Item discounts are applied before invoice discounts. Pass an empty string to remove previously-defined discounts.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceLineItemService::UpdateParams::Discount]))))
}
attr_accessor :discounts
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The IDs of the margins to apply to the line item. When set, the `default_margins` on the invoice do not apply to this line item.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :margins
# 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`. For [type=subscription](https://stripe.com/docs/api/invoices/line_item#invoice_line_item_object-type) line items, the incoming metadata specified on the request is directly used to set this value, in contrast to [type=invoiceitem](api/invoices/line_item#invoice_line_item_object-type) line items, where any existing metadata on the invoice line is merged with the incoming data.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :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.
sig { returns(T.nilable(::Stripe::InvoiceLineItemService::UpdateParams::Period)) }
attr_accessor :period
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
sig { returns(T.nilable(::Stripe::InvoiceLineItemService::UpdateParams::PriceData)) }
attr_accessor :price_data
# The pricing information for the invoice item.
sig { returns(T.nilable(::Stripe::InvoiceLineItemService::UpdateParams::Pricing)) }
attr_accessor :pricing
# Non-negative integer. The quantity of units for the line item.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# A list of up to 10 tax amounts for this line item. This can be useful if you calculate taxes on your own or use a third-party to calculate them. You cannot set tax amounts if any line item has [tax_rates](https://stripe.com/docs/api/invoices/line_item#invoice_line_item_object-tax_rates) or if the invoice has [default_tax_rates](https://stripe.com/docs/api/invoices/object#invoice_object-default_tax_rates) or uses [automatic tax](https://stripe.com/docs/tax/invoicing). Pass an empty string to remove previously defined tax amounts.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceLineItemService::UpdateParams::TaxAmount]))))
}
attr_accessor :tax_amounts
# The tax rates which apply to the line item. When set, the `default_tax_rates` on the invoice do not apply to this line item. Pass an empty string to remove previously-defined tax rates.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
sig {
params(amount: T.nilable(Integer), description: T.nilable(String), discountable: T.nilable(T::Boolean), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceLineItemService::UpdateParams::Discount]))), expand: T.nilable(T::Array[String]), margins: T.nilable(T.nilable(T.any(String, T::Array[String]))), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), period: T.nilable(::Stripe::InvoiceLineItemService::UpdateParams::Period), price_data: T.nilable(::Stripe::InvoiceLineItemService::UpdateParams::PriceData), pricing: T.nilable(::Stripe::InvoiceLineItemService::UpdateParams::Pricing), quantity: T.nilable(Integer), tax_amounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceLineItemService::UpdateParams::TaxAmount]))), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String])))).void
}
def initialize(
amount: nil,
description: nil,
discountable: nil,
discounts: nil,
expand: nil,
margins: nil,
metadata: nil,
period: nil,
price_data: nil,
pricing: nil,
quantity: nil,
tax_amounts: nil,
tax_rates: nil
); end
end
# When retrieving an invoice, you'll get a lines property containing the total count of line items and the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items.
sig {
params(invoice: String, params: T.any(::Stripe::InvoiceLineItemService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(invoice, params = {}, opts = {}); end
# Updates an invoice's line item. Some fields, such as tax_amounts, only live on the invoice line item,
# so they can only be updated through this endpoint. Other fields, such as amount, live on both the invoice
# item and the invoice line item, so updates on this endpoint will propagate to the invoice item as well.
# Updating an invoice's line item is only possible before the invoice is finalized.
sig {
params(invoice: String, line_item_id: String, params: T.any(::Stripe::InvoiceLineItemService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::InvoiceLineItem)
}
def update(invoice, line_item_id, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class InvoiceRenderingTemplateService < StripeService
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Attribute for param field status
sig { returns(T.nilable(String)) }
attr_accessor :status
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String), status: T.nilable(String)).void
}
def initialize(
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil,
status: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Attribute for param field version
sig { returns(T.nilable(Integer)) }
attr_accessor :version
sig { params(expand: T.nilable(T::Array[String]), version: T.nilable(Integer)).void }
def initialize(expand: nil, version: nil); end
end
class ArchiveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UnarchiveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Updates the status of an invoice rendering template to ‘archived' so no new Stripe objects (customers, invoices, etc.) can reference it. The template can also no longer be updated. However, if the template is already set on a Stripe object, it will continue to be applied on invoices generated by it.
sig {
params(template: String, params: T.any(::Stripe::InvoiceRenderingTemplateService::ArchiveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::InvoiceRenderingTemplate)
}
def archive(template, params = {}, opts = {}); end
# List all templates, ordered by creation date, with the most recently created template appearing first.
sig {
params(params: T.any(::Stripe::InvoiceRenderingTemplateService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves an invoice rendering template with the given ID. It by default returns the latest version of the template. Optionally, specify a version to see previous versions.
sig {
params(template: String, params: T.any(::Stripe::InvoiceRenderingTemplateService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::InvoiceRenderingTemplate)
}
def retrieve(template, params = {}, opts = {}); end
# Unarchive an invoice rendering template so it can be used on new Stripe objects again.
sig {
params(template: String, params: T.any(::Stripe::InvoiceRenderingTemplateService::UnarchiveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::InvoiceRenderingTemplate)
}
def unarchive(template, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class InvoiceItemService < StripeService
class DeleteParams < Stripe::RequestParams; end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::InvoiceItemService::UpdateParams::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::InvoiceItemService::UpdateParams::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::InvoiceItemService::UpdateParams::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::InvoiceItemService::UpdateParams::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class Period < Stripe::RequestParams
# The end of the period, which must be greater than or equal to the start. This value is inclusive.
sig { returns(Integer) }
attr_accessor :end
# The start of the period. This value is inclusive.
sig { returns(Integer) }
attr_accessor :start
sig { params(end_: Integer, start: Integer).void }
def initialize(end_: nil, start: nil); end
end
class PriceData < Stripe::RequestParams
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
sig { returns(String) }
attr_accessor :product
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, product: String, tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
class Pricing < Stripe::RequestParams
# The ID of the price object.
sig { returns(T.nilable(String)) }
attr_accessor :price
sig { params(price: T.nilable(String)).void }
def initialize(price: nil); end
end
# The integer amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. If you want to apply a credit to the customer's account, pass a negative amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# An arbitrary string which you can attach to the invoice item. The description is displayed in the invoice for easy tracking.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Controls whether discounts apply to this invoice item. Defaults to false for prorations or negative invoice items, and true for all other invoice items. Cannot be set to true for prorations.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :discountable
# The coupons, promotion codes & existing discounts which apply to the invoice item or invoice line item. Item discounts are applied before invoice discounts. Pass an empty string to remove previously-defined discounts.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceItemService::UpdateParams::Discount]))))
}
attr_accessor :discounts
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The ids of the margins to apply to the invoice item. When set, the `default_margins` on the invoice do not apply to this invoice item.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :margins
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :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.
sig { returns(T.nilable(::Stripe::InvoiceItemService::UpdateParams::Period)) }
attr_accessor :period
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
sig { returns(T.nilable(::Stripe::InvoiceItemService::UpdateParams::PriceData)) }
attr_accessor :price_data
# The pricing information for the invoice item.
sig { returns(T.nilable(::Stripe::InvoiceItemService::UpdateParams::Pricing)) }
attr_accessor :pricing
# Non-negative integer. The quantity of units for the invoice item.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :tax_code
# The tax rates which apply to the invoice item. When set, the `default_tax_rates` on the invoice do not apply to this invoice item. Pass an empty string to remove previously-defined tax rates.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
# The decimal unit amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. This `unit_amount_decimal` will be multiplied by the quantity to get the full amount. Passing in a negative `unit_amount_decimal` will reduce the `amount_due` on the invoice. Accepts at most 12 decimal places.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(amount: T.nilable(Integer), description: T.nilable(String), discountable: T.nilable(T::Boolean), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceItemService::UpdateParams::Discount]))), expand: T.nilable(T::Array[String]), margins: T.nilable(T.nilable(T.any(String, T::Array[String]))), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), period: T.nilable(::Stripe::InvoiceItemService::UpdateParams::Period), price_data: T.nilable(::Stripe::InvoiceItemService::UpdateParams::PriceData), pricing: T.nilable(::Stripe::InvoiceItemService::UpdateParams::Pricing), quantity: T.nilable(Integer), tax_behavior: T.nilable(String), tax_code: T.nilable(T.nilable(String)), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String]))), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
amount: nil,
description: nil,
discountable: nil,
discounts: nil,
expand: nil,
margins: nil,
metadata: nil,
period: nil,
price_data: nil,
pricing: nil,
quantity: nil,
tax_behavior: nil,
tax_code: nil,
tax_rates: nil,
unit_amount_decimal: nil
); end
end
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return invoice items that were created during the given date interval.
sig { returns(T.nilable(T.any(::Stripe::InvoiceItemService::ListParams::Created, Integer))) }
attr_accessor :created
# The identifier of the customer whose invoice items to return. If none is provided, all invoice items will be returned.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# The identifier of the account whose invoice items to return. If none is provided, all invoice items will be returned.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Only return invoice items belonging to this invoice. If none is provided, all invoice items will be returned. If specifying an invoice, no customer identifier is needed.
sig { returns(T.nilable(String)) }
attr_accessor :invoice
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Set to `true` to only show pending invoice items, which are not yet attached to any invoices. Set to `false` to only show invoice items already attached to invoices. If unspecified, no filter is applied.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :pending
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(created: T.nilable(T.any(::Stripe::InvoiceItemService::ListParams::Created, Integer)), customer: T.nilable(String), customer_account: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), invoice: T.nilable(String), limit: T.nilable(Integer), pending: T.nilable(T::Boolean), starting_after: T.nilable(String)).void
}
def initialize(
created: nil,
customer: nil,
customer_account: nil,
ending_before: nil,
expand: nil,
invoice: nil,
limit: nil,
pending: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::InvoiceItemService::CreateParams::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::InvoiceItemService::CreateParams::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::InvoiceItemService::CreateParams::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::InvoiceItemService::CreateParams::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class Period < Stripe::RequestParams
# The end of the period, which must be greater than or equal to the start. This value is inclusive.
sig { returns(Integer) }
attr_accessor :end
# The start of the period. This value is inclusive.
sig { returns(Integer) }
attr_accessor :start
sig { params(end_: Integer, start: Integer).void }
def initialize(end_: nil, start: nil); end
end
class PriceData < Stripe::RequestParams
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
sig { returns(String) }
attr_accessor :product
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, product: String, tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
class Pricing < Stripe::RequestParams
# The ID of the price object.
sig { returns(T.nilable(String)) }
attr_accessor :price
sig { params(price: T.nilable(String)).void }
def initialize(price: nil); end
end
# The integer amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. Passing in a negative `amount` will reduce the `amount_due` on the invoice.
sig { returns(T.nilable(Integer)) }
attr_accessor :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).
sig { returns(T.nilable(String)) }
attr_accessor :currency
# The ID of the customer who will be billed when this invoice item is billed.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# The ID of the account who will be billed when this invoice item is billed.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# An arbitrary string which you can attach to the invoice item. The description is displayed in the invoice for easy tracking.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Controls whether discounts apply to this invoice item. Defaults to false for prorations or negative invoice items, and true for all other invoice items.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :discountable
# The coupons and promotion codes to redeem into discounts for the invoice item or invoice line item.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceItemService::CreateParams::Discount]))))
}
attr_accessor :discounts
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The ID of an existing invoice to add this invoice item to. When left blank, the invoice item will be added to the next upcoming scheduled invoice. This is useful when adding invoice items in response to an invoice.created webhook. You can only add invoice items to draft invoices and there is a maximum of 250 items per invoice.
sig { returns(T.nilable(String)) }
attr_accessor :invoice
# The ids of the margins to apply to the invoice item. When set, the `default_margins` on the invoice do not apply to this invoice item.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :margins
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :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.
sig { returns(T.nilable(::Stripe::InvoiceItemService::CreateParams::Period)) }
attr_accessor :period
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
sig { returns(T.nilable(::Stripe::InvoiceItemService::CreateParams::PriceData)) }
attr_accessor :price_data
# The pricing information for the invoice item.
sig { returns(T.nilable(::Stripe::InvoiceItemService::CreateParams::Pricing)) }
attr_accessor :pricing
# Non-negative integer. The quantity of units for the invoice item.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# The ID of a subscription to add this invoice item to. When left blank, the invoice item is added to the next upcoming scheduled invoice. When set, scheduled invoices for subscriptions other than the specified subscription will ignore the invoice item. Use this when you want to express that an invoice item has been accrued within the context of a particular subscription.
sig { returns(T.nilable(String)) }
attr_accessor :subscription
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :tax_code
# The tax rates which apply to the invoice item. When set, the `default_tax_rates` on the invoice do not apply to this invoice item.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :tax_rates
# The decimal unit amount in cents (or local equivalent) of the charge to be applied to the upcoming invoice. This `unit_amount_decimal` will be multiplied by the quantity to get the full amount. Passing in a negative `unit_amount_decimal` will reduce the `amount_due` on the invoice. Accepts at most 12 decimal places.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(amount: T.nilable(Integer), currency: T.nilable(String), customer: T.nilable(String), customer_account: T.nilable(String), description: T.nilable(String), discountable: T.nilable(T::Boolean), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::InvoiceItemService::CreateParams::Discount]))), expand: T.nilable(T::Array[String]), invoice: T.nilable(String), margins: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), period: T.nilable(::Stripe::InvoiceItemService::CreateParams::Period), price_data: T.nilable(::Stripe::InvoiceItemService::CreateParams::PriceData), pricing: T.nilable(::Stripe::InvoiceItemService::CreateParams::Pricing), quantity: T.nilable(Integer), subscription: T.nilable(String), tax_behavior: T.nilable(String), tax_code: T.nilable(T.nilable(String)), tax_rates: T.nilable(T::Array[String]), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
amount: nil,
currency: nil,
customer: nil,
customer_account: nil,
description: nil,
discountable: nil,
discounts: nil,
expand: nil,
invoice: nil,
margins: nil,
metadata: nil,
period: nil,
price_data: nil,
pricing: nil,
quantity: nil,
subscription: nil,
tax_behavior: nil,
tax_code: nil,
tax_rates: nil,
unit_amount_decimal: nil
); end
end
# Creates an item to be added to a draft invoice (up to 250 items per invoice). If no invoice is specified, the item will be on the next invoice created for the customer specified.
sig {
params(params: T.any(::Stripe::InvoiceItemService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::InvoiceItem)
}
def create(params = {}, opts = {}); end
# Deletes an invoice item, removing it from an invoice. Deleting invoice items is only possible when they're not attached to invoices, or if it's attached to a draft invoice.
sig {
params(invoiceitem: String, params: T.any(::Stripe::InvoiceItemService::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::InvoiceItem)
}
def delete(invoiceitem, params = {}, opts = {}); end
# Returns a list of your invoice items. Invoice items are returned sorted by creation date, with the most recently created invoice items appearing first.
sig {
params(params: T.any(::Stripe::InvoiceItemService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the invoice item with the given ID.
sig {
params(invoiceitem: String, params: T.any(::Stripe::InvoiceItemService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::InvoiceItem)
}
def retrieve(invoiceitem, params = {}, opts = {}); end
# Updates the amount or description of an invoice item on an upcoming invoice. Updating an invoice item is only possible before the invoice it's attached to is closed.
sig {
params(invoiceitem: String, params: T.any(::Stripe::InvoiceItemService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::InvoiceItem)
}
def update(invoiceitem, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class IssuingService < StripeService
attr_reader :authorizations
attr_reader :cards
attr_reader :cardholders
attr_reader :credit_underwriting_records
attr_reader :disputes
attr_reader :dispute_settlement_details
attr_reader :fraud_liability_debits
attr_reader :personalization_designs
attr_reader :physical_bundles
attr_reader :tokens
attr_reader :transactions
end
end
# typed: true
module Stripe
module Issuing
class AuthorizationService < StripeService
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return authorizations that belong to the given card.
sig { returns(T.nilable(String)) }
attr_accessor :card
# Only return authorizations that belong to the given cardholder.
sig { returns(T.nilable(String)) }
attr_accessor :cardholder
# Only return authorizations that were created during the given date interval.
sig {
returns(T.nilable(T.any(::Stripe::Issuing::AuthorizationService::ListParams::Created, Integer)))
}
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return authorizations with the given status. One of `pending`, `closed`, or `reversed`.
sig { returns(T.nilable(String)) }
attr_accessor :status
sig {
params(card: T.nilable(String), cardholder: T.nilable(String), created: T.nilable(T.any(::Stripe::Issuing::AuthorizationService::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String), status: T.nilable(String)).void
}
def initialize(
card: nil,
cardholder: nil,
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil,
status: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
sig {
params(expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String])))).void
}
def initialize(expand: nil, metadata: nil); end
end
class ApproveParams < Stripe::RequestParams
# If the authorization's `pending_request.is_amount_controllable` property is `true`, you may provide this value to control how much to hold for the authorization. Must be positive (use [`decline`](https://stripe.com/docs/api/issuing/authorizations/decline) to decline an authorization request).
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
sig {
params(amount: T.nilable(Integer), expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String])))).void
}
def initialize(amount: nil, expand: nil, metadata: nil); end
end
class DeclineParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
sig {
params(expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String])))).void
}
def initialize(expand: nil, metadata: nil); end
end
# [Deprecated] Approves a pending Issuing Authorization object. This request should be made within the timeout window of the [real-time authorization](https://docs.stripe.com/docs/issuing/controls/real-time-authorizations) flow.
# This method is deprecated. Instead, [respond directly to the webhook request to approve an authorization](https://docs.stripe.com/docs/issuing/controls/real-time-authorizations#authorization-handling).
sig {
params(authorization: String, params: T.any(::Stripe::Issuing::AuthorizationService::ApproveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Authorization)
}
def approve(authorization, params = {}, opts = {}); end
# [Deprecated] Declines a pending Issuing Authorization object. This request should be made within the timeout window of the [real time authorization](https://docs.stripe.com/docs/issuing/controls/real-time-authorizations) flow.
# This method is deprecated. Instead, [respond directly to the webhook request to decline an authorization](https://docs.stripe.com/docs/issuing/controls/real-time-authorizations#authorization-handling).
sig {
params(authorization: String, params: T.any(::Stripe::Issuing::AuthorizationService::DeclineParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Authorization)
}
def decline(authorization, params = {}, opts = {}); end
# Returns a list of Issuing Authorization objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.
sig {
params(params: T.any(::Stripe::Issuing::AuthorizationService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves an Issuing Authorization object.
sig {
params(authorization: String, params: T.any(::Stripe::Issuing::AuthorizationService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Authorization)
}
def retrieve(authorization, params = {}, opts = {}); end
# Updates the specified Issuing Authorization object by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
sig {
params(authorization: String, params: T.any(::Stripe::Issuing::AuthorizationService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Authorization)
}
def update(authorization, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Issuing
class CardService < StripeService
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return cards belonging to the Cardholder with the provided ID.
sig { returns(T.nilable(String)) }
attr_accessor :cardholder
# Only return cards that were issued during the given date interval.
sig {
returns(T.nilable(T.any(::Stripe::Issuing::CardService::ListParams::Created, Integer)))
}
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Only return cards that have the given expiration month.
sig { returns(T.nilable(Integer)) }
attr_accessor :exp_month
# Only return cards that have the given expiration year.
sig { returns(T.nilable(Integer)) }
attr_accessor :exp_year
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Only return cards that have the given last four digits.
sig { returns(T.nilable(String)) }
attr_accessor :last4
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Attribute for param field personalization_design
sig { returns(T.nilable(String)) }
attr_accessor :personalization_design
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return cards that have the given status. One of `active`, `inactive`, or `canceled`.
sig { returns(T.nilable(String)) }
attr_accessor :status
# Only return cards that have the given type. One of `virtual` or `physical`.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(cardholder: T.nilable(String), created: T.nilable(T.any(::Stripe::Issuing::CardService::ListParams::Created, Integer)), ending_before: T.nilable(String), exp_month: T.nilable(Integer), exp_year: T.nilable(Integer), expand: T.nilable(T::Array[String]), last4: T.nilable(String), limit: T.nilable(Integer), personalization_design: T.nilable(String), starting_after: T.nilable(String), status: T.nilable(String), type: T.nilable(String)).void
}
def initialize(
cardholder: nil,
created: nil,
ending_before: nil,
exp_month: nil,
exp_year: nil,
expand: nil,
last4: nil,
limit: nil,
personalization_design: nil,
starting_after: nil,
status: nil,
type: nil
); end
end
class CreateParams < Stripe::RequestParams
class Pin < Stripe::RequestParams
# The card's desired new PIN, encrypted under Stripe's public key.
sig { returns(T.nilable(String)) }
attr_accessor :encrypted_number
sig { params(encrypted_number: T.nilable(String)).void }
def initialize(encrypted_number: nil); end
end
class Shipping < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(String) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(String) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(String) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(String) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: String, country: String, line1: String, line2: T.nilable(String), postal_code: String, state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class AddressValidation < Stripe::RequestParams
# The address validation capabilities to use.
sig { returns(String) }
attr_accessor :mode
sig { params(mode: String).void }
def initialize(mode: nil); end
end
class Customs < Stripe::RequestParams
# The Economic Operators Registration and Identification (EORI) number to use for Customs. Required for bulk shipments to Europe.
sig { returns(T.nilable(String)) }
attr_accessor :eori_number
sig { params(eori_number: T.nilable(String)).void }
def initialize(eori_number: nil); end
end
# The address that the card is shipped to.
sig { returns(::Stripe::Issuing::CardService::CreateParams::Shipping::Address) }
attr_accessor :address
# Address validation settings.
sig {
returns(T.nilable(::Stripe::Issuing::CardService::CreateParams::Shipping::AddressValidation))
}
attr_accessor :address_validation
# Customs information for the shipment.
sig {
returns(T.nilable(::Stripe::Issuing::CardService::CreateParams::Shipping::Customs))
}
attr_accessor :customs
# The name printed on the shipping label when shipping the card.
sig { returns(String) }
attr_accessor :name
# Phone number of the recipient of the shipment.
sig { returns(T.nilable(String)) }
attr_accessor :phone_number
# Whether a signature is required for card delivery.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :require_signature
# Shipment service.
sig { returns(T.nilable(String)) }
attr_accessor :service
# Packaging options.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(address: ::Stripe::Issuing::CardService::CreateParams::Shipping::Address, address_validation: T.nilable(::Stripe::Issuing::CardService::CreateParams::Shipping::AddressValidation), customs: T.nilable(::Stripe::Issuing::CardService::CreateParams::Shipping::Customs), name: String, phone_number: T.nilable(String), require_signature: T.nilable(T::Boolean), service: T.nilable(String), type: T.nilable(String)).void
}
def initialize(
address: nil,
address_validation: nil,
customs: nil,
name: nil,
phone_number: nil,
require_signature: nil,
service: nil,
type: nil
); end
end
class SpendingControls < Stripe::RequestParams
class SpendingLimit < Stripe::RequestParams
# Maximum amount allowed to spend per interval.
sig { returns(Integer) }
attr_accessor :amount
# Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) this limit applies to. Omitting this field will apply the limit to all categories.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :categories
# Interval (or event) to which the amount applies.
sig { returns(String) }
attr_accessor :interval
sig {
params(amount: Integer, categories: T.nilable(T::Array[String]), interval: String).void
}
def initialize(amount: nil, categories: nil, interval: nil); end
end
# Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to allow. All other categories will be blocked. Cannot be set with `blocked_categories`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :allowed_categories
# Array of strings containing representing countries from which authorizations will be allowed. Authorizations from merchants in all other countries will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `blocked_merchant_countries`. Provide an empty value to unset this control.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :allowed_merchant_countries
# Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to decline. All other categories will be allowed. Cannot be set with `allowed_categories`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :blocked_categories
# Array of strings containing representing countries from which authorizations will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `allowed_merchant_countries`. Provide an empty value to unset this control.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :blocked_merchant_countries
# Limit spending with amount-based rules that apply across any cards this card replaced (i.e., its `replacement_for` card and _that_ card's `replacement_for` card, up the chain).
sig {
returns(T.nilable(T::Array[::Stripe::Issuing::CardService::CreateParams::SpendingControls::SpendingLimit]))
}
attr_accessor :spending_limits
sig {
params(allowed_categories: T.nilable(T::Array[String]), allowed_merchant_countries: T.nilable(T::Array[String]), blocked_categories: T.nilable(T::Array[String]), blocked_merchant_countries: T.nilable(T::Array[String]), spending_limits: T.nilable(T::Array[::Stripe::Issuing::CardService::CreateParams::SpendingControls::SpendingLimit])).void
}
def initialize(
allowed_categories: nil,
allowed_merchant_countries: nil,
blocked_categories: nil,
blocked_merchant_countries: nil,
spending_limits: nil
); end
end
# The [Cardholder](https://stripe.com/docs/api#issuing_cardholder_object) object with which the card will be associated.
sig { returns(T.nilable(String)) }
attr_accessor :cardholder
# The currency for the card.
sig { returns(String) }
attr_accessor :currency
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The new financial account ID the card will be associated with. This field allows a card to be reassigned to a different financial account.
sig { returns(T.nilable(String)) }
attr_accessor :financial_account
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The personalization design object belonging to this card.
sig { returns(T.nilable(String)) }
attr_accessor :personalization_design
# The desired PIN for this card.
sig { returns(T.nilable(::Stripe::Issuing::CardService::CreateParams::Pin)) }
attr_accessor :pin
# The card this is meant to be a replacement for (if any).
sig { returns(T.nilable(String)) }
attr_accessor :replacement_for
# If `replacement_for` is specified, this should indicate why that card is being replaced.
sig { returns(T.nilable(String)) }
attr_accessor :replacement_reason
# The second line to print on the card. Max length: 24 characters.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :second_line
# The address where the card will be shipped.
sig { returns(T.nilable(::Stripe::Issuing::CardService::CreateParams::Shipping)) }
attr_accessor :shipping
# Rules that control spending for this card. Refer to our [documentation](https://stripe.com/docs/issuing/controls/spending-controls) for more details.
sig { returns(T.nilable(::Stripe::Issuing::CardService::CreateParams::SpendingControls)) }
attr_accessor :spending_controls
# Whether authorizations can be approved on this card. May be blocked from activating cards depending on past-due Cardholder requirements. Defaults to `inactive`.
sig { returns(T.nilable(String)) }
attr_accessor :status
# The type of card to issue. Possible values are `physical` or `virtual`.
sig { returns(String) }
attr_accessor :type
sig {
params(cardholder: T.nilable(String), currency: String, expand: T.nilable(T::Array[String]), financial_account: T.nilable(String), metadata: T.nilable(T::Hash[String, String]), personalization_design: T.nilable(String), pin: T.nilable(::Stripe::Issuing::CardService::CreateParams::Pin), replacement_for: T.nilable(String), replacement_reason: T.nilable(String), second_line: T.nilable(T.nilable(String)), shipping: T.nilable(::Stripe::Issuing::CardService::CreateParams::Shipping), spending_controls: T.nilable(::Stripe::Issuing::CardService::CreateParams::SpendingControls), status: T.nilable(String), type: String).void
}
def initialize(
cardholder: nil,
currency: nil,
expand: nil,
financial_account: nil,
metadata: nil,
personalization_design: nil,
pin: nil,
replacement_for: nil,
replacement_reason: nil,
second_line: nil,
shipping: nil,
spending_controls: nil,
status: nil,
type: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
class Pin < Stripe::RequestParams
# The card's desired new PIN, encrypted under Stripe's public key.
sig { returns(T.nilable(String)) }
attr_accessor :encrypted_number
sig { params(encrypted_number: T.nilable(String)).void }
def initialize(encrypted_number: nil); end
end
class Shipping < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(String) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(String) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(String) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(String) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: String, country: String, line1: String, line2: T.nilable(String), postal_code: String, state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class AddressValidation < Stripe::RequestParams
# The address validation capabilities to use.
sig { returns(String) }
attr_accessor :mode
sig { params(mode: String).void }
def initialize(mode: nil); end
end
class Customs < Stripe::RequestParams
# The Economic Operators Registration and Identification (EORI) number to use for Customs. Required for bulk shipments to Europe.
sig { returns(T.nilable(String)) }
attr_accessor :eori_number
sig { params(eori_number: T.nilable(String)).void }
def initialize(eori_number: nil); end
end
# The address that the card is shipped to.
sig { returns(::Stripe::Issuing::CardService::UpdateParams::Shipping::Address) }
attr_accessor :address
# Address validation settings.
sig {
returns(T.nilable(::Stripe::Issuing::CardService::UpdateParams::Shipping::AddressValidation))
}
attr_accessor :address_validation
# Customs information for the shipment.
sig {
returns(T.nilable(::Stripe::Issuing::CardService::UpdateParams::Shipping::Customs))
}
attr_accessor :customs
# The name printed on the shipping label when shipping the card.
sig { returns(String) }
attr_accessor :name
# Phone number of the recipient of the shipment.
sig { returns(T.nilable(String)) }
attr_accessor :phone_number
# Whether a signature is required for card delivery.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :require_signature
# Shipment service.
sig { returns(T.nilable(String)) }
attr_accessor :service
# Packaging options.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(address: ::Stripe::Issuing::CardService::UpdateParams::Shipping::Address, address_validation: T.nilable(::Stripe::Issuing::CardService::UpdateParams::Shipping::AddressValidation), customs: T.nilable(::Stripe::Issuing::CardService::UpdateParams::Shipping::Customs), name: String, phone_number: T.nilable(String), require_signature: T.nilable(T::Boolean), service: T.nilable(String), type: T.nilable(String)).void
}
def initialize(
address: nil,
address_validation: nil,
customs: nil,
name: nil,
phone_number: nil,
require_signature: nil,
service: nil,
type: nil
); end
end
class SpendingControls < Stripe::RequestParams
class SpendingLimit < Stripe::RequestParams
# Maximum amount allowed to spend per interval.
sig { returns(Integer) }
attr_accessor :amount
# Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) this limit applies to. Omitting this field will apply the limit to all categories.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :categories
# Interval (or event) to which the amount applies.
sig { returns(String) }
attr_accessor :interval
sig {
params(amount: Integer, categories: T.nilable(T::Array[String]), interval: String).void
}
def initialize(amount: nil, categories: nil, interval: nil); end
end
# Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to allow. All other categories will be blocked. Cannot be set with `blocked_categories`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :allowed_categories
# Array of strings containing representing countries from which authorizations will be allowed. Authorizations from merchants in all other countries will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `blocked_merchant_countries`. Provide an empty value to unset this control.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :allowed_merchant_countries
# Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to decline. All other categories will be allowed. Cannot be set with `allowed_categories`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :blocked_categories
# Array of strings containing representing countries from which authorizations will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `allowed_merchant_countries`. Provide an empty value to unset this control.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :blocked_merchant_countries
# Limit spending with amount-based rules that apply across any cards this card replaced (i.e., its `replacement_for` card and _that_ card's `replacement_for` card, up the chain).
sig {
returns(T.nilable(T::Array[::Stripe::Issuing::CardService::UpdateParams::SpendingControls::SpendingLimit]))
}
attr_accessor :spending_limits
sig {
params(allowed_categories: T.nilable(T::Array[String]), allowed_merchant_countries: T.nilable(T::Array[String]), blocked_categories: T.nilable(T::Array[String]), blocked_merchant_countries: T.nilable(T::Array[String]), spending_limits: T.nilable(T::Array[::Stripe::Issuing::CardService::UpdateParams::SpendingControls::SpendingLimit])).void
}
def initialize(
allowed_categories: nil,
allowed_merchant_countries: nil,
blocked_categories: nil,
blocked_merchant_countries: nil,
spending_limits: nil
); end
end
# Reason why the `status` of this card is `canceled`.
sig { returns(T.nilable(String)) }
attr_accessor :cancellation_reason
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Attribute for param field personalization_design
sig { returns(T.nilable(String)) }
attr_accessor :personalization_design
# The desired new PIN for this card.
sig { returns(T.nilable(::Stripe::Issuing::CardService::UpdateParams::Pin)) }
attr_accessor :pin
# Updated shipping information for the card.
sig { returns(T.nilable(::Stripe::Issuing::CardService::UpdateParams::Shipping)) }
attr_accessor :shipping
# Rules that control spending for this card. Refer to our [documentation](https://stripe.com/docs/issuing/controls/spending-controls) for more details.
sig { returns(T.nilable(::Stripe::Issuing::CardService::UpdateParams::SpendingControls)) }
attr_accessor :spending_controls
# Dictates whether authorizations can be approved on this card. May be blocked from activating cards depending on past-due Cardholder requirements. Defaults to `inactive`. If this card is being canceled because it was lost or stolen, this information should be provided as `cancellation_reason`.
sig { returns(T.nilable(String)) }
attr_accessor :status
sig {
params(cancellation_reason: T.nilable(String), expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), personalization_design: T.nilable(String), pin: T.nilable(::Stripe::Issuing::CardService::UpdateParams::Pin), shipping: T.nilable(::Stripe::Issuing::CardService::UpdateParams::Shipping), spending_controls: T.nilable(::Stripe::Issuing::CardService::UpdateParams::SpendingControls), status: T.nilable(String)).void
}
def initialize(
cancellation_reason: nil,
expand: nil,
metadata: nil,
personalization_design: nil,
pin: nil,
shipping: nil,
spending_controls: nil,
status: nil
); end
end
# Creates an Issuing Card object.
sig {
params(params: T.any(::Stripe::Issuing::CardService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Card)
}
def create(params = {}, opts = {}); end
# Returns a list of Issuing Card objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.
sig {
params(params: T.any(::Stripe::Issuing::CardService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves an Issuing Card object.
sig {
params(card: String, params: T.any(::Stripe::Issuing::CardService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Card)
}
def retrieve(card, params = {}, opts = {}); end
# Updates the specified Issuing Card object by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
sig {
params(card: String, params: T.any(::Stripe::Issuing::CardService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Card)
}
def update(card, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Issuing
class CardholderService < StripeService
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return cardholders that were created during the given date interval.
sig {
returns(T.nilable(T.any(::Stripe::Issuing::CardholderService::ListParams::Created, Integer)))
}
attr_accessor :created
# Only return cardholders that have the given email address.
sig { returns(T.nilable(String)) }
attr_accessor :email
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Only return cardholders that have the given phone number.
sig { returns(T.nilable(String)) }
attr_accessor :phone_number
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return cardholders that have the given status. One of `active`, `inactive`, or `blocked`.
sig { returns(T.nilable(String)) }
attr_accessor :status
# Only return cardholders that have the given type. One of `individual` or `company`.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(created: T.nilable(T.any(::Stripe::Issuing::CardholderService::ListParams::Created, Integer)), email: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), phone_number: T.nilable(String), starting_after: T.nilable(String), status: T.nilable(String), type: T.nilable(String)).void
}
def initialize(
created: nil,
email: nil,
ending_before: nil,
expand: nil,
limit: nil,
phone_number: nil,
starting_after: nil,
status: nil,
type: nil
); end
end
class CreateParams < Stripe::RequestParams
class Billing < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(String) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(String) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(String) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(String) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: String, country: String, line1: String, line2: T.nilable(String), postal_code: String, state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# The cardholder’s billing address.
sig { returns(::Stripe::Issuing::CardholderService::CreateParams::Billing::Address) }
attr_accessor :address
sig {
params(address: ::Stripe::Issuing::CardholderService::CreateParams::Billing::Address).void
}
def initialize(address: nil); end
end
class Company < Stripe::RequestParams
# The entity's business ID number.
sig { returns(T.nilable(String)) }
attr_accessor :tax_id
sig { params(tax_id: T.nilable(String)).void }
def initialize(tax_id: nil); end
end
class Individual < Stripe::RequestParams
class CardIssuing < Stripe::RequestParams
class UserTermsAcceptance < Stripe::RequestParams
# The Unix timestamp marking when the cardholder accepted the Authorized User Terms. Required for Celtic Spend Card users.
sig { returns(T.nilable(Integer)) }
attr_accessor :date
# The IP address from which the cardholder accepted the Authorized User Terms. Required for Celtic Spend Card users.
sig { returns(T.nilable(String)) }
attr_accessor :ip
# The user agent of the browser from which the cardholder accepted the Authorized User Terms.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :user_agent
sig {
params(date: T.nilable(Integer), ip: T.nilable(String), user_agent: T.nilable(T.nilable(String))).void
}
def initialize(date: nil, ip: nil, user_agent: nil); end
end
# Information about cardholder acceptance of Celtic [Authorized User Terms](https://stripe.com/docs/issuing/cards#accept-authorized-user-terms). Required for cards backed by a Celtic program.
sig {
returns(T.nilable(::Stripe::Issuing::CardholderService::CreateParams::Individual::CardIssuing::UserTermsAcceptance))
}
attr_accessor :user_terms_acceptance
sig {
params(user_terms_acceptance: T.nilable(::Stripe::Issuing::CardholderService::CreateParams::Individual::CardIssuing::UserTermsAcceptance)).void
}
def initialize(user_terms_acceptance: nil); end
end
class Dob < Stripe::RequestParams
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
class Verification < Stripe::RequestParams
class Document < Stripe::RequestParams
# The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`.
sig { returns(T.nilable(String)) }
attr_accessor :back
# The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`.
sig { returns(T.nilable(String)) }
attr_accessor :front
sig { params(back: T.nilable(String), front: T.nilable(String)).void }
def initialize(back: nil, front: nil); end
end
# An identifying document, either a passport or local ID card.
sig {
returns(T.nilable(::Stripe::Issuing::CardholderService::CreateParams::Individual::Verification::Document))
}
attr_accessor :document
sig {
params(document: T.nilable(::Stripe::Issuing::CardholderService::CreateParams::Individual::Verification::Document)).void
}
def initialize(document: nil); end
end
# Information related to the card_issuing program for this cardholder.
sig {
returns(T.nilable(::Stripe::Issuing::CardholderService::CreateParams::Individual::CardIssuing))
}
attr_accessor :card_issuing
# The date of birth of this cardholder. Cardholders must be older than 13 years old.
sig {
returns(T.nilable(::Stripe::Issuing::CardholderService::CreateParams::Individual::Dob))
}
attr_accessor :dob
# The first name of this cardholder. Required before activating Cards. This field cannot contain any numbers, special characters (except periods, commas, hyphens, spaces and apostrophes) or non-latin letters.
sig { returns(T.nilable(String)) }
attr_accessor :first_name
# The last name of this cardholder. Required before activating Cards. This field cannot contain any numbers, special characters (except periods, commas, hyphens, spaces and apostrophes) or non-latin letters.
sig { returns(T.nilable(String)) }
attr_accessor :last_name
# Government-issued ID document for this cardholder.
sig {
returns(T.nilable(::Stripe::Issuing::CardholderService::CreateParams::Individual::Verification))
}
attr_accessor :verification
sig {
params(card_issuing: T.nilable(::Stripe::Issuing::CardholderService::CreateParams::Individual::CardIssuing), dob: T.nilable(::Stripe::Issuing::CardholderService::CreateParams::Individual::Dob), first_name: T.nilable(String), last_name: T.nilable(String), verification: T.nilable(::Stripe::Issuing::CardholderService::CreateParams::Individual::Verification)).void
}
def initialize(
card_issuing: nil,
dob: nil,
first_name: nil,
last_name: nil,
verification: nil
); end
end
class SpendingControls < Stripe::RequestParams
class SpendingLimit < Stripe::RequestParams
# Maximum amount allowed to spend per interval.
sig { returns(Integer) }
attr_accessor :amount
# Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) this limit applies to. Omitting this field will apply the limit to all categories.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :categories
# Interval (or event) to which the amount applies.
sig { returns(String) }
attr_accessor :interval
sig {
params(amount: Integer, categories: T.nilable(T::Array[String]), interval: String).void
}
def initialize(amount: nil, categories: nil, interval: nil); end
end
# Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to allow. All other categories will be blocked. Cannot be set with `blocked_categories`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :allowed_categories
# Array of strings containing representing countries from which authorizations will be allowed. Authorizations from merchants in all other countries will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `blocked_merchant_countries`. Provide an empty value to unset this control.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :allowed_merchant_countries
# Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to decline. All other categories will be allowed. Cannot be set with `allowed_categories`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :blocked_categories
# Array of strings containing representing countries from which authorizations will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `allowed_merchant_countries`. Provide an empty value to unset this control.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :blocked_merchant_countries
# Limit spending with amount-based rules that apply across this cardholder's cards.
sig {
returns(T.nilable(T::Array[::Stripe::Issuing::CardholderService::CreateParams::SpendingControls::SpendingLimit]))
}
attr_accessor :spending_limits
# Currency of amounts within `spending_limits`. Defaults to your merchant country's currency.
sig { returns(T.nilable(String)) }
attr_accessor :spending_limits_currency
sig {
params(allowed_categories: T.nilable(T::Array[String]), allowed_merchant_countries: T.nilable(T::Array[String]), blocked_categories: T.nilable(T::Array[String]), blocked_merchant_countries: T.nilable(T::Array[String]), spending_limits: T.nilable(T::Array[::Stripe::Issuing::CardholderService::CreateParams::SpendingControls::SpendingLimit]), spending_limits_currency: T.nilable(String)).void
}
def initialize(
allowed_categories: nil,
allowed_merchant_countries: nil,
blocked_categories: nil,
blocked_merchant_countries: nil,
spending_limits: nil,
spending_limits_currency: nil
); end
end
# The cardholder's billing address.
sig { returns(::Stripe::Issuing::CardholderService::CreateParams::Billing) }
attr_accessor :billing
# Additional information about a `company` cardholder.
sig { returns(T.nilable(::Stripe::Issuing::CardholderService::CreateParams::Company)) }
attr_accessor :company
# The cardholder's email address.
sig { returns(T.nilable(String)) }
attr_accessor :email
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Additional information about an `individual` cardholder.
sig { returns(T.nilable(::Stripe::Issuing::CardholderService::CreateParams::Individual)) }
attr_accessor :individual
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The cardholder's name. This will be printed on cards issued to them. The maximum length of this field is 24 characters. This field cannot contain any special characters or numbers.
sig { returns(String) }
attr_accessor :name
# The cardholder's phone number. This will be transformed to [E.164](https://en.wikipedia.org/wiki/E.164) if it is not provided in that format already. 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.
sig { returns(T.nilable(String)) }
attr_accessor :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.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :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.
sig {
returns(T.nilable(::Stripe::Issuing::CardholderService::CreateParams::SpendingControls))
}
attr_accessor :spending_controls
# Specifies whether to permit authorizations on this cardholder's cards. Defaults to `active`.
sig { returns(T.nilable(String)) }
attr_accessor :status
# One of `individual` or `company`. See [Choose a cardholder type](https://stripe.com/docs/issuing/other/choose-cardholder) for more details.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(billing: ::Stripe::Issuing::CardholderService::CreateParams::Billing, company: T.nilable(::Stripe::Issuing::CardholderService::CreateParams::Company), email: T.nilable(String), expand: T.nilable(T::Array[String]), individual: T.nilable(::Stripe::Issuing::CardholderService::CreateParams::Individual), metadata: T.nilable(T::Hash[String, String]), name: String, phone_number: T.nilable(String), preferred_locales: T.nilable(T::Array[String]), spending_controls: T.nilable(::Stripe::Issuing::CardholderService::CreateParams::SpendingControls), status: T.nilable(String), type: T.nilable(String)).void
}
def initialize(
billing: nil,
company: nil,
email: nil,
expand: nil,
individual: nil,
metadata: nil,
name: nil,
phone_number: nil,
preferred_locales: nil,
spending_controls: nil,
status: nil,
type: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
class Billing < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(String) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(String) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(String) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(String) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: String, country: String, line1: String, line2: T.nilable(String), postal_code: String, state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# The cardholder’s billing address.
sig { returns(::Stripe::Issuing::CardholderService::UpdateParams::Billing::Address) }
attr_accessor :address
sig {
params(address: ::Stripe::Issuing::CardholderService::UpdateParams::Billing::Address).void
}
def initialize(address: nil); end
end
class Company < Stripe::RequestParams
# The entity's business ID number.
sig { returns(T.nilable(String)) }
attr_accessor :tax_id
sig { params(tax_id: T.nilable(String)).void }
def initialize(tax_id: nil); end
end
class Individual < Stripe::RequestParams
class CardIssuing < Stripe::RequestParams
class UserTermsAcceptance < Stripe::RequestParams
# The Unix timestamp marking when the cardholder accepted the Authorized User Terms. Required for Celtic Spend Card users.
sig { returns(T.nilable(Integer)) }
attr_accessor :date
# The IP address from which the cardholder accepted the Authorized User Terms. Required for Celtic Spend Card users.
sig { returns(T.nilable(String)) }
attr_accessor :ip
# The user agent of the browser from which the cardholder accepted the Authorized User Terms.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :user_agent
sig {
params(date: T.nilable(Integer), ip: T.nilable(String), user_agent: T.nilable(T.nilable(String))).void
}
def initialize(date: nil, ip: nil, user_agent: nil); end
end
# Information about cardholder acceptance of Celtic [Authorized User Terms](https://stripe.com/docs/issuing/cards#accept-authorized-user-terms). Required for cards backed by a Celtic program.
sig {
returns(T.nilable(::Stripe::Issuing::CardholderService::UpdateParams::Individual::CardIssuing::UserTermsAcceptance))
}
attr_accessor :user_terms_acceptance
sig {
params(user_terms_acceptance: T.nilable(::Stripe::Issuing::CardholderService::UpdateParams::Individual::CardIssuing::UserTermsAcceptance)).void
}
def initialize(user_terms_acceptance: nil); end
end
class Dob < Stripe::RequestParams
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
class Verification < Stripe::RequestParams
class Document < Stripe::RequestParams
# The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`.
sig { returns(T.nilable(String)) }
attr_accessor :back
# The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`.
sig { returns(T.nilable(String)) }
attr_accessor :front
sig { params(back: T.nilable(String), front: T.nilable(String)).void }
def initialize(back: nil, front: nil); end
end
# An identifying document, either a passport or local ID card.
sig {
returns(T.nilable(::Stripe::Issuing::CardholderService::UpdateParams::Individual::Verification::Document))
}
attr_accessor :document
sig {
params(document: T.nilable(::Stripe::Issuing::CardholderService::UpdateParams::Individual::Verification::Document)).void
}
def initialize(document: nil); end
end
# Information related to the card_issuing program for this cardholder.
sig {
returns(T.nilable(::Stripe::Issuing::CardholderService::UpdateParams::Individual::CardIssuing))
}
attr_accessor :card_issuing
# The date of birth of this cardholder. Cardholders must be older than 13 years old.
sig {
returns(T.nilable(::Stripe::Issuing::CardholderService::UpdateParams::Individual::Dob))
}
attr_accessor :dob
# The first name of this cardholder. Required before activating Cards. This field cannot contain any numbers, special characters (except periods, commas, hyphens, spaces and apostrophes) or non-latin letters.
sig { returns(T.nilable(String)) }
attr_accessor :first_name
# The last name of this cardholder. Required before activating Cards. This field cannot contain any numbers, special characters (except periods, commas, hyphens, spaces and apostrophes) or non-latin letters.
sig { returns(T.nilable(String)) }
attr_accessor :last_name
# Government-issued ID document for this cardholder.
sig {
returns(T.nilable(::Stripe::Issuing::CardholderService::UpdateParams::Individual::Verification))
}
attr_accessor :verification
sig {
params(card_issuing: T.nilable(::Stripe::Issuing::CardholderService::UpdateParams::Individual::CardIssuing), dob: T.nilable(::Stripe::Issuing::CardholderService::UpdateParams::Individual::Dob), first_name: T.nilable(String), last_name: T.nilable(String), verification: T.nilable(::Stripe::Issuing::CardholderService::UpdateParams::Individual::Verification)).void
}
def initialize(
card_issuing: nil,
dob: nil,
first_name: nil,
last_name: nil,
verification: nil
); end
end
class SpendingControls < Stripe::RequestParams
class SpendingLimit < Stripe::RequestParams
# Maximum amount allowed to spend per interval.
sig { returns(Integer) }
attr_accessor :amount
# Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) this limit applies to. Omitting this field will apply the limit to all categories.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :categories
# Interval (or event) to which the amount applies.
sig { returns(String) }
attr_accessor :interval
sig {
params(amount: Integer, categories: T.nilable(T::Array[String]), interval: String).void
}
def initialize(amount: nil, categories: nil, interval: nil); end
end
# Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to allow. All other categories will be blocked. Cannot be set with `blocked_categories`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :allowed_categories
# Array of strings containing representing countries from which authorizations will be allowed. Authorizations from merchants in all other countries will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `blocked_merchant_countries`. Provide an empty value to unset this control.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :allowed_merchant_countries
# Array of strings containing [categories](https://stripe.com/docs/api#issuing_authorization_object-merchant_data-category) of authorizations to decline. All other categories will be allowed. Cannot be set with `allowed_categories`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :blocked_categories
# Array of strings containing representing countries from which authorizations will be declined. Country codes should be ISO 3166 alpha-2 country codes (e.g. `US`). Cannot be set with `allowed_merchant_countries`. Provide an empty value to unset this control.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :blocked_merchant_countries
# Limit spending with amount-based rules that apply across this cardholder's cards.
sig {
returns(T.nilable(T::Array[::Stripe::Issuing::CardholderService::UpdateParams::SpendingControls::SpendingLimit]))
}
attr_accessor :spending_limits
# Currency of amounts within `spending_limits`. Defaults to your merchant country's currency.
sig { returns(T.nilable(String)) }
attr_accessor :spending_limits_currency
sig {
params(allowed_categories: T.nilable(T::Array[String]), allowed_merchant_countries: T.nilable(T::Array[String]), blocked_categories: T.nilable(T::Array[String]), blocked_merchant_countries: T.nilable(T::Array[String]), spending_limits: T.nilable(T::Array[::Stripe::Issuing::CardholderService::UpdateParams::SpendingControls::SpendingLimit]), spending_limits_currency: T.nilable(String)).void
}
def initialize(
allowed_categories: nil,
allowed_merchant_countries: nil,
blocked_categories: nil,
blocked_merchant_countries: nil,
spending_limits: nil,
spending_limits_currency: nil
); end
end
# The cardholder's billing address.
sig { returns(T.nilable(::Stripe::Issuing::CardholderService::UpdateParams::Billing)) }
attr_accessor :billing
# Additional information about a `company` cardholder.
sig { returns(T.nilable(::Stripe::Issuing::CardholderService::UpdateParams::Company)) }
attr_accessor :company
# The cardholder's email address.
sig { returns(T.nilable(String)) }
attr_accessor :email
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Additional information about an `individual` cardholder.
sig { returns(T.nilable(::Stripe::Issuing::CardholderService::UpdateParams::Individual)) }
attr_accessor :individual
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# 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) for more details.
sig { returns(T.nilable(String)) }
attr_accessor :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.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :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.
sig {
returns(T.nilable(::Stripe::Issuing::CardholderService::UpdateParams::SpendingControls))
}
attr_accessor :spending_controls
# Specifies whether to permit authorizations on this cardholder's cards.
sig { returns(T.nilable(String)) }
attr_accessor :status
sig {
params(billing: T.nilable(::Stripe::Issuing::CardholderService::UpdateParams::Billing), company: T.nilable(::Stripe::Issuing::CardholderService::UpdateParams::Company), email: T.nilable(String), expand: T.nilable(T::Array[String]), individual: T.nilable(::Stripe::Issuing::CardholderService::UpdateParams::Individual), metadata: T.nilable(T::Hash[String, String]), phone_number: T.nilable(String), preferred_locales: T.nilable(T::Array[String]), spending_controls: T.nilable(::Stripe::Issuing::CardholderService::UpdateParams::SpendingControls), status: T.nilable(String)).void
}
def initialize(
billing: nil,
company: nil,
email: nil,
expand: nil,
individual: nil,
metadata: nil,
phone_number: nil,
preferred_locales: nil,
spending_controls: nil,
status: nil
); end
end
# Creates a new Issuing Cardholder object that can be issued cards.
sig {
params(params: T.any(::Stripe::Issuing::CardholderService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Cardholder)
}
def create(params = {}, opts = {}); end
# Returns a list of Issuing Cardholder objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.
sig {
params(params: T.any(::Stripe::Issuing::CardholderService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves an Issuing Cardholder object.
sig {
params(cardholder: String, params: T.any(::Stripe::Issuing::CardholderService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Cardholder)
}
def retrieve(cardholder, params = {}, opts = {}); end
# Updates the specified Issuing Cardholder object by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
sig {
params(cardholder: String, params: T.any(::Stripe::Issuing::CardholderService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Cardholder)
}
def update(cardholder, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Issuing
class CreditUnderwritingRecordService < StripeService
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class CorrectParams < Stripe::RequestParams
class Application < Stripe::RequestParams
# The channel through which the applicant has submitted their application. Defaults to `online`.
sig { returns(T.nilable(String)) }
attr_accessor :application_method
# Scope of demand made by the applicant.
sig { returns(String) }
attr_accessor :purpose
# Date when the applicant submitted their application.
sig { returns(Integer) }
attr_accessor :submitted_at
sig {
params(application_method: T.nilable(String), purpose: String, submitted_at: Integer).void
}
def initialize(application_method: nil, purpose: nil, submitted_at: nil); end
end
class CreditUser < Stripe::RequestParams
# Email of the applicant or accountholder.
sig { returns(String) }
attr_accessor :email
# Full name of the company or person.
sig { returns(String) }
attr_accessor :name
sig { params(email: String, name: String).void }
def initialize(email: nil, name: nil); end
end
class Decision < Stripe::RequestParams
class ApplicationRejected < Stripe::RequestParams
# Details about the `reasons.other` when present.
sig { returns(T.nilable(String)) }
attr_accessor :reason_other_explanation
# List of reasons why the application was rejected, up to 4 reasons, in order of importance.
sig { returns(T::Array[String]) }
attr_accessor :reasons
sig {
params(reason_other_explanation: T.nilable(String), reasons: T::Array[String]).void
}
def initialize(reason_other_explanation: nil, reasons: nil); end
end
class CreditLimitApproved < Stripe::RequestParams
# The credit approved, in the currency of the account and [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(Integer) }
attr_accessor :amount
# The currency of the credit approved, will default to the Account's Issuing currency.
sig { returns(T.nilable(String)) }
attr_accessor :currency
sig { params(amount: Integer, currency: T.nilable(String)).void }
def initialize(amount: nil, currency: nil); end
end
class CreditLimitDecreased < Stripe::RequestParams
# The credit approved, in the currency of the account and [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(Integer) }
attr_accessor :amount
# The currency of the credit approved, will default to the Account's Issuing currency.
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Details about the `reasons.other` when present.
sig { returns(T.nilable(String)) }
attr_accessor :reason_other_explanation
# List of reasons why the existing credit was decreased, up to 4 reasons, in order of importance.
sig { returns(T::Array[String]) }
attr_accessor :reasons
sig {
params(amount: Integer, currency: T.nilable(String), reason_other_explanation: T.nilable(String), reasons: T::Array[String]).void
}
def initialize(
amount: nil,
currency: nil,
reason_other_explanation: nil,
reasons: nil
); end
end
class CreditLineClosed < Stripe::RequestParams
# Details about the `reasons.other` when present.
sig { returns(T.nilable(String)) }
attr_accessor :reason_other_explanation
# List of reasons why the credit line was closed, up to 4 reasons, in order of importance.
sig { returns(T::Array[String]) }
attr_accessor :reasons
sig {
params(reason_other_explanation: T.nilable(String), reasons: T::Array[String]).void
}
def initialize(reason_other_explanation: nil, reasons: nil); end
end
# Details about the application rejection.
sig {
returns(T.nilable(::Stripe::Issuing::CreditUnderwritingRecordService::CorrectParams::Decision::ApplicationRejected))
}
attr_accessor :application_rejected
# Details about the credit limit approved. An approved credit limit is required before you can set a `credit_limit_amount` in the [CreditPolicy API](https://stripe.com/docs/api/issuing/credit_policy/)
sig {
returns(T.nilable(::Stripe::Issuing::CreditUnderwritingRecordService::CorrectParams::Decision::CreditLimitApproved))
}
attr_accessor :credit_limit_approved
# Details about the credit limit decreased.
sig {
returns(T.nilable(::Stripe::Issuing::CreditUnderwritingRecordService::CorrectParams::Decision::CreditLimitDecreased))
}
attr_accessor :credit_limit_decreased
# Details about the credit line closed.
sig {
returns(T.nilable(::Stripe::Issuing::CreditUnderwritingRecordService::CorrectParams::Decision::CreditLineClosed))
}
attr_accessor :credit_line_closed
# Outcome of the decision.
sig { returns(String) }
attr_accessor :type
sig {
params(application_rejected: T.nilable(::Stripe::Issuing::CreditUnderwritingRecordService::CorrectParams::Decision::ApplicationRejected), credit_limit_approved: T.nilable(::Stripe::Issuing::CreditUnderwritingRecordService::CorrectParams::Decision::CreditLimitApproved), credit_limit_decreased: T.nilable(::Stripe::Issuing::CreditUnderwritingRecordService::CorrectParams::Decision::CreditLimitDecreased), credit_line_closed: T.nilable(::Stripe::Issuing::CreditUnderwritingRecordService::CorrectParams::Decision::CreditLineClosed), type: String).void
}
def initialize(
application_rejected: nil,
credit_limit_approved: nil,
credit_limit_decreased: nil,
credit_line_closed: nil,
type: nil
); end
end
class UnderwritingException < Stripe::RequestParams
# Written explanation for the exception.
sig { returns(String) }
attr_accessor :explanation
# The decision before the exception was applied.
sig { returns(String) }
attr_accessor :original_decision_type
sig { params(explanation: String, original_decision_type: String).void }
def initialize(explanation: nil, original_decision_type: nil); end
end
# Details about the application submission.
sig {
returns(T.nilable(::Stripe::Issuing::CreditUnderwritingRecordService::CorrectParams::Application))
}
attr_accessor :application
# Information about the company or person applying or holding the account.
sig {
returns(T.nilable(::Stripe::Issuing::CreditUnderwritingRecordService::CorrectParams::CreditUser))
}
attr_accessor :credit_user
# Date when a decision was made.
sig { returns(T.nilable(Integer)) }
attr_accessor :decided_at
# Details about the decision.
sig {
returns(T.nilable(::Stripe::Issuing::CreditUnderwritingRecordService::CorrectParams::Decision))
}
attr_accessor :decision
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# File containing regulatory reporting data for the decision. Required if you are subject to this [reporting requirement](https://stripe.com/docs/issuing/credit/report-required-regulatory-data-for-credit-decisions). Optional if previously provided and no changes are needed.
sig { returns(T.nilable(String)) }
attr_accessor :regulatory_reporting_file
# If an exception to the usual underwriting criteria was made for this decision, details about the exception must be provided. Exceptions should only be granted in rare circumstances, in consultation with Stripe Compliance.
sig {
returns(T.nilable(::Stripe::Issuing::CreditUnderwritingRecordService::CorrectParams::UnderwritingException))
}
attr_accessor :underwriting_exception
sig {
params(application: T.nilable(::Stripe::Issuing::CreditUnderwritingRecordService::CorrectParams::Application), credit_user: T.nilable(::Stripe::Issuing::CreditUnderwritingRecordService::CorrectParams::CreditUser), decided_at: T.nilable(Integer), decision: T.nilable(::Stripe::Issuing::CreditUnderwritingRecordService::CorrectParams::Decision), expand: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), regulatory_reporting_file: T.nilable(String), underwriting_exception: T.nilable(::Stripe::Issuing::CreditUnderwritingRecordService::CorrectParams::UnderwritingException)).void
}
def initialize(
application: nil,
credit_user: nil,
decided_at: nil,
decision: nil,
expand: nil,
metadata: nil,
regulatory_reporting_file: nil,
underwriting_exception: nil
); end
end
class ReportDecisionParams < Stripe::RequestParams
class Decision < Stripe::RequestParams
class ApplicationRejected < Stripe::RequestParams
# Details about the `reasons.other` when present.
sig { returns(T.nilable(String)) }
attr_accessor :reason_other_explanation
# List of reasons why the application was rejected, up to 4 reasons, in order of importance.
sig { returns(T::Array[String]) }
attr_accessor :reasons
sig {
params(reason_other_explanation: T.nilable(String), reasons: T::Array[String]).void
}
def initialize(reason_other_explanation: nil, reasons: nil); end
end
class CreditLimitApproved < Stripe::RequestParams
# The credit approved, in the currency of the account and [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(Integer) }
attr_accessor :amount
# The currency of the credit approved, will default to the Account's Issuing currency.
sig { returns(T.nilable(String)) }
attr_accessor :currency
sig { params(amount: Integer, currency: T.nilable(String)).void }
def initialize(amount: nil, currency: nil); end
end
# Details about the application rejection.
sig {
returns(T.nilable(::Stripe::Issuing::CreditUnderwritingRecordService::ReportDecisionParams::Decision::ApplicationRejected))
}
attr_accessor :application_rejected
# Details about the credit limit approved. An approved credit limit is required before you can set a `credit_limit_amount` in the [CreditPolicy API](https://stripe.com/docs/api/issuing/credit_policy/)
sig {
returns(T.nilable(::Stripe::Issuing::CreditUnderwritingRecordService::ReportDecisionParams::Decision::CreditLimitApproved))
}
attr_accessor :credit_limit_approved
# Outcome of the decision.
sig { returns(String) }
attr_accessor :type
sig {
params(application_rejected: T.nilable(::Stripe::Issuing::CreditUnderwritingRecordService::ReportDecisionParams::Decision::ApplicationRejected), credit_limit_approved: T.nilable(::Stripe::Issuing::CreditUnderwritingRecordService::ReportDecisionParams::Decision::CreditLimitApproved), type: String).void
}
def initialize(application_rejected: nil, credit_limit_approved: nil, type: nil); end
end
class UnderwritingException < Stripe::RequestParams
# Written explanation for the exception.
sig { returns(String) }
attr_accessor :explanation
# The decision before the exception was applied.
sig { returns(String) }
attr_accessor :original_decision_type
sig { params(explanation: String, original_decision_type: String).void }
def initialize(explanation: nil, original_decision_type: nil); end
end
# Date when a decision was made.
sig { returns(Integer) }
attr_accessor :decided_at
# Details about the decision.
sig {
returns(::Stripe::Issuing::CreditUnderwritingRecordService::ReportDecisionParams::Decision)
}
attr_accessor :decision
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# File containing regulatory reporting data for the decision. Required if you are subject to this [reporting requirement](https://stripe.com/docs/issuing/credit/report-required-regulatory-data-for-credit-decisions).
sig { returns(T.nilable(String)) }
attr_accessor :regulatory_reporting_file
# If an exception to the usual underwriting criteria was made for this decision, details about the exception must be provided. Exceptions should only be granted in rare circumstances, in consultation with Stripe Compliance.
sig {
returns(T.nilable(::Stripe::Issuing::CreditUnderwritingRecordService::ReportDecisionParams::UnderwritingException))
}
attr_accessor :underwriting_exception
sig {
params(decided_at: Integer, decision: ::Stripe::Issuing::CreditUnderwritingRecordService::ReportDecisionParams::Decision, expand: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), regulatory_reporting_file: T.nilable(String), underwriting_exception: T.nilable(::Stripe::Issuing::CreditUnderwritingRecordService::ReportDecisionParams::UnderwritingException)).void
}
def initialize(
decided_at: nil,
decision: nil,
expand: nil,
metadata: nil,
regulatory_reporting_file: nil,
underwriting_exception: nil
); end
end
class CreateFromApplicationParams < Stripe::RequestParams
class Application < Stripe::RequestParams
# The channel through which the applicant has submitted their application. Defaults to `online`.
sig { returns(T.nilable(String)) }
attr_accessor :application_method
# Scope of demand made by the applicant.
sig { returns(String) }
attr_accessor :purpose
# Date when the applicant submitted their application.
sig { returns(Integer) }
attr_accessor :submitted_at
sig {
params(application_method: T.nilable(String), purpose: String, submitted_at: Integer).void
}
def initialize(application_method: nil, purpose: nil, submitted_at: nil); end
end
class CreditUser < Stripe::RequestParams
# Email of the applicant or accountholder.
sig { returns(String) }
attr_accessor :email
# Full name of the company or person.
sig { returns(String) }
attr_accessor :name
sig { params(email: String, name: String).void }
def initialize(email: nil, name: nil); end
end
# Details about the application submission.
sig {
returns(::Stripe::Issuing::CreditUnderwritingRecordService::CreateFromApplicationParams::Application)
}
attr_accessor :application
# Information about the company or person applying or holding the account.
sig {
returns(::Stripe::Issuing::CreditUnderwritingRecordService::CreateFromApplicationParams::CreditUser)
}
attr_accessor :credit_user
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
sig {
params(application: ::Stripe::Issuing::CreditUnderwritingRecordService::CreateFromApplicationParams::Application, credit_user: ::Stripe::Issuing::CreditUnderwritingRecordService::CreateFromApplicationParams::CreditUser, expand: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String])).void
}
def initialize(application: nil, credit_user: nil, expand: nil, metadata: nil); end
end
class CreateFromProactiveReviewParams < Stripe::RequestParams
class CreditUser < Stripe::RequestParams
# Email of the applicant or accountholder.
sig { returns(String) }
attr_accessor :email
# Full name of the company or person.
sig { returns(String) }
attr_accessor :name
sig { params(email: String, name: String).void }
def initialize(email: nil, name: nil); end
end
class Decision < Stripe::RequestParams
class CreditLimitApproved < Stripe::RequestParams
# The credit approved, in the currency of the account and [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(Integer) }
attr_accessor :amount
# The currency of the credit approved, will default to the Account's Issuing currency.
sig { returns(T.nilable(String)) }
attr_accessor :currency
sig { params(amount: Integer, currency: T.nilable(String)).void }
def initialize(amount: nil, currency: nil); end
end
class CreditLimitDecreased < Stripe::RequestParams
# The credit approved, in the currency of the account and [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(Integer) }
attr_accessor :amount
# The currency of the credit approved, will default to the Account's Issuing currency.
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Details about the `reasons.other` when present.
sig { returns(T.nilable(String)) }
attr_accessor :reason_other_explanation
# List of reasons why the existing credit was decreased, up to 4 reasons, in order of importance.
sig { returns(T::Array[String]) }
attr_accessor :reasons
sig {
params(amount: Integer, currency: T.nilable(String), reason_other_explanation: T.nilable(String), reasons: T::Array[String]).void
}
def initialize(
amount: nil,
currency: nil,
reason_other_explanation: nil,
reasons: nil
); end
end
class CreditLineClosed < Stripe::RequestParams
# Details about the `reasons.other` when present.
sig { returns(T.nilable(String)) }
attr_accessor :reason_other_explanation
# List of reasons why the credit line was closed, up to 4 reasons, in order of importance.
sig { returns(T::Array[String]) }
attr_accessor :reasons
sig {
params(reason_other_explanation: T.nilable(String), reasons: T::Array[String]).void
}
def initialize(reason_other_explanation: nil, reasons: nil); end
end
# Details about the credit limit approved. An approved credit limit is required before you can set a `credit_limit_amount` in the [CreditPolicy API](https://stripe.com/docs/api/issuing/credit_policy/)
sig {
returns(T.nilable(::Stripe::Issuing::CreditUnderwritingRecordService::CreateFromProactiveReviewParams::Decision::CreditLimitApproved))
}
attr_accessor :credit_limit_approved
# Details about the credit limit decreased.
sig {
returns(T.nilable(::Stripe::Issuing::CreditUnderwritingRecordService::CreateFromProactiveReviewParams::Decision::CreditLimitDecreased))
}
attr_accessor :credit_limit_decreased
# Details about the credit line closed.
sig {
returns(T.nilable(::Stripe::Issuing::CreditUnderwritingRecordService::CreateFromProactiveReviewParams::Decision::CreditLineClosed))
}
attr_accessor :credit_line_closed
# Outcome of the decision.
sig { returns(String) }
attr_accessor :type
sig {
params(credit_limit_approved: T.nilable(::Stripe::Issuing::CreditUnderwritingRecordService::CreateFromProactiveReviewParams::Decision::CreditLimitApproved), credit_limit_decreased: T.nilable(::Stripe::Issuing::CreditUnderwritingRecordService::CreateFromProactiveReviewParams::Decision::CreditLimitDecreased), credit_line_closed: T.nilable(::Stripe::Issuing::CreditUnderwritingRecordService::CreateFromProactiveReviewParams::Decision::CreditLineClosed), type: String).void
}
def initialize(
credit_limit_approved: nil,
credit_limit_decreased: nil,
credit_line_closed: nil,
type: nil
); end
end
class UnderwritingException < Stripe::RequestParams
# Written explanation for the exception.
sig { returns(String) }
attr_accessor :explanation
# The decision before the exception was applied.
sig { returns(String) }
attr_accessor :original_decision_type
sig { params(explanation: String, original_decision_type: String).void }
def initialize(explanation: nil, original_decision_type: nil); end
end
# Information about the company or person applying or holding the account.
sig {
returns(::Stripe::Issuing::CreditUnderwritingRecordService::CreateFromProactiveReviewParams::CreditUser)
}
attr_accessor :credit_user
# Date when a decision was made.
sig { returns(Integer) }
attr_accessor :decided_at
# Details about the decision.
sig {
returns(::Stripe::Issuing::CreditUnderwritingRecordService::CreateFromProactiveReviewParams::Decision)
}
attr_accessor :decision
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# File containing regulatory reporting data for the decision. Required if you are subject to this [reporting requirement](https://stripe.com/docs/issuing/credit/report-required-regulatory-data-for-credit-decisions).
sig { returns(T.nilable(String)) }
attr_accessor :regulatory_reporting_file
# If an exception to the usual underwriting criteria was made for this decision, details about the exception must be provided. Exceptions should only be granted in rare circumstances, in consultation with Stripe Compliance.
sig {
returns(T.nilable(::Stripe::Issuing::CreditUnderwritingRecordService::CreateFromProactiveReviewParams::UnderwritingException))
}
attr_accessor :underwriting_exception
sig {
params(credit_user: ::Stripe::Issuing::CreditUnderwritingRecordService::CreateFromProactiveReviewParams::CreditUser, decided_at: Integer, decision: ::Stripe::Issuing::CreditUnderwritingRecordService::CreateFromProactiveReviewParams::Decision, expand: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), regulatory_reporting_file: T.nilable(String), underwriting_exception: T.nilable(::Stripe::Issuing::CreditUnderwritingRecordService::CreateFromProactiveReviewParams::UnderwritingException)).void
}
def initialize(
credit_user: nil,
decided_at: nil,
decision: nil,
expand: nil,
metadata: nil,
regulatory_reporting_file: nil,
underwriting_exception: nil
); end
end
# Update a CreditUnderwritingRecord object to correct mistakes.
sig {
params(credit_underwriting_record: String, params: T.any(::Stripe::Issuing::CreditUnderwritingRecordService::CorrectParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::CreditUnderwritingRecord)
}
def correct(credit_underwriting_record, params = {}, opts = {}); end
# Creates a CreditUnderwritingRecord object with information about a credit application submission.
sig {
params(params: T.any(::Stripe::Issuing::CreditUnderwritingRecordService::CreateFromApplicationParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::CreditUnderwritingRecord)
}
def create_from_application(params = {}, opts = {}); end
# Creates a CreditUnderwritingRecord object from an underwriting decision coming from a proactive review of an existing accountholder.
sig {
params(params: T.any(::Stripe::Issuing::CreditUnderwritingRecordService::CreateFromProactiveReviewParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::CreditUnderwritingRecord)
}
def create_from_proactive_review(params = {}, opts = {}); end
# Retrieves a list of CreditUnderwritingRecord objects. The objects are sorted in descending order by creation date, with the most-recently-created object appearing first.
sig {
params(params: T.any(::Stripe::Issuing::CreditUnderwritingRecordService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Update a CreditUnderwritingRecord object from a decision made on a credit application.
sig {
params(credit_underwriting_record: String, params: T.any(::Stripe::Issuing::CreditUnderwritingRecordService::ReportDecisionParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::CreditUnderwritingRecord)
}
def report_decision(credit_underwriting_record, params = {}, opts = {}); end
# Retrieves a CreditUnderwritingRecord object.
sig {
params(credit_underwriting_record: String, params: T.any(::Stripe::Issuing::CreditUnderwritingRecordService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::CreditUnderwritingRecord)
}
def retrieve(credit_underwriting_record, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Issuing
class DisputeService < StripeService
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return Issuing disputes that were created during the given date interval.
sig {
returns(T.nilable(T.any(::Stripe::Issuing::DisputeService::ListParams::Created, Integer)))
}
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Select Issuing disputes with the given status.
sig { returns(T.nilable(String)) }
attr_accessor :status
# Select the Issuing dispute for the given transaction.
sig { returns(T.nilable(String)) }
attr_accessor :transaction
sig {
params(created: T.nilable(T.any(::Stripe::Issuing::DisputeService::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String), status: T.nilable(String), transaction: T.nilable(String)).void
}
def initialize(
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil,
status: nil,
transaction: nil
); end
end
class CreateParams < Stripe::RequestParams
class Evidence < Stripe::RequestParams
class Canceled < Stripe::RequestParams
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :additional_documentation
# Date when order was canceled.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :canceled_at
# Whether the cardholder was provided with a cancellation policy.
sig { returns(T.nilable(T.nilable(T.any(String, T::Boolean)))) }
attr_accessor :cancellation_policy_provided
# Reason for canceling the order.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :cancellation_reason
# Date when the cardholder expected to receive the product.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :expected_at
# Explanation of why the cardholder is disputing this transaction.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :explanation
# Description of the merchandise or service that was purchased.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :product_description
# Whether the product was a merchandise or service.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :product_type
# Result of cardholder's attempt to return the product.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :return_status
# Date when the product was returned or attempted to be returned.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :returned_at
sig {
params(additional_documentation: T.nilable(T.nilable(String)), canceled_at: T.nilable(T.nilable(T.any(String, Integer))), cancellation_policy_provided: T.nilable(T.nilable(T.any(String, T::Boolean))), cancellation_reason: T.nilable(T.nilable(String)), expected_at: T.nilable(T.nilable(T.any(String, Integer))), explanation: T.nilable(T.nilable(String)), product_description: T.nilable(T.nilable(String)), product_type: T.nilable(T.nilable(T.any(String, String))), return_status: T.nilable(T.nilable(T.any(String, String))), returned_at: T.nilable(T.nilable(T.any(String, Integer)))).void
}
def initialize(
additional_documentation: nil,
canceled_at: nil,
cancellation_policy_provided: nil,
cancellation_reason: nil,
expected_at: nil,
explanation: nil,
product_description: nil,
product_type: nil,
return_status: nil,
returned_at: nil
); end
end
class Duplicate < Stripe::RequestParams
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :additional_documentation
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Copy of the card statement showing that the product had already been paid for.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :card_statement
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Copy of the receipt showing that the product had been paid for in cash.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :cash_receipt
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Image of the front and back of the check that was used to pay for the product.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :check_image
# Explanation of why the cardholder is disputing this transaction.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :explanation
# Transaction (e.g., ipi_...) that the disputed transaction is a duplicate of. Of the two or more transactions that are copies of each other, this is original undisputed one.
sig { returns(T.nilable(String)) }
attr_accessor :original_transaction
sig {
params(additional_documentation: T.nilable(T.nilable(String)), card_statement: T.nilable(T.nilable(String)), cash_receipt: T.nilable(T.nilable(String)), check_image: T.nilable(T.nilable(String)), explanation: T.nilable(T.nilable(String)), original_transaction: T.nilable(String)).void
}
def initialize(
additional_documentation: nil,
card_statement: nil,
cash_receipt: nil,
check_image: nil,
explanation: nil,
original_transaction: nil
); end
end
class Fraudulent < Stripe::RequestParams
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :additional_documentation
# Explanation of why the cardholder is disputing this transaction.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :explanation
sig {
params(additional_documentation: T.nilable(T.nilable(String)), explanation: T.nilable(T.nilable(String))).void
}
def initialize(additional_documentation: nil, explanation: nil); end
end
class MerchandiseNotAsDescribed < Stripe::RequestParams
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :additional_documentation
# Explanation of why the cardholder is disputing this transaction.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :explanation
# Date when the product was received.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :received_at
# Description of the cardholder's attempt to return the product.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :return_description
# Result of cardholder's attempt to return the product.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :return_status
# Date when the product was returned or attempted to be returned.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :returned_at
sig {
params(additional_documentation: T.nilable(T.nilable(String)), explanation: T.nilable(T.nilable(String)), received_at: T.nilable(T.nilable(T.any(String, Integer))), return_description: T.nilable(T.nilable(String)), return_status: T.nilable(T.nilable(T.any(String, String))), returned_at: T.nilable(T.nilable(T.any(String, Integer)))).void
}
def initialize(
additional_documentation: nil,
explanation: nil,
received_at: nil,
return_description: nil,
return_status: nil,
returned_at: nil
); end
end
class NoValidAuthorization < Stripe::RequestParams
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :additional_documentation
# Explanation of why the cardholder is disputing this transaction.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :explanation
sig {
params(additional_documentation: T.nilable(T.nilable(String)), explanation: T.nilable(T.nilable(String))).void
}
def initialize(additional_documentation: nil, explanation: nil); end
end
class NotReceived < Stripe::RequestParams
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :additional_documentation
# Date when the cardholder expected to receive the product.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :expected_at
# Explanation of why the cardholder is disputing this transaction.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :explanation
# Description of the merchandise or service that was purchased.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :product_description
# Whether the product was a merchandise or service.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :product_type
sig {
params(additional_documentation: T.nilable(T.nilable(String)), expected_at: T.nilable(T.nilable(T.any(String, Integer))), explanation: T.nilable(T.nilable(String)), product_description: T.nilable(T.nilable(String)), product_type: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(
additional_documentation: nil,
expected_at: nil,
explanation: nil,
product_description: nil,
product_type: nil
); end
end
class Other < Stripe::RequestParams
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :additional_documentation
# Explanation of why the cardholder is disputing this transaction.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :explanation
# Description of the merchandise or service that was purchased.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :product_description
# Whether the product was a merchandise or service.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :product_type
sig {
params(additional_documentation: T.nilable(T.nilable(String)), explanation: T.nilable(T.nilable(String)), product_description: T.nilable(T.nilable(String)), product_type: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(
additional_documentation: nil,
explanation: nil,
product_description: nil,
product_type: nil
); end
end
class ServiceNotAsDescribed < Stripe::RequestParams
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :additional_documentation
# Date when order was canceled.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :canceled_at
# Reason for canceling the order.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :cancellation_reason
# Explanation of why the cardholder is disputing this transaction.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :explanation
# Date when the product was received.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :received_at
sig {
params(additional_documentation: T.nilable(T.nilable(String)), canceled_at: T.nilable(T.nilable(T.any(String, Integer))), cancellation_reason: T.nilable(T.nilable(String)), explanation: T.nilable(T.nilable(String)), received_at: T.nilable(T.nilable(T.any(String, Integer)))).void
}
def initialize(
additional_documentation: nil,
canceled_at: nil,
cancellation_reason: nil,
explanation: nil,
received_at: nil
); end
end
# Evidence provided when `reason` is 'canceled'.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::DisputeService::CreateParams::Evidence::Canceled))))
}
attr_accessor :canceled
# Evidence provided when `reason` is 'duplicate'.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::DisputeService::CreateParams::Evidence::Duplicate))))
}
attr_accessor :duplicate
# Evidence provided when `reason` is 'fraudulent'.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::DisputeService::CreateParams::Evidence::Fraudulent))))
}
attr_accessor :fraudulent
# Evidence provided when `reason` is 'merchandise_not_as_described'.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::DisputeService::CreateParams::Evidence::MerchandiseNotAsDescribed))))
}
attr_accessor :merchandise_not_as_described
# Evidence provided when `reason` is 'no_valid_authorization'.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::DisputeService::CreateParams::Evidence::NoValidAuthorization))))
}
attr_accessor :no_valid_authorization
# Evidence provided when `reason` is 'not_received'.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::DisputeService::CreateParams::Evidence::NotReceived))))
}
attr_accessor :not_received
# Evidence provided when `reason` is 'other'.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::DisputeService::CreateParams::Evidence::Other))))
}
attr_accessor :other
# The reason for filing the dispute. The evidence should be submitted in the field of the same name.
sig { returns(T.nilable(String)) }
attr_accessor :reason
# Evidence provided when `reason` is 'service_not_as_described'.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::DisputeService::CreateParams::Evidence::ServiceNotAsDescribed))))
}
attr_accessor :service_not_as_described
sig {
params(canceled: T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::DisputeService::CreateParams::Evidence::Canceled))), duplicate: T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::DisputeService::CreateParams::Evidence::Duplicate))), fraudulent: T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::DisputeService::CreateParams::Evidence::Fraudulent))), merchandise_not_as_described: T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::DisputeService::CreateParams::Evidence::MerchandiseNotAsDescribed))), no_valid_authorization: T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::DisputeService::CreateParams::Evidence::NoValidAuthorization))), not_received: T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::DisputeService::CreateParams::Evidence::NotReceived))), other: T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::DisputeService::CreateParams::Evidence::Other))), reason: T.nilable(String), service_not_as_described: T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::DisputeService::CreateParams::Evidence::ServiceNotAsDescribed)))).void
}
def initialize(
canceled: nil,
duplicate: nil,
fraudulent: nil,
merchandise_not_as_described: nil,
no_valid_authorization: nil,
not_received: nil,
other: nil,
reason: nil,
service_not_as_described: nil
); end
end
class Treasury < Stripe::RequestParams
# The ID of the ReceivedDebit to initiate an Issuings dispute for.
sig { returns(String) }
attr_accessor :received_debit
sig { params(received_debit: String).void }
def initialize(received_debit: nil); end
end
# The dispute amount in the card's currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal). If not set, defaults to the full transaction amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# Evidence provided for the dispute.
sig { returns(T.nilable(::Stripe::Issuing::DisputeService::CreateParams::Evidence)) }
attr_accessor :evidence
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The ID of the issuing transaction to create a dispute for. For transaction on Treasury FinancialAccounts, use `treasury.received_debit`.
sig { returns(T.nilable(String)) }
attr_accessor :transaction
# Params for disputes related to Treasury FinancialAccounts
sig { returns(T.nilable(::Stripe::Issuing::DisputeService::CreateParams::Treasury)) }
attr_accessor :treasury
sig {
params(amount: T.nilable(Integer), evidence: T.nilable(::Stripe::Issuing::DisputeService::CreateParams::Evidence), expand: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), transaction: T.nilable(String), treasury: T.nilable(::Stripe::Issuing::DisputeService::CreateParams::Treasury)).void
}
def initialize(
amount: nil,
evidence: nil,
expand: nil,
metadata: nil,
transaction: nil,
treasury: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
class Evidence < Stripe::RequestParams
class Canceled < Stripe::RequestParams
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :additional_documentation
# Date when order was canceled.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :canceled_at
# Whether the cardholder was provided with a cancellation policy.
sig { returns(T.nilable(T.nilable(T.any(String, T::Boolean)))) }
attr_accessor :cancellation_policy_provided
# Reason for canceling the order.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :cancellation_reason
# Date when the cardholder expected to receive the product.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :expected_at
# Explanation of why the cardholder is disputing this transaction.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :explanation
# Description of the merchandise or service that was purchased.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :product_description
# Whether the product was a merchandise or service.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :product_type
# Result of cardholder's attempt to return the product.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :return_status
# Date when the product was returned or attempted to be returned.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :returned_at
sig {
params(additional_documentation: T.nilable(T.nilable(String)), canceled_at: T.nilable(T.nilable(T.any(String, Integer))), cancellation_policy_provided: T.nilable(T.nilable(T.any(String, T::Boolean))), cancellation_reason: T.nilable(T.nilable(String)), expected_at: T.nilable(T.nilable(T.any(String, Integer))), explanation: T.nilable(T.nilable(String)), product_description: T.nilable(T.nilable(String)), product_type: T.nilable(T.nilable(T.any(String, String))), return_status: T.nilable(T.nilable(T.any(String, String))), returned_at: T.nilable(T.nilable(T.any(String, Integer)))).void
}
def initialize(
additional_documentation: nil,
canceled_at: nil,
cancellation_policy_provided: nil,
cancellation_reason: nil,
expected_at: nil,
explanation: nil,
product_description: nil,
product_type: nil,
return_status: nil,
returned_at: nil
); end
end
class Duplicate < Stripe::RequestParams
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :additional_documentation
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Copy of the card statement showing that the product had already been paid for.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :card_statement
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Copy of the receipt showing that the product had been paid for in cash.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :cash_receipt
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Image of the front and back of the check that was used to pay for the product.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :check_image
# Explanation of why the cardholder is disputing this transaction.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :explanation
# Transaction (e.g., ipi_...) that the disputed transaction is a duplicate of. Of the two or more transactions that are copies of each other, this is original undisputed one.
sig { returns(T.nilable(String)) }
attr_accessor :original_transaction
sig {
params(additional_documentation: T.nilable(T.nilable(String)), card_statement: T.nilable(T.nilable(String)), cash_receipt: T.nilable(T.nilable(String)), check_image: T.nilable(T.nilable(String)), explanation: T.nilable(T.nilable(String)), original_transaction: T.nilable(String)).void
}
def initialize(
additional_documentation: nil,
card_statement: nil,
cash_receipt: nil,
check_image: nil,
explanation: nil,
original_transaction: nil
); end
end
class Fraudulent < Stripe::RequestParams
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :additional_documentation
# Explanation of why the cardholder is disputing this transaction.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :explanation
sig {
params(additional_documentation: T.nilable(T.nilable(String)), explanation: T.nilable(T.nilable(String))).void
}
def initialize(additional_documentation: nil, explanation: nil); end
end
class MerchandiseNotAsDescribed < Stripe::RequestParams
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :additional_documentation
# Explanation of why the cardholder is disputing this transaction.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :explanation
# Date when the product was received.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :received_at
# Description of the cardholder's attempt to return the product.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :return_description
# Result of cardholder's attempt to return the product.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :return_status
# Date when the product was returned or attempted to be returned.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :returned_at
sig {
params(additional_documentation: T.nilable(T.nilable(String)), explanation: T.nilable(T.nilable(String)), received_at: T.nilable(T.nilable(T.any(String, Integer))), return_description: T.nilable(T.nilable(String)), return_status: T.nilable(T.nilable(T.any(String, String))), returned_at: T.nilable(T.nilable(T.any(String, Integer)))).void
}
def initialize(
additional_documentation: nil,
explanation: nil,
received_at: nil,
return_description: nil,
return_status: nil,
returned_at: nil
); end
end
class NoValidAuthorization < Stripe::RequestParams
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :additional_documentation
# Explanation of why the cardholder is disputing this transaction.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :explanation
sig {
params(additional_documentation: T.nilable(T.nilable(String)), explanation: T.nilable(T.nilable(String))).void
}
def initialize(additional_documentation: nil, explanation: nil); end
end
class NotReceived < Stripe::RequestParams
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :additional_documentation
# Date when the cardholder expected to receive the product.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :expected_at
# Explanation of why the cardholder is disputing this transaction.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :explanation
# Description of the merchandise or service that was purchased.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :product_description
# Whether the product was a merchandise or service.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :product_type
sig {
params(additional_documentation: T.nilable(T.nilable(String)), expected_at: T.nilable(T.nilable(T.any(String, Integer))), explanation: T.nilable(T.nilable(String)), product_description: T.nilable(T.nilable(String)), product_type: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(
additional_documentation: nil,
expected_at: nil,
explanation: nil,
product_description: nil,
product_type: nil
); end
end
class Other < Stripe::RequestParams
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :additional_documentation
# Explanation of why the cardholder is disputing this transaction.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :explanation
# Description of the merchandise or service that was purchased.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :product_description
# Whether the product was a merchandise or service.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :product_type
sig {
params(additional_documentation: T.nilable(T.nilable(String)), explanation: T.nilable(T.nilable(String)), product_description: T.nilable(T.nilable(String)), product_type: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(
additional_documentation: nil,
explanation: nil,
product_description: nil,
product_type: nil
); end
end
class ServiceNotAsDescribed < Stripe::RequestParams
# (ID of a [file upload](https://stripe.com/docs/guides/file-upload)) Additional documentation supporting the dispute.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :additional_documentation
# Date when order was canceled.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :canceled_at
# Reason for canceling the order.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :cancellation_reason
# Explanation of why the cardholder is disputing this transaction.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :explanation
# Date when the product was received.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :received_at
sig {
params(additional_documentation: T.nilable(T.nilable(String)), canceled_at: T.nilable(T.nilable(T.any(String, Integer))), cancellation_reason: T.nilable(T.nilable(String)), explanation: T.nilable(T.nilable(String)), received_at: T.nilable(T.nilable(T.any(String, Integer)))).void
}
def initialize(
additional_documentation: nil,
canceled_at: nil,
cancellation_reason: nil,
explanation: nil,
received_at: nil
); end
end
# Evidence provided when `reason` is 'canceled'.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::DisputeService::UpdateParams::Evidence::Canceled))))
}
attr_accessor :canceled
# Evidence provided when `reason` is 'duplicate'.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::DisputeService::UpdateParams::Evidence::Duplicate))))
}
attr_accessor :duplicate
# Evidence provided when `reason` is 'fraudulent'.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::DisputeService::UpdateParams::Evidence::Fraudulent))))
}
attr_accessor :fraudulent
# Evidence provided when `reason` is 'merchandise_not_as_described'.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::DisputeService::UpdateParams::Evidence::MerchandiseNotAsDescribed))))
}
attr_accessor :merchandise_not_as_described
# Evidence provided when `reason` is 'no_valid_authorization'.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::DisputeService::UpdateParams::Evidence::NoValidAuthorization))))
}
attr_accessor :no_valid_authorization
# Evidence provided when `reason` is 'not_received'.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::DisputeService::UpdateParams::Evidence::NotReceived))))
}
attr_accessor :not_received
# Evidence provided when `reason` is 'other'.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::DisputeService::UpdateParams::Evidence::Other))))
}
attr_accessor :other
# The reason for filing the dispute. The evidence should be submitted in the field of the same name.
sig { returns(T.nilable(String)) }
attr_accessor :reason
# Evidence provided when `reason` is 'service_not_as_described'.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::DisputeService::UpdateParams::Evidence::ServiceNotAsDescribed))))
}
attr_accessor :service_not_as_described
sig {
params(canceled: T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::DisputeService::UpdateParams::Evidence::Canceled))), duplicate: T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::DisputeService::UpdateParams::Evidence::Duplicate))), fraudulent: T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::DisputeService::UpdateParams::Evidence::Fraudulent))), merchandise_not_as_described: T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::DisputeService::UpdateParams::Evidence::MerchandiseNotAsDescribed))), no_valid_authorization: T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::DisputeService::UpdateParams::Evidence::NoValidAuthorization))), not_received: T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::DisputeService::UpdateParams::Evidence::NotReceived))), other: T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::DisputeService::UpdateParams::Evidence::Other))), reason: T.nilable(String), service_not_as_described: T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::DisputeService::UpdateParams::Evidence::ServiceNotAsDescribed)))).void
}
def initialize(
canceled: nil,
duplicate: nil,
fraudulent: nil,
merchandise_not_as_described: nil,
no_valid_authorization: nil,
not_received: nil,
other: nil,
reason: nil,
service_not_as_described: nil
); end
end
# The dispute amount in the card's currency and in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# Evidence provided for the dispute.
sig { returns(T.nilable(::Stripe::Issuing::DisputeService::UpdateParams::Evidence)) }
attr_accessor :evidence
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
sig {
params(amount: T.nilable(Integer), evidence: T.nilable(::Stripe::Issuing::DisputeService::UpdateParams::Evidence), expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String])))).void
}
def initialize(amount: nil, evidence: nil, expand: nil, metadata: nil); end
end
class SubmitParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
sig {
params(expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String])))).void
}
def initialize(expand: nil, metadata: nil); end
end
# Creates an Issuing Dispute object. Individual pieces of evidence within the evidence object are optional at this point. Stripe only validates that required evidence is present during submission. Refer to [Dispute reasons and evidence](https://docs.stripe.com/docs/issuing/purchases/disputes#dispute-reasons-and-evidence) for more details about evidence requirements.
sig {
params(params: T.any(::Stripe::Issuing::DisputeService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Dispute)
}
def create(params = {}, opts = {}); end
# Returns a list of Issuing Dispute objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.
sig {
params(params: T.any(::Stripe::Issuing::DisputeService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves an Issuing Dispute object.
sig {
params(dispute: String, params: T.any(::Stripe::Issuing::DisputeService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Dispute)
}
def retrieve(dispute, params = {}, opts = {}); end
# Submits an Issuing Dispute to the card network. Stripe validates that all evidence fields required for the dispute's reason are present. For more details, see [Dispute reasons and evidence](https://docs.stripe.com/docs/issuing/purchases/disputes#dispute-reasons-and-evidence).
sig {
params(dispute: String, params: T.any(::Stripe::Issuing::DisputeService::SubmitParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Dispute)
}
def submit(dispute, params = {}, opts = {}); end
# Updates the specified Issuing Dispute object by setting the values of the parameters passed. Any parameters not provided will be left unchanged. Properties on the evidence object can be unset by passing in an empty string.
sig {
params(dispute: String, params: T.any(::Stripe::Issuing::DisputeService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Dispute)
}
def update(dispute, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Issuing
class DisputeSettlementDetailService < StripeService
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Select the Issuing dispute settlement details for the given settlement.
sig { returns(T.nilable(String)) }
attr_accessor :settlement
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), settlement: T.nilable(String), starting_after: T.nilable(String)).void
}
def initialize(
ending_before: nil,
expand: nil,
limit: nil,
settlement: nil,
starting_after: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Returns a list of Issuing DisputeSettlementDetail objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.
sig {
params(params: T.any(::Stripe::Issuing::DisputeSettlementDetailService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves an Issuing DisputeSettlementDetail object.
sig {
params(dispute_settlement_detail: String, params: T.any(::Stripe::Issuing::DisputeSettlementDetailService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::DisputeSettlementDetail)
}
def retrieve(dispute_settlement_detail, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Issuing
class FraudLiabilityDebitService < StripeService
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return Issuing Fraud Liability Debits that were created during the given date interval.
sig {
returns(T.nilable(T.any(::Stripe::Issuing::FraudLiabilityDebitService::ListParams::Created, Integer)))
}
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(created: T.nilable(T.any(::Stripe::Issuing::FraudLiabilityDebitService::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Returns a list of Issuing FraudLiabilityDebit objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.
sig {
params(params: T.any(::Stripe::Issuing::FraudLiabilityDebitService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves an Issuing FraudLiabilityDebit object.
sig {
params(fraud_liability_debit: String, params: T.any(::Stripe::Issuing::FraudLiabilityDebitService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::FraudLiabilityDebit)
}
def retrieve(fraud_liability_debit, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Issuing
class PersonalizationDesignService < StripeService
class ListParams < Stripe::RequestParams
class Preferences < Stripe::RequestParams
# Only return the personalization design that's set as the default. A connected account uses the Connect platform's default design if no personalization design is set as the default.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :is_default
# Only return the personalization design that is set as the Connect platform's default. This parameter is only applicable to connected accounts.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :is_platform_default
sig {
params(is_default: T.nilable(T::Boolean), is_platform_default: T.nilable(T::Boolean)).void
}
def initialize(is_default: nil, is_platform_default: nil); end
end
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Only return personalization designs with the given lookup keys.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :lookup_keys
# Only return personalization designs with the given preferences.
sig {
returns(T.nilable(::Stripe::Issuing::PersonalizationDesignService::ListParams::Preferences))
}
attr_accessor :preferences
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return personalization designs with the given status.
sig { returns(T.nilable(String)) }
attr_accessor :status
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), lookup_keys: T.nilable(T::Array[String]), preferences: T.nilable(::Stripe::Issuing::PersonalizationDesignService::ListParams::Preferences), starting_after: T.nilable(String), status: T.nilable(String)).void
}
def initialize(
ending_before: nil,
expand: nil,
limit: nil,
lookup_keys: nil,
preferences: nil,
starting_after: nil,
status: nil
); end
end
class CreateParams < Stripe::RequestParams
class CarrierText < Stripe::RequestParams
# The footer body text of the carrier letter.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :footer_body
# The footer title text of the carrier letter.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :footer_title
# The header body text of the carrier letter.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :header_body
# The header title text of the carrier letter.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :header_title
sig {
params(footer_body: T.nilable(T.nilable(String)), footer_title: T.nilable(T.nilable(String)), header_body: T.nilable(T.nilable(String)), header_title: T.nilable(T.nilable(String))).void
}
def initialize(
footer_body: nil,
footer_title: nil,
header_body: nil,
header_title: nil
); end
end
class Preferences < Stripe::RequestParams
# Whether we use this personalization design to create cards when one isn't specified. A connected account uses the Connect platform's default design if no personalization design is set as the default design.
sig { returns(T::Boolean) }
attr_accessor :is_default
sig { params(is_default: T::Boolean).void }
def initialize(is_default: nil); end
end
# The file for the card logo, for use with physical bundles that support card logos. Must have a `purpose` value of `issuing_logo`.
sig { returns(T.nilable(String)) }
attr_accessor :card_logo
# Hash containing carrier text, for use with physical bundles that support carrier text.
sig {
returns(T.nilable(::Stripe::Issuing::PersonalizationDesignService::CreateParams::CarrierText))
}
attr_accessor :carrier_text
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A lookup key used to retrieve personalization designs dynamically from a static string. This may be up to 200 characters.
sig { returns(T.nilable(String)) }
attr_accessor :lookup_key
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Friendly display name.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The physical bundle object belonging to this personalization design.
sig { returns(String) }
attr_accessor :physical_bundle
# Information on whether this personalization design is used to create cards when one is not specified.
sig {
returns(T.nilable(::Stripe::Issuing::PersonalizationDesignService::CreateParams::Preferences))
}
attr_accessor :preferences
# If set to true, will atomically remove the lookup key from the existing personalization design, and assign it to this personalization design.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :transfer_lookup_key
sig {
params(card_logo: T.nilable(String), carrier_text: T.nilable(::Stripe::Issuing::PersonalizationDesignService::CreateParams::CarrierText), expand: T.nilable(T::Array[String]), lookup_key: T.nilable(String), metadata: T.nilable(T::Hash[String, String]), name: T.nilable(String), physical_bundle: String, preferences: T.nilable(::Stripe::Issuing::PersonalizationDesignService::CreateParams::Preferences), transfer_lookup_key: T.nilable(T::Boolean)).void
}
def initialize(
card_logo: nil,
carrier_text: nil,
expand: nil,
lookup_key: nil,
metadata: nil,
name: nil,
physical_bundle: nil,
preferences: nil,
transfer_lookup_key: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
class CarrierText < Stripe::RequestParams
# The footer body text of the carrier letter.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :footer_body
# The footer title text of the carrier letter.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :footer_title
# The header body text of the carrier letter.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :header_body
# The header title text of the carrier letter.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :header_title
sig {
params(footer_body: T.nilable(T.nilable(String)), footer_title: T.nilable(T.nilable(String)), header_body: T.nilable(T.nilable(String)), header_title: T.nilable(T.nilable(String))).void
}
def initialize(
footer_body: nil,
footer_title: nil,
header_body: nil,
header_title: nil
); end
end
class Preferences < Stripe::RequestParams
# Whether we use this personalization design to create cards when one isn't specified. A connected account uses the Connect platform's default design if no personalization design is set as the default design.
sig { returns(T::Boolean) }
attr_accessor :is_default
sig { params(is_default: T::Boolean).void }
def initialize(is_default: nil); end
end
# The file for the card logo, for use with physical bundles that support card logos. Must have a `purpose` value of `issuing_logo`.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :card_logo
# Hash containing carrier text, for use with physical bundles that support carrier text.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::PersonalizationDesignService::UpdateParams::CarrierText))))
}
attr_accessor :carrier_text
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A lookup key used to retrieve personalization designs dynamically from a static string. This may be up to 200 characters.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :lookup_key
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Friendly display name. Providing an empty string will set the field to null.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :name
# The physical bundle object belonging to this personalization design.
sig { returns(T.nilable(String)) }
attr_accessor :physical_bundle
# Information on whether this personalization design is used to create cards when one is not specified.
sig {
returns(T.nilable(::Stripe::Issuing::PersonalizationDesignService::UpdateParams::Preferences))
}
attr_accessor :preferences
# If set to true, will atomically remove the lookup key from the existing personalization design, and assign it to this personalization design.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :transfer_lookup_key
sig {
params(card_logo: T.nilable(T.nilable(String)), carrier_text: T.nilable(T.nilable(T.any(String, ::Stripe::Issuing::PersonalizationDesignService::UpdateParams::CarrierText))), expand: T.nilable(T::Array[String]), lookup_key: T.nilable(T.nilable(String)), metadata: T.nilable(T::Hash[String, String]), name: T.nilable(T.nilable(String)), physical_bundle: T.nilable(String), preferences: T.nilable(::Stripe::Issuing::PersonalizationDesignService::UpdateParams::Preferences), transfer_lookup_key: T.nilable(T::Boolean)).void
}
def initialize(
card_logo: nil,
carrier_text: nil,
expand: nil,
lookup_key: nil,
metadata: nil,
name: nil,
physical_bundle: nil,
preferences: nil,
transfer_lookup_key: nil
); end
end
# Creates a personalization design object.
sig {
params(params: T.any(::Stripe::Issuing::PersonalizationDesignService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::PersonalizationDesign)
}
def create(params = {}, opts = {}); end
# Returns a list of personalization design objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.
sig {
params(params: T.any(::Stripe::Issuing::PersonalizationDesignService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves a personalization design object.
sig {
params(personalization_design: String, params: T.any(::Stripe::Issuing::PersonalizationDesignService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::PersonalizationDesign)
}
def retrieve(personalization_design, params = {}, opts = {}); end
# Updates a card personalization object.
sig {
params(personalization_design: String, params: T.any(::Stripe::Issuing::PersonalizationDesignService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::PersonalizationDesign)
}
def update(personalization_design, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Issuing
class PhysicalBundleService < StripeService
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return physical bundles with the given status.
sig { returns(T.nilable(String)) }
attr_accessor :status
# Only return physical bundles with the given type.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String), status: T.nilable(String), type: T.nilable(String)).void
}
def initialize(
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil,
status: nil,
type: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Returns a list of physical bundle objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.
sig {
params(params: T.any(::Stripe::Issuing::PhysicalBundleService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves a physical bundle object.
sig {
params(physical_bundle: String, params: T.any(::Stripe::Issuing::PhysicalBundleService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::PhysicalBundle)
}
def retrieve(physical_bundle, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Issuing
class TokenService < StripeService
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# The Issuing card identifier to list tokens for.
sig { returns(String) }
attr_accessor :card
# Only return Issuing tokens that were created during the given date interval.
sig {
returns(T.nilable(T.any(::Stripe::Issuing::TokenService::ListParams::Created, Integer)))
}
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Select Issuing tokens with the given status.
sig { returns(T.nilable(String)) }
attr_accessor :status
sig {
params(card: String, created: T.nilable(T.any(::Stripe::Issuing::TokenService::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String), status: T.nilable(String)).void
}
def initialize(
card: nil,
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil,
status: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Specifies which status the token should be updated to.
sig { returns(String) }
attr_accessor :status
sig { params(expand: T.nilable(T::Array[String]), status: String).void }
def initialize(expand: nil, status: nil); end
end
# Lists all Issuing Token objects for a given card.
sig {
params(params: T.any(::Stripe::Issuing::TokenService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves an Issuing Token object.
sig {
params(token: String, params: T.any(::Stripe::Issuing::TokenService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Token)
}
def retrieve(token, params = {}, opts = {}); end
# Attempts to update the specified Issuing Token object to the status specified.
sig {
params(token: String, params: T.any(::Stripe::Issuing::TokenService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Token)
}
def update(token, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Issuing
class TransactionService < StripeService
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return transactions that belong to the given card.
sig { returns(T.nilable(String)) }
attr_accessor :card
# Only return transactions that belong to the given cardholder.
sig { returns(T.nilable(String)) }
attr_accessor :cardholder
# Only return transactions that were created during the given date interval.
sig {
returns(T.nilable(T.any(::Stripe::Issuing::TransactionService::ListParams::Created, Integer)))
}
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Only return transactions that are associated with the given settlement.
sig { returns(T.nilable(String)) }
attr_accessor :settlement
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return transactions that have the given type. One of `capture` or `refund`.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(card: T.nilable(String), cardholder: T.nilable(String), created: T.nilable(T.any(::Stripe::Issuing::TransactionService::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), settlement: T.nilable(String), starting_after: T.nilable(String), type: T.nilable(String)).void
}
def initialize(
card: nil,
cardholder: nil,
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
settlement: nil,
starting_after: nil,
type: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
sig {
params(expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String])))).void
}
def initialize(expand: nil, metadata: nil); end
end
# Returns a list of Issuing Transaction objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.
sig {
params(params: T.any(::Stripe::Issuing::TransactionService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves an Issuing Transaction object.
sig {
params(transaction: String, params: T.any(::Stripe::Issuing::TransactionService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Transaction)
}
def retrieve(transaction, params = {}, opts = {}); end
# Updates the specified Issuing Transaction object by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
sig {
params(transaction: String, params: T.any(::Stripe::Issuing::TransactionService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Issuing::Transaction)
}
def update(transaction, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
class MandateService < StripeService
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Retrieves a Mandate object.
sig {
params(mandate: String, params: T.any(::Stripe::MandateService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Mandate)
}
def retrieve(mandate, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class MarginService < StripeService
class ListParams < Stripe::RequestParams
# Only return margins that are active or inactive. For example, pass `true` to only list active margins.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(active: T.nilable(T::Boolean), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
active: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
# Whether the margin can be applied to invoices, invoice items, or invoice line items or not. Defaults to `true`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Name of the margin, which is displayed to customers, such as on invoices.
sig { returns(T.nilable(String)) }
attr_accessor :name
# Percent that will be taken off the subtotal before tax (after all other discounts and promotions) of any invoice to which the margin is applied.
sig { returns(Float) }
attr_accessor :percent_off
sig {
params(active: T.nilable(T::Boolean), expand: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), name: T.nilable(String), percent_off: Float).void
}
def initialize(active: nil, expand: nil, metadata: nil, name: nil, percent_off: nil); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
# Whether the margin can be applied to invoices, invoice items, or invoice line items or not.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Name of the margin, which is displayed to customers, such as on invoices.
sig { returns(T.nilable(String)) }
attr_accessor :name
sig {
params(active: T.nilable(T::Boolean), expand: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), name: T.nilable(String)).void
}
def initialize(active: nil, expand: nil, metadata: nil, name: nil); end
end
# Create a margin object to be used with invoices, invoice items, and invoice line items for a customer to represent a partner discount. A margin has a percent_off which is the percent that will be taken off the subtotal after all items and other discounts and promotions) of any invoices for a customer. Calculation of prorations do not include any partner margins applied on the original invoice item.
sig {
params(params: T.any(::Stripe::MarginService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Margin)
}
def create(params = {}, opts = {}); end
# Retrieve a list of your margins.
sig {
params(params: T.any(::Stripe::MarginService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieve a margin object with the given ID.
sig {
params(margin: String, params: T.any(::Stripe::MarginService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Margin)
}
def retrieve(margin, params = {}, opts = {}); end
# Update the specified margin object. Certain fields of the margin object are not editable.
sig {
params(margin: String, params: T.any(::Stripe::MarginService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Margin)
}
def update(margin, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class OrderService < StripeService
attr_reader :line_items
class ListParams < Stripe::RequestParams
# Only return orders for the given customer.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(customer: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
customer: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class AutomaticTax < Stripe::RequestParams
# Enable automatic tax calculation which will automatically compute tax rates on this order.
sig { returns(T::Boolean) }
attr_accessor :enabled
sig { params(enabled: T::Boolean).void }
def initialize(enabled: nil); end
end
class BillingDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State/province as an [ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2) subdivision code, without country prefix. Example: "NY" or "TX".
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# The billing address provided by the customer.
sig { returns(T.nilable(::Stripe::OrderService::CreateParams::BillingDetails::Address)) }
attr_accessor :address
# The billing email provided by the customer.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The billing name provided by the customer.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The billing phone number provided by the customer.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(address: T.nilable(::Stripe::OrderService::CreateParams::BillingDetails::Address), email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(address: nil, email: nil, name: nil, phone: nil); end
end
class Discount < Stripe::RequestParams
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, promotion_code: nil); end
end
class LineItem < Stripe::RequestParams
class Discount < Stripe::RequestParams
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
sig { params(coupon: T.nilable(String), discount: T.nilable(String)).void }
def initialize(coupon: nil, discount: nil); end
end
class PriceData < Stripe::RequestParams
# 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).
sig { returns(T.nilable(String)) }
attr_accessor :currency
# ID of the [Product](https://docs.stripe.com/api/products) this [Price](https://docs.stripe.com/api/prices) belongs to.
#
# Use this to implement a variable-pricing model in your integration. This is required if `product_data` is not specified.
sig { returns(T.nilable(String)) }
attr_accessor :product
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: T.nilable(String), product: T.nilable(String), tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
class ProductData < Stripe::RequestParams
class PackageDimensions < Stripe::RequestParams
# Height, in inches. Maximum precision is 2 decimal places.
sig { returns(Float) }
attr_accessor :height
# Length, in inches. Maximum precision is 2 decimal places.
sig { returns(Float) }
attr_accessor :length
# Weight, in ounces. Maximum precision is 2 decimal places.
sig { returns(Float) }
attr_accessor :weight
# Width, in inches. Maximum precision is 2 decimal places.
sig { returns(Float) }
attr_accessor :width
sig { params(height: Float, length: Float, weight: Float, width: Float).void }
def initialize(height: nil, length: nil, weight: nil, width: nil); end
end
# The product's description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :description
# A unique identifier for this product.
#
# `product_data` automatically creates a Product with this ID. If a Product with the same ID already exists, then `product_data` re-uses it to avoid duplicates. If any of the fields in the existing Product are different from the values in `product_data`, `product_data` updates the existing Product with the new information. So set `product_data[id]` to the same string every time you sell the same product, but don't re-use the same string for different products.
sig { returns(String) }
attr_accessor :id
# A list of up to 8 URLs of images for this product, meant to be displayable to the customer.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :images
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# The product's name, meant to be displayable to the customer.
sig { returns(String) }
attr_accessor :name
# The dimensions of this product for shipping purposes.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::CreateParams::LineItem::ProductData::PackageDimensions))))
}
attr_accessor :package_dimensions
# Whether this product is shipped (i.e., physical goods).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :shippable
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :tax_code
# A URL of a publicly-accessible webpage for this product.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :url
sig {
params(description: T.nilable(T.nilable(String)), id: String, images: T.nilable(T.nilable(T.any(String, T::Array[String]))), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), name: String, package_dimensions: T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::CreateParams::LineItem::ProductData::PackageDimensions))), shippable: T.nilable(T::Boolean), tax_code: T.nilable(T.nilable(String)), url: T.nilable(T.nilable(String))).void
}
def initialize(
description: nil,
id: nil,
images: nil,
metadata: nil,
name: nil,
package_dimensions: nil,
shippable: nil,
tax_code: nil,
url: nil
); end
end
# The description for the line item. Will default to the name of the associated product.
sig { returns(T.nilable(String)) }
attr_accessor :description
# The discounts applied to this line item.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::OrderService::CreateParams::LineItem::Discount]))))
}
attr_accessor :discounts
# The ID of a [Price](https://docs.stripe.com/api/prices) to add to the Order.
#
# The `price` parameter is an alternative to using the `product` parameter. If each of your products are sold at a single price, you can set `Product.default_price` and then pass the `product` parameter when creating a line item. If your products are sold at several possible prices, use the `price` parameter to explicitly specify which one to use.
sig { returns(T.nilable(String)) }
attr_accessor :price
# Data used to generate a new Price object inline.
#
# The `price_data` parameter is an alternative to using the `product` or `price` parameters. If you create a Product upfront and configure a `Product.default_price`, pass the `product` parameter when creating a line item. If you prefer not to define Products upfront, or if you charge variable prices, pass the `price_data` parameter to describe the price for this line item.
#
# Each time you pass `price_data` we create a Price for the Product. This Price is hidden in both the Dashboard and API lists and cannot be reused.
sig { returns(T.nilable(::Stripe::OrderService::CreateParams::LineItem::PriceData)) }
attr_accessor :price_data
# The ID of a [Product](https://docs.stripe.com/api/products) to add to the Order.
#
# The Product must have a `default_price` specified. Otherwise, specify the price by passing the `price` or `price_data` parameter.
sig { returns(T.nilable(String)) }
attr_accessor :product
# Defines a [Product](https://docs.stripe.com/api/products) inline and adds it to the Order.
#
# `product_data` is an alternative to the `product` parameter. If you created a Product upfront, use the `product` parameter to refer to the existing Product. But if you prefer not to create Products upfront, pass the `product_data` parameter to define a Product inline as part of configuring the Order.
#
# `product_data` automatically creates a Product, just as if you had manually created the Product. If a Product with the same ID already exists, then `product_data` re-uses it to avoid duplicates.
sig { returns(T.nilable(::Stripe::OrderService::CreateParams::LineItem::ProductData)) }
attr_accessor :product_data
# The quantity of the line item.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# The tax rates applied to this line item.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
sig {
params(description: T.nilable(String), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::OrderService::CreateParams::LineItem::Discount]))), price: T.nilable(String), price_data: T.nilable(::Stripe::OrderService::CreateParams::LineItem::PriceData), product: T.nilable(String), product_data: T.nilable(::Stripe::OrderService::CreateParams::LineItem::ProductData), quantity: T.nilable(Integer), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String])))).void
}
def initialize(
description: nil,
discounts: nil,
price: nil,
price_data: nil,
product: nil,
product_data: nil,
quantity: nil,
tax_rates: nil
); end
end
class Payment < Stripe::RequestParams
class Settings < Stripe::RequestParams
class PaymentMethodOptions < Stripe::RequestParams
class AcssDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# A URL for custom mandate text to render during confirmation step.
# The URL will be rendered with additional GET parameters `payment_intent` and `payment_intent_client_secret` when confirming a Payment Intent,
# or `setup_intent` and `setup_intent_client_secret` when confirming a Setup Intent.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :custom_mandate_url
# Description of the mandate interval. Only required if 'payment_schedule' parameter is 'interval' or 'combined'.
sig { returns(T.nilable(String)) }
attr_accessor :interval_description
# Payment schedule for the mandate.
sig { returns(T.nilable(String)) }
attr_accessor :payment_schedule
# Transaction type of the mandate.
sig { returns(T.nilable(String)) }
attr_accessor :transaction_type
sig {
params(custom_mandate_url: T.nilable(T.nilable(String)), interval_description: T.nilable(String), payment_schedule: T.nilable(String), transaction_type: T.nilable(String)).void
}
def initialize(
custom_mandate_url: nil,
interval_description: nil,
payment_schedule: nil,
transaction_type: nil
); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::OrderService::CreateParams::Payment::Settings::PaymentMethodOptions::AcssDebit::MandateOptions))
}
attr_accessor :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
# Bank account verification method.
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(mandate_options: T.nilable(::Stripe::OrderService::CreateParams::Payment::Settings::PaymentMethodOptions::AcssDebit::MandateOptions), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), target_date: T.nilable(String), verification_method: T.nilable(String)).void
}
def initialize(
mandate_options: nil,
setup_future_usage: nil,
target_date: nil,
verification_method: nil
); end
end
class AfterpayClearpay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(String)) }
attr_accessor :capture_method
# An internal identifier or reference this payment corresponds to. The identifier is limited to 128 characters and may contain only letters, digits, underscores, backslashes and dashes.
sig { returns(T.nilable(String)) }
attr_accessor :reference
# Indicates that you intend to make future payments with the payment method.
#
# Providing this parameter will [attach the payment method](https://stripe.com/docs/payments/save-during-payment) to the order's Customer, if present, after the order's PaymentIntent is confirmed and any required actions from the user are complete. If no Customer was provided, the payment method can still be [attached](https://stripe.com/docs/api/payment_methods/attach) to a Customer after the transaction completes.
#
# When processing card payments, Stripe also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as [SCA](https://stripe.com/docs/strong-customer-authentication).
#
# If `setup_future_usage` is already set and you are performing a request using a publishable key, you may only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(String), reference: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(capture_method: nil, reference: nil, setup_future_usage: nil); end
end
class Alipay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void }
def initialize(setup_future_usage: nil); end
end
class Bancontact < Stripe::RequestParams
# Preferred language of the Bancontact authorization page that the customer is redirected to.
sig { returns(T.nilable(String)) }
attr_accessor :preferred_language
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(preferred_language: T.nilable(String), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(preferred_language: nil, setup_future_usage: nil); end
end
class Card < Stripe::RequestParams
# Controls when the funds will be captured from the customer's account.
sig { returns(T.nilable(String)) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with the payment method.
#
# Providing this parameter will [attach the payment method](https://stripe.com/docs/payments/save-during-payment) to the order's Customer, if present, after the order's PaymentIntent is confirmed and any required actions from the user are complete. If no Customer was provided, the payment method can still be [attached](https://stripe.com/docs/api/payment_methods/attach) to a Customer after the transaction completes.
#
# When processing card payments, Stripe also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as [SCA](https://stripe.com/docs/strong-customer-authentication).
#
# If `setup_future_usage` is already set and you are performing a request using a publishable key, you may only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class CustomerBalance < Stripe::RequestParams
class BankTransfer < Stripe::RequestParams
class EuBankTransfer < Stripe::RequestParams
# The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
sig { returns(String) }
attr_accessor :country
sig { params(country: String).void }
def initialize(country: nil); end
end
# Configuration for the eu_bank_transfer funding type.
sig {
returns(T.nilable(::Stripe::OrderService::CreateParams::Payment::Settings::PaymentMethodOptions::CustomerBalance::BankTransfer::EuBankTransfer))
}
attr_accessor :eu_bank_transfer
# List of address types that should be returned in the financial_addresses response. If not specified, all valid types will be returned.
#
# Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :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`, `mx_bank_transfer`, or `us_bank_transfer`.
sig { returns(String) }
attr_accessor :type
sig {
params(eu_bank_transfer: T.nilable(::Stripe::OrderService::CreateParams::Payment::Settings::PaymentMethodOptions::CustomerBalance::BankTransfer::EuBankTransfer), requested_address_types: T.nilable(T::Array[String]), type: String).void
}
def initialize(eu_bank_transfer: nil, requested_address_types: nil, type: nil); end
end
# Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
sig {
returns(T.nilable(::Stripe::OrderService::CreateParams::Payment::Settings::PaymentMethodOptions::CustomerBalance::BankTransfer))
}
attr_accessor :bank_transfer
# The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
sig { returns(T.nilable(String)) }
attr_accessor :funding_type
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(bank_transfer: T.nilable(::Stripe::OrderService::CreateParams::Payment::Settings::PaymentMethodOptions::CustomerBalance::BankTransfer), funding_type: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(bank_transfer: nil, funding_type: nil, setup_future_usage: nil); end
end
class Ideal < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void }
def initialize(setup_future_usage: nil); end
end
class Klarna < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Preferred language of the Klarna authorization page that the customer is redirected to
sig { returns(T.nilable(String)) }
attr_accessor :preferred_locale
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), preferred_locale: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(
capture_method: nil,
preferred_locale: nil,
setup_future_usage: nil
); end
end
class Link < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# [Deprecated] This is a legacy parameter that no longer has any function.
sig { returns(T.nilable(String)) }
attr_accessor :persistent_token
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), persistent_token: T.nilable(String), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(
capture_method: nil,
persistent_token: nil,
setup_future_usage: nil
); end
end
class Oxxo < Stripe::RequestParams
# The number of calendar days before an OXXO voucher expires. For example, if you create an OXXO voucher on Monday and you set expires_after_days to 2, the OXXO invoice will expire on Wednesday at 23:59 America/Mexico_City time.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_after_days
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(expires_after_days: T.nilable(Integer), setup_future_usage: T.nilable(String)).void
}
def initialize(expires_after_days: nil, setup_future_usage: nil); end
end
class P24 < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
# Confirm that the payer has accepted the P24 terms and conditions.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :tos_shown_and_accepted
sig {
params(setup_future_usage: T.nilable(String), tos_shown_and_accepted: T.nilable(T::Boolean)).void
}
def initialize(setup_future_usage: nil, tos_shown_and_accepted: nil); end
end
class Paypal < Stripe::RequestParams
class LineItem < Stripe::RequestParams
class Tax < Stripe::RequestParams
# The tax for a single unit of the line item in minor units. Cannot be a negative number.
sig { returns(Integer) }
attr_accessor :amount
# The tax behavior for the line item.
sig { returns(String) }
attr_accessor :behavior
sig { params(amount: Integer, behavior: String).void }
def initialize(amount: nil, behavior: nil); end
end
# Type of the line item.
sig { returns(T.nilable(String)) }
attr_accessor :category
# Description of the line item.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Descriptive name of the line item.
sig { returns(String) }
attr_accessor :name
# Quantity of the line item. Must be a positive number.
sig { returns(Integer) }
attr_accessor :quantity
# Client facing stock keeping unit, article number or similar.
sig { returns(T.nilable(String)) }
attr_accessor :sku
# The Stripe account ID of the connected account that sells the item.
sig { returns(T.nilable(String)) }
attr_accessor :sold_by
# The tax information for the line item.
sig {
returns(T.nilable(::Stripe::OrderService::CreateParams::Payment::Settings::PaymentMethodOptions::Paypal::LineItem::Tax))
}
attr_accessor :tax
# Price for a single unit of the line item in minor units. Cannot be a negative number.
sig { returns(Integer) }
attr_accessor :unit_amount
sig {
params(category: T.nilable(String), description: T.nilable(String), name: String, quantity: Integer, sku: T.nilable(String), sold_by: T.nilable(String), tax: T.nilable(::Stripe::OrderService::CreateParams::Payment::Settings::PaymentMethodOptions::Paypal::LineItem::Tax), unit_amount: Integer).void
}
def initialize(
category: nil,
description: nil,
name: nil,
quantity: nil,
sku: nil,
sold_by: nil,
tax: nil,
unit_amount: nil
); end
end
# Controls when the funds will be captured from the customer's account.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# The line items purchased by the customer.
sig {
returns(T.nilable(T::Array[::Stripe::OrderService::CreateParams::Payment::Settings::PaymentMethodOptions::Paypal::LineItem]))
}
attr_accessor :line_items
# [Preferred locale](https://stripe.com/docs/payments/paypal/supported-locales) of the PayPal checkout page that the customer is redirected to.
sig { returns(T.nilable(String)) }
attr_accessor :preferred_locale
# A reference of the PayPal transaction visible to customer which is mapped to PayPal's invoice ID. This must be a globally unique ID if you have configured in your PayPal settings to block multiple payments per invoice ID.
sig { returns(T.nilable(String)) }
attr_accessor :reference
# A reference of the PayPal transaction visible to customer which is mapped to PayPal's invoice ID. This must be a globally unique ID if you have configured in your PayPal settings to block multiple payments per invoice ID.
sig { returns(T.nilable(String)) }
attr_accessor :reference_id
# The risk correlation ID for an on-session payment using a saved PayPal payment method.
sig { returns(T.nilable(String)) }
attr_accessor :risk_correlation_id
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# The Stripe connected account IDs of the sellers on the platform for this transaction (optional). Only allowed when [separate charges and transfers](https://stripe.com/docs/connect/separate-charges-and-transfers) are used.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :subsellers
sig {
params(capture_method: T.nilable(T.nilable(String)), line_items: T.nilable(T::Array[::Stripe::OrderService::CreateParams::Payment::Settings::PaymentMethodOptions::Paypal::LineItem]), preferred_locale: T.nilable(String), reference: T.nilable(String), reference_id: T.nilable(String), risk_correlation_id: T.nilable(String), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), subsellers: T.nilable(T::Array[String])).void
}
def initialize(
capture_method: nil,
line_items: nil,
preferred_locale: nil,
reference: nil,
reference_id: nil,
risk_correlation_id: nil,
setup_future_usage: nil,
subsellers: nil
); end
end
class SepaDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'STRIPE'.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :reference_prefix
sig { params(reference_prefix: T.nilable(T.nilable(String))).void }
def initialize(reference_prefix: nil); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::OrderService::CreateParams::Payment::Settings::PaymentMethodOptions::SepaDebit::MandateOptions))
}
attr_accessor :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
sig {
params(mandate_options: T.nilable(::Stripe::OrderService::CreateParams::Payment::Settings::PaymentMethodOptions::SepaDebit::MandateOptions), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), target_date: T.nilable(String)).void
}
def initialize(mandate_options: nil, setup_future_usage: nil, target_date: nil); end
end
class Sofort < Stripe::RequestParams
# Language shown to the payer on redirect.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :preferred_language
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(preferred_language: T.nilable(T.nilable(T.any(String, String))), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(preferred_language: nil, setup_future_usage: nil); end
end
class WechatPay < Stripe::RequestParams
# The app ID registered with WeChat Pay. Only required when client is ios or android.
sig { returns(T.nilable(String)) }
attr_accessor :app_id
# The client type that the end customer will pay from
sig { returns(T.nilable(String)) }
attr_accessor :client
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(app_id: T.nilable(String), client: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(app_id: nil, client: nil, setup_future_usage: nil); end
end
# If paying by `acss_debit`, this sub-hash contains details about the ACSS Debit payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(::Stripe::OrderService::CreateParams::Payment::Settings::PaymentMethodOptions::AcssDebit))
}
attr_accessor :acss_debit
# If paying by `afterpay_clearpay`, this sub-hash contains details about the AfterpayClearpay payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(::Stripe::OrderService::CreateParams::Payment::Settings::PaymentMethodOptions::AfterpayClearpay))
}
attr_accessor :afterpay_clearpay
# If paying by `alipay`, this sub-hash contains details about the Alipay payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(::Stripe::OrderService::CreateParams::Payment::Settings::PaymentMethodOptions::Alipay))
}
attr_accessor :alipay
# If paying by `bancontact`, this sub-hash contains details about the Bancontact payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(::Stripe::OrderService::CreateParams::Payment::Settings::PaymentMethodOptions::Bancontact))
}
attr_accessor :bancontact
# If paying by `card`, this sub-hash contains details about the Card payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(::Stripe::OrderService::CreateParams::Payment::Settings::PaymentMethodOptions::Card))
}
attr_accessor :card
# If paying by `customer_balance`, this sub-hash contains details about the Customer Balance payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(::Stripe::OrderService::CreateParams::Payment::Settings::PaymentMethodOptions::CustomerBalance))
}
attr_accessor :customer_balance
# If paying by `ideal`, this sub-hash contains details about the iDEAL payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(::Stripe::OrderService::CreateParams::Payment::Settings::PaymentMethodOptions::Ideal))
}
attr_accessor :ideal
# If paying by `klarna`, this sub-hash contains details about the Klarna payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(::Stripe::OrderService::CreateParams::Payment::Settings::PaymentMethodOptions::Klarna))
}
attr_accessor :klarna
# If paying by `link`, this sub-hash contains details about the Link payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(::Stripe::OrderService::CreateParams::Payment::Settings::PaymentMethodOptions::Link))
}
attr_accessor :link
# If paying by `oxxo`, this sub-hash contains details about the OXXO payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(::Stripe::OrderService::CreateParams::Payment::Settings::PaymentMethodOptions::Oxxo))
}
attr_accessor :oxxo
# If paying by `p24`, this sub-hash contains details about the P24 payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(::Stripe::OrderService::CreateParams::Payment::Settings::PaymentMethodOptions::P24))
}
attr_accessor :p24
# If paying by `paypal`, this sub-hash contains details about the PayPal payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(::Stripe::OrderService::CreateParams::Payment::Settings::PaymentMethodOptions::Paypal))
}
attr_accessor :paypal
# If paying by `sepa_debit`, this sub-hash contains details about the SEPA Debit payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(::Stripe::OrderService::CreateParams::Payment::Settings::PaymentMethodOptions::SepaDebit))
}
attr_accessor :sepa_debit
# If paying by `sofort`, this sub-hash contains details about the Sofort payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(::Stripe::OrderService::CreateParams::Payment::Settings::PaymentMethodOptions::Sofort))
}
attr_accessor :sofort
# If paying by `wechat_pay`, this sub-hash contains details about the WeChat Pay payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(::Stripe::OrderService::CreateParams::Payment::Settings::PaymentMethodOptions::WechatPay))
}
attr_accessor :wechat_pay
sig {
params(acss_debit: T.nilable(::Stripe::OrderService::CreateParams::Payment::Settings::PaymentMethodOptions::AcssDebit), afterpay_clearpay: T.nilable(::Stripe::OrderService::CreateParams::Payment::Settings::PaymentMethodOptions::AfterpayClearpay), alipay: T.nilable(::Stripe::OrderService::CreateParams::Payment::Settings::PaymentMethodOptions::Alipay), bancontact: T.nilable(::Stripe::OrderService::CreateParams::Payment::Settings::PaymentMethodOptions::Bancontact), card: T.nilable(::Stripe::OrderService::CreateParams::Payment::Settings::PaymentMethodOptions::Card), customer_balance: T.nilable(::Stripe::OrderService::CreateParams::Payment::Settings::PaymentMethodOptions::CustomerBalance), ideal: T.nilable(::Stripe::OrderService::CreateParams::Payment::Settings::PaymentMethodOptions::Ideal), klarna: T.nilable(::Stripe::OrderService::CreateParams::Payment::Settings::PaymentMethodOptions::Klarna), link: T.nilable(::Stripe::OrderService::CreateParams::Payment::Settings::PaymentMethodOptions::Link), oxxo: T.nilable(::Stripe::OrderService::CreateParams::Payment::Settings::PaymentMethodOptions::Oxxo), p24: T.nilable(::Stripe::OrderService::CreateParams::Payment::Settings::PaymentMethodOptions::P24), paypal: T.nilable(::Stripe::OrderService::CreateParams::Payment::Settings::PaymentMethodOptions::Paypal), sepa_debit: T.nilable(::Stripe::OrderService::CreateParams::Payment::Settings::PaymentMethodOptions::SepaDebit), sofort: T.nilable(::Stripe::OrderService::CreateParams::Payment::Settings::PaymentMethodOptions::Sofort), wechat_pay: T.nilable(::Stripe::OrderService::CreateParams::Payment::Settings::PaymentMethodOptions::WechatPay)).void
}
def initialize(
acss_debit: nil,
afterpay_clearpay: nil,
alipay: nil,
bancontact: nil,
card: nil,
customer_balance: nil,
ideal: nil,
klarna: nil,
link: nil,
oxxo: nil,
p24: nil,
paypal: nil,
sepa_debit: nil,
sofort: nil,
wechat_pay: nil
); end
end
class TransferData < Stripe::RequestParams
# The amount that will be transferred automatically when the order is paid. If no amount is set, the full amount is transferred. There cannot be any line items with recurring prices when using this field.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# ID of the Connected account receiving the transfer.
sig { returns(String) }
attr_accessor :destination
sig { params(amount: T.nilable(Integer), destination: String).void }
def initialize(amount: nil, destination: nil); end
end
# The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account.
sig { returns(T.nilable(Integer)) }
attr_accessor :application_fee_amount
# PaymentMethod-specific configuration to provide to the order's PaymentIntent.
sig {
returns(T.nilable(::Stripe::OrderService::CreateParams::Payment::Settings::PaymentMethodOptions))
}
attr_accessor :payment_method_options
# The list of [payment method types](https://stripe.com/docs/payments/payment-methods/overview) to provide to the order's PaymentIntent. Do not include this attribute if you prefer to manage your payment methods from the [Stripe Dashboard](https://dashboard.stripe.com/settings/payment_methods).
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :payment_method_types
# The URL to redirect the customer to after they authenticate their payment.
sig { returns(T.nilable(String)) }
attr_accessor :return_url
# For non-card charges, you can use this value as the complete description that appears on your customers' statements. Must contain at least one letter, maximum 22 characters.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
# Provides information about a card payment that customers see on their statements. Concatenated with the prefix (shortened descriptor) or statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 22 characters for the concatenated descriptor.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor_suffix
# Provides configuration for completing a transfer for the order after it is paid.
sig {
returns(T.nilable(::Stripe::OrderService::CreateParams::Payment::Settings::TransferData))
}
attr_accessor :transfer_data
sig {
params(application_fee_amount: T.nilable(Integer), payment_method_options: T.nilable(::Stripe::OrderService::CreateParams::Payment::Settings::PaymentMethodOptions), payment_method_types: T.nilable(T::Array[String]), return_url: T.nilable(String), statement_descriptor: T.nilable(String), statement_descriptor_suffix: T.nilable(String), transfer_data: T.nilable(::Stripe::OrderService::CreateParams::Payment::Settings::TransferData)).void
}
def initialize(
application_fee_amount: nil,
payment_method_options: nil,
payment_method_types: nil,
return_url: nil,
statement_descriptor: nil,
statement_descriptor_suffix: nil,
transfer_data: nil
); end
end
# Settings describing how the order should configure generated PaymentIntents.
sig { returns(::Stripe::OrderService::CreateParams::Payment::Settings) }
attr_accessor :settings
sig { params(settings: ::Stripe::OrderService::CreateParams::Payment::Settings).void }
def initialize(settings: nil); end
end
class ShippingCost < Stripe::RequestParams
class ShippingRateData < Stripe::RequestParams
class DeliveryEstimate < Stripe::RequestParams
class Maximum < Stripe::RequestParams
# A unit of time.
sig { returns(String) }
attr_accessor :unit
# Must be greater than 0.
sig { returns(Integer) }
attr_accessor :value
sig { params(unit: String, value: Integer).void }
def initialize(unit: nil, value: nil); end
end
class Minimum < Stripe::RequestParams
# A unit of time.
sig { returns(String) }
attr_accessor :unit
# Must be greater than 0.
sig { returns(Integer) }
attr_accessor :value
sig { params(unit: String, value: Integer).void }
def initialize(unit: nil, value: nil); end
end
# The upper bound of the estimated range. If empty, represents no upper bound i.e., infinite.
sig {
returns(T.nilable(::Stripe::OrderService::CreateParams::ShippingCost::ShippingRateData::DeliveryEstimate::Maximum))
}
attr_accessor :maximum
# The lower bound of the estimated range. If empty, represents no lower bound.
sig {
returns(T.nilable(::Stripe::OrderService::CreateParams::ShippingCost::ShippingRateData::DeliveryEstimate::Minimum))
}
attr_accessor :minimum
sig {
params(maximum: T.nilable(::Stripe::OrderService::CreateParams::ShippingCost::ShippingRateData::DeliveryEstimate::Maximum), minimum: T.nilable(::Stripe::OrderService::CreateParams::ShippingCost::ShippingRateData::DeliveryEstimate::Minimum)).void
}
def initialize(maximum: nil, minimum: nil); end
end
class FixedAmount < Stripe::RequestParams
class CurrencyOptions < Stripe::RequestParams
# A non-negative integer in cents representing how much to charge.
sig { returns(Integer) }
attr_accessor :amount
# Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
sig { params(amount: Integer, tax_behavior: T.nilable(String)).void }
def initialize(amount: nil, tax_behavior: nil); end
end
# A non-negative integer in cents representing how much to charge.
sig { returns(Integer) }
attr_accessor :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).
sig { returns(String) }
attr_accessor :currency
# Shipping rates defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
sig {
returns(T.nilable(T::Hash[String, ::Stripe::OrderService::CreateParams::ShippingCost::ShippingRateData::FixedAmount::CurrencyOptions]))
}
attr_accessor :currency_options
sig {
params(amount: Integer, currency: String, currency_options: T.nilable(T::Hash[String, ::Stripe::OrderService::CreateParams::ShippingCost::ShippingRateData::FixedAmount::CurrencyOptions])).void
}
def initialize(amount: nil, currency: nil, currency_options: nil); end
end
# The estimated range for how long shipping will take, meant to be displayable to the customer. This will appear on CheckoutSessions.
sig {
returns(T.nilable(::Stripe::OrderService::CreateParams::ShippingCost::ShippingRateData::DeliveryEstimate))
}
attr_accessor :delivery_estimate
# The name of the shipping rate, meant to be displayable to the customer. This will appear on CheckoutSessions.
sig { returns(String) }
attr_accessor :display_name
# Describes a fixed amount to charge for shipping. Must be present if type is `fixed_amount`.
sig {
returns(T.nilable(::Stripe::OrderService::CreateParams::ShippingCost::ShippingRateData::FixedAmount))
}
attr_accessor :fixed_amount
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID. The Shipping tax code is `txcd_92010001`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_code
# The type of calculation to use on the shipping rate.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(delivery_estimate: T.nilable(::Stripe::OrderService::CreateParams::ShippingCost::ShippingRateData::DeliveryEstimate), display_name: String, fixed_amount: T.nilable(::Stripe::OrderService::CreateParams::ShippingCost::ShippingRateData::FixedAmount), metadata: T.nilable(T::Hash[String, String]), tax_behavior: T.nilable(String), tax_code: T.nilable(String), type: T.nilable(String)).void
}
def initialize(
delivery_estimate: nil,
display_name: nil,
fixed_amount: nil,
metadata: nil,
tax_behavior: nil,
tax_code: nil,
type: nil
); end
end
# The ID of the shipping rate to use for this order.
sig { returns(T.nilable(String)) }
attr_accessor :shipping_rate
# Parameters to create a new ad-hoc shipping rate for this order.
sig {
returns(T.nilable(::Stripe::OrderService::CreateParams::ShippingCost::ShippingRateData))
}
attr_accessor :shipping_rate_data
sig {
params(shipping_rate: T.nilable(String), shipping_rate_data: T.nilable(::Stripe::OrderService::CreateParams::ShippingCost::ShippingRateData)).void
}
def initialize(shipping_rate: nil, shipping_rate_data: nil); end
end
class ShippingDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State/province as an [ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2) subdivision code, without country prefix. Example: "NY" or "TX".
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# The shipping address for the order.
sig { returns(::Stripe::OrderService::CreateParams::ShippingDetails::Address) }
attr_accessor :address
# The name of the recipient of the order.
sig { returns(String) }
attr_accessor :name
# The phone number (including extension) for the recipient of the order.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :phone
sig {
params(address: ::Stripe::OrderService::CreateParams::ShippingDetails::Address, name: String, phone: T.nilable(T.nilable(String))).void
}
def initialize(address: nil, name: nil, phone: nil); end
end
class TaxDetails < Stripe::RequestParams
class TaxId < Stripe::RequestParams
# Type of the tax ID, one of `ad_nrt`, `ae_trn`, `al_tin`, `am_tin`, `ao_tin`, `ar_cuit`, `au_abn`, `au_arn`, `aw_tin`, `az_tin`, `ba_tin`, `bb_tin`, `bd_bin`, `bf_ifu`, `bg_uic`, `bh_vat`, `bj_ifu`, `bo_tin`, `br_cnpj`, `br_cpf`, `bs_tin`, `by_tin`, `ca_bn`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `ca_qst`, `cd_nif`, `ch_uid`, `ch_vat`, `cl_tin`, `cm_niu`, `cn_tin`, `co_nit`, `cr_tin`, `cv_nif`, `de_stn`, `do_rcn`, `ec_ruc`, `eg_tin`, `es_cif`, `et_tin`, `eu_oss_vat`, `eu_vat`, `gb_vat`, `ge_vat`, `gn_nif`, `hk_br`, `hr_oib`, `hu_tin`, `id_npwp`, `il_vat`, `in_gst`, `is_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `ke_pin`, `kg_tin`, `kh_tin`, `kr_brn`, `kz_bin`, `la_tin`, `li_uid`, `li_vat`, `ma_vat`, `md_vat`, `me_pib`, `mk_vat`, `mr_nif`, `mx_rfc`, `my_frp`, `my_itn`, `my_sst`, `ng_tin`, `no_vat`, `no_voec`, `np_pan`, `nz_gst`, `om_vat`, `pe_ruc`, `ph_tin`, `ro_tin`, `rs_pib`, `ru_inn`, `ru_kpp`, `sa_vat`, `sg_gst`, `sg_uen`, `si_tin`, `sn_ninea`, `sr_fin`, `sv_nit`, `th_vat`, `tj_tin`, `tr_tin`, `tw_vat`, `tz_vat`, `ua_vat`, `ug_tin`, `us_ein`, `uy_ruc`, `uz_tin`, `uz_vat`, `ve_rif`, `vn_tin`, `za_vat`, `zm_tin`, or `zw_tin`
sig { returns(String) }
attr_accessor :type
# Value of the tax ID.
sig { returns(String) }
attr_accessor :value
sig { params(type: String, value: String).void }
def initialize(type: nil, value: nil); end
end
# The purchaser's tax exemption status. One of `none`, `exempt`, or `reverse`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :tax_exempt
# The purchaser's tax IDs to be used for this order.
sig {
returns(T.nilable(T::Array[::Stripe::OrderService::CreateParams::TaxDetails::TaxId]))
}
attr_accessor :tax_ids
sig {
params(tax_exempt: T.nilable(T.nilable(T.any(String, String))), tax_ids: T.nilable(T::Array[::Stripe::OrderService::CreateParams::TaxDetails::TaxId])).void
}
def initialize(tax_exempt: nil, tax_ids: nil); end
end
# Settings for automatic tax calculation for this order.
sig { returns(T.nilable(::Stripe::OrderService::CreateParams::AutomaticTax)) }
attr_accessor :automatic_tax
# Billing details for the customer. If a customer is provided, this will be automatically populated with values from that customer if override values are not provided.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::CreateParams::BillingDetails))))
}
attr_accessor :billing_details
# 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).
sig { returns(String) }
attr_accessor :currency
# The customer associated with this order.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# The coupons, promotion codes, and/or discounts to apply to the order.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::OrderService::CreateParams::Discount]))))
}
attr_accessor :discounts
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The IP address of the purchaser for this order.
sig { returns(T.nilable(String)) }
attr_accessor :ip_address
# A list of line items the customer is ordering. Each line item includes information about the product, the quantity, and the resulting cost.
sig { returns(T::Array[::Stripe::OrderService::CreateParams::LineItem]) }
attr_accessor :line_items
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Payment information associated with the order, including payment settings.
sig { returns(T.nilable(::Stripe::OrderService::CreateParams::Payment)) }
attr_accessor :payment
# Settings for the customer cost of shipping for this order.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::CreateParams::ShippingCost))))
}
attr_accessor :shipping_cost
# Shipping details for the order.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::CreateParams::ShippingDetails))))
}
attr_accessor :shipping_details
# Additional tax details about the purchaser to be used for this order.
sig { returns(T.nilable(::Stripe::OrderService::CreateParams::TaxDetails)) }
attr_accessor :tax_details
sig {
params(automatic_tax: T.nilable(::Stripe::OrderService::CreateParams::AutomaticTax), billing_details: T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::CreateParams::BillingDetails))), currency: String, customer: T.nilable(String), description: T.nilable(String), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::OrderService::CreateParams::Discount]))), expand: T.nilable(T::Array[String]), ip_address: T.nilable(String), line_items: T::Array[::Stripe::OrderService::CreateParams::LineItem], metadata: T.nilable(T::Hash[String, String]), payment: T.nilable(::Stripe::OrderService::CreateParams::Payment), shipping_cost: T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::CreateParams::ShippingCost))), shipping_details: T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::CreateParams::ShippingDetails))), tax_details: T.nilable(::Stripe::OrderService::CreateParams::TaxDetails)).void
}
def initialize(
automatic_tax: nil,
billing_details: nil,
currency: nil,
customer: nil,
description: nil,
discounts: nil,
expand: nil,
ip_address: nil,
line_items: nil,
metadata: nil,
payment: nil,
shipping_cost: nil,
shipping_details: nil,
tax_details: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
class AutomaticTax < Stripe::RequestParams
# Enable automatic tax calculation which will automatically compute tax rates on this order.
sig { returns(T::Boolean) }
attr_accessor :enabled
sig { params(enabled: T::Boolean).void }
def initialize(enabled: nil); end
end
class BillingDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State/province as an [ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2) subdivision code, without country prefix. Example: "NY" or "TX".
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# The billing address provided by the customer.
sig { returns(T.nilable(::Stripe::OrderService::UpdateParams::BillingDetails::Address)) }
attr_accessor :address
# The billing email provided by the customer.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The billing name provided by the customer.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The billing phone number provided by the customer.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(address: T.nilable(::Stripe::OrderService::UpdateParams::BillingDetails::Address), email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(address: nil, email: nil, name: nil, phone: nil); end
end
class Discount < Stripe::RequestParams
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, promotion_code: nil); end
end
class LineItem < Stripe::RequestParams
class Discount < Stripe::RequestParams
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
sig { params(coupon: T.nilable(String), discount: T.nilable(String)).void }
def initialize(coupon: nil, discount: nil); end
end
class PriceData < Stripe::RequestParams
# 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).
sig { returns(T.nilable(String)) }
attr_accessor :currency
# ID of the [Product](https://docs.stripe.com/api/products) this [Price](https://docs.stripe.com/api/prices) belongs to.
#
# Use this to implement a variable-pricing model in your integration. This is required if `product_data` is not specified.
sig { returns(T.nilable(String)) }
attr_accessor :product
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: T.nilable(String), product: T.nilable(String), tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
class ProductData < Stripe::RequestParams
class PackageDimensions < Stripe::RequestParams
# Height, in inches. Maximum precision is 2 decimal places.
sig { returns(Float) }
attr_accessor :height
# Length, in inches. Maximum precision is 2 decimal places.
sig { returns(Float) }
attr_accessor :length
# Weight, in ounces. Maximum precision is 2 decimal places.
sig { returns(Float) }
attr_accessor :weight
# Width, in inches. Maximum precision is 2 decimal places.
sig { returns(Float) }
attr_accessor :width
sig { params(height: Float, length: Float, weight: Float, width: Float).void }
def initialize(height: nil, length: nil, weight: nil, width: nil); end
end
# The product's description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :description
# A unique identifier for this product.
#
# `product_data` automatically creates a Product with this ID. If a Product with the same ID already exists, then `product_data` re-uses it to avoid duplicates. If any of the fields in the existing Product are different from the values in `product_data`, `product_data` updates the existing Product with the new information. So set `product_data[id]` to the same string every time you sell the same product, but don't re-use the same string for different products.
sig { returns(String) }
attr_accessor :id
# A list of up to 8 URLs of images for this product, meant to be displayable to the customer.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :images
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# The product's name, meant to be displayable to the customer.
sig { returns(String) }
attr_accessor :name
# The dimensions of this product for shipping purposes.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::UpdateParams::LineItem::ProductData::PackageDimensions))))
}
attr_accessor :package_dimensions
# Whether this product is shipped (i.e., physical goods).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :shippable
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :tax_code
# A URL of a publicly-accessible webpage for this product.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :url
sig {
params(description: T.nilable(T.nilable(String)), id: String, images: T.nilable(T.nilable(T.any(String, T::Array[String]))), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), name: String, package_dimensions: T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::UpdateParams::LineItem::ProductData::PackageDimensions))), shippable: T.nilable(T::Boolean), tax_code: T.nilable(T.nilable(String)), url: T.nilable(T.nilable(String))).void
}
def initialize(
description: nil,
id: nil,
images: nil,
metadata: nil,
name: nil,
package_dimensions: nil,
shippable: nil,
tax_code: nil,
url: nil
); end
end
# The description for the line item. Will default to the name of the associated product.
sig { returns(T.nilable(String)) }
attr_accessor :description
# The discounts applied to this line item.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::OrderService::UpdateParams::LineItem::Discount]))))
}
attr_accessor :discounts
# The ID of an existing line item on the order.
sig { returns(T.nilable(String)) }
attr_accessor :id
# The ID of a [Price](https://docs.stripe.com/api/prices) to add to the Order.
#
# The `price` parameter is an alternative to using the `product` parameter. If each of your products are sold at a single price, you can set `Product.default_price` and then pass the `product` parameter when creating a line item. If your products are sold at several possible prices, use the `price` parameter to explicitly specify which one to use.
sig { returns(T.nilable(String)) }
attr_accessor :price
# Data used to generate a new Price object inline.
#
# The `price_data` parameter is an alternative to using the `product` or `price` parameters. If you create a Product upfront and configure a `Product.default_price`, pass the `product` parameter when creating a line item. If you prefer not to define Products upfront, or if you charge variable prices, pass the `price_data` parameter to describe the price for this line item.
#
# Each time you pass `price_data` we create a Price for the Product. This Price is hidden in both the Dashboard and API lists and cannot be reused.
sig { returns(T.nilable(::Stripe::OrderService::UpdateParams::LineItem::PriceData)) }
attr_accessor :price_data
# The ID of a [Product](https://docs.stripe.com/api/products) to add to the Order.
#
# The Product must have a `default_price` specified. Otherwise, specify the price by passing the `price` or `price_data` parameter.
sig { returns(T.nilable(String)) }
attr_accessor :product
# Defines a [Product](https://docs.stripe.com/api/products) inline and adds it to the Order.
#
# `product_data` is an alternative to the `product` parameter. If you created a Product upfront, use the `product` parameter to refer to the existing Product. But if you prefer not to create Products upfront, pass the `product_data` parameter to define a Product inline as part of configuring the Order.
#
# `product_data` automatically creates a Product, just as if you had manually created the Product. If a Product with the same ID already exists, then `product_data` re-uses it to avoid duplicates.
sig { returns(T.nilable(::Stripe::OrderService::UpdateParams::LineItem::ProductData)) }
attr_accessor :product_data
# The quantity of the line item.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# The tax rates applied to this line item.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
sig {
params(description: T.nilable(String), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::OrderService::UpdateParams::LineItem::Discount]))), id: T.nilable(String), price: T.nilable(String), price_data: T.nilable(::Stripe::OrderService::UpdateParams::LineItem::PriceData), product: T.nilable(String), product_data: T.nilable(::Stripe::OrderService::UpdateParams::LineItem::ProductData), quantity: T.nilable(Integer), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String])))).void
}
def initialize(
description: nil,
discounts: nil,
id: nil,
price: nil,
price_data: nil,
product: nil,
product_data: nil,
quantity: nil,
tax_rates: nil
); end
end
class Payment < Stripe::RequestParams
class Settings < Stripe::RequestParams
class PaymentMethodOptions < Stripe::RequestParams
class AcssDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# A URL for custom mandate text to render during confirmation step.
# The URL will be rendered with additional GET parameters `payment_intent` and `payment_intent_client_secret` when confirming a Payment Intent,
# or `setup_intent` and `setup_intent_client_secret` when confirming a Setup Intent.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :custom_mandate_url
# Description of the mandate interval. Only required if 'payment_schedule' parameter is 'interval' or 'combined'.
sig { returns(T.nilable(String)) }
attr_accessor :interval_description
# Payment schedule for the mandate.
sig { returns(T.nilable(String)) }
attr_accessor :payment_schedule
# Transaction type of the mandate.
sig { returns(T.nilable(String)) }
attr_accessor :transaction_type
sig {
params(custom_mandate_url: T.nilable(T.nilable(String)), interval_description: T.nilable(String), payment_schedule: T.nilable(String), transaction_type: T.nilable(String)).void
}
def initialize(
custom_mandate_url: nil,
interval_description: nil,
payment_schedule: nil,
transaction_type: nil
); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::OrderService::UpdateParams::Payment::Settings::PaymentMethodOptions::AcssDebit::MandateOptions))
}
attr_accessor :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
# Bank account verification method.
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(mandate_options: T.nilable(::Stripe::OrderService::UpdateParams::Payment::Settings::PaymentMethodOptions::AcssDebit::MandateOptions), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), target_date: T.nilable(String), verification_method: T.nilable(String)).void
}
def initialize(
mandate_options: nil,
setup_future_usage: nil,
target_date: nil,
verification_method: nil
); end
end
class AfterpayClearpay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(String)) }
attr_accessor :capture_method
# An internal identifier or reference this payment corresponds to. The identifier is limited to 128 characters and may contain only letters, digits, underscores, backslashes and dashes.
sig { returns(T.nilable(String)) }
attr_accessor :reference
# Indicates that you intend to make future payments with the payment method.
#
# Providing this parameter will [attach the payment method](https://stripe.com/docs/payments/save-during-payment) to the order's Customer, if present, after the order's PaymentIntent is confirmed and any required actions from the user are complete. If no Customer was provided, the payment method can still be [attached](https://stripe.com/docs/api/payment_methods/attach) to a Customer after the transaction completes.
#
# When processing card payments, Stripe also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as [SCA](https://stripe.com/docs/strong-customer-authentication).
#
# If `setup_future_usage` is already set and you are performing a request using a publishable key, you may only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(String), reference: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(capture_method: nil, reference: nil, setup_future_usage: nil); end
end
class Alipay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void }
def initialize(setup_future_usage: nil); end
end
class Bancontact < Stripe::RequestParams
# Preferred language of the Bancontact authorization page that the customer is redirected to.
sig { returns(T.nilable(String)) }
attr_accessor :preferred_language
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(preferred_language: T.nilable(String), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(preferred_language: nil, setup_future_usage: nil); end
end
class Card < Stripe::RequestParams
# Controls when the funds will be captured from the customer's account.
sig { returns(T.nilable(String)) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with the payment method.
#
# Providing this parameter will [attach the payment method](https://stripe.com/docs/payments/save-during-payment) to the order's Customer, if present, after the order's PaymentIntent is confirmed and any required actions from the user are complete. If no Customer was provided, the payment method can still be [attached](https://stripe.com/docs/api/payment_methods/attach) to a Customer after the transaction completes.
#
# When processing card payments, Stripe also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as [SCA](https://stripe.com/docs/strong-customer-authentication).
#
# If `setup_future_usage` is already set and you are performing a request using a publishable key, you may only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class CustomerBalance < Stripe::RequestParams
class BankTransfer < Stripe::RequestParams
class EuBankTransfer < Stripe::RequestParams
# The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
sig { returns(String) }
attr_accessor :country
sig { params(country: String).void }
def initialize(country: nil); end
end
# Configuration for the eu_bank_transfer funding type.
sig {
returns(T.nilable(::Stripe::OrderService::UpdateParams::Payment::Settings::PaymentMethodOptions::CustomerBalance::BankTransfer::EuBankTransfer))
}
attr_accessor :eu_bank_transfer
# List of address types that should be returned in the financial_addresses response. If not specified, all valid types will be returned.
#
# Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :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`, `mx_bank_transfer`, or `us_bank_transfer`.
sig { returns(String) }
attr_accessor :type
sig {
params(eu_bank_transfer: T.nilable(::Stripe::OrderService::UpdateParams::Payment::Settings::PaymentMethodOptions::CustomerBalance::BankTransfer::EuBankTransfer), requested_address_types: T.nilable(T::Array[String]), type: String).void
}
def initialize(eu_bank_transfer: nil, requested_address_types: nil, type: nil); end
end
# Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
sig {
returns(T.nilable(::Stripe::OrderService::UpdateParams::Payment::Settings::PaymentMethodOptions::CustomerBalance::BankTransfer))
}
attr_accessor :bank_transfer
# The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
sig { returns(T.nilable(String)) }
attr_accessor :funding_type
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(bank_transfer: T.nilable(::Stripe::OrderService::UpdateParams::Payment::Settings::PaymentMethodOptions::CustomerBalance::BankTransfer), funding_type: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(bank_transfer: nil, funding_type: nil, setup_future_usage: nil); end
end
class Ideal < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void }
def initialize(setup_future_usage: nil); end
end
class Klarna < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Preferred language of the Klarna authorization page that the customer is redirected to
sig { returns(T.nilable(String)) }
attr_accessor :preferred_locale
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), preferred_locale: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(
capture_method: nil,
preferred_locale: nil,
setup_future_usage: nil
); end
end
class Link < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# [Deprecated] This is a legacy parameter that no longer has any function.
sig { returns(T.nilable(String)) }
attr_accessor :persistent_token
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), persistent_token: T.nilable(String), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(
capture_method: nil,
persistent_token: nil,
setup_future_usage: nil
); end
end
class Oxxo < Stripe::RequestParams
# The number of calendar days before an OXXO voucher expires. For example, if you create an OXXO voucher on Monday and you set expires_after_days to 2, the OXXO invoice will expire on Wednesday at 23:59 America/Mexico_City time.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_after_days
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(expires_after_days: T.nilable(Integer), setup_future_usage: T.nilable(String)).void
}
def initialize(expires_after_days: nil, setup_future_usage: nil); end
end
class P24 < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
# Confirm that the payer has accepted the P24 terms and conditions.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :tos_shown_and_accepted
sig {
params(setup_future_usage: T.nilable(String), tos_shown_and_accepted: T.nilable(T::Boolean)).void
}
def initialize(setup_future_usage: nil, tos_shown_and_accepted: nil); end
end
class Paypal < Stripe::RequestParams
class LineItem < Stripe::RequestParams
class Tax < Stripe::RequestParams
# The tax for a single unit of the line item in minor units. Cannot be a negative number.
sig { returns(Integer) }
attr_accessor :amount
# The tax behavior for the line item.
sig { returns(String) }
attr_accessor :behavior
sig { params(amount: Integer, behavior: String).void }
def initialize(amount: nil, behavior: nil); end
end
# Type of the line item.
sig { returns(T.nilable(String)) }
attr_accessor :category
# Description of the line item.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Descriptive name of the line item.
sig { returns(String) }
attr_accessor :name
# Quantity of the line item. Must be a positive number.
sig { returns(Integer) }
attr_accessor :quantity
# Client facing stock keeping unit, article number or similar.
sig { returns(T.nilable(String)) }
attr_accessor :sku
# The Stripe account ID of the connected account that sells the item.
sig { returns(T.nilable(String)) }
attr_accessor :sold_by
# The tax information for the line item.
sig {
returns(T.nilable(::Stripe::OrderService::UpdateParams::Payment::Settings::PaymentMethodOptions::Paypal::LineItem::Tax))
}
attr_accessor :tax
# Price for a single unit of the line item in minor units. Cannot be a negative number.
sig { returns(Integer) }
attr_accessor :unit_amount
sig {
params(category: T.nilable(String), description: T.nilable(String), name: String, quantity: Integer, sku: T.nilable(String), sold_by: T.nilable(String), tax: T.nilable(::Stripe::OrderService::UpdateParams::Payment::Settings::PaymentMethodOptions::Paypal::LineItem::Tax), unit_amount: Integer).void
}
def initialize(
category: nil,
description: nil,
name: nil,
quantity: nil,
sku: nil,
sold_by: nil,
tax: nil,
unit_amount: nil
); end
end
# Controls when the funds will be captured from the customer's account.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# The line items purchased by the customer.
sig {
returns(T.nilable(T::Array[::Stripe::OrderService::UpdateParams::Payment::Settings::PaymentMethodOptions::Paypal::LineItem]))
}
attr_accessor :line_items
# [Preferred locale](https://stripe.com/docs/payments/paypal/supported-locales) of the PayPal checkout page that the customer is redirected to.
sig { returns(T.nilable(String)) }
attr_accessor :preferred_locale
# A reference of the PayPal transaction visible to customer which is mapped to PayPal's invoice ID. This must be a globally unique ID if you have configured in your PayPal settings to block multiple payments per invoice ID.
sig { returns(T.nilable(String)) }
attr_accessor :reference
# A reference of the PayPal transaction visible to customer which is mapped to PayPal's invoice ID. This must be a globally unique ID if you have configured in your PayPal settings to block multiple payments per invoice ID.
sig { returns(T.nilable(String)) }
attr_accessor :reference_id
# The risk correlation ID for an on-session payment using a saved PayPal payment method.
sig { returns(T.nilable(String)) }
attr_accessor :risk_correlation_id
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# The Stripe connected account IDs of the sellers on the platform for this transaction (optional). Only allowed when [separate charges and transfers](https://stripe.com/docs/connect/separate-charges-and-transfers) are used.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :subsellers
sig {
params(capture_method: T.nilable(T.nilable(String)), line_items: T.nilable(T::Array[::Stripe::OrderService::UpdateParams::Payment::Settings::PaymentMethodOptions::Paypal::LineItem]), preferred_locale: T.nilable(String), reference: T.nilable(String), reference_id: T.nilable(String), risk_correlation_id: T.nilable(String), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), subsellers: T.nilable(T::Array[String])).void
}
def initialize(
capture_method: nil,
line_items: nil,
preferred_locale: nil,
reference: nil,
reference_id: nil,
risk_correlation_id: nil,
setup_future_usage: nil,
subsellers: nil
); end
end
class SepaDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'STRIPE'.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :reference_prefix
sig { params(reference_prefix: T.nilable(T.nilable(String))).void }
def initialize(reference_prefix: nil); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::OrderService::UpdateParams::Payment::Settings::PaymentMethodOptions::SepaDebit::MandateOptions))
}
attr_accessor :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
sig {
params(mandate_options: T.nilable(::Stripe::OrderService::UpdateParams::Payment::Settings::PaymentMethodOptions::SepaDebit::MandateOptions), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), target_date: T.nilable(String)).void
}
def initialize(mandate_options: nil, setup_future_usage: nil, target_date: nil); end
end
class Sofort < Stripe::RequestParams
# Language shown to the payer on redirect.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :preferred_language
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(preferred_language: T.nilable(T.nilable(T.any(String, String))), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(preferred_language: nil, setup_future_usage: nil); end
end
class WechatPay < Stripe::RequestParams
# The app ID registered with WeChat Pay. Only required when client is ios or android.
sig { returns(T.nilable(String)) }
attr_accessor :app_id
# The client type that the end customer will pay from
sig { returns(T.nilable(String)) }
attr_accessor :client
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(app_id: T.nilable(String), client: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(app_id: nil, client: nil, setup_future_usage: nil); end
end
# If paying by `acss_debit`, this sub-hash contains details about the ACSS Debit payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::UpdateParams::Payment::Settings::PaymentMethodOptions::AcssDebit))))
}
attr_accessor :acss_debit
# If paying by `afterpay_clearpay`, this sub-hash contains details about the AfterpayClearpay payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::UpdateParams::Payment::Settings::PaymentMethodOptions::AfterpayClearpay))))
}
attr_accessor :afterpay_clearpay
# If paying by `alipay`, this sub-hash contains details about the Alipay payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::UpdateParams::Payment::Settings::PaymentMethodOptions::Alipay))))
}
attr_accessor :alipay
# If paying by `bancontact`, this sub-hash contains details about the Bancontact payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::UpdateParams::Payment::Settings::PaymentMethodOptions::Bancontact))))
}
attr_accessor :bancontact
# If paying by `card`, this sub-hash contains details about the Card payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::UpdateParams::Payment::Settings::PaymentMethodOptions::Card))))
}
attr_accessor :card
# If paying by `customer_balance`, this sub-hash contains details about the Customer Balance payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::UpdateParams::Payment::Settings::PaymentMethodOptions::CustomerBalance))))
}
attr_accessor :customer_balance
# If paying by `ideal`, this sub-hash contains details about the iDEAL payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::UpdateParams::Payment::Settings::PaymentMethodOptions::Ideal))))
}
attr_accessor :ideal
# If paying by `klarna`, this sub-hash contains details about the Klarna payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::UpdateParams::Payment::Settings::PaymentMethodOptions::Klarna))))
}
attr_accessor :klarna
# If paying by `link`, this sub-hash contains details about the Link payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::UpdateParams::Payment::Settings::PaymentMethodOptions::Link))))
}
attr_accessor :link
# If paying by `oxxo`, this sub-hash contains details about the OXXO payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::UpdateParams::Payment::Settings::PaymentMethodOptions::Oxxo))))
}
attr_accessor :oxxo
# If paying by `p24`, this sub-hash contains details about the P24 payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::UpdateParams::Payment::Settings::PaymentMethodOptions::P24))))
}
attr_accessor :p24
# If paying by `paypal`, this sub-hash contains details about the PayPal payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::UpdateParams::Payment::Settings::PaymentMethodOptions::Paypal))))
}
attr_accessor :paypal
# If paying by `sepa_debit`, this sub-hash contains details about the SEPA Debit payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::UpdateParams::Payment::Settings::PaymentMethodOptions::SepaDebit))))
}
attr_accessor :sepa_debit
# If paying by `sofort`, this sub-hash contains details about the Sofort payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::UpdateParams::Payment::Settings::PaymentMethodOptions::Sofort))))
}
attr_accessor :sofort
# If paying by `wechat_pay`, this sub-hash contains details about the WeChat Pay payment method options to pass to the order's PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::UpdateParams::Payment::Settings::PaymentMethodOptions::WechatPay))))
}
attr_accessor :wechat_pay
sig {
params(acss_debit: T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::UpdateParams::Payment::Settings::PaymentMethodOptions::AcssDebit))), afterpay_clearpay: T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::UpdateParams::Payment::Settings::PaymentMethodOptions::AfterpayClearpay))), alipay: T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::UpdateParams::Payment::Settings::PaymentMethodOptions::Alipay))), bancontact: T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::UpdateParams::Payment::Settings::PaymentMethodOptions::Bancontact))), card: T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::UpdateParams::Payment::Settings::PaymentMethodOptions::Card))), customer_balance: T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::UpdateParams::Payment::Settings::PaymentMethodOptions::CustomerBalance))), ideal: T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::UpdateParams::Payment::Settings::PaymentMethodOptions::Ideal))), klarna: T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::UpdateParams::Payment::Settings::PaymentMethodOptions::Klarna))), link: T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::UpdateParams::Payment::Settings::PaymentMethodOptions::Link))), oxxo: T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::UpdateParams::Payment::Settings::PaymentMethodOptions::Oxxo))), p24: T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::UpdateParams::Payment::Settings::PaymentMethodOptions::P24))), paypal: T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::UpdateParams::Payment::Settings::PaymentMethodOptions::Paypal))), sepa_debit: T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::UpdateParams::Payment::Settings::PaymentMethodOptions::SepaDebit))), sofort: T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::UpdateParams::Payment::Settings::PaymentMethodOptions::Sofort))), wechat_pay: T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::UpdateParams::Payment::Settings::PaymentMethodOptions::WechatPay)))).void
}
def initialize(
acss_debit: nil,
afterpay_clearpay: nil,
alipay: nil,
bancontact: nil,
card: nil,
customer_balance: nil,
ideal: nil,
klarna: nil,
link: nil,
oxxo: nil,
p24: nil,
paypal: nil,
sepa_debit: nil,
sofort: nil,
wechat_pay: nil
); end
end
class TransferData < Stripe::RequestParams
# The amount that will be transferred automatically when the order is paid. If no amount is set, the full amount is transferred. There cannot be any line items with recurring prices when using this field.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# ID of the Connected account receiving the transfer.
sig { returns(String) }
attr_accessor :destination
sig { params(amount: T.nilable(Integer), destination: String).void }
def initialize(amount: nil, destination: nil); end
end
# The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :application_fee_amount
# PaymentMethod-specific configuration to provide to the order's PaymentIntent.
sig {
returns(T.nilable(::Stripe::OrderService::UpdateParams::Payment::Settings::PaymentMethodOptions))
}
attr_accessor :payment_method_options
# The list of [payment method types](https://stripe.com/docs/payments/payment-methods/overview) to provide to the order's PaymentIntent. Do not include this attribute if you prefer to manage your payment methods from the [Stripe Dashboard](https://dashboard.stripe.com/settings/payment_methods).
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :payment_method_types
# The URL to redirect the customer to after they authenticate their payment.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :return_url
# For non-card charges, you can use this value as the complete description that appears on your customers' statements. Must contain at least one letter, maximum 22 characters.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
# Provides information about a card payment that customers see on their statements. Concatenated with the prefix (shortened descriptor) or statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 22 characters for the concatenated descriptor.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor_suffix
# Provides configuration for completing a transfer for the order after it is paid.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::UpdateParams::Payment::Settings::TransferData))))
}
attr_accessor :transfer_data
sig {
params(application_fee_amount: T.nilable(T.nilable(T.any(String, Integer))), payment_method_options: T.nilable(::Stripe::OrderService::UpdateParams::Payment::Settings::PaymentMethodOptions), payment_method_types: T.nilable(T::Array[String]), return_url: T.nilable(T.nilable(String)), statement_descriptor: T.nilable(String), statement_descriptor_suffix: T.nilable(String), transfer_data: T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::UpdateParams::Payment::Settings::TransferData)))).void
}
def initialize(
application_fee_amount: nil,
payment_method_options: nil,
payment_method_types: nil,
return_url: nil,
statement_descriptor: nil,
statement_descriptor_suffix: nil,
transfer_data: nil
); end
end
# Settings describing how the order should configure generated PaymentIntents.
sig { returns(::Stripe::OrderService::UpdateParams::Payment::Settings) }
attr_accessor :settings
sig { params(settings: ::Stripe::OrderService::UpdateParams::Payment::Settings).void }
def initialize(settings: nil); end
end
class ShippingCost < Stripe::RequestParams
class ShippingRateData < Stripe::RequestParams
class DeliveryEstimate < Stripe::RequestParams
class Maximum < Stripe::RequestParams
# A unit of time.
sig { returns(String) }
attr_accessor :unit
# Must be greater than 0.
sig { returns(Integer) }
attr_accessor :value
sig { params(unit: String, value: Integer).void }
def initialize(unit: nil, value: nil); end
end
class Minimum < Stripe::RequestParams
# A unit of time.
sig { returns(String) }
attr_accessor :unit
# Must be greater than 0.
sig { returns(Integer) }
attr_accessor :value
sig { params(unit: String, value: Integer).void }
def initialize(unit: nil, value: nil); end
end
# The upper bound of the estimated range. If empty, represents no upper bound i.e., infinite.
sig {
returns(T.nilable(::Stripe::OrderService::UpdateParams::ShippingCost::ShippingRateData::DeliveryEstimate::Maximum))
}
attr_accessor :maximum
# The lower bound of the estimated range. If empty, represents no lower bound.
sig {
returns(T.nilable(::Stripe::OrderService::UpdateParams::ShippingCost::ShippingRateData::DeliveryEstimate::Minimum))
}
attr_accessor :minimum
sig {
params(maximum: T.nilable(::Stripe::OrderService::UpdateParams::ShippingCost::ShippingRateData::DeliveryEstimate::Maximum), minimum: T.nilable(::Stripe::OrderService::UpdateParams::ShippingCost::ShippingRateData::DeliveryEstimate::Minimum)).void
}
def initialize(maximum: nil, minimum: nil); end
end
class FixedAmount < Stripe::RequestParams
class CurrencyOptions < Stripe::RequestParams
# A non-negative integer in cents representing how much to charge.
sig { returns(Integer) }
attr_accessor :amount
# Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
sig { params(amount: Integer, tax_behavior: T.nilable(String)).void }
def initialize(amount: nil, tax_behavior: nil); end
end
# A non-negative integer in cents representing how much to charge.
sig { returns(Integer) }
attr_accessor :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).
sig { returns(String) }
attr_accessor :currency
# Shipping rates defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
sig {
returns(T.nilable(T::Hash[String, ::Stripe::OrderService::UpdateParams::ShippingCost::ShippingRateData::FixedAmount::CurrencyOptions]))
}
attr_accessor :currency_options
sig {
params(amount: Integer, currency: String, currency_options: T.nilable(T::Hash[String, ::Stripe::OrderService::UpdateParams::ShippingCost::ShippingRateData::FixedAmount::CurrencyOptions])).void
}
def initialize(amount: nil, currency: nil, currency_options: nil); end
end
# The estimated range for how long shipping will take, meant to be displayable to the customer. This will appear on CheckoutSessions.
sig {
returns(T.nilable(::Stripe::OrderService::UpdateParams::ShippingCost::ShippingRateData::DeliveryEstimate))
}
attr_accessor :delivery_estimate
# The name of the shipping rate, meant to be displayable to the customer. This will appear on CheckoutSessions.
sig { returns(String) }
attr_accessor :display_name
# Describes a fixed amount to charge for shipping. Must be present if type is `fixed_amount`.
sig {
returns(T.nilable(::Stripe::OrderService::UpdateParams::ShippingCost::ShippingRateData::FixedAmount))
}
attr_accessor :fixed_amount
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID. The Shipping tax code is `txcd_92010001`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_code
# The type of calculation to use on the shipping rate.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(delivery_estimate: T.nilable(::Stripe::OrderService::UpdateParams::ShippingCost::ShippingRateData::DeliveryEstimate), display_name: String, fixed_amount: T.nilable(::Stripe::OrderService::UpdateParams::ShippingCost::ShippingRateData::FixedAmount), metadata: T.nilable(T::Hash[String, String]), tax_behavior: T.nilable(String), tax_code: T.nilable(String), type: T.nilable(String)).void
}
def initialize(
delivery_estimate: nil,
display_name: nil,
fixed_amount: nil,
metadata: nil,
tax_behavior: nil,
tax_code: nil,
type: nil
); end
end
# The ID of the shipping rate to use for this order.
sig { returns(T.nilable(String)) }
attr_accessor :shipping_rate
# Parameters to create a new ad-hoc shipping rate for this order.
sig {
returns(T.nilable(::Stripe::OrderService::UpdateParams::ShippingCost::ShippingRateData))
}
attr_accessor :shipping_rate_data
sig {
params(shipping_rate: T.nilable(String), shipping_rate_data: T.nilable(::Stripe::OrderService::UpdateParams::ShippingCost::ShippingRateData)).void
}
def initialize(shipping_rate: nil, shipping_rate_data: nil); end
end
class ShippingDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State/province as an [ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2) subdivision code, without country prefix. Example: "NY" or "TX".
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# The shipping address for the order.
sig { returns(::Stripe::OrderService::UpdateParams::ShippingDetails::Address) }
attr_accessor :address
# The name of the recipient of the order.
sig { returns(String) }
attr_accessor :name
# The phone number (including extension) for the recipient of the order.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :phone
sig {
params(address: ::Stripe::OrderService::UpdateParams::ShippingDetails::Address, name: String, phone: T.nilable(T.nilable(String))).void
}
def initialize(address: nil, name: nil, phone: nil); end
end
class TaxDetails < Stripe::RequestParams
class TaxId < Stripe::RequestParams
# Type of the tax ID, one of `ad_nrt`, `ae_trn`, `al_tin`, `am_tin`, `ao_tin`, `ar_cuit`, `au_abn`, `au_arn`, `aw_tin`, `az_tin`, `ba_tin`, `bb_tin`, `bd_bin`, `bf_ifu`, `bg_uic`, `bh_vat`, `bj_ifu`, `bo_tin`, `br_cnpj`, `br_cpf`, `bs_tin`, `by_tin`, `ca_bn`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `ca_qst`, `cd_nif`, `ch_uid`, `ch_vat`, `cl_tin`, `cm_niu`, `cn_tin`, `co_nit`, `cr_tin`, `cv_nif`, `de_stn`, `do_rcn`, `ec_ruc`, `eg_tin`, `es_cif`, `et_tin`, `eu_oss_vat`, `eu_vat`, `gb_vat`, `ge_vat`, `gn_nif`, `hk_br`, `hr_oib`, `hu_tin`, `id_npwp`, `il_vat`, `in_gst`, `is_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `ke_pin`, `kg_tin`, `kh_tin`, `kr_brn`, `kz_bin`, `la_tin`, `li_uid`, `li_vat`, `ma_vat`, `md_vat`, `me_pib`, `mk_vat`, `mr_nif`, `mx_rfc`, `my_frp`, `my_itn`, `my_sst`, `ng_tin`, `no_vat`, `no_voec`, `np_pan`, `nz_gst`, `om_vat`, `pe_ruc`, `ph_tin`, `ro_tin`, `rs_pib`, `ru_inn`, `ru_kpp`, `sa_vat`, `sg_gst`, `sg_uen`, `si_tin`, `sn_ninea`, `sr_fin`, `sv_nit`, `th_vat`, `tj_tin`, `tr_tin`, `tw_vat`, `tz_vat`, `ua_vat`, `ug_tin`, `us_ein`, `uy_ruc`, `uz_tin`, `uz_vat`, `ve_rif`, `vn_tin`, `za_vat`, `zm_tin`, or `zw_tin`
sig { returns(String) }
attr_accessor :type
# Value of the tax ID.
sig { returns(String) }
attr_accessor :value
sig { params(type: String, value: String).void }
def initialize(type: nil, value: nil); end
end
# The purchaser's tax exemption status. One of `none`, `exempt`, or `reverse`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :tax_exempt
# The purchaser's tax IDs to be used for this order.
sig {
returns(T.nilable(T::Array[::Stripe::OrderService::UpdateParams::TaxDetails::TaxId]))
}
attr_accessor :tax_ids
sig {
params(tax_exempt: T.nilable(T.nilable(T.any(String, String))), tax_ids: T.nilable(T::Array[::Stripe::OrderService::UpdateParams::TaxDetails::TaxId])).void
}
def initialize(tax_exempt: nil, tax_ids: nil); end
end
# Settings for automatic tax calculation for this order.
sig { returns(T.nilable(::Stripe::OrderService::UpdateParams::AutomaticTax)) }
attr_accessor :automatic_tax
# Billing details for the customer. If a customer is provided, this will be automatically populated with values from that customer if override values are not provided.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::UpdateParams::BillingDetails))))
}
attr_accessor :billing_details
# 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).
sig { returns(T.nilable(String)) }
attr_accessor :currency
# The customer associated with this order.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :description
# The coupons, promotion codes, and/or discounts to apply to the order. Pass the empty string `""` to unset this field.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::OrderService::UpdateParams::Discount]))))
}
attr_accessor :discounts
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The IP address of the purchaser for this order.
sig { returns(T.nilable(String)) }
attr_accessor :ip_address
# A list of line items the customer is ordering. Each line item includes information about the product, the quantity, and the resulting cost.
sig { returns(T.nilable(T::Array[::Stripe::OrderService::UpdateParams::LineItem])) }
attr_accessor :line_items
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Payment information associated with the order, including payment settings.
sig { returns(T.nilable(::Stripe::OrderService::UpdateParams::Payment)) }
attr_accessor :payment
# Settings for the customer cost of shipping for this order.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::UpdateParams::ShippingCost))))
}
attr_accessor :shipping_cost
# Shipping details for the order.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::UpdateParams::ShippingDetails))))
}
attr_accessor :shipping_details
# Additional tax details about the purchaser to be used for this order.
sig { returns(T.nilable(::Stripe::OrderService::UpdateParams::TaxDetails)) }
attr_accessor :tax_details
sig {
params(automatic_tax: T.nilable(::Stripe::OrderService::UpdateParams::AutomaticTax), billing_details: T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::UpdateParams::BillingDetails))), currency: T.nilable(String), customer: T.nilable(String), description: T.nilable(T.nilable(String)), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::OrderService::UpdateParams::Discount]))), expand: T.nilable(T::Array[String]), ip_address: T.nilable(String), line_items: T.nilable(T::Array[::Stripe::OrderService::UpdateParams::LineItem]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), payment: T.nilable(::Stripe::OrderService::UpdateParams::Payment), shipping_cost: T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::UpdateParams::ShippingCost))), shipping_details: T.nilable(T.nilable(T.any(String, ::Stripe::OrderService::UpdateParams::ShippingDetails))), tax_details: T.nilable(::Stripe::OrderService::UpdateParams::TaxDetails)).void
}
def initialize(
automatic_tax: nil,
billing_details: nil,
currency: nil,
customer: nil,
description: nil,
discounts: nil,
expand: nil,
ip_address: nil,
line_items: nil,
metadata: nil,
payment: nil,
shipping_cost: nil,
shipping_details: nil,
tax_details: nil
); end
end
class CancelParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class ReopenParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class SubmitParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# `expected_total` should always be set to the order's `amount_total` field. If they don't match, submitting the order will fail. This helps detect race conditions where something else concurrently modifies the order.
sig { returns(Integer) }
attr_accessor :expected_total
sig { params(expand: T.nilable(T::Array[String]), expected_total: Integer).void }
def initialize(expand: nil, expected_total: nil); end
end
# Cancels the order as well as the payment intent if one is attached.
sig {
params(id: String, params: T.any(::Stripe::OrderService::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Order)
}
def cancel(id, params = {}, opts = {}); end
# Creates a new open order object.
sig {
params(params: T.any(::Stripe::OrderService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Order)
}
def create(params = {}, opts = {}); end
# Returns a list of your orders. The orders are returned sorted by creation date, with the most recently created orders appearing first.
sig {
params(params: T.any(::Stripe::OrderService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Reopens a submitted order.
sig {
params(id: String, params: T.any(::Stripe::OrderService::ReopenParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Order)
}
def reopen(id, params = {}, opts = {}); end
# Retrieves the details of an existing order. Supply the unique order ID from either an order creation request or the order list, and Stripe will return the corresponding order information.
sig {
params(id: String, params: T.any(::Stripe::OrderService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Order)
}
def retrieve(id, params = {}, opts = {}); end
# Submitting an Order transitions the status to processing and creates a PaymentIntent object so the order can be paid. If the Order has an amount_total of 0, no PaymentIntent object will be created. Once the order is submitted, its contents cannot be changed, unless the [reopen](https://docs.stripe.com/api#reopen_order) method is called.
sig {
params(id: String, params: T.any(::Stripe::OrderService::SubmitParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Order)
}
def submit(id, params = {}, opts = {}); end
# Updates the specific order by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
sig {
params(id: String, params: T.any(::Stripe::OrderService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Order)
}
def update(id, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class OrderLineItemService < StripeService
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
# When retrieving an order, there is an includable line_items property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items.
sig {
params(id: String, params: T.any(::Stripe::OrderLineItemService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(id, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class PaymentAttemptRecordService < StripeService
class ListParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The ID of the Payment Record.
sig { returns(String) }
attr_accessor :payment_record
sig { params(expand: T.nilable(T::Array[String]), payment_record: String).void }
def initialize(expand: nil, payment_record: nil); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# List all the Payment Attempt Records attached to the specified Payment Record.
sig {
params(params: T.any(::Stripe::PaymentAttemptRecordService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves a Payment Attempt Record with the given ID
sig {
params(id: String, params: T.any(::Stripe::PaymentAttemptRecordService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentAttemptRecord)
}
def retrieve(id, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class PaymentIntentService < StripeService
attr_reader :amount_details_line_items
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp or a dictionary with a number of different query options.
sig {
returns(T.nilable(T.any(::Stripe::PaymentIntentService::ListParams::Created, Integer)))
}
attr_accessor :created
# Only return PaymentIntents for the customer that this customer ID specifies.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# Only return PaymentIntents for the account that this ID specifies.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(created: T.nilable(T.any(::Stripe::PaymentIntentService::ListParams::Created, Integer)), customer: T.nilable(String), customer_account: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
created: nil,
customer: nil,
customer_account: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class AutomaticPaymentMethods < Stripe::RequestParams
# Controls whether this PaymentIntent will accept redirect-based payment methods.
#
# Redirect-based payment methods may require your customer to be redirected to a payment method's app or site for authentication or additional steps. To [confirm](https://stripe.com/docs/api/payment_intents/confirm) this PaymentIntent, you may be required to provide a `return_url` to redirect customers back to your site after they authenticate or complete the payment.
sig { returns(T.nilable(String)) }
attr_accessor :allow_redirects
# Whether this feature is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
sig { params(allow_redirects: T.nilable(String), enabled: T::Boolean).void }
def initialize(allow_redirects: nil, enabled: nil); end
end
class Hooks < Stripe::RequestParams
class Inputs < Stripe::RequestParams
class Tax < Stripe::RequestParams
# The [TaxCalculation](https://stripe.com/docs/api/tax/calculations) id
sig { returns(T.nilable(String)) }
attr_accessor :calculation
sig { params(calculation: T.nilable(String)).void }
def initialize(calculation: nil); end
end
# Tax arguments for automations
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::Hooks::Inputs::Tax))
}
attr_accessor :tax
sig {
params(tax: T.nilable(::Stripe::PaymentIntentService::CreateParams::Hooks::Inputs::Tax)).void
}
def initialize(tax: nil); end
end
# Arguments passed in automations
sig { returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::Hooks::Inputs)) }
attr_accessor :inputs
sig {
params(inputs: T.nilable(::Stripe::PaymentIntentService::CreateParams::Hooks::Inputs)).void
}
def initialize(inputs: nil); end
end
class MandateData < Stripe::RequestParams
class CustomerAcceptance < Stripe::RequestParams
class Offline < Stripe::RequestParams; end
class Online < Stripe::RequestParams
# The IP address from which the Mandate was accepted by the customer.
sig { returns(String) }
attr_accessor :ip_address
# The user agent of the browser from which the Mandate was accepted by the customer.
sig { returns(String) }
attr_accessor :user_agent
sig { params(ip_address: String, user_agent: String).void }
def initialize(ip_address: nil, user_agent: nil); end
end
# The time at which the customer accepted the Mandate.
sig { returns(T.nilable(Integer)) }
attr_accessor :accepted_at
# If this is a Mandate accepted offline, this hash contains details about the offline acceptance.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::MandateData::CustomerAcceptance::Offline))
}
attr_accessor :offline
# If this is a Mandate accepted online, this hash contains details about the online acceptance.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::MandateData::CustomerAcceptance::Online))
}
attr_accessor :online
# The type of customer acceptance information included with the Mandate. One of `online` or `offline`.
sig { returns(String) }
attr_accessor :type
sig {
params(accepted_at: T.nilable(Integer), offline: T.nilable(::Stripe::PaymentIntentService::CreateParams::MandateData::CustomerAcceptance::Offline), online: T.nilable(::Stripe::PaymentIntentService::CreateParams::MandateData::CustomerAcceptance::Online), type: String).void
}
def initialize(accepted_at: nil, offline: nil, online: nil, type: nil); end
end
# This hash contains details about the customer acceptance of the Mandate.
sig {
returns(::Stripe::PaymentIntentService::CreateParams::MandateData::CustomerAcceptance)
}
attr_accessor :customer_acceptance
sig {
params(customer_acceptance: ::Stripe::PaymentIntentService::CreateParams::MandateData::CustomerAcceptance).void
}
def initialize(customer_acceptance: nil); end
end
class PaymentDetails < Stripe::RequestParams
class CarRental < Stripe::RequestParams
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::CarRental::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::CarRental::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
class Distance < Stripe::RequestParams
# Distance traveled.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# Unit of measurement for the distance traveled. One of `miles` or `kilometers`.
sig { returns(T.nilable(String)) }
attr_accessor :unit
sig { params(amount: T.nilable(Integer), unit: T.nilable(String)).void }
def initialize(amount: nil, unit: nil); end
end
class Driver < Stripe::RequestParams
# Driver's identification number.
sig { returns(T.nilable(String)) }
attr_accessor :driver_identification_number
# Driver's tax number.
sig { returns(T.nilable(String)) }
attr_accessor :driver_tax_number
# Full name of the person or entity on the car reservation.
sig { returns(String) }
attr_accessor :name
sig {
params(driver_identification_number: T.nilable(String), driver_tax_number: T.nilable(String), name: String).void
}
def initialize(
driver_identification_number: nil,
driver_tax_number: nil,
name: nil
); end
end
class PickupAddress < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class ReturnAddress < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::CarRental::Affiliate))
}
attr_accessor :affiliate
# The booking number associated with the car rental.
sig { returns(String) }
attr_accessor :booking_number
# Class code of the car.
sig { returns(T.nilable(String)) }
attr_accessor :car_class_code
# Make of the car.
sig { returns(T.nilable(String)) }
attr_accessor :car_make
# Model of the car.
sig { returns(T.nilable(String)) }
attr_accessor :car_model
# The name of the rental car company.
sig { returns(T.nilable(String)) }
attr_accessor :company
# The customer service phone number of the car rental company.
sig { returns(T.nilable(String)) }
attr_accessor :customer_service_phone_number
# Number of days the car is being rented.
sig { returns(Integer) }
attr_accessor :days_rented
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::CarRental::Delivery))
}
attr_accessor :delivery
# The details of the distance traveled during the rental period.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::CarRental::Distance))
}
attr_accessor :distance
# The details of the passengers in the travel reservation
sig {
returns(T.nilable(T::Array[::Stripe::PaymentIntentService::CreateParams::PaymentDetails::CarRental::Driver]))
}
attr_accessor :drivers
# List of additional charges being billed.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :extra_charges
# Indicates if the customer did not keep nor cancel their booking.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :no_show
# Car pick-up address.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::CarRental::PickupAddress))
}
attr_accessor :pickup_address
# Car pick-up time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :pickup_at
# Name of the pickup location.
sig { returns(T.nilable(String)) }
attr_accessor :pickup_location_name
# Rental rate.
sig { returns(T.nilable(Integer)) }
attr_accessor :rate_amount
# The frequency at which the rate amount is applied. One of `day`, `week` or `month`
sig { returns(T.nilable(String)) }
attr_accessor :rate_interval
# The name of the person or entity renting the car.
sig { returns(T.nilable(String)) }
attr_accessor :renter_name
# Car return address.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::CarRental::ReturnAddress))
}
attr_accessor :return_address
# Car return time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :return_at
# Name of the return location.
sig { returns(T.nilable(String)) }
attr_accessor :return_location_name
# Indicates whether the goods or services are tax-exempt or tax is not collected.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :tax_exempt
# The vehicle identification number.
sig { returns(T.nilable(String)) }
attr_accessor :vehicle_identification_number
sig {
params(affiliate: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::CarRental::Affiliate), booking_number: String, car_class_code: T.nilable(String), car_make: T.nilable(String), car_model: T.nilable(String), company: T.nilable(String), customer_service_phone_number: T.nilable(String), days_rented: Integer, delivery: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::CarRental::Delivery), distance: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::CarRental::Distance), drivers: T.nilable(T::Array[::Stripe::PaymentIntentService::CreateParams::PaymentDetails::CarRental::Driver]), extra_charges: T.nilable(T::Array[String]), no_show: T.nilable(T::Boolean), pickup_address: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::CarRental::PickupAddress), pickup_at: Integer, pickup_location_name: T.nilable(String), rate_amount: T.nilable(Integer), rate_interval: T.nilable(String), renter_name: T.nilable(String), return_address: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::CarRental::ReturnAddress), return_at: Integer, return_location_name: T.nilable(String), tax_exempt: T.nilable(T::Boolean), vehicle_identification_number: T.nilable(String)).void
}
def initialize(
affiliate: nil,
booking_number: nil,
car_class_code: nil,
car_make: nil,
car_model: nil,
company: nil,
customer_service_phone_number: nil,
days_rented: nil,
delivery: nil,
distance: nil,
drivers: nil,
extra_charges: nil,
no_show: nil,
pickup_address: nil,
pickup_at: nil,
pickup_location_name: nil,
rate_amount: nil,
rate_interval: nil,
renter_name: nil,
return_address: nil,
return_at: nil,
return_location_name: nil,
tax_exempt: nil,
vehicle_identification_number: nil
); end
end
class EventDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::EventDetails::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::EventDetails::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
# Indicates if the tickets are digitally checked when entering the venue.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :access_controlled_venue
# The event location's address.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::EventDetails::Address))
}
attr_accessor :address
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::EventDetails::Affiliate))
}
attr_accessor :affiliate
# The name of the company
sig { returns(T.nilable(String)) }
attr_accessor :company
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::EventDetails::Delivery))
}
attr_accessor :delivery
# Event end time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :ends_at
# Type of the event entertainment (concert, sports event etc)
sig { returns(T.nilable(String)) }
attr_accessor :genre
# The name of the event.
sig { returns(String) }
attr_accessor :name
# Event start time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :starts_at
sig {
params(access_controlled_venue: T.nilable(T::Boolean), address: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::EventDetails::Address), affiliate: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::EventDetails::Affiliate), company: T.nilable(String), delivery: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::EventDetails::Delivery), ends_at: T.nilable(Integer), genre: T.nilable(String), name: String, starts_at: T.nilable(Integer)).void
}
def initialize(
access_controlled_venue: nil,
address: nil,
affiliate: nil,
company: nil,
delivery: nil,
ends_at: nil,
genre: nil,
name: nil,
starts_at: nil
); end
end
class Flight < Stripe::RequestParams
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::Flight::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::Flight::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
class Passenger < Stripe::RequestParams
# Full name of the person or entity on the flight reservation.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Segment < Stripe::RequestParams
# The flight segment amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# The International Air Transport Association (IATA) airport code for the arrival airport.
sig { returns(T.nilable(String)) }
attr_accessor :arrival_airport
# The arrival time for the flight segment. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :arrives_at
# The International Air Transport Association (IATA) carrier code of the carrier operating the flight segment.
sig { returns(T.nilable(String)) }
attr_accessor :carrier
# The departure time for the flight segment. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :departs_at
# The International Air Transport Association (IATA) airport code for the departure airport.
sig { returns(T.nilable(String)) }
attr_accessor :departure_airport
# The flight number associated with the segment
sig { returns(T.nilable(String)) }
attr_accessor :flight_number
# The fare class for the segment.
sig { returns(T.nilable(String)) }
attr_accessor :service_class
sig {
params(amount: T.nilable(Integer), arrival_airport: T.nilable(String), arrives_at: T.nilable(Integer), carrier: T.nilable(String), departs_at: Integer, departure_airport: T.nilable(String), flight_number: T.nilable(String), service_class: T.nilable(String)).void
}
def initialize(
amount: nil,
arrival_airport: nil,
arrives_at: nil,
carrier: nil,
departs_at: nil,
departure_airport: nil,
flight_number: nil,
service_class: nil
); end
end
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::Flight::Affiliate))
}
attr_accessor :affiliate
# The agency number (i.e. International Air Transport Association (IATA) agency number) of the travel agency that made the booking.
sig { returns(T.nilable(String)) }
attr_accessor :agency_number
# The International Air Transport Association (IATA) carrier code of the carrier that issued the ticket.
sig { returns(T.nilable(String)) }
attr_accessor :carrier
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::Flight::Delivery))
}
attr_accessor :delivery
# The name of the person or entity on the reservation.
sig { returns(T.nilable(String)) }
attr_accessor :passenger_name
# The details of the passengers in the travel reservation.
sig {
returns(T.nilable(T::Array[::Stripe::PaymentIntentService::CreateParams::PaymentDetails::Flight::Passenger]))
}
attr_accessor :passengers
# The individual flight segments associated with the trip.
sig {
returns(T::Array[::Stripe::PaymentIntentService::CreateParams::PaymentDetails::Flight::Segment])
}
attr_accessor :segments
# The ticket number associated with the travel reservation.
sig { returns(T.nilable(String)) }
attr_accessor :ticket_number
sig {
params(affiliate: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::Flight::Affiliate), agency_number: T.nilable(String), carrier: T.nilable(String), delivery: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::Flight::Delivery), passenger_name: T.nilable(String), passengers: T.nilable(T::Array[::Stripe::PaymentIntentService::CreateParams::PaymentDetails::Flight::Passenger]), segments: T::Array[::Stripe::PaymentIntentService::CreateParams::PaymentDetails::Flight::Segment], ticket_number: T.nilable(String)).void
}
def initialize(
affiliate: nil,
agency_number: nil,
carrier: nil,
delivery: nil,
passenger_name: nil,
passengers: nil,
segments: nil,
ticket_number: nil
); end
end
class Lodging < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::Lodging::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::Lodging::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
class Passenger < Stripe::RequestParams
# Full name of the person or entity on the lodging reservation.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
# The lodging location's address.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::Lodging::Address))
}
attr_accessor :address
# The number of adults on the booking
sig { returns(T.nilable(Integer)) }
attr_accessor :adults
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::Lodging::Affiliate))
}
attr_accessor :affiliate
# The booking number associated with the lodging reservation.
sig { returns(T.nilable(String)) }
attr_accessor :booking_number
# The lodging category
sig { returns(T.nilable(String)) }
attr_accessor :category
# Lodging check-in time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :checkin_at
# Lodging check-out time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :checkout_at
# The customer service phone number of the lodging company.
sig { returns(T.nilable(String)) }
attr_accessor :customer_service_phone_number
# The daily lodging room rate.
sig { returns(T.nilable(Integer)) }
attr_accessor :daily_room_rate_amount
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::Lodging::Delivery))
}
attr_accessor :delivery
# List of additional charges being billed.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :extra_charges
# Indicates whether the lodging location is compliant with the Fire Safety Act.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :fire_safety_act_compliance
# The name of the lodging location.
sig { returns(T.nilable(String)) }
attr_accessor :name
# Indicates if the customer did not keep their booking while failing to cancel the reservation.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :no_show
# The number of rooms on the booking
sig { returns(T.nilable(Integer)) }
attr_accessor :number_of_rooms
# The details of the passengers in the travel reservation
sig {
returns(T.nilable(T::Array[::Stripe::PaymentIntentService::CreateParams::PaymentDetails::Lodging::Passenger]))
}
attr_accessor :passengers
# The phone number of the lodging location.
sig { returns(T.nilable(String)) }
attr_accessor :property_phone_number
# The room class for this purchase.
sig { returns(T.nilable(String)) }
attr_accessor :room_class
# The number of room nights
sig { returns(T.nilable(Integer)) }
attr_accessor :room_nights
# The total tax amount associating with the room reservation.
sig { returns(T.nilable(Integer)) }
attr_accessor :total_room_tax_amount
# The total tax amount
sig { returns(T.nilable(Integer)) }
attr_accessor :total_tax_amount
sig {
params(address: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::Lodging::Address), adults: T.nilable(Integer), affiliate: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::Lodging::Affiliate), booking_number: T.nilable(String), category: T.nilable(String), checkin_at: Integer, checkout_at: Integer, customer_service_phone_number: T.nilable(String), daily_room_rate_amount: T.nilable(Integer), delivery: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::Lodging::Delivery), extra_charges: T.nilable(T::Array[String]), fire_safety_act_compliance: T.nilable(T::Boolean), name: T.nilable(String), no_show: T.nilable(T::Boolean), number_of_rooms: T.nilable(Integer), passengers: T.nilable(T::Array[::Stripe::PaymentIntentService::CreateParams::PaymentDetails::Lodging::Passenger]), property_phone_number: T.nilable(String), room_class: T.nilable(String), room_nights: T.nilable(Integer), total_room_tax_amount: T.nilable(Integer), total_tax_amount: T.nilable(Integer)).void
}
def initialize(
address: nil,
adults: nil,
affiliate: nil,
booking_number: nil,
category: nil,
checkin_at: nil,
checkout_at: nil,
customer_service_phone_number: nil,
daily_room_rate_amount: nil,
delivery: nil,
extra_charges: nil,
fire_safety_act_compliance: nil,
name: nil,
no_show: nil,
number_of_rooms: nil,
passengers: nil,
property_phone_number: nil,
room_class: nil,
room_nights: nil,
total_room_tax_amount: nil,
total_tax_amount: nil
); end
end
class Subscription < Stripe::RequestParams
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class BillingInterval < Stripe::RequestParams
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :count
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
sig { params(count: Integer, interval: String).void }
def initialize(count: nil, interval: nil); end
end
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::Subscription::Affiliate))
}
attr_accessor :affiliate
# Info whether the subscription will be auto renewed upon expiry.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :auto_renewal
# Subscription billing details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::Subscription::BillingInterval))
}
attr_accessor :billing_interval
# Subscription end time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :ends_at
# Name of the product on subscription. e.g. Apple Music Subscription
sig { returns(String) }
attr_accessor :name
# Subscription start time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :starts_at
sig {
params(affiliate: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::Subscription::Affiliate), auto_renewal: T.nilable(T::Boolean), billing_interval: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::Subscription::BillingInterval), ends_at: T.nilable(Integer), name: String, starts_at: T.nilable(Integer)).void
}
def initialize(
affiliate: nil,
auto_renewal: nil,
billing_interval: nil,
ends_at: nil,
name: nil,
starts_at: nil
); end
end
# Car rental details for this PaymentIntent.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::CarRental))
}
attr_accessor :car_rental
# Some customers might be required by their company or organization to provide this information. If so, provide this value. Otherwise you can ignore this field.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :customer_reference
# Event details for this PaymentIntent
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::EventDetails))
}
attr_accessor :event_details
# Flight reservation details for this PaymentIntent
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::Flight))
}
attr_accessor :flight
# Lodging reservation details for this PaymentIntent
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::Lodging))
}
attr_accessor :lodging
# A unique value assigned by the business to identify the transaction.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :order_reference
# Subscription details for this PaymentIntent
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::Subscription))
}
attr_accessor :subscription
sig {
params(car_rental: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::CarRental), customer_reference: T.nilable(T.nilable(String)), event_details: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::EventDetails), flight: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::Flight), lodging: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::Lodging), order_reference: T.nilable(T.nilable(String)), subscription: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails::Subscription)).void
}
def initialize(
car_rental: nil,
customer_reference: nil,
event_details: nil,
flight: nil,
lodging: nil,
order_reference: nil,
subscription: nil
); end
end
class PaymentMethodData < Stripe::RequestParams
class AcssDebit < Stripe::RequestParams
# Customer's bank account number.
sig { returns(String) }
attr_accessor :account_number
# Institution number of the customer's bank.
sig { returns(String) }
attr_accessor :institution_number
# Transit number of the customer's bank.
sig { returns(String) }
attr_accessor :transit_number
sig {
params(account_number: String, institution_number: String, transit_number: String).void
}
def initialize(account_number: nil, institution_number: nil, transit_number: nil); end
end
class Affirm < Stripe::RequestParams; end
class AfterpayClearpay < Stripe::RequestParams; end
class Alipay < Stripe::RequestParams; end
class Alma < Stripe::RequestParams; end
class AmazonPay < Stripe::RequestParams; end
class AuBecsDebit < Stripe::RequestParams
# The account number for the bank account.
sig { returns(String) }
attr_accessor :account_number
# Bank-State-Branch number of the bank account.
sig { returns(String) }
attr_accessor :bsb_number
sig { params(account_number: String, bsb_number: String).void }
def initialize(account_number: nil, bsb_number: nil); end
end
class BacsDebit < Stripe::RequestParams
# Account number of the bank account that the funds will be debited from.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Sort code of the bank account. (e.g., `10-20-30`)
sig { returns(T.nilable(String)) }
attr_accessor :sort_code
sig { params(account_number: T.nilable(String), sort_code: T.nilable(String)).void }
def initialize(account_number: nil, sort_code: nil); end
end
class Bancontact < Stripe::RequestParams; end
class Billie < Stripe::RequestParams; end
class BillingDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Billing address.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::BillingDetails::Address))))
}
attr_accessor :address
# Email address.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :email
# Full name.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :name
# Billing phone number (including extension).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :phone
# Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
sig { returns(T.nilable(String)) }
attr_accessor :tax_id
sig {
params(address: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::BillingDetails::Address))), email: T.nilable(T.nilable(String)), name: T.nilable(T.nilable(String)), phone: T.nilable(T.nilable(String)), tax_id: T.nilable(String)).void
}
def initialize(address: nil, email: nil, name: nil, phone: nil, tax_id: nil); end
end
class Blik < Stripe::RequestParams; end
class Boleto < Stripe::RequestParams
# The tax ID of the customer (CPF for individual consumers or CNPJ for businesses consumers)
sig { returns(String) }
attr_accessor :tax_id
sig { params(tax_id: String).void }
def initialize(tax_id: nil); end
end
class Cashapp < Stripe::RequestParams; end
class CustomerBalance < Stripe::RequestParams; end
class Eps < Stripe::RequestParams
# The customer's bank.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class Fpx < Stripe::RequestParams
# Account holder type for FPX transaction
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_type
# The customer's bank.
sig { returns(String) }
attr_accessor :bank
sig { params(account_holder_type: T.nilable(String), bank: String).void }
def initialize(account_holder_type: nil, bank: nil); end
end
class Giropay < Stripe::RequestParams; end
class Gopay < Stripe::RequestParams; end
class Grabpay < Stripe::RequestParams; end
class IdBankTransfer < Stripe::RequestParams
# Bank where the account is held.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class Ideal < Stripe::RequestParams
# The customer's bank. Only use this parameter for existing customers. Don't use it for new customers.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class InteracPresent < Stripe::RequestParams; end
class KakaoPay < Stripe::RequestParams; end
class Klarna < Stripe::RequestParams
class Dob < Stripe::RequestParams
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
# Customer's date of birth
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Klarna::Dob))
}
attr_accessor :dob
sig {
params(dob: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Klarna::Dob)).void
}
def initialize(dob: nil); end
end
class Konbini < Stripe::RequestParams; end
class KrCard < Stripe::RequestParams; end
class Link < Stripe::RequestParams; end
class MbWay < Stripe::RequestParams; end
class Mobilepay < Stripe::RequestParams; end
class Multibanco < Stripe::RequestParams; end
class NaverPay < Stripe::RequestParams
# Whether to use Naver Pay points or a card to fund this transaction. If not provided, this defaults to `card`.
sig { returns(T.nilable(String)) }
attr_accessor :funding
sig { params(funding: T.nilable(String)).void }
def initialize(funding: nil); end
end
class NzBankAccount < Stripe::RequestParams
# The name on the bank account. Only required if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod’s billing details.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_name
# The account number for the bank account.
sig { returns(String) }
attr_accessor :account_number
# The numeric code for the bank account's bank.
sig { returns(String) }
attr_accessor :bank_code
# The numeric code for the bank account's bank branch.
sig { returns(String) }
attr_accessor :branch_code
# Attribute for param field reference
sig { returns(T.nilable(String)) }
attr_accessor :reference
# The suffix of the bank account number.
sig { returns(String) }
attr_accessor :suffix
sig {
params(account_holder_name: T.nilable(String), account_number: String, bank_code: String, branch_code: String, reference: T.nilable(String), suffix: String).void
}
def initialize(
account_holder_name: nil,
account_number: nil,
bank_code: nil,
branch_code: nil,
reference: nil,
suffix: nil
); end
end
class Oxxo < Stripe::RequestParams; end
class P24 < Stripe::RequestParams
# The customer's bank.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class PayByBank < Stripe::RequestParams; end
class Payco < Stripe::RequestParams; end
class Paynow < Stripe::RequestParams; end
class Paypal < Stripe::RequestParams; end
class Payto < Stripe::RequestParams
# The account number for the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Bank-State-Branch number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :bsb_number
# The PayID alias for the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :pay_id
sig {
params(account_number: T.nilable(String), bsb_number: T.nilable(String), pay_id: T.nilable(String)).void
}
def initialize(account_number: nil, bsb_number: nil, pay_id: nil); end
end
class Pix < Stripe::RequestParams; end
class Promptpay < Stripe::RequestParams; end
class Qris < Stripe::RequestParams; end
class RadarOptions < Stripe::RequestParams
# A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
sig { returns(T.nilable(String)) }
attr_accessor :session
sig { params(session: T.nilable(String)).void }
def initialize(session: nil); end
end
class Rechnung < Stripe::RequestParams
class Dob < Stripe::RequestParams
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
# Customer's date of birth
sig {
returns(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Rechnung::Dob)
}
attr_accessor :dob
sig {
params(dob: ::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Rechnung::Dob).void
}
def initialize(dob: nil); end
end
class RevolutPay < Stripe::RequestParams; end
class SamsungPay < Stripe::RequestParams; end
class Satispay < Stripe::RequestParams; end
class SepaDebit < Stripe::RequestParams
# IBAN of the bank account.
sig { returns(String) }
attr_accessor :iban
sig { params(iban: String).void }
def initialize(iban: nil); end
end
class Shopeepay < Stripe::RequestParams; end
class Sofort < Stripe::RequestParams
# Two-letter ISO code representing the country the bank account is located in.
sig { returns(String) }
attr_accessor :country
sig { params(country: String).void }
def initialize(country: nil); end
end
class StripeBalance < Stripe::RequestParams
# The connected account ID whose Stripe balance to use as the source of payment
sig { returns(T.nilable(String)) }
attr_accessor :account
# The [source_type](https://docs.stripe.com/api/balance/balance_object#balance_object-available-source_types) of the balance
sig { returns(T.nilable(String)) }
attr_accessor :source_type
sig { params(account: T.nilable(String), source_type: T.nilable(String)).void }
def initialize(account: nil, source_type: nil); end
end
class Swish < Stripe::RequestParams; end
class Twint < Stripe::RequestParams; end
class UsBankAccount < Stripe::RequestParams
# Account holder type: individual or company.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_type
# Account number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Account type: checkings or savings. Defaults to checking if omitted.
sig { returns(T.nilable(String)) }
attr_accessor :account_type
# The ID of a Financial Connections Account to use as a payment method.
sig { returns(T.nilable(String)) }
attr_accessor :financial_connections_account
# Routing number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :routing_number
sig {
params(account_holder_type: T.nilable(String), account_number: T.nilable(String), account_type: T.nilable(String), financial_connections_account: T.nilable(String), routing_number: T.nilable(String)).void
}
def initialize(
account_holder_type: nil,
account_number: nil,
account_type: nil,
financial_connections_account: nil,
routing_number: nil
); end
end
class WechatPay < Stripe::RequestParams; end
class Zip < Stripe::RequestParams; end
# If this is an `acss_debit` PaymentMethod, this hash contains details about the ACSS Debit payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::AcssDebit))
}
attr_accessor :acss_debit
# If this is an `affirm` PaymentMethod, this hash contains details about the Affirm payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Affirm))
}
attr_accessor :affirm
# If this is an `AfterpayClearpay` PaymentMethod, this hash contains details about the AfterpayClearpay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::AfterpayClearpay))
}
attr_accessor :afterpay_clearpay
# If this is an `Alipay` PaymentMethod, this hash contains details about the Alipay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Alipay))
}
attr_accessor :alipay
# This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :allow_redisplay
# If this is a Alma PaymentMethod, this hash contains details about the Alma payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Alma))
}
attr_accessor :alma
# If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::AmazonPay))
}
attr_accessor :amazon_pay
# If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::AuBecsDebit))
}
attr_accessor :au_becs_debit
# If this is a `bacs_debit` PaymentMethod, this hash contains details about the Bacs Direct Debit bank account.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::BacsDebit))
}
attr_accessor :bacs_debit
# If this is a `bancontact` PaymentMethod, this hash contains details about the Bancontact payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Bancontact))
}
attr_accessor :bancontact
# If this is a `billie` PaymentMethod, this hash contains details about the Billie payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Billie))
}
attr_accessor :billie
# Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::BillingDetails))
}
attr_accessor :billing_details
# If this is a `blik` PaymentMethod, this hash contains details about the BLIK payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Blik))
}
attr_accessor :blik
# If this is a `boleto` PaymentMethod, this hash contains details about the Boleto payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Boleto))
}
attr_accessor :boleto
# If this is a `cashapp` PaymentMethod, this hash contains details about the Cash App Pay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Cashapp))
}
attr_accessor :cashapp
# If this is a `customer_balance` PaymentMethod, this hash contains details about the CustomerBalance payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::CustomerBalance))
}
attr_accessor :customer_balance
# If this is an `eps` PaymentMethod, this hash contains details about the EPS payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Eps))
}
attr_accessor :eps
# If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Fpx))
}
attr_accessor :fpx
# If this is a `giropay` PaymentMethod, this hash contains details about the Giropay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Giropay))
}
attr_accessor :giropay
# If this is a Gopay PaymentMethod, this hash contains details about the Gopay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Gopay))
}
attr_accessor :gopay
# If this is a `grabpay` PaymentMethod, this hash contains details about the GrabPay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Grabpay))
}
attr_accessor :grabpay
# If this is an `IdBankTransfer` PaymentMethod, this hash contains details about the IdBankTransfer payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::IdBankTransfer))
}
attr_accessor :id_bank_transfer
# If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Ideal))
}
attr_accessor :ideal
# If this is an `interac_present` PaymentMethod, this hash contains details about the Interac Present payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::InteracPresent))
}
attr_accessor :interac_present
# If this is a `kakao_pay` PaymentMethod, this hash contains details about the Kakao Pay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::KakaoPay))
}
attr_accessor :kakao_pay
# If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Klarna))
}
attr_accessor :klarna
# If this is a `konbini` PaymentMethod, this hash contains details about the Konbini payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Konbini))
}
attr_accessor :konbini
# If this is a `kr_card` PaymentMethod, this hash contains details about the Korean Card payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::KrCard))
}
attr_accessor :kr_card
# If this is an `Link` PaymentMethod, this hash contains details about the Link payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Link))
}
attr_accessor :link
# If this is a MB WAY PaymentMethod, this hash contains details about the MB WAY payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::MbWay))
}
attr_accessor :mb_way
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# If this is a `mobilepay` PaymentMethod, this hash contains details about the MobilePay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Mobilepay))
}
attr_accessor :mobilepay
# If this is a `multibanco` PaymentMethod, this hash contains details about the Multibanco payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Multibanco))
}
attr_accessor :multibanco
# If this is a `naver_pay` PaymentMethod, this hash contains details about the Naver Pay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::NaverPay))
}
attr_accessor :naver_pay
# If this is an nz_bank_account PaymentMethod, this hash contains details about the nz_bank_account payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::NzBankAccount))
}
attr_accessor :nz_bank_account
# If this is an `oxxo` PaymentMethod, this hash contains details about the OXXO payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Oxxo))
}
attr_accessor :oxxo
# If this is a `p24` PaymentMethod, this hash contains details about the P24 payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::P24))
}
attr_accessor :p24
# If this is a `pay_by_bank` PaymentMethod, this hash contains details about the PayByBank payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::PayByBank))
}
attr_accessor :pay_by_bank
# If this is a `payco` PaymentMethod, this hash contains details about the PAYCO payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Payco))
}
attr_accessor :payco
# If this is a `paynow` PaymentMethod, this hash contains details about the PayNow payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Paynow))
}
attr_accessor :paynow
# If this is a `paypal` PaymentMethod, this hash contains details about the PayPal payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Paypal))
}
attr_accessor :paypal
# If this is a `payto` PaymentMethod, this hash contains details about the PayTo payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Payto))
}
attr_accessor :payto
# If this is a `pix` PaymentMethod, this hash contains details about the Pix payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Pix))
}
attr_accessor :pix
# If this is a `promptpay` PaymentMethod, this hash contains details about the PromptPay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Promptpay))
}
attr_accessor :promptpay
# If this is a `qris` PaymentMethod, this hash contains details about the QRIS payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Qris))
}
attr_accessor :qris
# Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::RadarOptions))
}
attr_accessor :radar_options
# If this is a `rechnung` PaymentMethod, this hash contains details about the Rechnung payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Rechnung))
}
attr_accessor :rechnung
# If this is a `revolut_pay` PaymentMethod, this hash contains details about the Revolut Pay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::RevolutPay))
}
attr_accessor :revolut_pay
# If this is a `samsung_pay` PaymentMethod, this hash contains details about the SamsungPay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::SamsungPay))
}
attr_accessor :samsung_pay
# If this is a `satispay` PaymentMethod, this hash contains details about the Satispay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Satispay))
}
attr_accessor :satispay
# If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::SepaDebit))
}
attr_accessor :sepa_debit
# If this is a Shopeepay PaymentMethod, this hash contains details about the Shopeepay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Shopeepay))
}
attr_accessor :shopeepay
# If this is a `sofort` PaymentMethod, this hash contains details about the SOFORT payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Sofort))
}
attr_accessor :sofort
# This hash contains details about the Stripe balance payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::StripeBalance))
}
attr_accessor :stripe_balance
# If this is a `swish` PaymentMethod, this hash contains details about the Swish payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Swish))
}
attr_accessor :swish
# If this is a TWINT PaymentMethod, this hash contains details about the TWINT payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Twint))
}
attr_accessor :twint
# The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
sig { returns(String) }
attr_accessor :type
# If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::UsBankAccount))
}
attr_accessor :us_bank_account
# If this is an `wechat_pay` PaymentMethod, this hash contains details about the wechat_pay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::WechatPay))
}
attr_accessor :wechat_pay
# If this is a `zip` PaymentMethod, this hash contains details about the Zip payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Zip))
}
attr_accessor :zip
sig {
params(acss_debit: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::AcssDebit), affirm: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Affirm), afterpay_clearpay: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::AfterpayClearpay), alipay: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Alipay), allow_redisplay: T.nilable(String), alma: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Alma), amazon_pay: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::AmazonPay), au_becs_debit: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::AuBecsDebit), bacs_debit: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::BacsDebit), bancontact: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Bancontact), billie: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Billie), billing_details: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::BillingDetails), blik: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Blik), boleto: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Boleto), cashapp: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Cashapp), customer_balance: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::CustomerBalance), eps: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Eps), fpx: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Fpx), giropay: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Giropay), gopay: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Gopay), grabpay: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Grabpay), id_bank_transfer: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::IdBankTransfer), ideal: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Ideal), interac_present: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::InteracPresent), kakao_pay: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::KakaoPay), klarna: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Klarna), konbini: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Konbini), kr_card: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::KrCard), link: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Link), mb_way: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::MbWay), metadata: T.nilable(T::Hash[String, String]), mobilepay: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Mobilepay), multibanco: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Multibanco), naver_pay: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::NaverPay), nz_bank_account: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::NzBankAccount), oxxo: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Oxxo), p24: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::P24), pay_by_bank: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::PayByBank), payco: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Payco), paynow: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Paynow), paypal: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Paypal), payto: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Payto), pix: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Pix), promptpay: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Promptpay), qris: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Qris), radar_options: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::RadarOptions), rechnung: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Rechnung), revolut_pay: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::RevolutPay), samsung_pay: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::SamsungPay), satispay: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Satispay), sepa_debit: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::SepaDebit), shopeepay: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Shopeepay), sofort: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Sofort), stripe_balance: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::StripeBalance), swish: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Swish), twint: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Twint), type: String, us_bank_account: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::UsBankAccount), wechat_pay: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::WechatPay), zip: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData::Zip)).void
}
def initialize(
acss_debit: nil,
affirm: nil,
afterpay_clearpay: nil,
alipay: nil,
allow_redisplay: nil,
alma: nil,
amazon_pay: nil,
au_becs_debit: nil,
bacs_debit: nil,
bancontact: nil,
billie: nil,
billing_details: nil,
blik: nil,
boleto: nil,
cashapp: nil,
customer_balance: nil,
eps: nil,
fpx: nil,
giropay: nil,
gopay: nil,
grabpay: nil,
id_bank_transfer: nil,
ideal: nil,
interac_present: nil,
kakao_pay: nil,
klarna: nil,
konbini: nil,
kr_card: nil,
link: nil,
mb_way: nil,
metadata: nil,
mobilepay: nil,
multibanco: nil,
naver_pay: nil,
nz_bank_account: nil,
oxxo: nil,
p24: nil,
pay_by_bank: nil,
payco: nil,
paynow: nil,
paypal: nil,
payto: nil,
pix: nil,
promptpay: nil,
qris: nil,
radar_options: nil,
rechnung: nil,
revolut_pay: nil,
samsung_pay: nil,
satispay: nil,
sepa_debit: nil,
shopeepay: nil,
sofort: nil,
stripe_balance: nil,
swish: nil,
twint: nil,
type: nil,
us_bank_account: nil,
wechat_pay: nil,
zip: nil
); end
end
class PaymentMethodOptions < Stripe::RequestParams
class AcssDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# A URL for custom mandate text to render during confirmation step.
# The URL will be rendered with additional GET parameters `payment_intent` and `payment_intent_client_secret` when confirming a Payment Intent,
# or `setup_intent` and `setup_intent_client_secret` when confirming a Setup Intent.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :custom_mandate_url
# Description of the mandate interval. Only required if 'payment_schedule' parameter is 'interval' or 'combined'.
sig { returns(T.nilable(String)) }
attr_accessor :interval_description
# Payment schedule for the mandate.
sig { returns(T.nilable(String)) }
attr_accessor :payment_schedule
# Transaction type of the mandate.
sig { returns(T.nilable(String)) }
attr_accessor :transaction_type
sig {
params(custom_mandate_url: T.nilable(T.nilable(String)), interval_description: T.nilable(String), payment_schedule: T.nilable(String), transaction_type: T.nilable(String)).void
}
def initialize(
custom_mandate_url: nil,
interval_description: nil,
payment_schedule: nil,
transaction_type: nil
); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::AcssDebit::MandateOptions))
}
attr_accessor :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
# Bank account verification method.
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(mandate_options: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::AcssDebit::MandateOptions), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), target_date: T.nilable(String), verification_method: T.nilable(String)).void
}
def initialize(
mandate_options: nil,
setup_future_usage: nil,
target_date: nil,
verification_method: nil
); end
end
class Affirm < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Preferred language of the Affirm authorization page that the customer is redirected to.
sig { returns(T.nilable(String)) }
attr_accessor :preferred_locale
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), preferred_locale: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(capture_method: nil, preferred_locale: nil, setup_future_usage: nil); end
end
class AfterpayClearpay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# An internal identifier or reference that this payment corresponds to. You must limit the identifier to 128 characters, and it can only contain letters, numbers, underscores, backslashes, and dashes.
# This field differs from the statement descriptor and item name.
sig { returns(T.nilable(String)) }
attr_accessor :reference
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), reference: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(capture_method: nil, reference: nil, setup_future_usage: nil); end
end
class Alipay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void }
def initialize(setup_future_usage: nil); end
end
class Alma < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
sig { params(capture_method: T.nilable(T.nilable(String))).void }
def initialize(capture_method: nil); end
end
class AmazonPay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class AuBecsDebit < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
sig {
params(setup_future_usage: T.nilable(T.nilable(T.any(String, String))), target_date: T.nilable(String)).void
}
def initialize(setup_future_usage: nil, target_date: nil); end
end
class BacsDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'DDIC' or 'STRIPE'.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :reference_prefix
sig { params(reference_prefix: T.nilable(T.nilable(String))).void }
def initialize(reference_prefix: nil); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::BacsDebit::MandateOptions))
}
attr_accessor :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
sig {
params(mandate_options: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::BacsDebit::MandateOptions), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), target_date: T.nilable(String)).void
}
def initialize(mandate_options: nil, setup_future_usage: nil, target_date: nil); end
end
class Bancontact < Stripe::RequestParams
# Preferred language of the Bancontact authorization page that the customer is redirected to.
sig { returns(T.nilable(String)) }
attr_accessor :preferred_language
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(preferred_language: T.nilable(String), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(preferred_language: nil, setup_future_usage: nil); end
end
class Billie < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
sig { params(capture_method: T.nilable(T.nilable(String))).void }
def initialize(capture_method: nil); end
end
class Blik < Stripe::RequestParams
# The 6-digit BLIK code that a customer has generated using their banking application. Can only be set on confirmation.
sig { returns(T.nilable(String)) }
attr_accessor :code
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :setup_future_usage
sig {
params(code: T.nilable(String), setup_future_usage: T.nilable(T.nilable(String))).void
}
def initialize(code: nil, setup_future_usage: nil); end
end
class Boleto < Stripe::RequestParams
# The number of calendar days before a Boleto voucher expires. For example, if you create a Boleto voucher on Monday and you set expires_after_days to 2, the Boleto invoice will expire on Wednesday at 23:59 America/Sao_Paulo time.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_after_days
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(expires_after_days: T.nilable(Integer), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(expires_after_days: nil, setup_future_usage: nil); end
end
class Card < Stripe::RequestParams
class Installments < Stripe::RequestParams
class Plan < Stripe::RequestParams
# For `fixed_count` installment plans, this is required. It represents the number of installment payments your customer will make to their credit card.
sig { returns(T.nilable(Integer)) }
attr_accessor :count
# For `fixed_count` installment plans, this is required. It represents the interval between installment payments your customer will make to their credit card.
# One of `month`.
sig { returns(T.nilable(String)) }
attr_accessor :interval
# Type of installment plan, one of `fixed_count`.
sig { returns(String) }
attr_accessor :type
sig {
params(count: T.nilable(Integer), interval: T.nilable(String), type: String).void
}
def initialize(count: nil, interval: nil, type: nil); end
end
# Setting to true enables installments for this PaymentIntent.
# This will cause the response to contain a list of available installment plans.
# Setting to false will prevent any selected plan from applying to a charge.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :enabled
# The selected installment plan to use for this payment attempt.
# This parameter can only be provided during confirmation.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Card::Installments::Plan))))
}
attr_accessor :plan
sig {
params(enabled: T.nilable(T::Boolean), plan: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Card::Installments::Plan)))).void
}
def initialize(enabled: nil, plan: nil); end
end
class MandateOptions < Stripe::RequestParams
# Amount to be charged for future payments.
sig { returns(Integer) }
attr_accessor :amount
# One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.
sig { returns(String) }
attr_accessor :amount_type
# A description of the mandate or subscription that is meant to be displayed to the customer.
sig { returns(T.nilable(String)) }
attr_accessor :description
# End date of the mandate or subscription. If not provided, the mandate will be active until canceled. If provided, end date should be after start date.
sig { returns(T.nilable(Integer)) }
attr_accessor :end_date
# Specifies payment frequency. One of `day`, `week`, `month`, `year`, or `sporadic`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals between payments. For example, `interval=month` and `interval_count=3` indicates one payment every three months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks). This parameter is optional when `interval=sporadic`.
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_count
# Unique identifier for the mandate or subscription.
sig { returns(String) }
attr_accessor :reference
# Start date of the mandate or subscription. Start date should not be lesser than yesterday.
sig { returns(Integer) }
attr_accessor :start_date
# Specifies the type of mandates supported. Possible values are `india`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :supported_types
sig {
params(amount: Integer, amount_type: String, description: T.nilable(String), end_date: T.nilable(Integer), interval: String, interval_count: T.nilable(Integer), reference: String, start_date: Integer, supported_types: T.nilable(T::Array[String])).void
}
def initialize(
amount: nil,
amount_type: nil,
description: nil,
end_date: nil,
interval: nil,
interval_count: nil,
reference: nil,
start_date: nil,
supported_types: nil
); end
end
class StatementDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Please pass in an address that is within your Stripe user account country
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Card::StatementDetails::Address))
}
attr_accessor :address
# Phone number (e.g., a toll-free number that customers can call)
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(address: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Card::StatementDetails::Address), phone: T.nilable(String)).void
}
def initialize(address: nil, phone: nil); end
end
class ThreeDSecure < Stripe::RequestParams
class NetworkOptions < Stripe::RequestParams
class CartesBancaires < Stripe::RequestParams
# The cryptogram calculation algorithm used by the card Issuer's ACS
# to calculate the Authentication cryptogram. Also known as `cavvAlgorithm`.
# messageExtension: CB-AVALGO
sig { returns(String) }
attr_accessor :cb_avalgo
# The exemption indicator returned from Cartes Bancaires in the ARes.
# message extension: CB-EXEMPTION; string (4 characters)
# This is a 3 byte bitmap (low significant byte first and most significant
# bit first) that has been Base64 encoded
sig { returns(T.nilable(String)) }
attr_accessor :cb_exemption
# The risk score returned from Cartes Bancaires in the ARes.
# message extension: CB-SCORE; numeric value 0-99
sig { returns(T.nilable(Integer)) }
attr_accessor :cb_score
sig {
params(cb_avalgo: String, cb_exemption: T.nilable(String), cb_score: T.nilable(Integer)).void
}
def initialize(cb_avalgo: nil, cb_exemption: nil, cb_score: nil); end
end
# Cartes Bancaires-specific 3DS fields.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions::CartesBancaires))
}
attr_accessor :cartes_bancaires
sig {
params(cartes_bancaires: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions::CartesBancaires)).void
}
def initialize(cartes_bancaires: nil); end
end
# The `transStatus` returned from the card Issuer’s ACS in the ARes.
sig { returns(T.nilable(String)) }
attr_accessor :ares_trans_status
# The cryptogram, also known as the "authentication value" (AAV, CAVV or
# AEVV). This value is 20 bytes, base64-encoded into a 28-character string.
# (Most 3D Secure providers will return the base64-encoded version, which
# is what you should specify here.)
sig { returns(String) }
attr_accessor :cryptogram
# The Electronic Commerce Indicator (ECI) is returned by your 3D Secure
# provider and indicates what degree of authentication was performed.
sig { returns(T.nilable(String)) }
attr_accessor :electronic_commerce_indicator
# The exemption requested via 3DS and accepted by the issuer at authentication time.
sig { returns(T.nilable(String)) }
attr_accessor :exemption_indicator
# Network specific 3DS fields. Network specific arguments require an
# explicit card brand choice. The parameter `payment_method_options.card.network``
# must be populated accordingly
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions))
}
attr_accessor :network_options
# The challenge indicator (`threeDSRequestorChallengeInd`) which was requested in the
# AReq sent to the card Issuer's ACS. A string containing 2 digits from 01-99.
sig { returns(T.nilable(String)) }
attr_accessor :requestor_challenge_indicator
# For 3D Secure 1, the XID. For 3D Secure 2, the Directory Server
# Transaction ID (dsTransID).
sig { returns(String) }
attr_accessor :transaction_id
# The version of 3D Secure that was performed.
sig { returns(String) }
attr_accessor :version
sig {
params(ares_trans_status: T.nilable(String), cryptogram: String, electronic_commerce_indicator: T.nilable(String), exemption_indicator: T.nilable(String), network_options: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions), requestor_challenge_indicator: T.nilable(String), transaction_id: String, version: String).void
}
def initialize(
ares_trans_status: nil,
cryptogram: nil,
electronic_commerce_indicator: nil,
exemption_indicator: nil,
network_options: nil,
requestor_challenge_indicator: nil,
transaction_id: nil,
version: nil
); end
end
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# A single-use `cvc_update` Token that represents a card CVC value. When provided, the CVC value will be verified during the card payment attempt. This parameter can only be provided during confirmation.
sig { returns(T.nilable(String)) }
attr_accessor :cvc_token
# Installment configuration for payments attempted on this PaymentIntent (Mexico Only).
#
# For more information, see the [installments integration guide](https://stripe.com/docs/payments/installments).
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Card::Installments))
}
attr_accessor :installments
# Configuration options for setting up an eMandate for cards issued in India.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Card::MandateOptions))
}
attr_accessor :mandate_options
# When specified, this parameter indicates that a transaction will be marked
# as MOTO (Mail Order Telephone Order) and thus out of scope for SCA. This
# parameter can only be provided during confirmation.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :moto
# Selected network to process this PaymentIntent on. Depends on the available networks of the card attached to the PaymentIntent. Can be only set confirm-time.
sig { returns(T.nilable(String)) }
attr_accessor :network
# Request ability to [decrement the authorization](https://stripe.com/docs/payments/decremental-authorization) for this PaymentIntent.
sig { returns(T.nilable(String)) }
attr_accessor :request_decremental_authorization
# Request ability to [capture beyond the standard authorization validity window](https://stripe.com/docs/payments/extended-authorization) for this PaymentIntent.
sig { returns(T.nilable(String)) }
attr_accessor :request_extended_authorization
# Request ability to [increment the authorization](https://stripe.com/docs/payments/incremental-authorization) for this PaymentIntent.
sig { returns(T.nilable(String)) }
attr_accessor :request_incremental_authorization
# Request ability to make [multiple captures](https://stripe.com/docs/payments/multicapture) for this PaymentIntent.
sig { returns(T.nilable(String)) }
attr_accessor :request_multicapture
# Request ability to [overcapture](https://stripe.com/docs/payments/overcapture) for this PaymentIntent.
sig { returns(T.nilable(String)) }
attr_accessor :request_overcapture
# Request partial authorization on this PaymentIntent.
sig { returns(T.nilable(String)) }
attr_accessor :request_partial_authorization
# We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. If not provided, this value defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
sig { returns(T.nilable(String)) }
attr_accessor :request_three_d_secure
# When enabled, using a card that is attached to a customer will require the CVC to be provided again (i.e. using the cvc_token parameter).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :require_cvc_recollection
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Provides information about a card payment that customers see on their statements. Concatenated with the Kana prefix (shortened Kana descriptor) or Kana statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 22 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 22 characters.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :statement_descriptor_suffix_kana
# Provides information about a card payment that customers see on their statements. Concatenated with the Kanji prefix (shortened Kanji descriptor) or Kanji statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 17 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 17 characters.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :statement_descriptor_suffix_kanji
# Statement details for this payment intent. You can use this to override the merchant details shown on your customers' statements.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Card::StatementDetails))))
}
attr_accessor :statement_details
# If 3D Secure authentication was performed with a third-party provider,
# the authentication details to use for this payment.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Card::ThreeDSecure))
}
attr_accessor :three_d_secure
sig {
params(capture_method: T.nilable(T.nilable(String)), cvc_token: T.nilable(String), installments: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Card::Installments), mandate_options: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Card::MandateOptions), moto: T.nilable(T::Boolean), network: T.nilable(String), request_decremental_authorization: T.nilable(String), request_extended_authorization: T.nilable(String), request_incremental_authorization: T.nilable(String), request_multicapture: T.nilable(String), request_overcapture: T.nilable(String), request_partial_authorization: T.nilable(String), request_three_d_secure: T.nilable(String), require_cvc_recollection: T.nilable(T::Boolean), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), statement_descriptor_suffix_kana: T.nilable(T.nilable(String)), statement_descriptor_suffix_kanji: T.nilable(T.nilable(String)), statement_details: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Card::StatementDetails))), three_d_secure: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Card::ThreeDSecure)).void
}
def initialize(
capture_method: nil,
cvc_token: nil,
installments: nil,
mandate_options: nil,
moto: nil,
network: nil,
request_decremental_authorization: nil,
request_extended_authorization: nil,
request_incremental_authorization: nil,
request_multicapture: nil,
request_overcapture: nil,
request_partial_authorization: nil,
request_three_d_secure: nil,
require_cvc_recollection: nil,
setup_future_usage: nil,
statement_descriptor_suffix_kana: nil,
statement_descriptor_suffix_kanji: nil,
statement_details: nil,
three_d_secure: nil
); end
end
class CardPresent < Stripe::RequestParams
class Routing < Stripe::RequestParams
# Routing requested priority
sig { returns(T.nilable(String)) }
attr_accessor :requested_priority
sig { params(requested_priority: T.nilable(String)).void }
def initialize(requested_priority: nil); end
end
# Request ability to capture this payment beyond the standard [authorization validity window](https://stripe.com/docs/terminal/features/extended-authorizations#authorization-validity)
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :request_extended_authorization
# Request ability to [increment](https://stripe.com/docs/terminal/features/incremental-authorizations) this PaymentIntent if the combination of MCC and card brand is eligible. Check [incremental_authorization_supported](https://stripe.com/docs/api/charges/object#charge_object-payment_method_details-card_present-incremental_authorization_supported) in the [Confirm](https://stripe.com/docs/api/payment_intents/confirm) response to verify support.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :request_incremental_authorization_support
# Network routing priority on co-branded EMV cards supporting domestic debit and international card schemes.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::CardPresent::Routing))
}
attr_accessor :routing
sig {
params(request_extended_authorization: T.nilable(T::Boolean), request_incremental_authorization_support: T.nilable(T::Boolean), routing: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::CardPresent::Routing)).void
}
def initialize(
request_extended_authorization: nil,
request_incremental_authorization_support: nil,
routing: nil
); end
end
class Cashapp < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class CustomerBalance < Stripe::RequestParams
class BankTransfer < Stripe::RequestParams
class EuBankTransfer < Stripe::RequestParams
# The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
sig { returns(String) }
attr_accessor :country
sig { params(country: String).void }
def initialize(country: nil); end
end
# Configuration for the eu_bank_transfer funding type.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::CustomerBalance::BankTransfer::EuBankTransfer))
}
attr_accessor :eu_bank_transfer
# List of address types that should be returned in the financial_addresses response. If not specified, all valid types will be returned.
#
# Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :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`, `mx_bank_transfer`, or `us_bank_transfer`.
sig { returns(String) }
attr_accessor :type
sig {
params(eu_bank_transfer: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::CustomerBalance::BankTransfer::EuBankTransfer), requested_address_types: T.nilable(T::Array[String]), type: String).void
}
def initialize(eu_bank_transfer: nil, requested_address_types: nil, type: nil); end
end
# Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::CustomerBalance::BankTransfer))
}
attr_accessor :bank_transfer
# The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
sig { returns(T.nilable(String)) }
attr_accessor :funding_type
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(bank_transfer: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::CustomerBalance::BankTransfer), funding_type: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(bank_transfer: nil, funding_type: nil, setup_future_usage: nil); end
end
class Eps < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Fpx < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Giropay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Gopay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Grabpay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class IdBankTransfer < Stripe::RequestParams
# The UNIX timestamp until which the virtual bank account is valid. Permitted range is from 5 minutes from now until 31 days from now. If unset, it defaults to 3 days from now.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_after
# The UNIX timestamp until which the virtual bank account is valid. Permitted range is from now until 30 days from now. If unset, it defaults to 1 days from now.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_at
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(expires_after: T.nilable(Integer), expires_at: T.nilable(Integer), setup_future_usage: T.nilable(String)).void
}
def initialize(expires_after: nil, expires_at: nil, setup_future_usage: nil); end
end
class Ideal < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void }
def initialize(setup_future_usage: nil); end
end
class InteracPresent < Stripe::RequestParams; end
class KakaoPay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class Klarna < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Preferred language of the Klarna authorization page that the customer is redirected to
sig { returns(T.nilable(String)) }
attr_accessor :preferred_locale
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), preferred_locale: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(capture_method: nil, preferred_locale: nil, setup_future_usage: nil); end
end
class Konbini < Stripe::RequestParams
# An optional 10 to 11 digit numeric-only string determining the confirmation code at applicable convenience stores. Must not consist of only zeroes and could be rejected in case of insufficient uniqueness. We recommend to use the customer's phone number.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :confirmation_number
# The number of calendar days (between 1 and 60) after which Konbini payment instructions will expire. For example, if a PaymentIntent is confirmed with Konbini and `expires_after_days` set to 2 on Monday JST, the instructions will expire on Wednesday 23:59:59 JST. Defaults to 3 days.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :expires_after_days
# The timestamp at which the Konbini payment instructions will expire. Only one of `expires_after_days` or `expires_at` may be set.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :expires_at
# A product descriptor of up to 22 characters, which will appear to customers at the convenience store.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :product_description
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(confirmation_number: T.nilable(T.nilable(String)), expires_after_days: T.nilable(T.nilable(T.any(String, Integer))), expires_at: T.nilable(T.nilable(T.any(String, Integer))), product_description: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(String)).void
}
def initialize(
confirmation_number: nil,
expires_after_days: nil,
expires_at: nil,
product_description: nil,
setup_future_usage: nil
); end
end
class KrCard < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class Link < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# [Deprecated] This is a legacy parameter that no longer has any function.
sig { returns(T.nilable(String)) }
attr_accessor :persistent_token
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), persistent_token: T.nilable(String), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(capture_method: nil, persistent_token: nil, setup_future_usage: nil); end
end
class MbWay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Mobilepay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(String)).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class Multibanco < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class NaverPay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class NzBankAccount < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
sig {
params(setup_future_usage: T.nilable(T.nilable(T.any(String, String))), target_date: T.nilable(String)).void
}
def initialize(setup_future_usage: nil, target_date: nil); end
end
class Oxxo < Stripe::RequestParams
# The number of calendar days before an OXXO voucher expires. For example, if you create an OXXO voucher on Monday and you set expires_after_days to 2, the OXXO invoice will expire on Wednesday at 23:59 America/Mexico_City time.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_after_days
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(expires_after_days: T.nilable(Integer), setup_future_usage: T.nilable(String)).void
}
def initialize(expires_after_days: nil, setup_future_usage: nil); end
end
class P24 < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
# Confirm that the payer has accepted the P24 terms and conditions.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :tos_shown_and_accepted
sig {
params(setup_future_usage: T.nilable(String), tos_shown_and_accepted: T.nilable(T::Boolean)).void
}
def initialize(setup_future_usage: nil, tos_shown_and_accepted: nil); end
end
class PayByBank < Stripe::RequestParams; end
class Payco < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
sig { params(capture_method: T.nilable(T.nilable(String))).void }
def initialize(capture_method: nil); end
end
class Paynow < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Paypal < Stripe::RequestParams
class LineItem < Stripe::RequestParams
class Tax < Stripe::RequestParams
# The tax for a single unit of the line item in minor units. Cannot be a negative number.
sig { returns(Integer) }
attr_accessor :amount
# The tax behavior for the line item.
sig { returns(String) }
attr_accessor :behavior
sig { params(amount: Integer, behavior: String).void }
def initialize(amount: nil, behavior: nil); end
end
# Type of the line item.
sig { returns(T.nilable(String)) }
attr_accessor :category
# Description of the line item.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Descriptive name of the line item.
sig { returns(String) }
attr_accessor :name
# Quantity of the line item. Must be a positive number.
sig { returns(Integer) }
attr_accessor :quantity
# Client facing stock keeping unit, article number or similar.
sig { returns(T.nilable(String)) }
attr_accessor :sku
# The Stripe account ID of the connected account that sells the item.
sig { returns(T.nilable(String)) }
attr_accessor :sold_by
# The tax information for the line item.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Paypal::LineItem::Tax))
}
attr_accessor :tax
# Price for a single unit of the line item in minor units. Cannot be a negative number.
sig { returns(Integer) }
attr_accessor :unit_amount
sig {
params(category: T.nilable(String), description: T.nilable(String), name: String, quantity: Integer, sku: T.nilable(String), sold_by: T.nilable(String), tax: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Paypal::LineItem::Tax), unit_amount: Integer).void
}
def initialize(
category: nil,
description: nil,
name: nil,
quantity: nil,
sku: nil,
sold_by: nil,
tax: nil,
unit_amount: nil
); end
end
# Controls when the funds will be captured from the customer's account.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# The line items purchased by the customer.
sig {
returns(T.nilable(T::Array[::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Paypal::LineItem]))
}
attr_accessor :line_items
# [Preferred locale](https://stripe.com/docs/payments/paypal/supported-locales) of the PayPal checkout page that the customer is redirected to.
sig { returns(T.nilable(String)) }
attr_accessor :preferred_locale
# A reference of the PayPal transaction visible to customer which is mapped to PayPal's invoice ID. This must be a globally unique ID if you have configured in your PayPal settings to block multiple payments per invoice ID.
sig { returns(T.nilable(String)) }
attr_accessor :reference
# A reference of the PayPal transaction visible to customer which is mapped to PayPal's invoice ID. This must be a globally unique ID if you have configured in your PayPal settings to block multiple payments per invoice ID.
sig { returns(T.nilable(String)) }
attr_accessor :reference_id
# The risk correlation ID for an on-session payment using a saved PayPal payment method.
sig { returns(T.nilable(String)) }
attr_accessor :risk_correlation_id
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# The Stripe connected account IDs of the sellers on the platform for this transaction (optional). Only allowed when [separate charges and transfers](https://stripe.com/docs/connect/separate-charges-and-transfers) are used.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :subsellers
sig {
params(capture_method: T.nilable(T.nilable(String)), line_items: T.nilable(T::Array[::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Paypal::LineItem]), preferred_locale: T.nilable(String), reference: T.nilable(String), reference_id: T.nilable(String), risk_correlation_id: T.nilable(String), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), subsellers: T.nilable(T::Array[String])).void
}
def initialize(
capture_method: nil,
line_items: nil,
preferred_locale: nil,
reference: nil,
reference_id: nil,
risk_correlation_id: nil,
setup_future_usage: nil,
subsellers: nil
); end
end
class Payto < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Amount that will be collected. It is required when `amount_type` is `fixed`.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# The type of amount that will be collected. The amount charged must be exact or up to the value of `amount` param for `fixed` or `maximum` type respectively.
sig { returns(T.nilable(String)) }
attr_accessor :amount_type
# Date, in YYYY-MM-DD format, after which payments will not be collected. Defaults to no end date.
sig { returns(T.nilable(String)) }
attr_accessor :end_date
# The periodicity at which payments will be collected.
sig { returns(T.nilable(String)) }
attr_accessor :payment_schedule
# The number of payments that will be made during a payment period. Defaults to 1 except for when `payment_schedule` is `adhoc`. In that case, it defaults to no limit.
sig { returns(T.nilable(Integer)) }
attr_accessor :payments_per_period
# The purpose for which payments are made. Defaults to retail.
sig { returns(T.nilable(String)) }
attr_accessor :purpose
sig {
params(amount: T.nilable(Integer), amount_type: T.nilable(String), end_date: T.nilable(String), payment_schedule: T.nilable(String), payments_per_period: T.nilable(Integer), purpose: T.nilable(String)).void
}
def initialize(
amount: nil,
amount_type: nil,
end_date: nil,
payment_schedule: nil,
payments_per_period: nil,
purpose: nil
); end
end
# Additional fields for Mandate creation. Only `purpose` field is configurable for PayTo PaymentIntent with `setup_future_usage=none`. Other fields are only applicable to PayTo PaymentIntent with `setup_future_usage=off_session`
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Payto::MandateOptions))
}
attr_accessor :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(mandate_options: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Payto::MandateOptions), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(mandate_options: nil, setup_future_usage: nil); end
end
class Pix < Stripe::RequestParams
# The number of seconds (between 10 and 1209600) after which Pix payment will expire. Defaults to 86400 seconds.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_after_seconds
# The timestamp at which the Pix expires (between 10 and 1209600 seconds in the future). Defaults to 1 day in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_at
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(expires_after_seconds: T.nilable(Integer), expires_at: T.nilable(Integer), setup_future_usage: T.nilable(String)).void
}
def initialize(expires_after_seconds: nil, expires_at: nil, setup_future_usage: nil); end
end
class Promptpay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Qris < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Rechnung < Stripe::RequestParams; end
class RevolutPay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class SamsungPay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
sig { params(capture_method: T.nilable(T.nilable(String))).void }
def initialize(capture_method: nil); end
end
class Satispay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
sig { params(capture_method: T.nilable(T.nilable(String))).void }
def initialize(capture_method: nil); end
end
class SepaDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'STRIPE'.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :reference_prefix
sig { params(reference_prefix: T.nilable(T.nilable(String))).void }
def initialize(reference_prefix: nil); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::SepaDebit::MandateOptions))
}
attr_accessor :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
sig {
params(mandate_options: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::SepaDebit::MandateOptions), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), target_date: T.nilable(String)).void
}
def initialize(mandate_options: nil, setup_future_usage: nil, target_date: nil); end
end
class Shopeepay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Sofort < Stripe::RequestParams
# Language shown to the payer on redirect.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :preferred_language
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(preferred_language: T.nilable(T.nilable(T.any(String, String))), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(preferred_language: nil, setup_future_usage: nil); end
end
class StripeBalance < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void }
def initialize(setup_future_usage: nil); end
end
class Swish < Stripe::RequestParams
# A reference for this payment to be displayed in the Swish app.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :reference
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(reference: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(String)).void
}
def initialize(reference: nil, setup_future_usage: nil); end
end
class Twint < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class UsBankAccount < Stripe::RequestParams
class FinancialConnections < Stripe::RequestParams
class Filters < Stripe::RequestParams
# The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :account_subcategories
# ID of the institution to use to filter for selectable accounts.
sig { returns(T.nilable(String)) }
attr_accessor :institution
sig {
params(account_subcategories: T.nilable(T::Array[String]), institution: T.nilable(String)).void
}
def initialize(account_subcategories: nil, institution: nil); end
end
class ManualEntry < Stripe::RequestParams
# Settings for configuring manual entry of account details.
sig { returns(String) }
attr_accessor :mode
sig { params(mode: String).void }
def initialize(mode: nil); end
end
# Provide filters for the linked accounts that the customer can select for the payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::Filters))
}
attr_accessor :filters
# Customize manual entry behavior
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::ManualEntry))
}
attr_accessor :manual_entry
# The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :permissions
# List of data features that you would like to retrieve upon account creation.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :prefetch
# For webview integrations only. Upon completing OAuth login in the native browser, the user will be redirected to this URL to return to your app.
sig { returns(T.nilable(String)) }
attr_accessor :return_url
sig {
params(filters: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::Filters), manual_entry: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::ManualEntry), permissions: T.nilable(T::Array[String]), prefetch: T.nilable(T::Array[String]), return_url: T.nilable(String)).void
}
def initialize(
filters: nil,
manual_entry: nil,
permissions: nil,
prefetch: nil,
return_url: nil
); end
end
class MandateOptions < Stripe::RequestParams
# The method used to collect offline mandate customer acceptance.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :collection_method
sig { params(collection_method: T.nilable(T.nilable(String))).void }
def initialize(collection_method: nil); end
end
class Networks < Stripe::RequestParams
# Triggers validations to run across the selected networks
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Array[String])).void }
def initialize(requested: nil); end
end
# Additional fields for Financial Connections Session creation
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections))
}
attr_accessor :financial_connections
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::UsBankAccount::MandateOptions))
}
attr_accessor :mandate_options
# Additional fields for network related functions
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::UsBankAccount::Networks))
}
attr_accessor :networks
# Preferred transaction settlement speed
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :preferred_settlement_speed
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
# Bank account verification method.
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(financial_connections: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections), mandate_options: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::UsBankAccount::MandateOptions), networks: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::UsBankAccount::Networks), preferred_settlement_speed: T.nilable(T.nilable(T.any(String, String))), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), target_date: T.nilable(String), verification_method: T.nilable(String)).void
}
def initialize(
financial_connections: nil,
mandate_options: nil,
networks: nil,
preferred_settlement_speed: nil,
setup_future_usage: nil,
target_date: nil,
verification_method: nil
); end
end
class WechatPay < Stripe::RequestParams
# The app ID registered with WeChat Pay. Only required when client is ios or android.
sig { returns(T.nilable(String)) }
attr_accessor :app_id
# The client type that the end customer will pay from
sig { returns(T.nilable(String)) }
attr_accessor :client
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(app_id: T.nilable(String), client: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(app_id: nil, client: nil, setup_future_usage: nil); end
end
class Zip < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
# If this is a `acss_debit` PaymentMethod, this sub-hash contains details about the ACSS Debit payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::AcssDebit))))
}
attr_accessor :acss_debit
# If this is an `affirm` PaymentMethod, this sub-hash contains details about the Affirm payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Affirm))))
}
attr_accessor :affirm
# If this is a `afterpay_clearpay` PaymentMethod, this sub-hash contains details about the Afterpay Clearpay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::AfterpayClearpay))))
}
attr_accessor :afterpay_clearpay
# If this is a `alipay` PaymentMethod, this sub-hash contains details about the Alipay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Alipay))))
}
attr_accessor :alipay
# If this is a `alma` PaymentMethod, this sub-hash contains details about the Alma payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Alma))))
}
attr_accessor :alma
# If this is a `amazon_pay` PaymentMethod, this sub-hash contains details about the Amazon Pay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::AmazonPay))))
}
attr_accessor :amazon_pay
# If this is a `au_becs_debit` PaymentMethod, this sub-hash contains details about the AU BECS Direct Debit payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::AuBecsDebit))))
}
attr_accessor :au_becs_debit
# If this is a `bacs_debit` PaymentMethod, this sub-hash contains details about the BACS Debit payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::BacsDebit))))
}
attr_accessor :bacs_debit
# If this is a `bancontact` PaymentMethod, this sub-hash contains details about the Bancontact payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Bancontact))))
}
attr_accessor :bancontact
# If this is a `billie` PaymentMethod, this sub-hash contains details about the Billie payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Billie))))
}
attr_accessor :billie
# If this is a `blik` PaymentMethod, this sub-hash contains details about the BLIK payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Blik))))
}
attr_accessor :blik
# If this is a `boleto` PaymentMethod, this sub-hash contains details about the Boleto payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Boleto))))
}
attr_accessor :boleto
# Configuration for any card payments attempted on this PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Card))))
}
attr_accessor :card
# If this is a `card_present` PaymentMethod, this sub-hash contains details about the Card Present payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::CardPresent))))
}
attr_accessor :card_present
# If this is a `cashapp` PaymentMethod, this sub-hash contains details about the Cash App Pay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Cashapp))))
}
attr_accessor :cashapp
# If this is a `customer balance` PaymentMethod, this sub-hash contains details about the customer balance payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::CustomerBalance))))
}
attr_accessor :customer_balance
# If this is a `eps` PaymentMethod, this sub-hash contains details about the EPS payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Eps))))
}
attr_accessor :eps
# If this is a `fpx` PaymentMethod, this sub-hash contains details about the FPX payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Fpx))))
}
attr_accessor :fpx
# If this is a `giropay` PaymentMethod, this sub-hash contains details about the Giropay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Giropay))))
}
attr_accessor :giropay
# If this is a `gopay` PaymentMethod, this sub-hash contains details about the Gopay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Gopay))))
}
attr_accessor :gopay
# If this is a `grabpay` PaymentMethod, this sub-hash contains details about the Grabpay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Grabpay))))
}
attr_accessor :grabpay
# If this is a `id_bank_transfer` PaymentMethod, this sub-hash contains details about the Indonesia Bank Transfer payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::IdBankTransfer))))
}
attr_accessor :id_bank_transfer
# If this is a `ideal` PaymentMethod, this sub-hash contains details about the Ideal payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Ideal))))
}
attr_accessor :ideal
# If this is a `interac_present` PaymentMethod, this sub-hash contains details about the Card Present payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::InteracPresent))))
}
attr_accessor :interac_present
# If this is a `kakao_pay` PaymentMethod, this sub-hash contains details about the Kakao Pay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::KakaoPay))))
}
attr_accessor :kakao_pay
# If this is a `klarna` PaymentMethod, this sub-hash contains details about the Klarna payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Klarna))))
}
attr_accessor :klarna
# If this is a `konbini` PaymentMethod, this sub-hash contains details about the Konbini payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Konbini))))
}
attr_accessor :konbini
# If this is a `kr_card` PaymentMethod, this sub-hash contains details about the KR Card payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::KrCard))))
}
attr_accessor :kr_card
# If this is a `link` PaymentMethod, this sub-hash contains details about the Link payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Link))))
}
attr_accessor :link
# If this is a `mb_way` PaymentMethod, this sub-hash contains details about the MB WAY payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::MbWay))))
}
attr_accessor :mb_way
# If this is a `MobilePay` PaymentMethod, this sub-hash contains details about the MobilePay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Mobilepay))))
}
attr_accessor :mobilepay
# If this is a `multibanco` PaymentMethod, this sub-hash contains details about the Multibanco payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Multibanco))))
}
attr_accessor :multibanco
# If this is a `naver_pay` PaymentMethod, this sub-hash contains details about the Naver Pay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::NaverPay))))
}
attr_accessor :naver_pay
# If this is a `nz_bank_account` PaymentMethod, this sub-hash contains details about the NZ BECS Direct Debit payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::NzBankAccount))))
}
attr_accessor :nz_bank_account
# If this is a `oxxo` PaymentMethod, this sub-hash contains details about the OXXO payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Oxxo))))
}
attr_accessor :oxxo
# If this is a `p24` PaymentMethod, this sub-hash contains details about the Przelewy24 payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::P24))))
}
attr_accessor :p24
# If this is a `pay_by_bank` PaymentMethod, this sub-hash contains details about the PayByBank payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::PayByBank))))
}
attr_accessor :pay_by_bank
# If this is a `payco` PaymentMethod, this sub-hash contains details about the PAYCO payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Payco))))
}
attr_accessor :payco
# If this is a `paynow` PaymentMethod, this sub-hash contains details about the PayNow payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Paynow))))
}
attr_accessor :paynow
# If this is a `paypal` PaymentMethod, this sub-hash contains details about the PayPal payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Paypal))))
}
attr_accessor :paypal
# If this is a `payto` PaymentMethod, this sub-hash contains details about the PayTo payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Payto))))
}
attr_accessor :payto
# If this is a `pix` PaymentMethod, this sub-hash contains details about the Pix payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Pix))))
}
attr_accessor :pix
# If this is a `promptpay` PaymentMethod, this sub-hash contains details about the PromptPay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Promptpay))))
}
attr_accessor :promptpay
# If this is a `qris` PaymentMethod, this sub-hash contains details about the QRIS payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Qris))))
}
attr_accessor :qris
# If this is a `rechnung` PaymentMethod, this sub-hash contains details about the Rechnung payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Rechnung))))
}
attr_accessor :rechnung
# If this is a `revolut_pay` PaymentMethod, this sub-hash contains details about the Revolut Pay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::RevolutPay))))
}
attr_accessor :revolut_pay
# If this is a `samsung_pay` PaymentMethod, this sub-hash contains details about the Samsung Pay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::SamsungPay))))
}
attr_accessor :samsung_pay
# If this is a `satispay` PaymentMethod, this sub-hash contains details about the Satispay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Satispay))))
}
attr_accessor :satispay
# If this is a `sepa_debit` PaymentIntent, this sub-hash contains details about the SEPA Debit payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::SepaDebit))))
}
attr_accessor :sepa_debit
# If this is a `shopeepay` PaymentMethod, this sub-hash contains details about the ShopeePay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Shopeepay))))
}
attr_accessor :shopeepay
# If this is a `sofort` PaymentMethod, this sub-hash contains details about the SOFORT payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Sofort))))
}
attr_accessor :sofort
# If this is a `stripe_balance` PaymentMethod, this sub-hash contains details about the Stripe Balance payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::StripeBalance))))
}
attr_accessor :stripe_balance
# If this is a `Swish` PaymentMethod, this sub-hash contains details about the Swish payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Swish))))
}
attr_accessor :swish
# If this is a `twint` PaymentMethod, this sub-hash contains details about the TWINT payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Twint))))
}
attr_accessor :twint
# If this is a `us_bank_account` PaymentMethod, this sub-hash contains details about the US bank account payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::UsBankAccount))))
}
attr_accessor :us_bank_account
# If this is a `wechat_pay` PaymentMethod, this sub-hash contains details about the WeChat Pay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::WechatPay))))
}
attr_accessor :wechat_pay
# If this is a `zip` PaymentMethod, this sub-hash contains details about the Zip payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Zip))))
}
attr_accessor :zip
sig {
params(acss_debit: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::AcssDebit))), affirm: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Affirm))), afterpay_clearpay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::AfterpayClearpay))), alipay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Alipay))), alma: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Alma))), amazon_pay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::AmazonPay))), au_becs_debit: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::AuBecsDebit))), bacs_debit: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::BacsDebit))), bancontact: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Bancontact))), billie: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Billie))), blik: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Blik))), boleto: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Boleto))), card: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Card))), card_present: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::CardPresent))), cashapp: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Cashapp))), customer_balance: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::CustomerBalance))), eps: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Eps))), fpx: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Fpx))), giropay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Giropay))), gopay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Gopay))), grabpay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Grabpay))), id_bank_transfer: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::IdBankTransfer))), ideal: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Ideal))), interac_present: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::InteracPresent))), kakao_pay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::KakaoPay))), klarna: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Klarna))), konbini: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Konbini))), kr_card: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::KrCard))), link: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Link))), mb_way: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::MbWay))), mobilepay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Mobilepay))), multibanco: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Multibanco))), naver_pay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::NaverPay))), nz_bank_account: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::NzBankAccount))), oxxo: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Oxxo))), p24: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::P24))), pay_by_bank: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::PayByBank))), payco: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Payco))), paynow: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Paynow))), paypal: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Paypal))), payto: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Payto))), pix: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Pix))), promptpay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Promptpay))), qris: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Qris))), rechnung: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Rechnung))), revolut_pay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::RevolutPay))), samsung_pay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::SamsungPay))), satispay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Satispay))), sepa_debit: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::SepaDebit))), shopeepay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Shopeepay))), sofort: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Sofort))), stripe_balance: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::StripeBalance))), swish: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Swish))), twint: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Twint))), us_bank_account: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::UsBankAccount))), wechat_pay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::WechatPay))), zip: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions::Zip)))).void
}
def initialize(
acss_debit: nil,
affirm: nil,
afterpay_clearpay: nil,
alipay: nil,
alma: nil,
amazon_pay: nil,
au_becs_debit: nil,
bacs_debit: nil,
bancontact: nil,
billie: nil,
blik: nil,
boleto: nil,
card: nil,
card_present: nil,
cashapp: nil,
customer_balance: nil,
eps: nil,
fpx: nil,
giropay: nil,
gopay: nil,
grabpay: nil,
id_bank_transfer: nil,
ideal: nil,
interac_present: nil,
kakao_pay: nil,
klarna: nil,
konbini: nil,
kr_card: nil,
link: nil,
mb_way: nil,
mobilepay: nil,
multibanco: nil,
naver_pay: nil,
nz_bank_account: nil,
oxxo: nil,
p24: nil,
pay_by_bank: nil,
payco: nil,
paynow: nil,
paypal: nil,
payto: nil,
pix: nil,
promptpay: nil,
qris: nil,
rechnung: nil,
revolut_pay: nil,
samsung_pay: nil,
satispay: nil,
sepa_debit: nil,
shopeepay: nil,
sofort: nil,
stripe_balance: nil,
swish: nil,
twint: nil,
us_bank_account: nil,
wechat_pay: nil,
zip: nil
); end
end
class RadarOptions < Stripe::RequestParams
# A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
sig { returns(T.nilable(String)) }
attr_accessor :session
sig { params(session: T.nilable(String)).void }
def initialize(session: nil); end
end
class Shipping < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Shipping address.
sig { returns(::Stripe::PaymentIntentService::CreateParams::Shipping::Address) }
attr_accessor :address
# The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
sig { returns(T.nilable(String)) }
attr_accessor :carrier
# Recipient name.
sig { returns(String) }
attr_accessor :name
# Recipient phone (including extension).
sig { returns(T.nilable(String)) }
attr_accessor :phone
# The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
sig { returns(T.nilable(String)) }
attr_accessor :tracking_number
sig {
params(address: ::Stripe::PaymentIntentService::CreateParams::Shipping::Address, carrier: T.nilable(String), name: String, phone: T.nilable(String), tracking_number: T.nilable(String)).void
}
def initialize(address: nil, carrier: nil, name: nil, phone: nil, tracking_number: nil); end
end
class TransferData < Stripe::RequestParams
# The amount that will be transferred automatically when a charge succeeds.
# The amount is capped at the total transaction amount and if no amount is set,
# the full amount is transferred.
#
# If you intend to collect a fee and you need a more robust reporting experience, using
# [application_fee_amount](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-application_fee_amount)
# might be a better fit for your integration.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# If specified, successful charges will be attributed to the destination
# account for tax reporting, and the funds from charges will be transferred
# to the destination account. The ID of the resulting transfer will be
# returned on the successful charge's `transfer` field.
sig { returns(String) }
attr_accessor :destination
sig { params(amount: T.nilable(Integer), destination: String).void }
def initialize(amount: nil, destination: nil); end
end
# Amount intended to be collected by this PaymentIntent. A positive integer representing how much to charge in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is $0.50 US or [equivalent in charge currency](https://stripe.com/docs/currencies#minimum-and-maximum-charge-amounts). The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99).
sig { returns(Integer) }
attr_accessor :amount
# The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. The amount of the application fee collected will be capped at the total amount captured. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
sig { returns(T.nilable(Integer)) }
attr_accessor :application_fee_amount
# When you enable this parameter, this PaymentIntent accepts payment methods that you enable in the Dashboard and that are compatible with this PaymentIntent's other parameters.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::AutomaticPaymentMethods))
}
attr_accessor :automatic_payment_methods
# Controls when the funds will be captured from the customer's account.
sig { returns(T.nilable(String)) }
attr_accessor :capture_method
# Set to `true` to attempt to [confirm this PaymentIntent](https://stripe.com/docs/api/payment_intents/confirm) immediately. This parameter defaults to `false`. When creating and confirming a PaymentIntent at the same time, you can also provide the parameters available in the [Confirm API](https://stripe.com/docs/api/payment_intents/confirm).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :confirm
# Describes whether we can confirm this PaymentIntent automatically, or if it requires customer action to confirm the payment.
sig { returns(T.nilable(String)) }
attr_accessor :confirmation_method
# ID of the ConfirmationToken used to confirm this PaymentIntent.
#
# If the provided ConfirmationToken contains properties that are also being provided in this request, such as `payment_method`, then the values in this request will take precedence.
sig { returns(T.nilable(String)) }
attr_accessor :confirmation_token
# 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).
sig { returns(String) }
attr_accessor :currency
# ID of the Customer this PaymentIntent belongs to, if one exists.
#
# Payment methods attached to other Customers cannot be used with this PaymentIntent.
#
# If [setup_future_usage](https://stripe.com/docs/api#payment_intent_object-setup_future_usage) is set and this PaymentIntent's payment method is not `card_present`, then the payment method attaches to the Customer after the PaymentIntent has been confirmed and any required actions from the user are complete. If the payment method is `card_present` and isn't a digital wallet, then a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card is created and attached to the Customer instead.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# ID of the Account this PaymentIntent belongs to, if one exists.
#
# Payment methods attached to other Accounts cannot be used with this PaymentIntent.
#
# If [setup_future_usage](https://stripe.com/docs/api#payment_intent_object-setup_future_usage) is set and this PaymentIntent's payment method is not `card_present`, then the payment method attaches to the Account after the PaymentIntent has been confirmed and any required actions from the user are complete. If the payment method is `card_present` and isn't a digital wallet, then a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card is created and attached to the Account instead.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Set to `true` to fail the payment attempt if the PaymentIntent transitions into `requires_action`. Use this parameter for simpler integrations that don't handle customer actions, such as [saving cards without authentication](https://stripe.com/docs/payments/save-card-without-authentication). This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-confirm).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :error_on_requires_action
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The FX rate in the quote is validated and used to convert the presentment amount to the settlement amount.
sig { returns(T.nilable(String)) }
attr_accessor :fx_quote
# Automations to be run during the PaymentIntent lifecycle
sig { returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::Hooks)) }
attr_accessor :hooks
# ID of the mandate that's used for this payment. This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-confirm).
sig { returns(T.nilable(String)) }
attr_accessor :mandate
# This hash contains details about the Mandate to create. This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-confirm).
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::MandateData))))
}
attr_accessor :mandate_data
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Set to `true` to indicate that the customer isn't in your checkout flow during this payment attempt and can't authenticate. Use this parameter in scenarios where you collect card details and [charge them later](https://stripe.com/docs/payments/cards/charging-saved-cards). This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-confirm).
sig { returns(T.nilable(T.any(T::Boolean, String))) }
attr_accessor :off_session
# The Stripe account ID that these funds are intended for. Learn more about the [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
sig { returns(T.nilable(String)) }
attr_accessor :on_behalf_of
# Provides industry-specific information about the charge.
sig { returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails)) }
attr_accessor :payment_details
# ID of the payment method (a PaymentMethod, Card, or [compatible Source](https://stripe.com/docs/payments/payment-methods#compatibility) object) to attach to this PaymentIntent.
#
# If you don't provide the `payment_method` parameter or the `source` parameter with `confirm=true`, `source` automatically populates with `customer.default_source` to improve migration for users of the Charges API. We recommend that you explicitly provide the `payment_method` moving forward.
# If the payment method is attached to a Customer, you must also provide the ID of that Customer as the [customer](https://stripe.com/docs/api#create_payment_intent-customer) parameter of this PaymentIntent.
# end
sig { returns(T.nilable(String)) }
attr_accessor :payment_method
# The ID of the [payment method configuration](https://stripe.com/docs/api/payment_method_configurations) to use with this PaymentIntent.
sig { returns(T.nilable(String)) }
attr_accessor :payment_method_configuration
# If provided, this hash will be used to create a PaymentMethod. The new PaymentMethod will appear
# in the [payment_method](https://stripe.com/docs/api/payment_intents/object#payment_intent_object-payment_method)
# property on the PaymentIntent.
sig { returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData)) }
attr_accessor :payment_method_data
# Payment method-specific configuration for this PaymentIntent.
sig { returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions)) }
attr_accessor :payment_method_options
# The list of payment method types (for example, a card) that this PaymentIntent can use. If you don't provide this, Stripe will dynamically show relevant payment methods from your [payment method settings](https://dashboard.stripe.com/settings/payment_methods).
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :payment_method_types
# Options to configure Radar. Learn more about [Radar Sessions](https://stripe.com/docs/radar/radar-session).
sig { returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::RadarOptions)) }
attr_accessor :radar_options
# Email address to send the receipt to. If you specify `receipt_email` for a payment in live mode, you send a receipt regardless of your [email settings](https://dashboard.stripe.com/account/emails).
sig { returns(T.nilable(String)) }
attr_accessor :receipt_email
# The URL to redirect your customer back to after they authenticate or cancel their payment on the payment method's app or site. If you'd prefer to redirect to a mobile application, you can alternatively supply an application URI scheme. This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/payment_intents/create#create_payment_intent-confirm).
sig { returns(T.nilable(String)) }
attr_accessor :return_url
# Indicates whether confirmation for this PaymentIntent using a secret key is `required` or `optional`.
sig { returns(T.nilable(String)) }
attr_accessor :secret_key_confirmation
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
# Shipping information for this PaymentIntent.
sig { returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::Shipping)) }
attr_accessor :shipping
# Text that appears on the customer's statement as the statement descriptor for a non-card charge. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
#
# Setting this value for a card charge returns an error. For card charges, set the [statement_descriptor_suffix](https://docs.stripe.com/get-started/account/statement-descriptors#dynamic) instead.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
# Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor_suffix
# The parameters that you can use to automatically create a Transfer.
# Learn more about the [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
sig { returns(T.nilable(::Stripe::PaymentIntentService::CreateParams::TransferData)) }
attr_accessor :transfer_data
# A string that identifies the resulting payment as part of a group. Learn more about the [use case for connected accounts](https://stripe.com/docs/connect/separate-charges-and-transfers).
sig { returns(T.nilable(String)) }
attr_accessor :transfer_group
# Set to `true` when confirming server-side and using Stripe.js, iOS, or Android client-side SDKs to handle the next actions.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :use_stripe_sdk
sig {
params(amount: Integer, application_fee_amount: T.nilable(Integer), automatic_payment_methods: T.nilable(::Stripe::PaymentIntentService::CreateParams::AutomaticPaymentMethods), capture_method: T.nilable(String), confirm: T.nilable(T::Boolean), confirmation_method: T.nilable(String), confirmation_token: T.nilable(String), currency: String, customer: T.nilable(String), customer_account: T.nilable(String), description: T.nilable(String), error_on_requires_action: T.nilable(T::Boolean), expand: T.nilable(T::Array[String]), fx_quote: T.nilable(String), hooks: T.nilable(::Stripe::PaymentIntentService::CreateParams::Hooks), mandate: T.nilable(String), mandate_data: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CreateParams::MandateData))), metadata: T.nilable(T::Hash[String, String]), off_session: T.nilable(T.any(T::Boolean, String)), on_behalf_of: T.nilable(String), payment_details: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentDetails), payment_method: T.nilable(String), payment_method_configuration: T.nilable(String), payment_method_data: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodData), payment_method_options: T.nilable(::Stripe::PaymentIntentService::CreateParams::PaymentMethodOptions), payment_method_types: T.nilable(T::Array[String]), radar_options: T.nilable(::Stripe::PaymentIntentService::CreateParams::RadarOptions), receipt_email: T.nilable(String), return_url: T.nilable(String), secret_key_confirmation: T.nilable(String), setup_future_usage: T.nilable(String), shipping: T.nilable(::Stripe::PaymentIntentService::CreateParams::Shipping), statement_descriptor: T.nilable(String), statement_descriptor_suffix: T.nilable(String), transfer_data: T.nilable(::Stripe::PaymentIntentService::CreateParams::TransferData), transfer_group: T.nilable(String), use_stripe_sdk: T.nilable(T::Boolean)).void
}
def initialize(
amount: nil,
application_fee_amount: nil,
automatic_payment_methods: nil,
capture_method: nil,
confirm: nil,
confirmation_method: nil,
confirmation_token: nil,
currency: nil,
customer: nil,
customer_account: nil,
description: nil,
error_on_requires_action: nil,
expand: nil,
fx_quote: nil,
hooks: nil,
mandate: nil,
mandate_data: nil,
metadata: nil,
off_session: nil,
on_behalf_of: nil,
payment_details: nil,
payment_method: nil,
payment_method_configuration: nil,
payment_method_data: nil,
payment_method_options: nil,
payment_method_types: nil,
radar_options: nil,
receipt_email: nil,
return_url: nil,
secret_key_confirmation: nil,
setup_future_usage: nil,
shipping: nil,
statement_descriptor: nil,
statement_descriptor_suffix: nil,
transfer_data: nil,
transfer_group: nil,
use_stripe_sdk: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# The client secret of the PaymentIntent. We require it if you use a publishable key to retrieve the source.
sig { returns(T.nilable(String)) }
attr_accessor :client_secret
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(client_secret: T.nilable(String), expand: T.nilable(T::Array[String])).void }
def initialize(client_secret: nil, expand: nil); end
end
class UpdateParams < Stripe::RequestParams
class Hooks < Stripe::RequestParams
class Inputs < Stripe::RequestParams
class Tax < Stripe::RequestParams
# The [TaxCalculation](https://stripe.com/docs/api/tax/calculations) id
sig { returns(T.nilable(String)) }
attr_accessor :calculation
sig { params(calculation: T.nilable(String)).void }
def initialize(calculation: nil); end
end
# Tax arguments for automations
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::Hooks::Inputs::Tax))
}
attr_accessor :tax
sig {
params(tax: T.nilable(::Stripe::PaymentIntentService::UpdateParams::Hooks::Inputs::Tax)).void
}
def initialize(tax: nil); end
end
# Arguments passed in automations
sig { returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::Hooks::Inputs)) }
attr_accessor :inputs
sig {
params(inputs: T.nilable(::Stripe::PaymentIntentService::UpdateParams::Hooks::Inputs)).void
}
def initialize(inputs: nil); end
end
class MandateData < Stripe::RequestParams
class CustomerAcceptance < Stripe::RequestParams
class Online < Stripe::RequestParams
# The IP address from which the Mandate was accepted by the customer.
sig { returns(T.nilable(String)) }
attr_accessor :ip_address
# The user agent of the browser from which the Mandate was accepted by the customer.
sig { returns(T.nilable(String)) }
attr_accessor :user_agent
sig { params(ip_address: T.nilable(String), user_agent: T.nilable(String)).void }
def initialize(ip_address: nil, user_agent: nil); end
end
# If this is a Mandate accepted online, this hash contains details about the online acceptance.
sig {
returns(::Stripe::PaymentIntentService::UpdateParams::MandateData::CustomerAcceptance::Online)
}
attr_accessor :online
# The type of customer acceptance information included with the Mandate.
sig { returns(String) }
attr_accessor :type
sig {
params(online: ::Stripe::PaymentIntentService::UpdateParams::MandateData::CustomerAcceptance::Online, type: String).void
}
def initialize(online: nil, type: nil); end
end
# This hash contains details about the customer acceptance of the Mandate.
sig {
returns(::Stripe::PaymentIntentService::UpdateParams::MandateData::CustomerAcceptance)
}
attr_accessor :customer_acceptance
sig {
params(customer_acceptance: ::Stripe::PaymentIntentService::UpdateParams::MandateData::CustomerAcceptance).void
}
def initialize(customer_acceptance: nil); end
end
class PaymentDetails < Stripe::RequestParams
class CarRental < Stripe::RequestParams
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::CarRental::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::CarRental::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
class Distance < Stripe::RequestParams
# Distance traveled.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# Unit of measurement for the distance traveled. One of `miles` or `kilometers`.
sig { returns(T.nilable(String)) }
attr_accessor :unit
sig { params(amount: T.nilable(Integer), unit: T.nilable(String)).void }
def initialize(amount: nil, unit: nil); end
end
class Driver < Stripe::RequestParams
# Driver's identification number.
sig { returns(T.nilable(String)) }
attr_accessor :driver_identification_number
# Driver's tax number.
sig { returns(T.nilable(String)) }
attr_accessor :driver_tax_number
# Full name of the person or entity on the car reservation.
sig { returns(String) }
attr_accessor :name
sig {
params(driver_identification_number: T.nilable(String), driver_tax_number: T.nilable(String), name: String).void
}
def initialize(
driver_identification_number: nil,
driver_tax_number: nil,
name: nil
); end
end
class PickupAddress < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class ReturnAddress < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::CarRental::Affiliate))
}
attr_accessor :affiliate
# The booking number associated with the car rental.
sig { returns(String) }
attr_accessor :booking_number
# Class code of the car.
sig { returns(T.nilable(String)) }
attr_accessor :car_class_code
# Make of the car.
sig { returns(T.nilable(String)) }
attr_accessor :car_make
# Model of the car.
sig { returns(T.nilable(String)) }
attr_accessor :car_model
# The name of the rental car company.
sig { returns(T.nilable(String)) }
attr_accessor :company
# The customer service phone number of the car rental company.
sig { returns(T.nilable(String)) }
attr_accessor :customer_service_phone_number
# Number of days the car is being rented.
sig { returns(Integer) }
attr_accessor :days_rented
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::CarRental::Delivery))
}
attr_accessor :delivery
# The details of the distance traveled during the rental period.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::CarRental::Distance))
}
attr_accessor :distance
# The details of the passengers in the travel reservation
sig {
returns(T.nilable(T::Array[::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::CarRental::Driver]))
}
attr_accessor :drivers
# List of additional charges being billed.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :extra_charges
# Indicates if the customer did not keep nor cancel their booking.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :no_show
# Car pick-up address.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::CarRental::PickupAddress))
}
attr_accessor :pickup_address
# Car pick-up time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :pickup_at
# Name of the pickup location.
sig { returns(T.nilable(String)) }
attr_accessor :pickup_location_name
# Rental rate.
sig { returns(T.nilable(Integer)) }
attr_accessor :rate_amount
# The frequency at which the rate amount is applied. One of `day`, `week` or `month`
sig { returns(T.nilable(String)) }
attr_accessor :rate_interval
# The name of the person or entity renting the car.
sig { returns(T.nilable(String)) }
attr_accessor :renter_name
# Car return address.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::CarRental::ReturnAddress))
}
attr_accessor :return_address
# Car return time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :return_at
# Name of the return location.
sig { returns(T.nilable(String)) }
attr_accessor :return_location_name
# Indicates whether the goods or services are tax-exempt or tax is not collected.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :tax_exempt
# The vehicle identification number.
sig { returns(T.nilable(String)) }
attr_accessor :vehicle_identification_number
sig {
params(affiliate: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::CarRental::Affiliate), booking_number: String, car_class_code: T.nilable(String), car_make: T.nilable(String), car_model: T.nilable(String), company: T.nilable(String), customer_service_phone_number: T.nilable(String), days_rented: Integer, delivery: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::CarRental::Delivery), distance: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::CarRental::Distance), drivers: T.nilable(T::Array[::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::CarRental::Driver]), extra_charges: T.nilable(T::Array[String]), no_show: T.nilable(T::Boolean), pickup_address: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::CarRental::PickupAddress), pickup_at: Integer, pickup_location_name: T.nilable(String), rate_amount: T.nilable(Integer), rate_interval: T.nilable(String), renter_name: T.nilable(String), return_address: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::CarRental::ReturnAddress), return_at: Integer, return_location_name: T.nilable(String), tax_exempt: T.nilable(T::Boolean), vehicle_identification_number: T.nilable(String)).void
}
def initialize(
affiliate: nil,
booking_number: nil,
car_class_code: nil,
car_make: nil,
car_model: nil,
company: nil,
customer_service_phone_number: nil,
days_rented: nil,
delivery: nil,
distance: nil,
drivers: nil,
extra_charges: nil,
no_show: nil,
pickup_address: nil,
pickup_at: nil,
pickup_location_name: nil,
rate_amount: nil,
rate_interval: nil,
renter_name: nil,
return_address: nil,
return_at: nil,
return_location_name: nil,
tax_exempt: nil,
vehicle_identification_number: nil
); end
end
class EventDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::EventDetails::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::EventDetails::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
# Indicates if the tickets are digitally checked when entering the venue.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :access_controlled_venue
# The event location's address.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::EventDetails::Address))
}
attr_accessor :address
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::EventDetails::Affiliate))
}
attr_accessor :affiliate
# The name of the company
sig { returns(T.nilable(String)) }
attr_accessor :company
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::EventDetails::Delivery))
}
attr_accessor :delivery
# Event end time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :ends_at
# Type of the event entertainment (concert, sports event etc)
sig { returns(T.nilable(String)) }
attr_accessor :genre
# The name of the event.
sig { returns(String) }
attr_accessor :name
# Event start time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :starts_at
sig {
params(access_controlled_venue: T.nilable(T::Boolean), address: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::EventDetails::Address), affiliate: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::EventDetails::Affiliate), company: T.nilable(String), delivery: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::EventDetails::Delivery), ends_at: T.nilable(Integer), genre: T.nilable(String), name: String, starts_at: T.nilable(Integer)).void
}
def initialize(
access_controlled_venue: nil,
address: nil,
affiliate: nil,
company: nil,
delivery: nil,
ends_at: nil,
genre: nil,
name: nil,
starts_at: nil
); end
end
class Flight < Stripe::RequestParams
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::Flight::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::Flight::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
class Passenger < Stripe::RequestParams
# Full name of the person or entity on the flight reservation.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Segment < Stripe::RequestParams
# The flight segment amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# The International Air Transport Association (IATA) airport code for the arrival airport.
sig { returns(T.nilable(String)) }
attr_accessor :arrival_airport
# The arrival time for the flight segment. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :arrives_at
# The International Air Transport Association (IATA) carrier code of the carrier operating the flight segment.
sig { returns(T.nilable(String)) }
attr_accessor :carrier
# The departure time for the flight segment. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :departs_at
# The International Air Transport Association (IATA) airport code for the departure airport.
sig { returns(T.nilable(String)) }
attr_accessor :departure_airport
# The flight number associated with the segment
sig { returns(T.nilable(String)) }
attr_accessor :flight_number
# The fare class for the segment.
sig { returns(T.nilable(String)) }
attr_accessor :service_class
sig {
params(amount: T.nilable(Integer), arrival_airport: T.nilable(String), arrives_at: T.nilable(Integer), carrier: T.nilable(String), departs_at: Integer, departure_airport: T.nilable(String), flight_number: T.nilable(String), service_class: T.nilable(String)).void
}
def initialize(
amount: nil,
arrival_airport: nil,
arrives_at: nil,
carrier: nil,
departs_at: nil,
departure_airport: nil,
flight_number: nil,
service_class: nil
); end
end
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::Flight::Affiliate))
}
attr_accessor :affiliate
# The agency number (i.e. International Air Transport Association (IATA) agency number) of the travel agency that made the booking.
sig { returns(T.nilable(String)) }
attr_accessor :agency_number
# The International Air Transport Association (IATA) carrier code of the carrier that issued the ticket.
sig { returns(T.nilable(String)) }
attr_accessor :carrier
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::Flight::Delivery))
}
attr_accessor :delivery
# The name of the person or entity on the reservation.
sig { returns(T.nilable(String)) }
attr_accessor :passenger_name
# The details of the passengers in the travel reservation.
sig {
returns(T.nilable(T::Array[::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::Flight::Passenger]))
}
attr_accessor :passengers
# The individual flight segments associated with the trip.
sig {
returns(T::Array[::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::Flight::Segment])
}
attr_accessor :segments
# The ticket number associated with the travel reservation.
sig { returns(T.nilable(String)) }
attr_accessor :ticket_number
sig {
params(affiliate: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::Flight::Affiliate), agency_number: T.nilable(String), carrier: T.nilable(String), delivery: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::Flight::Delivery), passenger_name: T.nilable(String), passengers: T.nilable(T::Array[::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::Flight::Passenger]), segments: T::Array[::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::Flight::Segment], ticket_number: T.nilable(String)).void
}
def initialize(
affiliate: nil,
agency_number: nil,
carrier: nil,
delivery: nil,
passenger_name: nil,
passengers: nil,
segments: nil,
ticket_number: nil
); end
end
class Lodging < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::Lodging::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::Lodging::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
class Passenger < Stripe::RequestParams
# Full name of the person or entity on the lodging reservation.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
# The lodging location's address.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::Lodging::Address))
}
attr_accessor :address
# The number of adults on the booking
sig { returns(T.nilable(Integer)) }
attr_accessor :adults
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::Lodging::Affiliate))
}
attr_accessor :affiliate
# The booking number associated with the lodging reservation.
sig { returns(T.nilable(String)) }
attr_accessor :booking_number
# The lodging category
sig { returns(T.nilable(String)) }
attr_accessor :category
# Lodging check-in time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :checkin_at
# Lodging check-out time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :checkout_at
# The customer service phone number of the lodging company.
sig { returns(T.nilable(String)) }
attr_accessor :customer_service_phone_number
# The daily lodging room rate.
sig { returns(T.nilable(Integer)) }
attr_accessor :daily_room_rate_amount
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::Lodging::Delivery))
}
attr_accessor :delivery
# List of additional charges being billed.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :extra_charges
# Indicates whether the lodging location is compliant with the Fire Safety Act.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :fire_safety_act_compliance
# The name of the lodging location.
sig { returns(T.nilable(String)) }
attr_accessor :name
# Indicates if the customer did not keep their booking while failing to cancel the reservation.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :no_show
# The number of rooms on the booking
sig { returns(T.nilable(Integer)) }
attr_accessor :number_of_rooms
# The details of the passengers in the travel reservation
sig {
returns(T.nilable(T::Array[::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::Lodging::Passenger]))
}
attr_accessor :passengers
# The phone number of the lodging location.
sig { returns(T.nilable(String)) }
attr_accessor :property_phone_number
# The room class for this purchase.
sig { returns(T.nilable(String)) }
attr_accessor :room_class
# The number of room nights
sig { returns(T.nilable(Integer)) }
attr_accessor :room_nights
# The total tax amount associating with the room reservation.
sig { returns(T.nilable(Integer)) }
attr_accessor :total_room_tax_amount
# The total tax amount
sig { returns(T.nilable(Integer)) }
attr_accessor :total_tax_amount
sig {
params(address: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::Lodging::Address), adults: T.nilable(Integer), affiliate: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::Lodging::Affiliate), booking_number: T.nilable(String), category: T.nilable(String), checkin_at: Integer, checkout_at: Integer, customer_service_phone_number: T.nilable(String), daily_room_rate_amount: T.nilable(Integer), delivery: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::Lodging::Delivery), extra_charges: T.nilable(T::Array[String]), fire_safety_act_compliance: T.nilable(T::Boolean), name: T.nilable(String), no_show: T.nilable(T::Boolean), number_of_rooms: T.nilable(Integer), passengers: T.nilable(T::Array[::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::Lodging::Passenger]), property_phone_number: T.nilable(String), room_class: T.nilable(String), room_nights: T.nilable(Integer), total_room_tax_amount: T.nilable(Integer), total_tax_amount: T.nilable(Integer)).void
}
def initialize(
address: nil,
adults: nil,
affiliate: nil,
booking_number: nil,
category: nil,
checkin_at: nil,
checkout_at: nil,
customer_service_phone_number: nil,
daily_room_rate_amount: nil,
delivery: nil,
extra_charges: nil,
fire_safety_act_compliance: nil,
name: nil,
no_show: nil,
number_of_rooms: nil,
passengers: nil,
property_phone_number: nil,
room_class: nil,
room_nights: nil,
total_room_tax_amount: nil,
total_tax_amount: nil
); end
end
class Subscription < Stripe::RequestParams
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class BillingInterval < Stripe::RequestParams
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :count
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
sig { params(count: Integer, interval: String).void }
def initialize(count: nil, interval: nil); end
end
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::Subscription::Affiliate))
}
attr_accessor :affiliate
# Info whether the subscription will be auto renewed upon expiry.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :auto_renewal
# Subscription billing details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::Subscription::BillingInterval))
}
attr_accessor :billing_interval
# Subscription end time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :ends_at
# Name of the product on subscription. e.g. Apple Music Subscription
sig { returns(String) }
attr_accessor :name
# Subscription start time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :starts_at
sig {
params(affiliate: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::Subscription::Affiliate), auto_renewal: T.nilable(T::Boolean), billing_interval: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::Subscription::BillingInterval), ends_at: T.nilable(Integer), name: String, starts_at: T.nilable(Integer)).void
}
def initialize(
affiliate: nil,
auto_renewal: nil,
billing_interval: nil,
ends_at: nil,
name: nil,
starts_at: nil
); end
end
# Car rental details for this PaymentIntent.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::CarRental))
}
attr_accessor :car_rental
# Some customers might be required by their company or organization to provide this information. If so, provide this value. Otherwise you can ignore this field.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :customer_reference
# Event details for this PaymentIntent
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::EventDetails))
}
attr_accessor :event_details
# Flight reservation details for this PaymentIntent
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::Flight))
}
attr_accessor :flight
# Lodging reservation details for this PaymentIntent
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::Lodging))
}
attr_accessor :lodging
# A unique value assigned by the business to identify the transaction.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :order_reference
# Subscription details for this PaymentIntent
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::Subscription))
}
attr_accessor :subscription
sig {
params(car_rental: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::CarRental), customer_reference: T.nilable(T.nilable(String)), event_details: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::EventDetails), flight: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::Flight), lodging: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::Lodging), order_reference: T.nilable(T.nilable(String)), subscription: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentDetails::Subscription)).void
}
def initialize(
car_rental: nil,
customer_reference: nil,
event_details: nil,
flight: nil,
lodging: nil,
order_reference: nil,
subscription: nil
); end
end
class PaymentMethodData < Stripe::RequestParams
class AcssDebit < Stripe::RequestParams
# Customer's bank account number.
sig { returns(String) }
attr_accessor :account_number
# Institution number of the customer's bank.
sig { returns(String) }
attr_accessor :institution_number
# Transit number of the customer's bank.
sig { returns(String) }
attr_accessor :transit_number
sig {
params(account_number: String, institution_number: String, transit_number: String).void
}
def initialize(account_number: nil, institution_number: nil, transit_number: nil); end
end
class Affirm < Stripe::RequestParams; end
class AfterpayClearpay < Stripe::RequestParams; end
class Alipay < Stripe::RequestParams; end
class Alma < Stripe::RequestParams; end
class AmazonPay < Stripe::RequestParams; end
class AuBecsDebit < Stripe::RequestParams
# The account number for the bank account.
sig { returns(String) }
attr_accessor :account_number
# Bank-State-Branch number of the bank account.
sig { returns(String) }
attr_accessor :bsb_number
sig { params(account_number: String, bsb_number: String).void }
def initialize(account_number: nil, bsb_number: nil); end
end
class BacsDebit < Stripe::RequestParams
# Account number of the bank account that the funds will be debited from.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Sort code of the bank account. (e.g., `10-20-30`)
sig { returns(T.nilable(String)) }
attr_accessor :sort_code
sig { params(account_number: T.nilable(String), sort_code: T.nilable(String)).void }
def initialize(account_number: nil, sort_code: nil); end
end
class Bancontact < Stripe::RequestParams; end
class Billie < Stripe::RequestParams; end
class BillingDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Billing address.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::BillingDetails::Address))))
}
attr_accessor :address
# Email address.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :email
# Full name.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :name
# Billing phone number (including extension).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :phone
# Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
sig { returns(T.nilable(String)) }
attr_accessor :tax_id
sig {
params(address: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::BillingDetails::Address))), email: T.nilable(T.nilable(String)), name: T.nilable(T.nilable(String)), phone: T.nilable(T.nilable(String)), tax_id: T.nilable(String)).void
}
def initialize(address: nil, email: nil, name: nil, phone: nil, tax_id: nil); end
end
class Blik < Stripe::RequestParams; end
class Boleto < Stripe::RequestParams
# The tax ID of the customer (CPF for individual consumers or CNPJ for businesses consumers)
sig { returns(String) }
attr_accessor :tax_id
sig { params(tax_id: String).void }
def initialize(tax_id: nil); end
end
class Cashapp < Stripe::RequestParams; end
class CustomerBalance < Stripe::RequestParams; end
class Eps < Stripe::RequestParams
# The customer's bank.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class Fpx < Stripe::RequestParams
# Account holder type for FPX transaction
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_type
# The customer's bank.
sig { returns(String) }
attr_accessor :bank
sig { params(account_holder_type: T.nilable(String), bank: String).void }
def initialize(account_holder_type: nil, bank: nil); end
end
class Giropay < Stripe::RequestParams; end
class Gopay < Stripe::RequestParams; end
class Grabpay < Stripe::RequestParams; end
class IdBankTransfer < Stripe::RequestParams
# Bank where the account is held.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class Ideal < Stripe::RequestParams
# The customer's bank. Only use this parameter for existing customers. Don't use it for new customers.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class InteracPresent < Stripe::RequestParams; end
class KakaoPay < Stripe::RequestParams; end
class Klarna < Stripe::RequestParams
class Dob < Stripe::RequestParams
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
# Customer's date of birth
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Klarna::Dob))
}
attr_accessor :dob
sig {
params(dob: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Klarna::Dob)).void
}
def initialize(dob: nil); end
end
class Konbini < Stripe::RequestParams; end
class KrCard < Stripe::RequestParams; end
class Link < Stripe::RequestParams; end
class MbWay < Stripe::RequestParams; end
class Mobilepay < Stripe::RequestParams; end
class Multibanco < Stripe::RequestParams; end
class NaverPay < Stripe::RequestParams
# Whether to use Naver Pay points or a card to fund this transaction. If not provided, this defaults to `card`.
sig { returns(T.nilable(String)) }
attr_accessor :funding
sig { params(funding: T.nilable(String)).void }
def initialize(funding: nil); end
end
class NzBankAccount < Stripe::RequestParams
# The name on the bank account. Only required if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod’s billing details.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_name
# The account number for the bank account.
sig { returns(String) }
attr_accessor :account_number
# The numeric code for the bank account's bank.
sig { returns(String) }
attr_accessor :bank_code
# The numeric code for the bank account's bank branch.
sig { returns(String) }
attr_accessor :branch_code
# Attribute for param field reference
sig { returns(T.nilable(String)) }
attr_accessor :reference
# The suffix of the bank account number.
sig { returns(String) }
attr_accessor :suffix
sig {
params(account_holder_name: T.nilable(String), account_number: String, bank_code: String, branch_code: String, reference: T.nilable(String), suffix: String).void
}
def initialize(
account_holder_name: nil,
account_number: nil,
bank_code: nil,
branch_code: nil,
reference: nil,
suffix: nil
); end
end
class Oxxo < Stripe::RequestParams; end
class P24 < Stripe::RequestParams
# The customer's bank.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class PayByBank < Stripe::RequestParams; end
class Payco < Stripe::RequestParams; end
class Paynow < Stripe::RequestParams; end
class Paypal < Stripe::RequestParams; end
class Payto < Stripe::RequestParams
# The account number for the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Bank-State-Branch number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :bsb_number
# The PayID alias for the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :pay_id
sig {
params(account_number: T.nilable(String), bsb_number: T.nilable(String), pay_id: T.nilable(String)).void
}
def initialize(account_number: nil, bsb_number: nil, pay_id: nil); end
end
class Pix < Stripe::RequestParams; end
class Promptpay < Stripe::RequestParams; end
class Qris < Stripe::RequestParams; end
class RadarOptions < Stripe::RequestParams
# A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
sig { returns(T.nilable(String)) }
attr_accessor :session
sig { params(session: T.nilable(String)).void }
def initialize(session: nil); end
end
class Rechnung < Stripe::RequestParams
class Dob < Stripe::RequestParams
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
# Customer's date of birth
sig {
returns(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Rechnung::Dob)
}
attr_accessor :dob
sig {
params(dob: ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Rechnung::Dob).void
}
def initialize(dob: nil); end
end
class RevolutPay < Stripe::RequestParams; end
class SamsungPay < Stripe::RequestParams; end
class Satispay < Stripe::RequestParams; end
class SepaDebit < Stripe::RequestParams
# IBAN of the bank account.
sig { returns(String) }
attr_accessor :iban
sig { params(iban: String).void }
def initialize(iban: nil); end
end
class Shopeepay < Stripe::RequestParams; end
class Sofort < Stripe::RequestParams
# Two-letter ISO code representing the country the bank account is located in.
sig { returns(String) }
attr_accessor :country
sig { params(country: String).void }
def initialize(country: nil); end
end
class StripeBalance < Stripe::RequestParams
# The connected account ID whose Stripe balance to use as the source of payment
sig { returns(T.nilable(String)) }
attr_accessor :account
# The [source_type](https://docs.stripe.com/api/balance/balance_object#balance_object-available-source_types) of the balance
sig { returns(T.nilable(String)) }
attr_accessor :source_type
sig { params(account: T.nilable(String), source_type: T.nilable(String)).void }
def initialize(account: nil, source_type: nil); end
end
class Swish < Stripe::RequestParams; end
class Twint < Stripe::RequestParams; end
class UsBankAccount < Stripe::RequestParams
# Account holder type: individual or company.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_type
# Account number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Account type: checkings or savings. Defaults to checking if omitted.
sig { returns(T.nilable(String)) }
attr_accessor :account_type
# The ID of a Financial Connections Account to use as a payment method.
sig { returns(T.nilable(String)) }
attr_accessor :financial_connections_account
# Routing number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :routing_number
sig {
params(account_holder_type: T.nilable(String), account_number: T.nilable(String), account_type: T.nilable(String), financial_connections_account: T.nilable(String), routing_number: T.nilable(String)).void
}
def initialize(
account_holder_type: nil,
account_number: nil,
account_type: nil,
financial_connections_account: nil,
routing_number: nil
); end
end
class WechatPay < Stripe::RequestParams; end
class Zip < Stripe::RequestParams; end
# If this is an `acss_debit` PaymentMethod, this hash contains details about the ACSS Debit payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::AcssDebit))
}
attr_accessor :acss_debit
# If this is an `affirm` PaymentMethod, this hash contains details about the Affirm payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Affirm))
}
attr_accessor :affirm
# If this is an `AfterpayClearpay` PaymentMethod, this hash contains details about the AfterpayClearpay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::AfterpayClearpay))
}
attr_accessor :afterpay_clearpay
# If this is an `Alipay` PaymentMethod, this hash contains details about the Alipay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Alipay))
}
attr_accessor :alipay
# This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :allow_redisplay
# If this is a Alma PaymentMethod, this hash contains details about the Alma payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Alma))
}
attr_accessor :alma
# If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::AmazonPay))
}
attr_accessor :amazon_pay
# If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::AuBecsDebit))
}
attr_accessor :au_becs_debit
# If this is a `bacs_debit` PaymentMethod, this hash contains details about the Bacs Direct Debit bank account.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::BacsDebit))
}
attr_accessor :bacs_debit
# If this is a `bancontact` PaymentMethod, this hash contains details about the Bancontact payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Bancontact))
}
attr_accessor :bancontact
# If this is a `billie` PaymentMethod, this hash contains details about the Billie payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Billie))
}
attr_accessor :billie
# Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::BillingDetails))
}
attr_accessor :billing_details
# If this is a `blik` PaymentMethod, this hash contains details about the BLIK payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Blik))
}
attr_accessor :blik
# If this is a `boleto` PaymentMethod, this hash contains details about the Boleto payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Boleto))
}
attr_accessor :boleto
# If this is a `cashapp` PaymentMethod, this hash contains details about the Cash App Pay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Cashapp))
}
attr_accessor :cashapp
# If this is a `customer_balance` PaymentMethod, this hash contains details about the CustomerBalance payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::CustomerBalance))
}
attr_accessor :customer_balance
# If this is an `eps` PaymentMethod, this hash contains details about the EPS payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Eps))
}
attr_accessor :eps
# If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Fpx))
}
attr_accessor :fpx
# If this is a `giropay` PaymentMethod, this hash contains details about the Giropay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Giropay))
}
attr_accessor :giropay
# If this is a Gopay PaymentMethod, this hash contains details about the Gopay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Gopay))
}
attr_accessor :gopay
# If this is a `grabpay` PaymentMethod, this hash contains details about the GrabPay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Grabpay))
}
attr_accessor :grabpay
# If this is an `IdBankTransfer` PaymentMethod, this hash contains details about the IdBankTransfer payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::IdBankTransfer))
}
attr_accessor :id_bank_transfer
# If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Ideal))
}
attr_accessor :ideal
# If this is an `interac_present` PaymentMethod, this hash contains details about the Interac Present payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::InteracPresent))
}
attr_accessor :interac_present
# If this is a `kakao_pay` PaymentMethod, this hash contains details about the Kakao Pay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::KakaoPay))
}
attr_accessor :kakao_pay
# If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Klarna))
}
attr_accessor :klarna
# If this is a `konbini` PaymentMethod, this hash contains details about the Konbini payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Konbini))
}
attr_accessor :konbini
# If this is a `kr_card` PaymentMethod, this hash contains details about the Korean Card payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::KrCard))
}
attr_accessor :kr_card
# If this is an `Link` PaymentMethod, this hash contains details about the Link payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Link))
}
attr_accessor :link
# If this is a MB WAY PaymentMethod, this hash contains details about the MB WAY payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::MbWay))
}
attr_accessor :mb_way
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# If this is a `mobilepay` PaymentMethod, this hash contains details about the MobilePay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Mobilepay))
}
attr_accessor :mobilepay
# If this is a `multibanco` PaymentMethod, this hash contains details about the Multibanco payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Multibanco))
}
attr_accessor :multibanco
# If this is a `naver_pay` PaymentMethod, this hash contains details about the Naver Pay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::NaverPay))
}
attr_accessor :naver_pay
# If this is an nz_bank_account PaymentMethod, this hash contains details about the nz_bank_account payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::NzBankAccount))
}
attr_accessor :nz_bank_account
# If this is an `oxxo` PaymentMethod, this hash contains details about the OXXO payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Oxxo))
}
attr_accessor :oxxo
# If this is a `p24` PaymentMethod, this hash contains details about the P24 payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::P24))
}
attr_accessor :p24
# If this is a `pay_by_bank` PaymentMethod, this hash contains details about the PayByBank payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::PayByBank))
}
attr_accessor :pay_by_bank
# If this is a `payco` PaymentMethod, this hash contains details about the PAYCO payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Payco))
}
attr_accessor :payco
# If this is a `paynow` PaymentMethod, this hash contains details about the PayNow payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Paynow))
}
attr_accessor :paynow
# If this is a `paypal` PaymentMethod, this hash contains details about the PayPal payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Paypal))
}
attr_accessor :paypal
# If this is a `payto` PaymentMethod, this hash contains details about the PayTo payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Payto))
}
attr_accessor :payto
# If this is a `pix` PaymentMethod, this hash contains details about the Pix payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Pix))
}
attr_accessor :pix
# If this is a `promptpay` PaymentMethod, this hash contains details about the PromptPay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Promptpay))
}
attr_accessor :promptpay
# If this is a `qris` PaymentMethod, this hash contains details about the QRIS payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Qris))
}
attr_accessor :qris
# Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::RadarOptions))
}
attr_accessor :radar_options
# If this is a `rechnung` PaymentMethod, this hash contains details about the Rechnung payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Rechnung))
}
attr_accessor :rechnung
# If this is a `revolut_pay` PaymentMethod, this hash contains details about the Revolut Pay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::RevolutPay))
}
attr_accessor :revolut_pay
# If this is a `samsung_pay` PaymentMethod, this hash contains details about the SamsungPay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::SamsungPay))
}
attr_accessor :samsung_pay
# If this is a `satispay` PaymentMethod, this hash contains details about the Satispay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Satispay))
}
attr_accessor :satispay
# If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::SepaDebit))
}
attr_accessor :sepa_debit
# If this is a Shopeepay PaymentMethod, this hash contains details about the Shopeepay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Shopeepay))
}
attr_accessor :shopeepay
# If this is a `sofort` PaymentMethod, this hash contains details about the SOFORT payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Sofort))
}
attr_accessor :sofort
# This hash contains details about the Stripe balance payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::StripeBalance))
}
attr_accessor :stripe_balance
# If this is a `swish` PaymentMethod, this hash contains details about the Swish payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Swish))
}
attr_accessor :swish
# If this is a TWINT PaymentMethod, this hash contains details about the TWINT payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Twint))
}
attr_accessor :twint
# The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
sig { returns(String) }
attr_accessor :type
# If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::UsBankAccount))
}
attr_accessor :us_bank_account
# If this is an `wechat_pay` PaymentMethod, this hash contains details about the wechat_pay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::WechatPay))
}
attr_accessor :wechat_pay
# If this is a `zip` PaymentMethod, this hash contains details about the Zip payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Zip))
}
attr_accessor :zip
sig {
params(acss_debit: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::AcssDebit), affirm: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Affirm), afterpay_clearpay: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::AfterpayClearpay), alipay: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Alipay), allow_redisplay: T.nilable(String), alma: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Alma), amazon_pay: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::AmazonPay), au_becs_debit: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::AuBecsDebit), bacs_debit: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::BacsDebit), bancontact: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Bancontact), billie: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Billie), billing_details: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::BillingDetails), blik: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Blik), boleto: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Boleto), cashapp: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Cashapp), customer_balance: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::CustomerBalance), eps: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Eps), fpx: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Fpx), giropay: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Giropay), gopay: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Gopay), grabpay: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Grabpay), id_bank_transfer: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::IdBankTransfer), ideal: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Ideal), interac_present: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::InteracPresent), kakao_pay: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::KakaoPay), klarna: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Klarna), konbini: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Konbini), kr_card: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::KrCard), link: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Link), mb_way: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::MbWay), metadata: T.nilable(T::Hash[String, String]), mobilepay: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Mobilepay), multibanco: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Multibanco), naver_pay: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::NaverPay), nz_bank_account: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::NzBankAccount), oxxo: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Oxxo), p24: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::P24), pay_by_bank: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::PayByBank), payco: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Payco), paynow: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Paynow), paypal: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Paypal), payto: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Payto), pix: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Pix), promptpay: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Promptpay), qris: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Qris), radar_options: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::RadarOptions), rechnung: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Rechnung), revolut_pay: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::RevolutPay), samsung_pay: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::SamsungPay), satispay: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Satispay), sepa_debit: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::SepaDebit), shopeepay: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Shopeepay), sofort: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Sofort), stripe_balance: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::StripeBalance), swish: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Swish), twint: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Twint), type: String, us_bank_account: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::UsBankAccount), wechat_pay: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::WechatPay), zip: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData::Zip)).void
}
def initialize(
acss_debit: nil,
affirm: nil,
afterpay_clearpay: nil,
alipay: nil,
allow_redisplay: nil,
alma: nil,
amazon_pay: nil,
au_becs_debit: nil,
bacs_debit: nil,
bancontact: nil,
billie: nil,
billing_details: nil,
blik: nil,
boleto: nil,
cashapp: nil,
customer_balance: nil,
eps: nil,
fpx: nil,
giropay: nil,
gopay: nil,
grabpay: nil,
id_bank_transfer: nil,
ideal: nil,
interac_present: nil,
kakao_pay: nil,
klarna: nil,
konbini: nil,
kr_card: nil,
link: nil,
mb_way: nil,
metadata: nil,
mobilepay: nil,
multibanco: nil,
naver_pay: nil,
nz_bank_account: nil,
oxxo: nil,
p24: nil,
pay_by_bank: nil,
payco: nil,
paynow: nil,
paypal: nil,
payto: nil,
pix: nil,
promptpay: nil,
qris: nil,
radar_options: nil,
rechnung: nil,
revolut_pay: nil,
samsung_pay: nil,
satispay: nil,
sepa_debit: nil,
shopeepay: nil,
sofort: nil,
stripe_balance: nil,
swish: nil,
twint: nil,
type: nil,
us_bank_account: nil,
wechat_pay: nil,
zip: nil
); end
end
class PaymentMethodOptions < Stripe::RequestParams
class AcssDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# A URL for custom mandate text to render during confirmation step.
# The URL will be rendered with additional GET parameters `payment_intent` and `payment_intent_client_secret` when confirming a Payment Intent,
# or `setup_intent` and `setup_intent_client_secret` when confirming a Setup Intent.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :custom_mandate_url
# Description of the mandate interval. Only required if 'payment_schedule' parameter is 'interval' or 'combined'.
sig { returns(T.nilable(String)) }
attr_accessor :interval_description
# Payment schedule for the mandate.
sig { returns(T.nilable(String)) }
attr_accessor :payment_schedule
# Transaction type of the mandate.
sig { returns(T.nilable(String)) }
attr_accessor :transaction_type
sig {
params(custom_mandate_url: T.nilable(T.nilable(String)), interval_description: T.nilable(String), payment_schedule: T.nilable(String), transaction_type: T.nilable(String)).void
}
def initialize(
custom_mandate_url: nil,
interval_description: nil,
payment_schedule: nil,
transaction_type: nil
); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::AcssDebit::MandateOptions))
}
attr_accessor :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
# Bank account verification method.
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(mandate_options: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::AcssDebit::MandateOptions), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), target_date: T.nilable(String), verification_method: T.nilable(String)).void
}
def initialize(
mandate_options: nil,
setup_future_usage: nil,
target_date: nil,
verification_method: nil
); end
end
class Affirm < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Preferred language of the Affirm authorization page that the customer is redirected to.
sig { returns(T.nilable(String)) }
attr_accessor :preferred_locale
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), preferred_locale: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(capture_method: nil, preferred_locale: nil, setup_future_usage: nil); end
end
class AfterpayClearpay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# An internal identifier or reference that this payment corresponds to. You must limit the identifier to 128 characters, and it can only contain letters, numbers, underscores, backslashes, and dashes.
# This field differs from the statement descriptor and item name.
sig { returns(T.nilable(String)) }
attr_accessor :reference
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), reference: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(capture_method: nil, reference: nil, setup_future_usage: nil); end
end
class Alipay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void }
def initialize(setup_future_usage: nil); end
end
class Alma < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
sig { params(capture_method: T.nilable(T.nilable(String))).void }
def initialize(capture_method: nil); end
end
class AmazonPay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class AuBecsDebit < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
sig {
params(setup_future_usage: T.nilable(T.nilable(T.any(String, String))), target_date: T.nilable(String)).void
}
def initialize(setup_future_usage: nil, target_date: nil); end
end
class BacsDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'DDIC' or 'STRIPE'.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :reference_prefix
sig { params(reference_prefix: T.nilable(T.nilable(String))).void }
def initialize(reference_prefix: nil); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::BacsDebit::MandateOptions))
}
attr_accessor :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
sig {
params(mandate_options: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::BacsDebit::MandateOptions), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), target_date: T.nilable(String)).void
}
def initialize(mandate_options: nil, setup_future_usage: nil, target_date: nil); end
end
class Bancontact < Stripe::RequestParams
# Preferred language of the Bancontact authorization page that the customer is redirected to.
sig { returns(T.nilable(String)) }
attr_accessor :preferred_language
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(preferred_language: T.nilable(String), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(preferred_language: nil, setup_future_usage: nil); end
end
class Billie < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
sig { params(capture_method: T.nilable(T.nilable(String))).void }
def initialize(capture_method: nil); end
end
class Blik < Stripe::RequestParams
# The 6-digit BLIK code that a customer has generated using their banking application. Can only be set on confirmation.
sig { returns(T.nilable(String)) }
attr_accessor :code
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :setup_future_usage
sig {
params(code: T.nilable(String), setup_future_usage: T.nilable(T.nilable(String))).void
}
def initialize(code: nil, setup_future_usage: nil); end
end
class Boleto < Stripe::RequestParams
# The number of calendar days before a Boleto voucher expires. For example, if you create a Boleto voucher on Monday and you set expires_after_days to 2, the Boleto invoice will expire on Wednesday at 23:59 America/Sao_Paulo time.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_after_days
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(expires_after_days: T.nilable(Integer), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(expires_after_days: nil, setup_future_usage: nil); end
end
class Card < Stripe::RequestParams
class Installments < Stripe::RequestParams
class Plan < Stripe::RequestParams
# For `fixed_count` installment plans, this is required. It represents the number of installment payments your customer will make to their credit card.
sig { returns(T.nilable(Integer)) }
attr_accessor :count
# For `fixed_count` installment plans, this is required. It represents the interval between installment payments your customer will make to their credit card.
# One of `month`.
sig { returns(T.nilable(String)) }
attr_accessor :interval
# Type of installment plan, one of `fixed_count`.
sig { returns(String) }
attr_accessor :type
sig {
params(count: T.nilable(Integer), interval: T.nilable(String), type: String).void
}
def initialize(count: nil, interval: nil, type: nil); end
end
# Setting to true enables installments for this PaymentIntent.
# This will cause the response to contain a list of available installment plans.
# Setting to false will prevent any selected plan from applying to a charge.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :enabled
# The selected installment plan to use for this payment attempt.
# This parameter can only be provided during confirmation.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Card::Installments::Plan))))
}
attr_accessor :plan
sig {
params(enabled: T.nilable(T::Boolean), plan: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Card::Installments::Plan)))).void
}
def initialize(enabled: nil, plan: nil); end
end
class MandateOptions < Stripe::RequestParams
# Amount to be charged for future payments.
sig { returns(Integer) }
attr_accessor :amount
# One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.
sig { returns(String) }
attr_accessor :amount_type
# A description of the mandate or subscription that is meant to be displayed to the customer.
sig { returns(T.nilable(String)) }
attr_accessor :description
# End date of the mandate or subscription. If not provided, the mandate will be active until canceled. If provided, end date should be after start date.
sig { returns(T.nilable(Integer)) }
attr_accessor :end_date
# Specifies payment frequency. One of `day`, `week`, `month`, `year`, or `sporadic`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals between payments. For example, `interval=month` and `interval_count=3` indicates one payment every three months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks). This parameter is optional when `interval=sporadic`.
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_count
# Unique identifier for the mandate or subscription.
sig { returns(String) }
attr_accessor :reference
# Start date of the mandate or subscription. Start date should not be lesser than yesterday.
sig { returns(Integer) }
attr_accessor :start_date
# Specifies the type of mandates supported. Possible values are `india`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :supported_types
sig {
params(amount: Integer, amount_type: String, description: T.nilable(String), end_date: T.nilable(Integer), interval: String, interval_count: T.nilable(Integer), reference: String, start_date: Integer, supported_types: T.nilable(T::Array[String])).void
}
def initialize(
amount: nil,
amount_type: nil,
description: nil,
end_date: nil,
interval: nil,
interval_count: nil,
reference: nil,
start_date: nil,
supported_types: nil
); end
end
class StatementDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Please pass in an address that is within your Stripe user account country
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Card::StatementDetails::Address))
}
attr_accessor :address
# Phone number (e.g., a toll-free number that customers can call)
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(address: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Card::StatementDetails::Address), phone: T.nilable(String)).void
}
def initialize(address: nil, phone: nil); end
end
class ThreeDSecure < Stripe::RequestParams
class NetworkOptions < Stripe::RequestParams
class CartesBancaires < Stripe::RequestParams
# The cryptogram calculation algorithm used by the card Issuer's ACS
# to calculate the Authentication cryptogram. Also known as `cavvAlgorithm`.
# messageExtension: CB-AVALGO
sig { returns(String) }
attr_accessor :cb_avalgo
# The exemption indicator returned from Cartes Bancaires in the ARes.
# message extension: CB-EXEMPTION; string (4 characters)
# This is a 3 byte bitmap (low significant byte first and most significant
# bit first) that has been Base64 encoded
sig { returns(T.nilable(String)) }
attr_accessor :cb_exemption
# The risk score returned from Cartes Bancaires in the ARes.
# message extension: CB-SCORE; numeric value 0-99
sig { returns(T.nilable(Integer)) }
attr_accessor :cb_score
sig {
params(cb_avalgo: String, cb_exemption: T.nilable(String), cb_score: T.nilable(Integer)).void
}
def initialize(cb_avalgo: nil, cb_exemption: nil, cb_score: nil); end
end
# Cartes Bancaires-specific 3DS fields.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions::CartesBancaires))
}
attr_accessor :cartes_bancaires
sig {
params(cartes_bancaires: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions::CartesBancaires)).void
}
def initialize(cartes_bancaires: nil); end
end
# The `transStatus` returned from the card Issuer’s ACS in the ARes.
sig { returns(T.nilable(String)) }
attr_accessor :ares_trans_status
# The cryptogram, also known as the "authentication value" (AAV, CAVV or
# AEVV). This value is 20 bytes, base64-encoded into a 28-character string.
# (Most 3D Secure providers will return the base64-encoded version, which
# is what you should specify here.)
sig { returns(String) }
attr_accessor :cryptogram
# The Electronic Commerce Indicator (ECI) is returned by your 3D Secure
# provider and indicates what degree of authentication was performed.
sig { returns(T.nilable(String)) }
attr_accessor :electronic_commerce_indicator
# The exemption requested via 3DS and accepted by the issuer at authentication time.
sig { returns(T.nilable(String)) }
attr_accessor :exemption_indicator
# Network specific 3DS fields. Network specific arguments require an
# explicit card brand choice. The parameter `payment_method_options.card.network``
# must be populated accordingly
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions))
}
attr_accessor :network_options
# The challenge indicator (`threeDSRequestorChallengeInd`) which was requested in the
# AReq sent to the card Issuer's ACS. A string containing 2 digits from 01-99.
sig { returns(T.nilable(String)) }
attr_accessor :requestor_challenge_indicator
# For 3D Secure 1, the XID. For 3D Secure 2, the Directory Server
# Transaction ID (dsTransID).
sig { returns(String) }
attr_accessor :transaction_id
# The version of 3D Secure that was performed.
sig { returns(String) }
attr_accessor :version
sig {
params(ares_trans_status: T.nilable(String), cryptogram: String, electronic_commerce_indicator: T.nilable(String), exemption_indicator: T.nilable(String), network_options: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions), requestor_challenge_indicator: T.nilable(String), transaction_id: String, version: String).void
}
def initialize(
ares_trans_status: nil,
cryptogram: nil,
electronic_commerce_indicator: nil,
exemption_indicator: nil,
network_options: nil,
requestor_challenge_indicator: nil,
transaction_id: nil,
version: nil
); end
end
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# A single-use `cvc_update` Token that represents a card CVC value. When provided, the CVC value will be verified during the card payment attempt. This parameter can only be provided during confirmation.
sig { returns(T.nilable(String)) }
attr_accessor :cvc_token
# Installment configuration for payments attempted on this PaymentIntent (Mexico Only).
#
# For more information, see the [installments integration guide](https://stripe.com/docs/payments/installments).
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Card::Installments))
}
attr_accessor :installments
# Configuration options for setting up an eMandate for cards issued in India.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Card::MandateOptions))
}
attr_accessor :mandate_options
# When specified, this parameter indicates that a transaction will be marked
# as MOTO (Mail Order Telephone Order) and thus out of scope for SCA. This
# parameter can only be provided during confirmation.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :moto
# Selected network to process this PaymentIntent on. Depends on the available networks of the card attached to the PaymentIntent. Can be only set confirm-time.
sig { returns(T.nilable(String)) }
attr_accessor :network
# Request ability to [decrement the authorization](https://stripe.com/docs/payments/decremental-authorization) for this PaymentIntent.
sig { returns(T.nilable(String)) }
attr_accessor :request_decremental_authorization
# Request ability to [capture beyond the standard authorization validity window](https://stripe.com/docs/payments/extended-authorization) for this PaymentIntent.
sig { returns(T.nilable(String)) }
attr_accessor :request_extended_authorization
# Request ability to [increment the authorization](https://stripe.com/docs/payments/incremental-authorization) for this PaymentIntent.
sig { returns(T.nilable(String)) }
attr_accessor :request_incremental_authorization
# Request ability to make [multiple captures](https://stripe.com/docs/payments/multicapture) for this PaymentIntent.
sig { returns(T.nilable(String)) }
attr_accessor :request_multicapture
# Request ability to [overcapture](https://stripe.com/docs/payments/overcapture) for this PaymentIntent.
sig { returns(T.nilable(String)) }
attr_accessor :request_overcapture
# Request partial authorization on this PaymentIntent.
sig { returns(T.nilable(String)) }
attr_accessor :request_partial_authorization
# We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. If not provided, this value defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
sig { returns(T.nilable(String)) }
attr_accessor :request_three_d_secure
# When enabled, using a card that is attached to a customer will require the CVC to be provided again (i.e. using the cvc_token parameter).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :require_cvc_recollection
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Provides information about a card payment that customers see on their statements. Concatenated with the Kana prefix (shortened Kana descriptor) or Kana statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 22 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 22 characters.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :statement_descriptor_suffix_kana
# Provides information about a card payment that customers see on their statements. Concatenated with the Kanji prefix (shortened Kanji descriptor) or Kanji statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 17 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 17 characters.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :statement_descriptor_suffix_kanji
# Statement details for this payment intent. You can use this to override the merchant details shown on your customers' statements.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Card::StatementDetails))))
}
attr_accessor :statement_details
# If 3D Secure authentication was performed with a third-party provider,
# the authentication details to use for this payment.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Card::ThreeDSecure))
}
attr_accessor :three_d_secure
sig {
params(capture_method: T.nilable(T.nilable(String)), cvc_token: T.nilable(String), installments: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Card::Installments), mandate_options: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Card::MandateOptions), moto: T.nilable(T::Boolean), network: T.nilable(String), request_decremental_authorization: T.nilable(String), request_extended_authorization: T.nilable(String), request_incremental_authorization: T.nilable(String), request_multicapture: T.nilable(String), request_overcapture: T.nilable(String), request_partial_authorization: T.nilable(String), request_three_d_secure: T.nilable(String), require_cvc_recollection: T.nilable(T::Boolean), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), statement_descriptor_suffix_kana: T.nilable(T.nilable(String)), statement_descriptor_suffix_kanji: T.nilable(T.nilable(String)), statement_details: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Card::StatementDetails))), three_d_secure: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Card::ThreeDSecure)).void
}
def initialize(
capture_method: nil,
cvc_token: nil,
installments: nil,
mandate_options: nil,
moto: nil,
network: nil,
request_decremental_authorization: nil,
request_extended_authorization: nil,
request_incremental_authorization: nil,
request_multicapture: nil,
request_overcapture: nil,
request_partial_authorization: nil,
request_three_d_secure: nil,
require_cvc_recollection: nil,
setup_future_usage: nil,
statement_descriptor_suffix_kana: nil,
statement_descriptor_suffix_kanji: nil,
statement_details: nil,
three_d_secure: nil
); end
end
class CardPresent < Stripe::RequestParams
class Routing < Stripe::RequestParams
# Routing requested priority
sig { returns(T.nilable(String)) }
attr_accessor :requested_priority
sig { params(requested_priority: T.nilable(String)).void }
def initialize(requested_priority: nil); end
end
# Request ability to capture this payment beyond the standard [authorization validity window](https://stripe.com/docs/terminal/features/extended-authorizations#authorization-validity)
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :request_extended_authorization
# Request ability to [increment](https://stripe.com/docs/terminal/features/incremental-authorizations) this PaymentIntent if the combination of MCC and card brand is eligible. Check [incremental_authorization_supported](https://stripe.com/docs/api/charges/object#charge_object-payment_method_details-card_present-incremental_authorization_supported) in the [Confirm](https://stripe.com/docs/api/payment_intents/confirm) response to verify support.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :request_incremental_authorization_support
# Network routing priority on co-branded EMV cards supporting domestic debit and international card schemes.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::CardPresent::Routing))
}
attr_accessor :routing
sig {
params(request_extended_authorization: T.nilable(T::Boolean), request_incremental_authorization_support: T.nilable(T::Boolean), routing: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::CardPresent::Routing)).void
}
def initialize(
request_extended_authorization: nil,
request_incremental_authorization_support: nil,
routing: nil
); end
end
class Cashapp < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class CustomerBalance < Stripe::RequestParams
class BankTransfer < Stripe::RequestParams
class EuBankTransfer < Stripe::RequestParams
# The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
sig { returns(String) }
attr_accessor :country
sig { params(country: String).void }
def initialize(country: nil); end
end
# Configuration for the eu_bank_transfer funding type.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::CustomerBalance::BankTransfer::EuBankTransfer))
}
attr_accessor :eu_bank_transfer
# List of address types that should be returned in the financial_addresses response. If not specified, all valid types will be returned.
#
# Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :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`, `mx_bank_transfer`, or `us_bank_transfer`.
sig { returns(String) }
attr_accessor :type
sig {
params(eu_bank_transfer: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::CustomerBalance::BankTransfer::EuBankTransfer), requested_address_types: T.nilable(T::Array[String]), type: String).void
}
def initialize(eu_bank_transfer: nil, requested_address_types: nil, type: nil); end
end
# Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::CustomerBalance::BankTransfer))
}
attr_accessor :bank_transfer
# The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
sig { returns(T.nilable(String)) }
attr_accessor :funding_type
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(bank_transfer: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::CustomerBalance::BankTransfer), funding_type: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(bank_transfer: nil, funding_type: nil, setup_future_usage: nil); end
end
class Eps < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Fpx < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Giropay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Gopay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Grabpay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class IdBankTransfer < Stripe::RequestParams
# The UNIX timestamp until which the virtual bank account is valid. Permitted range is from 5 minutes from now until 31 days from now. If unset, it defaults to 3 days from now.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_after
# The UNIX timestamp until which the virtual bank account is valid. Permitted range is from now until 30 days from now. If unset, it defaults to 1 days from now.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_at
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(expires_after: T.nilable(Integer), expires_at: T.nilable(Integer), setup_future_usage: T.nilable(String)).void
}
def initialize(expires_after: nil, expires_at: nil, setup_future_usage: nil); end
end
class Ideal < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void }
def initialize(setup_future_usage: nil); end
end
class InteracPresent < Stripe::RequestParams; end
class KakaoPay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class Klarna < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Preferred language of the Klarna authorization page that the customer is redirected to
sig { returns(T.nilable(String)) }
attr_accessor :preferred_locale
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), preferred_locale: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(capture_method: nil, preferred_locale: nil, setup_future_usage: nil); end
end
class Konbini < Stripe::RequestParams
# An optional 10 to 11 digit numeric-only string determining the confirmation code at applicable convenience stores. Must not consist of only zeroes and could be rejected in case of insufficient uniqueness. We recommend to use the customer's phone number.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :confirmation_number
# The number of calendar days (between 1 and 60) after which Konbini payment instructions will expire. For example, if a PaymentIntent is confirmed with Konbini and `expires_after_days` set to 2 on Monday JST, the instructions will expire on Wednesday 23:59:59 JST. Defaults to 3 days.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :expires_after_days
# The timestamp at which the Konbini payment instructions will expire. Only one of `expires_after_days` or `expires_at` may be set.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :expires_at
# A product descriptor of up to 22 characters, which will appear to customers at the convenience store.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :product_description
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(confirmation_number: T.nilable(T.nilable(String)), expires_after_days: T.nilable(T.nilable(T.any(String, Integer))), expires_at: T.nilable(T.nilable(T.any(String, Integer))), product_description: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(String)).void
}
def initialize(
confirmation_number: nil,
expires_after_days: nil,
expires_at: nil,
product_description: nil,
setup_future_usage: nil
); end
end
class KrCard < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class Link < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# [Deprecated] This is a legacy parameter that no longer has any function.
sig { returns(T.nilable(String)) }
attr_accessor :persistent_token
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), persistent_token: T.nilable(String), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(capture_method: nil, persistent_token: nil, setup_future_usage: nil); end
end
class MbWay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Mobilepay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(String)).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class Multibanco < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class NaverPay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class NzBankAccount < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
sig {
params(setup_future_usage: T.nilable(T.nilable(T.any(String, String))), target_date: T.nilable(String)).void
}
def initialize(setup_future_usage: nil, target_date: nil); end
end
class Oxxo < Stripe::RequestParams
# The number of calendar days before an OXXO voucher expires. For example, if you create an OXXO voucher on Monday and you set expires_after_days to 2, the OXXO invoice will expire on Wednesday at 23:59 America/Mexico_City time.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_after_days
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(expires_after_days: T.nilable(Integer), setup_future_usage: T.nilable(String)).void
}
def initialize(expires_after_days: nil, setup_future_usage: nil); end
end
class P24 < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
# Confirm that the payer has accepted the P24 terms and conditions.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :tos_shown_and_accepted
sig {
params(setup_future_usage: T.nilable(String), tos_shown_and_accepted: T.nilable(T::Boolean)).void
}
def initialize(setup_future_usage: nil, tos_shown_and_accepted: nil); end
end
class PayByBank < Stripe::RequestParams; end
class Payco < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
sig { params(capture_method: T.nilable(T.nilable(String))).void }
def initialize(capture_method: nil); end
end
class Paynow < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Paypal < Stripe::RequestParams
class LineItem < Stripe::RequestParams
class Tax < Stripe::RequestParams
# The tax for a single unit of the line item in minor units. Cannot be a negative number.
sig { returns(Integer) }
attr_accessor :amount
# The tax behavior for the line item.
sig { returns(String) }
attr_accessor :behavior
sig { params(amount: Integer, behavior: String).void }
def initialize(amount: nil, behavior: nil); end
end
# Type of the line item.
sig { returns(T.nilable(String)) }
attr_accessor :category
# Description of the line item.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Descriptive name of the line item.
sig { returns(String) }
attr_accessor :name
# Quantity of the line item. Must be a positive number.
sig { returns(Integer) }
attr_accessor :quantity
# Client facing stock keeping unit, article number or similar.
sig { returns(T.nilable(String)) }
attr_accessor :sku
# The Stripe account ID of the connected account that sells the item.
sig { returns(T.nilable(String)) }
attr_accessor :sold_by
# The tax information for the line item.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Paypal::LineItem::Tax))
}
attr_accessor :tax
# Price for a single unit of the line item in minor units. Cannot be a negative number.
sig { returns(Integer) }
attr_accessor :unit_amount
sig {
params(category: T.nilable(String), description: T.nilable(String), name: String, quantity: Integer, sku: T.nilable(String), sold_by: T.nilable(String), tax: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Paypal::LineItem::Tax), unit_amount: Integer).void
}
def initialize(
category: nil,
description: nil,
name: nil,
quantity: nil,
sku: nil,
sold_by: nil,
tax: nil,
unit_amount: nil
); end
end
# Controls when the funds will be captured from the customer's account.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# The line items purchased by the customer.
sig {
returns(T.nilable(T::Array[::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Paypal::LineItem]))
}
attr_accessor :line_items
# [Preferred locale](https://stripe.com/docs/payments/paypal/supported-locales) of the PayPal checkout page that the customer is redirected to.
sig { returns(T.nilable(String)) }
attr_accessor :preferred_locale
# A reference of the PayPal transaction visible to customer which is mapped to PayPal's invoice ID. This must be a globally unique ID if you have configured in your PayPal settings to block multiple payments per invoice ID.
sig { returns(T.nilable(String)) }
attr_accessor :reference
# A reference of the PayPal transaction visible to customer which is mapped to PayPal's invoice ID. This must be a globally unique ID if you have configured in your PayPal settings to block multiple payments per invoice ID.
sig { returns(T.nilable(String)) }
attr_accessor :reference_id
# The risk correlation ID for an on-session payment using a saved PayPal payment method.
sig { returns(T.nilable(String)) }
attr_accessor :risk_correlation_id
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# The Stripe connected account IDs of the sellers on the platform for this transaction (optional). Only allowed when [separate charges and transfers](https://stripe.com/docs/connect/separate-charges-and-transfers) are used.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :subsellers
sig {
params(capture_method: T.nilable(T.nilable(String)), line_items: T.nilable(T::Array[::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Paypal::LineItem]), preferred_locale: T.nilable(String), reference: T.nilable(String), reference_id: T.nilable(String), risk_correlation_id: T.nilable(String), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), subsellers: T.nilable(T::Array[String])).void
}
def initialize(
capture_method: nil,
line_items: nil,
preferred_locale: nil,
reference: nil,
reference_id: nil,
risk_correlation_id: nil,
setup_future_usage: nil,
subsellers: nil
); end
end
class Payto < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Amount that will be collected. It is required when `amount_type` is `fixed`.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# The type of amount that will be collected. The amount charged must be exact or up to the value of `amount` param for `fixed` or `maximum` type respectively.
sig { returns(T.nilable(String)) }
attr_accessor :amount_type
# Date, in YYYY-MM-DD format, after which payments will not be collected. Defaults to no end date.
sig { returns(T.nilable(String)) }
attr_accessor :end_date
# The periodicity at which payments will be collected.
sig { returns(T.nilable(String)) }
attr_accessor :payment_schedule
# The number of payments that will be made during a payment period. Defaults to 1 except for when `payment_schedule` is `adhoc`. In that case, it defaults to no limit.
sig { returns(T.nilable(Integer)) }
attr_accessor :payments_per_period
# The purpose for which payments are made. Defaults to retail.
sig { returns(T.nilable(String)) }
attr_accessor :purpose
sig {
params(amount: T.nilable(Integer), amount_type: T.nilable(String), end_date: T.nilable(String), payment_schedule: T.nilable(String), payments_per_period: T.nilable(Integer), purpose: T.nilable(String)).void
}
def initialize(
amount: nil,
amount_type: nil,
end_date: nil,
payment_schedule: nil,
payments_per_period: nil,
purpose: nil
); end
end
# Additional fields for Mandate creation. Only `purpose` field is configurable for PayTo PaymentIntent with `setup_future_usage=none`. Other fields are only applicable to PayTo PaymentIntent with `setup_future_usage=off_session`
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Payto::MandateOptions))
}
attr_accessor :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(mandate_options: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Payto::MandateOptions), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(mandate_options: nil, setup_future_usage: nil); end
end
class Pix < Stripe::RequestParams
# The number of seconds (between 10 and 1209600) after which Pix payment will expire. Defaults to 86400 seconds.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_after_seconds
# The timestamp at which the Pix expires (between 10 and 1209600 seconds in the future). Defaults to 1 day in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_at
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(expires_after_seconds: T.nilable(Integer), expires_at: T.nilable(Integer), setup_future_usage: T.nilable(String)).void
}
def initialize(expires_after_seconds: nil, expires_at: nil, setup_future_usage: nil); end
end
class Promptpay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Qris < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Rechnung < Stripe::RequestParams; end
class RevolutPay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class SamsungPay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
sig { params(capture_method: T.nilable(T.nilable(String))).void }
def initialize(capture_method: nil); end
end
class Satispay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
sig { params(capture_method: T.nilable(T.nilable(String))).void }
def initialize(capture_method: nil); end
end
class SepaDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'STRIPE'.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :reference_prefix
sig { params(reference_prefix: T.nilable(T.nilable(String))).void }
def initialize(reference_prefix: nil); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::SepaDebit::MandateOptions))
}
attr_accessor :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
sig {
params(mandate_options: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::SepaDebit::MandateOptions), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), target_date: T.nilable(String)).void
}
def initialize(mandate_options: nil, setup_future_usage: nil, target_date: nil); end
end
class Shopeepay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Sofort < Stripe::RequestParams
# Language shown to the payer on redirect.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :preferred_language
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(preferred_language: T.nilable(T.nilable(T.any(String, String))), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(preferred_language: nil, setup_future_usage: nil); end
end
class StripeBalance < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void }
def initialize(setup_future_usage: nil); end
end
class Swish < Stripe::RequestParams
# A reference for this payment to be displayed in the Swish app.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :reference
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(reference: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(String)).void
}
def initialize(reference: nil, setup_future_usage: nil); end
end
class Twint < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class UsBankAccount < Stripe::RequestParams
class FinancialConnections < Stripe::RequestParams
class Filters < Stripe::RequestParams
# The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :account_subcategories
# ID of the institution to use to filter for selectable accounts.
sig { returns(T.nilable(String)) }
attr_accessor :institution
sig {
params(account_subcategories: T.nilable(T::Array[String]), institution: T.nilable(String)).void
}
def initialize(account_subcategories: nil, institution: nil); end
end
class ManualEntry < Stripe::RequestParams
# Settings for configuring manual entry of account details.
sig { returns(String) }
attr_accessor :mode
sig { params(mode: String).void }
def initialize(mode: nil); end
end
# Provide filters for the linked accounts that the customer can select for the payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::Filters))
}
attr_accessor :filters
# Customize manual entry behavior
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::ManualEntry))
}
attr_accessor :manual_entry
# The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :permissions
# List of data features that you would like to retrieve upon account creation.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :prefetch
# For webview integrations only. Upon completing OAuth login in the native browser, the user will be redirected to this URL to return to your app.
sig { returns(T.nilable(String)) }
attr_accessor :return_url
sig {
params(filters: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::Filters), manual_entry: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::ManualEntry), permissions: T.nilable(T::Array[String]), prefetch: T.nilable(T::Array[String]), return_url: T.nilable(String)).void
}
def initialize(
filters: nil,
manual_entry: nil,
permissions: nil,
prefetch: nil,
return_url: nil
); end
end
class MandateOptions < Stripe::RequestParams
# The method used to collect offline mandate customer acceptance.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :collection_method
sig { params(collection_method: T.nilable(T.nilable(String))).void }
def initialize(collection_method: nil); end
end
class Networks < Stripe::RequestParams
# Triggers validations to run across the selected networks
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Array[String])).void }
def initialize(requested: nil); end
end
# Additional fields for Financial Connections Session creation
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections))
}
attr_accessor :financial_connections
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::UsBankAccount::MandateOptions))
}
attr_accessor :mandate_options
# Additional fields for network related functions
sig {
returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::UsBankAccount::Networks))
}
attr_accessor :networks
# Preferred transaction settlement speed
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :preferred_settlement_speed
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
# Bank account verification method.
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(financial_connections: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections), mandate_options: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::UsBankAccount::MandateOptions), networks: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::UsBankAccount::Networks), preferred_settlement_speed: T.nilable(T.nilable(T.any(String, String))), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), target_date: T.nilable(String), verification_method: T.nilable(String)).void
}
def initialize(
financial_connections: nil,
mandate_options: nil,
networks: nil,
preferred_settlement_speed: nil,
setup_future_usage: nil,
target_date: nil,
verification_method: nil
); end
end
class WechatPay < Stripe::RequestParams
# The app ID registered with WeChat Pay. Only required when client is ios or android.
sig { returns(T.nilable(String)) }
attr_accessor :app_id
# The client type that the end customer will pay from
sig { returns(T.nilable(String)) }
attr_accessor :client
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(app_id: T.nilable(String), client: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(app_id: nil, client: nil, setup_future_usage: nil); end
end
class Zip < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
# If this is a `acss_debit` PaymentMethod, this sub-hash contains details about the ACSS Debit payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::AcssDebit))))
}
attr_accessor :acss_debit
# If this is an `affirm` PaymentMethod, this sub-hash contains details about the Affirm payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Affirm))))
}
attr_accessor :affirm
# If this is a `afterpay_clearpay` PaymentMethod, this sub-hash contains details about the Afterpay Clearpay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::AfterpayClearpay))))
}
attr_accessor :afterpay_clearpay
# If this is a `alipay` PaymentMethod, this sub-hash contains details about the Alipay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Alipay))))
}
attr_accessor :alipay
# If this is a `alma` PaymentMethod, this sub-hash contains details about the Alma payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Alma))))
}
attr_accessor :alma
# If this is a `amazon_pay` PaymentMethod, this sub-hash contains details about the Amazon Pay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::AmazonPay))))
}
attr_accessor :amazon_pay
# If this is a `au_becs_debit` PaymentMethod, this sub-hash contains details about the AU BECS Direct Debit payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::AuBecsDebit))))
}
attr_accessor :au_becs_debit
# If this is a `bacs_debit` PaymentMethod, this sub-hash contains details about the BACS Debit payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::BacsDebit))))
}
attr_accessor :bacs_debit
# If this is a `bancontact` PaymentMethod, this sub-hash contains details about the Bancontact payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Bancontact))))
}
attr_accessor :bancontact
# If this is a `billie` PaymentMethod, this sub-hash contains details about the Billie payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Billie))))
}
attr_accessor :billie
# If this is a `blik` PaymentMethod, this sub-hash contains details about the BLIK payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Blik))))
}
attr_accessor :blik
# If this is a `boleto` PaymentMethod, this sub-hash contains details about the Boleto payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Boleto))))
}
attr_accessor :boleto
# Configuration for any card payments attempted on this PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Card))))
}
attr_accessor :card
# If this is a `card_present` PaymentMethod, this sub-hash contains details about the Card Present payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::CardPresent))))
}
attr_accessor :card_present
# If this is a `cashapp` PaymentMethod, this sub-hash contains details about the Cash App Pay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Cashapp))))
}
attr_accessor :cashapp
# If this is a `customer balance` PaymentMethod, this sub-hash contains details about the customer balance payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::CustomerBalance))))
}
attr_accessor :customer_balance
# If this is a `eps` PaymentMethod, this sub-hash contains details about the EPS payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Eps))))
}
attr_accessor :eps
# If this is a `fpx` PaymentMethod, this sub-hash contains details about the FPX payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Fpx))))
}
attr_accessor :fpx
# If this is a `giropay` PaymentMethod, this sub-hash contains details about the Giropay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Giropay))))
}
attr_accessor :giropay
# If this is a `gopay` PaymentMethod, this sub-hash contains details about the Gopay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Gopay))))
}
attr_accessor :gopay
# If this is a `grabpay` PaymentMethod, this sub-hash contains details about the Grabpay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Grabpay))))
}
attr_accessor :grabpay
# If this is a `id_bank_transfer` PaymentMethod, this sub-hash contains details about the Indonesia Bank Transfer payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::IdBankTransfer))))
}
attr_accessor :id_bank_transfer
# If this is a `ideal` PaymentMethod, this sub-hash contains details about the Ideal payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Ideal))))
}
attr_accessor :ideal
# If this is a `interac_present` PaymentMethod, this sub-hash contains details about the Card Present payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::InteracPresent))))
}
attr_accessor :interac_present
# If this is a `kakao_pay` PaymentMethod, this sub-hash contains details about the Kakao Pay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::KakaoPay))))
}
attr_accessor :kakao_pay
# If this is a `klarna` PaymentMethod, this sub-hash contains details about the Klarna payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Klarna))))
}
attr_accessor :klarna
# If this is a `konbini` PaymentMethod, this sub-hash contains details about the Konbini payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Konbini))))
}
attr_accessor :konbini
# If this is a `kr_card` PaymentMethod, this sub-hash contains details about the KR Card payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::KrCard))))
}
attr_accessor :kr_card
# If this is a `link` PaymentMethod, this sub-hash contains details about the Link payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Link))))
}
attr_accessor :link
# If this is a `mb_way` PaymentMethod, this sub-hash contains details about the MB WAY payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::MbWay))))
}
attr_accessor :mb_way
# If this is a `MobilePay` PaymentMethod, this sub-hash contains details about the MobilePay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Mobilepay))))
}
attr_accessor :mobilepay
# If this is a `multibanco` PaymentMethod, this sub-hash contains details about the Multibanco payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Multibanco))))
}
attr_accessor :multibanco
# If this is a `naver_pay` PaymentMethod, this sub-hash contains details about the Naver Pay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::NaverPay))))
}
attr_accessor :naver_pay
# If this is a `nz_bank_account` PaymentMethod, this sub-hash contains details about the NZ BECS Direct Debit payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::NzBankAccount))))
}
attr_accessor :nz_bank_account
# If this is a `oxxo` PaymentMethod, this sub-hash contains details about the OXXO payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Oxxo))))
}
attr_accessor :oxxo
# If this is a `p24` PaymentMethod, this sub-hash contains details about the Przelewy24 payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::P24))))
}
attr_accessor :p24
# If this is a `pay_by_bank` PaymentMethod, this sub-hash contains details about the PayByBank payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::PayByBank))))
}
attr_accessor :pay_by_bank
# If this is a `payco` PaymentMethod, this sub-hash contains details about the PAYCO payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Payco))))
}
attr_accessor :payco
# If this is a `paynow` PaymentMethod, this sub-hash contains details about the PayNow payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Paynow))))
}
attr_accessor :paynow
# If this is a `paypal` PaymentMethod, this sub-hash contains details about the PayPal payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Paypal))))
}
attr_accessor :paypal
# If this is a `payto` PaymentMethod, this sub-hash contains details about the PayTo payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Payto))))
}
attr_accessor :payto
# If this is a `pix` PaymentMethod, this sub-hash contains details about the Pix payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Pix))))
}
attr_accessor :pix
# If this is a `promptpay` PaymentMethod, this sub-hash contains details about the PromptPay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Promptpay))))
}
attr_accessor :promptpay
# If this is a `qris` PaymentMethod, this sub-hash contains details about the QRIS payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Qris))))
}
attr_accessor :qris
# If this is a `rechnung` PaymentMethod, this sub-hash contains details about the Rechnung payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Rechnung))))
}
attr_accessor :rechnung
# If this is a `revolut_pay` PaymentMethod, this sub-hash contains details about the Revolut Pay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::RevolutPay))))
}
attr_accessor :revolut_pay
# If this is a `samsung_pay` PaymentMethod, this sub-hash contains details about the Samsung Pay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::SamsungPay))))
}
attr_accessor :samsung_pay
# If this is a `satispay` PaymentMethod, this sub-hash contains details about the Satispay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Satispay))))
}
attr_accessor :satispay
# If this is a `sepa_debit` PaymentIntent, this sub-hash contains details about the SEPA Debit payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::SepaDebit))))
}
attr_accessor :sepa_debit
# If this is a `shopeepay` PaymentMethod, this sub-hash contains details about the ShopeePay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Shopeepay))))
}
attr_accessor :shopeepay
# If this is a `sofort` PaymentMethod, this sub-hash contains details about the SOFORT payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Sofort))))
}
attr_accessor :sofort
# If this is a `stripe_balance` PaymentMethod, this sub-hash contains details about the Stripe Balance payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::StripeBalance))))
}
attr_accessor :stripe_balance
# If this is a `Swish` PaymentMethod, this sub-hash contains details about the Swish payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Swish))))
}
attr_accessor :swish
# If this is a `twint` PaymentMethod, this sub-hash contains details about the TWINT payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Twint))))
}
attr_accessor :twint
# If this is a `us_bank_account` PaymentMethod, this sub-hash contains details about the US bank account payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::UsBankAccount))))
}
attr_accessor :us_bank_account
# If this is a `wechat_pay` PaymentMethod, this sub-hash contains details about the WeChat Pay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::WechatPay))))
}
attr_accessor :wechat_pay
# If this is a `zip` PaymentMethod, this sub-hash contains details about the Zip payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Zip))))
}
attr_accessor :zip
sig {
params(acss_debit: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::AcssDebit))), affirm: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Affirm))), afterpay_clearpay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::AfterpayClearpay))), alipay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Alipay))), alma: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Alma))), amazon_pay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::AmazonPay))), au_becs_debit: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::AuBecsDebit))), bacs_debit: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::BacsDebit))), bancontact: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Bancontact))), billie: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Billie))), blik: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Blik))), boleto: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Boleto))), card: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Card))), card_present: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::CardPresent))), cashapp: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Cashapp))), customer_balance: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::CustomerBalance))), eps: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Eps))), fpx: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Fpx))), giropay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Giropay))), gopay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Gopay))), grabpay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Grabpay))), id_bank_transfer: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::IdBankTransfer))), ideal: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Ideal))), interac_present: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::InteracPresent))), kakao_pay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::KakaoPay))), klarna: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Klarna))), konbini: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Konbini))), kr_card: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::KrCard))), link: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Link))), mb_way: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::MbWay))), mobilepay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Mobilepay))), multibanco: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Multibanco))), naver_pay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::NaverPay))), nz_bank_account: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::NzBankAccount))), oxxo: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Oxxo))), p24: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::P24))), pay_by_bank: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::PayByBank))), payco: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Payco))), paynow: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Paynow))), paypal: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Paypal))), payto: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Payto))), pix: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Pix))), promptpay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Promptpay))), qris: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Qris))), rechnung: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Rechnung))), revolut_pay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::RevolutPay))), samsung_pay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::SamsungPay))), satispay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Satispay))), sepa_debit: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::SepaDebit))), shopeepay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Shopeepay))), sofort: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Sofort))), stripe_balance: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::StripeBalance))), swish: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Swish))), twint: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Twint))), us_bank_account: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::UsBankAccount))), wechat_pay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::WechatPay))), zip: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions::Zip)))).void
}
def initialize(
acss_debit: nil,
affirm: nil,
afterpay_clearpay: nil,
alipay: nil,
alma: nil,
amazon_pay: nil,
au_becs_debit: nil,
bacs_debit: nil,
bancontact: nil,
billie: nil,
blik: nil,
boleto: nil,
card: nil,
card_present: nil,
cashapp: nil,
customer_balance: nil,
eps: nil,
fpx: nil,
giropay: nil,
gopay: nil,
grabpay: nil,
id_bank_transfer: nil,
ideal: nil,
interac_present: nil,
kakao_pay: nil,
klarna: nil,
konbini: nil,
kr_card: nil,
link: nil,
mb_way: nil,
mobilepay: nil,
multibanco: nil,
naver_pay: nil,
nz_bank_account: nil,
oxxo: nil,
p24: nil,
pay_by_bank: nil,
payco: nil,
paynow: nil,
paypal: nil,
payto: nil,
pix: nil,
promptpay: nil,
qris: nil,
rechnung: nil,
revolut_pay: nil,
samsung_pay: nil,
satispay: nil,
sepa_debit: nil,
shopeepay: nil,
sofort: nil,
stripe_balance: nil,
swish: nil,
twint: nil,
us_bank_account: nil,
wechat_pay: nil,
zip: nil
); end
end
class Shipping < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Shipping address.
sig { returns(::Stripe::PaymentIntentService::UpdateParams::Shipping::Address) }
attr_accessor :address
# The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
sig { returns(T.nilable(String)) }
attr_accessor :carrier
# Recipient name.
sig { returns(String) }
attr_accessor :name
# Recipient phone (including extension).
sig { returns(T.nilable(String)) }
attr_accessor :phone
# The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
sig { returns(T.nilable(String)) }
attr_accessor :tracking_number
sig {
params(address: ::Stripe::PaymentIntentService::UpdateParams::Shipping::Address, carrier: T.nilable(String), name: String, phone: T.nilable(String), tracking_number: T.nilable(String)).void
}
def initialize(address: nil, carrier: nil, name: nil, phone: nil, tracking_number: nil); end
end
class TransferData < Stripe::RequestParams
# The amount that will be transferred automatically when a charge succeeds.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
sig { params(amount: T.nilable(Integer)).void }
def initialize(amount: nil); end
end
# Amount intended to be collected by this PaymentIntent. A positive integer representing how much to charge in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is $0.50 US or [equivalent in charge currency](https://stripe.com/docs/currencies#minimum-and-maximum-charge-amounts). The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99).
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. The amount of the application fee collected will be capped at the total amount captured. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :application_fee_amount
# Controls when the funds will be captured from the customer's account.
sig { returns(T.nilable(String)) }
attr_accessor :capture_method
# 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).
sig { returns(T.nilable(String)) }
attr_accessor :currency
# ID of the Customer this PaymentIntent belongs to, if one exists.
#
# Payment methods attached to other Customers cannot be used with this PaymentIntent.
#
# If [setup_future_usage](https://stripe.com/docs/api#payment_intent_object-setup_future_usage) is set and this PaymentIntent's payment method is not `card_present`, then the payment method attaches to the Customer after the PaymentIntent has been confirmed and any required actions from the user are complete. If the payment method is `card_present` and isn't a digital wallet, then a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card is created and attached to the Customer instead.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# ID of the Account this PaymentIntent belongs to, if one exists.
#
# Payment methods attached to other Accounts cannot be used with this PaymentIntent.
#
# If [setup_future_usage](https://stripe.com/docs/api#payment_intent_object-setup_future_usage) is set and this PaymentIntent's payment method is not `card_present`, then the payment method attaches to the Account after the PaymentIntent has been confirmed and any required actions from the user are complete. If the payment method is `card_present` and isn't a digital wallet, then a [generated_card](https://docs.stripe.com/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card is created and attached to the Account instead.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The FX rate in the quote is validated and used to convert the presentment amount to the settlement amount.
sig { returns(T.nilable(String)) }
attr_accessor :fx_quote
# Automations to be run during the PaymentIntent lifecycle
sig { returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::Hooks)) }
attr_accessor :hooks
# This hash contains details about the Mandate to create.
sig { returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::MandateData)) }
attr_accessor :mandate_data
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Provides industry-specific information about the charge.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentDetails))))
}
attr_accessor :payment_details
# Attribute for param field payment_method
sig { returns(T.nilable(String)) }
attr_accessor :payment_method
# The ID of the [payment method configuration](https://stripe.com/docs/api/payment_method_configurations) to use with this PaymentIntent.
sig { returns(T.nilable(String)) }
attr_accessor :payment_method_configuration
# If provided, this hash will be used to create a PaymentMethod. The new PaymentMethod will appear
# in the [payment_method](https://stripe.com/docs/api/payment_intents/object#payment_intent_object-payment_method)
# property on the PaymentIntent.
sig { returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData)) }
attr_accessor :payment_method_data
# Payment-method-specific configuration for this PaymentIntent.
sig { returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions)) }
attr_accessor :payment_method_options
# The list of payment method types (for example, card) that this PaymentIntent can use. Use `automatic_payment_methods` to manage payment methods from the [Stripe Dashboard](https://dashboard.stripe.com/settings/payment_methods).
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :payment_method_types
# Email address that the receipt for the resulting payment will be sent to. If `receipt_email` is specified for a payment in live mode, a receipt will be sent regardless of your [email settings](https://dashboard.stripe.com/account/emails).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :receipt_email
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Shipping information for this PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::Shipping))))
}
attr_accessor :shipping
# Text that appears on the customer's statement as the statement descriptor for a non-card charge. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
#
# Setting this value for a card charge returns an error. For card charges, set the [statement_descriptor_suffix](https://docs.stripe.com/get-started/account/statement-descriptors#dynamic) instead.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
# Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor_suffix
# Use this parameter to automatically create a Transfer when the payment succeeds. Learn more about the [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
sig { returns(T.nilable(::Stripe::PaymentIntentService::UpdateParams::TransferData)) }
attr_accessor :transfer_data
# A string that identifies the resulting payment as part of a group. You can only provide `transfer_group` if it hasn't been set. Learn more about the [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
sig { returns(T.nilable(String)) }
attr_accessor :transfer_group
sig {
params(amount: T.nilable(Integer), application_fee_amount: T.nilable(T.nilable(T.any(String, Integer))), capture_method: T.nilable(String), currency: T.nilable(String), customer: T.nilable(String), customer_account: T.nilable(String), description: T.nilable(String), expand: T.nilable(T::Array[String]), fx_quote: T.nilable(String), hooks: T.nilable(::Stripe::PaymentIntentService::UpdateParams::Hooks), mandate_data: T.nilable(::Stripe::PaymentIntentService::UpdateParams::MandateData), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), payment_details: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::PaymentDetails))), payment_method: T.nilable(String), payment_method_configuration: T.nilable(String), payment_method_data: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodData), payment_method_options: T.nilable(::Stripe::PaymentIntentService::UpdateParams::PaymentMethodOptions), payment_method_types: T.nilable(T::Array[String]), receipt_email: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), shipping: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::UpdateParams::Shipping))), statement_descriptor: T.nilable(String), statement_descriptor_suffix: T.nilable(String), transfer_data: T.nilable(::Stripe::PaymentIntentService::UpdateParams::TransferData), transfer_group: T.nilable(String)).void
}
def initialize(
amount: nil,
application_fee_amount: nil,
capture_method: nil,
currency: nil,
customer: nil,
customer_account: nil,
description: nil,
expand: nil,
fx_quote: nil,
hooks: nil,
mandate_data: nil,
metadata: nil,
payment_details: nil,
payment_method: nil,
payment_method_configuration: nil,
payment_method_data: nil,
payment_method_options: nil,
payment_method_types: nil,
receipt_email: nil,
setup_future_usage: nil,
shipping: nil,
statement_descriptor: nil,
statement_descriptor_suffix: nil,
transfer_data: nil,
transfer_group: nil
); end
end
class SearchParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for pagination across multiple pages of results. Don't include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.
sig { returns(T.nilable(String)) }
attr_accessor :page
# The search query string. See [search query language](https://stripe.com/docs/search#search-query-language) and the list of supported [query fields for payment intents](https://stripe.com/docs/search#query-fields-for-payment-intents).
sig { returns(String) }
attr_accessor :query
sig {
params(expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), page: T.nilable(String), query: String).void
}
def initialize(expand: nil, limit: nil, page: nil, query: nil); end
end
class ApplyCustomerBalanceParams < Stripe::RequestParams
# Amount that you intend to apply to this PaymentIntent from the customer’s cash balance. If the PaymentIntent was created by an Invoice, the full amount of the PaymentIntent is applied regardless of this parameter.
#
# A positive integer representing how much to charge in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (for example, 100 cents to charge 1 USD or 100 to charge 100 JPY, a zero-decimal currency). The maximum amount is the amount of the PaymentIntent.
#
# When you omit the amount, it defaults to the remaining amount requested on the PaymentIntent.
sig { returns(T.nilable(Integer)) }
attr_accessor :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).
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig {
params(amount: T.nilable(Integer), currency: T.nilable(String), expand: T.nilable(T::Array[String])).void
}
def initialize(amount: nil, currency: nil, expand: nil); end
end
class CancelParams < Stripe::RequestParams
# Reason for canceling this PaymentIntent. Possible values are: `duplicate`, `fraudulent`, `requested_by_customer`, or `abandoned`
sig { returns(T.nilable(String)) }
attr_accessor :cancellation_reason
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig {
params(cancellation_reason: T.nilable(String), expand: T.nilable(T::Array[String])).void
}
def initialize(cancellation_reason: nil, expand: nil); end
end
class CaptureParams < Stripe::RequestParams
class Hooks < Stripe::RequestParams
class Inputs < Stripe::RequestParams
class Tax < Stripe::RequestParams
# The [TaxCalculation](https://stripe.com/docs/api/tax/calculations) id
sig { returns(T.nilable(String)) }
attr_accessor :calculation
sig { params(calculation: T.nilable(String)).void }
def initialize(calculation: nil); end
end
# Tax arguments for automations
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CaptureParams::Hooks::Inputs::Tax))
}
attr_accessor :tax
sig {
params(tax: T.nilable(::Stripe::PaymentIntentService::CaptureParams::Hooks::Inputs::Tax)).void
}
def initialize(tax: nil); end
end
# Arguments passed in automations
sig { returns(T.nilable(::Stripe::PaymentIntentService::CaptureParams::Hooks::Inputs)) }
attr_accessor :inputs
sig {
params(inputs: T.nilable(::Stripe::PaymentIntentService::CaptureParams::Hooks::Inputs)).void
}
def initialize(inputs: nil); end
end
class PaymentDetails < Stripe::RequestParams
class CarRental < Stripe::RequestParams
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::CarRental::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::CarRental::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
class Distance < Stripe::RequestParams
# Distance traveled.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# Unit of measurement for the distance traveled. One of `miles` or `kilometers`.
sig { returns(T.nilable(String)) }
attr_accessor :unit
sig { params(amount: T.nilable(Integer), unit: T.nilable(String)).void }
def initialize(amount: nil, unit: nil); end
end
class Driver < Stripe::RequestParams
# Driver's identification number.
sig { returns(T.nilable(String)) }
attr_accessor :driver_identification_number
# Driver's tax number.
sig { returns(T.nilable(String)) }
attr_accessor :driver_tax_number
# Full name of the person or entity on the car reservation.
sig { returns(String) }
attr_accessor :name
sig {
params(driver_identification_number: T.nilable(String), driver_tax_number: T.nilable(String), name: String).void
}
def initialize(
driver_identification_number: nil,
driver_tax_number: nil,
name: nil
); end
end
class PickupAddress < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class ReturnAddress < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::CarRental::Affiliate))
}
attr_accessor :affiliate
# The booking number associated with the car rental.
sig { returns(String) }
attr_accessor :booking_number
# Class code of the car.
sig { returns(T.nilable(String)) }
attr_accessor :car_class_code
# Make of the car.
sig { returns(T.nilable(String)) }
attr_accessor :car_make
# Model of the car.
sig { returns(T.nilable(String)) }
attr_accessor :car_model
# The name of the rental car company.
sig { returns(T.nilable(String)) }
attr_accessor :company
# The customer service phone number of the car rental company.
sig { returns(T.nilable(String)) }
attr_accessor :customer_service_phone_number
# Number of days the car is being rented.
sig { returns(Integer) }
attr_accessor :days_rented
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::CarRental::Delivery))
}
attr_accessor :delivery
# The details of the distance traveled during the rental period.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::CarRental::Distance))
}
attr_accessor :distance
# The details of the passengers in the travel reservation
sig {
returns(T.nilable(T::Array[::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::CarRental::Driver]))
}
attr_accessor :drivers
# List of additional charges being billed.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :extra_charges
# Indicates if the customer did not keep nor cancel their booking.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :no_show
# Car pick-up address.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::CarRental::PickupAddress))
}
attr_accessor :pickup_address
# Car pick-up time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :pickup_at
# Name of the pickup location.
sig { returns(T.nilable(String)) }
attr_accessor :pickup_location_name
# Rental rate.
sig { returns(T.nilable(Integer)) }
attr_accessor :rate_amount
# The frequency at which the rate amount is applied. One of `day`, `week` or `month`
sig { returns(T.nilable(String)) }
attr_accessor :rate_interval
# The name of the person or entity renting the car.
sig { returns(T.nilable(String)) }
attr_accessor :renter_name
# Car return address.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::CarRental::ReturnAddress))
}
attr_accessor :return_address
# Car return time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :return_at
# Name of the return location.
sig { returns(T.nilable(String)) }
attr_accessor :return_location_name
# Indicates whether the goods or services are tax-exempt or tax is not collected.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :tax_exempt
# The vehicle identification number.
sig { returns(T.nilable(String)) }
attr_accessor :vehicle_identification_number
sig {
params(affiliate: T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::CarRental::Affiliate), booking_number: String, car_class_code: T.nilable(String), car_make: T.nilable(String), car_model: T.nilable(String), company: T.nilable(String), customer_service_phone_number: T.nilable(String), days_rented: Integer, delivery: T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::CarRental::Delivery), distance: T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::CarRental::Distance), drivers: T.nilable(T::Array[::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::CarRental::Driver]), extra_charges: T.nilable(T::Array[String]), no_show: T.nilable(T::Boolean), pickup_address: T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::CarRental::PickupAddress), pickup_at: Integer, pickup_location_name: T.nilable(String), rate_amount: T.nilable(Integer), rate_interval: T.nilable(String), renter_name: T.nilable(String), return_address: T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::CarRental::ReturnAddress), return_at: Integer, return_location_name: T.nilable(String), tax_exempt: T.nilable(T::Boolean), vehicle_identification_number: T.nilable(String)).void
}
def initialize(
affiliate: nil,
booking_number: nil,
car_class_code: nil,
car_make: nil,
car_model: nil,
company: nil,
customer_service_phone_number: nil,
days_rented: nil,
delivery: nil,
distance: nil,
drivers: nil,
extra_charges: nil,
no_show: nil,
pickup_address: nil,
pickup_at: nil,
pickup_location_name: nil,
rate_amount: nil,
rate_interval: nil,
renter_name: nil,
return_address: nil,
return_at: nil,
return_location_name: nil,
tax_exempt: nil,
vehicle_identification_number: nil
); end
end
class EventDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::EventDetails::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::EventDetails::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
# Indicates if the tickets are digitally checked when entering the venue.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :access_controlled_venue
# The event location's address.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::EventDetails::Address))
}
attr_accessor :address
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::EventDetails::Affiliate))
}
attr_accessor :affiliate
# The name of the company
sig { returns(T.nilable(String)) }
attr_accessor :company
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::EventDetails::Delivery))
}
attr_accessor :delivery
# Event end time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :ends_at
# Type of the event entertainment (concert, sports event etc)
sig { returns(T.nilable(String)) }
attr_accessor :genre
# The name of the event.
sig { returns(String) }
attr_accessor :name
# Event start time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :starts_at
sig {
params(access_controlled_venue: T.nilable(T::Boolean), address: T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::EventDetails::Address), affiliate: T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::EventDetails::Affiliate), company: T.nilable(String), delivery: T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::EventDetails::Delivery), ends_at: T.nilable(Integer), genre: T.nilable(String), name: String, starts_at: T.nilable(Integer)).void
}
def initialize(
access_controlled_venue: nil,
address: nil,
affiliate: nil,
company: nil,
delivery: nil,
ends_at: nil,
genre: nil,
name: nil,
starts_at: nil
); end
end
class Flight < Stripe::RequestParams
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::Flight::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::Flight::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
class Passenger < Stripe::RequestParams
# Full name of the person or entity on the flight reservation.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Segment < Stripe::RequestParams
# The flight segment amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# The International Air Transport Association (IATA) airport code for the arrival airport.
sig { returns(T.nilable(String)) }
attr_accessor :arrival_airport
# The arrival time for the flight segment. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :arrives_at
# The International Air Transport Association (IATA) carrier code of the carrier operating the flight segment.
sig { returns(T.nilable(String)) }
attr_accessor :carrier
# The departure time for the flight segment. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :departs_at
# The International Air Transport Association (IATA) airport code for the departure airport.
sig { returns(T.nilable(String)) }
attr_accessor :departure_airport
# The flight number associated with the segment
sig { returns(T.nilable(String)) }
attr_accessor :flight_number
# The fare class for the segment.
sig { returns(T.nilable(String)) }
attr_accessor :service_class
sig {
params(amount: T.nilable(Integer), arrival_airport: T.nilable(String), arrives_at: T.nilable(Integer), carrier: T.nilable(String), departs_at: Integer, departure_airport: T.nilable(String), flight_number: T.nilable(String), service_class: T.nilable(String)).void
}
def initialize(
amount: nil,
arrival_airport: nil,
arrives_at: nil,
carrier: nil,
departs_at: nil,
departure_airport: nil,
flight_number: nil,
service_class: nil
); end
end
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::Flight::Affiliate))
}
attr_accessor :affiliate
# The agency number (i.e. International Air Transport Association (IATA) agency number) of the travel agency that made the booking.
sig { returns(T.nilable(String)) }
attr_accessor :agency_number
# The International Air Transport Association (IATA) carrier code of the carrier that issued the ticket.
sig { returns(T.nilable(String)) }
attr_accessor :carrier
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::Flight::Delivery))
}
attr_accessor :delivery
# The name of the person or entity on the reservation.
sig { returns(T.nilable(String)) }
attr_accessor :passenger_name
# The details of the passengers in the travel reservation.
sig {
returns(T.nilable(T::Array[::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::Flight::Passenger]))
}
attr_accessor :passengers
# The individual flight segments associated with the trip.
sig {
returns(T::Array[::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::Flight::Segment])
}
attr_accessor :segments
# The ticket number associated with the travel reservation.
sig { returns(T.nilable(String)) }
attr_accessor :ticket_number
sig {
params(affiliate: T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::Flight::Affiliate), agency_number: T.nilable(String), carrier: T.nilable(String), delivery: T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::Flight::Delivery), passenger_name: T.nilable(String), passengers: T.nilable(T::Array[::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::Flight::Passenger]), segments: T::Array[::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::Flight::Segment], ticket_number: T.nilable(String)).void
}
def initialize(
affiliate: nil,
agency_number: nil,
carrier: nil,
delivery: nil,
passenger_name: nil,
passengers: nil,
segments: nil,
ticket_number: nil
); end
end
class Lodging < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::Lodging::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::Lodging::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
class Passenger < Stripe::RequestParams
# Full name of the person or entity on the lodging reservation.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
# The lodging location's address.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::Lodging::Address))
}
attr_accessor :address
# The number of adults on the booking
sig { returns(T.nilable(Integer)) }
attr_accessor :adults
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::Lodging::Affiliate))
}
attr_accessor :affiliate
# The booking number associated with the lodging reservation.
sig { returns(T.nilable(String)) }
attr_accessor :booking_number
# The lodging category
sig { returns(T.nilable(String)) }
attr_accessor :category
# Lodging check-in time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :checkin_at
# Lodging check-out time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :checkout_at
# The customer service phone number of the lodging company.
sig { returns(T.nilable(String)) }
attr_accessor :customer_service_phone_number
# The daily lodging room rate.
sig { returns(T.nilable(Integer)) }
attr_accessor :daily_room_rate_amount
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::Lodging::Delivery))
}
attr_accessor :delivery
# List of additional charges being billed.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :extra_charges
# Indicates whether the lodging location is compliant with the Fire Safety Act.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :fire_safety_act_compliance
# The name of the lodging location.
sig { returns(T.nilable(String)) }
attr_accessor :name
# Indicates if the customer did not keep their booking while failing to cancel the reservation.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :no_show
# The number of rooms on the booking
sig { returns(T.nilable(Integer)) }
attr_accessor :number_of_rooms
# The details of the passengers in the travel reservation
sig {
returns(T.nilable(T::Array[::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::Lodging::Passenger]))
}
attr_accessor :passengers
# The phone number of the lodging location.
sig { returns(T.nilable(String)) }
attr_accessor :property_phone_number
# The room class for this purchase.
sig { returns(T.nilable(String)) }
attr_accessor :room_class
# The number of room nights
sig { returns(T.nilable(Integer)) }
attr_accessor :room_nights
# The total tax amount associating with the room reservation.
sig { returns(T.nilable(Integer)) }
attr_accessor :total_room_tax_amount
# The total tax amount
sig { returns(T.nilable(Integer)) }
attr_accessor :total_tax_amount
sig {
params(address: T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::Lodging::Address), adults: T.nilable(Integer), affiliate: T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::Lodging::Affiliate), booking_number: T.nilable(String), category: T.nilable(String), checkin_at: Integer, checkout_at: Integer, customer_service_phone_number: T.nilable(String), daily_room_rate_amount: T.nilable(Integer), delivery: T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::Lodging::Delivery), extra_charges: T.nilable(T::Array[String]), fire_safety_act_compliance: T.nilable(T::Boolean), name: T.nilable(String), no_show: T.nilable(T::Boolean), number_of_rooms: T.nilable(Integer), passengers: T.nilable(T::Array[::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::Lodging::Passenger]), property_phone_number: T.nilable(String), room_class: T.nilable(String), room_nights: T.nilable(Integer), total_room_tax_amount: T.nilable(Integer), total_tax_amount: T.nilable(Integer)).void
}
def initialize(
address: nil,
adults: nil,
affiliate: nil,
booking_number: nil,
category: nil,
checkin_at: nil,
checkout_at: nil,
customer_service_phone_number: nil,
daily_room_rate_amount: nil,
delivery: nil,
extra_charges: nil,
fire_safety_act_compliance: nil,
name: nil,
no_show: nil,
number_of_rooms: nil,
passengers: nil,
property_phone_number: nil,
room_class: nil,
room_nights: nil,
total_room_tax_amount: nil,
total_tax_amount: nil
); end
end
class Subscription < Stripe::RequestParams
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class BillingInterval < Stripe::RequestParams
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :count
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
sig { params(count: Integer, interval: String).void }
def initialize(count: nil, interval: nil); end
end
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::Subscription::Affiliate))
}
attr_accessor :affiliate
# Info whether the subscription will be auto renewed upon expiry.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :auto_renewal
# Subscription billing details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::Subscription::BillingInterval))
}
attr_accessor :billing_interval
# Subscription end time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :ends_at
# Name of the product on subscription. e.g. Apple Music Subscription
sig { returns(String) }
attr_accessor :name
# Subscription start time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :starts_at
sig {
params(affiliate: T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::Subscription::Affiliate), auto_renewal: T.nilable(T::Boolean), billing_interval: T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::Subscription::BillingInterval), ends_at: T.nilable(Integer), name: String, starts_at: T.nilable(Integer)).void
}
def initialize(
affiliate: nil,
auto_renewal: nil,
billing_interval: nil,
ends_at: nil,
name: nil,
starts_at: nil
); end
end
# Car rental details for this PaymentIntent.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::CarRental))
}
attr_accessor :car_rental
# Some customers might be required by their company or organization to provide this information. If so, provide this value. Otherwise you can ignore this field.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :customer_reference
# Event details for this PaymentIntent
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::EventDetails))
}
attr_accessor :event_details
# Flight reservation details for this PaymentIntent
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::Flight))
}
attr_accessor :flight
# Lodging reservation details for this PaymentIntent
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::Lodging))
}
attr_accessor :lodging
# A unique value assigned by the business to identify the transaction.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :order_reference
# Subscription details for this PaymentIntent
sig {
returns(T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::Subscription))
}
attr_accessor :subscription
sig {
params(car_rental: T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::CarRental), customer_reference: T.nilable(T.nilable(String)), event_details: T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::EventDetails), flight: T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::Flight), lodging: T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::Lodging), order_reference: T.nilable(T.nilable(String)), subscription: T.nilable(::Stripe::PaymentIntentService::CaptureParams::PaymentDetails::Subscription)).void
}
def initialize(
car_rental: nil,
customer_reference: nil,
event_details: nil,
flight: nil,
lodging: nil,
order_reference: nil,
subscription: nil
); end
end
class TransferData < Stripe::RequestParams
# The amount that will be transferred automatically when a charge succeeds.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
sig { params(amount: T.nilable(Integer)).void }
def initialize(amount: nil); end
end
# The amount to capture from the PaymentIntent, which must be less than or equal to the original amount. Defaults to the full `amount_capturable` if it's not provided.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount_to_capture
# The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. The amount of the application fee collected will be capped at the total amount captured. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
sig { returns(T.nilable(Integer)) }
attr_accessor :application_fee_amount
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Defaults to `true`. When capturing a PaymentIntent, setting `final_capture` to `false` notifies Stripe to not release the remaining uncaptured funds to make sure that they're captured in future requests. You can only use this setting when [multicapture](https://stripe.com/docs/payments/multicapture) is available for PaymentIntents.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :final_capture
# Automations to be run during the PaymentIntent lifecycle
sig { returns(T.nilable(::Stripe::PaymentIntentService::CaptureParams::Hooks)) }
attr_accessor :hooks
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Provides industry-specific information about the charge.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CaptureParams::PaymentDetails))))
}
attr_accessor :payment_details
# Text that appears on the customer's statement as the statement descriptor for a non-card charge. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
#
# Setting this value for a card charge returns an error. For card charges, set the [statement_descriptor_suffix](https://docs.stripe.com/get-started/account/statement-descriptors#dynamic) instead.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
# Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor_suffix
# The parameters that you can use to automatically create a transfer after the payment
# is captured. Learn more about the [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
sig { returns(T.nilable(::Stripe::PaymentIntentService::CaptureParams::TransferData)) }
attr_accessor :transfer_data
sig {
params(amount_to_capture: T.nilable(Integer), application_fee_amount: T.nilable(Integer), expand: T.nilable(T::Array[String]), final_capture: T.nilable(T::Boolean), hooks: T.nilable(::Stripe::PaymentIntentService::CaptureParams::Hooks), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), payment_details: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::CaptureParams::PaymentDetails))), statement_descriptor: T.nilable(String), statement_descriptor_suffix: T.nilable(String), transfer_data: T.nilable(::Stripe::PaymentIntentService::CaptureParams::TransferData)).void
}
def initialize(
amount_to_capture: nil,
application_fee_amount: nil,
expand: nil,
final_capture: nil,
hooks: nil,
metadata: nil,
payment_details: nil,
statement_descriptor: nil,
statement_descriptor_suffix: nil,
transfer_data: nil
); end
end
class ConfirmParams < Stripe::RequestParams
class Hooks < Stripe::RequestParams
class Inputs < Stripe::RequestParams
class Tax < Stripe::RequestParams
# The [TaxCalculation](https://stripe.com/docs/api/tax/calculations) id
sig { returns(T.nilable(String)) }
attr_accessor :calculation
sig { params(calculation: T.nilable(String)).void }
def initialize(calculation: nil); end
end
# Tax arguments for automations
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::Hooks::Inputs::Tax))
}
attr_accessor :tax
sig {
params(tax: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::Hooks::Inputs::Tax)).void
}
def initialize(tax: nil); end
end
# Arguments passed in automations
sig { returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::Hooks::Inputs)) }
attr_accessor :inputs
sig {
params(inputs: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::Hooks::Inputs)).void
}
def initialize(inputs: nil); end
end
class MandateData < Stripe::RequestParams
class CustomerAcceptance < Stripe::RequestParams
class Offline < Stripe::RequestParams; end
class Online < Stripe::RequestParams
# The IP address from which the Mandate was accepted by the customer.
sig { returns(T.nilable(String)) }
attr_accessor :ip_address
# The user agent of the browser from which the Mandate was accepted by the customer.
sig { returns(T.nilable(String)) }
attr_accessor :user_agent
sig { params(ip_address: T.nilable(String), user_agent: T.nilable(String)).void }
def initialize(ip_address: nil, user_agent: nil); end
end
# The time at which the customer accepted the Mandate.
sig { returns(T.nilable(Integer)) }
attr_accessor :accepted_at
# If this is a Mandate accepted offline, this hash contains details about the offline acceptance.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::MandateData::CustomerAcceptance::Offline))
}
attr_accessor :offline
# If this is a Mandate accepted online, this hash contains details about the online acceptance.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::MandateData::CustomerAcceptance::Online))
}
attr_accessor :online
# The type of customer acceptance information included with the Mandate. One of `online` or `offline`.
sig { returns(String) }
attr_accessor :type
sig {
params(accepted_at: T.nilable(Integer), offline: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::MandateData::CustomerAcceptance::Offline), online: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::MandateData::CustomerAcceptance::Online), type: String).void
}
def initialize(accepted_at: nil, offline: nil, online: nil, type: nil); end
end
# This hash contains details about the customer acceptance of the Mandate.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::MandateData::CustomerAcceptance))
}
attr_accessor :customer_acceptance
sig {
params(customer_acceptance: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::MandateData::CustomerAcceptance)).void
}
def initialize(customer_acceptance: nil); end
end
class PaymentDetails < Stripe::RequestParams
class CarRental < Stripe::RequestParams
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::CarRental::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::CarRental::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
class Distance < Stripe::RequestParams
# Distance traveled.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# Unit of measurement for the distance traveled. One of `miles` or `kilometers`.
sig { returns(T.nilable(String)) }
attr_accessor :unit
sig { params(amount: T.nilable(Integer), unit: T.nilable(String)).void }
def initialize(amount: nil, unit: nil); end
end
class Driver < Stripe::RequestParams
# Driver's identification number.
sig { returns(T.nilable(String)) }
attr_accessor :driver_identification_number
# Driver's tax number.
sig { returns(T.nilable(String)) }
attr_accessor :driver_tax_number
# Full name of the person or entity on the car reservation.
sig { returns(String) }
attr_accessor :name
sig {
params(driver_identification_number: T.nilable(String), driver_tax_number: T.nilable(String), name: String).void
}
def initialize(
driver_identification_number: nil,
driver_tax_number: nil,
name: nil
); end
end
class PickupAddress < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class ReturnAddress < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::CarRental::Affiliate))
}
attr_accessor :affiliate
# The booking number associated with the car rental.
sig { returns(String) }
attr_accessor :booking_number
# Class code of the car.
sig { returns(T.nilable(String)) }
attr_accessor :car_class_code
# Make of the car.
sig { returns(T.nilable(String)) }
attr_accessor :car_make
# Model of the car.
sig { returns(T.nilable(String)) }
attr_accessor :car_model
# The name of the rental car company.
sig { returns(T.nilable(String)) }
attr_accessor :company
# The customer service phone number of the car rental company.
sig { returns(T.nilable(String)) }
attr_accessor :customer_service_phone_number
# Number of days the car is being rented.
sig { returns(Integer) }
attr_accessor :days_rented
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::CarRental::Delivery))
}
attr_accessor :delivery
# The details of the distance traveled during the rental period.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::CarRental::Distance))
}
attr_accessor :distance
# The details of the passengers in the travel reservation
sig {
returns(T.nilable(T::Array[::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::CarRental::Driver]))
}
attr_accessor :drivers
# List of additional charges being billed.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :extra_charges
# Indicates if the customer did not keep nor cancel their booking.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :no_show
# Car pick-up address.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::CarRental::PickupAddress))
}
attr_accessor :pickup_address
# Car pick-up time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :pickup_at
# Name of the pickup location.
sig { returns(T.nilable(String)) }
attr_accessor :pickup_location_name
# Rental rate.
sig { returns(T.nilable(Integer)) }
attr_accessor :rate_amount
# The frequency at which the rate amount is applied. One of `day`, `week` or `month`
sig { returns(T.nilable(String)) }
attr_accessor :rate_interval
# The name of the person or entity renting the car.
sig { returns(T.nilable(String)) }
attr_accessor :renter_name
# Car return address.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::CarRental::ReturnAddress))
}
attr_accessor :return_address
# Car return time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :return_at
# Name of the return location.
sig { returns(T.nilable(String)) }
attr_accessor :return_location_name
# Indicates whether the goods or services are tax-exempt or tax is not collected.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :tax_exempt
# The vehicle identification number.
sig { returns(T.nilable(String)) }
attr_accessor :vehicle_identification_number
sig {
params(affiliate: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::CarRental::Affiliate), booking_number: String, car_class_code: T.nilable(String), car_make: T.nilable(String), car_model: T.nilable(String), company: T.nilable(String), customer_service_phone_number: T.nilable(String), days_rented: Integer, delivery: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::CarRental::Delivery), distance: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::CarRental::Distance), drivers: T.nilable(T::Array[::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::CarRental::Driver]), extra_charges: T.nilable(T::Array[String]), no_show: T.nilable(T::Boolean), pickup_address: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::CarRental::PickupAddress), pickup_at: Integer, pickup_location_name: T.nilable(String), rate_amount: T.nilable(Integer), rate_interval: T.nilable(String), renter_name: T.nilable(String), return_address: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::CarRental::ReturnAddress), return_at: Integer, return_location_name: T.nilable(String), tax_exempt: T.nilable(T::Boolean), vehicle_identification_number: T.nilable(String)).void
}
def initialize(
affiliate: nil,
booking_number: nil,
car_class_code: nil,
car_make: nil,
car_model: nil,
company: nil,
customer_service_phone_number: nil,
days_rented: nil,
delivery: nil,
distance: nil,
drivers: nil,
extra_charges: nil,
no_show: nil,
pickup_address: nil,
pickup_at: nil,
pickup_location_name: nil,
rate_amount: nil,
rate_interval: nil,
renter_name: nil,
return_address: nil,
return_at: nil,
return_location_name: nil,
tax_exempt: nil,
vehicle_identification_number: nil
); end
end
class EventDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::EventDetails::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::EventDetails::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
# Indicates if the tickets are digitally checked when entering the venue.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :access_controlled_venue
# The event location's address.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::EventDetails::Address))
}
attr_accessor :address
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::EventDetails::Affiliate))
}
attr_accessor :affiliate
# The name of the company
sig { returns(T.nilable(String)) }
attr_accessor :company
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::EventDetails::Delivery))
}
attr_accessor :delivery
# Event end time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :ends_at
# Type of the event entertainment (concert, sports event etc)
sig { returns(T.nilable(String)) }
attr_accessor :genre
# The name of the event.
sig { returns(String) }
attr_accessor :name
# Event start time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :starts_at
sig {
params(access_controlled_venue: T.nilable(T::Boolean), address: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::EventDetails::Address), affiliate: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::EventDetails::Affiliate), company: T.nilable(String), delivery: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::EventDetails::Delivery), ends_at: T.nilable(Integer), genre: T.nilable(String), name: String, starts_at: T.nilable(Integer)).void
}
def initialize(
access_controlled_venue: nil,
address: nil,
affiliate: nil,
company: nil,
delivery: nil,
ends_at: nil,
genre: nil,
name: nil,
starts_at: nil
); end
end
class Flight < Stripe::RequestParams
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::Flight::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::Flight::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
class Passenger < Stripe::RequestParams
# Full name of the person or entity on the flight reservation.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Segment < Stripe::RequestParams
# The flight segment amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# The International Air Transport Association (IATA) airport code for the arrival airport.
sig { returns(T.nilable(String)) }
attr_accessor :arrival_airport
# The arrival time for the flight segment. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :arrives_at
# The International Air Transport Association (IATA) carrier code of the carrier operating the flight segment.
sig { returns(T.nilable(String)) }
attr_accessor :carrier
# The departure time for the flight segment. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :departs_at
# The International Air Transport Association (IATA) airport code for the departure airport.
sig { returns(T.nilable(String)) }
attr_accessor :departure_airport
# The flight number associated with the segment
sig { returns(T.nilable(String)) }
attr_accessor :flight_number
# The fare class for the segment.
sig { returns(T.nilable(String)) }
attr_accessor :service_class
sig {
params(amount: T.nilable(Integer), arrival_airport: T.nilable(String), arrives_at: T.nilable(Integer), carrier: T.nilable(String), departs_at: Integer, departure_airport: T.nilable(String), flight_number: T.nilable(String), service_class: T.nilable(String)).void
}
def initialize(
amount: nil,
arrival_airport: nil,
arrives_at: nil,
carrier: nil,
departs_at: nil,
departure_airport: nil,
flight_number: nil,
service_class: nil
); end
end
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::Flight::Affiliate))
}
attr_accessor :affiliate
# The agency number (i.e. International Air Transport Association (IATA) agency number) of the travel agency that made the booking.
sig { returns(T.nilable(String)) }
attr_accessor :agency_number
# The International Air Transport Association (IATA) carrier code of the carrier that issued the ticket.
sig { returns(T.nilable(String)) }
attr_accessor :carrier
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::Flight::Delivery))
}
attr_accessor :delivery
# The name of the person or entity on the reservation.
sig { returns(T.nilable(String)) }
attr_accessor :passenger_name
# The details of the passengers in the travel reservation.
sig {
returns(T.nilable(T::Array[::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::Flight::Passenger]))
}
attr_accessor :passengers
# The individual flight segments associated with the trip.
sig {
returns(T::Array[::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::Flight::Segment])
}
attr_accessor :segments
# The ticket number associated with the travel reservation.
sig { returns(T.nilable(String)) }
attr_accessor :ticket_number
sig {
params(affiliate: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::Flight::Affiliate), agency_number: T.nilable(String), carrier: T.nilable(String), delivery: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::Flight::Delivery), passenger_name: T.nilable(String), passengers: T.nilable(T::Array[::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::Flight::Passenger]), segments: T::Array[::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::Flight::Segment], ticket_number: T.nilable(String)).void
}
def initialize(
affiliate: nil,
agency_number: nil,
carrier: nil,
delivery: nil,
passenger_name: nil,
passengers: nil,
segments: nil,
ticket_number: nil
); end
end
class Lodging < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class Delivery < Stripe::RequestParams
class Recipient < Stripe::RequestParams
# The email of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The name of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The phone number of the recipient the ticket is delivered to.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(email: nil, name: nil, phone: nil); end
end
# The delivery method for the payment
sig { returns(T.nilable(String)) }
attr_accessor :mode
# Details of the recipient.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::Lodging::Delivery::Recipient))
}
attr_accessor :recipient
sig {
params(mode: T.nilable(String), recipient: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::Lodging::Delivery::Recipient)).void
}
def initialize(mode: nil, recipient: nil); end
end
class Passenger < Stripe::RequestParams
# Full name of the person or entity on the lodging reservation.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
# The lodging location's address.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::Lodging::Address))
}
attr_accessor :address
# The number of adults on the booking
sig { returns(T.nilable(Integer)) }
attr_accessor :adults
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::Lodging::Affiliate))
}
attr_accessor :affiliate
# The booking number associated with the lodging reservation.
sig { returns(T.nilable(String)) }
attr_accessor :booking_number
# The lodging category
sig { returns(T.nilable(String)) }
attr_accessor :category
# Lodging check-in time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :checkin_at
# Lodging check-out time. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :checkout_at
# The customer service phone number of the lodging company.
sig { returns(T.nilable(String)) }
attr_accessor :customer_service_phone_number
# The daily lodging room rate.
sig { returns(T.nilable(Integer)) }
attr_accessor :daily_room_rate_amount
# Delivery details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::Lodging::Delivery))
}
attr_accessor :delivery
# List of additional charges being billed.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :extra_charges
# Indicates whether the lodging location is compliant with the Fire Safety Act.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :fire_safety_act_compliance
# The name of the lodging location.
sig { returns(T.nilable(String)) }
attr_accessor :name
# Indicates if the customer did not keep their booking while failing to cancel the reservation.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :no_show
# The number of rooms on the booking
sig { returns(T.nilable(Integer)) }
attr_accessor :number_of_rooms
# The details of the passengers in the travel reservation
sig {
returns(T.nilable(T::Array[::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::Lodging::Passenger]))
}
attr_accessor :passengers
# The phone number of the lodging location.
sig { returns(T.nilable(String)) }
attr_accessor :property_phone_number
# The room class for this purchase.
sig { returns(T.nilable(String)) }
attr_accessor :room_class
# The number of room nights
sig { returns(T.nilable(Integer)) }
attr_accessor :room_nights
# The total tax amount associating with the room reservation.
sig { returns(T.nilable(Integer)) }
attr_accessor :total_room_tax_amount
# The total tax amount
sig { returns(T.nilable(Integer)) }
attr_accessor :total_tax_amount
sig {
params(address: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::Lodging::Address), adults: T.nilable(Integer), affiliate: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::Lodging::Affiliate), booking_number: T.nilable(String), category: T.nilable(String), checkin_at: Integer, checkout_at: Integer, customer_service_phone_number: T.nilable(String), daily_room_rate_amount: T.nilable(Integer), delivery: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::Lodging::Delivery), extra_charges: T.nilable(T::Array[String]), fire_safety_act_compliance: T.nilable(T::Boolean), name: T.nilable(String), no_show: T.nilable(T::Boolean), number_of_rooms: T.nilable(Integer), passengers: T.nilable(T::Array[::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::Lodging::Passenger]), property_phone_number: T.nilable(String), room_class: T.nilable(String), room_nights: T.nilable(Integer), total_room_tax_amount: T.nilable(Integer), total_tax_amount: T.nilable(Integer)).void
}
def initialize(
address: nil,
adults: nil,
affiliate: nil,
booking_number: nil,
category: nil,
checkin_at: nil,
checkout_at: nil,
customer_service_phone_number: nil,
daily_room_rate_amount: nil,
delivery: nil,
extra_charges: nil,
fire_safety_act_compliance: nil,
name: nil,
no_show: nil,
number_of_rooms: nil,
passengers: nil,
property_phone_number: nil,
room_class: nil,
room_nights: nil,
total_room_tax_amount: nil,
total_tax_amount: nil
); end
end
class Subscription < Stripe::RequestParams
class Affiliate < Stripe::RequestParams
# The name of the affiliate that originated the purchase.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class BillingInterval < Stripe::RequestParams
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :count
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
sig { params(count: Integer, interval: String).void }
def initialize(count: nil, interval: nil); end
end
# Affiliate details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::Subscription::Affiliate))
}
attr_accessor :affiliate
# Info whether the subscription will be auto renewed upon expiry.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :auto_renewal
# Subscription billing details for this purchase.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::Subscription::BillingInterval))
}
attr_accessor :billing_interval
# Subscription end time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :ends_at
# Name of the product on subscription. e.g. Apple Music Subscription
sig { returns(String) }
attr_accessor :name
# Subscription start time. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :starts_at
sig {
params(affiliate: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::Subscription::Affiliate), auto_renewal: T.nilable(T::Boolean), billing_interval: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::Subscription::BillingInterval), ends_at: T.nilable(Integer), name: String, starts_at: T.nilable(Integer)).void
}
def initialize(
affiliate: nil,
auto_renewal: nil,
billing_interval: nil,
ends_at: nil,
name: nil,
starts_at: nil
); end
end
# Car rental details for this PaymentIntent.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::CarRental))
}
attr_accessor :car_rental
# Some customers might be required by their company or organization to provide this information. If so, provide this value. Otherwise you can ignore this field.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :customer_reference
# Event details for this PaymentIntent
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::EventDetails))
}
attr_accessor :event_details
# Flight reservation details for this PaymentIntent
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::Flight))
}
attr_accessor :flight
# Lodging reservation details for this PaymentIntent
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::Lodging))
}
attr_accessor :lodging
# A unique value assigned by the business to identify the transaction.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :order_reference
# Subscription details for this PaymentIntent
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::Subscription))
}
attr_accessor :subscription
sig {
params(car_rental: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::CarRental), customer_reference: T.nilable(T.nilable(String)), event_details: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::EventDetails), flight: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::Flight), lodging: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::Lodging), order_reference: T.nilable(T.nilable(String)), subscription: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails::Subscription)).void
}
def initialize(
car_rental: nil,
customer_reference: nil,
event_details: nil,
flight: nil,
lodging: nil,
order_reference: nil,
subscription: nil
); end
end
class PaymentMethodData < Stripe::RequestParams
class AcssDebit < Stripe::RequestParams
# Customer's bank account number.
sig { returns(String) }
attr_accessor :account_number
# Institution number of the customer's bank.
sig { returns(String) }
attr_accessor :institution_number
# Transit number of the customer's bank.
sig { returns(String) }
attr_accessor :transit_number
sig {
params(account_number: String, institution_number: String, transit_number: String).void
}
def initialize(account_number: nil, institution_number: nil, transit_number: nil); end
end
class Affirm < Stripe::RequestParams; end
class AfterpayClearpay < Stripe::RequestParams; end
class Alipay < Stripe::RequestParams; end
class Alma < Stripe::RequestParams; end
class AmazonPay < Stripe::RequestParams; end
class AuBecsDebit < Stripe::RequestParams
# The account number for the bank account.
sig { returns(String) }
attr_accessor :account_number
# Bank-State-Branch number of the bank account.
sig { returns(String) }
attr_accessor :bsb_number
sig { params(account_number: String, bsb_number: String).void }
def initialize(account_number: nil, bsb_number: nil); end
end
class BacsDebit < Stripe::RequestParams
# Account number of the bank account that the funds will be debited from.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Sort code of the bank account. (e.g., `10-20-30`)
sig { returns(T.nilable(String)) }
attr_accessor :sort_code
sig { params(account_number: T.nilable(String), sort_code: T.nilable(String)).void }
def initialize(account_number: nil, sort_code: nil); end
end
class Bancontact < Stripe::RequestParams; end
class Billie < Stripe::RequestParams; end
class BillingDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Billing address.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::BillingDetails::Address))))
}
attr_accessor :address
# Email address.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :email
# Full name.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :name
# Billing phone number (including extension).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :phone
# Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
sig { returns(T.nilable(String)) }
attr_accessor :tax_id
sig {
params(address: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::BillingDetails::Address))), email: T.nilable(T.nilable(String)), name: T.nilable(T.nilable(String)), phone: T.nilable(T.nilable(String)), tax_id: T.nilable(String)).void
}
def initialize(address: nil, email: nil, name: nil, phone: nil, tax_id: nil); end
end
class Blik < Stripe::RequestParams; end
class Boleto < Stripe::RequestParams
# The tax ID of the customer (CPF for individual consumers or CNPJ for businesses consumers)
sig { returns(String) }
attr_accessor :tax_id
sig { params(tax_id: String).void }
def initialize(tax_id: nil); end
end
class Cashapp < Stripe::RequestParams; end
class CustomerBalance < Stripe::RequestParams; end
class Eps < Stripe::RequestParams
# The customer's bank.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class Fpx < Stripe::RequestParams
# Account holder type for FPX transaction
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_type
# The customer's bank.
sig { returns(String) }
attr_accessor :bank
sig { params(account_holder_type: T.nilable(String), bank: String).void }
def initialize(account_holder_type: nil, bank: nil); end
end
class Giropay < Stripe::RequestParams; end
class Gopay < Stripe::RequestParams; end
class Grabpay < Stripe::RequestParams; end
class IdBankTransfer < Stripe::RequestParams
# Bank where the account is held.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class Ideal < Stripe::RequestParams
# The customer's bank. Only use this parameter for existing customers. Don't use it for new customers.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class InteracPresent < Stripe::RequestParams; end
class KakaoPay < Stripe::RequestParams; end
class Klarna < Stripe::RequestParams
class Dob < Stripe::RequestParams
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
# Customer's date of birth
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Klarna::Dob))
}
attr_accessor :dob
sig {
params(dob: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Klarna::Dob)).void
}
def initialize(dob: nil); end
end
class Konbini < Stripe::RequestParams; end
class KrCard < Stripe::RequestParams; end
class Link < Stripe::RequestParams; end
class MbWay < Stripe::RequestParams; end
class Mobilepay < Stripe::RequestParams; end
class Multibanco < Stripe::RequestParams; end
class NaverPay < Stripe::RequestParams
# Whether to use Naver Pay points or a card to fund this transaction. If not provided, this defaults to `card`.
sig { returns(T.nilable(String)) }
attr_accessor :funding
sig { params(funding: T.nilable(String)).void }
def initialize(funding: nil); end
end
class NzBankAccount < Stripe::RequestParams
# The name on the bank account. Only required if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod’s billing details.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_name
# The account number for the bank account.
sig { returns(String) }
attr_accessor :account_number
# The numeric code for the bank account's bank.
sig { returns(String) }
attr_accessor :bank_code
# The numeric code for the bank account's bank branch.
sig { returns(String) }
attr_accessor :branch_code
# Attribute for param field reference
sig { returns(T.nilable(String)) }
attr_accessor :reference
# The suffix of the bank account number.
sig { returns(String) }
attr_accessor :suffix
sig {
params(account_holder_name: T.nilable(String), account_number: String, bank_code: String, branch_code: String, reference: T.nilable(String), suffix: String).void
}
def initialize(
account_holder_name: nil,
account_number: nil,
bank_code: nil,
branch_code: nil,
reference: nil,
suffix: nil
); end
end
class Oxxo < Stripe::RequestParams; end
class P24 < Stripe::RequestParams
# The customer's bank.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class PayByBank < Stripe::RequestParams; end
class Payco < Stripe::RequestParams; end
class Paynow < Stripe::RequestParams; end
class Paypal < Stripe::RequestParams; end
class Payto < Stripe::RequestParams
# The account number for the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Bank-State-Branch number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :bsb_number
# The PayID alias for the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :pay_id
sig {
params(account_number: T.nilable(String), bsb_number: T.nilable(String), pay_id: T.nilable(String)).void
}
def initialize(account_number: nil, bsb_number: nil, pay_id: nil); end
end
class Pix < Stripe::RequestParams; end
class Promptpay < Stripe::RequestParams; end
class Qris < Stripe::RequestParams; end
class RadarOptions < Stripe::RequestParams
# A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
sig { returns(T.nilable(String)) }
attr_accessor :session
sig { params(session: T.nilable(String)).void }
def initialize(session: nil); end
end
class Rechnung < Stripe::RequestParams
class Dob < Stripe::RequestParams
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
# Customer's date of birth
sig {
returns(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Rechnung::Dob)
}
attr_accessor :dob
sig {
params(dob: ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Rechnung::Dob).void
}
def initialize(dob: nil); end
end
class RevolutPay < Stripe::RequestParams; end
class SamsungPay < Stripe::RequestParams; end
class Satispay < Stripe::RequestParams; end
class SepaDebit < Stripe::RequestParams
# IBAN of the bank account.
sig { returns(String) }
attr_accessor :iban
sig { params(iban: String).void }
def initialize(iban: nil); end
end
class Shopeepay < Stripe::RequestParams; end
class Sofort < Stripe::RequestParams
# Two-letter ISO code representing the country the bank account is located in.
sig { returns(String) }
attr_accessor :country
sig { params(country: String).void }
def initialize(country: nil); end
end
class StripeBalance < Stripe::RequestParams
# The connected account ID whose Stripe balance to use as the source of payment
sig { returns(T.nilable(String)) }
attr_accessor :account
# The [source_type](https://docs.stripe.com/api/balance/balance_object#balance_object-available-source_types) of the balance
sig { returns(T.nilable(String)) }
attr_accessor :source_type
sig { params(account: T.nilable(String), source_type: T.nilable(String)).void }
def initialize(account: nil, source_type: nil); end
end
class Swish < Stripe::RequestParams; end
class Twint < Stripe::RequestParams; end
class UsBankAccount < Stripe::RequestParams
# Account holder type: individual or company.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_type
# Account number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Account type: checkings or savings. Defaults to checking if omitted.
sig { returns(T.nilable(String)) }
attr_accessor :account_type
# The ID of a Financial Connections Account to use as a payment method.
sig { returns(T.nilable(String)) }
attr_accessor :financial_connections_account
# Routing number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :routing_number
sig {
params(account_holder_type: T.nilable(String), account_number: T.nilable(String), account_type: T.nilable(String), financial_connections_account: T.nilable(String), routing_number: T.nilable(String)).void
}
def initialize(
account_holder_type: nil,
account_number: nil,
account_type: nil,
financial_connections_account: nil,
routing_number: nil
); end
end
class WechatPay < Stripe::RequestParams; end
class Zip < Stripe::RequestParams; end
# If this is an `acss_debit` PaymentMethod, this hash contains details about the ACSS Debit payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::AcssDebit))
}
attr_accessor :acss_debit
# If this is an `affirm` PaymentMethod, this hash contains details about the Affirm payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Affirm))
}
attr_accessor :affirm
# If this is an `AfterpayClearpay` PaymentMethod, this hash contains details about the AfterpayClearpay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::AfterpayClearpay))
}
attr_accessor :afterpay_clearpay
# If this is an `Alipay` PaymentMethod, this hash contains details about the Alipay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Alipay))
}
attr_accessor :alipay
# This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :allow_redisplay
# If this is a Alma PaymentMethod, this hash contains details about the Alma payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Alma))
}
attr_accessor :alma
# If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::AmazonPay))
}
attr_accessor :amazon_pay
# If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::AuBecsDebit))
}
attr_accessor :au_becs_debit
# If this is a `bacs_debit` PaymentMethod, this hash contains details about the Bacs Direct Debit bank account.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::BacsDebit))
}
attr_accessor :bacs_debit
# If this is a `bancontact` PaymentMethod, this hash contains details about the Bancontact payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Bancontact))
}
attr_accessor :bancontact
# If this is a `billie` PaymentMethod, this hash contains details about the Billie payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Billie))
}
attr_accessor :billie
# Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::BillingDetails))
}
attr_accessor :billing_details
# If this is a `blik` PaymentMethod, this hash contains details about the BLIK payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Blik))
}
attr_accessor :blik
# If this is a `boleto` PaymentMethod, this hash contains details about the Boleto payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Boleto))
}
attr_accessor :boleto
# If this is a `cashapp` PaymentMethod, this hash contains details about the Cash App Pay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Cashapp))
}
attr_accessor :cashapp
# If this is a `customer_balance` PaymentMethod, this hash contains details about the CustomerBalance payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::CustomerBalance))
}
attr_accessor :customer_balance
# If this is an `eps` PaymentMethod, this hash contains details about the EPS payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Eps))
}
attr_accessor :eps
# If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Fpx))
}
attr_accessor :fpx
# If this is a `giropay` PaymentMethod, this hash contains details about the Giropay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Giropay))
}
attr_accessor :giropay
# If this is a Gopay PaymentMethod, this hash contains details about the Gopay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Gopay))
}
attr_accessor :gopay
# If this is a `grabpay` PaymentMethod, this hash contains details about the GrabPay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Grabpay))
}
attr_accessor :grabpay
# If this is an `IdBankTransfer` PaymentMethod, this hash contains details about the IdBankTransfer payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::IdBankTransfer))
}
attr_accessor :id_bank_transfer
# If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Ideal))
}
attr_accessor :ideal
# If this is an `interac_present` PaymentMethod, this hash contains details about the Interac Present payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::InteracPresent))
}
attr_accessor :interac_present
# If this is a `kakao_pay` PaymentMethod, this hash contains details about the Kakao Pay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::KakaoPay))
}
attr_accessor :kakao_pay
# If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Klarna))
}
attr_accessor :klarna
# If this is a `konbini` PaymentMethod, this hash contains details about the Konbini payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Konbini))
}
attr_accessor :konbini
# If this is a `kr_card` PaymentMethod, this hash contains details about the Korean Card payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::KrCard))
}
attr_accessor :kr_card
# If this is an `Link` PaymentMethod, this hash contains details about the Link payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Link))
}
attr_accessor :link
# If this is a MB WAY PaymentMethod, this hash contains details about the MB WAY payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::MbWay))
}
attr_accessor :mb_way
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# If this is a `mobilepay` PaymentMethod, this hash contains details about the MobilePay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Mobilepay))
}
attr_accessor :mobilepay
# If this is a `multibanco` PaymentMethod, this hash contains details about the Multibanco payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Multibanco))
}
attr_accessor :multibanco
# If this is a `naver_pay` PaymentMethod, this hash contains details about the Naver Pay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::NaverPay))
}
attr_accessor :naver_pay
# If this is an nz_bank_account PaymentMethod, this hash contains details about the nz_bank_account payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::NzBankAccount))
}
attr_accessor :nz_bank_account
# If this is an `oxxo` PaymentMethod, this hash contains details about the OXXO payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Oxxo))
}
attr_accessor :oxxo
# If this is a `p24` PaymentMethod, this hash contains details about the P24 payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::P24))
}
attr_accessor :p24
# If this is a `pay_by_bank` PaymentMethod, this hash contains details about the PayByBank payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::PayByBank))
}
attr_accessor :pay_by_bank
# If this is a `payco` PaymentMethod, this hash contains details about the PAYCO payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Payco))
}
attr_accessor :payco
# If this is a `paynow` PaymentMethod, this hash contains details about the PayNow payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Paynow))
}
attr_accessor :paynow
# If this is a `paypal` PaymentMethod, this hash contains details about the PayPal payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Paypal))
}
attr_accessor :paypal
# If this is a `payto` PaymentMethod, this hash contains details about the PayTo payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Payto))
}
attr_accessor :payto
# If this is a `pix` PaymentMethod, this hash contains details about the Pix payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Pix))
}
attr_accessor :pix
# If this is a `promptpay` PaymentMethod, this hash contains details about the PromptPay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Promptpay))
}
attr_accessor :promptpay
# If this is a `qris` PaymentMethod, this hash contains details about the QRIS payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Qris))
}
attr_accessor :qris
# Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::RadarOptions))
}
attr_accessor :radar_options
# If this is a `rechnung` PaymentMethod, this hash contains details about the Rechnung payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Rechnung))
}
attr_accessor :rechnung
# If this is a `revolut_pay` PaymentMethod, this hash contains details about the Revolut Pay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::RevolutPay))
}
attr_accessor :revolut_pay
# If this is a `samsung_pay` PaymentMethod, this hash contains details about the SamsungPay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::SamsungPay))
}
attr_accessor :samsung_pay
# If this is a `satispay` PaymentMethod, this hash contains details about the Satispay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Satispay))
}
attr_accessor :satispay
# If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::SepaDebit))
}
attr_accessor :sepa_debit
# If this is a Shopeepay PaymentMethod, this hash contains details about the Shopeepay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Shopeepay))
}
attr_accessor :shopeepay
# If this is a `sofort` PaymentMethod, this hash contains details about the SOFORT payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Sofort))
}
attr_accessor :sofort
# This hash contains details about the Stripe balance payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::StripeBalance))
}
attr_accessor :stripe_balance
# If this is a `swish` PaymentMethod, this hash contains details about the Swish payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Swish))
}
attr_accessor :swish
# If this is a TWINT PaymentMethod, this hash contains details about the TWINT payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Twint))
}
attr_accessor :twint
# The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
sig { returns(String) }
attr_accessor :type
# If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::UsBankAccount))
}
attr_accessor :us_bank_account
# If this is an `wechat_pay` PaymentMethod, this hash contains details about the wechat_pay payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::WechatPay))
}
attr_accessor :wechat_pay
# If this is a `zip` PaymentMethod, this hash contains details about the Zip payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Zip))
}
attr_accessor :zip
sig {
params(acss_debit: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::AcssDebit), affirm: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Affirm), afterpay_clearpay: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::AfterpayClearpay), alipay: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Alipay), allow_redisplay: T.nilable(String), alma: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Alma), amazon_pay: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::AmazonPay), au_becs_debit: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::AuBecsDebit), bacs_debit: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::BacsDebit), bancontact: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Bancontact), billie: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Billie), billing_details: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::BillingDetails), blik: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Blik), boleto: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Boleto), cashapp: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Cashapp), customer_balance: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::CustomerBalance), eps: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Eps), fpx: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Fpx), giropay: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Giropay), gopay: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Gopay), grabpay: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Grabpay), id_bank_transfer: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::IdBankTransfer), ideal: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Ideal), interac_present: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::InteracPresent), kakao_pay: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::KakaoPay), klarna: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Klarna), konbini: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Konbini), kr_card: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::KrCard), link: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Link), mb_way: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::MbWay), metadata: T.nilable(T::Hash[String, String]), mobilepay: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Mobilepay), multibanco: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Multibanco), naver_pay: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::NaverPay), nz_bank_account: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::NzBankAccount), oxxo: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Oxxo), p24: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::P24), pay_by_bank: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::PayByBank), payco: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Payco), paynow: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Paynow), paypal: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Paypal), payto: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Payto), pix: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Pix), promptpay: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Promptpay), qris: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Qris), radar_options: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::RadarOptions), rechnung: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Rechnung), revolut_pay: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::RevolutPay), samsung_pay: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::SamsungPay), satispay: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Satispay), sepa_debit: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::SepaDebit), shopeepay: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Shopeepay), sofort: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Sofort), stripe_balance: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::StripeBalance), swish: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Swish), twint: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Twint), type: String, us_bank_account: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::UsBankAccount), wechat_pay: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::WechatPay), zip: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData::Zip)).void
}
def initialize(
acss_debit: nil,
affirm: nil,
afterpay_clearpay: nil,
alipay: nil,
allow_redisplay: nil,
alma: nil,
amazon_pay: nil,
au_becs_debit: nil,
bacs_debit: nil,
bancontact: nil,
billie: nil,
billing_details: nil,
blik: nil,
boleto: nil,
cashapp: nil,
customer_balance: nil,
eps: nil,
fpx: nil,
giropay: nil,
gopay: nil,
grabpay: nil,
id_bank_transfer: nil,
ideal: nil,
interac_present: nil,
kakao_pay: nil,
klarna: nil,
konbini: nil,
kr_card: nil,
link: nil,
mb_way: nil,
metadata: nil,
mobilepay: nil,
multibanco: nil,
naver_pay: nil,
nz_bank_account: nil,
oxxo: nil,
p24: nil,
pay_by_bank: nil,
payco: nil,
paynow: nil,
paypal: nil,
payto: nil,
pix: nil,
promptpay: nil,
qris: nil,
radar_options: nil,
rechnung: nil,
revolut_pay: nil,
samsung_pay: nil,
satispay: nil,
sepa_debit: nil,
shopeepay: nil,
sofort: nil,
stripe_balance: nil,
swish: nil,
twint: nil,
type: nil,
us_bank_account: nil,
wechat_pay: nil,
zip: nil
); end
end
class PaymentMethodOptions < Stripe::RequestParams
class AcssDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# A URL for custom mandate text to render during confirmation step.
# The URL will be rendered with additional GET parameters `payment_intent` and `payment_intent_client_secret` when confirming a Payment Intent,
# or `setup_intent` and `setup_intent_client_secret` when confirming a Setup Intent.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :custom_mandate_url
# Description of the mandate interval. Only required if 'payment_schedule' parameter is 'interval' or 'combined'.
sig { returns(T.nilable(String)) }
attr_accessor :interval_description
# Payment schedule for the mandate.
sig { returns(T.nilable(String)) }
attr_accessor :payment_schedule
# Transaction type of the mandate.
sig { returns(T.nilable(String)) }
attr_accessor :transaction_type
sig {
params(custom_mandate_url: T.nilable(T.nilable(String)), interval_description: T.nilable(String), payment_schedule: T.nilable(String), transaction_type: T.nilable(String)).void
}
def initialize(
custom_mandate_url: nil,
interval_description: nil,
payment_schedule: nil,
transaction_type: nil
); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::AcssDebit::MandateOptions))
}
attr_accessor :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
# Bank account verification method.
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(mandate_options: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::AcssDebit::MandateOptions), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), target_date: T.nilable(String), verification_method: T.nilable(String)).void
}
def initialize(
mandate_options: nil,
setup_future_usage: nil,
target_date: nil,
verification_method: nil
); end
end
class Affirm < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Preferred language of the Affirm authorization page that the customer is redirected to.
sig { returns(T.nilable(String)) }
attr_accessor :preferred_locale
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), preferred_locale: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(capture_method: nil, preferred_locale: nil, setup_future_usage: nil); end
end
class AfterpayClearpay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# An internal identifier or reference that this payment corresponds to. You must limit the identifier to 128 characters, and it can only contain letters, numbers, underscores, backslashes, and dashes.
# This field differs from the statement descriptor and item name.
sig { returns(T.nilable(String)) }
attr_accessor :reference
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), reference: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(capture_method: nil, reference: nil, setup_future_usage: nil); end
end
class Alipay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void }
def initialize(setup_future_usage: nil); end
end
class Alma < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
sig { params(capture_method: T.nilable(T.nilable(String))).void }
def initialize(capture_method: nil); end
end
class AmazonPay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class AuBecsDebit < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
sig {
params(setup_future_usage: T.nilable(T.nilable(T.any(String, String))), target_date: T.nilable(String)).void
}
def initialize(setup_future_usage: nil, target_date: nil); end
end
class BacsDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'DDIC' or 'STRIPE'.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :reference_prefix
sig { params(reference_prefix: T.nilable(T.nilable(String))).void }
def initialize(reference_prefix: nil); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::BacsDebit::MandateOptions))
}
attr_accessor :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
sig {
params(mandate_options: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::BacsDebit::MandateOptions), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), target_date: T.nilable(String)).void
}
def initialize(mandate_options: nil, setup_future_usage: nil, target_date: nil); end
end
class Bancontact < Stripe::RequestParams
# Preferred language of the Bancontact authorization page that the customer is redirected to.
sig { returns(T.nilable(String)) }
attr_accessor :preferred_language
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(preferred_language: T.nilable(String), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(preferred_language: nil, setup_future_usage: nil); end
end
class Billie < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
sig { params(capture_method: T.nilable(T.nilable(String))).void }
def initialize(capture_method: nil); end
end
class Blik < Stripe::RequestParams
# The 6-digit BLIK code that a customer has generated using their banking application. Can only be set on confirmation.
sig { returns(T.nilable(String)) }
attr_accessor :code
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :setup_future_usage
sig {
params(code: T.nilable(String), setup_future_usage: T.nilable(T.nilable(String))).void
}
def initialize(code: nil, setup_future_usage: nil); end
end
class Boleto < Stripe::RequestParams
# The number of calendar days before a Boleto voucher expires. For example, if you create a Boleto voucher on Monday and you set expires_after_days to 2, the Boleto invoice will expire on Wednesday at 23:59 America/Sao_Paulo time.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_after_days
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(expires_after_days: T.nilable(Integer), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(expires_after_days: nil, setup_future_usage: nil); end
end
class Card < Stripe::RequestParams
class Installments < Stripe::RequestParams
class Plan < Stripe::RequestParams
# For `fixed_count` installment plans, this is required. It represents the number of installment payments your customer will make to their credit card.
sig { returns(T.nilable(Integer)) }
attr_accessor :count
# For `fixed_count` installment plans, this is required. It represents the interval between installment payments your customer will make to their credit card.
# One of `month`.
sig { returns(T.nilable(String)) }
attr_accessor :interval
# Type of installment plan, one of `fixed_count`.
sig { returns(String) }
attr_accessor :type
sig {
params(count: T.nilable(Integer), interval: T.nilable(String), type: String).void
}
def initialize(count: nil, interval: nil, type: nil); end
end
# Setting to true enables installments for this PaymentIntent.
# This will cause the response to contain a list of available installment plans.
# Setting to false will prevent any selected plan from applying to a charge.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :enabled
# The selected installment plan to use for this payment attempt.
# This parameter can only be provided during confirmation.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Card::Installments::Plan))))
}
attr_accessor :plan
sig {
params(enabled: T.nilable(T::Boolean), plan: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Card::Installments::Plan)))).void
}
def initialize(enabled: nil, plan: nil); end
end
class MandateOptions < Stripe::RequestParams
# Amount to be charged for future payments.
sig { returns(Integer) }
attr_accessor :amount
# One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.
sig { returns(String) }
attr_accessor :amount_type
# A description of the mandate or subscription that is meant to be displayed to the customer.
sig { returns(T.nilable(String)) }
attr_accessor :description
# End date of the mandate or subscription. If not provided, the mandate will be active until canceled. If provided, end date should be after start date.
sig { returns(T.nilable(Integer)) }
attr_accessor :end_date
# Specifies payment frequency. One of `day`, `week`, `month`, `year`, or `sporadic`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals between payments. For example, `interval=month` and `interval_count=3` indicates one payment every three months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks). This parameter is optional when `interval=sporadic`.
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_count
# Unique identifier for the mandate or subscription.
sig { returns(String) }
attr_accessor :reference
# Start date of the mandate or subscription. Start date should not be lesser than yesterday.
sig { returns(Integer) }
attr_accessor :start_date
# Specifies the type of mandates supported. Possible values are `india`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :supported_types
sig {
params(amount: Integer, amount_type: String, description: T.nilable(String), end_date: T.nilable(Integer), interval: String, interval_count: T.nilable(Integer), reference: String, start_date: Integer, supported_types: T.nilable(T::Array[String])).void
}
def initialize(
amount: nil,
amount_type: nil,
description: nil,
end_date: nil,
interval: nil,
interval_count: nil,
reference: nil,
start_date: nil,
supported_types: nil
); end
end
class StatementDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Please pass in an address that is within your Stripe user account country
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Card::StatementDetails::Address))
}
attr_accessor :address
# Phone number (e.g., a toll-free number that customers can call)
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(address: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Card::StatementDetails::Address), phone: T.nilable(String)).void
}
def initialize(address: nil, phone: nil); end
end
class ThreeDSecure < Stripe::RequestParams
class NetworkOptions < Stripe::RequestParams
class CartesBancaires < Stripe::RequestParams
# The cryptogram calculation algorithm used by the card Issuer's ACS
# to calculate the Authentication cryptogram. Also known as `cavvAlgorithm`.
# messageExtension: CB-AVALGO
sig { returns(String) }
attr_accessor :cb_avalgo
# The exemption indicator returned from Cartes Bancaires in the ARes.
# message extension: CB-EXEMPTION; string (4 characters)
# This is a 3 byte bitmap (low significant byte first and most significant
# bit first) that has been Base64 encoded
sig { returns(T.nilable(String)) }
attr_accessor :cb_exemption
# The risk score returned from Cartes Bancaires in the ARes.
# message extension: CB-SCORE; numeric value 0-99
sig { returns(T.nilable(Integer)) }
attr_accessor :cb_score
sig {
params(cb_avalgo: String, cb_exemption: T.nilable(String), cb_score: T.nilable(Integer)).void
}
def initialize(cb_avalgo: nil, cb_exemption: nil, cb_score: nil); end
end
# Cartes Bancaires-specific 3DS fields.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions::CartesBancaires))
}
attr_accessor :cartes_bancaires
sig {
params(cartes_bancaires: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions::CartesBancaires)).void
}
def initialize(cartes_bancaires: nil); end
end
# The `transStatus` returned from the card Issuer’s ACS in the ARes.
sig { returns(T.nilable(String)) }
attr_accessor :ares_trans_status
# The cryptogram, also known as the "authentication value" (AAV, CAVV or
# AEVV). This value is 20 bytes, base64-encoded into a 28-character string.
# (Most 3D Secure providers will return the base64-encoded version, which
# is what you should specify here.)
sig { returns(String) }
attr_accessor :cryptogram
# The Electronic Commerce Indicator (ECI) is returned by your 3D Secure
# provider and indicates what degree of authentication was performed.
sig { returns(T.nilable(String)) }
attr_accessor :electronic_commerce_indicator
# The exemption requested via 3DS and accepted by the issuer at authentication time.
sig { returns(T.nilable(String)) }
attr_accessor :exemption_indicator
# Network specific 3DS fields. Network specific arguments require an
# explicit card brand choice. The parameter `payment_method_options.card.network``
# must be populated accordingly
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions))
}
attr_accessor :network_options
# The challenge indicator (`threeDSRequestorChallengeInd`) which was requested in the
# AReq sent to the card Issuer's ACS. A string containing 2 digits from 01-99.
sig { returns(T.nilable(String)) }
attr_accessor :requestor_challenge_indicator
# For 3D Secure 1, the XID. For 3D Secure 2, the Directory Server
# Transaction ID (dsTransID).
sig { returns(String) }
attr_accessor :transaction_id
# The version of 3D Secure that was performed.
sig { returns(String) }
attr_accessor :version
sig {
params(ares_trans_status: T.nilable(String), cryptogram: String, electronic_commerce_indicator: T.nilable(String), exemption_indicator: T.nilable(String), network_options: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions), requestor_challenge_indicator: T.nilable(String), transaction_id: String, version: String).void
}
def initialize(
ares_trans_status: nil,
cryptogram: nil,
electronic_commerce_indicator: nil,
exemption_indicator: nil,
network_options: nil,
requestor_challenge_indicator: nil,
transaction_id: nil,
version: nil
); end
end
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# A single-use `cvc_update` Token that represents a card CVC value. When provided, the CVC value will be verified during the card payment attempt. This parameter can only be provided during confirmation.
sig { returns(T.nilable(String)) }
attr_accessor :cvc_token
# Installment configuration for payments attempted on this PaymentIntent (Mexico Only).
#
# For more information, see the [installments integration guide](https://stripe.com/docs/payments/installments).
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Card::Installments))
}
attr_accessor :installments
# Configuration options for setting up an eMandate for cards issued in India.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Card::MandateOptions))
}
attr_accessor :mandate_options
# When specified, this parameter indicates that a transaction will be marked
# as MOTO (Mail Order Telephone Order) and thus out of scope for SCA. This
# parameter can only be provided during confirmation.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :moto
# Selected network to process this PaymentIntent on. Depends on the available networks of the card attached to the PaymentIntent. Can be only set confirm-time.
sig { returns(T.nilable(String)) }
attr_accessor :network
# Request ability to [decrement the authorization](https://stripe.com/docs/payments/decremental-authorization) for this PaymentIntent.
sig { returns(T.nilable(String)) }
attr_accessor :request_decremental_authorization
# Request ability to [capture beyond the standard authorization validity window](https://stripe.com/docs/payments/extended-authorization) for this PaymentIntent.
sig { returns(T.nilable(String)) }
attr_accessor :request_extended_authorization
# Request ability to [increment the authorization](https://stripe.com/docs/payments/incremental-authorization) for this PaymentIntent.
sig { returns(T.nilable(String)) }
attr_accessor :request_incremental_authorization
# Request ability to make [multiple captures](https://stripe.com/docs/payments/multicapture) for this PaymentIntent.
sig { returns(T.nilable(String)) }
attr_accessor :request_multicapture
# Request ability to [overcapture](https://stripe.com/docs/payments/overcapture) for this PaymentIntent.
sig { returns(T.nilable(String)) }
attr_accessor :request_overcapture
# Request partial authorization on this PaymentIntent.
sig { returns(T.nilable(String)) }
attr_accessor :request_partial_authorization
# We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. If not provided, this value defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
sig { returns(T.nilable(String)) }
attr_accessor :request_three_d_secure
# When enabled, using a card that is attached to a customer will require the CVC to be provided again (i.e. using the cvc_token parameter).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :require_cvc_recollection
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Provides information about a card payment that customers see on their statements. Concatenated with the Kana prefix (shortened Kana descriptor) or Kana statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 22 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 22 characters.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :statement_descriptor_suffix_kana
# Provides information about a card payment that customers see on their statements. Concatenated with the Kanji prefix (shortened Kanji descriptor) or Kanji statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 17 characters. On card statements, the *concatenation* of both prefix and suffix (including separators) will appear truncated to 17 characters.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :statement_descriptor_suffix_kanji
# Statement details for this payment intent. You can use this to override the merchant details shown on your customers' statements.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Card::StatementDetails))))
}
attr_accessor :statement_details
# If 3D Secure authentication was performed with a third-party provider,
# the authentication details to use for this payment.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Card::ThreeDSecure))
}
attr_accessor :three_d_secure
sig {
params(capture_method: T.nilable(T.nilable(String)), cvc_token: T.nilable(String), installments: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Card::Installments), mandate_options: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Card::MandateOptions), moto: T.nilable(T::Boolean), network: T.nilable(String), request_decremental_authorization: T.nilable(String), request_extended_authorization: T.nilable(String), request_incremental_authorization: T.nilable(String), request_multicapture: T.nilable(String), request_overcapture: T.nilable(String), request_partial_authorization: T.nilable(String), request_three_d_secure: T.nilable(String), require_cvc_recollection: T.nilable(T::Boolean), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), statement_descriptor_suffix_kana: T.nilable(T.nilable(String)), statement_descriptor_suffix_kanji: T.nilable(T.nilable(String)), statement_details: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Card::StatementDetails))), three_d_secure: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Card::ThreeDSecure)).void
}
def initialize(
capture_method: nil,
cvc_token: nil,
installments: nil,
mandate_options: nil,
moto: nil,
network: nil,
request_decremental_authorization: nil,
request_extended_authorization: nil,
request_incremental_authorization: nil,
request_multicapture: nil,
request_overcapture: nil,
request_partial_authorization: nil,
request_three_d_secure: nil,
require_cvc_recollection: nil,
setup_future_usage: nil,
statement_descriptor_suffix_kana: nil,
statement_descriptor_suffix_kanji: nil,
statement_details: nil,
three_d_secure: nil
); end
end
class CardPresent < Stripe::RequestParams
class Routing < Stripe::RequestParams
# Routing requested priority
sig { returns(T.nilable(String)) }
attr_accessor :requested_priority
sig { params(requested_priority: T.nilable(String)).void }
def initialize(requested_priority: nil); end
end
# Request ability to capture this payment beyond the standard [authorization validity window](https://stripe.com/docs/terminal/features/extended-authorizations#authorization-validity)
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :request_extended_authorization
# Request ability to [increment](https://stripe.com/docs/terminal/features/incremental-authorizations) this PaymentIntent if the combination of MCC and card brand is eligible. Check [incremental_authorization_supported](https://stripe.com/docs/api/charges/object#charge_object-payment_method_details-card_present-incremental_authorization_supported) in the [Confirm](https://stripe.com/docs/api/payment_intents/confirm) response to verify support.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :request_incremental_authorization_support
# Network routing priority on co-branded EMV cards supporting domestic debit and international card schemes.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::CardPresent::Routing))
}
attr_accessor :routing
sig {
params(request_extended_authorization: T.nilable(T::Boolean), request_incremental_authorization_support: T.nilable(T::Boolean), routing: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::CardPresent::Routing)).void
}
def initialize(
request_extended_authorization: nil,
request_incremental_authorization_support: nil,
routing: nil
); end
end
class Cashapp < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class CustomerBalance < Stripe::RequestParams
class BankTransfer < Stripe::RequestParams
class EuBankTransfer < Stripe::RequestParams
# The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
sig { returns(String) }
attr_accessor :country
sig { params(country: String).void }
def initialize(country: nil); end
end
# Configuration for the eu_bank_transfer funding type.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::CustomerBalance::BankTransfer::EuBankTransfer))
}
attr_accessor :eu_bank_transfer
# List of address types that should be returned in the financial_addresses response. If not specified, all valid types will be returned.
#
# Permitted values include: `sort_code`, `zengin`, `iban`, or `spei`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :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`, `mx_bank_transfer`, or `us_bank_transfer`.
sig { returns(String) }
attr_accessor :type
sig {
params(eu_bank_transfer: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::CustomerBalance::BankTransfer::EuBankTransfer), requested_address_types: T.nilable(T::Array[String]), type: String).void
}
def initialize(eu_bank_transfer: nil, requested_address_types: nil, type: nil); end
end
# Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::CustomerBalance::BankTransfer))
}
attr_accessor :bank_transfer
# The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
sig { returns(T.nilable(String)) }
attr_accessor :funding_type
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(bank_transfer: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::CustomerBalance::BankTransfer), funding_type: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(bank_transfer: nil, funding_type: nil, setup_future_usage: nil); end
end
class Eps < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Fpx < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Giropay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Gopay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Grabpay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class IdBankTransfer < Stripe::RequestParams
# The UNIX timestamp until which the virtual bank account is valid. Permitted range is from 5 minutes from now until 31 days from now. If unset, it defaults to 3 days from now.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_after
# The UNIX timestamp until which the virtual bank account is valid. Permitted range is from now until 30 days from now. If unset, it defaults to 1 days from now.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_at
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(expires_after: T.nilable(Integer), expires_at: T.nilable(Integer), setup_future_usage: T.nilable(String)).void
}
def initialize(expires_after: nil, expires_at: nil, setup_future_usage: nil); end
end
class Ideal < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void }
def initialize(setup_future_usage: nil); end
end
class InteracPresent < Stripe::RequestParams; end
class KakaoPay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class Klarna < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Preferred language of the Klarna authorization page that the customer is redirected to
sig { returns(T.nilable(String)) }
attr_accessor :preferred_locale
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), preferred_locale: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(capture_method: nil, preferred_locale: nil, setup_future_usage: nil); end
end
class Konbini < Stripe::RequestParams
# An optional 10 to 11 digit numeric-only string determining the confirmation code at applicable convenience stores. Must not consist of only zeroes and could be rejected in case of insufficient uniqueness. We recommend to use the customer's phone number.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :confirmation_number
# The number of calendar days (between 1 and 60) after which Konbini payment instructions will expire. For example, if a PaymentIntent is confirmed with Konbini and `expires_after_days` set to 2 on Monday JST, the instructions will expire on Wednesday 23:59:59 JST. Defaults to 3 days.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :expires_after_days
# The timestamp at which the Konbini payment instructions will expire. Only one of `expires_after_days` or `expires_at` may be set.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :expires_at
# A product descriptor of up to 22 characters, which will appear to customers at the convenience store.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :product_description
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(confirmation_number: T.nilable(T.nilable(String)), expires_after_days: T.nilable(T.nilable(T.any(String, Integer))), expires_at: T.nilable(T.nilable(T.any(String, Integer))), product_description: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(String)).void
}
def initialize(
confirmation_number: nil,
expires_after_days: nil,
expires_at: nil,
product_description: nil,
setup_future_usage: nil
); end
end
class KrCard < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class Link < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# [Deprecated] This is a legacy parameter that no longer has any function.
sig { returns(T.nilable(String)) }
attr_accessor :persistent_token
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), persistent_token: T.nilable(String), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(capture_method: nil, persistent_token: nil, setup_future_usage: nil); end
end
class MbWay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Mobilepay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(String)).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class Multibanco < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class NaverPay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class NzBankAccount < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
sig {
params(setup_future_usage: T.nilable(T.nilable(T.any(String, String))), target_date: T.nilable(String)).void
}
def initialize(setup_future_usage: nil, target_date: nil); end
end
class Oxxo < Stripe::RequestParams
# The number of calendar days before an OXXO voucher expires. For example, if you create an OXXO voucher on Monday and you set expires_after_days to 2, the OXXO invoice will expire on Wednesday at 23:59 America/Mexico_City time.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_after_days
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(expires_after_days: T.nilable(Integer), setup_future_usage: T.nilable(String)).void
}
def initialize(expires_after_days: nil, setup_future_usage: nil); end
end
class P24 < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
# Confirm that the payer has accepted the P24 terms and conditions.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :tos_shown_and_accepted
sig {
params(setup_future_usage: T.nilable(String), tos_shown_and_accepted: T.nilable(T::Boolean)).void
}
def initialize(setup_future_usage: nil, tos_shown_and_accepted: nil); end
end
class PayByBank < Stripe::RequestParams; end
class Payco < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
sig { params(capture_method: T.nilable(T.nilable(String))).void }
def initialize(capture_method: nil); end
end
class Paynow < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Paypal < Stripe::RequestParams
class LineItem < Stripe::RequestParams
class Tax < Stripe::RequestParams
# The tax for a single unit of the line item in minor units. Cannot be a negative number.
sig { returns(Integer) }
attr_accessor :amount
# The tax behavior for the line item.
sig { returns(String) }
attr_accessor :behavior
sig { params(amount: Integer, behavior: String).void }
def initialize(amount: nil, behavior: nil); end
end
# Type of the line item.
sig { returns(T.nilable(String)) }
attr_accessor :category
# Description of the line item.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Descriptive name of the line item.
sig { returns(String) }
attr_accessor :name
# Quantity of the line item. Must be a positive number.
sig { returns(Integer) }
attr_accessor :quantity
# Client facing stock keeping unit, article number or similar.
sig { returns(T.nilable(String)) }
attr_accessor :sku
# The Stripe account ID of the connected account that sells the item.
sig { returns(T.nilable(String)) }
attr_accessor :sold_by
# The tax information for the line item.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Paypal::LineItem::Tax))
}
attr_accessor :tax
# Price for a single unit of the line item in minor units. Cannot be a negative number.
sig { returns(Integer) }
attr_accessor :unit_amount
sig {
params(category: T.nilable(String), description: T.nilable(String), name: String, quantity: Integer, sku: T.nilable(String), sold_by: T.nilable(String), tax: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Paypal::LineItem::Tax), unit_amount: Integer).void
}
def initialize(
category: nil,
description: nil,
name: nil,
quantity: nil,
sku: nil,
sold_by: nil,
tax: nil,
unit_amount: nil
); end
end
# Controls when the funds will be captured from the customer's account.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# The line items purchased by the customer.
sig {
returns(T.nilable(T::Array[::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Paypal::LineItem]))
}
attr_accessor :line_items
# [Preferred locale](https://stripe.com/docs/payments/paypal/supported-locales) of the PayPal checkout page that the customer is redirected to.
sig { returns(T.nilable(String)) }
attr_accessor :preferred_locale
# A reference of the PayPal transaction visible to customer which is mapped to PayPal's invoice ID. This must be a globally unique ID if you have configured in your PayPal settings to block multiple payments per invoice ID.
sig { returns(T.nilable(String)) }
attr_accessor :reference
# A reference of the PayPal transaction visible to customer which is mapped to PayPal's invoice ID. This must be a globally unique ID if you have configured in your PayPal settings to block multiple payments per invoice ID.
sig { returns(T.nilable(String)) }
attr_accessor :reference_id
# The risk correlation ID for an on-session payment using a saved PayPal payment method.
sig { returns(T.nilable(String)) }
attr_accessor :risk_correlation_id
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# The Stripe connected account IDs of the sellers on the platform for this transaction (optional). Only allowed when [separate charges and transfers](https://stripe.com/docs/connect/separate-charges-and-transfers) are used.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :subsellers
sig {
params(capture_method: T.nilable(T.nilable(String)), line_items: T.nilable(T::Array[::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Paypal::LineItem]), preferred_locale: T.nilable(String), reference: T.nilable(String), reference_id: T.nilable(String), risk_correlation_id: T.nilable(String), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), subsellers: T.nilable(T::Array[String])).void
}
def initialize(
capture_method: nil,
line_items: nil,
preferred_locale: nil,
reference: nil,
reference_id: nil,
risk_correlation_id: nil,
setup_future_usage: nil,
subsellers: nil
); end
end
class Payto < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Amount that will be collected. It is required when `amount_type` is `fixed`.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# The type of amount that will be collected. The amount charged must be exact or up to the value of `amount` param for `fixed` or `maximum` type respectively.
sig { returns(T.nilable(String)) }
attr_accessor :amount_type
# Date, in YYYY-MM-DD format, after which payments will not be collected. Defaults to no end date.
sig { returns(T.nilable(String)) }
attr_accessor :end_date
# The periodicity at which payments will be collected.
sig { returns(T.nilable(String)) }
attr_accessor :payment_schedule
# The number of payments that will be made during a payment period. Defaults to 1 except for when `payment_schedule` is `adhoc`. In that case, it defaults to no limit.
sig { returns(T.nilable(Integer)) }
attr_accessor :payments_per_period
# The purpose for which payments are made. Defaults to retail.
sig { returns(T.nilable(String)) }
attr_accessor :purpose
sig {
params(amount: T.nilable(Integer), amount_type: T.nilable(String), end_date: T.nilable(String), payment_schedule: T.nilable(String), payments_per_period: T.nilable(Integer), purpose: T.nilable(String)).void
}
def initialize(
amount: nil,
amount_type: nil,
end_date: nil,
payment_schedule: nil,
payments_per_period: nil,
purpose: nil
); end
end
# Additional fields for Mandate creation. Only `purpose` field is configurable for PayTo PaymentIntent with `setup_future_usage=none`. Other fields are only applicable to PayTo PaymentIntent with `setup_future_usage=off_session`
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Payto::MandateOptions))
}
attr_accessor :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(mandate_options: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Payto::MandateOptions), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(mandate_options: nil, setup_future_usage: nil); end
end
class Pix < Stripe::RequestParams
# The number of seconds (between 10 and 1209600) after which Pix payment will expire. Defaults to 86400 seconds.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_after_seconds
# The timestamp at which the Pix expires (between 10 and 1209600 seconds in the future). Defaults to 1 day in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_at
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(expires_after_seconds: T.nilable(Integer), expires_at: T.nilable(Integer), setup_future_usage: T.nilable(String)).void
}
def initialize(expires_after_seconds: nil, expires_at: nil, setup_future_usage: nil); end
end
class Promptpay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Qris < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Rechnung < Stripe::RequestParams; end
class RevolutPay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(capture_method: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(capture_method: nil, setup_future_usage: nil); end
end
class SamsungPay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
sig { params(capture_method: T.nilable(T.nilable(String))).void }
def initialize(capture_method: nil); end
end
class Satispay < Stripe::RequestParams
# Controls when the funds are captured from the customer's account.
#
# If provided, this parameter overrides the behavior of the top-level [capture_method](/api/payment_intents/update#update_payment_intent-capture_method) for this payment method type when finalizing the payment with this payment method type.
#
# If `capture_method` is already set on the PaymentIntent, providing an empty value for this parameter unsets the stored value for this payment method type.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :capture_method
sig { params(capture_method: T.nilable(T.nilable(String))).void }
def initialize(capture_method: nil); end
end
class SepaDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'STRIPE'.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :reference_prefix
sig { params(reference_prefix: T.nilable(T.nilable(String))).void }
def initialize(reference_prefix: nil); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::SepaDebit::MandateOptions))
}
attr_accessor :mandate_options
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
sig {
params(mandate_options: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::SepaDebit::MandateOptions), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), target_date: T.nilable(String)).void
}
def initialize(mandate_options: nil, setup_future_usage: nil, target_date: nil); end
end
class Shopeepay < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class Sofort < Stripe::RequestParams
# Language shown to the payer on redirect.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :preferred_language
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig {
params(preferred_language: T.nilable(T.nilable(T.any(String, String))), setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(preferred_language: nil, setup_future_usage: nil); end
end
class StripeBalance < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(T.nilable(T.any(String, String)))).void }
def initialize(setup_future_usage: nil); end
end
class Swish < Stripe::RequestParams
# A reference for this payment to be displayed in the Swish app.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :reference
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(reference: T.nilable(T.nilable(String)), setup_future_usage: T.nilable(String)).void
}
def initialize(reference: nil, setup_future_usage: nil); end
end
class Twint < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
class UsBankAccount < Stripe::RequestParams
class FinancialConnections < Stripe::RequestParams
class Filters < Stripe::RequestParams
# The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :account_subcategories
# ID of the institution to use to filter for selectable accounts.
sig { returns(T.nilable(String)) }
attr_accessor :institution
sig {
params(account_subcategories: T.nilable(T::Array[String]), institution: T.nilable(String)).void
}
def initialize(account_subcategories: nil, institution: nil); end
end
class ManualEntry < Stripe::RequestParams
# Settings for configuring manual entry of account details.
sig { returns(String) }
attr_accessor :mode
sig { params(mode: String).void }
def initialize(mode: nil); end
end
# Provide filters for the linked accounts that the customer can select for the payment method.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::Filters))
}
attr_accessor :filters
# Customize manual entry behavior
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::ManualEntry))
}
attr_accessor :manual_entry
# The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :permissions
# List of data features that you would like to retrieve upon account creation.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :prefetch
# For webview integrations only. Upon completing OAuth login in the native browser, the user will be redirected to this URL to return to your app.
sig { returns(T.nilable(String)) }
attr_accessor :return_url
sig {
params(filters: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::Filters), manual_entry: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::ManualEntry), permissions: T.nilable(T::Array[String]), prefetch: T.nilable(T::Array[String]), return_url: T.nilable(String)).void
}
def initialize(
filters: nil,
manual_entry: nil,
permissions: nil,
prefetch: nil,
return_url: nil
); end
end
class MandateOptions < Stripe::RequestParams
# The method used to collect offline mandate customer acceptance.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :collection_method
sig { params(collection_method: T.nilable(T.nilable(String))).void }
def initialize(collection_method: nil); end
end
class Networks < Stripe::RequestParams
# Triggers validations to run across the selected networks
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Array[String])).void }
def initialize(requested: nil); end
end
# Additional fields for Financial Connections Session creation
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::UsBankAccount::FinancialConnections))
}
attr_accessor :financial_connections
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::UsBankAccount::MandateOptions))
}
attr_accessor :mandate_options
# Additional fields for network related functions
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::UsBankAccount::Networks))
}
attr_accessor :networks
# Preferred transaction settlement speed
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :preferred_settlement_speed
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Controls when Stripe will attempt to debit the funds from the customer's account. The date must be a string in YYYY-MM-DD format. The date must be in the future and between 3 and 15 calendar days from now.
sig { returns(T.nilable(String)) }
attr_accessor :target_date
# Bank account verification method.
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(financial_connections: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::UsBankAccount::FinancialConnections), mandate_options: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::UsBankAccount::MandateOptions), networks: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::UsBankAccount::Networks), preferred_settlement_speed: T.nilable(T.nilable(T.any(String, String))), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), target_date: T.nilable(String), verification_method: T.nilable(String)).void
}
def initialize(
financial_connections: nil,
mandate_options: nil,
networks: nil,
preferred_settlement_speed: nil,
setup_future_usage: nil,
target_date: nil,
verification_method: nil
); end
end
class WechatPay < Stripe::RequestParams
# The app ID registered with WeChat Pay. Only required when client is ios or android.
sig { returns(T.nilable(String)) }
attr_accessor :app_id
# The client type that the end customer will pay from
sig { returns(T.nilable(String)) }
attr_accessor :client
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig {
params(app_id: T.nilable(String), client: T.nilable(String), setup_future_usage: T.nilable(String)).void
}
def initialize(app_id: nil, client: nil, setup_future_usage: nil); end
end
class Zip < Stripe::RequestParams
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
sig { params(setup_future_usage: T.nilable(String)).void }
def initialize(setup_future_usage: nil); end
end
# If this is a `acss_debit` PaymentMethod, this sub-hash contains details about the ACSS Debit payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::AcssDebit))))
}
attr_accessor :acss_debit
# If this is an `affirm` PaymentMethod, this sub-hash contains details about the Affirm payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Affirm))))
}
attr_accessor :affirm
# If this is a `afterpay_clearpay` PaymentMethod, this sub-hash contains details about the Afterpay Clearpay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::AfterpayClearpay))))
}
attr_accessor :afterpay_clearpay
# If this is a `alipay` PaymentMethod, this sub-hash contains details about the Alipay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Alipay))))
}
attr_accessor :alipay
# If this is a `alma` PaymentMethod, this sub-hash contains details about the Alma payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Alma))))
}
attr_accessor :alma
# If this is a `amazon_pay` PaymentMethod, this sub-hash contains details about the Amazon Pay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::AmazonPay))))
}
attr_accessor :amazon_pay
# If this is a `au_becs_debit` PaymentMethod, this sub-hash contains details about the AU BECS Direct Debit payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::AuBecsDebit))))
}
attr_accessor :au_becs_debit
# If this is a `bacs_debit` PaymentMethod, this sub-hash contains details about the BACS Debit payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::BacsDebit))))
}
attr_accessor :bacs_debit
# If this is a `bancontact` PaymentMethod, this sub-hash contains details about the Bancontact payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Bancontact))))
}
attr_accessor :bancontact
# If this is a `billie` PaymentMethod, this sub-hash contains details about the Billie payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Billie))))
}
attr_accessor :billie
# If this is a `blik` PaymentMethod, this sub-hash contains details about the BLIK payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Blik))))
}
attr_accessor :blik
# If this is a `boleto` PaymentMethod, this sub-hash contains details about the Boleto payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Boleto))))
}
attr_accessor :boleto
# Configuration for any card payments attempted on this PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Card))))
}
attr_accessor :card
# If this is a `card_present` PaymentMethod, this sub-hash contains details about the Card Present payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::CardPresent))))
}
attr_accessor :card_present
# If this is a `cashapp` PaymentMethod, this sub-hash contains details about the Cash App Pay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Cashapp))))
}
attr_accessor :cashapp
# If this is a `customer balance` PaymentMethod, this sub-hash contains details about the customer balance payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::CustomerBalance))))
}
attr_accessor :customer_balance
# If this is a `eps` PaymentMethod, this sub-hash contains details about the EPS payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Eps))))
}
attr_accessor :eps
# If this is a `fpx` PaymentMethod, this sub-hash contains details about the FPX payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Fpx))))
}
attr_accessor :fpx
# If this is a `giropay` PaymentMethod, this sub-hash contains details about the Giropay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Giropay))))
}
attr_accessor :giropay
# If this is a `gopay` PaymentMethod, this sub-hash contains details about the Gopay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Gopay))))
}
attr_accessor :gopay
# If this is a `grabpay` PaymentMethod, this sub-hash contains details about the Grabpay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Grabpay))))
}
attr_accessor :grabpay
# If this is a `id_bank_transfer` PaymentMethod, this sub-hash contains details about the Indonesia Bank Transfer payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::IdBankTransfer))))
}
attr_accessor :id_bank_transfer
# If this is a `ideal` PaymentMethod, this sub-hash contains details about the Ideal payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Ideal))))
}
attr_accessor :ideal
# If this is a `interac_present` PaymentMethod, this sub-hash contains details about the Card Present payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::InteracPresent))))
}
attr_accessor :interac_present
# If this is a `kakao_pay` PaymentMethod, this sub-hash contains details about the Kakao Pay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::KakaoPay))))
}
attr_accessor :kakao_pay
# If this is a `klarna` PaymentMethod, this sub-hash contains details about the Klarna payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Klarna))))
}
attr_accessor :klarna
# If this is a `konbini` PaymentMethod, this sub-hash contains details about the Konbini payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Konbini))))
}
attr_accessor :konbini
# If this is a `kr_card` PaymentMethod, this sub-hash contains details about the KR Card payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::KrCard))))
}
attr_accessor :kr_card
# If this is a `link` PaymentMethod, this sub-hash contains details about the Link payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Link))))
}
attr_accessor :link
# If this is a `mb_way` PaymentMethod, this sub-hash contains details about the MB WAY payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::MbWay))))
}
attr_accessor :mb_way
# If this is a `MobilePay` PaymentMethod, this sub-hash contains details about the MobilePay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Mobilepay))))
}
attr_accessor :mobilepay
# If this is a `multibanco` PaymentMethod, this sub-hash contains details about the Multibanco payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Multibanco))))
}
attr_accessor :multibanco
# If this is a `naver_pay` PaymentMethod, this sub-hash contains details about the Naver Pay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::NaverPay))))
}
attr_accessor :naver_pay
# If this is a `nz_bank_account` PaymentMethod, this sub-hash contains details about the NZ BECS Direct Debit payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::NzBankAccount))))
}
attr_accessor :nz_bank_account
# If this is a `oxxo` PaymentMethod, this sub-hash contains details about the OXXO payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Oxxo))))
}
attr_accessor :oxxo
# If this is a `p24` PaymentMethod, this sub-hash contains details about the Przelewy24 payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::P24))))
}
attr_accessor :p24
# If this is a `pay_by_bank` PaymentMethod, this sub-hash contains details about the PayByBank payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::PayByBank))))
}
attr_accessor :pay_by_bank
# If this is a `payco` PaymentMethod, this sub-hash contains details about the PAYCO payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Payco))))
}
attr_accessor :payco
# If this is a `paynow` PaymentMethod, this sub-hash contains details about the PayNow payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Paynow))))
}
attr_accessor :paynow
# If this is a `paypal` PaymentMethod, this sub-hash contains details about the PayPal payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Paypal))))
}
attr_accessor :paypal
# If this is a `payto` PaymentMethod, this sub-hash contains details about the PayTo payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Payto))))
}
attr_accessor :payto
# If this is a `pix` PaymentMethod, this sub-hash contains details about the Pix payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Pix))))
}
attr_accessor :pix
# If this is a `promptpay` PaymentMethod, this sub-hash contains details about the PromptPay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Promptpay))))
}
attr_accessor :promptpay
# If this is a `qris` PaymentMethod, this sub-hash contains details about the QRIS payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Qris))))
}
attr_accessor :qris
# If this is a `rechnung` PaymentMethod, this sub-hash contains details about the Rechnung payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Rechnung))))
}
attr_accessor :rechnung
# If this is a `revolut_pay` PaymentMethod, this sub-hash contains details about the Revolut Pay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::RevolutPay))))
}
attr_accessor :revolut_pay
# If this is a `samsung_pay` PaymentMethod, this sub-hash contains details about the Samsung Pay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::SamsungPay))))
}
attr_accessor :samsung_pay
# If this is a `satispay` PaymentMethod, this sub-hash contains details about the Satispay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Satispay))))
}
attr_accessor :satispay
# If this is a `sepa_debit` PaymentIntent, this sub-hash contains details about the SEPA Debit payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::SepaDebit))))
}
attr_accessor :sepa_debit
# If this is a `shopeepay` PaymentMethod, this sub-hash contains details about the ShopeePay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Shopeepay))))
}
attr_accessor :shopeepay
# If this is a `sofort` PaymentMethod, this sub-hash contains details about the SOFORT payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Sofort))))
}
attr_accessor :sofort
# If this is a `stripe_balance` PaymentMethod, this sub-hash contains details about the Stripe Balance payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::StripeBalance))))
}
attr_accessor :stripe_balance
# If this is a `Swish` PaymentMethod, this sub-hash contains details about the Swish payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Swish))))
}
attr_accessor :swish
# If this is a `twint` PaymentMethod, this sub-hash contains details about the TWINT payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Twint))))
}
attr_accessor :twint
# If this is a `us_bank_account` PaymentMethod, this sub-hash contains details about the US bank account payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::UsBankAccount))))
}
attr_accessor :us_bank_account
# If this is a `wechat_pay` PaymentMethod, this sub-hash contains details about the WeChat Pay payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::WechatPay))))
}
attr_accessor :wechat_pay
# If this is a `zip` PaymentMethod, this sub-hash contains details about the Zip payment method options.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Zip))))
}
attr_accessor :zip
sig {
params(acss_debit: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::AcssDebit))), affirm: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Affirm))), afterpay_clearpay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::AfterpayClearpay))), alipay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Alipay))), alma: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Alma))), amazon_pay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::AmazonPay))), au_becs_debit: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::AuBecsDebit))), bacs_debit: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::BacsDebit))), bancontact: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Bancontact))), billie: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Billie))), blik: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Blik))), boleto: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Boleto))), card: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Card))), card_present: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::CardPresent))), cashapp: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Cashapp))), customer_balance: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::CustomerBalance))), eps: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Eps))), fpx: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Fpx))), giropay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Giropay))), gopay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Gopay))), grabpay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Grabpay))), id_bank_transfer: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::IdBankTransfer))), ideal: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Ideal))), interac_present: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::InteracPresent))), kakao_pay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::KakaoPay))), klarna: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Klarna))), konbini: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Konbini))), kr_card: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::KrCard))), link: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Link))), mb_way: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::MbWay))), mobilepay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Mobilepay))), multibanco: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Multibanco))), naver_pay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::NaverPay))), nz_bank_account: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::NzBankAccount))), oxxo: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Oxxo))), p24: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::P24))), pay_by_bank: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::PayByBank))), payco: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Payco))), paynow: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Paynow))), paypal: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Paypal))), payto: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Payto))), pix: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Pix))), promptpay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Promptpay))), qris: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Qris))), rechnung: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Rechnung))), revolut_pay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::RevolutPay))), samsung_pay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::SamsungPay))), satispay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Satispay))), sepa_debit: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::SepaDebit))), shopeepay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Shopeepay))), sofort: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Sofort))), stripe_balance: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::StripeBalance))), swish: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Swish))), twint: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Twint))), us_bank_account: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::UsBankAccount))), wechat_pay: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::WechatPay))), zip: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions::Zip)))).void
}
def initialize(
acss_debit: nil,
affirm: nil,
afterpay_clearpay: nil,
alipay: nil,
alma: nil,
amazon_pay: nil,
au_becs_debit: nil,
bacs_debit: nil,
bancontact: nil,
billie: nil,
blik: nil,
boleto: nil,
card: nil,
card_present: nil,
cashapp: nil,
customer_balance: nil,
eps: nil,
fpx: nil,
giropay: nil,
gopay: nil,
grabpay: nil,
id_bank_transfer: nil,
ideal: nil,
interac_present: nil,
kakao_pay: nil,
klarna: nil,
konbini: nil,
kr_card: nil,
link: nil,
mb_way: nil,
mobilepay: nil,
multibanco: nil,
naver_pay: nil,
nz_bank_account: nil,
oxxo: nil,
p24: nil,
pay_by_bank: nil,
payco: nil,
paynow: nil,
paypal: nil,
payto: nil,
pix: nil,
promptpay: nil,
qris: nil,
rechnung: nil,
revolut_pay: nil,
samsung_pay: nil,
satispay: nil,
sepa_debit: nil,
shopeepay: nil,
sofort: nil,
stripe_balance: nil,
swish: nil,
twint: nil,
us_bank_account: nil,
wechat_pay: nil,
zip: nil
); end
end
class RadarOptions < Stripe::RequestParams
# A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
sig { returns(T.nilable(String)) }
attr_accessor :session
sig { params(session: T.nilable(String)).void }
def initialize(session: nil); end
end
class Shipping < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Shipping address.
sig { returns(::Stripe::PaymentIntentService::ConfirmParams::Shipping::Address) }
attr_accessor :address
# The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
sig { returns(T.nilable(String)) }
attr_accessor :carrier
# Recipient name.
sig { returns(String) }
attr_accessor :name
# Recipient phone (including extension).
sig { returns(T.nilable(String)) }
attr_accessor :phone
# The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
sig { returns(T.nilable(String)) }
attr_accessor :tracking_number
sig {
params(address: ::Stripe::PaymentIntentService::ConfirmParams::Shipping::Address, carrier: T.nilable(String), name: String, phone: T.nilable(String), tracking_number: T.nilable(String)).void
}
def initialize(address: nil, carrier: nil, name: nil, phone: nil, tracking_number: nil); end
end
# The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. The amount of the application fee collected will be capped at the total amount captured. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :application_fee_amount
# Controls when the funds will be captured from the customer's account.
sig { returns(T.nilable(String)) }
attr_accessor :capture_method
# ID of the ConfirmationToken used to confirm this PaymentIntent.
#
# If the provided ConfirmationToken contains properties that are also being provided in this request, such as `payment_method`, then the values in this request will take precedence.
sig { returns(T.nilable(String)) }
attr_accessor :confirmation_token
# Set to `true` to fail the payment attempt if the PaymentIntent transitions into `requires_action`. This parameter is intended for simpler integrations that do not handle customer actions, like [saving cards without authentication](https://stripe.com/docs/payments/save-card-without-authentication).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :error_on_requires_action
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The FX rate in the quote is validated and used to convert the presentment amount to the settlement amount.
sig { returns(T.nilable(String)) }
attr_accessor :fx_quote
# Automations to be run during the PaymentIntent lifecycle
sig { returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::Hooks)) }
attr_accessor :hooks
# ID of the mandate that's used for this payment.
sig { returns(T.nilable(String)) }
attr_accessor :mandate
# Attribute for param field mandate_data
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::MandateData))))
}
attr_accessor :mandate_data
# Set to `true` to indicate that the customer isn't in your checkout flow during this payment attempt and can't authenticate. Use this parameter in scenarios where you collect card details and [charge them later](https://stripe.com/docs/payments/cards/charging-saved-cards).
sig { returns(T.nilable(T.any(T::Boolean, String))) }
attr_accessor :off_session
# Provides industry-specific information about the charge.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails))))
}
attr_accessor :payment_details
# ID of the payment method (a PaymentMethod, Card, or [compatible Source](https://stripe.com/docs/payments/payment-methods/transitioning#compatibility) object) to attach to this PaymentIntent.
# If the payment method is attached to a Customer, it must match the [customer](https://stripe.com/docs/api#create_payment_intent-customer) that is set on this PaymentIntent.
sig { returns(T.nilable(String)) }
attr_accessor :payment_method
# If provided, this hash will be used to create a PaymentMethod. The new PaymentMethod will appear
# in the [payment_method](https://stripe.com/docs/api/payment_intents/object#payment_intent_object-payment_method)
# property on the PaymentIntent.
sig { returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData)) }
attr_accessor :payment_method_data
# Payment method-specific configuration for this PaymentIntent.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions))
}
attr_accessor :payment_method_options
# The list of payment method types (for example, a card) that this PaymentIntent can use. Use `automatic_payment_methods` to manage payment methods from the [Stripe Dashboard](https://dashboard.stripe.com/settings/payment_methods).
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :payment_method_types
# Options to configure Radar. Learn more about [Radar Sessions](https://stripe.com/docs/radar/radar-session).
sig { returns(T.nilable(::Stripe::PaymentIntentService::ConfirmParams::RadarOptions)) }
attr_accessor :radar_options
# Email address that the receipt for the resulting payment will be sent to. If `receipt_email` is specified for a payment in live mode, a receipt will be sent regardless of your [email settings](https://dashboard.stripe.com/account/emails).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :receipt_email
# The URL to redirect your customer back to after they authenticate or cancel their payment on the payment method's app or site.
# If you'd prefer to redirect to a mobile application, you can alternatively supply an application URI scheme.
# This parameter is only used for cards and other redirect-based payment methods.
sig { returns(T.nilable(String)) }
attr_accessor :return_url
# Indicates that you intend to make future payments with this PaymentIntent's payment method.
#
# If you provide a Customer with the PaymentIntent, you can use this parameter to [attach the payment method](/payments/save-during-payment) to the Customer after the PaymentIntent is confirmed and the customer completes any required actions. If you don't provide a Customer, you can still [attach](/api/payment_methods/attach) the payment method to a Customer after the transaction completes.
#
# If the payment method is `card_present` and isn't a digital wallet, Stripe creates and attaches a [generated_card](/api/charges/object#charge_object-payment_method_details-card_present-generated_card) payment method representing the card to the Customer instead.
#
# When processing card payments, Stripe uses `setup_future_usage` to help you comply with regional legislation and network rules, such as [SCA](/strong-customer-authentication).
#
# If you've already set `setup_future_usage` and you're performing a request using a publishable key, you can only update the value from `on_session` to `off_session`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :setup_future_usage
# Shipping information for this PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::Shipping))))
}
attr_accessor :shipping
# Set to `true` when confirming server-side and using Stripe.js, iOS, or Android client-side SDKs to handle the next actions.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :use_stripe_sdk
sig {
params(application_fee_amount: T.nilable(T.nilable(T.any(String, Integer))), capture_method: T.nilable(String), confirmation_token: T.nilable(String), error_on_requires_action: T.nilable(T::Boolean), expand: T.nilable(T::Array[String]), fx_quote: T.nilable(String), hooks: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::Hooks), mandate: T.nilable(String), mandate_data: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::MandateData))), off_session: T.nilable(T.any(T::Boolean, String)), payment_details: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::PaymentDetails))), payment_method: T.nilable(String), payment_method_data: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodData), payment_method_options: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::PaymentMethodOptions), payment_method_types: T.nilable(T::Array[String]), radar_options: T.nilable(::Stripe::PaymentIntentService::ConfirmParams::RadarOptions), receipt_email: T.nilable(T.nilable(String)), return_url: T.nilable(String), setup_future_usage: T.nilable(T.nilable(T.any(String, String))), shipping: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentIntentService::ConfirmParams::Shipping))), use_stripe_sdk: T.nilable(T::Boolean)).void
}
def initialize(
application_fee_amount: nil,
capture_method: nil,
confirmation_token: nil,
error_on_requires_action: nil,
expand: nil,
fx_quote: nil,
hooks: nil,
mandate: nil,
mandate_data: nil,
off_session: nil,
payment_details: nil,
payment_method: nil,
payment_method_data: nil,
payment_method_options: nil,
payment_method_types: nil,
radar_options: nil,
receipt_email: nil,
return_url: nil,
setup_future_usage: nil,
shipping: nil,
use_stripe_sdk: nil
); end
end
class DecrementAuthorizationParams < Stripe::RequestParams
class Hooks < Stripe::RequestParams
class Inputs < Stripe::RequestParams
class Tax < Stripe::RequestParams
# The [TaxCalculation](https://stripe.com/docs/api/tax/calculations) id
sig { returns(T.nilable(String)) }
attr_accessor :calculation
sig { params(calculation: T.nilable(String)).void }
def initialize(calculation: nil); end
end
# Tax arguments for automations
sig {
returns(T.nilable(::Stripe::PaymentIntentService::DecrementAuthorizationParams::Hooks::Inputs::Tax))
}
attr_accessor :tax
sig {
params(tax: T.nilable(::Stripe::PaymentIntentService::DecrementAuthorizationParams::Hooks::Inputs::Tax)).void
}
def initialize(tax: nil); end
end
# Arguments passed in automations
sig {
returns(T.nilable(::Stripe::PaymentIntentService::DecrementAuthorizationParams::Hooks::Inputs))
}
attr_accessor :inputs
sig {
params(inputs: T.nilable(::Stripe::PaymentIntentService::DecrementAuthorizationParams::Hooks::Inputs)).void
}
def initialize(inputs: nil); end
end
class TransferData < Stripe::RequestParams
# The amount that will be transferred automatically when a charge succeeds.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
sig { params(amount: T.nilable(Integer)).void }
def initialize(amount: nil); end
end
# The updated total amount that you intend to collect from the cardholder. This amount must be smaller than the currently authorized amount and greater than the already captured amount.
sig { returns(Integer) }
attr_accessor :amount
# The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. The amount of the application fee collected will be capped at the total amount captured. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
sig { returns(T.nilable(Integer)) }
attr_accessor :application_fee_amount
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Automations to be run during the PaymentIntent lifecycle
sig {
returns(T.nilable(::Stripe::PaymentIntentService::DecrementAuthorizationParams::Hooks))
}
attr_accessor :hooks
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The parameters used to automatically create a transfer after the payment is captured.
# Learn more about the [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
sig {
returns(T.nilable(::Stripe::PaymentIntentService::DecrementAuthorizationParams::TransferData))
}
attr_accessor :transfer_data
sig {
params(amount: Integer, application_fee_amount: T.nilable(Integer), description: T.nilable(String), expand: T.nilable(T::Array[String]), hooks: T.nilable(::Stripe::PaymentIntentService::DecrementAuthorizationParams::Hooks), metadata: T.nilable(T::Hash[String, String]), transfer_data: T.nilable(::Stripe::PaymentIntentService::DecrementAuthorizationParams::TransferData)).void
}
def initialize(
amount: nil,
application_fee_amount: nil,
description: nil,
expand: nil,
hooks: nil,
metadata: nil,
transfer_data: nil
); end
end
class IncrementAuthorizationParams < Stripe::RequestParams
class Hooks < Stripe::RequestParams
class Inputs < Stripe::RequestParams
class Tax < Stripe::RequestParams
# The [TaxCalculation](https://stripe.com/docs/api/tax/calculations) id
sig { returns(T.nilable(String)) }
attr_accessor :calculation
sig { params(calculation: T.nilable(String)).void }
def initialize(calculation: nil); end
end
# Tax arguments for automations
sig {
returns(T.nilable(::Stripe::PaymentIntentService::IncrementAuthorizationParams::Hooks::Inputs::Tax))
}
attr_accessor :tax
sig {
params(tax: T.nilable(::Stripe::PaymentIntentService::IncrementAuthorizationParams::Hooks::Inputs::Tax)).void
}
def initialize(tax: nil); end
end
# Arguments passed in automations
sig {
returns(T.nilable(::Stripe::PaymentIntentService::IncrementAuthorizationParams::Hooks::Inputs))
}
attr_accessor :inputs
sig {
params(inputs: T.nilable(::Stripe::PaymentIntentService::IncrementAuthorizationParams::Hooks::Inputs)).void
}
def initialize(inputs: nil); end
end
class PaymentMethodOptions < Stripe::RequestParams
class Card < Stripe::RequestParams
# Request partial authorization on this PaymentIntent.
sig { returns(T.nilable(String)) }
attr_accessor :request_partial_authorization
sig { params(request_partial_authorization: T.nilable(String)).void }
def initialize(request_partial_authorization: nil); end
end
# Configuration for any card payments attempted on this PaymentIntent.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::IncrementAuthorizationParams::PaymentMethodOptions::Card))
}
attr_accessor :card
sig {
params(card: T.nilable(::Stripe::PaymentIntentService::IncrementAuthorizationParams::PaymentMethodOptions::Card)).void
}
def initialize(card: nil); end
end
class TransferData < Stripe::RequestParams
# The amount that will be transferred automatically when a charge succeeds.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
sig { params(amount: T.nilable(Integer)).void }
def initialize(amount: nil); end
end
# The updated total amount that you intend to collect from the cardholder. This amount must be greater than the currently authorized amount.
sig { returns(Integer) }
attr_accessor :amount
# The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. The amount of the application fee collected will be capped at the total amount captured. For more information, see the PaymentIntents [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
sig { returns(T.nilable(Integer)) }
attr_accessor :application_fee_amount
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Automations to be run during the PaymentIntent lifecycle
sig {
returns(T.nilable(::Stripe::PaymentIntentService::IncrementAuthorizationParams::Hooks))
}
attr_accessor :hooks
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Payment method-specific configuration for this PaymentIntent.
sig {
returns(T.nilable(::Stripe::PaymentIntentService::IncrementAuthorizationParams::PaymentMethodOptions))
}
attr_accessor :payment_method_options
# Text that appears on the customer's statement as the statement descriptor for a non-card or card charge. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
# The parameters used to automatically create a transfer after the payment is captured.
# Learn more about the [use case for connected accounts](https://stripe.com/docs/payments/connected-accounts).
sig {
returns(T.nilable(::Stripe::PaymentIntentService::IncrementAuthorizationParams::TransferData))
}
attr_accessor :transfer_data
sig {
params(amount: Integer, application_fee_amount: T.nilable(Integer), description: T.nilable(String), expand: T.nilable(T::Array[String]), hooks: T.nilable(::Stripe::PaymentIntentService::IncrementAuthorizationParams::Hooks), metadata: T.nilable(T::Hash[String, String]), payment_method_options: T.nilable(::Stripe::PaymentIntentService::IncrementAuthorizationParams::PaymentMethodOptions), statement_descriptor: T.nilable(String), transfer_data: T.nilable(::Stripe::PaymentIntentService::IncrementAuthorizationParams::TransferData)).void
}
def initialize(
amount: nil,
application_fee_amount: nil,
description: nil,
expand: nil,
hooks: nil,
metadata: nil,
payment_method_options: nil,
statement_descriptor: nil,
transfer_data: nil
); end
end
class VerifyMicrodepositsParams < Stripe::RequestParams
# Two positive integers, in *cents*, equal to the values of the microdeposits sent to the bank account.
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :amounts
# A six-character code starting with SM present in the microdeposit sent to the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :descriptor_code
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig {
params(amounts: T.nilable(T::Array[Integer]), descriptor_code: T.nilable(String), expand: T.nilable(T::Array[String])).void
}
def initialize(amounts: nil, descriptor_code: nil, expand: nil); end
end
class TriggerActionParams < Stripe::RequestParams
class ScanQrCode < Stripe::RequestParams
# Whether the QR Code scan's payment should succeed or fail.
sig { returns(T.nilable(String)) }
attr_accessor :result
sig { params(result: T.nilable(String)).void }
def initialize(result: nil); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# True to simulate success, false to simulate failure.
sig { returns(T.nilable(::Stripe::PaymentIntentService::TriggerActionParams::ScanQrCode)) }
attr_accessor :scan_qr_code
# The type of action to be simulated.
sig { returns(String) }
attr_accessor :type
sig {
params(expand: T.nilable(T::Array[String]), scan_qr_code: T.nilable(::Stripe::PaymentIntentService::TriggerActionParams::ScanQrCode), type: String).void
}
def initialize(expand: nil, scan_qr_code: nil, type: nil); end
end
# Manually reconcile the remaining amount for a customer_balance PaymentIntent.
sig {
params(intent: String, params: T.any(::Stripe::PaymentIntentService::ApplyCustomerBalanceParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentIntent)
}
def apply_customer_balance(intent, params = {}, opts = {}); end
# You can cancel a PaymentIntent object when it's in one of these statuses: requires_payment_method, requires_capture, requires_confirmation, requires_action or, [in rare cases](https://docs.stripe.com/docs/payments/intents), processing.
#
# After it's canceled, no additional charges are made by the PaymentIntent and any operations on the PaymentIntent fail with an error. For PaymentIntents with a status of requires_capture, the remaining amount_capturable is automatically refunded.
#
# You can't cancel the PaymentIntent for a Checkout Session. [Expire the Checkout Session](https://docs.stripe.com/docs/api/checkout/sessions/expire) instead.
sig {
params(intent: String, params: T.any(::Stripe::PaymentIntentService::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentIntent)
}
def cancel(intent, params = {}, opts = {}); end
# Capture the funds of an existing uncaptured PaymentIntent when its status is requires_capture.
#
# Uncaptured PaymentIntents are cancelled a set number of days (7 by default) after their creation.
#
# Learn more about [separate authorization and capture](https://docs.stripe.com/docs/payments/capture-later).
sig {
params(intent: String, params: T.any(::Stripe::PaymentIntentService::CaptureParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentIntent)
}
def capture(intent, params = {}, opts = {}); end
# Confirm that your customer intends to pay with current or provided
# payment method. Upon confirmation, the PaymentIntent will attempt to initiate
# a payment.
# If the selected payment method requires additional authentication steps, the
# PaymentIntent will transition to the requires_action status and
# suggest additional actions via next_action. If payment fails,
# the PaymentIntent transitions to the requires_payment_method status or the
# canceled status if the confirmation limit is reached. If
# payment succeeds, the PaymentIntent will transition to the succeeded
# status (or requires_capture, if capture_method is set to manual).
# If the confirmation_method is automatic, payment may be attempted
# using our [client SDKs](https://docs.stripe.com/docs/stripe-js/reference#stripe-handle-card-payment)
# and the PaymentIntent's [client_secret](https://docs.stripe.com/api#payment_intent_object-client_secret).
# After next_actions are handled by the client, no additional
# confirmation is required to complete the payment.
# If the confirmation_method is manual, all payment attempts must be
# initiated using a secret key.
# If any actions are required for the payment, the PaymentIntent will
# return to the requires_confirmation state
# after those actions are completed. Your server needs to then
# explicitly re-confirm the PaymentIntent to initiate the next payment
# attempt.
# There is a variable upper limit on how many times a PaymentIntent can be confirmed.
# After this limit is reached, any further calls to this endpoint will
# transition the PaymentIntent to the canceled state.
sig {
params(intent: String, params: T.any(::Stripe::PaymentIntentService::ConfirmParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentIntent)
}
def confirm(intent, params = {}, opts = {}); end
# Creates a PaymentIntent object.
#
# After the PaymentIntent is created, attach a payment method and [confirm](https://docs.stripe.com/docs/api/payment_intents/confirm)
# to continue the payment. Learn more about the available payment flows
# with the Payment Intents API.
#
# When you use confirm=true during creation, it's equivalent to creating
# and confirming the PaymentIntent in the same call. You can use any parameters
# available in the [confirm API](https://docs.stripe.com/docs/api/payment_intents/confirm) when you supply
# confirm=true.
sig {
params(params: T.any(::Stripe::PaymentIntentService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentIntent)
}
def create(params = {}, opts = {}); end
# Perform a decremental authorization on an eligible
# [PaymentIntent](https://docs.stripe.com/docs/api/payment_intents/object). To be eligible, the
# PaymentIntent's status must be requires_capture and
# [decremental_authorization.status](https://docs.stripe.com/docs/api/charges/object#charge_object-payment_method_details-card-decremental_authorization)
# must be available.
#
# Decremental authorizations decrease the authorized amount on your customer's card
# to the new, lower amount provided. A single PaymentIntent can call this endpoint multiple times to further decrease the authorized amount.
#
# After decrement, the PaymentIntent object
# returns with the updated
# [amount](https://docs.stripe.com/docs/api/payment_intents/object#payment_intent_object-amount).
# The PaymentIntent will now be capturable up to the new authorized amount.
#
# Each PaymentIntent can have a maximum of 10 decremental or incremental authorization attempts, including declines.
# After it's fully captured, a PaymentIntent can no longer be decremented.
sig {
params(intent: String, params: T.any(::Stripe::PaymentIntentService::DecrementAuthorizationParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentIntent)
}
def decrement_authorization(intent, params = {}, opts = {}); end
# Perform an incremental authorization on an eligible
# [PaymentIntent](https://docs.stripe.com/docs/api/payment_intents/object). To be eligible, the
# PaymentIntent's status must be requires_capture and
# [incremental_authorization_supported](https://docs.stripe.com/docs/api/charges/object#charge_object-payment_method_details-card_present-incremental_authorization_supported)
# must be true.
#
# Incremental authorizations attempt to increase the authorized amount on
# your customer's card to the new, higher amount provided. Similar to the
# initial authorization, incremental authorizations can be declined. A
# single PaymentIntent can call this endpoint multiple times to further
# increase the authorized amount.
#
# If the incremental authorization succeeds, the PaymentIntent object
# returns with the updated
# [amount](https://docs.stripe.com/docs/api/payment_intents/object#payment_intent_object-amount).
# If the incremental authorization fails, a
# [card_declined](https://docs.stripe.com/docs/error-codes#card-declined) error returns, and no other
# fields on the PaymentIntent or Charge update. The PaymentIntent
# object remains capturable for the previously authorized amount.
#
# Each PaymentIntent can have a maximum of 10 incremental authorization attempts, including declines.
# After it's captured, a PaymentIntent can no longer be incremented.
#
# Learn more about [incremental authorizations](https://docs.stripe.com/docs/terminal/features/incremental-authorizations).
sig {
params(intent: String, params: T.any(::Stripe::PaymentIntentService::IncrementAuthorizationParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentIntent)
}
def increment_authorization(intent, params = {}, opts = {}); end
# Returns a list of PaymentIntents.
sig {
params(params: T.any(::Stripe::PaymentIntentService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the details of a PaymentIntent that has previously been created.
#
# You can retrieve a PaymentIntent client-side using a publishable key when the client_secret is in the query string.
#
# If you retrieve a PaymentIntent with a publishable key, it only returns a subset of properties. Refer to the [payment intent](https://docs.stripe.com/api#payment_intent_object) object reference for more details.
sig {
params(intent: String, params: T.any(::Stripe::PaymentIntentService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentIntent)
}
def retrieve(intent, params = {}, opts = {}); end
# Search for PaymentIntents you've previously created using Stripe's [Search Query Language](https://docs.stripe.com/docs/search#search-query-language).
# Don't use search in read-after-write flows where strict consistency is necessary. Under normal operating
# conditions, data is searchable in less than a minute. Occasionally, propagation of new or updated data can be up
# to an hour behind during outages. Search functionality is not available to merchants in India.
sig {
params(params: T.any(::Stripe::PaymentIntentService::SearchParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SearchResultObject)
}
def search(params = {}, opts = {}); end
# Trigger an external action on a PaymentIntent.
sig {
params(intent: String, params: T.any(::Stripe::PaymentIntentService::TriggerActionParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentIntent)
}
def trigger_action(intent, params = {}, opts = {}); end
# Updates properties on a PaymentIntent object without confirming.
#
# Depending on which properties you update, you might need to confirm the
# PaymentIntent again. For example, updating the payment_method
# always requires you to confirm the PaymentIntent again. If you prefer to
# update and confirm at the same time, we recommend updating properties through
# the [confirm API](https://docs.stripe.com/docs/api/payment_intents/confirm) instead.
sig {
params(intent: String, params: T.any(::Stripe::PaymentIntentService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentIntent)
}
def update(intent, params = {}, opts = {}); end
# Verifies microdeposits on a PaymentIntent object.
sig {
params(intent: String, params: T.any(::Stripe::PaymentIntentService::VerifyMicrodepositsParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentIntent)
}
def verify_microdeposits(intent, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class PaymentIntentAmountDetailsLineItemService < StripeService
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
# Lists all LineItems of a given PaymentIntent.
sig {
params(intent: String, params: T.any(::Stripe::PaymentIntentAmountDetailsLineItemService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(intent, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class PaymentLinkService < StripeService
attr_reader :line_items
class ListParams < Stripe::RequestParams
# Only return payment links that are active or inactive (e.g., pass `false` to list all inactive payment links).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(active: T.nilable(T::Boolean), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
active: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class AfterCompletion < Stripe::RequestParams
class HostedConfirmation < Stripe::RequestParams
# A custom message to display to the customer after the purchase is complete.
sig { returns(T.nilable(String)) }
attr_accessor :custom_message
sig { params(custom_message: T.nilable(String)).void }
def initialize(custom_message: nil); end
end
class Redirect < Stripe::RequestParams
# The URL the customer will be redirected to after the purchase is complete. You can embed `{CHECKOUT_SESSION_ID}` into the URL to have the `id` of the completed [checkout session](https://stripe.com/docs/api/checkout/sessions/object#checkout_session_object-id) included.
sig { returns(String) }
attr_accessor :url
sig { params(url: String).void }
def initialize(url: nil); end
end
# Configuration when `type=hosted_confirmation`.
sig {
returns(T.nilable(::Stripe::PaymentLinkService::CreateParams::AfterCompletion::HostedConfirmation))
}
attr_accessor :hosted_confirmation
# Configuration when `type=redirect`.
sig {
returns(T.nilable(::Stripe::PaymentLinkService::CreateParams::AfterCompletion::Redirect))
}
attr_accessor :redirect
# The specified behavior after the purchase is complete. Either `redirect` or `hosted_confirmation`.
sig { returns(String) }
attr_accessor :type
sig {
params(hosted_confirmation: T.nilable(::Stripe::PaymentLinkService::CreateParams::AfterCompletion::HostedConfirmation), redirect: T.nilable(::Stripe::PaymentLinkService::CreateParams::AfterCompletion::Redirect), type: String).void
}
def initialize(hosted_confirmation: nil, redirect: nil, type: nil); end
end
class AutomaticTax < Stripe::RequestParams
class Liability < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# Set to `true` to [calculate tax automatically](https://docs.stripe.com/tax) using the customer's location.
#
# Enabling this parameter causes the payment link to collect any billing address information necessary for tax calculation.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
sig {
returns(T.nilable(::Stripe::PaymentLinkService::CreateParams::AutomaticTax::Liability))
}
attr_accessor :liability
sig {
params(enabled: T::Boolean, liability: T.nilable(::Stripe::PaymentLinkService::CreateParams::AutomaticTax::Liability)).void
}
def initialize(enabled: nil, liability: nil); end
end
class ConsentCollection < Stripe::RequestParams
class PaymentMethodReuseAgreement < Stripe::RequestParams
# Determines the position and visibility of the payment method reuse agreement in the UI. When set to `auto`, Stripe's
# defaults will be used. When set to `hidden`, the payment method reuse agreement text will always be hidden in the UI.
sig { returns(String) }
attr_accessor :position
sig { params(position: String).void }
def initialize(position: nil); end
end
# Determines the display of payment method reuse agreement text in the UI. If set to `hidden`, it will hide legal text related to the reuse of a payment method.
sig {
returns(T.nilable(::Stripe::PaymentLinkService::CreateParams::ConsentCollection::PaymentMethodReuseAgreement))
}
attr_accessor :payment_method_reuse_agreement
# If set to `auto`, enables the collection of customer consent for promotional communications. The Checkout
# Session will determine whether to display an option to opt into promotional communication
# from the merchant depending on the customer's locale. Only available to US merchants.
sig { returns(T.nilable(String)) }
attr_accessor :promotions
# If set to `required`, it requires customers to check a terms of service checkbox before being able to pay.
# There must be a valid terms of service URL set in your [Dashboard settings](https://dashboard.stripe.com/settings/public).
sig { returns(T.nilable(String)) }
attr_accessor :terms_of_service
sig {
params(payment_method_reuse_agreement: T.nilable(::Stripe::PaymentLinkService::CreateParams::ConsentCollection::PaymentMethodReuseAgreement), promotions: T.nilable(String), terms_of_service: T.nilable(String)).void
}
def initialize(
payment_method_reuse_agreement: nil,
promotions: nil,
terms_of_service: nil
); end
end
class CustomField < Stripe::RequestParams
class Dropdown < Stripe::RequestParams
class Option < Stripe::RequestParams
# The label for the option, displayed to the customer. Up to 100 characters.
sig { returns(String) }
attr_accessor :label
# The value for this option, not displayed to the customer, used by your integration to reconcile the option selected by the customer. Must be unique to this option, alphanumeric, and up to 100 characters.
sig { returns(String) }
attr_accessor :value
sig { params(label: String, value: String).void }
def initialize(label: nil, value: nil); end
end
# The value that will pre-fill the field on the payment page.Must match a `value` in the `options` array.
sig { returns(T.nilable(String)) }
attr_accessor :default_value
# The options available for the customer to select. Up to 200 options allowed.
sig {
returns(T::Array[::Stripe::PaymentLinkService::CreateParams::CustomField::Dropdown::Option])
}
attr_accessor :options
sig {
params(default_value: T.nilable(String), options: T::Array[::Stripe::PaymentLinkService::CreateParams::CustomField::Dropdown::Option]).void
}
def initialize(default_value: nil, options: nil); end
end
class Label < Stripe::RequestParams
# Custom text for the label, displayed to the customer. Up to 50 characters.
sig { returns(String) }
attr_accessor :custom
# The type of the label.
sig { returns(String) }
attr_accessor :type
sig { params(custom: String, type: String).void }
def initialize(custom: nil, type: nil); end
end
class Numeric < Stripe::RequestParams
# The value that will pre-fill the field on the payment page.
sig { returns(T.nilable(String)) }
attr_accessor :default_value
# The maximum character length constraint for the customer's input.
sig { returns(T.nilable(Integer)) }
attr_accessor :maximum_length
# The minimum character length requirement for the customer's input.
sig { returns(T.nilable(Integer)) }
attr_accessor :minimum_length
sig {
params(default_value: T.nilable(String), maximum_length: T.nilable(Integer), minimum_length: T.nilable(Integer)).void
}
def initialize(default_value: nil, maximum_length: nil, minimum_length: nil); end
end
class Text < Stripe::RequestParams
# The value that will pre-fill the field on the payment page.
sig { returns(T.nilable(String)) }
attr_accessor :default_value
# The maximum character length constraint for the customer's input.
sig { returns(T.nilable(Integer)) }
attr_accessor :maximum_length
# The minimum character length requirement for the customer's input.
sig { returns(T.nilable(Integer)) }
attr_accessor :minimum_length
sig {
params(default_value: T.nilable(String), maximum_length: T.nilable(Integer), minimum_length: T.nilable(Integer)).void
}
def initialize(default_value: nil, maximum_length: nil, minimum_length: nil); end
end
# Configuration for `type=dropdown` fields.
sig {
returns(T.nilable(::Stripe::PaymentLinkService::CreateParams::CustomField::Dropdown))
}
attr_accessor :dropdown
# String of your choice that your integration can use to reconcile this field. Must be unique to this field, alphanumeric, and up to 200 characters.
sig { returns(String) }
attr_accessor :key
# The label for the field, displayed to the customer.
sig { returns(::Stripe::PaymentLinkService::CreateParams::CustomField::Label) }
attr_accessor :label
# Configuration for `type=numeric` fields.
sig { returns(T.nilable(::Stripe::PaymentLinkService::CreateParams::CustomField::Numeric)) }
attr_accessor :numeric
# Whether the customer is required to complete the field before completing the Checkout Session. Defaults to `false`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :optional
# Configuration for `type=text` fields.
sig { returns(T.nilable(::Stripe::PaymentLinkService::CreateParams::CustomField::Text)) }
attr_accessor :text
# The type of the field.
sig { returns(String) }
attr_accessor :type
sig {
params(dropdown: T.nilable(::Stripe::PaymentLinkService::CreateParams::CustomField::Dropdown), key: String, label: ::Stripe::PaymentLinkService::CreateParams::CustomField::Label, numeric: T.nilable(::Stripe::PaymentLinkService::CreateParams::CustomField::Numeric), optional: T.nilable(T::Boolean), text: T.nilable(::Stripe::PaymentLinkService::CreateParams::CustomField::Text), type: String).void
}
def initialize(
dropdown: nil,
key: nil,
label: nil,
numeric: nil,
optional: nil,
text: nil,
type: nil
); end
end
class CustomText < Stripe::RequestParams
class AfterSubmit < Stripe::RequestParams
# Text may be up to 1200 characters in length.
sig { returns(String) }
attr_accessor :message
sig { params(message: String).void }
def initialize(message: nil); end
end
class ShippingAddress < Stripe::RequestParams
# Text may be up to 1200 characters in length.
sig { returns(String) }
attr_accessor :message
sig { params(message: String).void }
def initialize(message: nil); end
end
class Submit < Stripe::RequestParams
# Text may be up to 1200 characters in length.
sig { returns(String) }
attr_accessor :message
sig { params(message: String).void }
def initialize(message: nil); end
end
class TermsOfServiceAcceptance < Stripe::RequestParams
# Text may be up to 1200 characters in length.
sig { returns(String) }
attr_accessor :message
sig { params(message: String).void }
def initialize(message: nil); end
end
# Custom text that should be displayed after the payment confirmation button.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLinkService::CreateParams::CustomText::AfterSubmit))))
}
attr_accessor :after_submit
# Custom text that should be displayed alongside shipping address collection.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLinkService::CreateParams::CustomText::ShippingAddress))))
}
attr_accessor :shipping_address
# Custom text that should be displayed alongside the payment confirmation button.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLinkService::CreateParams::CustomText::Submit))))
}
attr_accessor :submit
# Custom text that should be displayed in place of the default terms of service agreement text.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLinkService::CreateParams::CustomText::TermsOfServiceAcceptance))))
}
attr_accessor :terms_of_service_acceptance
sig {
params(after_submit: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLinkService::CreateParams::CustomText::AfterSubmit))), shipping_address: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLinkService::CreateParams::CustomText::ShippingAddress))), submit: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLinkService::CreateParams::CustomText::Submit))), terms_of_service_acceptance: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLinkService::CreateParams::CustomText::TermsOfServiceAcceptance)))).void
}
def initialize(
after_submit: nil,
shipping_address: nil,
submit: nil,
terms_of_service_acceptance: nil
); end
end
class InvoiceCreation < Stripe::RequestParams
class InvoiceData < Stripe::RequestParams
class CustomField < Stripe::RequestParams
# The name of the custom field. This may be up to 40 characters.
sig { returns(String) }
attr_accessor :name
# The value of the custom field. This may be up to 140 characters.
sig { returns(String) }
attr_accessor :value
sig { params(name: String, value: String).void }
def initialize(name: nil, value: nil); end
end
class Issuer < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
class RenderingOptions < Stripe::RequestParams
# How line-item prices and amounts will be displayed with respect to tax on invoice PDFs. One of `exclude_tax` or `include_inclusive_tax`. `include_inclusive_tax` will include inclusive tax (and exclude exclusive tax) in invoice PDF amounts. `exclude_tax` will exclude all tax (inclusive and exclusive alike) from invoice PDF amounts.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :amount_tax_display
sig { params(amount_tax_display: T.nilable(T.nilable(T.any(String, String)))).void }
def initialize(amount_tax_display: nil); end
end
# The account tax IDs associated with the invoice.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :account_tax_ids
# Default custom fields to be displayed on invoices for this customer.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::PaymentLinkService::CreateParams::InvoiceCreation::InvoiceData::CustomField]))))
}
attr_accessor :custom_fields
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Default footer to be displayed on invoices for this customer.
sig { returns(T.nilable(String)) }
attr_accessor :footer
# The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
sig {
returns(T.nilable(::Stripe::PaymentLinkService::CreateParams::InvoiceCreation::InvoiceData::Issuer))
}
attr_accessor :issuer
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Default options for invoice PDF rendering for this customer.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLinkService::CreateParams::InvoiceCreation::InvoiceData::RenderingOptions))))
}
attr_accessor :rendering_options
sig {
params(account_tax_ids: T.nilable(T.nilable(T.any(String, T::Array[String]))), custom_fields: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::PaymentLinkService::CreateParams::InvoiceCreation::InvoiceData::CustomField]))), description: T.nilable(String), footer: T.nilable(String), issuer: T.nilable(::Stripe::PaymentLinkService::CreateParams::InvoiceCreation::InvoiceData::Issuer), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), rendering_options: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLinkService::CreateParams::InvoiceCreation::InvoiceData::RenderingOptions)))).void
}
def initialize(
account_tax_ids: nil,
custom_fields: nil,
description: nil,
footer: nil,
issuer: nil,
metadata: nil,
rendering_options: nil
); end
end
# Whether the feature is enabled
sig { returns(T::Boolean) }
attr_accessor :enabled
# Invoice PDF configuration.
sig {
returns(T.nilable(::Stripe::PaymentLinkService::CreateParams::InvoiceCreation::InvoiceData))
}
attr_accessor :invoice_data
sig {
params(enabled: T::Boolean, invoice_data: T.nilable(::Stripe::PaymentLinkService::CreateParams::InvoiceCreation::InvoiceData)).void
}
def initialize(enabled: nil, invoice_data: nil); end
end
class LineItem < Stripe::RequestParams
class AdjustableQuantity < Stripe::RequestParams
# Set to true if the quantity can be adjusted to any non-negative Integer.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The maximum quantity the customer can purchase. By default this value is 99. You can specify a value up to 999.
sig { returns(T.nilable(Integer)) }
attr_accessor :maximum
# The minimum quantity the customer can purchase. By default this value is 0. If there is only one item in the cart then that item's quantity cannot go down to 0.
sig { returns(T.nilable(Integer)) }
attr_accessor :minimum
sig {
params(enabled: T::Boolean, maximum: T.nilable(Integer), minimum: T.nilable(Integer)).void
}
def initialize(enabled: nil, maximum: nil, minimum: nil); end
end
# When set, provides configuration for this item’s quantity to be adjusted by the customer during checkout.
sig {
returns(T.nilable(::Stripe::PaymentLinkService::CreateParams::LineItem::AdjustableQuantity))
}
attr_accessor :adjustable_quantity
# The ID of the [Price](https://stripe.com/docs/api/prices) or [Plan](https://stripe.com/docs/api/plans) object.
sig { returns(String) }
attr_accessor :price
# The quantity of the line item being purchased.
sig { returns(Integer) }
attr_accessor :quantity
sig {
params(adjustable_quantity: T.nilable(::Stripe::PaymentLinkService::CreateParams::LineItem::AdjustableQuantity), price: String, quantity: Integer).void
}
def initialize(adjustable_quantity: nil, price: nil, quantity: nil); end
end
class OptionalItem < Stripe::RequestParams
class AdjustableQuantity < Stripe::RequestParams
# Set to true if the quantity can be adjusted to any non-negative integer.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The maximum quantity of this item the customer can purchase. By default this value is 99.
sig { returns(T.nilable(Integer)) }
attr_accessor :maximum
# The minimum quantity of this item the customer must purchase, if they choose to purchase it. Because this item is optional, the customer will always be able to remove it from their order, even if the `minimum` configured here is greater than 0. By default this value is 0.
sig { returns(T.nilable(Integer)) }
attr_accessor :minimum
sig {
params(enabled: T::Boolean, maximum: T.nilable(Integer), minimum: T.nilable(Integer)).void
}
def initialize(enabled: nil, maximum: nil, minimum: nil); end
end
# When set, provides configuration for the customer to adjust the quantity of the line item created when a customer chooses to add this optional item to their order.
sig {
returns(T.nilable(::Stripe::PaymentLinkService::CreateParams::OptionalItem::AdjustableQuantity))
}
attr_accessor :adjustable_quantity
# The ID of the [Price](https://stripe.com/docs/api/prices) or [Plan](https://stripe.com/docs/api/plans) object.
sig { returns(String) }
attr_accessor :price
# The initial quantity of the line item created when a customer chooses to add this optional item to their order.
sig { returns(Integer) }
attr_accessor :quantity
sig {
params(adjustable_quantity: T.nilable(::Stripe::PaymentLinkService::CreateParams::OptionalItem::AdjustableQuantity), price: String, quantity: Integer).void
}
def initialize(adjustable_quantity: nil, price: nil, quantity: nil); end
end
class PaymentIntentData < Stripe::RequestParams
# Controls when the funds will be captured from the customer's account.
sig { returns(T.nilable(String)) }
attr_accessor :capture_method
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Set of [key-value pairs](https://stripe.com/docs/api/metadata) that will declaratively set metadata on [Payment Intents](https://stripe.com/docs/api/payment_intents) generated from this payment link. Unlike object-level metadata, this field is declarative. Updates will clear prior values.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Indicates that you intend to [make future payments](https://stripe.com/docs/payments/payment-intents#future-usage) with the payment method collected by this Checkout Session.
#
# When setting this to `on_session`, Checkout will show a notice to the customer that their payment details will be saved.
#
# When setting this to `off_session`, Checkout will show a notice to the customer that their payment details will be saved and used for future payments.
#
# If a Customer has been provided or Checkout creates a new Customer,Checkout will attach the payment method to the Customer.
#
# If Checkout does not create a Customer, the payment method is not attached to a Customer. To reuse the payment method, you can retrieve it from the Checkout Session's PaymentIntent.
#
# When processing card payments, Checkout also uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as SCA.
sig { returns(T.nilable(String)) }
attr_accessor :setup_future_usage
# Text that appears on the customer's statement as the statement descriptor for a non-card charge. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
#
# Setting this value for a card charge returns an error. For card charges, set the [statement_descriptor_suffix](https://docs.stripe.com/get-started/account/statement-descriptors#dynamic) instead.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
# Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor_suffix
# A string that identifies the resulting payment as part of a group. See the PaymentIntents [use case for connected accounts](https://stripe.com/docs/connect/separate-charges-and-transfers) for details.
sig { returns(T.nilable(String)) }
attr_accessor :transfer_group
sig {
params(capture_method: T.nilable(String), description: T.nilable(String), metadata: T.nilable(T::Hash[String, String]), setup_future_usage: T.nilable(String), statement_descriptor: T.nilable(String), statement_descriptor_suffix: T.nilable(String), transfer_group: T.nilable(String)).void
}
def initialize(
capture_method: nil,
description: nil,
metadata: nil,
setup_future_usage: nil,
statement_descriptor: nil,
statement_descriptor_suffix: nil,
transfer_group: nil
); end
end
class PhoneNumberCollection < Stripe::RequestParams
# Set to `true` to enable phone number collection.
sig { returns(T::Boolean) }
attr_accessor :enabled
sig { params(enabled: T::Boolean).void }
def initialize(enabled: nil); end
end
class Restrictions < Stripe::RequestParams
class CompletedSessions < Stripe::RequestParams
# The maximum number of checkout sessions that can be completed for the `completed_sessions` restriction to be met.
sig { returns(Integer) }
attr_accessor :limit
sig { params(limit: Integer).void }
def initialize(limit: nil); end
end
# Configuration for the `completed_sessions` restriction type.
sig { returns(::Stripe::PaymentLinkService::CreateParams::Restrictions::CompletedSessions) }
attr_accessor :completed_sessions
sig {
params(completed_sessions: ::Stripe::PaymentLinkService::CreateParams::Restrictions::CompletedSessions).void
}
def initialize(completed_sessions: nil); end
end
class ShippingAddressCollection < Stripe::RequestParams
# An array of two-letter ISO country codes representing which countries Checkout should provide as options for
# shipping locations.
sig { returns(T::Array[String]) }
attr_accessor :allowed_countries
sig { params(allowed_countries: T::Array[String]).void }
def initialize(allowed_countries: nil); end
end
class ShippingOption < Stripe::RequestParams
# The ID of the Shipping Rate to use for this shipping option.
sig { returns(T.nilable(String)) }
attr_accessor :shipping_rate
sig { params(shipping_rate: T.nilable(String)).void }
def initialize(shipping_rate: nil); end
end
class SubscriptionData < Stripe::RequestParams
class InvoiceSettings < Stripe::RequestParams
class Issuer < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
sig {
returns(T.nilable(::Stripe::PaymentLinkService::CreateParams::SubscriptionData::InvoiceSettings::Issuer))
}
attr_accessor :issuer
sig {
params(issuer: T.nilable(::Stripe::PaymentLinkService::CreateParams::SubscriptionData::InvoiceSettings::Issuer)).void
}
def initialize(issuer: nil); end
end
class TrialSettings < Stripe::RequestParams
class EndBehavior < Stripe::RequestParams
# Indicates how the subscription should change when the trial ends if the user did not provide a payment method.
sig { returns(String) }
attr_accessor :missing_payment_method
sig { params(missing_payment_method: String).void }
def initialize(missing_payment_method: nil); end
end
# Defines how the subscription should behave when the user's free trial ends.
sig {
returns(::Stripe::PaymentLinkService::CreateParams::SubscriptionData::TrialSettings::EndBehavior)
}
attr_accessor :end_behavior
sig {
params(end_behavior: ::Stripe::PaymentLinkService::CreateParams::SubscriptionData::TrialSettings::EndBehavior).void
}
def initialize(end_behavior: nil); end
end
# The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
sig { returns(T.nilable(String)) }
attr_accessor :description
# All invoices will be billed using the specified settings.
sig {
returns(T.nilable(::Stripe::PaymentLinkService::CreateParams::SubscriptionData::InvoiceSettings))
}
attr_accessor :invoice_settings
# Set of [key-value pairs](https://stripe.com/docs/api/metadata) that will declaratively set metadata on [Subscriptions](https://stripe.com/docs/api/subscriptions) generated from this payment link. Unlike object-level metadata, this field is declarative. Updates will clear prior values.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Integer representing the number of trial period days before the customer is charged for the first time. Has to be at least 1.
sig { returns(T.nilable(Integer)) }
attr_accessor :trial_period_days
# Settings related to subscription trials.
sig {
returns(T.nilable(::Stripe::PaymentLinkService::CreateParams::SubscriptionData::TrialSettings))
}
attr_accessor :trial_settings
sig {
params(description: T.nilable(String), invoice_settings: T.nilable(::Stripe::PaymentLinkService::CreateParams::SubscriptionData::InvoiceSettings), metadata: T.nilable(T::Hash[String, String]), trial_period_days: T.nilable(Integer), trial_settings: T.nilable(::Stripe::PaymentLinkService::CreateParams::SubscriptionData::TrialSettings)).void
}
def initialize(
description: nil,
invoice_settings: nil,
metadata: nil,
trial_period_days: nil,
trial_settings: nil
); end
end
class TaxIdCollection < Stripe::RequestParams
# Enable tax ID collection during checkout. Defaults to `false`.
sig { returns(T::Boolean) }
attr_accessor :enabled
# Describes whether a tax ID is required during checkout. Defaults to `never`.
sig { returns(T.nilable(String)) }
attr_accessor :required
sig { params(enabled: T::Boolean, required: T.nilable(String)).void }
def initialize(enabled: nil, required: nil); end
end
class TransferData < Stripe::RequestParams
# The amount that will be transferred automatically when a charge succeeds.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# If specified, successful charges will be attributed to the destination
# account for tax reporting, and the funds from charges will be transferred
# to the destination account. The ID of the resulting transfer will be
# returned on the successful charge's `transfer` field.
sig { returns(String) }
attr_accessor :destination
sig { params(amount: T.nilable(Integer), destination: String).void }
def initialize(amount: nil, destination: nil); end
end
# Behavior after the purchase is complete.
sig { returns(T.nilable(::Stripe::PaymentLinkService::CreateParams::AfterCompletion)) }
attr_accessor :after_completion
# Enables user redeemable promotion codes.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :allow_promotion_codes
# The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. Can only be applied when there are no line items with recurring prices.
sig { returns(T.nilable(Integer)) }
attr_accessor :application_fee_amount
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. There must be at least 1 line item with a recurring price to use this field.
sig { returns(T.nilable(Float)) }
attr_accessor :application_fee_percent
# Configuration for automatic tax collection.
sig { returns(T.nilable(::Stripe::PaymentLinkService::CreateParams::AutomaticTax)) }
attr_accessor :automatic_tax
# Configuration for collecting the customer's billing address. Defaults to `auto`.
sig { returns(T.nilable(String)) }
attr_accessor :billing_address_collection
# Configure fields to gather active consent from customers.
sig { returns(T.nilable(::Stripe::PaymentLinkService::CreateParams::ConsentCollection)) }
attr_accessor :consent_collection
# 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) and supported by each line item's price.
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Collect additional information from your customer using custom fields. Up to 3 fields are supported.
sig { returns(T.nilable(T::Array[::Stripe::PaymentLinkService::CreateParams::CustomField])) }
attr_accessor :custom_fields
# Display additional text for your customers using custom text.
sig { returns(T.nilable(::Stripe::PaymentLinkService::CreateParams::CustomText)) }
attr_accessor :custom_text
# Configures whether [checkout sessions](https://stripe.com/docs/api/checkout/sessions) created by this payment link create a [Customer](https://stripe.com/docs/api/customers).
sig { returns(T.nilable(String)) }
attr_accessor :customer_creation
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The custom message to be displayed to a customer when a payment link is no longer active.
sig { returns(T.nilable(String)) }
attr_accessor :inactive_message
# Generate a post-purchase Invoice for one-time payments.
sig { returns(T.nilable(::Stripe::PaymentLinkService::CreateParams::InvoiceCreation)) }
attr_accessor :invoice_creation
# The line items representing what is being sold. Each line item represents an item being sold. Up to 20 line items are supported.
sig { returns(T::Array[::Stripe::PaymentLinkService::CreateParams::LineItem]) }
attr_accessor :line_items
# 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 associated with this Payment Link will automatically be copied to [checkout sessions](https://stripe.com/docs/api/checkout/sessions) created by this payment link.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The account on behalf of which to charge.
sig { returns(T.nilable(String)) }
attr_accessor :on_behalf_of
# A list of optional items the customer can add to their order at checkout. Use this parameter to pass one-time or recurring [Prices](https://stripe.com/docs/api/prices).
# There is a maximum of 10 optional items allowed on a payment link, and the existing limits on the number of line items allowed on a payment link apply to the combined number of line items and optional items.
# There is a maximum of 20 combined line items and optional items.
sig { returns(T.nilable(T::Array[::Stripe::PaymentLinkService::CreateParams::OptionalItem])) }
attr_accessor :optional_items
# A subset of parameters to be passed to PaymentIntent creation for Checkout Sessions in `payment` mode.
sig { returns(T.nilable(::Stripe::PaymentLinkService::CreateParams::PaymentIntentData)) }
attr_accessor :payment_intent_data
# Specify whether Checkout should collect a payment method. When set to `if_required`, Checkout will not collect a payment method when the total due for the session is 0.This may occur if the Checkout Session includes a free trial or a discount.
#
# Can only be set in `subscription` mode. Defaults to `always`.
#
# If you'd like information on how to collect a payment method outside of Checkout, read the guide on [configuring subscriptions with a free trial](https://stripe.com/docs/payments/checkout/free-trials).
sig { returns(T.nilable(String)) }
attr_accessor :payment_method_collection
# The list of payment method types that customers can use. If no value is passed, Stripe will dynamically show relevant payment methods from your [payment method settings](https://dashboard.stripe.com/settings/payment_methods) (20+ payment methods [supported](https://stripe.com/docs/payments/payment-methods/integration-options#payment-method-product-support)).
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :payment_method_types
# Controls phone number collection settings during checkout.
#
# We recommend that you review your privacy policy and check with your legal contacts.
sig { returns(T.nilable(::Stripe::PaymentLinkService::CreateParams::PhoneNumberCollection)) }
attr_accessor :phone_number_collection
# Settings that restrict the usage of a payment link.
sig { returns(T.nilable(::Stripe::PaymentLinkService::CreateParams::Restrictions)) }
attr_accessor :restrictions
# Configuration for collecting the customer's shipping address.
sig {
returns(T.nilable(::Stripe::PaymentLinkService::CreateParams::ShippingAddressCollection))
}
attr_accessor :shipping_address_collection
# The shipping rate options to apply to [checkout sessions](https://stripe.com/docs/api/checkout/sessions) created by this payment link.
sig {
returns(T.nilable(T::Array[::Stripe::PaymentLinkService::CreateParams::ShippingOption]))
}
attr_accessor :shipping_options
# Describes the type of transaction being performed in order to customize relevant text on the page, such as the submit button. Changing this value will also affect the hostname in the [url](https://stripe.com/docs/api/payment_links/payment_links/object#url) property (example: `donate.stripe.com`).
sig { returns(T.nilable(String)) }
attr_accessor :submit_type
# When creating a subscription, the specified configuration data will be used. There must be at least one line item with a recurring price to use `subscription_data`.
sig { returns(T.nilable(::Stripe::PaymentLinkService::CreateParams::SubscriptionData)) }
attr_accessor :subscription_data
# Controls tax ID collection during checkout.
sig { returns(T.nilable(::Stripe::PaymentLinkService::CreateParams::TaxIdCollection)) }
attr_accessor :tax_id_collection
# The account (if any) the payments will be attributed to for tax reporting, and where funds from each payment will be transferred to.
sig { returns(T.nilable(::Stripe::PaymentLinkService::CreateParams::TransferData)) }
attr_accessor :transfer_data
sig {
params(after_completion: T.nilable(::Stripe::PaymentLinkService::CreateParams::AfterCompletion), allow_promotion_codes: T.nilable(T::Boolean), application_fee_amount: T.nilable(Integer), application_fee_percent: T.nilable(Float), automatic_tax: T.nilable(::Stripe::PaymentLinkService::CreateParams::AutomaticTax), billing_address_collection: T.nilable(String), consent_collection: T.nilable(::Stripe::PaymentLinkService::CreateParams::ConsentCollection), currency: T.nilable(String), custom_fields: T.nilable(T::Array[::Stripe::PaymentLinkService::CreateParams::CustomField]), custom_text: T.nilable(::Stripe::PaymentLinkService::CreateParams::CustomText), customer_creation: T.nilable(String), expand: T.nilable(T::Array[String]), inactive_message: T.nilable(String), invoice_creation: T.nilable(::Stripe::PaymentLinkService::CreateParams::InvoiceCreation), line_items: T::Array[::Stripe::PaymentLinkService::CreateParams::LineItem], metadata: T.nilable(T::Hash[String, String]), on_behalf_of: T.nilable(String), optional_items: T.nilable(T::Array[::Stripe::PaymentLinkService::CreateParams::OptionalItem]), payment_intent_data: T.nilable(::Stripe::PaymentLinkService::CreateParams::PaymentIntentData), payment_method_collection: T.nilable(String), payment_method_types: T.nilable(T::Array[String]), phone_number_collection: T.nilable(::Stripe::PaymentLinkService::CreateParams::PhoneNumberCollection), restrictions: T.nilable(::Stripe::PaymentLinkService::CreateParams::Restrictions), shipping_address_collection: T.nilable(::Stripe::PaymentLinkService::CreateParams::ShippingAddressCollection), shipping_options: T.nilable(T::Array[::Stripe::PaymentLinkService::CreateParams::ShippingOption]), submit_type: T.nilable(String), subscription_data: T.nilable(::Stripe::PaymentLinkService::CreateParams::SubscriptionData), tax_id_collection: T.nilable(::Stripe::PaymentLinkService::CreateParams::TaxIdCollection), transfer_data: T.nilable(::Stripe::PaymentLinkService::CreateParams::TransferData)).void
}
def initialize(
after_completion: nil,
allow_promotion_codes: nil,
application_fee_amount: nil,
application_fee_percent: nil,
automatic_tax: nil,
billing_address_collection: nil,
consent_collection: nil,
currency: nil,
custom_fields: nil,
custom_text: nil,
customer_creation: nil,
expand: nil,
inactive_message: nil,
invoice_creation: nil,
line_items: nil,
metadata: nil,
on_behalf_of: nil,
optional_items: nil,
payment_intent_data: nil,
payment_method_collection: nil,
payment_method_types: nil,
phone_number_collection: nil,
restrictions: nil,
shipping_address_collection: nil,
shipping_options: nil,
submit_type: nil,
subscription_data: nil,
tax_id_collection: nil,
transfer_data: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
class AfterCompletion < Stripe::RequestParams
class HostedConfirmation < Stripe::RequestParams
# A custom message to display to the customer after the purchase is complete.
sig { returns(T.nilable(String)) }
attr_accessor :custom_message
sig { params(custom_message: T.nilable(String)).void }
def initialize(custom_message: nil); end
end
class Redirect < Stripe::RequestParams
# The URL the customer will be redirected to after the purchase is complete. You can embed `{CHECKOUT_SESSION_ID}` into the URL to have the `id` of the completed [checkout session](https://stripe.com/docs/api/checkout/sessions/object#checkout_session_object-id) included.
sig { returns(String) }
attr_accessor :url
sig { params(url: String).void }
def initialize(url: nil); end
end
# Configuration when `type=hosted_confirmation`.
sig {
returns(T.nilable(::Stripe::PaymentLinkService::UpdateParams::AfterCompletion::HostedConfirmation))
}
attr_accessor :hosted_confirmation
# Configuration when `type=redirect`.
sig {
returns(T.nilable(::Stripe::PaymentLinkService::UpdateParams::AfterCompletion::Redirect))
}
attr_accessor :redirect
# The specified behavior after the purchase is complete. Either `redirect` or `hosted_confirmation`.
sig { returns(String) }
attr_accessor :type
sig {
params(hosted_confirmation: T.nilable(::Stripe::PaymentLinkService::UpdateParams::AfterCompletion::HostedConfirmation), redirect: T.nilable(::Stripe::PaymentLinkService::UpdateParams::AfterCompletion::Redirect), type: String).void
}
def initialize(hosted_confirmation: nil, redirect: nil, type: nil); end
end
class AutomaticTax < Stripe::RequestParams
class Liability < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# Set to `true` to [calculate tax automatically](https://docs.stripe.com/tax) using the customer's location.
#
# Enabling this parameter causes the payment link to collect any billing address information necessary for tax calculation.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
sig {
returns(T.nilable(::Stripe::PaymentLinkService::UpdateParams::AutomaticTax::Liability))
}
attr_accessor :liability
sig {
params(enabled: T::Boolean, liability: T.nilable(::Stripe::PaymentLinkService::UpdateParams::AutomaticTax::Liability)).void
}
def initialize(enabled: nil, liability: nil); end
end
class CustomField < Stripe::RequestParams
class Dropdown < Stripe::RequestParams
class Option < Stripe::RequestParams
# The label for the option, displayed to the customer. Up to 100 characters.
sig { returns(String) }
attr_accessor :label
# The value for this option, not displayed to the customer, used by your integration to reconcile the option selected by the customer. Must be unique to this option, alphanumeric, and up to 100 characters.
sig { returns(String) }
attr_accessor :value
sig { params(label: String, value: String).void }
def initialize(label: nil, value: nil); end
end
# The value that will pre-fill the field on the payment page.Must match a `value` in the `options` array.
sig { returns(T.nilable(String)) }
attr_accessor :default_value
# The options available for the customer to select. Up to 200 options allowed.
sig {
returns(T::Array[::Stripe::PaymentLinkService::UpdateParams::CustomField::Dropdown::Option])
}
attr_accessor :options
sig {
params(default_value: T.nilable(String), options: T::Array[::Stripe::PaymentLinkService::UpdateParams::CustomField::Dropdown::Option]).void
}
def initialize(default_value: nil, options: nil); end
end
class Label < Stripe::RequestParams
# Custom text for the label, displayed to the customer. Up to 50 characters.
sig { returns(String) }
attr_accessor :custom
# The type of the label.
sig { returns(String) }
attr_accessor :type
sig { params(custom: String, type: String).void }
def initialize(custom: nil, type: nil); end
end
class Numeric < Stripe::RequestParams
# The value that will pre-fill the field on the payment page.
sig { returns(T.nilable(String)) }
attr_accessor :default_value
# The maximum character length constraint for the customer's input.
sig { returns(T.nilable(Integer)) }
attr_accessor :maximum_length
# The minimum character length requirement for the customer's input.
sig { returns(T.nilable(Integer)) }
attr_accessor :minimum_length
sig {
params(default_value: T.nilable(String), maximum_length: T.nilable(Integer), minimum_length: T.nilable(Integer)).void
}
def initialize(default_value: nil, maximum_length: nil, minimum_length: nil); end
end
class Text < Stripe::RequestParams
# The value that will pre-fill the field on the payment page.
sig { returns(T.nilable(String)) }
attr_accessor :default_value
# The maximum character length constraint for the customer's input.
sig { returns(T.nilable(Integer)) }
attr_accessor :maximum_length
# The minimum character length requirement for the customer's input.
sig { returns(T.nilable(Integer)) }
attr_accessor :minimum_length
sig {
params(default_value: T.nilable(String), maximum_length: T.nilable(Integer), minimum_length: T.nilable(Integer)).void
}
def initialize(default_value: nil, maximum_length: nil, minimum_length: nil); end
end
# Configuration for `type=dropdown` fields.
sig {
returns(T.nilable(::Stripe::PaymentLinkService::UpdateParams::CustomField::Dropdown))
}
attr_accessor :dropdown
# String of your choice that your integration can use to reconcile this field. Must be unique to this field, alphanumeric, and up to 200 characters.
sig { returns(String) }
attr_accessor :key
# The label for the field, displayed to the customer.
sig { returns(::Stripe::PaymentLinkService::UpdateParams::CustomField::Label) }
attr_accessor :label
# Configuration for `type=numeric` fields.
sig { returns(T.nilable(::Stripe::PaymentLinkService::UpdateParams::CustomField::Numeric)) }
attr_accessor :numeric
# Whether the customer is required to complete the field before completing the Checkout Session. Defaults to `false`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :optional
# Configuration for `type=text` fields.
sig { returns(T.nilable(::Stripe::PaymentLinkService::UpdateParams::CustomField::Text)) }
attr_accessor :text
# The type of the field.
sig { returns(String) }
attr_accessor :type
sig {
params(dropdown: T.nilable(::Stripe::PaymentLinkService::UpdateParams::CustomField::Dropdown), key: String, label: ::Stripe::PaymentLinkService::UpdateParams::CustomField::Label, numeric: T.nilable(::Stripe::PaymentLinkService::UpdateParams::CustomField::Numeric), optional: T.nilable(T::Boolean), text: T.nilable(::Stripe::PaymentLinkService::UpdateParams::CustomField::Text), type: String).void
}
def initialize(
dropdown: nil,
key: nil,
label: nil,
numeric: nil,
optional: nil,
text: nil,
type: nil
); end
end
class CustomText < Stripe::RequestParams
class AfterSubmit < Stripe::RequestParams
# Text may be up to 1200 characters in length.
sig { returns(String) }
attr_accessor :message
sig { params(message: String).void }
def initialize(message: nil); end
end
class ShippingAddress < Stripe::RequestParams
# Text may be up to 1200 characters in length.
sig { returns(String) }
attr_accessor :message
sig { params(message: String).void }
def initialize(message: nil); end
end
class Submit < Stripe::RequestParams
# Text may be up to 1200 characters in length.
sig { returns(String) }
attr_accessor :message
sig { params(message: String).void }
def initialize(message: nil); end
end
class TermsOfServiceAcceptance < Stripe::RequestParams
# Text may be up to 1200 characters in length.
sig { returns(String) }
attr_accessor :message
sig { params(message: String).void }
def initialize(message: nil); end
end
# Custom text that should be displayed after the payment confirmation button.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLinkService::UpdateParams::CustomText::AfterSubmit))))
}
attr_accessor :after_submit
# Custom text that should be displayed alongside shipping address collection.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLinkService::UpdateParams::CustomText::ShippingAddress))))
}
attr_accessor :shipping_address
# Custom text that should be displayed alongside the payment confirmation button.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLinkService::UpdateParams::CustomText::Submit))))
}
attr_accessor :submit
# Custom text that should be displayed in place of the default terms of service agreement text.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLinkService::UpdateParams::CustomText::TermsOfServiceAcceptance))))
}
attr_accessor :terms_of_service_acceptance
sig {
params(after_submit: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLinkService::UpdateParams::CustomText::AfterSubmit))), shipping_address: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLinkService::UpdateParams::CustomText::ShippingAddress))), submit: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLinkService::UpdateParams::CustomText::Submit))), terms_of_service_acceptance: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLinkService::UpdateParams::CustomText::TermsOfServiceAcceptance)))).void
}
def initialize(
after_submit: nil,
shipping_address: nil,
submit: nil,
terms_of_service_acceptance: nil
); end
end
class InvoiceCreation < Stripe::RequestParams
class InvoiceData < Stripe::RequestParams
class CustomField < Stripe::RequestParams
# The name of the custom field. This may be up to 40 characters.
sig { returns(String) }
attr_accessor :name
# The value of the custom field. This may be up to 140 characters.
sig { returns(String) }
attr_accessor :value
sig { params(name: String, value: String).void }
def initialize(name: nil, value: nil); end
end
class Issuer < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
class RenderingOptions < Stripe::RequestParams
# How line-item prices and amounts will be displayed with respect to tax on invoice PDFs. One of `exclude_tax` or `include_inclusive_tax`. `include_inclusive_tax` will include inclusive tax (and exclude exclusive tax) in invoice PDF amounts. `exclude_tax` will exclude all tax (inclusive and exclusive alike) from invoice PDF amounts.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :amount_tax_display
sig { params(amount_tax_display: T.nilable(T.nilable(T.any(String, String)))).void }
def initialize(amount_tax_display: nil); end
end
# The account tax IDs associated with the invoice.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :account_tax_ids
# Default custom fields to be displayed on invoices for this customer.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::PaymentLinkService::UpdateParams::InvoiceCreation::InvoiceData::CustomField]))))
}
attr_accessor :custom_fields
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Default footer to be displayed on invoices for this customer.
sig { returns(T.nilable(String)) }
attr_accessor :footer
# The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
sig {
returns(T.nilable(::Stripe::PaymentLinkService::UpdateParams::InvoiceCreation::InvoiceData::Issuer))
}
attr_accessor :issuer
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Default options for invoice PDF rendering for this customer.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLinkService::UpdateParams::InvoiceCreation::InvoiceData::RenderingOptions))))
}
attr_accessor :rendering_options
sig {
params(account_tax_ids: T.nilable(T.nilable(T.any(String, T::Array[String]))), custom_fields: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::PaymentLinkService::UpdateParams::InvoiceCreation::InvoiceData::CustomField]))), description: T.nilable(String), footer: T.nilable(String), issuer: T.nilable(::Stripe::PaymentLinkService::UpdateParams::InvoiceCreation::InvoiceData::Issuer), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), rendering_options: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLinkService::UpdateParams::InvoiceCreation::InvoiceData::RenderingOptions)))).void
}
def initialize(
account_tax_ids: nil,
custom_fields: nil,
description: nil,
footer: nil,
issuer: nil,
metadata: nil,
rendering_options: nil
); end
end
# Whether the feature is enabled
sig { returns(T::Boolean) }
attr_accessor :enabled
# Invoice PDF configuration.
sig {
returns(T.nilable(::Stripe::PaymentLinkService::UpdateParams::InvoiceCreation::InvoiceData))
}
attr_accessor :invoice_data
sig {
params(enabled: T::Boolean, invoice_data: T.nilable(::Stripe::PaymentLinkService::UpdateParams::InvoiceCreation::InvoiceData)).void
}
def initialize(enabled: nil, invoice_data: nil); end
end
class LineItem < Stripe::RequestParams
class AdjustableQuantity < Stripe::RequestParams
# Set to true if the quantity can be adjusted to any non-negative Integer.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The maximum quantity the customer can purchase. By default this value is 99. You can specify a value up to 999.
sig { returns(T.nilable(Integer)) }
attr_accessor :maximum
# The minimum quantity the customer can purchase. By default this value is 0. If there is only one item in the cart then that item's quantity cannot go down to 0.
sig { returns(T.nilable(Integer)) }
attr_accessor :minimum
sig {
params(enabled: T::Boolean, maximum: T.nilable(Integer), minimum: T.nilable(Integer)).void
}
def initialize(enabled: nil, maximum: nil, minimum: nil); end
end
# When set, provides configuration for this item’s quantity to be adjusted by the customer during checkout.
sig {
returns(T.nilable(::Stripe::PaymentLinkService::UpdateParams::LineItem::AdjustableQuantity))
}
attr_accessor :adjustable_quantity
# The ID of an existing line item on the payment link.
sig { returns(String) }
attr_accessor :id
# The quantity of the line item being purchased.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
sig {
params(adjustable_quantity: T.nilable(::Stripe::PaymentLinkService::UpdateParams::LineItem::AdjustableQuantity), id: String, quantity: T.nilable(Integer)).void
}
def initialize(adjustable_quantity: nil, id: nil, quantity: nil); end
end
class PaymentIntentData < Stripe::RequestParams
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :description
# Set of [key-value pairs](https://stripe.com/docs/api/metadata) that will declaratively set metadata on [Payment Intents](https://stripe.com/docs/api/payment_intents) generated from this payment link. Unlike object-level metadata, this field is declarative. Updates will clear prior values.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Text that appears on the customer's statement as the statement descriptor for a non-card charge. This value overrides the account's default statement descriptor. For information about requirements, including the 22-character limit, see [the Statement Descriptor docs](https://docs.stripe.com/get-started/account/statement-descriptors).
#
# Setting this value for a card charge returns an error. For card charges, set the [statement_descriptor_suffix](https://docs.stripe.com/get-started/account/statement-descriptors#dynamic) instead.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :statement_descriptor
# Provides information about a card charge. Concatenated to the account's [statement descriptor prefix](https://docs.stripe.com/get-started/account/statement-descriptors#static) to form the complete statement descriptor that appears on the customer's statement.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :statement_descriptor_suffix
# A string that identifies the resulting payment as part of a group. See the PaymentIntents [use case for connected accounts](https://stripe.com/docs/connect/separate-charges-and-transfers) for details.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :transfer_group
sig {
params(description: T.nilable(T.nilable(String)), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), statement_descriptor: T.nilable(T.nilable(String)), statement_descriptor_suffix: T.nilable(T.nilable(String)), transfer_group: T.nilable(T.nilable(String))).void
}
def initialize(
description: nil,
metadata: nil,
statement_descriptor: nil,
statement_descriptor_suffix: nil,
transfer_group: nil
); end
end
class PhoneNumberCollection < Stripe::RequestParams
# Set to `true` to enable phone number collection.
sig { returns(T::Boolean) }
attr_accessor :enabled
sig { params(enabled: T::Boolean).void }
def initialize(enabled: nil); end
end
class Restrictions < Stripe::RequestParams
class CompletedSessions < Stripe::RequestParams
# The maximum number of checkout sessions that can be completed for the `completed_sessions` restriction to be met.
sig { returns(Integer) }
attr_accessor :limit
sig { params(limit: Integer).void }
def initialize(limit: nil); end
end
# Configuration for the `completed_sessions` restriction type.
sig { returns(::Stripe::PaymentLinkService::UpdateParams::Restrictions::CompletedSessions) }
attr_accessor :completed_sessions
sig {
params(completed_sessions: ::Stripe::PaymentLinkService::UpdateParams::Restrictions::CompletedSessions).void
}
def initialize(completed_sessions: nil); end
end
class ShippingAddressCollection < Stripe::RequestParams
# An array of two-letter ISO country codes representing which countries Checkout should provide as options for
# shipping locations.
sig { returns(T::Array[String]) }
attr_accessor :allowed_countries
sig { params(allowed_countries: T::Array[String]).void }
def initialize(allowed_countries: nil); end
end
class SubscriptionData < Stripe::RequestParams
class InvoiceSettings < Stripe::RequestParams
class Issuer < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
sig {
returns(T.nilable(::Stripe::PaymentLinkService::UpdateParams::SubscriptionData::InvoiceSettings::Issuer))
}
attr_accessor :issuer
sig {
params(issuer: T.nilable(::Stripe::PaymentLinkService::UpdateParams::SubscriptionData::InvoiceSettings::Issuer)).void
}
def initialize(issuer: nil); end
end
class TrialSettings < Stripe::RequestParams
class EndBehavior < Stripe::RequestParams
# Indicates how the subscription should change when the trial ends if the user did not provide a payment method.
sig { returns(String) }
attr_accessor :missing_payment_method
sig { params(missing_payment_method: String).void }
def initialize(missing_payment_method: nil); end
end
# Defines how the subscription should behave when the user's free trial ends.
sig {
returns(::Stripe::PaymentLinkService::UpdateParams::SubscriptionData::TrialSettings::EndBehavior)
}
attr_accessor :end_behavior
sig {
params(end_behavior: ::Stripe::PaymentLinkService::UpdateParams::SubscriptionData::TrialSettings::EndBehavior).void
}
def initialize(end_behavior: nil); end
end
# All invoices will be billed using the specified settings.
sig {
returns(T.nilable(::Stripe::PaymentLinkService::UpdateParams::SubscriptionData::InvoiceSettings))
}
attr_accessor :invoice_settings
# Set of [key-value pairs](https://stripe.com/docs/api/metadata) that will declaratively set metadata on [Subscriptions](https://stripe.com/docs/api/subscriptions) generated from this payment link. Unlike object-level metadata, this field is declarative. Updates will clear prior values.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Integer representing the number of trial period days before the customer is charged for the first time. Has to be at least 1.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :trial_period_days
# Settings related to subscription trials.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLinkService::UpdateParams::SubscriptionData::TrialSettings))))
}
attr_accessor :trial_settings
sig {
params(invoice_settings: T.nilable(::Stripe::PaymentLinkService::UpdateParams::SubscriptionData::InvoiceSettings), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), trial_period_days: T.nilable(T.nilable(T.any(String, Integer))), trial_settings: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLinkService::UpdateParams::SubscriptionData::TrialSettings)))).void
}
def initialize(
invoice_settings: nil,
metadata: nil,
trial_period_days: nil,
trial_settings: nil
); end
end
class TaxIdCollection < Stripe::RequestParams
# Enable tax ID collection during checkout. Defaults to `false`.
sig { returns(T::Boolean) }
attr_accessor :enabled
# Describes whether a tax ID is required during checkout. Defaults to `never`.
sig { returns(T.nilable(String)) }
attr_accessor :required
sig { params(enabled: T::Boolean, required: T.nilable(String)).void }
def initialize(enabled: nil, required: nil); end
end
# Whether the payment link's `url` is active. If `false`, customers visiting the URL will be shown a page saying that the link has been deactivated.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# Behavior after the purchase is complete.
sig { returns(T.nilable(::Stripe::PaymentLinkService::UpdateParams::AfterCompletion)) }
attr_accessor :after_completion
# Enables user redeemable promotion codes.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :allow_promotion_codes
# Configuration for automatic tax collection.
sig { returns(T.nilable(::Stripe::PaymentLinkService::UpdateParams::AutomaticTax)) }
attr_accessor :automatic_tax
# Configuration for collecting the customer's billing address. Defaults to `auto`.
sig { returns(T.nilable(String)) }
attr_accessor :billing_address_collection
# Collect additional information from your customer using custom fields. Up to 3 fields are supported.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::PaymentLinkService::UpdateParams::CustomField]))))
}
attr_accessor :custom_fields
# Display additional text for your customers using custom text.
sig { returns(T.nilable(::Stripe::PaymentLinkService::UpdateParams::CustomText)) }
attr_accessor :custom_text
# Configures whether [checkout sessions](https://stripe.com/docs/api/checkout/sessions) created by this payment link create a [Customer](https://stripe.com/docs/api/customers).
sig { returns(T.nilable(String)) }
attr_accessor :customer_creation
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The custom message to be displayed to a customer when a payment link is no longer active.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :inactive_message
# Generate a post-purchase Invoice for one-time payments.
sig { returns(T.nilable(::Stripe::PaymentLinkService::UpdateParams::InvoiceCreation)) }
attr_accessor :invoice_creation
# The line items representing what is being sold. Each line item represents an item being sold. Up to 20 line items are supported.
sig { returns(T.nilable(T::Array[::Stripe::PaymentLinkService::UpdateParams::LineItem])) }
attr_accessor :line_items
# 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 associated with this Payment Link will automatically be copied to [checkout sessions](https://stripe.com/docs/api/checkout/sessions) created by this payment link.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# A subset of parameters to be passed to PaymentIntent creation for Checkout Sessions in `payment` mode.
sig { returns(T.nilable(::Stripe::PaymentLinkService::UpdateParams::PaymentIntentData)) }
attr_accessor :payment_intent_data
# Specify whether Checkout should collect a payment method. When set to `if_required`, Checkout will not collect a payment method when the total due for the session is 0.This may occur if the Checkout Session includes a free trial or a discount.
#
# Can only be set in `subscription` mode. Defaults to `always`.
#
# If you'd like information on how to collect a payment method outside of Checkout, read the guide on [configuring subscriptions with a free trial](https://stripe.com/docs/payments/checkout/free-trials).
sig { returns(T.nilable(String)) }
attr_accessor :payment_method_collection
# The list of payment method types that customers can use. Pass an empty string to enable dynamic payment methods that use your [payment method settings](https://dashboard.stripe.com/settings/payment_methods).
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :payment_method_types
# Controls phone number collection settings during checkout.
#
# We recommend that you review your privacy policy and check with your legal contacts.
sig { returns(T.nilable(::Stripe::PaymentLinkService::UpdateParams::PhoneNumberCollection)) }
attr_accessor :phone_number_collection
# Settings that restrict the usage of a payment link.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLinkService::UpdateParams::Restrictions))))
}
attr_accessor :restrictions
# Configuration for collecting the customer's shipping address.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLinkService::UpdateParams::ShippingAddressCollection))))
}
attr_accessor :shipping_address_collection
# Describes the type of transaction being performed in order to customize relevant text on the page, such as the submit button. Changing this value will also affect the hostname in the [url](https://stripe.com/docs/api/payment_links/payment_links/object#url) property (example: `donate.stripe.com`).
sig { returns(T.nilable(String)) }
attr_accessor :submit_type
# When creating a subscription, the specified configuration data will be used. There must be at least one line item with a recurring price to use `subscription_data`.
sig { returns(T.nilable(::Stripe::PaymentLinkService::UpdateParams::SubscriptionData)) }
attr_accessor :subscription_data
# Controls tax ID collection during checkout.
sig { returns(T.nilable(::Stripe::PaymentLinkService::UpdateParams::TaxIdCollection)) }
attr_accessor :tax_id_collection
sig {
params(active: T.nilable(T::Boolean), after_completion: T.nilable(::Stripe::PaymentLinkService::UpdateParams::AfterCompletion), allow_promotion_codes: T.nilable(T::Boolean), automatic_tax: T.nilable(::Stripe::PaymentLinkService::UpdateParams::AutomaticTax), billing_address_collection: T.nilable(String), custom_fields: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::PaymentLinkService::UpdateParams::CustomField]))), custom_text: T.nilable(::Stripe::PaymentLinkService::UpdateParams::CustomText), customer_creation: T.nilable(String), expand: T.nilable(T::Array[String]), inactive_message: T.nilable(T.nilable(String)), invoice_creation: T.nilable(::Stripe::PaymentLinkService::UpdateParams::InvoiceCreation), line_items: T.nilable(T::Array[::Stripe::PaymentLinkService::UpdateParams::LineItem]), metadata: T.nilable(T::Hash[String, String]), payment_intent_data: T.nilable(::Stripe::PaymentLinkService::UpdateParams::PaymentIntentData), payment_method_collection: T.nilable(String), payment_method_types: T.nilable(T.nilable(T.any(String, T::Array[String]))), phone_number_collection: T.nilable(::Stripe::PaymentLinkService::UpdateParams::PhoneNumberCollection), restrictions: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLinkService::UpdateParams::Restrictions))), shipping_address_collection: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentLinkService::UpdateParams::ShippingAddressCollection))), submit_type: T.nilable(String), subscription_data: T.nilable(::Stripe::PaymentLinkService::UpdateParams::SubscriptionData), tax_id_collection: T.nilable(::Stripe::PaymentLinkService::UpdateParams::TaxIdCollection)).void
}
def initialize(
active: nil,
after_completion: nil,
allow_promotion_codes: nil,
automatic_tax: nil,
billing_address_collection: nil,
custom_fields: nil,
custom_text: nil,
customer_creation: nil,
expand: nil,
inactive_message: nil,
invoice_creation: nil,
line_items: nil,
metadata: nil,
payment_intent_data: nil,
payment_method_collection: nil,
payment_method_types: nil,
phone_number_collection: nil,
restrictions: nil,
shipping_address_collection: nil,
submit_type: nil,
subscription_data: nil,
tax_id_collection: nil
); end
end
# Creates a payment link.
sig {
params(params: T.any(::Stripe::PaymentLinkService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentLink)
}
def create(params = {}, opts = {}); end
# Returns a list of your payment links.
sig {
params(params: T.any(::Stripe::PaymentLinkService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieve a payment link.
sig {
params(payment_link: String, params: T.any(::Stripe::PaymentLinkService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentLink)
}
def retrieve(payment_link, params = {}, opts = {}); end
# Updates a payment link.
sig {
params(payment_link: String, params: T.any(::Stripe::PaymentLinkService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentLink)
}
def update(payment_link, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class PaymentLinkLineItemService < StripeService
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
# When retrieving a payment link, there is an includable line_items property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items.
sig {
params(payment_link: String, params: T.any(::Stripe::PaymentLinkLineItemService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(payment_link, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class PaymentMethodService < StripeService
class ListParams < Stripe::RequestParams
# The ID of the customer whose PaymentMethods will be retrieved.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# An optional filter on the list, based on the object `type` field. Without the filter, the list includes all current and future payment method types. If your integration expects only one type of payment method in the response, make sure to provide a type value in the request.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(customer: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String), type: T.nilable(String)).void
}
def initialize(
customer: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil,
type: nil
); end
end
class CreateParams < Stripe::RequestParams
class AcssDebit < Stripe::RequestParams
# Customer's bank account number.
sig { returns(String) }
attr_accessor :account_number
# Institution number of the customer's bank.
sig { returns(String) }
attr_accessor :institution_number
# Transit number of the customer's bank.
sig { returns(String) }
attr_accessor :transit_number
sig {
params(account_number: String, institution_number: String, transit_number: String).void
}
def initialize(account_number: nil, institution_number: nil, transit_number: nil); end
end
class Affirm < Stripe::RequestParams; end
class AfterpayClearpay < Stripe::RequestParams; end
class Alipay < Stripe::RequestParams; end
class Alma < Stripe::RequestParams; end
class AmazonPay < Stripe::RequestParams; end
class AuBecsDebit < Stripe::RequestParams
# The account number for the bank account.
sig { returns(String) }
attr_accessor :account_number
# Bank-State-Branch number of the bank account.
sig { returns(String) }
attr_accessor :bsb_number
sig { params(account_number: String, bsb_number: String).void }
def initialize(account_number: nil, bsb_number: nil); end
end
class BacsDebit < Stripe::RequestParams
# Account number of the bank account that the funds will be debited from.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Sort code of the bank account. (e.g., `10-20-30`)
sig { returns(T.nilable(String)) }
attr_accessor :sort_code
sig { params(account_number: T.nilable(String), sort_code: T.nilable(String)).void }
def initialize(account_number: nil, sort_code: nil); end
end
class Bancontact < Stripe::RequestParams; end
class Billie < Stripe::RequestParams; end
class BillingDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Billing address.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentMethodService::CreateParams::BillingDetails::Address))))
}
attr_accessor :address
# Email address.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :email
# Full name.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :name
# Billing phone number (including extension).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :phone
# Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
sig { returns(T.nilable(String)) }
attr_accessor :tax_id
sig {
params(address: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentMethodService::CreateParams::BillingDetails::Address))), email: T.nilable(T.nilable(String)), name: T.nilable(T.nilable(String)), phone: T.nilable(T.nilable(String)), tax_id: T.nilable(String)).void
}
def initialize(address: nil, email: nil, name: nil, phone: nil, tax_id: nil); end
end
class Blik < Stripe::RequestParams; end
class Boleto < Stripe::RequestParams
# The tax ID of the customer (CPF for individual consumers or CNPJ for businesses consumers)
sig { returns(String) }
attr_accessor :tax_id
sig { params(tax_id: String).void }
def initialize(tax_id: nil); end
end
class Card < Stripe::RequestParams
class Networks < Stripe::RequestParams
# The customer's preferred card network for co-branded cards. Supports `cartes_bancaires`, `mastercard`, or `visa`. Selection of a network that does not apply to the card will be stored as `invalid_preference` on the card.
sig { returns(T.nilable(String)) }
attr_accessor :preferred
sig { params(preferred: T.nilable(String)).void }
def initialize(preferred: nil); end
end
# The card's CVC. It is highly recommended to always include this value.
sig { returns(T.nilable(String)) }
attr_accessor :cvc
# Two-digit number representing the card's expiration month.
sig { returns(T.nilable(Integer)) }
attr_accessor :exp_month
# Four-digit number representing the card's expiration year.
sig { returns(T.nilable(Integer)) }
attr_accessor :exp_year
# Contains information about card networks used to process the payment.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::Card::Networks)) }
attr_accessor :networks
# The card number, as a string without any separators.
sig { returns(T.nilable(String)) }
attr_accessor :number
# For backwards compatibility, you can alternatively provide a Stripe token (e.g., for Apple Pay, Amex Express Checkout, or legacy Checkout) into the card hash with format card: {token: "tok_visa"}.
sig { returns(T.nilable(String)) }
attr_accessor :token
sig {
params(cvc: T.nilable(String), exp_month: T.nilable(Integer), exp_year: T.nilable(Integer), networks: T.nilable(::Stripe::PaymentMethodService::CreateParams::Card::Networks), number: T.nilable(String), token: T.nilable(String)).void
}
def initialize(
cvc: nil,
exp_month: nil,
exp_year: nil,
networks: nil,
number: nil,
token: nil
); end
end
class Cashapp < Stripe::RequestParams; end
class CustomerBalance < Stripe::RequestParams; end
class Eps < Stripe::RequestParams
# The customer's bank.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class Fpx < Stripe::RequestParams
# Account holder type for FPX transaction
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_type
# The customer's bank.
sig { returns(String) }
attr_accessor :bank
sig { params(account_holder_type: T.nilable(String), bank: String).void }
def initialize(account_holder_type: nil, bank: nil); end
end
class Giropay < Stripe::RequestParams; end
class Gopay < Stripe::RequestParams; end
class Grabpay < Stripe::RequestParams; end
class IdBankTransfer < Stripe::RequestParams
# Bank where the account is held.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class Ideal < Stripe::RequestParams
# The customer's bank. Only use this parameter for existing customers. Don't use it for new customers.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class InteracPresent < Stripe::RequestParams; end
class KakaoPay < Stripe::RequestParams; end
class Klarna < Stripe::RequestParams
class Dob < Stripe::RequestParams
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
# Customer's date of birth
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::Klarna::Dob)) }
attr_accessor :dob
sig {
params(dob: T.nilable(::Stripe::PaymentMethodService::CreateParams::Klarna::Dob)).void
}
def initialize(dob: nil); end
end
class Konbini < Stripe::RequestParams; end
class KrCard < Stripe::RequestParams; end
class Link < Stripe::RequestParams; end
class MbWay < Stripe::RequestParams; end
class Mobilepay < Stripe::RequestParams; end
class Multibanco < Stripe::RequestParams; end
class NaverPay < Stripe::RequestParams
# Whether to use Naver Pay points or a card to fund this transaction. If not provided, this defaults to `card`.
sig { returns(T.nilable(String)) }
attr_accessor :funding
sig { params(funding: T.nilable(String)).void }
def initialize(funding: nil); end
end
class NzBankAccount < Stripe::RequestParams
# The name on the bank account. Only required if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod’s billing details.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_name
# The account number for the bank account.
sig { returns(String) }
attr_accessor :account_number
# The numeric code for the bank account's bank.
sig { returns(String) }
attr_accessor :bank_code
# The numeric code for the bank account's bank branch.
sig { returns(String) }
attr_accessor :branch_code
# Attribute for param field reference
sig { returns(T.nilable(String)) }
attr_accessor :reference
# The suffix of the bank account number.
sig { returns(String) }
attr_accessor :suffix
sig {
params(account_holder_name: T.nilable(String), account_number: String, bank_code: String, branch_code: String, reference: T.nilable(String), suffix: String).void
}
def initialize(
account_holder_name: nil,
account_number: nil,
bank_code: nil,
branch_code: nil,
reference: nil,
suffix: nil
); end
end
class Oxxo < Stripe::RequestParams; end
class P24 < Stripe::RequestParams
# The customer's bank.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class PayByBank < Stripe::RequestParams; end
class Payco < Stripe::RequestParams; end
class Paynow < Stripe::RequestParams; end
class Paypal < Stripe::RequestParams; end
class Payto < Stripe::RequestParams
# The account number for the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Bank-State-Branch number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :bsb_number
# The PayID alias for the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :pay_id
sig {
params(account_number: T.nilable(String), bsb_number: T.nilable(String), pay_id: T.nilable(String)).void
}
def initialize(account_number: nil, bsb_number: nil, pay_id: nil); end
end
class Pix < Stripe::RequestParams; end
class Promptpay < Stripe::RequestParams; end
class Qris < Stripe::RequestParams; end
class RadarOptions < Stripe::RequestParams
# A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
sig { returns(T.nilable(String)) }
attr_accessor :session
sig { params(session: T.nilable(String)).void }
def initialize(session: nil); end
end
class Rechnung < Stripe::RequestParams
class Dob < Stripe::RequestParams
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
# Customer's date of birth
sig { returns(::Stripe::PaymentMethodService::CreateParams::Rechnung::Dob) }
attr_accessor :dob
sig { params(dob: ::Stripe::PaymentMethodService::CreateParams::Rechnung::Dob).void }
def initialize(dob: nil); end
end
class RevolutPay < Stripe::RequestParams; end
class SamsungPay < Stripe::RequestParams; end
class Satispay < Stripe::RequestParams; end
class SepaDebit < Stripe::RequestParams
# IBAN of the bank account.
sig { returns(String) }
attr_accessor :iban
sig { params(iban: String).void }
def initialize(iban: nil); end
end
class Shopeepay < Stripe::RequestParams; end
class Sofort < Stripe::RequestParams
# Two-letter ISO code representing the country the bank account is located in.
sig { returns(String) }
attr_accessor :country
sig { params(country: String).void }
def initialize(country: nil); end
end
class StripeBalance < Stripe::RequestParams
# The connected account ID whose Stripe balance to use as the source of payment
sig { returns(T.nilable(String)) }
attr_accessor :account
# The [source_type](https://docs.stripe.com/api/balance/balance_object#balance_object-available-source_types) of the balance
sig { returns(T.nilable(String)) }
attr_accessor :source_type
sig { params(account: T.nilable(String), source_type: T.nilable(String)).void }
def initialize(account: nil, source_type: nil); end
end
class Swish < Stripe::RequestParams; end
class Twint < Stripe::RequestParams; end
class UsBankAccount < Stripe::RequestParams
# Account holder type: individual or company.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_type
# Account number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Account type: checkings or savings. Defaults to checking if omitted.
sig { returns(T.nilable(String)) }
attr_accessor :account_type
# The ID of a Financial Connections Account to use as a payment method.
sig { returns(T.nilable(String)) }
attr_accessor :financial_connections_account
# Routing number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :routing_number
sig {
params(account_holder_type: T.nilable(String), account_number: T.nilable(String), account_type: T.nilable(String), financial_connections_account: T.nilable(String), routing_number: T.nilable(String)).void
}
def initialize(
account_holder_type: nil,
account_number: nil,
account_type: nil,
financial_connections_account: nil,
routing_number: nil
); end
end
class WechatPay < Stripe::RequestParams; end
class Zip < Stripe::RequestParams; end
# If this is an `acss_debit` PaymentMethod, this hash contains details about the ACSS Debit payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::AcssDebit)) }
attr_accessor :acss_debit
# If this is an `affirm` PaymentMethod, this hash contains details about the Affirm payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::Affirm)) }
attr_accessor :affirm
# If this is an `AfterpayClearpay` PaymentMethod, this hash contains details about the AfterpayClearpay payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::AfterpayClearpay)) }
attr_accessor :afterpay_clearpay
# If this is an `Alipay` PaymentMethod, this hash contains details about the Alipay payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::Alipay)) }
attr_accessor :alipay
# This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :allow_redisplay
# If this is a Alma PaymentMethod, this hash contains details about the Alma payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::Alma)) }
attr_accessor :alma
# If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::AmazonPay)) }
attr_accessor :amazon_pay
# If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::AuBecsDebit)) }
attr_accessor :au_becs_debit
# If this is a `bacs_debit` PaymentMethod, this hash contains details about the Bacs Direct Debit bank account.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::BacsDebit)) }
attr_accessor :bacs_debit
# If this is a `bancontact` PaymentMethod, this hash contains details about the Bancontact payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::Bancontact)) }
attr_accessor :bancontact
# If this is a `billie` PaymentMethod, this hash contains details about the Billie payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::Billie)) }
attr_accessor :billie
# Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::BillingDetails)) }
attr_accessor :billing_details
# If this is a `blik` PaymentMethod, this hash contains details about the BLIK payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::Blik)) }
attr_accessor :blik
# If this is a `boleto` PaymentMethod, this hash contains details about the Boleto payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::Boleto)) }
attr_accessor :boleto
# If this is a `card` PaymentMethod, this hash contains the user's card details. For backwards compatibility, you can alternatively provide a Stripe token (e.g., for Apple Pay, Amex Express Checkout, or legacy Checkout) into the card hash with format `card: {token: "tok_visa"}`. When providing a card number, you must meet the requirements for [PCI compliance](https://stripe.com/docs/security#validating-pci-compliance). We strongly recommend using Stripe.js instead of interacting with this API directly.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::Card)) }
attr_accessor :card
# If this is a `cashapp` PaymentMethod, this hash contains details about the Cash App Pay payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::Cashapp)) }
attr_accessor :cashapp
# The `Customer` to whom the original PaymentMethod is attached.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# If this is a `customer_balance` PaymentMethod, this hash contains details about the CustomerBalance payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::CustomerBalance)) }
attr_accessor :customer_balance
# If this is an `eps` PaymentMethod, this hash contains details about the EPS payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::Eps)) }
attr_accessor :eps
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::Fpx)) }
attr_accessor :fpx
# If this is a `giropay` PaymentMethod, this hash contains details about the Giropay payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::Giropay)) }
attr_accessor :giropay
# If this is a Gopay PaymentMethod, this hash contains details about the Gopay payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::Gopay)) }
attr_accessor :gopay
# If this is a `grabpay` PaymentMethod, this hash contains details about the GrabPay payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::Grabpay)) }
attr_accessor :grabpay
# If this is an `IdBankTransfer` PaymentMethod, this hash contains details about the IdBankTransfer payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::IdBankTransfer)) }
attr_accessor :id_bank_transfer
# If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::Ideal)) }
attr_accessor :ideal
# If this is an `interac_present` PaymentMethod, this hash contains details about the Interac Present payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::InteracPresent)) }
attr_accessor :interac_present
# If this is a `kakao_pay` PaymentMethod, this hash contains details about the Kakao Pay payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::KakaoPay)) }
attr_accessor :kakao_pay
# If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::Klarna)) }
attr_accessor :klarna
# If this is a `konbini` PaymentMethod, this hash contains details about the Konbini payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::Konbini)) }
attr_accessor :konbini
# If this is a `kr_card` PaymentMethod, this hash contains details about the Korean Card payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::KrCard)) }
attr_accessor :kr_card
# If this is an `Link` PaymentMethod, this hash contains details about the Link payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::Link)) }
attr_accessor :link
# If this is a MB WAY PaymentMethod, this hash contains details about the MB WAY payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::MbWay)) }
attr_accessor :mb_way
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# If this is a `mobilepay` PaymentMethod, this hash contains details about the MobilePay payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::Mobilepay)) }
attr_accessor :mobilepay
# If this is a `multibanco` PaymentMethod, this hash contains details about the Multibanco payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::Multibanco)) }
attr_accessor :multibanco
# If this is a `naver_pay` PaymentMethod, this hash contains details about the Naver Pay payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::NaverPay)) }
attr_accessor :naver_pay
# If this is an nz_bank_account PaymentMethod, this hash contains details about the nz_bank_account payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::NzBankAccount)) }
attr_accessor :nz_bank_account
# If this is an `oxxo` PaymentMethod, this hash contains details about the OXXO payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::Oxxo)) }
attr_accessor :oxxo
# If this is a `p24` PaymentMethod, this hash contains details about the P24 payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::P24)) }
attr_accessor :p24
# If this is a `pay_by_bank` PaymentMethod, this hash contains details about the PayByBank payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::PayByBank)) }
attr_accessor :pay_by_bank
# If this is a `payco` PaymentMethod, this hash contains details about the PAYCO payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::Payco)) }
attr_accessor :payco
# The PaymentMethod to share.
sig { returns(T.nilable(String)) }
attr_accessor :payment_method
# If this is a `paynow` PaymentMethod, this hash contains details about the PayNow payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::Paynow)) }
attr_accessor :paynow
# If this is a `paypal` PaymentMethod, this hash contains details about the PayPal payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::Paypal)) }
attr_accessor :paypal
# If this is a `payto` PaymentMethod, this hash contains details about the PayTo payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::Payto)) }
attr_accessor :payto
# If this is a `pix` PaymentMethod, this hash contains details about the Pix payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::Pix)) }
attr_accessor :pix
# If this is a `promptpay` PaymentMethod, this hash contains details about the PromptPay payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::Promptpay)) }
attr_accessor :promptpay
# If this is a `qris` PaymentMethod, this hash contains details about the QRIS payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::Qris)) }
attr_accessor :qris
# Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::RadarOptions)) }
attr_accessor :radar_options
# If this is a `rechnung` PaymentMethod, this hash contains details about the Rechnung payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::Rechnung)) }
attr_accessor :rechnung
# If this is a `revolut_pay` PaymentMethod, this hash contains details about the Revolut Pay payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::RevolutPay)) }
attr_accessor :revolut_pay
# If this is a `samsung_pay` PaymentMethod, this hash contains details about the SamsungPay payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::SamsungPay)) }
attr_accessor :samsung_pay
# If this is a `satispay` PaymentMethod, this hash contains details about the Satispay payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::Satispay)) }
attr_accessor :satispay
# If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::SepaDebit)) }
attr_accessor :sepa_debit
# If this is a Shopeepay PaymentMethod, this hash contains details about the Shopeepay payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::Shopeepay)) }
attr_accessor :shopeepay
# If this is a `sofort` PaymentMethod, this hash contains details about the SOFORT payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::Sofort)) }
attr_accessor :sofort
# This hash contains details about the Stripe balance payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::StripeBalance)) }
attr_accessor :stripe_balance
# If this is a `swish` PaymentMethod, this hash contains details about the Swish payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::Swish)) }
attr_accessor :swish
# If this is a TWINT PaymentMethod, this hash contains details about the TWINT payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::Twint)) }
attr_accessor :twint
# The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
sig { returns(T.nilable(String)) }
attr_accessor :type
# If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::UsBankAccount)) }
attr_accessor :us_bank_account
# If this is an `wechat_pay` PaymentMethod, this hash contains details about the wechat_pay payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::WechatPay)) }
attr_accessor :wechat_pay
# If this is a `zip` PaymentMethod, this hash contains details about the Zip payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::CreateParams::Zip)) }
attr_accessor :zip
sig {
params(acss_debit: T.nilable(::Stripe::PaymentMethodService::CreateParams::AcssDebit), affirm: T.nilable(::Stripe::PaymentMethodService::CreateParams::Affirm), afterpay_clearpay: T.nilable(::Stripe::PaymentMethodService::CreateParams::AfterpayClearpay), alipay: T.nilable(::Stripe::PaymentMethodService::CreateParams::Alipay), allow_redisplay: T.nilable(String), alma: T.nilable(::Stripe::PaymentMethodService::CreateParams::Alma), amazon_pay: T.nilable(::Stripe::PaymentMethodService::CreateParams::AmazonPay), au_becs_debit: T.nilable(::Stripe::PaymentMethodService::CreateParams::AuBecsDebit), bacs_debit: T.nilable(::Stripe::PaymentMethodService::CreateParams::BacsDebit), bancontact: T.nilable(::Stripe::PaymentMethodService::CreateParams::Bancontact), billie: T.nilable(::Stripe::PaymentMethodService::CreateParams::Billie), billing_details: T.nilable(::Stripe::PaymentMethodService::CreateParams::BillingDetails), blik: T.nilable(::Stripe::PaymentMethodService::CreateParams::Blik), boleto: T.nilable(::Stripe::PaymentMethodService::CreateParams::Boleto), card: T.nilable(::Stripe::PaymentMethodService::CreateParams::Card), cashapp: T.nilable(::Stripe::PaymentMethodService::CreateParams::Cashapp), customer: T.nilable(String), customer_balance: T.nilable(::Stripe::PaymentMethodService::CreateParams::CustomerBalance), eps: T.nilable(::Stripe::PaymentMethodService::CreateParams::Eps), expand: T.nilable(T::Array[String]), fpx: T.nilable(::Stripe::PaymentMethodService::CreateParams::Fpx), giropay: T.nilable(::Stripe::PaymentMethodService::CreateParams::Giropay), gopay: T.nilable(::Stripe::PaymentMethodService::CreateParams::Gopay), grabpay: T.nilable(::Stripe::PaymentMethodService::CreateParams::Grabpay), id_bank_transfer: T.nilable(::Stripe::PaymentMethodService::CreateParams::IdBankTransfer), ideal: T.nilable(::Stripe::PaymentMethodService::CreateParams::Ideal), interac_present: T.nilable(::Stripe::PaymentMethodService::CreateParams::InteracPresent), kakao_pay: T.nilable(::Stripe::PaymentMethodService::CreateParams::KakaoPay), klarna: T.nilable(::Stripe::PaymentMethodService::CreateParams::Klarna), konbini: T.nilable(::Stripe::PaymentMethodService::CreateParams::Konbini), kr_card: T.nilable(::Stripe::PaymentMethodService::CreateParams::KrCard), link: T.nilable(::Stripe::PaymentMethodService::CreateParams::Link), mb_way: T.nilable(::Stripe::PaymentMethodService::CreateParams::MbWay), metadata: T.nilable(T::Hash[String, String]), mobilepay: T.nilable(::Stripe::PaymentMethodService::CreateParams::Mobilepay), multibanco: T.nilable(::Stripe::PaymentMethodService::CreateParams::Multibanco), naver_pay: T.nilable(::Stripe::PaymentMethodService::CreateParams::NaverPay), nz_bank_account: T.nilable(::Stripe::PaymentMethodService::CreateParams::NzBankAccount), oxxo: T.nilable(::Stripe::PaymentMethodService::CreateParams::Oxxo), p24: T.nilable(::Stripe::PaymentMethodService::CreateParams::P24), pay_by_bank: T.nilable(::Stripe::PaymentMethodService::CreateParams::PayByBank), payco: T.nilable(::Stripe::PaymentMethodService::CreateParams::Payco), payment_method: T.nilable(String), paynow: T.nilable(::Stripe::PaymentMethodService::CreateParams::Paynow), paypal: T.nilable(::Stripe::PaymentMethodService::CreateParams::Paypal), payto: T.nilable(::Stripe::PaymentMethodService::CreateParams::Payto), pix: T.nilable(::Stripe::PaymentMethodService::CreateParams::Pix), promptpay: T.nilable(::Stripe::PaymentMethodService::CreateParams::Promptpay), qris: T.nilable(::Stripe::PaymentMethodService::CreateParams::Qris), radar_options: T.nilable(::Stripe::PaymentMethodService::CreateParams::RadarOptions), rechnung: T.nilable(::Stripe::PaymentMethodService::CreateParams::Rechnung), revolut_pay: T.nilable(::Stripe::PaymentMethodService::CreateParams::RevolutPay), samsung_pay: T.nilable(::Stripe::PaymentMethodService::CreateParams::SamsungPay), satispay: T.nilable(::Stripe::PaymentMethodService::CreateParams::Satispay), sepa_debit: T.nilable(::Stripe::PaymentMethodService::CreateParams::SepaDebit), shopeepay: T.nilable(::Stripe::PaymentMethodService::CreateParams::Shopeepay), sofort: T.nilable(::Stripe::PaymentMethodService::CreateParams::Sofort), stripe_balance: T.nilable(::Stripe::PaymentMethodService::CreateParams::StripeBalance), swish: T.nilable(::Stripe::PaymentMethodService::CreateParams::Swish), twint: T.nilable(::Stripe::PaymentMethodService::CreateParams::Twint), type: T.nilable(String), us_bank_account: T.nilable(::Stripe::PaymentMethodService::CreateParams::UsBankAccount), wechat_pay: T.nilable(::Stripe::PaymentMethodService::CreateParams::WechatPay), zip: T.nilable(::Stripe::PaymentMethodService::CreateParams::Zip)).void
}
def initialize(
acss_debit: nil,
affirm: nil,
afterpay_clearpay: nil,
alipay: nil,
allow_redisplay: nil,
alma: nil,
amazon_pay: nil,
au_becs_debit: nil,
bacs_debit: nil,
bancontact: nil,
billie: nil,
billing_details: nil,
blik: nil,
boleto: nil,
card: nil,
cashapp: nil,
customer: nil,
customer_balance: nil,
eps: nil,
expand: nil,
fpx: nil,
giropay: nil,
gopay: nil,
grabpay: nil,
id_bank_transfer: nil,
ideal: nil,
interac_present: nil,
kakao_pay: nil,
klarna: nil,
konbini: nil,
kr_card: nil,
link: nil,
mb_way: nil,
metadata: nil,
mobilepay: nil,
multibanco: nil,
naver_pay: nil,
nz_bank_account: nil,
oxxo: nil,
p24: nil,
pay_by_bank: nil,
payco: nil,
payment_method: nil,
paynow: nil,
paypal: nil,
payto: nil,
pix: nil,
promptpay: nil,
qris: nil,
radar_options: nil,
rechnung: nil,
revolut_pay: nil,
samsung_pay: nil,
satispay: nil,
sepa_debit: nil,
shopeepay: nil,
sofort: nil,
stripe_balance: nil,
swish: nil,
twint: nil,
type: nil,
us_bank_account: nil,
wechat_pay: nil,
zip: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
class BillingDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Billing address.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PaymentMethodService::UpdateParams::BillingDetails::Address))))
}
attr_accessor :address
# Email address.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :email
# Full name.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :name
# Billing phone number (including extension).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :phone
# Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
sig { returns(T.nilable(String)) }
attr_accessor :tax_id
sig {
params(address: T.nilable(T.nilable(T.any(String, ::Stripe::PaymentMethodService::UpdateParams::BillingDetails::Address))), email: T.nilable(T.nilable(String)), name: T.nilable(T.nilable(String)), phone: T.nilable(T.nilable(String)), tax_id: T.nilable(String)).void
}
def initialize(address: nil, email: nil, name: nil, phone: nil, tax_id: nil); end
end
class Card < Stripe::RequestParams
class Networks < Stripe::RequestParams
# The customer's preferred card network for co-branded cards. Supports `cartes_bancaires`, `mastercard`, or `visa`. Selection of a network that does not apply to the card will be stored as `invalid_preference` on the card.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :preferred
sig { params(preferred: T.nilable(T.nilable(T.any(String, String)))).void }
def initialize(preferred: nil); end
end
# Two-digit number representing the card's expiration month.
sig { returns(T.nilable(Integer)) }
attr_accessor :exp_month
# Four-digit number representing the card's expiration year.
sig { returns(T.nilable(Integer)) }
attr_accessor :exp_year
# Contains information about card networks used to process the payment.
sig { returns(T.nilable(::Stripe::PaymentMethodService::UpdateParams::Card::Networks)) }
attr_accessor :networks
sig {
params(exp_month: T.nilable(Integer), exp_year: T.nilable(Integer), networks: T.nilable(::Stripe::PaymentMethodService::UpdateParams::Card::Networks)).void
}
def initialize(exp_month: nil, exp_year: nil, networks: nil); end
end
class Link < Stripe::RequestParams; end
class PayByBank < Stripe::RequestParams; end
class Payto < Stripe::RequestParams
# The account number for the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Bank-State-Branch number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :bsb_number
# The PayID alias for the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :pay_id
sig {
params(account_number: T.nilable(String), bsb_number: T.nilable(String), pay_id: T.nilable(String)).void
}
def initialize(account_number: nil, bsb_number: nil, pay_id: nil); end
end
class UsBankAccount < Stripe::RequestParams
# Bank account holder type.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_type
# Bank account type.
sig { returns(T.nilable(String)) }
attr_accessor :account_type
sig { params(account_holder_type: T.nilable(String), account_type: T.nilable(String)).void }
def initialize(account_holder_type: nil, account_type: nil); end
end
# This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :allow_redisplay
# Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
sig { returns(T.nilable(::Stripe::PaymentMethodService::UpdateParams::BillingDetails)) }
attr_accessor :billing_details
# If this is a `card` PaymentMethod, this hash contains the user's card details.
sig { returns(T.nilable(::Stripe::PaymentMethodService::UpdateParams::Card)) }
attr_accessor :card
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# If this is an `Link` PaymentMethod, this hash contains details about the Link payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::UpdateParams::Link)) }
attr_accessor :link
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# If this is a `pay_by_bank` PaymentMethod, this hash contains details about the PayByBank payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::UpdateParams::PayByBank)) }
attr_accessor :pay_by_bank
# If this is a `payto` PaymentMethod, this hash contains details about the PayTo payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::UpdateParams::Payto)) }
attr_accessor :payto
# If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
sig { returns(T.nilable(::Stripe::PaymentMethodService::UpdateParams::UsBankAccount)) }
attr_accessor :us_bank_account
sig {
params(allow_redisplay: T.nilable(String), billing_details: T.nilable(::Stripe::PaymentMethodService::UpdateParams::BillingDetails), card: T.nilable(::Stripe::PaymentMethodService::UpdateParams::Card), expand: T.nilable(T::Array[String]), link: T.nilable(::Stripe::PaymentMethodService::UpdateParams::Link), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), pay_by_bank: T.nilable(::Stripe::PaymentMethodService::UpdateParams::PayByBank), payto: T.nilable(::Stripe::PaymentMethodService::UpdateParams::Payto), us_bank_account: T.nilable(::Stripe::PaymentMethodService::UpdateParams::UsBankAccount)).void
}
def initialize(
allow_redisplay: nil,
billing_details: nil,
card: nil,
expand: nil,
link: nil,
metadata: nil,
pay_by_bank: nil,
payto: nil,
us_bank_account: nil
); end
end
class AttachParams < Stripe::RequestParams
# The ID of the customer to which to attach the PaymentMethod.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# The ID of the account to which to attach the PaymentMethod.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig {
params(customer: T.nilable(String), customer_account: T.nilable(String), expand: T.nilable(T::Array[String])).void
}
def initialize(customer: nil, customer_account: nil, expand: nil); end
end
class DetachParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Attaches a PaymentMethod object to a Customer.
#
# To attach a new PaymentMethod to a customer for future payments, we recommend you use a [SetupIntent](https://docs.stripe.com/docs/api/setup_intents)
# or a PaymentIntent with [setup_future_usage](https://docs.stripe.com/docs/api/payment_intents/create#create_payment_intent-setup_future_usage).
# These approaches will perform any necessary steps to set up the PaymentMethod for future payments. Using the /v1/payment_methods/:id/attach
# endpoint without first using a SetupIntent or PaymentIntent with setup_future_usage does not optimize the PaymentMethod for
# future use, which makes later declines and payment friction more likely.
# See [Optimizing cards for future payments](https://docs.stripe.com/docs/payments/payment-intents#future-usage) for more information about setting up
# future payments.
#
# To use this PaymentMethod as the default for invoice or subscription payments,
# set [invoice_settings.default_payment_method](https://docs.stripe.com/docs/api/customers/update#update_customer-invoice_settings-default_payment_method),
# on the Customer to the PaymentMethod's ID.
sig {
params(payment_method: String, params: T.any(::Stripe::PaymentMethodService::AttachParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentMethod)
}
def attach(payment_method, params = {}, opts = {}); end
# Creates a PaymentMethod object. Read the [Stripe.js reference](https://docs.stripe.com/docs/stripe-js/reference#stripe-create-payment-method) to learn how to create PaymentMethods via Stripe.js.
#
# Instead of creating a PaymentMethod directly, we recommend using the [PaymentIntents API to accept a payment immediately or the SetupIntent](https://docs.stripe.com/docs/payments/accept-a-payment) API to collect payment method details ahead of a future payment.
sig {
params(params: T.any(::Stripe::PaymentMethodService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentMethod)
}
def create(params = {}, opts = {}); end
# Detaches a PaymentMethod object from a Customer. After a PaymentMethod is detached, it can no longer be used for a payment or re-attached to a Customer.
sig {
params(payment_method: String, params: T.any(::Stripe::PaymentMethodService::DetachParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentMethod)
}
def detach(payment_method, params = {}, opts = {}); end
# Returns a list of PaymentMethods for Treasury flows. If you want to list the PaymentMethods attached to a Customer for payments, you should use the [List a Customer's PaymentMethods](https://docs.stripe.com/docs/api/payment_methods/customer_list) API instead.
sig {
params(params: T.any(::Stripe::PaymentMethodService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves a PaymentMethod object attached to the StripeAccount. To retrieve a payment method attached to a Customer, you should use [Retrieve a Customer's PaymentMethods](https://docs.stripe.com/docs/api/payment_methods/customer)
sig {
params(payment_method: String, params: T.any(::Stripe::PaymentMethodService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentMethod)
}
def retrieve(payment_method, params = {}, opts = {}); end
# Updates a PaymentMethod object. A PaymentMethod must be attached a customer to be updated.
sig {
params(payment_method: String, params: T.any(::Stripe::PaymentMethodService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentMethod)
}
def update(payment_method, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class PaymentMethodConfigurationService < StripeService
class ListParams < Stripe::RequestParams
# The Connect application to filter by.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :application
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(application: T.nilable(T.nilable(String)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
application: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class AcssDebit < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::AcssDebit::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::AcssDebit::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Affirm < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Affirm::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Affirm::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class AfterpayClearpay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::AfterpayClearpay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::AfterpayClearpay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Alipay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Alipay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Alipay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Alma < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Alma::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Alma::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class AmazonPay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::AmazonPay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::AmazonPay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class ApplePay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::ApplePay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::ApplePay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class ApplePayLater < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::ApplePayLater::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::ApplePayLater::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class AuBecsDebit < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::AuBecsDebit::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::AuBecsDebit::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class BacsDebit < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::BacsDebit::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::BacsDebit::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Bancontact < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Bancontact::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Bancontact::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Billie < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Billie::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Billie::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Blik < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Blik::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Blik::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Boleto < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Boleto::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Boleto::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Card < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Card::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Card::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class CartesBancaires < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::CartesBancaires::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::CartesBancaires::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Cashapp < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Cashapp::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Cashapp::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class CustomerBalance < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::CustomerBalance::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::CustomerBalance::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Eps < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Eps::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Eps::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Fpx < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Fpx::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Fpx::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Giropay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Giropay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Giropay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class GooglePay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::GooglePay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::GooglePay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Gopay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Gopay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Gopay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Grabpay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Grabpay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Grabpay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class IdBankTransfer < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::IdBankTransfer::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::IdBankTransfer::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Ideal < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Ideal::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Ideal::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Jcb < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Jcb::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Jcb::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class KakaoPay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::KakaoPay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::KakaoPay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Klarna < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Klarna::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Klarna::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Konbini < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Konbini::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Konbini::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class KrCard < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::KrCard::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::KrCard::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Link < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Link::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Link::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Mobilepay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Mobilepay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Mobilepay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Multibanco < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Multibanco::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Multibanco::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class NaverPay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::NaverPay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::NaverPay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class NzBankAccount < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::NzBankAccount::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::NzBankAccount::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Oxxo < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Oxxo::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Oxxo::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class P24 < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::P24::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::P24::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class PayByBank < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::PayByBank::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::PayByBank::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Payco < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Payco::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Payco::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Paynow < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Paynow::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Paynow::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Paypal < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Paypal::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Paypal::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Payto < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Payto::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Payto::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Pix < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Pix::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Pix::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Promptpay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Promptpay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Promptpay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Qris < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Qris::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Qris::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class RevolutPay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::RevolutPay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::RevolutPay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class SamsungPay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::SamsungPay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::SamsungPay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Satispay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Satispay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Satispay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class SepaDebit < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::SepaDebit::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::SepaDebit::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Shopeepay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Shopeepay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Shopeepay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Sofort < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Sofort::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Sofort::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Swish < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Swish::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Swish::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Twint < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Twint::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Twint::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class UsBankAccount < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::UsBankAccount::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::UsBankAccount::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class WechatPay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::WechatPay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::WechatPay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Zip < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Zip::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Zip::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
# Canadian pre-authorized debit payments, check this [page](https://stripe.com/docs/payments/acss-debit) for more details like country availability.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::AcssDebit))
}
attr_accessor :acss_debit
# [Affirm](https://www.affirm.com/) gives your customers a way to split purchases over a series of payments. Depending on the purchase, they can pay with four interest-free payments (Split Pay) or pay over a longer term (Installments), which might include interest. Check this [page](https://stripe.com/docs/payments/affirm) for more details like country availability.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Affirm)) }
attr_accessor :affirm
# Afterpay gives your customers a way to pay for purchases in installments, check this [page](https://stripe.com/docs/payments/afterpay-clearpay) for more details like country availability. Afterpay is particularly popular among businesses selling fashion, beauty, and sports products.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::AfterpayClearpay))
}
attr_accessor :afterpay_clearpay
# Alipay is a digital wallet in China that has more than a billion active users worldwide. Alipay users can pay on the web or on a mobile device using login credentials or their Alipay app. Alipay has a low dispute rate and reduces fraud by authenticating payments using the customer's login credentials. Check this [page](https://stripe.com/docs/payments/alipay) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Alipay)) }
attr_accessor :alipay
# Alma is a Buy Now, Pay Later payment method that offers customers the ability to pay in 2, 3, or 4 installments.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Alma)) }
attr_accessor :alma
# Amazon Pay is a wallet payment method that lets your customers check out the same way as on Amazon.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::AmazonPay))
}
attr_accessor :amazon_pay
# Stripe users can accept [Apple Pay](https://stripe.com/payments/apple-pay) in iOS applications in iOS 9 and later, and on the web in Safari starting with iOS 10 or macOS Sierra. There are no additional fees to process Apple Pay payments, and the [pricing](https://stripe.com/pricing) is the same as other card transactions. Check this [page](https://stripe.com/docs/apple-pay) for more details.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::ApplePay))
}
attr_accessor :apple_pay
# Apple Pay Later, a payment method for customers to buy now and pay later, gives your customers a way to split purchases into four installments across six weeks.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::ApplePayLater))
}
attr_accessor :apple_pay_later
# Stripe users in Australia can accept Bulk Electronic Clearing System (BECS) direct debit payments from customers with an Australian bank account. Check this [page](https://stripe.com/docs/payments/au-becs-debit) for more details.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::AuBecsDebit))
}
attr_accessor :au_becs_debit
# Stripe users in the UK can accept Bacs Direct Debit payments from customers with a UK bank account, check this [page](https://stripe.com/docs/payments/payment-methods/bacs-debit) for more details.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::BacsDebit))
}
attr_accessor :bacs_debit
# Bancontact is the most popular online payment method in Belgium, with over 15 million cards in circulation. [Customers](https://stripe.com/docs/api/customers) use a Bancontact card or mobile app linked to a Belgian bank account to make online payments that are secure, guaranteed, and confirmed immediately. Check this [page](https://stripe.com/docs/payments/bancontact) for more details.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Bancontact))
}
attr_accessor :bancontact
# Billie is a [single-use](https://docs.stripe.com/payments/payment-methods#usage) payment method that offers businesses Pay by Invoice where they offer payment terms ranging from 7-120 days. Customers are redirected from your website or app, authorize the payment with Billie, then return to your website or app. You get [immediate notification](/payments/payment-methods#payment-notification) of whether the payment succeeded or failed.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Billie)) }
attr_accessor :billie
# BLIK is a [single use](https://stripe.com/docs/payments/payment-methods#usage) payment method that requires customers to authenticate their payments. When customers want to pay online using BLIK, they request a six-digit code from their banking application and enter it into the payment collection form. Check this [page](https://stripe.com/docs/payments/blik) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Blik)) }
attr_accessor :blik
# Boleto is an official (regulated by the Central Bank of Brazil) payment method in Brazil. Check this [page](https://stripe.com/docs/payments/boleto) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Boleto)) }
attr_accessor :boleto
# Cards are a popular way for consumers and businesses to pay online or in person. Stripe supports global and local card networks.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Card)) }
attr_accessor :card
# Cartes Bancaires is France's local card network. More than 95% of these cards are co-branded with either Visa or Mastercard, meaning you can process these cards over either Cartes Bancaires or the Visa or Mastercard networks. Check this [page](https://stripe.com/docs/payments/cartes-bancaires) for more details.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::CartesBancaires))
}
attr_accessor :cartes_bancaires
# Cash App is a popular consumer app in the US that allows customers to bank, invest, send, and receive money using their digital wallet. Check this [page](https://stripe.com/docs/payments/cash-app-pay) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Cashapp)) }
attr_accessor :cashapp
# Uses a customer’s [cash balance](https://stripe.com/docs/payments/customer-balance) for the payment. The cash balance can be funded via a bank transfer. Check this [page](https://stripe.com/docs/payments/bank-transfers) for more details.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::CustomerBalance))
}
attr_accessor :customer_balance
# EPS is an Austria-based payment method that allows customers to complete transactions online using their bank credentials. EPS is supported by all Austrian banks and is accepted by over 80% of Austrian online retailers. Check this [page](https://stripe.com/docs/payments/eps) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Eps)) }
attr_accessor :eps
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Financial Process Exchange (FPX) is a Malaysia-based payment method that allows customers to complete transactions online using their bank credentials. Bank Negara Malaysia (BNM), the Central Bank of Malaysia, and eleven other major Malaysian financial institutions are members of the PayNet Group, which owns and operates FPX. It is one of the most popular online payment methods in Malaysia, with nearly 90 million transactions in 2018 according to BNM. Check this [page](https://stripe.com/docs/payments/fpx) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Fpx)) }
attr_accessor :fpx
# giropay is a German payment method based on online banking, introduced in 2006. It allows customers to complete transactions online using their online banking environment, with funds debited from their bank account. Depending on their bank, customers confirm payments on giropay using a second factor of authentication or a PIN. giropay accounts for 10% of online checkouts in Germany. Check this [page](https://stripe.com/docs/payments/giropay) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Giropay)) }
attr_accessor :giropay
# Google Pay allows customers to make payments in your app or website using any credit or debit card saved to their Google Account, including those from Google Play, YouTube, Chrome, or an Android device. Use the Google Pay API to request any credit or debit card stored in your customer's Google account. Check this [page](https://stripe.com/docs/google-pay) for more details.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::GooglePay))
}
attr_accessor :google_pay
# GoPay is a [single use](https://stripe.com/docs/payments/payment-methods#usage) digital wallet payment method popular in Indonesia. When paying with GoPay, customers authenticate and approve payments using the Gojek app. Desktop checkout is performed by scanning a QR code. When checking out on mobile, customers are redirected to the Gojek app to confirm payment.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Gopay)) }
attr_accessor :gopay
# GrabPay is a payment method developed by [Grab](https://www.grab.com/sg/consumer/finance/pay/). GrabPay is a digital wallet - customers maintain a balance in their wallets that they pay out with. Check this [page](https://stripe.com/docs/payments/grabpay) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Grabpay)) }
attr_accessor :grabpay
# Stripe users in Indonesia can receive bank transfers from customers in Indonesia. Bank transfers are a popular B2C and B2B payment method in Indonesia.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::IdBankTransfer))
}
attr_accessor :id_bank_transfer
# iDEAL is a Netherlands-based payment method that allows customers to complete transactions online using their bank credentials. All major Dutch banks are members of Currence, the scheme that operates iDEAL, making it the most popular online payment method in the Netherlands with a share of online transactions close to 55%. Check this [page](https://stripe.com/docs/payments/ideal) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Ideal)) }
attr_accessor :ideal
# JCB is a credit card company based in Japan. JCB is currently available in Japan to businesses approved by JCB, and available to all businesses in Australia, Canada, Hong Kong, Japan, New Zealand, Singapore, Switzerland, United Kingdom, United States, and all countries in the European Economic Area except Iceland. Check this [page](https://support.stripe.com/questions/accepting-japan-credit-bureau-%28jcb%29-payments) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Jcb)) }
attr_accessor :jcb
# Kakao Pay is a popular local wallet available in South Korea.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::KakaoPay))
}
attr_accessor :kakao_pay
# Klarna gives customers a range of [payment options](https://stripe.com/docs/payments/klarna#payment-options) during checkout. Available payment options vary depending on the customer's billing address and the transaction amount. These payment options make it convenient for customers to purchase items in all price ranges. Check this [page](https://stripe.com/docs/payments/klarna) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Klarna)) }
attr_accessor :klarna
# Konbini allows customers in Japan to pay for bills and online purchases at convenience stores with cash. Check this [page](https://stripe.com/docs/payments/konbini) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Konbini)) }
attr_accessor :konbini
# Korean cards let users pay using locally issued cards from South Korea.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::KrCard)) }
attr_accessor :kr_card
# [Link](https://stripe.com/docs/payments/link) is a payment method network. With Link, users save their payment details once, then reuse that information to pay with one click for any business on the network.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Link)) }
attr_accessor :link
# MobilePay is a [single-use](https://stripe.com/docs/payments/payment-methods#usage) card wallet payment method used in Denmark and Finland. It allows customers to [authenticate and approve](https://stripe.com/docs/payments/payment-methods#customer-actions) payments using the MobilePay app. Check this [page](https://stripe.com/docs/payments/mobilepay) for more details.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Mobilepay))
}
attr_accessor :mobilepay
# Stripe users in Europe and the United States can accept Multibanco payments from customers in Portugal using [Sources](https://stripe.com/docs/sources)—a single integration path for creating payments using any supported method.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Multibanco))
}
attr_accessor :multibanco
# Configuration name.
sig { returns(T.nilable(String)) }
attr_accessor :name
# Naver Pay is a popular local wallet available in South Korea.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::NaverPay))
}
attr_accessor :naver_pay
# Stripe users in New Zealand can accept Bulk Electronic Clearing System (BECS) direct debit payments from customers with a New Zeland bank account. Check this [page](https://stripe.com/docs/payments/nz-bank-account) for more details.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::NzBankAccount))
}
attr_accessor :nz_bank_account
# OXXO is a Mexican chain of convenience stores with thousands of locations across Latin America and represents nearly 20% of online transactions in Mexico. OXXO allows customers to pay bills and online purchases in-store with cash. Check this [page](https://stripe.com/docs/payments/oxxo) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Oxxo)) }
attr_accessor :oxxo
# Przelewy24 is a Poland-based payment method aggregator that allows customers to complete transactions online using bank transfers and other methods. Bank transfers account for 30% of online payments in Poland and Przelewy24 provides a way for customers to pay with over 165 banks. Check this [page](https://stripe.com/docs/payments/p24) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::P24)) }
attr_accessor :p24
# Configuration's parent configuration. Specify to create a child configuration.
sig { returns(T.nilable(String)) }
attr_accessor :parent
# Pay by bank is a redirect payment method backed by bank transfers. A customer is redirected to their bank to authorize a bank transfer for a given amount. This removes a lot of the error risks inherent in waiting for the customer to initiate a transfer themselves, and is less expensive than card payments.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::PayByBank))
}
attr_accessor :pay_by_bank
# PAYCO is a [single-use](https://docs.stripe.com/payments/payment-methods#usage local wallet available in South Korea.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Payco)) }
attr_accessor :payco
# PayNow is a Singapore-based payment method that allows customers to make a payment using their preferred app from participating banks and participating non-bank financial institutions. Check this [page](https://stripe.com/docs/payments/paynow) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Paynow)) }
attr_accessor :paynow
# PayPal, a digital wallet popular with customers in Europe, allows your customers worldwide to pay using their PayPal account. Check this [page](https://stripe.com/docs/payments/paypal) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Paypal)) }
attr_accessor :paypal
# PayTo is a [real-time](https://docs.stripe.com/payments/real-time) payment method that enables customers in Australia to pay by providing their bank account details. Customers must accept a mandate authorizing you to debit their account. Check this [page](https://docs.stripe.com/payments/payto) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Payto)) }
attr_accessor :payto
# Pix is a payment method popular in Brazil. When paying with Pix, customers authenticate and approve payments by scanning a QR code in their preferred banking app. Check this [page](https://docs.stripe.com/payments/pix) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Pix)) }
attr_accessor :pix
# PromptPay is a Thailand-based payment method that allows customers to make a payment using their preferred app from participating banks. Check this [page](https://stripe.com/docs/payments/promptpay) for more details.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Promptpay))
}
attr_accessor :promptpay
# QRIS is a [real-time](https://docs.stripe.com/payments/real-time) payment method popular in Indonesia. When paying with QRIS, customers authenticate and approve payments by scanning a QR code in their preferred digital wallet app.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Qris)) }
attr_accessor :qris
# Revolut Pay, developed by Revolut, a global finance app, is a digital wallet payment method. Revolut Pay uses the customer’s stored balance or cards to fund the payment, and offers the option for non-Revolut customers to save their details after their first purchase.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::RevolutPay))
}
attr_accessor :revolut_pay
# Samsung Pay is a [single-use](https://docs.stripe.com/payments/payment-methods#usage local wallet available in South Korea.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::SamsungPay))
}
attr_accessor :samsung_pay
# Satispay is a [single-use](https://docs.stripe.com/payments/payment-methods#usage) payment method where customers are required to [authenticate](/payments/payment-methods#customer-actions) their payment. Customers pay by being redirected from your website or app, authorizing the payment with Satispay, then returning to your website or app. You get [immediate notification](/payments/payment-methods#payment-notification) of whether the payment succeeded or failed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Satispay))
}
attr_accessor :satispay
# The [Single Euro Payments Area (SEPA)](https://en.wikipedia.org/wiki/Single_Euro_Payments_Area) is an initiative of the European Union to simplify payments within and across member countries. SEPA established and enforced banking standards to allow for the direct debiting of every EUR-denominated bank account within the SEPA region, check this [page](https://stripe.com/docs/payments/sepa-debit) for more details.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::SepaDebit))
}
attr_accessor :sepa_debit
# ShopeePay is a [single use](https://stripe.com/docs/payments/payment-methods#usage) digital wallet payment method popular in Indonesia. When paying with GoPay, customers authenticate and approve payments using the Shopee app. Desktop checkout is performed by scanning a QR code. When checking out on mobile, customers are redirected to the Shopee app to confirm payment.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Shopeepay))
}
attr_accessor :shopeepay
# Stripe users in Europe and the United States can use the [Payment Intents API](https://stripe.com/docs/payments/payment-intents)—a single integration path for creating payments using any supported method—to accept [Sofort](https://www.sofort.com/) payments from customers. Check this [page](https://stripe.com/docs/payments/sofort) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Sofort)) }
attr_accessor :sofort
# Swish is a [real-time](https://stripe.com/docs/payments/real-time) payment method popular in Sweden. It allows customers to [authenticate and approve](https://stripe.com/docs/payments/payment-methods#customer-actions) payments using the Swish mobile app and the Swedish BankID mobile app. Check this [page](https://stripe.com/docs/payments/swish) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Swish)) }
attr_accessor :swish
# Twint is a payment method popular in Switzerland. It allows customers to pay using their mobile phone. Check this [page](https://docs.stripe.com/payments/twint) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Twint)) }
attr_accessor :twint
# Stripe users in the United States can accept ACH direct debit payments from customers with a US bank account using the Automated Clearing House (ACH) payments system operated by Nacha. Check this [page](https://stripe.com/docs/payments/ach-direct-debit) for more details.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::UsBankAccount))
}
attr_accessor :us_bank_account
# WeChat, owned by Tencent, is China's leading mobile app with over 1 billion monthly active users. Chinese consumers can use WeChat Pay to pay for goods and services inside of businesses' apps and websites. WeChat Pay users buy most frequently in gaming, e-commerce, travel, online education, and food/nutrition. Check this [page](https://stripe.com/docs/payments/wechat-pay) for more details.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::WechatPay))
}
attr_accessor :wechat_pay
# Zip gives your customers a way to split purchases over a series of payments. Check this [page](https://stripe.com/docs/payments/zip) for more details like country availability.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Zip)) }
attr_accessor :zip
sig {
params(acss_debit: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::AcssDebit), affirm: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Affirm), afterpay_clearpay: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::AfterpayClearpay), alipay: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Alipay), alma: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Alma), amazon_pay: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::AmazonPay), apple_pay: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::ApplePay), apple_pay_later: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::ApplePayLater), au_becs_debit: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::AuBecsDebit), bacs_debit: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::BacsDebit), bancontact: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Bancontact), billie: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Billie), blik: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Blik), boleto: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Boleto), card: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Card), cartes_bancaires: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::CartesBancaires), cashapp: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Cashapp), customer_balance: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::CustomerBalance), eps: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Eps), expand: T.nilable(T::Array[String]), fpx: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Fpx), giropay: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Giropay), google_pay: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::GooglePay), gopay: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Gopay), grabpay: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Grabpay), id_bank_transfer: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::IdBankTransfer), ideal: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Ideal), jcb: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Jcb), kakao_pay: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::KakaoPay), klarna: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Klarna), konbini: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Konbini), kr_card: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::KrCard), link: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Link), mobilepay: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Mobilepay), multibanco: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Multibanco), name: T.nilable(String), naver_pay: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::NaverPay), nz_bank_account: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::NzBankAccount), oxxo: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Oxxo), p24: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::P24), parent: T.nilable(String), pay_by_bank: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::PayByBank), payco: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Payco), paynow: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Paynow), paypal: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Paypal), payto: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Payto), pix: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Pix), promptpay: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Promptpay), qris: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Qris), revolut_pay: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::RevolutPay), samsung_pay: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::SamsungPay), satispay: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Satispay), sepa_debit: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::SepaDebit), shopeepay: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Shopeepay), sofort: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Sofort), swish: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Swish), twint: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Twint), us_bank_account: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::UsBankAccount), wechat_pay: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::WechatPay), zip: T.nilable(::Stripe::PaymentMethodConfigurationService::CreateParams::Zip)).void
}
def initialize(
acss_debit: nil,
affirm: nil,
afterpay_clearpay: nil,
alipay: nil,
alma: nil,
amazon_pay: nil,
apple_pay: nil,
apple_pay_later: nil,
au_becs_debit: nil,
bacs_debit: nil,
bancontact: nil,
billie: nil,
blik: nil,
boleto: nil,
card: nil,
cartes_bancaires: nil,
cashapp: nil,
customer_balance: nil,
eps: nil,
expand: nil,
fpx: nil,
giropay: nil,
google_pay: nil,
gopay: nil,
grabpay: nil,
id_bank_transfer: nil,
ideal: nil,
jcb: nil,
kakao_pay: nil,
klarna: nil,
konbini: nil,
kr_card: nil,
link: nil,
mobilepay: nil,
multibanco: nil,
name: nil,
naver_pay: nil,
nz_bank_account: nil,
oxxo: nil,
p24: nil,
parent: nil,
pay_by_bank: nil,
payco: nil,
paynow: nil,
paypal: nil,
payto: nil,
pix: nil,
promptpay: nil,
qris: nil,
revolut_pay: nil,
samsung_pay: nil,
satispay: nil,
sepa_debit: nil,
shopeepay: nil,
sofort: nil,
swish: nil,
twint: nil,
us_bank_account: nil,
wechat_pay: nil,
zip: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
class AcssDebit < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::AcssDebit::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::AcssDebit::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Affirm < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Affirm::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Affirm::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class AfterpayClearpay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::AfterpayClearpay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::AfterpayClearpay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Alipay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Alipay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Alipay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Alma < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Alma::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Alma::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class AmazonPay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::AmazonPay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::AmazonPay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class ApplePay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::ApplePay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::ApplePay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class ApplePayLater < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::ApplePayLater::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::ApplePayLater::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class AuBecsDebit < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::AuBecsDebit::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::AuBecsDebit::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class BacsDebit < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::BacsDebit::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::BacsDebit::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Bancontact < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Bancontact::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Bancontact::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Billie < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Billie::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Billie::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Blik < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Blik::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Blik::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Boleto < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Boleto::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Boleto::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Card < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Card::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Card::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class CartesBancaires < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::CartesBancaires::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::CartesBancaires::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Cashapp < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Cashapp::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Cashapp::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class CustomerBalance < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::CustomerBalance::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::CustomerBalance::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Eps < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Eps::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Eps::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Fpx < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Fpx::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Fpx::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Giropay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Giropay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Giropay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class GooglePay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::GooglePay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::GooglePay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Gopay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Gopay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Gopay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Grabpay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Grabpay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Grabpay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class IdBankTransfer < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::IdBankTransfer::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::IdBankTransfer::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Ideal < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Ideal::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Ideal::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Jcb < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Jcb::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Jcb::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class KakaoPay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::KakaoPay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::KakaoPay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Klarna < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Klarna::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Klarna::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Konbini < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Konbini::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Konbini::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class KrCard < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::KrCard::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::KrCard::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Link < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Link::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Link::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Mobilepay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Mobilepay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Mobilepay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Multibanco < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Multibanco::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Multibanco::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class NaverPay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::NaverPay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::NaverPay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class NzBankAccount < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::NzBankAccount::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::NzBankAccount::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Oxxo < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Oxxo::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Oxxo::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class P24 < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::P24::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::P24::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class PayByBank < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::PayByBank::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::PayByBank::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Payco < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Payco::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Payco::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Paynow < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Paynow::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Paynow::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Paypal < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Paypal::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Paypal::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Payto < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Payto::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Payto::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Pix < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Pix::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Pix::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Promptpay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Promptpay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Promptpay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Qris < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Qris::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Qris::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class RevolutPay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::RevolutPay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::RevolutPay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class SamsungPay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::SamsungPay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::SamsungPay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Satispay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Satispay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Satispay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class SepaDebit < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::SepaDebit::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::SepaDebit::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Shopeepay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Shopeepay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Shopeepay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Sofort < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Sofort::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Sofort::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Swish < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Swish::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Swish::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Twint < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Twint::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Twint::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class UsBankAccount < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::UsBankAccount::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::UsBankAccount::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class WechatPay < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::WechatPay::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::WechatPay::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
class Zip < Stripe::RequestParams
class DisplayPreference < Stripe::RequestParams
# The account's preference for whether or not to display this payment method.
sig { returns(T.nilable(String)) }
attr_accessor :preference
sig { params(preference: T.nilable(String)).void }
def initialize(preference: nil); end
end
# Whether or not the payment method should be displayed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Zip::DisplayPreference))
}
attr_accessor :display_preference
sig {
params(display_preference: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Zip::DisplayPreference)).void
}
def initialize(display_preference: nil); end
end
# Canadian pre-authorized debit payments, check this [page](https://stripe.com/docs/payments/acss-debit) for more details like country availability.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::AcssDebit))
}
attr_accessor :acss_debit
# Whether the configuration can be used for new payments.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# [Affirm](https://www.affirm.com/) gives your customers a way to split purchases over a series of payments. Depending on the purchase, they can pay with four interest-free payments (Split Pay) or pay over a longer term (Installments), which might include interest. Check this [page](https://stripe.com/docs/payments/affirm) for more details like country availability.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Affirm)) }
attr_accessor :affirm
# Afterpay gives your customers a way to pay for purchases in installments, check this [page](https://stripe.com/docs/payments/afterpay-clearpay) for more details like country availability. Afterpay is particularly popular among businesses selling fashion, beauty, and sports products.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::AfterpayClearpay))
}
attr_accessor :afterpay_clearpay
# Alipay is a digital wallet in China that has more than a billion active users worldwide. Alipay users can pay on the web or on a mobile device using login credentials or their Alipay app. Alipay has a low dispute rate and reduces fraud by authenticating payments using the customer's login credentials. Check this [page](https://stripe.com/docs/payments/alipay) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Alipay)) }
attr_accessor :alipay
# Alma is a Buy Now, Pay Later payment method that offers customers the ability to pay in 2, 3, or 4 installments.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Alma)) }
attr_accessor :alma
# Amazon Pay is a wallet payment method that lets your customers check out the same way as on Amazon.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::AmazonPay))
}
attr_accessor :amazon_pay
# Stripe users can accept [Apple Pay](https://stripe.com/payments/apple-pay) in iOS applications in iOS 9 and later, and on the web in Safari starting with iOS 10 or macOS Sierra. There are no additional fees to process Apple Pay payments, and the [pricing](https://stripe.com/pricing) is the same as other card transactions. Check this [page](https://stripe.com/docs/apple-pay) for more details.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::ApplePay))
}
attr_accessor :apple_pay
# Apple Pay Later, a payment method for customers to buy now and pay later, gives your customers a way to split purchases into four installments across six weeks.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::ApplePayLater))
}
attr_accessor :apple_pay_later
# Stripe users in Australia can accept Bulk Electronic Clearing System (BECS) direct debit payments from customers with an Australian bank account. Check this [page](https://stripe.com/docs/payments/au-becs-debit) for more details.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::AuBecsDebit))
}
attr_accessor :au_becs_debit
# Stripe users in the UK can accept Bacs Direct Debit payments from customers with a UK bank account, check this [page](https://stripe.com/docs/payments/payment-methods/bacs-debit) for more details.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::BacsDebit))
}
attr_accessor :bacs_debit
# Bancontact is the most popular online payment method in Belgium, with over 15 million cards in circulation. [Customers](https://stripe.com/docs/api/customers) use a Bancontact card or mobile app linked to a Belgian bank account to make online payments that are secure, guaranteed, and confirmed immediately. Check this [page](https://stripe.com/docs/payments/bancontact) for more details.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Bancontact))
}
attr_accessor :bancontact
# Billie is a [single-use](https://docs.stripe.com/payments/payment-methods#usage) payment method that offers businesses Pay by Invoice where they offer payment terms ranging from 7-120 days. Customers are redirected from your website or app, authorize the payment with Billie, then return to your website or app. You get [immediate notification](/payments/payment-methods#payment-notification) of whether the payment succeeded or failed.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Billie)) }
attr_accessor :billie
# BLIK is a [single use](https://stripe.com/docs/payments/payment-methods#usage) payment method that requires customers to authenticate their payments. When customers want to pay online using BLIK, they request a six-digit code from their banking application and enter it into the payment collection form. Check this [page](https://stripe.com/docs/payments/blik) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Blik)) }
attr_accessor :blik
# Boleto is an official (regulated by the Central Bank of Brazil) payment method in Brazil. Check this [page](https://stripe.com/docs/payments/boleto) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Boleto)) }
attr_accessor :boleto
# Cards are a popular way for consumers and businesses to pay online or in person. Stripe supports global and local card networks.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Card)) }
attr_accessor :card
# Cartes Bancaires is France's local card network. More than 95% of these cards are co-branded with either Visa or Mastercard, meaning you can process these cards over either Cartes Bancaires or the Visa or Mastercard networks. Check this [page](https://stripe.com/docs/payments/cartes-bancaires) for more details.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::CartesBancaires))
}
attr_accessor :cartes_bancaires
# Cash App is a popular consumer app in the US that allows customers to bank, invest, send, and receive money using their digital wallet. Check this [page](https://stripe.com/docs/payments/cash-app-pay) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Cashapp)) }
attr_accessor :cashapp
# Uses a customer’s [cash balance](https://stripe.com/docs/payments/customer-balance) for the payment. The cash balance can be funded via a bank transfer. Check this [page](https://stripe.com/docs/payments/bank-transfers) for more details.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::CustomerBalance))
}
attr_accessor :customer_balance
# EPS is an Austria-based payment method that allows customers to complete transactions online using their bank credentials. EPS is supported by all Austrian banks and is accepted by over 80% of Austrian online retailers. Check this [page](https://stripe.com/docs/payments/eps) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Eps)) }
attr_accessor :eps
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Financial Process Exchange (FPX) is a Malaysia-based payment method that allows customers to complete transactions online using their bank credentials. Bank Negara Malaysia (BNM), the Central Bank of Malaysia, and eleven other major Malaysian financial institutions are members of the PayNet Group, which owns and operates FPX. It is one of the most popular online payment methods in Malaysia, with nearly 90 million transactions in 2018 according to BNM. Check this [page](https://stripe.com/docs/payments/fpx) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Fpx)) }
attr_accessor :fpx
# giropay is a German payment method based on online banking, introduced in 2006. It allows customers to complete transactions online using their online banking environment, with funds debited from their bank account. Depending on their bank, customers confirm payments on giropay using a second factor of authentication or a PIN. giropay accounts for 10% of online checkouts in Germany. Check this [page](https://stripe.com/docs/payments/giropay) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Giropay)) }
attr_accessor :giropay
# Google Pay allows customers to make payments in your app or website using any credit or debit card saved to their Google Account, including those from Google Play, YouTube, Chrome, or an Android device. Use the Google Pay API to request any credit or debit card stored in your customer's Google account. Check this [page](https://stripe.com/docs/google-pay) for more details.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::GooglePay))
}
attr_accessor :google_pay
# GoPay is a [single use](https://stripe.com/docs/payments/payment-methods#usage) digital wallet payment method popular in Indonesia. When paying with GoPay, customers authenticate and approve payments using the Gojek app. Desktop checkout is performed by scanning a QR code. When checking out on mobile, customers are redirected to the Gojek app to confirm payment.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Gopay)) }
attr_accessor :gopay
# GrabPay is a payment method developed by [Grab](https://www.grab.com/sg/consumer/finance/pay/). GrabPay is a digital wallet - customers maintain a balance in their wallets that they pay out with. Check this [page](https://stripe.com/docs/payments/grabpay) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Grabpay)) }
attr_accessor :grabpay
# Stripe users in Indonesia can receive bank transfers from customers in Indonesia. Bank transfers are a popular B2C and B2B payment method in Indonesia.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::IdBankTransfer))
}
attr_accessor :id_bank_transfer
# iDEAL is a Netherlands-based payment method that allows customers to complete transactions online using their bank credentials. All major Dutch banks are members of Currence, the scheme that operates iDEAL, making it the most popular online payment method in the Netherlands with a share of online transactions close to 55%. Check this [page](https://stripe.com/docs/payments/ideal) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Ideal)) }
attr_accessor :ideal
# JCB is a credit card company based in Japan. JCB is currently available in Japan to businesses approved by JCB, and available to all businesses in Australia, Canada, Hong Kong, Japan, New Zealand, Singapore, Switzerland, United Kingdom, United States, and all countries in the European Economic Area except Iceland. Check this [page](https://support.stripe.com/questions/accepting-japan-credit-bureau-%28jcb%29-payments) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Jcb)) }
attr_accessor :jcb
# Kakao Pay is a popular local wallet available in South Korea.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::KakaoPay))
}
attr_accessor :kakao_pay
# Klarna gives customers a range of [payment options](https://stripe.com/docs/payments/klarna#payment-options) during checkout. Available payment options vary depending on the customer's billing address and the transaction amount. These payment options make it convenient for customers to purchase items in all price ranges. Check this [page](https://stripe.com/docs/payments/klarna) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Klarna)) }
attr_accessor :klarna
# Konbini allows customers in Japan to pay for bills and online purchases at convenience stores with cash. Check this [page](https://stripe.com/docs/payments/konbini) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Konbini)) }
attr_accessor :konbini
# Korean cards let users pay using locally issued cards from South Korea.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::KrCard)) }
attr_accessor :kr_card
# [Link](https://stripe.com/docs/payments/link) is a payment method network. With Link, users save their payment details once, then reuse that information to pay with one click for any business on the network.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Link)) }
attr_accessor :link
# MobilePay is a [single-use](https://stripe.com/docs/payments/payment-methods#usage) card wallet payment method used in Denmark and Finland. It allows customers to [authenticate and approve](https://stripe.com/docs/payments/payment-methods#customer-actions) payments using the MobilePay app. Check this [page](https://stripe.com/docs/payments/mobilepay) for more details.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Mobilepay))
}
attr_accessor :mobilepay
# Stripe users in Europe and the United States can accept Multibanco payments from customers in Portugal using [Sources](https://stripe.com/docs/sources)—a single integration path for creating payments using any supported method.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Multibanco))
}
attr_accessor :multibanco
# Configuration name.
sig { returns(T.nilable(String)) }
attr_accessor :name
# Naver Pay is a popular local wallet available in South Korea.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::NaverPay))
}
attr_accessor :naver_pay
# Stripe users in New Zealand can accept Bulk Electronic Clearing System (BECS) direct debit payments from customers with a New Zeland bank account. Check this [page](https://stripe.com/docs/payments/nz-bank-account) for more details.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::NzBankAccount))
}
attr_accessor :nz_bank_account
# OXXO is a Mexican chain of convenience stores with thousands of locations across Latin America and represents nearly 20% of online transactions in Mexico. OXXO allows customers to pay bills and online purchases in-store with cash. Check this [page](https://stripe.com/docs/payments/oxxo) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Oxxo)) }
attr_accessor :oxxo
# Przelewy24 is a Poland-based payment method aggregator that allows customers to complete transactions online using bank transfers and other methods. Bank transfers account for 30% of online payments in Poland and Przelewy24 provides a way for customers to pay with over 165 banks. Check this [page](https://stripe.com/docs/payments/p24) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::P24)) }
attr_accessor :p24
# Pay by bank is a redirect payment method backed by bank transfers. A customer is redirected to their bank to authorize a bank transfer for a given amount. This removes a lot of the error risks inherent in waiting for the customer to initiate a transfer themselves, and is less expensive than card payments.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::PayByBank))
}
attr_accessor :pay_by_bank
# PAYCO is a [single-use](https://docs.stripe.com/payments/payment-methods#usage local wallet available in South Korea.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Payco)) }
attr_accessor :payco
# PayNow is a Singapore-based payment method that allows customers to make a payment using their preferred app from participating banks and participating non-bank financial institutions. Check this [page](https://stripe.com/docs/payments/paynow) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Paynow)) }
attr_accessor :paynow
# PayPal, a digital wallet popular with customers in Europe, allows your customers worldwide to pay using their PayPal account. Check this [page](https://stripe.com/docs/payments/paypal) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Paypal)) }
attr_accessor :paypal
# PayTo is a [real-time](https://docs.stripe.com/payments/real-time) payment method that enables customers in Australia to pay by providing their bank account details. Customers must accept a mandate authorizing you to debit their account. Check this [page](https://docs.stripe.com/payments/payto) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Payto)) }
attr_accessor :payto
# Pix is a payment method popular in Brazil. When paying with Pix, customers authenticate and approve payments by scanning a QR code in their preferred banking app. Check this [page](https://docs.stripe.com/payments/pix) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Pix)) }
attr_accessor :pix
# PromptPay is a Thailand-based payment method that allows customers to make a payment using their preferred app from participating banks. Check this [page](https://stripe.com/docs/payments/promptpay) for more details.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Promptpay))
}
attr_accessor :promptpay
# QRIS is a [real-time](https://docs.stripe.com/payments/real-time) payment method popular in Indonesia. When paying with QRIS, customers authenticate and approve payments by scanning a QR code in their preferred digital wallet app.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Qris)) }
attr_accessor :qris
# Revolut Pay, developed by Revolut, a global finance app, is a digital wallet payment method. Revolut Pay uses the customer’s stored balance or cards to fund the payment, and offers the option for non-Revolut customers to save their details after their first purchase.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::RevolutPay))
}
attr_accessor :revolut_pay
# Samsung Pay is a [single-use](https://docs.stripe.com/payments/payment-methods#usage local wallet available in South Korea.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::SamsungPay))
}
attr_accessor :samsung_pay
# Satispay is a [single-use](https://docs.stripe.com/payments/payment-methods#usage) payment method where customers are required to [authenticate](/payments/payment-methods#customer-actions) their payment. Customers pay by being redirected from your website or app, authorizing the payment with Satispay, then returning to your website or app. You get [immediate notification](/payments/payment-methods#payment-notification) of whether the payment succeeded or failed.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Satispay))
}
attr_accessor :satispay
# The [Single Euro Payments Area (SEPA)](https://en.wikipedia.org/wiki/Single_Euro_Payments_Area) is an initiative of the European Union to simplify payments within and across member countries. SEPA established and enforced banking standards to allow for the direct debiting of every EUR-denominated bank account within the SEPA region, check this [page](https://stripe.com/docs/payments/sepa-debit) for more details.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::SepaDebit))
}
attr_accessor :sepa_debit
# ShopeePay is a [single use](https://stripe.com/docs/payments/payment-methods#usage) digital wallet payment method popular in Indonesia. When paying with GoPay, customers authenticate and approve payments using the Shopee app. Desktop checkout is performed by scanning a QR code. When checking out on mobile, customers are redirected to the Shopee app to confirm payment.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Shopeepay))
}
attr_accessor :shopeepay
# Stripe users in Europe and the United States can use the [Payment Intents API](https://stripe.com/docs/payments/payment-intents)—a single integration path for creating payments using any supported method—to accept [Sofort](https://www.sofort.com/) payments from customers. Check this [page](https://stripe.com/docs/payments/sofort) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Sofort)) }
attr_accessor :sofort
# Swish is a [real-time](https://stripe.com/docs/payments/real-time) payment method popular in Sweden. It allows customers to [authenticate and approve](https://stripe.com/docs/payments/payment-methods#customer-actions) payments using the Swish mobile app and the Swedish BankID mobile app. Check this [page](https://stripe.com/docs/payments/swish) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Swish)) }
attr_accessor :swish
# Twint is a payment method popular in Switzerland. It allows customers to pay using their mobile phone. Check this [page](https://docs.stripe.com/payments/twint) for more details.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Twint)) }
attr_accessor :twint
# Stripe users in the United States can accept ACH direct debit payments from customers with a US bank account using the Automated Clearing House (ACH) payments system operated by Nacha. Check this [page](https://stripe.com/docs/payments/ach-direct-debit) for more details.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::UsBankAccount))
}
attr_accessor :us_bank_account
# WeChat, owned by Tencent, is China's leading mobile app with over 1 billion monthly active users. Chinese consumers can use WeChat Pay to pay for goods and services inside of businesses' apps and websites. WeChat Pay users buy most frequently in gaming, e-commerce, travel, online education, and food/nutrition. Check this [page](https://stripe.com/docs/payments/wechat-pay) for more details.
sig {
returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::WechatPay))
}
attr_accessor :wechat_pay
# Zip gives your customers a way to split purchases over a series of payments. Check this [page](https://stripe.com/docs/payments/zip) for more details like country availability.
sig { returns(T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Zip)) }
attr_accessor :zip
sig {
params(acss_debit: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::AcssDebit), active: T.nilable(T::Boolean), affirm: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Affirm), afterpay_clearpay: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::AfterpayClearpay), alipay: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Alipay), alma: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Alma), amazon_pay: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::AmazonPay), apple_pay: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::ApplePay), apple_pay_later: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::ApplePayLater), au_becs_debit: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::AuBecsDebit), bacs_debit: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::BacsDebit), bancontact: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Bancontact), billie: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Billie), blik: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Blik), boleto: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Boleto), card: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Card), cartes_bancaires: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::CartesBancaires), cashapp: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Cashapp), customer_balance: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::CustomerBalance), eps: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Eps), expand: T.nilable(T::Array[String]), fpx: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Fpx), giropay: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Giropay), google_pay: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::GooglePay), gopay: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Gopay), grabpay: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Grabpay), id_bank_transfer: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::IdBankTransfer), ideal: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Ideal), jcb: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Jcb), kakao_pay: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::KakaoPay), klarna: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Klarna), konbini: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Konbini), kr_card: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::KrCard), link: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Link), mobilepay: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Mobilepay), multibanco: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Multibanco), name: T.nilable(String), naver_pay: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::NaverPay), nz_bank_account: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::NzBankAccount), oxxo: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Oxxo), p24: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::P24), pay_by_bank: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::PayByBank), payco: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Payco), paynow: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Paynow), paypal: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Paypal), payto: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Payto), pix: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Pix), promptpay: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Promptpay), qris: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Qris), revolut_pay: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::RevolutPay), samsung_pay: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::SamsungPay), satispay: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Satispay), sepa_debit: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::SepaDebit), shopeepay: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Shopeepay), sofort: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Sofort), swish: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Swish), twint: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Twint), us_bank_account: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::UsBankAccount), wechat_pay: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::WechatPay), zip: T.nilable(::Stripe::PaymentMethodConfigurationService::UpdateParams::Zip)).void
}
def initialize(
acss_debit: nil,
active: nil,
affirm: nil,
afterpay_clearpay: nil,
alipay: nil,
alma: nil,
amazon_pay: nil,
apple_pay: nil,
apple_pay_later: nil,
au_becs_debit: nil,
bacs_debit: nil,
bancontact: nil,
billie: nil,
blik: nil,
boleto: nil,
card: nil,
cartes_bancaires: nil,
cashapp: nil,
customer_balance: nil,
eps: nil,
expand: nil,
fpx: nil,
giropay: nil,
google_pay: nil,
gopay: nil,
grabpay: nil,
id_bank_transfer: nil,
ideal: nil,
jcb: nil,
kakao_pay: nil,
klarna: nil,
konbini: nil,
kr_card: nil,
link: nil,
mobilepay: nil,
multibanco: nil,
name: nil,
naver_pay: nil,
nz_bank_account: nil,
oxxo: nil,
p24: nil,
pay_by_bank: nil,
payco: nil,
paynow: nil,
paypal: nil,
payto: nil,
pix: nil,
promptpay: nil,
qris: nil,
revolut_pay: nil,
samsung_pay: nil,
satispay: nil,
sepa_debit: nil,
shopeepay: nil,
sofort: nil,
swish: nil,
twint: nil,
us_bank_account: nil,
wechat_pay: nil,
zip: nil
); end
end
# Creates a payment method configuration
sig {
params(params: T.any(::Stripe::PaymentMethodConfigurationService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentMethodConfiguration)
}
def create(params = {}, opts = {}); end
# List payment method configurations
sig {
params(params: T.any(::Stripe::PaymentMethodConfigurationService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieve payment method configuration
sig {
params(configuration: String, params: T.any(::Stripe::PaymentMethodConfigurationService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentMethodConfiguration)
}
def retrieve(configuration, params = {}, opts = {}); end
# Update payment method configuration
sig {
params(configuration: String, params: T.any(::Stripe::PaymentMethodConfigurationService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentMethodConfiguration)
}
def update(configuration, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class PaymentMethodDomainService < StripeService
class ListParams < Stripe::RequestParams
# The domain name that this payment method domain object represents.
sig { returns(T.nilable(String)) }
attr_accessor :domain_name
# Whether this payment method domain is enabled. If the domain is not enabled, payment methods will not appear in Elements or Embedded Checkout
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :enabled
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(domain_name: T.nilable(String), enabled: T.nilable(T::Boolean), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
domain_name: nil,
enabled: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
# The domain name that this payment method domain object represents.
sig { returns(String) }
attr_accessor :domain_name
# Whether this payment method domain is enabled. If the domain is not enabled, payment methods that require a payment method domain will not appear in Elements or Embedded Checkout.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :enabled
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig {
params(domain_name: String, enabled: T.nilable(T::Boolean), expand: T.nilable(T::Array[String])).void
}
def initialize(domain_name: nil, enabled: nil, expand: nil); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
# Whether this payment method domain is enabled. If the domain is not enabled, payment methods that require a payment method domain will not appear in Elements or Embedded Checkout.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :enabled
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(enabled: T.nilable(T::Boolean), expand: T.nilable(T::Array[String])).void }
def initialize(enabled: nil, expand: nil); end
end
class ValidateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Creates a payment method domain.
sig {
params(params: T.any(::Stripe::PaymentMethodDomainService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentMethodDomain)
}
def create(params = {}, opts = {}); end
# Lists the details of existing payment method domains.
sig {
params(params: T.any(::Stripe::PaymentMethodDomainService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the details of an existing payment method domain.
sig {
params(payment_method_domain: String, params: T.any(::Stripe::PaymentMethodDomainService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentMethodDomain)
}
def retrieve(payment_method_domain, params = {}, opts = {}); end
# Updates an existing payment method domain.
sig {
params(payment_method_domain: String, params: T.any(::Stripe::PaymentMethodDomainService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentMethodDomain)
}
def update(payment_method_domain, params = {}, opts = {}); end
# Some payment methods might require additional steps to register a domain. If the requirements weren't satisfied when the domain was created, the payment method will be inactive on the domain.
# The payment method doesn't appear in Elements or Embedded Checkout for this domain until it is active.
#
# To activate a payment method on an existing payment method domain, complete the required registration steps specific to the payment method, and then validate the payment method domain with this endpoint.
#
# Related guides: [Payment method domains](https://docs.stripe.com/docs/payments/payment-methods/pmd-registration).
sig {
params(payment_method_domain: String, params: T.any(::Stripe::PaymentMethodDomainService::ValidateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentMethodDomain)
}
def validate(payment_method_domain, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class PaymentRecordService < StripeService
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class ReportPaymentAttemptParams < Stripe::RequestParams
class Failed < Stripe::RequestParams
# When the reported payment failed. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :failed_at
sig { params(failed_at: Integer).void }
def initialize(failed_at: nil); end
end
class Guaranteed < Stripe::RequestParams
# When the reported payment was guaranteed. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :guaranteed_at
sig { params(guaranteed_at: Integer).void }
def initialize(guaranteed_at: nil); end
end
class PaymentMethodDetails < Stripe::RequestParams
class BillingDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# The billing address associated with the method of payment.
sig {
returns(T.nilable(::Stripe::PaymentRecordService::ReportPaymentAttemptParams::PaymentMethodDetails::BillingDetails::Address))
}
attr_accessor :address
# The billing email associated with the method of payment.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The billing name associated with the method of payment.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The billing phone number associated with the method of payment.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(address: T.nilable(::Stripe::PaymentRecordService::ReportPaymentAttemptParams::PaymentMethodDetails::BillingDetails::Address), email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(address: nil, email: nil, name: nil, phone: nil); end
end
class Custom < Stripe::RequestParams
# Display name for the custom (user-defined) payment method type used to make this payment.
sig { returns(T.nilable(String)) }
attr_accessor :display_name
# The custom payment method type associated with this payment.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig { params(display_name: T.nilable(String), type: T.nilable(String)).void }
def initialize(display_name: nil, type: nil); end
end
# The billing details associated with the method of payment.
sig {
returns(T.nilable(::Stripe::PaymentRecordService::ReportPaymentAttemptParams::PaymentMethodDetails::BillingDetails))
}
attr_accessor :billing_details
# Information about the custom (user-defined) payment method used to make this payment.
sig {
returns(T.nilable(::Stripe::PaymentRecordService::ReportPaymentAttemptParams::PaymentMethodDetails::Custom))
}
attr_accessor :custom
# ID of the Stripe Payment Method used to make this payment.
sig { returns(T.nilable(String)) }
attr_accessor :payment_method
# The type of the payment method details. An additional hash is included on the payment_method_details with a name matching this value. It contains additional information specific to the type.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(billing_details: T.nilable(::Stripe::PaymentRecordService::ReportPaymentAttemptParams::PaymentMethodDetails::BillingDetails), custom: T.nilable(::Stripe::PaymentRecordService::ReportPaymentAttemptParams::PaymentMethodDetails::Custom), payment_method: T.nilable(String), type: T.nilable(String)).void
}
def initialize(billing_details: nil, custom: nil, payment_method: nil, type: nil); end
end
class ShippingDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# The physical shipping address.
sig {
returns(T.nilable(::Stripe::PaymentRecordService::ReportPaymentAttemptParams::ShippingDetails::Address))
}
attr_accessor :address
# The shipping recipient's name.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The shipping recipient's phone number.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(address: T.nilable(::Stripe::PaymentRecordService::ReportPaymentAttemptParams::ShippingDetails::Address), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(address: nil, name: nil, phone: nil); end
end
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Information about the payment attempt failure.
sig { returns(T.nilable(::Stripe::PaymentRecordService::ReportPaymentAttemptParams::Failed)) }
attr_accessor :failed
# Information about the payment attempt guarantee.
sig {
returns(T.nilable(::Stripe::PaymentRecordService::ReportPaymentAttemptParams::Guaranteed))
}
attr_accessor :guaranteed
# When the reported payment was initiated. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :initiated_at
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# The outcome of the reported payment.
sig { returns(T.nilable(String)) }
attr_accessor :outcome
# Information about the Payment Method debited for this payment.
sig {
returns(T.nilable(::Stripe::PaymentRecordService::ReportPaymentAttemptParams::PaymentMethodDetails))
}
attr_accessor :payment_method_details
# Shipping information for this payment.
sig {
returns(T.nilable(::Stripe::PaymentRecordService::ReportPaymentAttemptParams::ShippingDetails))
}
attr_accessor :shipping_details
sig {
params(description: T.nilable(String), expand: T.nilable(T::Array[String]), failed: T.nilable(::Stripe::PaymentRecordService::ReportPaymentAttemptParams::Failed), guaranteed: T.nilable(::Stripe::PaymentRecordService::ReportPaymentAttemptParams::Guaranteed), initiated_at: Integer, metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), outcome: T.nilable(String), payment_method_details: T.nilable(::Stripe::PaymentRecordService::ReportPaymentAttemptParams::PaymentMethodDetails), shipping_details: T.nilable(::Stripe::PaymentRecordService::ReportPaymentAttemptParams::ShippingDetails)).void
}
def initialize(
description: nil,
expand: nil,
failed: nil,
guaranteed: nil,
initiated_at: nil,
metadata: nil,
outcome: nil,
payment_method_details: nil,
shipping_details: nil
); end
end
class ReportPaymentAttemptCanceledParams < Stripe::RequestParams
# When the reported payment was canceled. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :canceled_at
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Attribute for param field metadata
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
sig {
params(canceled_at: Integer, expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String])))).void
}
def initialize(canceled_at: nil, expand: nil, metadata: nil); end
end
class ReportPaymentAttemptFailedParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# When the reported payment failed. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :failed_at
# Attribute for param field metadata
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
sig {
params(expand: T.nilable(T::Array[String]), failed_at: Integer, metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String])))).void
}
def initialize(expand: nil, failed_at: nil, metadata: nil); end
end
class ReportPaymentAttemptGuaranteedParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# When the reported payment was guaranteed. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :guaranteed_at
# Attribute for param field metadata
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
sig {
params(expand: T.nilable(T::Array[String]), guaranteed_at: Integer, metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String])))).void
}
def initialize(expand: nil, guaranteed_at: nil, metadata: nil); end
end
class ReportPaymentParams < Stripe::RequestParams
class AmountRequested < Stripe::RequestParams
# 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).
sig { returns(String) }
attr_accessor :currency
# A positive integer representing the amount in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) for example, 100 cents for 1 USD or 100 for 100 JPY, a zero-decimal currency.
sig { returns(Integer) }
attr_accessor :value
sig { params(currency: String, value: Integer).void }
def initialize(currency: nil, value: nil); end
end
class CustomerDetails < Stripe::RequestParams
# The customer who made the payment.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# The customer's phone number.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The customer's name.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The customer's phone number.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(customer: T.nilable(String), email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(customer: nil, email: nil, name: nil, phone: nil); end
end
class Failed < Stripe::RequestParams
# When the reported payment failed. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :failed_at
sig { params(failed_at: Integer).void }
def initialize(failed_at: nil); end
end
class Guaranteed < Stripe::RequestParams
# When the reported payment was guaranteed. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :guaranteed_at
sig { params(guaranteed_at: Integer).void }
def initialize(guaranteed_at: nil); end
end
class PaymentMethodDetails < Stripe::RequestParams
class BillingDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# The billing address associated with the method of payment.
sig {
returns(T.nilable(::Stripe::PaymentRecordService::ReportPaymentParams::PaymentMethodDetails::BillingDetails::Address))
}
attr_accessor :address
# The billing email associated with the method of payment.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The billing name associated with the method of payment.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The billing phone number associated with the method of payment.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(address: T.nilable(::Stripe::PaymentRecordService::ReportPaymentParams::PaymentMethodDetails::BillingDetails::Address), email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(address: nil, email: nil, name: nil, phone: nil); end
end
class Custom < Stripe::RequestParams
# Display name for the custom (user-defined) payment method type used to make this payment.
sig { returns(T.nilable(String)) }
attr_accessor :display_name
# The custom payment method type associated with this payment.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig { params(display_name: T.nilable(String), type: T.nilable(String)).void }
def initialize(display_name: nil, type: nil); end
end
# The billing details associated with the method of payment.
sig {
returns(T.nilable(::Stripe::PaymentRecordService::ReportPaymentParams::PaymentMethodDetails::BillingDetails))
}
attr_accessor :billing_details
# Information about the custom (user-defined) payment method used to make this payment.
sig {
returns(T.nilable(::Stripe::PaymentRecordService::ReportPaymentParams::PaymentMethodDetails::Custom))
}
attr_accessor :custom
# ID of the Stripe Payment Method used to make this payment.
sig { returns(T.nilable(String)) }
attr_accessor :payment_method
# The type of the payment method details. An additional hash is included on the payment_method_details with a name matching this value. It contains additional information specific to the type.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(billing_details: T.nilable(::Stripe::PaymentRecordService::ReportPaymentParams::PaymentMethodDetails::BillingDetails), custom: T.nilable(::Stripe::PaymentRecordService::ReportPaymentParams::PaymentMethodDetails::Custom), payment_method: T.nilable(String), type: T.nilable(String)).void
}
def initialize(billing_details: nil, custom: nil, payment_method: nil, type: nil); end
end
class ShippingDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# The physical shipping address.
sig {
returns(T.nilable(::Stripe::PaymentRecordService::ReportPaymentParams::ShippingDetails::Address))
}
attr_accessor :address
# The shipping recipient's name.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The shipping recipient's phone number.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(address: T.nilable(::Stripe::PaymentRecordService::ReportPaymentParams::ShippingDetails::Address), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(address: nil, name: nil, phone: nil); end
end
# The amount you initially requested for this payment.
sig { returns(::Stripe::PaymentRecordService::ReportPaymentParams::AmountRequested) }
attr_accessor :amount_requested
# Customer information for this payment.
sig {
returns(T.nilable(::Stripe::PaymentRecordService::ReportPaymentParams::CustomerDetails))
}
attr_accessor :customer_details
# Indicates whether the customer was present in your checkout flow during this payment.
sig { returns(T.nilable(String)) }
attr_accessor :customer_presence
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Information about the payment attempt failure.
sig { returns(T.nilable(::Stripe::PaymentRecordService::ReportPaymentParams::Failed)) }
attr_accessor :failed
# Information about the payment attempt guarantee.
sig { returns(T.nilable(::Stripe::PaymentRecordService::ReportPaymentParams::Guaranteed)) }
attr_accessor :guaranteed
# When the reported payment was initiated. Measured in seconds since the Unix epoch.
sig { returns(Integer) }
attr_accessor :initiated_at
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# The outcome of the reported payment.
sig { returns(T.nilable(String)) }
attr_accessor :outcome
# Information about the Payment Method debited for this payment.
sig { returns(::Stripe::PaymentRecordService::ReportPaymentParams::PaymentMethodDetails) }
attr_accessor :payment_method_details
# An opaque string for manual reconciliation of this payment, for example a check number or a payment processor ID.
sig { returns(T.nilable(String)) }
attr_accessor :payment_reference
# Shipping information for this payment.
sig {
returns(T.nilable(::Stripe::PaymentRecordService::ReportPaymentParams::ShippingDetails))
}
attr_accessor :shipping_details
sig {
params(amount_requested: ::Stripe::PaymentRecordService::ReportPaymentParams::AmountRequested, customer_details: T.nilable(::Stripe::PaymentRecordService::ReportPaymentParams::CustomerDetails), customer_presence: T.nilable(String), description: T.nilable(String), expand: T.nilable(T::Array[String]), failed: T.nilable(::Stripe::PaymentRecordService::ReportPaymentParams::Failed), guaranteed: T.nilable(::Stripe::PaymentRecordService::ReportPaymentParams::Guaranteed), initiated_at: Integer, metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), outcome: T.nilable(String), payment_method_details: ::Stripe::PaymentRecordService::ReportPaymentParams::PaymentMethodDetails, payment_reference: T.nilable(String), shipping_details: T.nilable(::Stripe::PaymentRecordService::ReportPaymentParams::ShippingDetails)).void
}
def initialize(
amount_requested: nil,
customer_details: nil,
customer_presence: nil,
description: nil,
expand: nil,
failed: nil,
guaranteed: nil,
initiated_at: nil,
metadata: nil,
outcome: nil,
payment_method_details: nil,
payment_reference: nil,
shipping_details: nil
); end
end
# Report a new Payment Record. You may report a Payment Record as it is
# initialized and later report updates through the other report_* methods, or report Payment
# Records in a terminal state directly, through this method.
sig {
params(params: T.any(::Stripe::PaymentRecordService::ReportPaymentParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentRecord)
}
def report_payment(params = {}, opts = {}); end
# Report a new payment attempt on the specified Payment Record. A new payment
# attempt can only be specified if all other payment attempts are canceled or failed.
sig {
params(id: String, params: T.any(::Stripe::PaymentRecordService::ReportPaymentAttemptParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentRecord)
}
def report_payment_attempt(id, params = {}, opts = {}); end
# Report that the most recent payment attempt on the specified Payment Record
# was canceled.
sig {
params(id: String, params: T.any(::Stripe::PaymentRecordService::ReportPaymentAttemptCanceledParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentRecord)
}
def report_payment_attempt_canceled(id, params = {}, opts = {}); end
# Report that the most recent payment attempt on the specified Payment Record
# failed or errored.
sig {
params(id: String, params: T.any(::Stripe::PaymentRecordService::ReportPaymentAttemptFailedParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentRecord)
}
def report_payment_attempt_failed(id, params = {}, opts = {}); end
# Report that the most recent payment attempt on the specified Payment Record
# was guaranteed.
sig {
params(id: String, params: T.any(::Stripe::PaymentRecordService::ReportPaymentAttemptGuaranteedParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentRecord)
}
def report_payment_attempt_guaranteed(id, params = {}, opts = {}); end
# Retrieves a Payment Record with the given ID
sig {
params(id: String, params: T.any(::Stripe::PaymentRecordService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PaymentRecord)
}
def retrieve(id, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class PayoutService < StripeService
class ListParams < Stripe::RequestParams
class ArrivalDate < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return payouts that are expected to arrive during the given date interval.
sig { returns(T.nilable(T.any(::Stripe::PayoutService::ListParams::ArrivalDate, Integer))) }
attr_accessor :arrival_date
# Only return payouts that were created during the given date interval.
sig { returns(T.nilable(T.any(::Stripe::PayoutService::ListParams::Created, Integer))) }
attr_accessor :created
# The ID of an external account - only return payouts sent to this external account.
sig { returns(T.nilable(String)) }
attr_accessor :destination
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return payouts that have the given status: `pending`, `paid`, `failed`, or `canceled`.
sig { returns(T.nilable(String)) }
attr_accessor :status
sig {
params(arrival_date: T.nilable(T.any(::Stripe::PayoutService::ListParams::ArrivalDate, Integer)), created: T.nilable(T.any(::Stripe::PayoutService::ListParams::Created, Integer)), destination: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String), status: T.nilable(String)).void
}
def initialize(
arrival_date: nil,
created: nil,
destination: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil,
status: nil
); end
end
class CreateParams < Stripe::RequestParams
# A positive integer in cents representing how much to payout.
sig { returns(Integer) }
attr_accessor :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).
sig { returns(String) }
attr_accessor :currency
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# The ID of a bank account or a card to send the payout to. If you don't provide a destination, we use the default external account for the specified currency.
sig { returns(T.nilable(String)) }
attr_accessor :destination
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The method used to send this payout, which is `standard` or `instant`. We support `instant` for payouts to debit cards and bank accounts in certain countries. Learn more about [bank support for Instant Payouts](https://stripe.com/docs/payouts/instant-payouts-banks).
sig { returns(T.nilable(String)) }
attr_accessor :method
# The ID of a v2 FinancialAccount to send funds to.
sig { returns(T.nilable(String)) }
attr_accessor :payout_method
# The balance type of your Stripe balance to draw this payout from. Balances for different payment sources are kept separately. You can find the amounts with the Balances API. One of `bank_account`, `card`, or `fpx`.
sig { returns(T.nilable(String)) }
attr_accessor :source_type
# A string that displays on the recipient's bank or card statement (up to 22 characters). A `statement_descriptor` that's longer than 22 characters return an error. Most banks truncate this information and display it inconsistently. Some banks might not display it at all.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
sig {
params(amount: Integer, currency: String, description: T.nilable(String), destination: T.nilable(String), expand: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), method: T.nilable(String), payout_method: T.nilable(String), source_type: T.nilable(String), statement_descriptor: T.nilable(String)).void
}
def initialize(
amount: nil,
currency: nil,
description: nil,
destination: nil,
expand: nil,
metadata: nil,
method: nil,
payout_method: nil,
source_type: nil,
statement_descriptor: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
sig {
params(expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String])))).void
}
def initialize(expand: nil, metadata: nil); end
end
class CancelParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class ReverseParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
sig {
params(expand: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String])).void
}
def initialize(expand: nil, metadata: nil); end
end
# You can cancel a previously created payout if its status is pending. Stripe refunds the funds to your available balance. You can't cancel automatic Stripe payouts.
sig {
params(payout: String, params: T.any(::Stripe::PayoutService::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Payout)
}
def cancel(payout, params = {}, opts = {}); end
# To send funds to your own bank account, create a new payout object. Your [Stripe balance](https://docs.stripe.com/api#balance) must cover the payout amount. If it doesn't, you receive an “Insufficient Funds” error.
#
# If your API key is in test mode, money won't actually be sent, though every other action occurs as if you're in live mode.
#
# If you create a manual payout on a Stripe account that uses multiple payment source types, you need to specify the source type balance that the payout draws from. The [balance object](https://docs.stripe.com/api#balance_object) details available and pending amounts by source type.
sig {
params(params: T.any(::Stripe::PayoutService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Payout)
}
def create(params = {}, opts = {}); end
# Returns a list of existing payouts sent to third-party bank accounts or payouts that Stripe sent to you. The payouts return in sorted order, with the most recently created payouts appearing first.
sig {
params(params: T.any(::Stripe::PayoutService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the details of an existing payout. Supply the unique payout ID from either a payout creation request or the payout list. Stripe returns the corresponding payout information.
sig {
params(payout: String, params: T.any(::Stripe::PayoutService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Payout)
}
def retrieve(payout, params = {}, opts = {}); end
# Reverses a payout by debiting the destination bank account. At this time, you can only reverse payouts for connected accounts to US bank accounts. If the payout is manual and in the pending status, use /v1/payouts/:id/cancel instead.
#
# By requesting a reversal through /v1/payouts/:id/reverse, you confirm that the authorized signatory of the selected bank account authorizes the debit on the bank account and that no other authorization is required.
sig {
params(payout: String, params: T.any(::Stripe::PayoutService::ReverseParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Payout)
}
def reverse(payout, params = {}, opts = {}); end
# Updates the specified payout by setting the values of the parameters you pass. We don't change parameters that you don't provide. This request only accepts the metadata as arguments.
sig {
params(payout: String, params: T.any(::Stripe::PayoutService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Payout)
}
def update(payout, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class PlanService < StripeService
class DeleteParams < Stripe::RequestParams; end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
# Whether the plan is currently available for new subscriptions.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# A brief description of the plan, hidden from customers.
sig { returns(T.nilable(String)) }
attr_accessor :nickname
# The product the plan belongs to. This cannot be changed once it has been used in a subscription or subscription schedule.
sig { returns(T.nilable(String)) }
attr_accessor :product
# Default number of trial days when subscribing a customer to this plan using [`trial_from_plan=true`](https://stripe.com/docs/api#create_subscription-trial_from_plan).
sig { returns(T.nilable(Integer)) }
attr_accessor :trial_period_days
sig {
params(active: T.nilable(T::Boolean), expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), nickname: T.nilable(String), product: T.nilable(String), trial_period_days: T.nilable(Integer)).void
}
def initialize(
active: nil,
expand: nil,
metadata: nil,
nickname: nil,
product: nil,
trial_period_days: nil
); end
end
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return plans that are active or inactive (e.g., pass `false` to list all inactive plans).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.
sig { returns(T.nilable(T.any(::Stripe::PlanService::ListParams::Created, Integer))) }
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Only return plans for the given product.
sig { returns(T.nilable(String)) }
attr_accessor :product
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(active: T.nilable(T::Boolean), created: T.nilable(T.any(::Stripe::PlanService::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), product: T.nilable(String), starting_after: T.nilable(String)).void
}
def initialize(
active: nil,
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
product: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class Product < Stripe::RequestParams
# Whether the product is currently available for purchase. Defaults to `true`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# The identifier for the product. Must be unique. If not provided, an identifier will be randomly generated.
sig { returns(T.nilable(String)) }
attr_accessor :id
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The product's name, meant to be displayable to the customer.
sig { returns(String) }
attr_accessor :name
# An arbitrary string to be displayed on your customer's credit card or bank statement. While most banks display this information consistently, some may display it incorrectly or not at all.
#
# This may be up to 22 characters. The statement description may not include `<`, `>`, `\`, `"`, `'` characters, and will appear on your customer's statement in capital letters. Non-ASCII characters are automatically stripped.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
sig { returns(T.nilable(String)) }
attr_accessor :tax_code
# A label that represents units of this product. When set, this will be included in customers' receipts, invoices, Checkout, and the customer portal.
sig { returns(T.nilable(String)) }
attr_accessor :unit_label
sig {
params(active: T.nilable(T::Boolean), id: T.nilable(String), metadata: T.nilable(T::Hash[String, String]), name: String, statement_descriptor: T.nilable(String), tax_code: T.nilable(String), unit_label: T.nilable(String)).void
}
def initialize(
active: nil,
id: nil,
metadata: nil,
name: nil,
statement_descriptor: nil,
tax_code: nil,
unit_label: nil
); end
end
class Tier < Stripe::RequestParams
# The flat billing amount for an entire tier, regardless of the number of units in the tier.
sig { returns(T.nilable(Integer)) }
attr_accessor :flat_amount
# Same as `flat_amount`, but accepts a decimal value representing an integer in the minor units of the currency. Only one of `flat_amount` and `flat_amount_decimal` can be set.
sig { returns(T.nilable(String)) }
attr_accessor :flat_amount_decimal
# The per unit billing amount for each individual unit for which this tier applies.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
# Specifies the upper bound of this tier. The lower bound of a tier is the upper bound of the previous tier adding one. Use `inf` to define a fallback tier.
sig { returns(T.any(String, Integer)) }
attr_accessor :up_to
sig {
params(flat_amount: T.nilable(Integer), flat_amount_decimal: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String), up_to: T.any(String, Integer)).void
}
def initialize(
flat_amount: nil,
flat_amount_decimal: nil,
unit_amount: nil,
unit_amount_decimal: nil,
up_to: nil
); end
end
class TransformUsage < Stripe::RequestParams
# Divide usage by this number.
sig { returns(Integer) }
attr_accessor :divide_by
# After division, either round the result `up` or `down`.
sig { returns(String) }
attr_accessor :round
sig { params(divide_by: Integer, round: String).void }
def initialize(divide_by: nil, round: nil); end
end
# Whether the plan is currently available for new subscriptions. Defaults to `true`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# A positive integer in cents (or local equivalent) (or 0 for a free plan) representing how much to charge on a recurring basis.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# Same as `amount`, but accepts a decimal value with at most 12 decimal places. Only one of `amount` and `amount_decimal` can be set.
sig { returns(T.nilable(String)) }
attr_accessor :amount_decimal
# Describes how to compute the price per period. Either `per_unit` or `tiered`. `per_unit` indicates that the fixed amount (specified in `amount`) will be charged per unit in `quantity` (for plans with `usage_type=licensed`), or per unit of total usage (for plans with `usage_type=metered`). `tiered` indicates that the unit pricing will be computed using a tiering strategy as defined using the `tiers` and `tiers_mode` attributes.
sig { returns(T.nilable(String)) }
attr_accessor :billing_scheme
# 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).
sig { returns(String) }
attr_accessor :currency
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# An identifier randomly generated by Stripe. Used to identify this plan when subscribing a customer. You can optionally override this ID, but the ID must be unique across all plans in your Stripe account. You can, however, use the same plan ID in both live and test modes.
sig { returns(T.nilable(String)) }
attr_accessor :id
# Specifies billing frequency. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_count
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# The meter tracking the usage of a metered price
sig { returns(T.nilable(String)) }
attr_accessor :meter
# A brief description of the plan, hidden from customers.
sig { returns(T.nilable(String)) }
attr_accessor :nickname
# Attribute for param field product
sig { returns(T.nilable(T.any(::Stripe::PlanService::CreateParams::Product, String))) }
attr_accessor :product
# Each element represents a pricing tier. This parameter requires `billing_scheme` to be set to `tiered`. See also the documentation for `billing_scheme`.
sig { returns(T.nilable(T::Array[::Stripe::PlanService::CreateParams::Tier])) }
attr_accessor :tiers
# Defines if the tiering price should be `graduated` or `volume` based. In `volume`-based tiering, the maximum quantity within a period determines the per unit price, in `graduated` tiering pricing can successively change as the quantity grows.
sig { returns(T.nilable(String)) }
attr_accessor :tiers_mode
# Apply a transformation to the reported usage or set quantity before computing the billed price. Cannot be combined with `tiers`.
sig { returns(T.nilable(::Stripe::PlanService::CreateParams::TransformUsage)) }
attr_accessor :transform_usage
# Default number of trial days when subscribing a customer to this plan using [`trial_from_plan=true`](https://stripe.com/docs/api#create_subscription-trial_from_plan).
sig { returns(T.nilable(Integer)) }
attr_accessor :trial_period_days
# Configures how the quantity per period should be determined. Can be either `metered` or `licensed`. `licensed` automatically bills the `quantity` set when adding it to a subscription. `metered` aggregates the total usage based on usage records. Defaults to `licensed`.
sig { returns(T.nilable(String)) }
attr_accessor :usage_type
sig {
params(active: T.nilable(T::Boolean), amount: T.nilable(Integer), amount_decimal: T.nilable(String), billing_scheme: T.nilable(String), currency: String, expand: T.nilable(T::Array[String]), id: T.nilable(String), interval: String, interval_count: T.nilable(Integer), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), meter: T.nilable(String), nickname: T.nilable(String), product: T.nilable(T.any(::Stripe::PlanService::CreateParams::Product, String)), tiers: T.nilable(T::Array[::Stripe::PlanService::CreateParams::Tier]), tiers_mode: T.nilable(String), transform_usage: T.nilable(::Stripe::PlanService::CreateParams::TransformUsage), trial_period_days: T.nilable(Integer), usage_type: T.nilable(String)).void
}
def initialize(
active: nil,
amount: nil,
amount_decimal: nil,
billing_scheme: nil,
currency: nil,
expand: nil,
id: nil,
interval: nil,
interval_count: nil,
metadata: nil,
meter: nil,
nickname: nil,
product: nil,
tiers: nil,
tiers_mode: nil,
transform_usage: nil,
trial_period_days: nil,
usage_type: nil
); end
end
# You can now model subscriptions more flexibly using the [Prices API](https://docs.stripe.com/api#prices). It replaces the Plans API and is backwards compatible to simplify your migration.
sig {
params(params: T.any(::Stripe::PlanService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Plan)
}
def create(params = {}, opts = {}); end
# Deleting plans means new subscribers can't be added. Existing subscribers aren't affected.
sig {
params(plan: String, params: T.any(::Stripe::PlanService::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Plan)
}
def delete(plan, params = {}, opts = {}); end
# Returns a list of your plans.
sig {
params(params: T.any(::Stripe::PlanService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the plan with the given ID.
sig {
params(plan: String, params: T.any(::Stripe::PlanService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Plan)
}
def retrieve(plan, params = {}, opts = {}); end
# Updates the specified plan by setting the values of the parameters passed. Any parameters not provided are left unchanged. By design, you cannot change a plan's ID, amount, currency, or billing cycle.
sig {
params(plan: String, params: T.any(::Stripe::PlanService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Plan)
}
def update(plan, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class PriceService < StripeService
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
class Recurring < Stripe::RequestParams
# Filter by billing frequency. Either `day`, `week`, `month` or `year`.
sig { returns(T.nilable(String)) }
attr_accessor :interval
# Filter by the price's meter.
sig { returns(T.nilable(String)) }
attr_accessor :meter
# Filter by the usage type for this price. Can be either `metered` or `licensed`.
sig { returns(T.nilable(String)) }
attr_accessor :usage_type
sig {
params(interval: T.nilable(String), meter: T.nilable(String), usage_type: T.nilable(String)).void
}
def initialize(interval: nil, meter: nil, usage_type: nil); end
end
# Only return prices that are active or inactive (e.g., pass `false` to list all inactive prices).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.
sig { returns(T.nilable(T.any(::Stripe::PriceService::ListParams::Created, Integer))) }
attr_accessor :created
# Only return prices for the given currency.
sig { returns(T.nilable(String)) }
attr_accessor :currency
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Only return the price with these lookup_keys, if any exist. You can specify up to 10 lookup_keys.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :lookup_keys
# Only return prices for the given product.
sig { returns(T.nilable(String)) }
attr_accessor :product
# Only return prices with these recurring fields.
sig { returns(T.nilable(::Stripe::PriceService::ListParams::Recurring)) }
attr_accessor :recurring
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return prices of type `recurring` or `one_time`.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(active: T.nilable(T::Boolean), created: T.nilable(T.any(::Stripe::PriceService::ListParams::Created, Integer)), currency: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), lookup_keys: T.nilable(T::Array[String]), product: T.nilable(String), recurring: T.nilable(::Stripe::PriceService::ListParams::Recurring), starting_after: T.nilable(String), type: T.nilable(String)).void
}
def initialize(
active: nil,
created: nil,
currency: nil,
ending_before: nil,
expand: nil,
limit: nil,
lookup_keys: nil,
product: nil,
recurring: nil,
starting_after: nil,
type: nil
); end
end
class CreateParams < Stripe::RequestParams
class CurrencyOptions < Stripe::RequestParams
class CustomUnitAmount < Stripe::RequestParams
# Pass in `true` to enable `custom_unit_amount`, otherwise omit `custom_unit_amount`.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The maximum unit amount the customer can specify for this item.
sig { returns(T.nilable(Integer)) }
attr_accessor :maximum
# The minimum unit amount the customer can specify for this item. Must be at least the minimum charge amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :minimum
# The starting unit amount which can be updated by the customer.
sig { returns(T.nilable(Integer)) }
attr_accessor :preset
sig {
params(enabled: T::Boolean, maximum: T.nilable(Integer), minimum: T.nilable(Integer), preset: T.nilable(Integer)).void
}
def initialize(enabled: nil, maximum: nil, minimum: nil, preset: nil); end
end
class Tier < Stripe::RequestParams
# The flat billing amount for an entire tier, regardless of the number of units in the tier.
sig { returns(T.nilable(Integer)) }
attr_accessor :flat_amount
# Same as `flat_amount`, but accepts a decimal value representing an integer in the minor units of the currency. Only one of `flat_amount` and `flat_amount_decimal` can be set.
sig { returns(T.nilable(String)) }
attr_accessor :flat_amount_decimal
# The per unit billing amount for each individual unit for which this tier applies.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
# Specifies the upper bound of this tier. The lower bound of a tier is the upper bound of the previous tier adding one. Use `inf` to define a fallback tier.
sig { returns(T.any(String, Integer)) }
attr_accessor :up_to
sig {
params(flat_amount: T.nilable(Integer), flat_amount_decimal: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String), up_to: T.any(String, Integer)).void
}
def initialize(
flat_amount: nil,
flat_amount_decimal: nil,
unit_amount: nil,
unit_amount_decimal: nil,
up_to: nil
); end
end
# When set, provides configuration for the amount to be adjusted by the customer during Checkout Sessions and Payment Links.
sig {
returns(T.nilable(::Stripe::PriceService::CreateParams::CurrencyOptions::CustomUnitAmount))
}
attr_accessor :custom_unit_amount
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# Each element represents a pricing tier. This parameter requires `billing_scheme` to be set to `tiered`. See also the documentation for `billing_scheme`.
sig {
returns(T.nilable(T::Array[::Stripe::PriceService::CreateParams::CurrencyOptions::Tier]))
}
attr_accessor :tiers
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(custom_unit_amount: T.nilable(::Stripe::PriceService::CreateParams::CurrencyOptions::CustomUnitAmount), tax_behavior: T.nilable(String), tiers: T.nilable(T::Array[::Stripe::PriceService::CreateParams::CurrencyOptions::Tier]), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
custom_unit_amount: nil,
tax_behavior: nil,
tiers: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
class CustomUnitAmount < Stripe::RequestParams
# Pass in `true` to enable `custom_unit_amount`, otherwise omit `custom_unit_amount`.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The maximum unit amount the customer can specify for this item.
sig { returns(T.nilable(Integer)) }
attr_accessor :maximum
# The minimum unit amount the customer can specify for this item. Must be at least the minimum charge amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :minimum
# The starting unit amount which can be updated by the customer.
sig { returns(T.nilable(Integer)) }
attr_accessor :preset
sig {
params(enabled: T::Boolean, maximum: T.nilable(Integer), minimum: T.nilable(Integer), preset: T.nilable(Integer)).void
}
def initialize(enabled: nil, maximum: nil, minimum: nil, preset: nil); end
end
class ProductData < Stripe::RequestParams
# Whether the product is currently available for purchase. Defaults to `true`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# The identifier for the product. Must be unique. If not provided, an identifier will be randomly generated.
sig { returns(T.nilable(String)) }
attr_accessor :id
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The product's name, meant to be displayable to the customer.
sig { returns(String) }
attr_accessor :name
# An arbitrary string to be displayed on your customer's credit card or bank statement. While most banks display this information consistently, some may display it incorrectly or not at all.
#
# This may be up to 22 characters. The statement description may not include `<`, `>`, `\`, `"`, `'` characters, and will appear on your customer's statement in capital letters. Non-ASCII characters are automatically stripped.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
sig { returns(T.nilable(String)) }
attr_accessor :tax_code
# A label that represents units of this product. When set, this will be included in customers' receipts, invoices, Checkout, and the customer portal.
sig { returns(T.nilable(String)) }
attr_accessor :unit_label
sig {
params(active: T.nilable(T::Boolean), id: T.nilable(String), metadata: T.nilable(T::Hash[String, String]), name: String, statement_descriptor: T.nilable(String), tax_code: T.nilable(String), unit_label: T.nilable(String)).void
}
def initialize(
active: nil,
id: nil,
metadata: nil,
name: nil,
statement_descriptor: nil,
tax_code: nil,
unit_label: nil
); end
end
class Recurring < Stripe::RequestParams
# Specifies billing frequency. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_count
# The meter tracking the usage of a metered price
sig { returns(T.nilable(String)) }
attr_accessor :meter
# Default number of trial days when subscribing a customer to this price using [`trial_from_plan=true`](https://stripe.com/docs/api#create_subscription-trial_from_plan).
sig { returns(T.nilable(Integer)) }
attr_accessor :trial_period_days
# Configures how the quantity per period should be determined. Can be either `metered` or `licensed`. `licensed` automatically bills the `quantity` set when adding it to a subscription. `metered` aggregates the total usage based on usage records. Defaults to `licensed`.
sig { returns(T.nilable(String)) }
attr_accessor :usage_type
sig {
params(interval: String, interval_count: T.nilable(Integer), meter: T.nilable(String), trial_period_days: T.nilable(Integer), usage_type: T.nilable(String)).void
}
def initialize(
interval: nil,
interval_count: nil,
meter: nil,
trial_period_days: nil,
usage_type: nil
); end
end
class Tier < Stripe::RequestParams
# The flat billing amount for an entire tier, regardless of the number of units in the tier.
sig { returns(T.nilable(Integer)) }
attr_accessor :flat_amount
# Same as `flat_amount`, but accepts a decimal value representing an integer in the minor units of the currency. Only one of `flat_amount` and `flat_amount_decimal` can be set.
sig { returns(T.nilable(String)) }
attr_accessor :flat_amount_decimal
# The per unit billing amount for each individual unit for which this tier applies.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
# Specifies the upper bound of this tier. The lower bound of a tier is the upper bound of the previous tier adding one. Use `inf` to define a fallback tier.
sig { returns(T.any(String, Integer)) }
attr_accessor :up_to
sig {
params(flat_amount: T.nilable(Integer), flat_amount_decimal: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String), up_to: T.any(String, Integer)).void
}
def initialize(
flat_amount: nil,
flat_amount_decimal: nil,
unit_amount: nil,
unit_amount_decimal: nil,
up_to: nil
); end
end
class TransformQuantity < Stripe::RequestParams
# Divide usage by this number.
sig { returns(Integer) }
attr_accessor :divide_by
# After division, either round the result `up` or `down`.
sig { returns(String) }
attr_accessor :round
sig { params(divide_by: Integer, round: String).void }
def initialize(divide_by: nil, round: nil); end
end
# Whether the price can be used for new purchases. Defaults to `true`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# Describes how to compute the price per period. Either `per_unit` or `tiered`. `per_unit` indicates that the fixed amount (specified in `unit_amount` or `unit_amount_decimal`) will be charged per unit in `quantity` (for prices with `usage_type=licensed`), or per unit of total usage (for prices with `usage_type=metered`). `tiered` indicates that the unit pricing will be computed using a tiering strategy as defined using the `tiers` and `tiers_mode` attributes.
sig { returns(T.nilable(String)) }
attr_accessor :billing_scheme
# 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).
sig { returns(String) }
attr_accessor :currency
# Prices defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
sig {
returns(T.nilable(T::Hash[String, ::Stripe::PriceService::CreateParams::CurrencyOptions]))
}
attr_accessor :currency_options
# When set, provides configuration for the amount to be adjusted by the customer during Checkout Sessions and Payment Links.
sig { returns(T.nilable(::Stripe::PriceService::CreateParams::CustomUnitAmount)) }
attr_accessor :custom_unit_amount
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A lookup key used to retrieve prices dynamically from a static string. This may be up to 200 characters.
sig { returns(T.nilable(String)) }
attr_accessor :lookup_key
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# A brief description of the price, hidden from customers.
sig { returns(T.nilable(String)) }
attr_accessor :nickname
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
sig { returns(T.nilable(String)) }
attr_accessor :product
# These fields can be used to create a new product that this price will belong to.
sig { returns(T.nilable(::Stripe::PriceService::CreateParams::ProductData)) }
attr_accessor :product_data
# The recurring components of a price such as `interval` and `usage_type`.
sig { returns(T.nilable(::Stripe::PriceService::CreateParams::Recurring)) }
attr_accessor :recurring
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# Each element represents a pricing tier. This parameter requires `billing_scheme` to be set to `tiered`. See also the documentation for `billing_scheme`.
sig { returns(T.nilable(T::Array[::Stripe::PriceService::CreateParams::Tier])) }
attr_accessor :tiers
# Defines if the tiering price should be `graduated` or `volume` based. In `volume`-based tiering, the maximum quantity within a period determines the per unit price, in `graduated` tiering pricing can successively change as the quantity grows.
sig { returns(T.nilable(String)) }
attr_accessor :tiers_mode
# If set to true, will atomically remove the lookup key from the existing price, and assign it to this price.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :transfer_lookup_key
# Apply a transformation to the reported usage or set quantity before computing the billed price. Cannot be combined with `tiers`.
sig { returns(T.nilable(::Stripe::PriceService::CreateParams::TransformQuantity)) }
attr_accessor :transform_quantity
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge. One of `unit_amount`, `unit_amount_decimal`, or `custom_unit_amount` is required, unless `billing_scheme=tiered`.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(active: T.nilable(T::Boolean), billing_scheme: T.nilable(String), currency: String, currency_options: T.nilable(T::Hash[String, ::Stripe::PriceService::CreateParams::CurrencyOptions]), custom_unit_amount: T.nilable(::Stripe::PriceService::CreateParams::CustomUnitAmount), expand: T.nilable(T::Array[String]), lookup_key: T.nilable(String), metadata: T.nilable(T::Hash[String, String]), nickname: T.nilable(String), product: T.nilable(String), product_data: T.nilable(::Stripe::PriceService::CreateParams::ProductData), recurring: T.nilable(::Stripe::PriceService::CreateParams::Recurring), tax_behavior: T.nilable(String), tiers: T.nilable(T::Array[::Stripe::PriceService::CreateParams::Tier]), tiers_mode: T.nilable(String), transfer_lookup_key: T.nilable(T::Boolean), transform_quantity: T.nilable(::Stripe::PriceService::CreateParams::TransformQuantity), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
active: nil,
billing_scheme: nil,
currency: nil,
currency_options: nil,
custom_unit_amount: nil,
expand: nil,
lookup_key: nil,
metadata: nil,
nickname: nil,
product: nil,
product_data: nil,
recurring: nil,
tax_behavior: nil,
tiers: nil,
tiers_mode: nil,
transfer_lookup_key: nil,
transform_quantity: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
class CurrencyOptions < Stripe::RequestParams
class CustomUnitAmount < Stripe::RequestParams
# Pass in `true` to enable `custom_unit_amount`, otherwise omit `custom_unit_amount`.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The maximum unit amount the customer can specify for this item.
sig { returns(T.nilable(Integer)) }
attr_accessor :maximum
# The minimum unit amount the customer can specify for this item. Must be at least the minimum charge amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :minimum
# The starting unit amount which can be updated by the customer.
sig { returns(T.nilable(Integer)) }
attr_accessor :preset
sig {
params(enabled: T::Boolean, maximum: T.nilable(Integer), minimum: T.nilable(Integer), preset: T.nilable(Integer)).void
}
def initialize(enabled: nil, maximum: nil, minimum: nil, preset: nil); end
end
class Tier < Stripe::RequestParams
# The flat billing amount for an entire tier, regardless of the number of units in the tier.
sig { returns(T.nilable(Integer)) }
attr_accessor :flat_amount
# Same as `flat_amount`, but accepts a decimal value representing an integer in the minor units of the currency. Only one of `flat_amount` and `flat_amount_decimal` can be set.
sig { returns(T.nilable(String)) }
attr_accessor :flat_amount_decimal
# The per unit billing amount for each individual unit for which this tier applies.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
# Specifies the upper bound of this tier. The lower bound of a tier is the upper bound of the previous tier adding one. Use `inf` to define a fallback tier.
sig { returns(T.any(String, Integer)) }
attr_accessor :up_to
sig {
params(flat_amount: T.nilable(Integer), flat_amount_decimal: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String), up_to: T.any(String, Integer)).void
}
def initialize(
flat_amount: nil,
flat_amount_decimal: nil,
unit_amount: nil,
unit_amount_decimal: nil,
up_to: nil
); end
end
# When set, provides configuration for the amount to be adjusted by the customer during Checkout Sessions and Payment Links.
sig {
returns(T.nilable(::Stripe::PriceService::UpdateParams::CurrencyOptions::CustomUnitAmount))
}
attr_accessor :custom_unit_amount
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# Each element represents a pricing tier. This parameter requires `billing_scheme` to be set to `tiered`. See also the documentation for `billing_scheme`.
sig {
returns(T.nilable(T::Array[::Stripe::PriceService::UpdateParams::CurrencyOptions::Tier]))
}
attr_accessor :tiers
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(custom_unit_amount: T.nilable(::Stripe::PriceService::UpdateParams::CurrencyOptions::CustomUnitAmount), tax_behavior: T.nilable(String), tiers: T.nilable(T::Array[::Stripe::PriceService::UpdateParams::CurrencyOptions::Tier]), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
custom_unit_amount: nil,
tax_behavior: nil,
tiers: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
class MigrateTo < Stripe::RequestParams
# The behavior controlling the point in the subscription lifecycle after which to migrate the price. Currently must be `at_cycle_end`.
sig { returns(String) }
attr_accessor :behavior
# The time after which subscriptions should start using the new price.
sig { returns(T.nilable(Integer)) }
attr_accessor :effective_after
# The ID of the price object.
sig { returns(String) }
attr_accessor :price
sig { params(behavior: String, effective_after: T.nilable(Integer), price: String).void }
def initialize(behavior: nil, effective_after: nil, price: nil); end
end
# Whether the price can be used for new purchases. Defaults to `true`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# Prices defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
sig {
returns(T.nilable(T.nilable(T.any(String, T::Hash[String, ::Stripe::PriceService::UpdateParams::CurrencyOptions]))))
}
attr_accessor :currency_options
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A lookup key used to retrieve prices dynamically from a static string. This may be up to 200 characters.
sig { returns(T.nilable(String)) }
attr_accessor :lookup_key
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# If specified, subscriptions using this price will be updated to use the new referenced price.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::PriceService::UpdateParams::MigrateTo))))
}
attr_accessor :migrate_to
# A brief description of the price, hidden from customers.
sig { returns(T.nilable(String)) }
attr_accessor :nickname
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# If set to true, will atomically remove the lookup key from the existing price, and assign it to this price.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :transfer_lookup_key
sig {
params(active: T.nilable(T::Boolean), currency_options: T.nilable(T.nilable(T.any(String, T::Hash[String, ::Stripe::PriceService::UpdateParams::CurrencyOptions]))), expand: T.nilable(T::Array[String]), lookup_key: T.nilable(String), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), migrate_to: T.nilable(T.nilable(T.any(String, ::Stripe::PriceService::UpdateParams::MigrateTo))), nickname: T.nilable(String), tax_behavior: T.nilable(String), transfer_lookup_key: T.nilable(T::Boolean)).void
}
def initialize(
active: nil,
currency_options: nil,
expand: nil,
lookup_key: nil,
metadata: nil,
migrate_to: nil,
nickname: nil,
tax_behavior: nil,
transfer_lookup_key: nil
); end
end
class SearchParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for pagination across multiple pages of results. Don't include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.
sig { returns(T.nilable(String)) }
attr_accessor :page
# The search query string. See [search query language](https://stripe.com/docs/search#search-query-language) and the list of supported [query fields for prices](https://stripe.com/docs/search#query-fields-for-prices).
sig { returns(String) }
attr_accessor :query
sig {
params(expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), page: T.nilable(String), query: String).void
}
def initialize(expand: nil, limit: nil, page: nil, query: nil); end
end
# Creates a new [Price for an existing Product](https://docs.stripe.com/api/prices). The Price can be recurring or one-time.
sig {
params(params: T.any(::Stripe::PriceService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Price)
}
def create(params = {}, opts = {}); end
# Returns a list of your active prices, excluding [inline prices](https://docs.stripe.com/docs/products-prices/pricing-models#inline-pricing). For the list of inactive prices, set active to false.
sig {
params(params: T.any(::Stripe::PriceService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the price with the given ID.
sig {
params(price: String, params: T.any(::Stripe::PriceService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Price)
}
def retrieve(price, params = {}, opts = {}); end
# Search for prices you've previously created using Stripe's [Search Query Language](https://docs.stripe.com/docs/search#search-query-language).
# Don't use search in read-after-write flows where strict consistency is necessary. Under normal operating
# conditions, data is searchable in less than a minute. Occasionally, propagation of new or updated data can be up
# to an hour behind during outages. Search functionality is not available to merchants in India.
sig {
params(params: T.any(::Stripe::PriceService::SearchParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SearchResultObject)
}
def search(params = {}, opts = {}); end
# Updates the specified price by setting the values of the parameters passed. Any parameters not provided are left unchanged.
sig {
params(price: String, params: T.any(::Stripe::PriceService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Price)
}
def update(price, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class PrivacyService < StripeService
attr_reader :redaction_jobs
end
end
# typed: true
module Stripe
module Privacy
class RedactionJobService < StripeService
attr_reader :validation_errors
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Attribute for param field status
sig { returns(T.nilable(String)) }
attr_accessor :status
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String), status: T.nilable(String)).void
}
def initialize(
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil,
status: nil
); end
end
class CreateParams < Stripe::RequestParams
class Objects < Stripe::RequestParams
# Attribute for param field charges
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :charges
# Attribute for param field checkout_sessions
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :checkout_sessions
# Attribute for param field customers
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :customers
# Attribute for param field identity_verification_sessions
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :identity_verification_sessions
# Attribute for param field invoices
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :invoices
# Attribute for param field issuing_cardholders
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :issuing_cardholders
# Attribute for param field issuing_cards
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :issuing_cards
# Attribute for param field payment_intents
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :payment_intents
# Attribute for param field radar_value_list_items
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :radar_value_list_items
# Attribute for param field setup_intents
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :setup_intents
sig {
params(charges: T.nilable(T::Array[String]), checkout_sessions: T.nilable(T::Array[String]), customers: T.nilable(T::Array[String]), identity_verification_sessions: T.nilable(T::Array[String]), invoices: T.nilable(T::Array[String]), issuing_cardholders: T.nilable(T::Array[String]), issuing_cards: T.nilable(T::Array[String]), payment_intents: T.nilable(T::Array[String]), radar_value_list_items: T.nilable(T::Array[String]), setup_intents: T.nilable(T::Array[String])).void
}
def initialize(
charges: nil,
checkout_sessions: nil,
customers: nil,
identity_verification_sessions: nil,
invoices: nil,
issuing_cardholders: nil,
issuing_cards: nil,
payment_intents: nil,
radar_value_list_items: nil,
setup_intents: nil
); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The objects to redact. These root objects and their related ones will be validated for redaction.
sig { returns(::Stripe::Privacy::RedactionJobService::CreateParams::Objects) }
attr_accessor :objects
# Determines the validation behavior of the job. Default is `error`.
sig { returns(T.nilable(String)) }
attr_accessor :validation_behavior
sig {
params(expand: T.nilable(T::Array[String]), objects: ::Stripe::Privacy::RedactionJobService::CreateParams::Objects, validation_behavior: T.nilable(String)).void
}
def initialize(expand: nil, objects: nil, validation_behavior: nil); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Determines the validation behavior of the job. Default is `error`.
sig { returns(T.nilable(String)) }
attr_accessor :validation_behavior
sig {
params(expand: T.nilable(T::Array[String]), validation_behavior: T.nilable(String)).void
}
def initialize(expand: nil, validation_behavior: nil); end
end
class CancelParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class RunParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class ValidateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# You can cancel a redaction job when it's in one of these statuses: ready, failed.
#
# Canceling the redaction job will abandon its attempt to redact the configured objects. A canceled job cannot be used again.
sig {
params(job: String, params: T.any(::Stripe::Privacy::RedactionJobService::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Privacy::RedactionJob)
}
def cancel(job, params = {}, opts = {}); end
# Creates a redaction job. When a job is created, it will start to validate.
sig {
params(params: T.any(::Stripe::Privacy::RedactionJobService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Privacy::RedactionJob)
}
def create(params = {}, opts = {}); end
# Returns a list of redaction jobs.
sig {
params(params: T.any(::Stripe::Privacy::RedactionJobService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the details of a previously created redaction job.
sig {
params(job: String, params: T.any(::Stripe::Privacy::RedactionJobService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Privacy::RedactionJob)
}
def retrieve(job, params = {}, opts = {}); end
# Run a redaction job in a ready status.
#
# When you run a job, the configured objects will be redacted asynchronously. This action is irreversible and cannot be canceled once started.
#
# The status of the job will move to redacting. Once all of the objects are redacted, the status will become succeeded. If the job's validation_behavior is set to fix, the automatic fixes will be applied to objects at this step.
sig {
params(job: String, params: T.any(::Stripe::Privacy::RedactionJobService::RunParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Privacy::RedactionJob)
}
def run(job, params = {}, opts = {}); end
# Updates the properties of a redaction job without running or canceling the job.
#
# If the job to update is in a failed status, it will not automatically start to validate. Once you applied all of the changes, use the validate API to start validation again.
sig {
params(job: String, params: T.any(::Stripe::Privacy::RedactionJobService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Privacy::RedactionJob)
}
def update(job, params = {}, opts = {}); end
# Validate a redaction job when it is in a failed status.
#
# When a job is created, it automatically begins to validate on the configured objects' eligibility for redaction. Use this to validate the job again after its validation errors are resolved or the job's validation_behavior is changed.
#
# The status of the job will move to validating. Once all of the objects are validated, the status of the job will become ready. If there are any validation errors preventing the job from running, the status will become failed.
sig {
params(job: String, params: T.any(::Stripe::Privacy::RedactionJobService::ValidateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Privacy::RedactionJob)
}
def validate(job, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Privacy
class RedactionJobValidationErrorService < StripeService
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
# Returns a list of validation errors for the specified redaction job.
sig {
params(job: String, params: T.any(::Stripe::Privacy::RedactionJobValidationErrorService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(job, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
class ProductService < StripeService
attr_reader :features
class DeleteParams < Stripe::RequestParams; end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
class MarketingFeature < Stripe::RequestParams
# The marketing feature name. Up to 80 characters long.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class PackageDimensions < Stripe::RequestParams
# Height, in inches. Maximum precision is 2 decimal places.
sig { returns(Float) }
attr_accessor :height
# Length, in inches. Maximum precision is 2 decimal places.
sig { returns(Float) }
attr_accessor :length
# Weight, in ounces. Maximum precision is 2 decimal places.
sig { returns(Float) }
attr_accessor :weight
# Width, in inches. Maximum precision is 2 decimal places.
sig { returns(Float) }
attr_accessor :width
sig { params(height: Float, length: Float, weight: Float, width: Float).void }
def initialize(height: nil, length: nil, weight: nil, width: nil); end
end
# Whether the product is available for purchase.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# The ID of the [Price](https://stripe.com/docs/api/prices) object that is the default price for this product.
sig { returns(T.nilable(String)) }
attr_accessor :default_price
# The product's description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :description
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A list of up to 8 URLs of images for this product, meant to be displayable to the customer.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :images
# A list of up to 15 marketing features for this product. These are displayed in [pricing tables](https://stripe.com/docs/payments/checkout/pricing-table).
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::ProductService::UpdateParams::MarketingFeature]))))
}
attr_accessor :marketing_features
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# The product's name, meant to be displayable to the customer.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The dimensions of this product for shipping purposes.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::ProductService::UpdateParams::PackageDimensions))))
}
attr_accessor :package_dimensions
# Whether this product is shipped (i.e., physical goods).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :shippable
# An arbitrary string to be displayed on your customer's credit card or bank statement. While most banks display this information consistently, some may display it incorrectly or not at all.
#
# This may be up to 22 characters. The statement description may not include `<`, `>`, `\`, `"`, `'` characters, and will appear on your customer's statement in capital letters. Non-ASCII characters are automatically stripped.
# It must contain at least one letter. May only be set if `type=service`. Only used for subscription payments.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :tax_code
# A label that represents units of this product. When set, this will be included in customers' receipts, invoices, Checkout, and the customer portal. May only be set if `type=service`.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :unit_label
# A URL of a publicly-accessible webpage for this product.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :url
sig {
params(active: T.nilable(T::Boolean), default_price: T.nilable(String), description: T.nilable(T.nilable(String)), expand: T.nilable(T::Array[String]), images: T.nilable(T.nilable(T.any(String, T::Array[String]))), marketing_features: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::ProductService::UpdateParams::MarketingFeature]))), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), name: T.nilable(String), package_dimensions: T.nilable(T.nilable(T.any(String, ::Stripe::ProductService::UpdateParams::PackageDimensions))), shippable: T.nilable(T::Boolean), statement_descriptor: T.nilable(String), tax_code: T.nilable(T.nilable(String)), unit_label: T.nilable(T.nilable(String)), url: T.nilable(T.nilable(String))).void
}
def initialize(
active: nil,
default_price: nil,
description: nil,
expand: nil,
images: nil,
marketing_features: nil,
metadata: nil,
name: nil,
package_dimensions: nil,
shippable: nil,
statement_descriptor: nil,
tax_code: nil,
unit_label: nil,
url: nil
); end
end
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return products that are active or inactive (e.g., pass `false` to list all inactive products).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# Only return products that were created during the given date interval.
sig { returns(T.nilable(T.any(::Stripe::ProductService::ListParams::Created, Integer))) }
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Only return products with the given IDs. Cannot be used with [starting_after](https://stripe.com/docs/api#list_products-starting_after) or [ending_before](https://stripe.com/docs/api#list_products-ending_before).
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :ids
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Only return products that can be shipped (i.e., physical, not digital products).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :shippable
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return products of this type.
sig { returns(T.nilable(String)) }
attr_accessor :type
# Only return products with the given url.
sig { returns(T.nilable(String)) }
attr_accessor :url
sig {
params(active: T.nilable(T::Boolean), created: T.nilable(T.any(::Stripe::ProductService::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), ids: T.nilable(T::Array[String]), limit: T.nilable(Integer), shippable: T.nilable(T::Boolean), starting_after: T.nilable(String), type: T.nilable(String), url: T.nilable(String)).void
}
def initialize(
active: nil,
created: nil,
ending_before: nil,
expand: nil,
ids: nil,
limit: nil,
shippable: nil,
starting_after: nil,
type: nil,
url: nil
); end
end
class CreateParams < Stripe::RequestParams
class DefaultPriceData < Stripe::RequestParams
class CurrencyOptions < Stripe::RequestParams
class CustomUnitAmount < Stripe::RequestParams
# Pass in `true` to enable `custom_unit_amount`, otherwise omit `custom_unit_amount`.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The maximum unit amount the customer can specify for this item.
sig { returns(T.nilable(Integer)) }
attr_accessor :maximum
# The minimum unit amount the customer can specify for this item. Must be at least the minimum charge amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :minimum
# The starting unit amount which can be updated by the customer.
sig { returns(T.nilable(Integer)) }
attr_accessor :preset
sig {
params(enabled: T::Boolean, maximum: T.nilable(Integer), minimum: T.nilable(Integer), preset: T.nilable(Integer)).void
}
def initialize(enabled: nil, maximum: nil, minimum: nil, preset: nil); end
end
class Tier < Stripe::RequestParams
# The flat billing amount for an entire tier, regardless of the number of units in the tier.
sig { returns(T.nilable(Integer)) }
attr_accessor :flat_amount
# Same as `flat_amount`, but accepts a decimal value representing an integer in the minor units of the currency. Only one of `flat_amount` and `flat_amount_decimal` can be set.
sig { returns(T.nilable(String)) }
attr_accessor :flat_amount_decimal
# The per unit billing amount for each individual unit for which this tier applies.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
# Specifies the upper bound of this tier. The lower bound of a tier is the upper bound of the previous tier adding one. Use `inf` to define a fallback tier.
sig { returns(T.any(String, Integer)) }
attr_accessor :up_to
sig {
params(flat_amount: T.nilable(Integer), flat_amount_decimal: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String), up_to: T.any(String, Integer)).void
}
def initialize(
flat_amount: nil,
flat_amount_decimal: nil,
unit_amount: nil,
unit_amount_decimal: nil,
up_to: nil
); end
end
# When set, provides configuration for the amount to be adjusted by the customer during Checkout Sessions and Payment Links.
sig {
returns(T.nilable(::Stripe::ProductService::CreateParams::DefaultPriceData::CurrencyOptions::CustomUnitAmount))
}
attr_accessor :custom_unit_amount
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# Each element represents a pricing tier. This parameter requires `billing_scheme` to be set to `tiered`. See also the documentation for `billing_scheme`.
sig {
returns(T.nilable(T::Array[::Stripe::ProductService::CreateParams::DefaultPriceData::CurrencyOptions::Tier]))
}
attr_accessor :tiers
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(custom_unit_amount: T.nilable(::Stripe::ProductService::CreateParams::DefaultPriceData::CurrencyOptions::CustomUnitAmount), tax_behavior: T.nilable(String), tiers: T.nilable(T::Array[::Stripe::ProductService::CreateParams::DefaultPriceData::CurrencyOptions::Tier]), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
custom_unit_amount: nil,
tax_behavior: nil,
tiers: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
class CustomUnitAmount < Stripe::RequestParams
# Pass in `true` to enable `custom_unit_amount`, otherwise omit `custom_unit_amount`.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The maximum unit amount the customer can specify for this item.
sig { returns(T.nilable(Integer)) }
attr_accessor :maximum
# The minimum unit amount the customer can specify for this item. Must be at least the minimum charge amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :minimum
# The starting unit amount which can be updated by the customer.
sig { returns(T.nilable(Integer)) }
attr_accessor :preset
sig {
params(enabled: T::Boolean, maximum: T.nilable(Integer), minimum: T.nilable(Integer), preset: T.nilable(Integer)).void
}
def initialize(enabled: nil, maximum: nil, minimum: nil, preset: nil); end
end
class Recurring < Stripe::RequestParams
# Specifies billing frequency. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: T.nilable(Integer)).void }
def initialize(interval: nil, interval_count: nil); end
end
# 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).
sig { returns(String) }
attr_accessor :currency
# Prices defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
sig {
returns(T.nilable(T::Hash[String, ::Stripe::ProductService::CreateParams::DefaultPriceData::CurrencyOptions]))
}
attr_accessor :currency_options
# When set, provides configuration for the amount to be adjusted by the customer during Checkout Sessions and Payment Links.
sig {
returns(T.nilable(::Stripe::ProductService::CreateParams::DefaultPriceData::CustomUnitAmount))
}
attr_accessor :custom_unit_amount
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The recurring components of a price such as `interval` and `interval_count`.
sig {
returns(T.nilable(::Stripe::ProductService::CreateParams::DefaultPriceData::Recurring))
}
attr_accessor :recurring
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge. One of `unit_amount`, `unit_amount_decimal`, or `custom_unit_amount` is required.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, currency_options: T.nilable(T::Hash[String, ::Stripe::ProductService::CreateParams::DefaultPriceData::CurrencyOptions]), custom_unit_amount: T.nilable(::Stripe::ProductService::CreateParams::DefaultPriceData::CustomUnitAmount), metadata: T.nilable(T::Hash[String, String]), recurring: T.nilable(::Stripe::ProductService::CreateParams::DefaultPriceData::Recurring), tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
currency_options: nil,
custom_unit_amount: nil,
metadata: nil,
recurring: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
class MarketingFeature < Stripe::RequestParams
# The marketing feature name. Up to 80 characters long.
sig { returns(String) }
attr_accessor :name
sig { params(name: String).void }
def initialize(name: nil); end
end
class PackageDimensions < Stripe::RequestParams
# Height, in inches. Maximum precision is 2 decimal places.
sig { returns(Float) }
attr_accessor :height
# Length, in inches. Maximum precision is 2 decimal places.
sig { returns(Float) }
attr_accessor :length
# Weight, in ounces. Maximum precision is 2 decimal places.
sig { returns(Float) }
attr_accessor :weight
# Width, in inches. Maximum precision is 2 decimal places.
sig { returns(Float) }
attr_accessor :width
sig { params(height: Float, length: Float, weight: Float, width: Float).void }
def initialize(height: nil, length: nil, weight: nil, width: nil); end
end
# Whether the product is currently available for purchase. Defaults to `true`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object. This Price will be set as the default price for this product.
sig { returns(T.nilable(::Stripe::ProductService::CreateParams::DefaultPriceData)) }
attr_accessor :default_price_data
# The product's description, meant to be displayable to the customer. Use this field to optionally store a long form explanation of the product being sold for your own rendering purposes.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# An identifier will be randomly generated by Stripe. You can optionally override this ID, but the ID must be unique across all products in your Stripe account.
sig { returns(T.nilable(String)) }
attr_accessor :id
# A list of up to 8 URLs of images for this product, meant to be displayable to the customer.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :images
# A list of up to 15 marketing features for this product. These are displayed in [pricing tables](https://stripe.com/docs/payments/checkout/pricing-table).
sig { returns(T.nilable(T::Array[::Stripe::ProductService::CreateParams::MarketingFeature])) }
attr_accessor :marketing_features
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The product's name, meant to be displayable to the customer.
sig { returns(String) }
attr_accessor :name
# The dimensions of this product for shipping purposes.
sig { returns(T.nilable(::Stripe::ProductService::CreateParams::PackageDimensions)) }
attr_accessor :package_dimensions
# Whether this product is shipped (i.e., physical goods).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :shippable
# An arbitrary string to be displayed on your customer's credit card or bank statement. While most banks display this information consistently, some may display it incorrectly or not at all.
#
# This may be up to 22 characters. The statement description may not include `<`, `>`, `\`, `"`, `'` characters, and will appear on your customer's statement in capital letters. Non-ASCII characters are automatically stripped.
# It must contain at least one letter. Only used for subscription payments.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
sig { returns(T.nilable(String)) }
attr_accessor :tax_code
# The type of the product. Defaults to `service` if not explicitly specified, enabling use of this product with Subscriptions and Plans. Set this parameter to `good` to use this product with Orders and SKUs. On API versions before `2018-02-05`, this field defaults to `good` for compatibility reasons.
sig { returns(T.nilable(String)) }
attr_accessor :type
# A label that represents units of this product. When set, this will be included in customers' receipts, invoices, Checkout, and the customer portal.
sig { returns(T.nilable(String)) }
attr_accessor :unit_label
# A URL of a publicly-accessible webpage for this product.
sig { returns(T.nilable(String)) }
attr_accessor :url
sig {
params(active: T.nilable(T::Boolean), default_price_data: T.nilable(::Stripe::ProductService::CreateParams::DefaultPriceData), description: T.nilable(String), expand: T.nilable(T::Array[String]), id: T.nilable(String), images: T.nilable(T::Array[String]), marketing_features: T.nilable(T::Array[::Stripe::ProductService::CreateParams::MarketingFeature]), metadata: T.nilable(T::Hash[String, String]), name: String, package_dimensions: T.nilable(::Stripe::ProductService::CreateParams::PackageDimensions), shippable: T.nilable(T::Boolean), statement_descriptor: T.nilable(String), tax_code: T.nilable(String), type: T.nilable(String), unit_label: T.nilable(String), url: T.nilable(String)).void
}
def initialize(
active: nil,
default_price_data: nil,
description: nil,
expand: nil,
id: nil,
images: nil,
marketing_features: nil,
metadata: nil,
name: nil,
package_dimensions: nil,
shippable: nil,
statement_descriptor: nil,
tax_code: nil,
type: nil,
unit_label: nil,
url: nil
); end
end
class SearchParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for pagination across multiple pages of results. Don't include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.
sig { returns(T.nilable(String)) }
attr_accessor :page
# The search query string. See [search query language](https://stripe.com/docs/search#search-query-language) and the list of supported [query fields for products](https://stripe.com/docs/search#query-fields-for-products).
sig { returns(String) }
attr_accessor :query
sig {
params(expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), page: T.nilable(String), query: String).void
}
def initialize(expand: nil, limit: nil, page: nil, query: nil); end
end
# Creates a new product object.
sig {
params(params: T.any(::Stripe::ProductService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Product)
}
def create(params = {}, opts = {}); end
# Delete a product. Deleting a product is only possible if it has no prices associated with it. Additionally, deleting a product with type=good is only possible if it has no SKUs associated with it.
sig {
params(id: String, params: T.any(::Stripe::ProductService::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Product)
}
def delete(id, params = {}, opts = {}); end
# Returns a list of your products. The products are returned sorted by creation date, with the most recently created products appearing first.
sig {
params(params: T.any(::Stripe::ProductService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the details of an existing product. Supply the unique product ID from either a product creation request or the product list, and Stripe will return the corresponding product information.
sig {
params(id: String, params: T.any(::Stripe::ProductService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Product)
}
def retrieve(id, params = {}, opts = {}); end
# Search for products you've previously created using Stripe's [Search Query Language](https://docs.stripe.com/docs/search#search-query-language).
# Don't use search in read-after-write flows where strict consistency is necessary. Under normal operating
# conditions, data is searchable in less than a minute. Occasionally, propagation of new or updated data can be up
# to an hour behind during outages. Search functionality is not available to merchants in India.
sig {
params(params: T.any(::Stripe::ProductService::SearchParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SearchResultObject)
}
def search(params = {}, opts = {}); end
# Updates the specific product by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
sig {
params(id: String, params: T.any(::Stripe::ProductService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Product)
}
def update(id, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class ProductFeatureService < StripeService
class DeleteParams < Stripe::RequestParams; end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
class CreateParams < Stripe::RequestParams
# The ID of the [Feature](https://stripe.com/docs/api/entitlements/feature) object attached to this product.
sig { returns(String) }
attr_accessor :entitlement_feature
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(entitlement_feature: String, expand: T.nilable(T::Array[String])).void }
def initialize(entitlement_feature: nil, expand: nil); end
end
# Creates a product_feature, which represents a feature attachment to a product
sig {
params(product: String, params: T.any(::Stripe::ProductFeatureService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ProductFeature)
}
def create(product, params = {}, opts = {}); end
# Deletes the feature attachment to a product
sig {
params(product: String, id: String, params: T.any(::Stripe::ProductFeatureService::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ProductFeature)
}
def delete(product, id, params = {}, opts = {}); end
# Retrieve a list of features for a product
sig {
params(product: String, params: T.any(::Stripe::ProductFeatureService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(product, params = {}, opts = {}); end
# Retrieves a product_feature, which represents a feature attachment to a product
sig {
params(product: String, id: String, params: T.any(::Stripe::ProductFeatureService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ProductFeature)
}
def retrieve(product, id, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class PromotionCodeService < StripeService
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Filter promotion codes by whether they are active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# Only return promotion codes that have this case-insensitive code.
sig { returns(T.nilable(String)) }
attr_accessor :code
# Only return promotion codes for this coupon.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.
sig {
returns(T.nilable(T.any(::Stripe::PromotionCodeService::ListParams::Created, Integer)))
}
attr_accessor :created
# Only return promotion codes that are restricted to this customer.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# Only return promotion codes that are restricted to this account.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(active: T.nilable(T::Boolean), code: T.nilable(String), coupon: T.nilable(String), created: T.nilable(T.any(::Stripe::PromotionCodeService::ListParams::Created, Integer)), customer: T.nilable(String), customer_account: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
active: nil,
code: nil,
coupon: nil,
created: nil,
customer: nil,
customer_account: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class Restrictions < Stripe::RequestParams
class CurrencyOptions < Stripe::RequestParams
# Minimum amount required to redeem this Promotion Code into a Coupon (e.g., a purchase must be $100 or more to work).
sig { returns(T.nilable(Integer)) }
attr_accessor :minimum_amount
sig { params(minimum_amount: T.nilable(Integer)).void }
def initialize(minimum_amount: nil); end
end
# Promotion codes defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
sig {
returns(T.nilable(T::Hash[String, ::Stripe::PromotionCodeService::CreateParams::Restrictions::CurrencyOptions]))
}
attr_accessor :currency_options
# A Boolean indicating if the Promotion Code should only be redeemed for Customers without any successful payments or invoices
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :first_time_transaction
# Minimum amount required to redeem this Promotion Code into a Coupon (e.g., a purchase must be $100 or more to work).
sig { returns(T.nilable(Integer)) }
attr_accessor :minimum_amount
# Three-letter [ISO code](https://stripe.com/docs/currencies) for minimum_amount
sig { returns(T.nilable(String)) }
attr_accessor :minimum_amount_currency
sig {
params(currency_options: T.nilable(T::Hash[String, ::Stripe::PromotionCodeService::CreateParams::Restrictions::CurrencyOptions]), first_time_transaction: T.nilable(T::Boolean), minimum_amount: T.nilable(Integer), minimum_amount_currency: T.nilable(String)).void
}
def initialize(
currency_options: nil,
first_time_transaction: nil,
minimum_amount: nil,
minimum_amount_currency: nil
); end
end
# Whether the promotion code is currently active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# The customer-facing code. Regardless of case, this code must be unique across all active promotion codes for a specific customer. Valid characters are lower case letters (a-z), upper case letters (A-Z), and digits (0-9).
#
# If left blank, we will generate one automatically.
sig { returns(T.nilable(String)) }
attr_accessor :code
# The coupon for this promotion code.
sig { returns(String) }
attr_accessor :coupon
# The customer that this promotion code can be used by. If not set, the promotion code can be used by all customers.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# The account that this promotion code can be used by. If not set, the promotion code can be used by all accounts.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The timestamp at which this promotion code will expire. If the coupon has specified a `redeems_by`, then this value cannot be after the coupon's `redeems_by`.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_at
# A positive integer specifying the number of times the promotion code can be redeemed. If the coupon has specified a `max_redemptions`, then this value cannot be greater than the coupon's `max_redemptions`.
sig { returns(T.nilable(Integer)) }
attr_accessor :max_redemptions
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Settings that restrict the redemption of the promotion code.
sig { returns(T.nilable(::Stripe::PromotionCodeService::CreateParams::Restrictions)) }
attr_accessor :restrictions
sig {
params(active: T.nilable(T::Boolean), code: T.nilable(String), coupon: String, customer: T.nilable(String), customer_account: T.nilable(String), expand: T.nilable(T::Array[String]), expires_at: T.nilable(Integer), max_redemptions: T.nilable(Integer), metadata: T.nilable(T::Hash[String, String]), restrictions: T.nilable(::Stripe::PromotionCodeService::CreateParams::Restrictions)).void
}
def initialize(
active: nil,
code: nil,
coupon: nil,
customer: nil,
customer_account: nil,
expand: nil,
expires_at: nil,
max_redemptions: nil,
metadata: nil,
restrictions: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
class Restrictions < Stripe::RequestParams
class CurrencyOptions < Stripe::RequestParams
# Minimum amount required to redeem this Promotion Code into a Coupon (e.g., a purchase must be $100 or more to work).
sig { returns(T.nilable(Integer)) }
attr_accessor :minimum_amount
sig { params(minimum_amount: T.nilable(Integer)).void }
def initialize(minimum_amount: nil); end
end
# Promotion codes defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
sig {
returns(T.nilable(T::Hash[String, ::Stripe::PromotionCodeService::UpdateParams::Restrictions::CurrencyOptions]))
}
attr_accessor :currency_options
sig {
params(currency_options: T.nilable(T::Hash[String, ::Stripe::PromotionCodeService::UpdateParams::Restrictions::CurrencyOptions])).void
}
def initialize(currency_options: nil); end
end
# Whether the promotion code is currently active. A promotion code can only be reactivated when the coupon is still valid and the promotion code is otherwise redeemable.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Settings that restrict the redemption of the promotion code.
sig { returns(T.nilable(::Stripe::PromotionCodeService::UpdateParams::Restrictions)) }
attr_accessor :restrictions
sig {
params(active: T.nilable(T::Boolean), expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), restrictions: T.nilable(::Stripe::PromotionCodeService::UpdateParams::Restrictions)).void
}
def initialize(active: nil, expand: nil, metadata: nil, restrictions: nil); end
end
# A promotion code points to a coupon. You can optionally restrict the code to a specific customer, redemption limit, and expiration date.
sig {
params(params: T.any(::Stripe::PromotionCodeService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PromotionCode)
}
def create(params = {}, opts = {}); end
# Returns a list of your promotion codes.
sig {
params(params: T.any(::Stripe::PromotionCodeService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the promotion code with the given ID. In order to retrieve a promotion code by the customer-facing code use [list](https://docs.stripe.com/docs/api/promotion_codes/list) with the desired code.
sig {
params(promotion_code: String, params: T.any(::Stripe::PromotionCodeService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PromotionCode)
}
def retrieve(promotion_code, params = {}, opts = {}); end
# Updates the specified promotion code by setting the values of the parameters passed. Most fields are, by design, not editable.
sig {
params(promotion_code: String, params: T.any(::Stripe::PromotionCodeService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::PromotionCode)
}
def update(promotion_code, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class QuoteService < StripeService
attr_reader :preview_invoices
attr_reader :preview_subscription_schedules
attr_reader :lines
attr_reader :line_items
attr_reader :computed_upfront_line_items
class ListParams < Stripe::RequestParams
# The ID of the customer whose quotes will be retrieved.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# The ID of the account whose quotes will be retrieved.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The subscription which the quote updates.
sig { returns(T.nilable(String)) }
attr_accessor :from_subscription
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# The status of the quote.
sig { returns(T.nilable(String)) }
attr_accessor :status
# Provides a list of quotes that are associated with the specified test clock. The response will not include quotes with test clocks if this and the customer parameter is not set.
sig { returns(T.nilable(String)) }
attr_accessor :test_clock
sig {
params(customer: T.nilable(String), customer_account: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), from_subscription: T.nilable(String), limit: T.nilable(Integer), starting_after: T.nilable(String), status: T.nilable(String), test_clock: T.nilable(String)).void
}
def initialize(
customer: nil,
customer_account: nil,
ending_before: nil,
expand: nil,
from_subscription: nil,
limit: nil,
starting_after: nil,
status: nil,
test_clock: nil
); end
end
class CreateParams < Stripe::RequestParams
class AutomaticTax < Stripe::RequestParams
class Liability < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# Controls whether Stripe will automatically compute tax on the resulting invoices or subscriptions as well as the quote itself.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
sig { returns(T.nilable(::Stripe::QuoteService::CreateParams::AutomaticTax::Liability)) }
attr_accessor :liability
sig {
params(enabled: T::Boolean, liability: T.nilable(::Stripe::QuoteService::CreateParams::AutomaticTax::Liability)).void
}
def initialize(enabled: nil, liability: nil); end
end
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::QuoteService::CreateParams::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::QuoteService::CreateParams::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig { returns(T.nilable(::Stripe::QuoteService::CreateParams::Discount::DiscountEnd)) }
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::QuoteService::CreateParams::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class FromQuote < Stripe::RequestParams
# Whether this quote is a revision of the previous quote.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :is_revision
# The `id` of the quote that will be cloned.
sig { returns(String) }
attr_accessor :quote
sig { params(is_revision: T.nilable(T::Boolean), quote: String).void }
def initialize(is_revision: nil, quote: nil); end
end
class InvoiceSettings < Stripe::RequestParams
class Issuer < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# Number of days within which a customer must pay the invoice generated by this quote. This value will be `null` for quotes where `collection_method=charge_automatically`.
sig { returns(T.nilable(Integer)) }
attr_accessor :days_until_due
# The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
sig { returns(T.nilable(::Stripe::QuoteService::CreateParams::InvoiceSettings::Issuer)) }
attr_accessor :issuer
sig {
params(days_until_due: T.nilable(Integer), issuer: T.nilable(::Stripe::QuoteService::CreateParams::InvoiceSettings::Issuer)).void
}
def initialize(days_until_due: nil, issuer: nil); end
end
class Line < Stripe::RequestParams
class Action < Stripe::RequestParams
class AddDiscount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
# The coupon code to redeem.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# An ID of an existing discount for a coupon that was already redeemed.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::QuoteService::CreateParams::Line::Action::AddDiscount::DiscountEnd))
}
attr_accessor :discount_end
# The index, starting at 0, at which to position the new discount. When not supplied, Stripe defaults to appending the discount to the end of the `discounts` array.
sig { returns(T.nilable(Integer)) }
attr_accessor :index
# The promotion code to redeem.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::QuoteService::CreateParams::Line::Action::AddDiscount::DiscountEnd), index: T.nilable(Integer), promotion_code: T.nilable(String)).void
}
def initialize(
coupon: nil,
discount: nil,
discount_end: nil,
index: nil,
promotion_code: nil
); end
end
class AddItem < Stripe::RequestParams
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::QuoteService::CreateParams::Line::Action::AddItem::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::QuoteService::CreateParams::Line::Action::AddItem::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::QuoteService::CreateParams::Line::Action::AddItem::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::QuoteService::CreateParams::Line::Action::AddItem::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(
coupon: nil,
discount: nil,
discount_end: nil,
promotion_code: nil
); end
end
class Trial < Stripe::RequestParams
# List of price IDs which, if present on the subscription following a paid trial, constitute opting-in to the paid trial. Currently only supports at most 1 price ID.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :converts_to
# Determines the type of trial for this item.
sig { returns(String) }
attr_accessor :type
sig { params(converts_to: T.nilable(T::Array[String]), type: String).void }
def initialize(converts_to: nil, type: nil); end
end
# The discounts applied to the item. Subscription item discounts are applied before subscription discounts.
sig {
returns(T.nilable(T::Array[::Stripe::QuoteService::CreateParams::Line::Action::AddItem::Discount]))
}
attr_accessor :discounts
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The ID of the price object.
sig { returns(String) }
attr_accessor :price
# Quantity for this item.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# The tax rates that apply to this subscription item. When set, the `default_tax_rates` on the subscription do not apply to this `subscription_item`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :tax_rates
# Options that configure the trial on the subscription item.
sig {
returns(T.nilable(::Stripe::QuoteService::CreateParams::Line::Action::AddItem::Trial))
}
attr_accessor :trial
sig {
params(discounts: T.nilable(T::Array[::Stripe::QuoteService::CreateParams::Line::Action::AddItem::Discount]), metadata: T.nilable(T::Hash[String, String]), price: String, quantity: T.nilable(Integer), tax_rates: T.nilable(T::Array[String]), trial: T.nilable(::Stripe::QuoteService::CreateParams::Line::Action::AddItem::Trial)).void
}
def initialize(
discounts: nil,
metadata: nil,
price: nil,
quantity: nil,
tax_rates: nil,
trial: nil
); end
end
class RemoveDiscount < Stripe::RequestParams
# The coupon code to remove from the `discounts` array.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# The ID of a discount to remove from the `discounts` array.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# The ID of a promotion code to remove from the `discounts` array.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, promotion_code: nil); end
end
class RemoveItem < Stripe::RequestParams
# ID of a price to remove.
sig { returns(String) }
attr_accessor :price
sig { params(price: String).void }
def initialize(price: nil); end
end
class SetDiscount < Stripe::RequestParams
# The coupon code to replace the `discounts` array with.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# An ID of an existing discount to replace the `discounts` array with.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# An ID of an existing promotion code to replace the `discounts` array with.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, promotion_code: nil); end
end
class SetItem < Stripe::RequestParams
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::QuoteService::CreateParams::Line::Action::SetItem::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::QuoteService::CreateParams::Line::Action::SetItem::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::QuoteService::CreateParams::Line::Action::SetItem::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::QuoteService::CreateParams::Line::Action::SetItem::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(
coupon: nil,
discount: nil,
discount_end: nil,
promotion_code: nil
); end
end
class Trial < Stripe::RequestParams
# List of price IDs which, if present on the subscription following a paid trial, constitute opting-in to the paid trial. Currently only supports at most 1 price ID.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :converts_to
# Determines the type of trial for this item.
sig { returns(String) }
attr_accessor :type
sig { params(converts_to: T.nilable(T::Array[String]), type: String).void }
def initialize(converts_to: nil, type: nil); end
end
# If an item with the `price` already exists, passing this will override the `discounts` array on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `discounts`.
sig {
returns(T.nilable(T::Array[::Stripe::QuoteService::CreateParams::Line::Action::SetItem::Discount]))
}
attr_accessor :discounts
# If an item with the `price` already exists, passing this will override the `metadata` on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `metadata`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The ID of the price object.
sig { returns(String) }
attr_accessor :price
# If an item with the `price` already exists, passing this will override the quantity on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `quantity`.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# If an item with the `price` already exists, passing this will override the `tax_rates` array on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `tax_rates`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :tax_rates
# If an item with the `price` already exists, passing this will override the `trial` configuration on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `trial`.
sig {
returns(T.nilable(::Stripe::QuoteService::CreateParams::Line::Action::SetItem::Trial))
}
attr_accessor :trial
sig {
params(discounts: T.nilable(T::Array[::Stripe::QuoteService::CreateParams::Line::Action::SetItem::Discount]), metadata: T.nilable(T::Hash[String, String]), price: String, quantity: T.nilable(Integer), tax_rates: T.nilable(T::Array[String]), trial: T.nilable(::Stripe::QuoteService::CreateParams::Line::Action::SetItem::Trial)).void
}
def initialize(
discounts: nil,
metadata: nil,
price: nil,
quantity: nil,
tax_rates: nil,
trial: nil
); end
end
# Details for the `add_discount` type.
sig {
returns(T.nilable(::Stripe::QuoteService::CreateParams::Line::Action::AddDiscount))
}
attr_accessor :add_discount
# Details for the `add_item` type.
sig { returns(T.nilable(::Stripe::QuoteService::CreateParams::Line::Action::AddItem)) }
attr_accessor :add_item
# Details for the `add_metadata` type: specify a hash of key-value pairs.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :add_metadata
# Details for the `remove_discount` type.
sig {
returns(T.nilable(::Stripe::QuoteService::CreateParams::Line::Action::RemoveDiscount))
}
attr_accessor :remove_discount
# Details for the `remove_item` type.
sig { returns(T.nilable(::Stripe::QuoteService::CreateParams::Line::Action::RemoveItem)) }
attr_accessor :remove_item
# Details for the `remove_metadata` type: specify an array of metadata keys.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :remove_metadata
# Details for the `set_discounts` type.
sig {
returns(T.nilable(T::Array[::Stripe::QuoteService::CreateParams::Line::Action::SetDiscount]))
}
attr_accessor :set_discounts
# Details for the `set_items` type.
sig {
returns(T.nilable(T::Array[::Stripe::QuoteService::CreateParams::Line::Action::SetItem]))
}
attr_accessor :set_items
# Details for the `set_metadata` type: specify an array of key-value pairs.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :set_metadata
# The type of action the quote line performs.
sig { returns(String) }
attr_accessor :type
sig {
params(add_discount: T.nilable(::Stripe::QuoteService::CreateParams::Line::Action::AddDiscount), add_item: T.nilable(::Stripe::QuoteService::CreateParams::Line::Action::AddItem), add_metadata: T.nilable(T::Hash[String, String]), remove_discount: T.nilable(::Stripe::QuoteService::CreateParams::Line::Action::RemoveDiscount), remove_item: T.nilable(::Stripe::QuoteService::CreateParams::Line::Action::RemoveItem), remove_metadata: T.nilable(T::Array[String]), set_discounts: T.nilable(T::Array[::Stripe::QuoteService::CreateParams::Line::Action::SetDiscount]), set_items: T.nilable(T::Array[::Stripe::QuoteService::CreateParams::Line::Action::SetItem]), set_metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), type: String).void
}
def initialize(
add_discount: nil,
add_item: nil,
add_metadata: nil,
remove_discount: nil,
remove_item: nil,
remove_metadata: nil,
set_discounts: nil,
set_items: nil,
set_metadata: nil,
type: nil
); end
end
class AppliesTo < Stripe::RequestParams
# A custom string that identifies a new subscription schedule being created upon quote acceptance. All quote lines with the same `new_reference` field will be applied to the creation of a new subscription schedule.
sig { returns(T.nilable(String)) }
attr_accessor :new_reference
# The ID of the schedule the line applies to.
sig { returns(T.nilable(String)) }
attr_accessor :subscription_schedule
# Describes whether the quote line is affecting a new schedule or an existing schedule.
sig { returns(String) }
attr_accessor :type
sig {
params(new_reference: T.nilable(String), subscription_schedule: T.nilable(String), type: String).void
}
def initialize(new_reference: nil, subscription_schedule: nil, type: nil); end
end
class CancelSubscriptionSchedule < Stripe::RequestParams
# Timestamp helper to cancel the underlying schedule on the accompanying line's start date. Must be set to `line_starts_at`.
sig { returns(String) }
attr_accessor :cancel_at
# If the subscription schedule is `active`, indicates if a final invoice will be generated that contains any un-invoiced metered usage and new/pending proration invoice items. Boolean that defaults to `true`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :invoice_now
# If the subscription schedule is `active`, indicates if the cancellation should be prorated. Boolean that defaults to `true`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :prorate
sig {
params(cancel_at: String, invoice_now: T.nilable(T::Boolean), prorate: T.nilable(T::Boolean)).void
}
def initialize(cancel_at: nil, invoice_now: nil, prorate: nil); end
end
class EndsAt < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
# The ID of a specific discount.
sig { returns(String) }
attr_accessor :discount
sig { params(discount: String).void }
def initialize(discount: nil); end
end
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Use the `end` time of a given discount.
sig {
returns(T.nilable(::Stripe::QuoteService::CreateParams::Line::EndsAt::DiscountEnd))
}
attr_accessor :discount_end
# Time span for the quote line starting from the `starts_at` date.
sig { returns(T.nilable(::Stripe::QuoteService::CreateParams::Line::EndsAt::Duration)) }
attr_accessor :duration
# A precise Unix timestamp.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# Select a way to pass in `ends_at`.
sig { returns(String) }
attr_accessor :type
sig {
params(discount_end: T.nilable(::Stripe::QuoteService::CreateParams::Line::EndsAt::DiscountEnd), duration: T.nilable(::Stripe::QuoteService::CreateParams::Line::EndsAt::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(discount_end: nil, duration: nil, timestamp: nil, type: nil); end
end
class SetPauseCollection < Stripe::RequestParams
class Set < Stripe::RequestParams
# The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`.
sig { returns(String) }
attr_accessor :behavior
sig { params(behavior: String).void }
def initialize(behavior: nil); end
end
# Details of the pause_collection behavior to apply to the amendment.
sig {
returns(T.nilable(::Stripe::QuoteService::CreateParams::Line::SetPauseCollection::Set))
}
attr_accessor :set
# Determines the type of the pause_collection amendment.
sig { returns(String) }
attr_accessor :type
sig {
params(set: T.nilable(::Stripe::QuoteService::CreateParams::Line::SetPauseCollection::Set), type: String).void
}
def initialize(set: nil, type: nil); end
end
class StartsAt < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
# The ID of a specific discount.
sig { returns(String) }
attr_accessor :discount
sig { params(discount: String).void }
def initialize(discount: nil); end
end
class LineEndsAt < Stripe::RequestParams
# The position of the previous quote line in the `lines` array after which this line should begin. Indexes start from 0 and must be less than the index of the current line in the array.
sig { returns(T.nilable(Integer)) }
attr_accessor :index
sig { params(index: T.nilable(Integer)).void }
def initialize(index: nil); end
end
# Use the `end` time of a given discount.
sig {
returns(T.nilable(::Stripe::QuoteService::CreateParams::Line::StartsAt::DiscountEnd))
}
attr_accessor :discount_end
# The timestamp the given line ends at.
sig {
returns(T.nilable(::Stripe::QuoteService::CreateParams::Line::StartsAt::LineEndsAt))
}
attr_accessor :line_ends_at
# A precise Unix timestamp.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# Select a way to pass in `starts_at`.
sig { returns(String) }
attr_accessor :type
sig {
params(discount_end: T.nilable(::Stripe::QuoteService::CreateParams::Line::StartsAt::DiscountEnd), line_ends_at: T.nilable(::Stripe::QuoteService::CreateParams::Line::StartsAt::LineEndsAt), timestamp: T.nilable(Integer), type: String).void
}
def initialize(discount_end: nil, line_ends_at: nil, timestamp: nil, type: nil); end
end
class TrialSettings < Stripe::RequestParams
class EndBehavior < Stripe::RequestParams
# Configure how an opt-in following a paid trial is billed when using `billing_behavior: prorate_up_front`.
sig { returns(T.nilable(String)) }
attr_accessor :prorate_up_front
sig { params(prorate_up_front: T.nilable(String)).void }
def initialize(prorate_up_front: nil); end
end
# Defines how the subscription should behave when a trial ends.
sig {
returns(T.nilable(::Stripe::QuoteService::CreateParams::Line::TrialSettings::EndBehavior))
}
attr_accessor :end_behavior
sig {
params(end_behavior: T.nilable(::Stripe::QuoteService::CreateParams::Line::TrialSettings::EndBehavior)).void
}
def initialize(end_behavior: nil); end
end
# An array of operations the quote line performs.
sig { returns(T.nilable(T::Array[::Stripe::QuoteService::CreateParams::Line::Action])) }
attr_accessor :actions
# Details to identify the subscription schedule the quote line applies to.
sig { returns(T.nilable(::Stripe::QuoteService::CreateParams::Line::AppliesTo)) }
attr_accessor :applies_to
# For point-in-time quote lines (having no `ends_at` timestamp), this attribute lets you set or remove whether the subscription's billing cycle anchor is reset at the Quote Line `starts_at` timestamp.For time-span based quote lines (having both `starts_at` and `ends_at`), the only valid value is `automatic`, which removes any previously configured billing cycle anchor resets during the window of time spanning the quote line.
sig { returns(T.nilable(String)) }
attr_accessor :billing_cycle_anchor
# A point-in-time operation that cancels an existing subscription schedule at the line's starts_at timestamp. Currently only compatible with `quote_acceptance_date` for `starts_at`. When using cancel_subscription_schedule, the subscription schedule on the quote remains unalterable, except for modifications to the metadata, collection_method or invoice_settings.
sig {
returns(T.nilable(::Stripe::QuoteService::CreateParams::Line::CancelSubscriptionSchedule))
}
attr_accessor :cancel_subscription_schedule
# Details to identify the end of the time range modified by the proposed change. If not supplied, the quote line is considered a point-in-time operation that only affects the exact timestamp at `starts_at`, and a restricted set of attributes is supported on the quote line.
sig { returns(T.nilable(::Stripe::QuoteService::CreateParams::Line::EndsAt)) }
attr_accessor :ends_at
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
# Defines how to pause collection for the underlying subscription throughout the duration of the amendment.
sig { returns(T.nilable(::Stripe::QuoteService::CreateParams::Line::SetPauseCollection)) }
attr_accessor :set_pause_collection
# Timestamp helper to end the underlying schedule early, based on the acompanying line's start or end date.
sig { returns(T.nilable(String)) }
attr_accessor :set_schedule_end
# Details to identify the earliest timestamp where the proposed change should take effect.
sig { returns(T.nilable(::Stripe::QuoteService::CreateParams::Line::StartsAt)) }
attr_accessor :starts_at
# Settings related to subscription trials.
sig { returns(T.nilable(::Stripe::QuoteService::CreateParams::Line::TrialSettings)) }
attr_accessor :trial_settings
sig {
params(actions: T.nilable(T::Array[::Stripe::QuoteService::CreateParams::Line::Action]), applies_to: T.nilable(::Stripe::QuoteService::CreateParams::Line::AppliesTo), billing_cycle_anchor: T.nilable(String), cancel_subscription_schedule: T.nilable(::Stripe::QuoteService::CreateParams::Line::CancelSubscriptionSchedule), ends_at: T.nilable(::Stripe::QuoteService::CreateParams::Line::EndsAt), proration_behavior: T.nilable(String), set_pause_collection: T.nilable(::Stripe::QuoteService::CreateParams::Line::SetPauseCollection), set_schedule_end: T.nilable(String), starts_at: T.nilable(::Stripe::QuoteService::CreateParams::Line::StartsAt), trial_settings: T.nilable(::Stripe::QuoteService::CreateParams::Line::TrialSettings)).void
}
def initialize(
actions: nil,
applies_to: nil,
billing_cycle_anchor: nil,
cancel_subscription_schedule: nil,
ends_at: nil,
proration_behavior: nil,
set_pause_collection: nil,
set_schedule_end: nil,
starts_at: nil,
trial_settings: nil
); end
end
class LineItem < Stripe::RequestParams
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::QuoteService::CreateParams::LineItem::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::QuoteService::CreateParams::LineItem::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::QuoteService::CreateParams::LineItem::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::QuoteService::CreateParams::LineItem::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class PriceData < Stripe::RequestParams
class Recurring < Stripe::RequestParams
# Specifies billing frequency. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: T.nilable(Integer)).void }
def initialize(interval: nil, interval_count: nil); end
end
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
sig { returns(String) }
attr_accessor :product
# The recurring components of a price such as `interval` and `interval_count`.
sig {
returns(T.nilable(::Stripe::QuoteService::CreateParams::LineItem::PriceData::Recurring))
}
attr_accessor :recurring
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, product: String, recurring: T.nilable(::Stripe::QuoteService::CreateParams::LineItem::PriceData::Recurring), tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
recurring: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
# The discounts applied to this line item.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::QuoteService::CreateParams::LineItem::Discount]))))
}
attr_accessor :discounts
# The ID of the price object. One of `price` or `price_data` is required.
sig { returns(T.nilable(String)) }
attr_accessor :price
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
sig { returns(T.nilable(::Stripe::QuoteService::CreateParams::LineItem::PriceData)) }
attr_accessor :price_data
# The quantity of the line item.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# The tax rates which apply to the line item. When set, the `default_tax_rates` on the quote do not apply to this line item.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
sig {
params(discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::QuoteService::CreateParams::LineItem::Discount]))), price: T.nilable(String), price_data: T.nilable(::Stripe::QuoteService::CreateParams::LineItem::PriceData), quantity: T.nilable(Integer), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String])))).void
}
def initialize(
discounts: nil,
price: nil,
price_data: nil,
quantity: nil,
tax_rates: nil
); end
end
class SubscriptionData < Stripe::RequestParams
class BillOnAcceptance < Stripe::RequestParams
class BillFrom < Stripe::RequestParams
class LineStartsAt < Stripe::RequestParams
# The ID of a quote line.
sig { returns(T.nilable(String)) }
attr_accessor :id
# The position of the previous quote line in the `lines` array after which this line should begin. Indexes start from 0 and must be less than the index of the current line in the array.
sig { returns(T.nilable(Integer)) }
attr_accessor :index
sig { params(id: T.nilable(String), index: T.nilable(Integer)).void }
def initialize(id: nil, index: nil); end
end
# Details of a Quote line to start the bill period from.
sig {
returns(T.nilable(::Stripe::QuoteService::CreateParams::SubscriptionData::BillOnAcceptance::BillFrom::LineStartsAt))
}
attr_accessor :line_starts_at
# A precise Unix timestamp.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of method to specify the `bill_from` time.
sig { returns(String) }
attr_accessor :type
sig {
params(line_starts_at: T.nilable(::Stripe::QuoteService::CreateParams::SubscriptionData::BillOnAcceptance::BillFrom::LineStartsAt), timestamp: T.nilable(Integer), type: String).void
}
def initialize(line_starts_at: nil, timestamp: nil, type: nil); end
end
class BillUntil < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
class LineEndsAt < Stripe::RequestParams
# The ID of a quote line.
sig { returns(T.nilable(String)) }
attr_accessor :id
# The position of the previous quote line in the `lines` array after which this line should begin. Indexes start from 0 and must be less than the index of the current line in the array.
sig { returns(T.nilable(Integer)) }
attr_accessor :index
sig { params(id: T.nilable(String), index: T.nilable(Integer)).void }
def initialize(id: nil, index: nil); end
end
# Details of the duration over which to bill.
sig {
returns(T.nilable(::Stripe::QuoteService::CreateParams::SubscriptionData::BillOnAcceptance::BillUntil::Duration))
}
attr_accessor :duration
# Details of a Quote line item from which to bill until.
sig {
returns(T.nilable(::Stripe::QuoteService::CreateParams::SubscriptionData::BillOnAcceptance::BillUntil::LineEndsAt))
}
attr_accessor :line_ends_at
# A precise Unix timestamp.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of method to specify the `bill_until` time.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::QuoteService::CreateParams::SubscriptionData::BillOnAcceptance::BillUntil::Duration), line_ends_at: T.nilable(::Stripe::QuoteService::CreateParams::SubscriptionData::BillOnAcceptance::BillUntil::LineEndsAt), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, line_ends_at: nil, timestamp: nil, type: nil); end
end
# The start of the period to bill from when the Quote is accepted.
sig {
returns(T.nilable(::Stripe::QuoteService::CreateParams::SubscriptionData::BillOnAcceptance::BillFrom))
}
attr_accessor :bill_from
# The end of the period to bill until when the Quote is accepted.
sig {
returns(T.nilable(::Stripe::QuoteService::CreateParams::SubscriptionData::BillOnAcceptance::BillUntil))
}
attr_accessor :bill_until
sig {
params(bill_from: T.nilable(::Stripe::QuoteService::CreateParams::SubscriptionData::BillOnAcceptance::BillFrom), bill_until: T.nilable(::Stripe::QuoteService::CreateParams::SubscriptionData::BillOnAcceptance::BillUntil)).void
}
def initialize(bill_from: nil, bill_until: nil); end
end
class Prebilling < Stripe::RequestParams
# This is used to determine the number of billing cycles to prebill.
sig { returns(Integer) }
attr_accessor :iterations
sig { params(iterations: Integer).void }
def initialize(iterations: nil); end
end
# Describes the period to bill for upon accepting the quote.
sig {
returns(T.nilable(::Stripe::QuoteService::CreateParams::SubscriptionData::BillOnAcceptance))
}
attr_accessor :bill_on_acceptance
# Configures when the subscription schedule generates prorations for phase transitions. Possible values are `prorate_on_next_phase` or `prorate_up_front` with the default being `prorate_on_next_phase`. `prorate_on_next_phase` will apply phase changes and generate prorations at transition time. `prorate_up_front` will bill for all phases within the current billing cycle up front.
sig { returns(T.nilable(String)) }
attr_accessor :billing_behavior
# When specified as `reset`, the subscription will always start a new billing period when the quote is accepted.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :billing_cycle_anchor
# Controls how prorations and invoices for subscriptions are calculated and orchestrated.
sig { returns(T.nilable(String)) }
attr_accessor :billing_mode
# The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
sig { returns(T.nilable(String)) }
attr_accessor :description
# When creating a new subscription, the date of which the subscription schedule will start after the quote is accepted. When updating a subscription, the date of which the subscription will be updated using a subscription schedule. The special value `current_period_end` can be provided to update a subscription at the end of its current period. The `effective_date` is ignored if it is in the past when the quote is accepted.
sig { returns(T.nilable(T.nilable(T.any(String, T.any(String, Integer))))) }
attr_accessor :effective_date
# Behavior of the subscription schedule and underlying subscription when it ends.
sig { returns(T.nilable(String)) }
attr_accessor :end_behavior
# The id of a subscription that the quote will update. By default, the quote will contain the state of the subscription (such as line items, collection method and billing thresholds) unless overridden.
sig { returns(T.nilable(String)) }
attr_accessor :from_subscription
# Set of [key-value pairs](https://stripe.com/docs/api/metadata) that will set metadata on the subscription or subscription schedule when the quote is accepted. If a recurring price is included in `line_items`, this field will be passed to the resulting subscription's `metadata` field. If `subscription_data.effective_date` is used, this field will be passed to the resulting subscription schedule's `phases.metadata` field. Unlike object-level metadata, this field is declarative. Updates will clear prior values.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# If specified, the invoicing for the given billing cycle iterations will be processed when the quote is accepted. Cannot be used with `effective_date`.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::QuoteService::CreateParams::SubscriptionData::Prebilling))))
}
attr_accessor :prebilling
# Determines how to handle [prorations](https://stripe.com/docs/subscriptions/billing-cycle#prorations). When creating a subscription, valid values are `create_prorations` or `none`.
#
# When updating a subscription, valid values are `create_prorations`, `none`, or `always_invoice`.
#
# Passing `create_prorations` will cause proration invoice items to be created when applicable. These proration items will only be invoiced immediately under [certain conditions](https://stripe.com/docs/subscriptions/upgrading-downgrading#immediate-payment). In order to always invoice immediately for prorations, pass `always_invoice`.
#
# Prorations can be disabled by passing `none`.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
# Integer representing the number of trial period days before the customer is charged for the first time.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :trial_period_days
sig {
params(bill_on_acceptance: T.nilable(::Stripe::QuoteService::CreateParams::SubscriptionData::BillOnAcceptance), billing_behavior: T.nilable(String), billing_cycle_anchor: T.nilable(T.nilable(String)), billing_mode: T.nilable(String), description: T.nilable(String), effective_date: T.nilable(T.nilable(T.any(String, T.any(String, Integer)))), end_behavior: T.nilable(String), from_subscription: T.nilable(String), metadata: T.nilable(T::Hash[String, String]), prebilling: T.nilable(T.nilable(T.any(String, ::Stripe::QuoteService::CreateParams::SubscriptionData::Prebilling))), proration_behavior: T.nilable(String), trial_period_days: T.nilable(T.nilable(T.any(String, Integer)))).void
}
def initialize(
bill_on_acceptance: nil,
billing_behavior: nil,
billing_cycle_anchor: nil,
billing_mode: nil,
description: nil,
effective_date: nil,
end_behavior: nil,
from_subscription: nil,
metadata: nil,
prebilling: nil,
proration_behavior: nil,
trial_period_days: nil
); end
end
class SubscriptionDataOverride < Stripe::RequestParams
class AppliesTo < Stripe::RequestParams
# A custom string that identifies a new subscription schedule being created upon quote acceptance. All quote lines with the same `new_reference` field will be applied to the creation of a new subscription schedule.
sig { returns(T.nilable(String)) }
attr_accessor :new_reference
# The ID of the schedule the line applies to.
sig { returns(T.nilable(String)) }
attr_accessor :subscription_schedule
# Describes whether the quote line is affecting a new schedule or an existing schedule.
sig { returns(String) }
attr_accessor :type
sig {
params(new_reference: T.nilable(String), subscription_schedule: T.nilable(String), type: String).void
}
def initialize(new_reference: nil, subscription_schedule: nil, type: nil); end
end
class BillOnAcceptance < Stripe::RequestParams
class BillFrom < Stripe::RequestParams
class LineStartsAt < Stripe::RequestParams
# The ID of a quote line.
sig { returns(T.nilable(String)) }
attr_accessor :id
# The position of the previous quote line in the `lines` array after which this line should begin. Indexes start from 0 and must be less than the index of the current line in the array.
sig { returns(T.nilable(Integer)) }
attr_accessor :index
sig { params(id: T.nilable(String), index: T.nilable(Integer)).void }
def initialize(id: nil, index: nil); end
end
# Details of a Quote line to start the bill period from.
sig {
returns(T.nilable(::Stripe::QuoteService::CreateParams::SubscriptionDataOverride::BillOnAcceptance::BillFrom::LineStartsAt))
}
attr_accessor :line_starts_at
# A precise Unix timestamp.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of method to specify the `bill_from` time.
sig { returns(String) }
attr_accessor :type
sig {
params(line_starts_at: T.nilable(::Stripe::QuoteService::CreateParams::SubscriptionDataOverride::BillOnAcceptance::BillFrom::LineStartsAt), timestamp: T.nilable(Integer), type: String).void
}
def initialize(line_starts_at: nil, timestamp: nil, type: nil); end
end
class BillUntil < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
class LineEndsAt < Stripe::RequestParams
# The ID of a quote line.
sig { returns(T.nilable(String)) }
attr_accessor :id
# The position of the previous quote line in the `lines` array after which this line should begin. Indexes start from 0 and must be less than the index of the current line in the array.
sig { returns(T.nilable(Integer)) }
attr_accessor :index
sig { params(id: T.nilable(String), index: T.nilable(Integer)).void }
def initialize(id: nil, index: nil); end
end
# Details of the duration over which to bill.
sig {
returns(T.nilable(::Stripe::QuoteService::CreateParams::SubscriptionDataOverride::BillOnAcceptance::BillUntil::Duration))
}
attr_accessor :duration
# Details of a Quote line item from which to bill until.
sig {
returns(T.nilable(::Stripe::QuoteService::CreateParams::SubscriptionDataOverride::BillOnAcceptance::BillUntil::LineEndsAt))
}
attr_accessor :line_ends_at
# A precise Unix timestamp.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of method to specify the `bill_until` time.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::QuoteService::CreateParams::SubscriptionDataOverride::BillOnAcceptance::BillUntil::Duration), line_ends_at: T.nilable(::Stripe::QuoteService::CreateParams::SubscriptionDataOverride::BillOnAcceptance::BillUntil::LineEndsAt), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, line_ends_at: nil, timestamp: nil, type: nil); end
end
# The start of the period to bill from when the Quote is accepted.
sig {
returns(T.nilable(::Stripe::QuoteService::CreateParams::SubscriptionDataOverride::BillOnAcceptance::BillFrom))
}
attr_accessor :bill_from
# The end of the period to bill until when the Quote is accepted.
sig {
returns(T.nilable(::Stripe::QuoteService::CreateParams::SubscriptionDataOverride::BillOnAcceptance::BillUntil))
}
attr_accessor :bill_until
sig {
params(bill_from: T.nilable(::Stripe::QuoteService::CreateParams::SubscriptionDataOverride::BillOnAcceptance::BillFrom), bill_until: T.nilable(::Stripe::QuoteService::CreateParams::SubscriptionDataOverride::BillOnAcceptance::BillUntil)).void
}
def initialize(bill_from: nil, bill_until: nil); end
end
# Whether the override applies to an existing Subscription Schedule or a new Subscription Schedule.
sig { returns(::Stripe::QuoteService::CreateParams::SubscriptionDataOverride::AppliesTo) }
attr_accessor :applies_to
# Describes the period to bill for upon accepting the quote.
sig {
returns(T.nilable(::Stripe::QuoteService::CreateParams::SubscriptionDataOverride::BillOnAcceptance))
}
attr_accessor :bill_on_acceptance
# Configures when the subscription schedule generates prorations for phase transitions. Possible values are `prorate_on_next_phase` or `prorate_up_front` with the default being `prorate_on_next_phase`. `prorate_on_next_phase` will apply phase changes and generate prorations at transition time. `prorate_up_front` will bill for all phases within the current billing cycle up front.
sig { returns(T.nilable(String)) }
attr_accessor :billing_behavior
# The customer the Subscription Data override applies to. This is only relevant when `applies_to.type=new_reference`.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Behavior of the subscription schedule and underlying subscription when it ends.
sig { returns(T.nilable(String)) }
attr_accessor :end_behavior
# Determines how to handle [prorations](https://stripe.com/docs/subscriptions/billing-cycle#prorations). When creating a subscription, valid values are `create_prorations` or `none`.
#
# When updating a subscription, valid values are `create_prorations`, `none`, or `always_invoice`.
#
# Passing `create_prorations` will cause proration invoice items to be created when applicable. These proration items will only be invoiced immediately under [certain conditions](https://stripe.com/docs/subscriptions/upgrading-downgrading#immediate-payment). In order to always invoice immediately for prorations, pass `always_invoice`.
#
# Prorations can be disabled by passing `none`.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
sig {
params(applies_to: ::Stripe::QuoteService::CreateParams::SubscriptionDataOverride::AppliesTo, bill_on_acceptance: T.nilable(::Stripe::QuoteService::CreateParams::SubscriptionDataOverride::BillOnAcceptance), billing_behavior: T.nilable(String), customer: T.nilable(String), description: T.nilable(String), end_behavior: T.nilable(String), proration_behavior: T.nilable(String)).void
}
def initialize(
applies_to: nil,
bill_on_acceptance: nil,
billing_behavior: nil,
customer: nil,
description: nil,
end_behavior: nil,
proration_behavior: nil
); end
end
class TransferData < Stripe::RequestParams
# The amount that will be transferred automatically when the invoice is paid. If no amount is set, the full amount is transferred. There cannot be any line items with recurring prices when using this field.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination. There must be at least 1 line item with a recurring price to use this field.
sig { returns(T.nilable(Float)) }
attr_accessor :amount_percent
# ID of an existing, connected Stripe account.
sig { returns(String) }
attr_accessor :destination
sig {
params(amount: T.nilable(Integer), amount_percent: T.nilable(Float), destination: String).void
}
def initialize(amount: nil, amount_percent: nil, destination: nil); end
end
# Set to true to allow quote lines to have `starts_at` in the past if collection is paused between `starts_at` and now.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :allow_backdated_lines
# The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. There cannot be any line items with recurring prices when using this field.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :application_fee_amount
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. There must be at least 1 line item with a recurring price to use this field.
sig { returns(T.nilable(T.nilable(T.any(String, Float)))) }
attr_accessor :application_fee_percent
# Settings for automatic tax lookup for this quote and resulting invoices and subscriptions.
sig { returns(T.nilable(::Stripe::QuoteService::CreateParams::AutomaticTax)) }
attr_accessor :automatic_tax
# Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay invoices at the end of the subscription cycle or at invoice finalization using the default payment method attached to the subscription or customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically`.
sig { returns(T.nilable(String)) }
attr_accessor :collection_method
# The customer for which this quote belongs to. A customer is required before finalizing the quote. Once specified, it cannot be changed.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# The account for which this quote belongs to. A customer or account is required before finalizing the quote. Once specified, it cannot be changed.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# The tax rates that will apply to any line item that does not have `tax_rates` set.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :default_tax_rates
# A description that will be displayed on the quote PDF. If no value is passed, the default description configured in your [quote template settings](https://dashboard.stripe.com/settings/billing/quote) will be used.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :description
# The discounts applied to the quote.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::QuoteService::CreateParams::Discount]))))
}
attr_accessor :discounts
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A future timestamp on which the quote will be canceled if in `open` or `draft` status. Measured in seconds since the Unix epoch. If no value is passed, the default expiration date configured in your [quote template settings](https://dashboard.stripe.com/settings/billing/quote) will be used.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_at
# A footer that will be displayed on the quote PDF. If no value is passed, the default footer configured in your [quote template settings](https://dashboard.stripe.com/settings/billing/quote) will be used.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :footer
# Clone an existing quote. The new quote will be created in `status=draft`. When using this parameter, you cannot specify any other parameters except for `expires_at`.
sig { returns(T.nilable(::Stripe::QuoteService::CreateParams::FromQuote)) }
attr_accessor :from_quote
# A header that will be displayed on the quote PDF. If no value is passed, the default header configured in your [quote template settings](https://dashboard.stripe.com/settings/billing/quote) will be used.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :header
# All invoices will be billed using the specified settings.
sig { returns(T.nilable(::Stripe::QuoteService::CreateParams::InvoiceSettings)) }
attr_accessor :invoice_settings
# A list of line items the customer is being quoted for. Each line item includes information about the product, the quantity, and the resulting cost.
sig { returns(T.nilable(T::Array[::Stripe::QuoteService::CreateParams::LineItem])) }
attr_accessor :line_items
# A list of [quote lines](https://docs.stripe.com/api/quote_lines) on the quote. These lines describe changes, in the order provided, that will be used to create new subscription schedules or update existing subscription schedules when the quote is accepted.
sig { returns(T.nilable(T::Array[::Stripe::QuoteService::CreateParams::Line])) }
attr_accessor :lines
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The account on behalf of which to charge.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :on_behalf_of
# When creating a subscription or subscription schedule, the specified configuration data will be used. There must be at least one line item with a recurring price for a subscription or subscription schedule to be created. A subscription schedule is created if `subscription_data[effective_date]` is present and in the future, otherwise a subscription is created.
sig { returns(T.nilable(::Stripe::QuoteService::CreateParams::SubscriptionData)) }
attr_accessor :subscription_data
# List representing overrides for `subscription_data` configurations for specific subscription schedules.
sig {
returns(T.nilable(T::Array[::Stripe::QuoteService::CreateParams::SubscriptionDataOverride]))
}
attr_accessor :subscription_data_overrides
# ID of the test clock to attach to the quote.
sig { returns(T.nilable(String)) }
attr_accessor :test_clock
# The data with which to automatically create a Transfer for each of the invoices.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::QuoteService::CreateParams::TransferData))))
}
attr_accessor :transfer_data
sig {
params(allow_backdated_lines: T.nilable(T::Boolean), application_fee_amount: T.nilable(T.nilable(T.any(String, Integer))), application_fee_percent: T.nilable(T.nilable(T.any(String, Float))), automatic_tax: T.nilable(::Stripe::QuoteService::CreateParams::AutomaticTax), collection_method: T.nilable(String), customer: T.nilable(String), customer_account: T.nilable(String), default_tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String]))), description: T.nilable(T.nilable(String)), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::QuoteService::CreateParams::Discount]))), expand: T.nilable(T::Array[String]), expires_at: T.nilable(Integer), footer: T.nilable(T.nilable(String)), from_quote: T.nilable(::Stripe::QuoteService::CreateParams::FromQuote), header: T.nilable(T.nilable(String)), invoice_settings: T.nilable(::Stripe::QuoteService::CreateParams::InvoiceSettings), line_items: T.nilable(T::Array[::Stripe::QuoteService::CreateParams::LineItem]), lines: T.nilable(T::Array[::Stripe::QuoteService::CreateParams::Line]), metadata: T.nilable(T::Hash[String, String]), on_behalf_of: T.nilable(T.nilable(String)), subscription_data: T.nilable(::Stripe::QuoteService::CreateParams::SubscriptionData), subscription_data_overrides: T.nilable(T::Array[::Stripe::QuoteService::CreateParams::SubscriptionDataOverride]), test_clock: T.nilable(String), transfer_data: T.nilable(T.nilable(T.any(String, ::Stripe::QuoteService::CreateParams::TransferData)))).void
}
def initialize(
allow_backdated_lines: nil,
application_fee_amount: nil,
application_fee_percent: nil,
automatic_tax: nil,
collection_method: nil,
customer: nil,
customer_account: nil,
default_tax_rates: nil,
description: nil,
discounts: nil,
expand: nil,
expires_at: nil,
footer: nil,
from_quote: nil,
header: nil,
invoice_settings: nil,
line_items: nil,
lines: nil,
metadata: nil,
on_behalf_of: nil,
subscription_data: nil,
subscription_data_overrides: nil,
test_clock: nil,
transfer_data: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
class AutomaticTax < Stripe::RequestParams
class Liability < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# Controls whether Stripe will automatically compute tax on the resulting invoices or subscriptions as well as the quote itself.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
sig { returns(T.nilable(::Stripe::QuoteService::UpdateParams::AutomaticTax::Liability)) }
attr_accessor :liability
sig {
params(enabled: T::Boolean, liability: T.nilable(::Stripe::QuoteService::UpdateParams::AutomaticTax::Liability)).void
}
def initialize(enabled: nil, liability: nil); end
end
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::QuoteService::UpdateParams::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::QuoteService::UpdateParams::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig { returns(T.nilable(::Stripe::QuoteService::UpdateParams::Discount::DiscountEnd)) }
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::QuoteService::UpdateParams::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class InvoiceSettings < Stripe::RequestParams
class Issuer < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# Number of days within which a customer must pay the invoice generated by this quote. This value will be `null` for quotes where `collection_method=charge_automatically`.
sig { returns(T.nilable(Integer)) }
attr_accessor :days_until_due
# The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
sig { returns(T.nilable(::Stripe::QuoteService::UpdateParams::InvoiceSettings::Issuer)) }
attr_accessor :issuer
sig {
params(days_until_due: T.nilable(Integer), issuer: T.nilable(::Stripe::QuoteService::UpdateParams::InvoiceSettings::Issuer)).void
}
def initialize(days_until_due: nil, issuer: nil); end
end
class Line < Stripe::RequestParams
class Action < Stripe::RequestParams
class AddDiscount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
# The coupon code to redeem.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# An ID of an existing discount for a coupon that was already redeemed.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::QuoteService::UpdateParams::Line::Action::AddDiscount::DiscountEnd))
}
attr_accessor :discount_end
# The index, starting at 0, at which to position the new discount. When not supplied, Stripe defaults to appending the discount to the end of the `discounts` array.
sig { returns(T.nilable(Integer)) }
attr_accessor :index
# The promotion code to redeem.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::QuoteService::UpdateParams::Line::Action::AddDiscount::DiscountEnd), index: T.nilable(Integer), promotion_code: T.nilable(String)).void
}
def initialize(
coupon: nil,
discount: nil,
discount_end: nil,
index: nil,
promotion_code: nil
); end
end
class AddItem < Stripe::RequestParams
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::QuoteService::UpdateParams::Line::Action::AddItem::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::QuoteService::UpdateParams::Line::Action::AddItem::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::QuoteService::UpdateParams::Line::Action::AddItem::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::QuoteService::UpdateParams::Line::Action::AddItem::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(
coupon: nil,
discount: nil,
discount_end: nil,
promotion_code: nil
); end
end
class Trial < Stripe::RequestParams
# List of price IDs which, if present on the subscription following a paid trial, constitute opting-in to the paid trial. Currently only supports at most 1 price ID.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :converts_to
# Determines the type of trial for this item.
sig { returns(String) }
attr_accessor :type
sig { params(converts_to: T.nilable(T::Array[String]), type: String).void }
def initialize(converts_to: nil, type: nil); end
end
# The discounts applied to the item. Subscription item discounts are applied before subscription discounts.
sig {
returns(T.nilable(T::Array[::Stripe::QuoteService::UpdateParams::Line::Action::AddItem::Discount]))
}
attr_accessor :discounts
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The ID of the price object.
sig { returns(String) }
attr_accessor :price
# Quantity for this item.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# The tax rates that apply to this subscription item. When set, the `default_tax_rates` on the subscription do not apply to this `subscription_item`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :tax_rates
# Options that configure the trial on the subscription item.
sig {
returns(T.nilable(::Stripe::QuoteService::UpdateParams::Line::Action::AddItem::Trial))
}
attr_accessor :trial
sig {
params(discounts: T.nilable(T::Array[::Stripe::QuoteService::UpdateParams::Line::Action::AddItem::Discount]), metadata: T.nilable(T::Hash[String, String]), price: String, quantity: T.nilable(Integer), tax_rates: T.nilable(T::Array[String]), trial: T.nilable(::Stripe::QuoteService::UpdateParams::Line::Action::AddItem::Trial)).void
}
def initialize(
discounts: nil,
metadata: nil,
price: nil,
quantity: nil,
tax_rates: nil,
trial: nil
); end
end
class RemoveDiscount < Stripe::RequestParams
# The coupon code to remove from the `discounts` array.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# The ID of a discount to remove from the `discounts` array.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# The ID of a promotion code to remove from the `discounts` array.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, promotion_code: nil); end
end
class RemoveItem < Stripe::RequestParams
# ID of a price to remove.
sig { returns(String) }
attr_accessor :price
sig { params(price: String).void }
def initialize(price: nil); end
end
class SetDiscount < Stripe::RequestParams
# The coupon code to replace the `discounts` array with.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# An ID of an existing discount to replace the `discounts` array with.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# An ID of an existing promotion code to replace the `discounts` array with.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, promotion_code: nil); end
end
class SetItem < Stripe::RequestParams
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::QuoteService::UpdateParams::Line::Action::SetItem::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::QuoteService::UpdateParams::Line::Action::SetItem::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::QuoteService::UpdateParams::Line::Action::SetItem::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::QuoteService::UpdateParams::Line::Action::SetItem::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(
coupon: nil,
discount: nil,
discount_end: nil,
promotion_code: nil
); end
end
class Trial < Stripe::RequestParams
# List of price IDs which, if present on the subscription following a paid trial, constitute opting-in to the paid trial. Currently only supports at most 1 price ID.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :converts_to
# Determines the type of trial for this item.
sig { returns(String) }
attr_accessor :type
sig { params(converts_to: T.nilable(T::Array[String]), type: String).void }
def initialize(converts_to: nil, type: nil); end
end
# If an item with the `price` already exists, passing this will override the `discounts` array on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `discounts`.
sig {
returns(T.nilable(T::Array[::Stripe::QuoteService::UpdateParams::Line::Action::SetItem::Discount]))
}
attr_accessor :discounts
# If an item with the `price` already exists, passing this will override the `metadata` on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `metadata`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The ID of the price object.
sig { returns(String) }
attr_accessor :price
# If an item with the `price` already exists, passing this will override the quantity on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `quantity`.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# If an item with the `price` already exists, passing this will override the `tax_rates` array on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `tax_rates`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :tax_rates
# If an item with the `price` already exists, passing this will override the `trial` configuration on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `trial`.
sig {
returns(T.nilable(::Stripe::QuoteService::UpdateParams::Line::Action::SetItem::Trial))
}
attr_accessor :trial
sig {
params(discounts: T.nilable(T::Array[::Stripe::QuoteService::UpdateParams::Line::Action::SetItem::Discount]), metadata: T.nilable(T::Hash[String, String]), price: String, quantity: T.nilable(Integer), tax_rates: T.nilable(T::Array[String]), trial: T.nilable(::Stripe::QuoteService::UpdateParams::Line::Action::SetItem::Trial)).void
}
def initialize(
discounts: nil,
metadata: nil,
price: nil,
quantity: nil,
tax_rates: nil,
trial: nil
); end
end
# Details for the `add_discount` type.
sig {
returns(T.nilable(::Stripe::QuoteService::UpdateParams::Line::Action::AddDiscount))
}
attr_accessor :add_discount
# Details for the `add_item` type.
sig { returns(T.nilable(::Stripe::QuoteService::UpdateParams::Line::Action::AddItem)) }
attr_accessor :add_item
# Details for the `add_metadata` type: specify a hash of key-value pairs.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :add_metadata
# Details for the `remove_discount` type.
sig {
returns(T.nilable(::Stripe::QuoteService::UpdateParams::Line::Action::RemoveDiscount))
}
attr_accessor :remove_discount
# Details for the `remove_item` type.
sig { returns(T.nilable(::Stripe::QuoteService::UpdateParams::Line::Action::RemoveItem)) }
attr_accessor :remove_item
# Details for the `remove_metadata` type: specify an array of metadata keys.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :remove_metadata
# Details for the `set_discounts` type.
sig {
returns(T.nilable(T::Array[::Stripe::QuoteService::UpdateParams::Line::Action::SetDiscount]))
}
attr_accessor :set_discounts
# Details for the `set_items` type.
sig {
returns(T.nilable(T::Array[::Stripe::QuoteService::UpdateParams::Line::Action::SetItem]))
}
attr_accessor :set_items
# Details for the `set_metadata` type: specify an array of key-value pairs.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :set_metadata
# The type of action the quote line performs.
sig { returns(String) }
attr_accessor :type
sig {
params(add_discount: T.nilable(::Stripe::QuoteService::UpdateParams::Line::Action::AddDiscount), add_item: T.nilable(::Stripe::QuoteService::UpdateParams::Line::Action::AddItem), add_metadata: T.nilable(T::Hash[String, String]), remove_discount: T.nilable(::Stripe::QuoteService::UpdateParams::Line::Action::RemoveDiscount), remove_item: T.nilable(::Stripe::QuoteService::UpdateParams::Line::Action::RemoveItem), remove_metadata: T.nilable(T::Array[String]), set_discounts: T.nilable(T::Array[::Stripe::QuoteService::UpdateParams::Line::Action::SetDiscount]), set_items: T.nilable(T::Array[::Stripe::QuoteService::UpdateParams::Line::Action::SetItem]), set_metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), type: String).void
}
def initialize(
add_discount: nil,
add_item: nil,
add_metadata: nil,
remove_discount: nil,
remove_item: nil,
remove_metadata: nil,
set_discounts: nil,
set_items: nil,
set_metadata: nil,
type: nil
); end
end
class AppliesTo < Stripe::RequestParams
# A custom string that identifies a new subscription schedule being created upon quote acceptance. All quote lines with the same `new_reference` field will be applied to the creation of a new subscription schedule.
sig { returns(T.nilable(String)) }
attr_accessor :new_reference
# The ID of the schedule the line applies to.
sig { returns(T.nilable(String)) }
attr_accessor :subscription_schedule
# Describes whether the quote line is affecting a new schedule or an existing schedule.
sig { returns(String) }
attr_accessor :type
sig {
params(new_reference: T.nilable(String), subscription_schedule: T.nilable(String), type: String).void
}
def initialize(new_reference: nil, subscription_schedule: nil, type: nil); end
end
class CancelSubscriptionSchedule < Stripe::RequestParams
# Timestamp helper to cancel the underlying schedule on the accompanying line's start date. Must be set to `line_starts_at`.
sig { returns(String) }
attr_accessor :cancel_at
# If the subscription schedule is `active`, indicates if a final invoice will be generated that contains any un-invoiced metered usage and new/pending proration invoice items. Boolean that defaults to `true`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :invoice_now
# If the subscription schedule is `active`, indicates if the cancellation should be prorated. Boolean that defaults to `true`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :prorate
sig {
params(cancel_at: String, invoice_now: T.nilable(T::Boolean), prorate: T.nilable(T::Boolean)).void
}
def initialize(cancel_at: nil, invoice_now: nil, prorate: nil); end
end
class EndsAt < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
# The ID of a specific discount.
sig { returns(String) }
attr_accessor :discount
sig { params(discount: String).void }
def initialize(discount: nil); end
end
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Use the `end` time of a given discount.
sig {
returns(T.nilable(::Stripe::QuoteService::UpdateParams::Line::EndsAt::DiscountEnd))
}
attr_accessor :discount_end
# Time span for the quote line starting from the `starts_at` date.
sig { returns(T.nilable(::Stripe::QuoteService::UpdateParams::Line::EndsAt::Duration)) }
attr_accessor :duration
# A precise Unix timestamp.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# Select a way to pass in `ends_at`.
sig { returns(String) }
attr_accessor :type
sig {
params(discount_end: T.nilable(::Stripe::QuoteService::UpdateParams::Line::EndsAt::DiscountEnd), duration: T.nilable(::Stripe::QuoteService::UpdateParams::Line::EndsAt::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(discount_end: nil, duration: nil, timestamp: nil, type: nil); end
end
class SetPauseCollection < Stripe::RequestParams
class Set < Stripe::RequestParams
# The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`.
sig { returns(String) }
attr_accessor :behavior
sig { params(behavior: String).void }
def initialize(behavior: nil); end
end
# Details of the pause_collection behavior to apply to the amendment.
sig {
returns(T.nilable(::Stripe::QuoteService::UpdateParams::Line::SetPauseCollection::Set))
}
attr_accessor :set
# Determines the type of the pause_collection amendment.
sig { returns(String) }
attr_accessor :type
sig {
params(set: T.nilable(::Stripe::QuoteService::UpdateParams::Line::SetPauseCollection::Set), type: String).void
}
def initialize(set: nil, type: nil); end
end
class StartsAt < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
# The ID of a specific discount.
sig { returns(String) }
attr_accessor :discount
sig { params(discount: String).void }
def initialize(discount: nil); end
end
class LineEndsAt < Stripe::RequestParams
# The ID of a quote line.
sig { returns(T.nilable(String)) }
attr_accessor :id
# The position of the previous quote line in the `lines` array after which this line should begin. Indexes start from 0 and must be less than the index of the current line in the array.
sig { returns(T.nilable(Integer)) }
attr_accessor :index
sig { params(id: T.nilable(String), index: T.nilable(Integer)).void }
def initialize(id: nil, index: nil); end
end
# Use the `end` time of a given discount.
sig {
returns(T.nilable(::Stripe::QuoteService::UpdateParams::Line::StartsAt::DiscountEnd))
}
attr_accessor :discount_end
# The timestamp the given line ends at.
sig {
returns(T.nilable(::Stripe::QuoteService::UpdateParams::Line::StartsAt::LineEndsAt))
}
attr_accessor :line_ends_at
# A precise Unix timestamp.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# Select a way to pass in `starts_at`.
sig { returns(String) }
attr_accessor :type
sig {
params(discount_end: T.nilable(::Stripe::QuoteService::UpdateParams::Line::StartsAt::DiscountEnd), line_ends_at: T.nilable(::Stripe::QuoteService::UpdateParams::Line::StartsAt::LineEndsAt), timestamp: T.nilable(Integer), type: String).void
}
def initialize(discount_end: nil, line_ends_at: nil, timestamp: nil, type: nil); end
end
class TrialSettings < Stripe::RequestParams
class EndBehavior < Stripe::RequestParams
# Configure how an opt-in following a paid trial is billed when using `billing_behavior: prorate_up_front`.
sig { returns(T.nilable(String)) }
attr_accessor :prorate_up_front
sig { params(prorate_up_front: T.nilable(String)).void }
def initialize(prorate_up_front: nil); end
end
# Defines how the subscription should behave when a trial ends.
sig {
returns(T.nilable(::Stripe::QuoteService::UpdateParams::Line::TrialSettings::EndBehavior))
}
attr_accessor :end_behavior
sig {
params(end_behavior: T.nilable(::Stripe::QuoteService::UpdateParams::Line::TrialSettings::EndBehavior)).void
}
def initialize(end_behavior: nil); end
end
# An array of operations the quote line performs.
sig { returns(T.nilable(T::Array[::Stripe::QuoteService::UpdateParams::Line::Action])) }
attr_accessor :actions
# Details to identify the subscription schedule the quote line applies to.
sig { returns(T.nilable(::Stripe::QuoteService::UpdateParams::Line::AppliesTo)) }
attr_accessor :applies_to
# For point-in-time quote lines (having no `ends_at` timestamp), this attribute lets you set or remove whether the subscription's billing cycle anchor is reset at the Quote Line `starts_at` timestamp.For time-span based quote lines (having both `starts_at` and `ends_at`), the only valid value is `automatic`, which removes any previously configured billing cycle anchor resets during the window of time spanning the quote line.
sig { returns(T.nilable(String)) }
attr_accessor :billing_cycle_anchor
# A point-in-time operation that cancels an existing subscription schedule at the line's starts_at timestamp. Currently only compatible with `quote_acceptance_date` for `starts_at`. When using cancel_subscription_schedule, the subscription schedule on the quote remains unalterable, except for modifications to the metadata, collection_method or invoice_settings.
sig {
returns(T.nilable(::Stripe::QuoteService::UpdateParams::Line::CancelSubscriptionSchedule))
}
attr_accessor :cancel_subscription_schedule
# Details to identify the end of the time range modified by the proposed change. If not supplied, the quote line is considered a point-in-time operation that only affects the exact timestamp at `starts_at`, and a restricted set of attributes is supported on the quote line.
sig { returns(T.nilable(::Stripe::QuoteService::UpdateParams::Line::EndsAt)) }
attr_accessor :ends_at
# The ID of an existing line on the quote.
sig { returns(T.nilable(String)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
# Defines how to pause collection for the underlying subscription throughout the duration of the amendment.
sig { returns(T.nilable(::Stripe::QuoteService::UpdateParams::Line::SetPauseCollection)) }
attr_accessor :set_pause_collection
# Timestamp helper to end the underlying schedule early, based on the acompanying line's start or end date.
sig { returns(T.nilable(String)) }
attr_accessor :set_schedule_end
# Details to identify the earliest timestamp where the proposed change should take effect.
sig { returns(T.nilable(::Stripe::QuoteService::UpdateParams::Line::StartsAt)) }
attr_accessor :starts_at
# Settings related to subscription trials.
sig { returns(T.nilable(::Stripe::QuoteService::UpdateParams::Line::TrialSettings)) }
attr_accessor :trial_settings
sig {
params(actions: T.nilable(T::Array[::Stripe::QuoteService::UpdateParams::Line::Action]), applies_to: T.nilable(::Stripe::QuoteService::UpdateParams::Line::AppliesTo), billing_cycle_anchor: T.nilable(String), cancel_subscription_schedule: T.nilable(::Stripe::QuoteService::UpdateParams::Line::CancelSubscriptionSchedule), ends_at: T.nilable(::Stripe::QuoteService::UpdateParams::Line::EndsAt), id: T.nilable(String), proration_behavior: T.nilable(String), set_pause_collection: T.nilable(::Stripe::QuoteService::UpdateParams::Line::SetPauseCollection), set_schedule_end: T.nilable(String), starts_at: T.nilable(::Stripe::QuoteService::UpdateParams::Line::StartsAt), trial_settings: T.nilable(::Stripe::QuoteService::UpdateParams::Line::TrialSettings)).void
}
def initialize(
actions: nil,
applies_to: nil,
billing_cycle_anchor: nil,
cancel_subscription_schedule: nil,
ends_at: nil,
id: nil,
proration_behavior: nil,
set_pause_collection: nil,
set_schedule_end: nil,
starts_at: nil,
trial_settings: nil
); end
end
class LineItem < Stripe::RequestParams
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::QuoteService::UpdateParams::LineItem::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::QuoteService::UpdateParams::LineItem::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::QuoteService::UpdateParams::LineItem::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::QuoteService::UpdateParams::LineItem::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class PriceData < Stripe::RequestParams
class Recurring < Stripe::RequestParams
# Specifies billing frequency. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: T.nilable(Integer)).void }
def initialize(interval: nil, interval_count: nil); end
end
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
sig { returns(String) }
attr_accessor :product
# The recurring components of a price such as `interval` and `interval_count`.
sig {
returns(T.nilable(::Stripe::QuoteService::UpdateParams::LineItem::PriceData::Recurring))
}
attr_accessor :recurring
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, product: String, recurring: T.nilable(::Stripe::QuoteService::UpdateParams::LineItem::PriceData::Recurring), tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
recurring: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
# The discounts applied to this line item.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::QuoteService::UpdateParams::LineItem::Discount]))))
}
attr_accessor :discounts
# The ID of an existing line item on the quote.
sig { returns(T.nilable(String)) }
attr_accessor :id
# The ID of the price object. One of `price` or `price_data` is required.
sig { returns(T.nilable(String)) }
attr_accessor :price
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
sig { returns(T.nilable(::Stripe::QuoteService::UpdateParams::LineItem::PriceData)) }
attr_accessor :price_data
# The quantity of the line item.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# The tax rates which apply to the line item. When set, the `default_tax_rates` on the quote do not apply to this line item.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
sig {
params(discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::QuoteService::UpdateParams::LineItem::Discount]))), id: T.nilable(String), price: T.nilable(String), price_data: T.nilable(::Stripe::QuoteService::UpdateParams::LineItem::PriceData), quantity: T.nilable(Integer), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String])))).void
}
def initialize(
discounts: nil,
id: nil,
price: nil,
price_data: nil,
quantity: nil,
tax_rates: nil
); end
end
class SubscriptionData < Stripe::RequestParams
class BillOnAcceptance < Stripe::RequestParams
class BillFrom < Stripe::RequestParams
class LineStartsAt < Stripe::RequestParams
# The ID of a quote line.
sig { returns(T.nilable(String)) }
attr_accessor :id
# The position of the previous quote line in the `lines` array after which this line should begin. Indexes start from 0 and must be less than the index of the current line in the array.
sig { returns(T.nilable(Integer)) }
attr_accessor :index
sig { params(id: T.nilable(String), index: T.nilable(Integer)).void }
def initialize(id: nil, index: nil); end
end
# Details of a Quote line to start the bill period from.
sig {
returns(T.nilable(::Stripe::QuoteService::UpdateParams::SubscriptionData::BillOnAcceptance::BillFrom::LineStartsAt))
}
attr_accessor :line_starts_at
# A precise Unix timestamp.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of method to specify the `bill_from` time.
sig { returns(String) }
attr_accessor :type
sig {
params(line_starts_at: T.nilable(::Stripe::QuoteService::UpdateParams::SubscriptionData::BillOnAcceptance::BillFrom::LineStartsAt), timestamp: T.nilable(Integer), type: String).void
}
def initialize(line_starts_at: nil, timestamp: nil, type: nil); end
end
class BillUntil < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
class LineEndsAt < Stripe::RequestParams
# The ID of a quote line.
sig { returns(T.nilable(String)) }
attr_accessor :id
# The position of the previous quote line in the `lines` array after which this line should begin. Indexes start from 0 and must be less than the index of the current line in the array.
sig { returns(T.nilable(Integer)) }
attr_accessor :index
sig { params(id: T.nilable(String), index: T.nilable(Integer)).void }
def initialize(id: nil, index: nil); end
end
# Details of the duration over which to bill.
sig {
returns(T.nilable(::Stripe::QuoteService::UpdateParams::SubscriptionData::BillOnAcceptance::BillUntil::Duration))
}
attr_accessor :duration
# Details of a Quote line item from which to bill until.
sig {
returns(T.nilable(::Stripe::QuoteService::UpdateParams::SubscriptionData::BillOnAcceptance::BillUntil::LineEndsAt))
}
attr_accessor :line_ends_at
# A precise Unix timestamp.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of method to specify the `bill_until` time.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::QuoteService::UpdateParams::SubscriptionData::BillOnAcceptance::BillUntil::Duration), line_ends_at: T.nilable(::Stripe::QuoteService::UpdateParams::SubscriptionData::BillOnAcceptance::BillUntil::LineEndsAt), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, line_ends_at: nil, timestamp: nil, type: nil); end
end
# The start of the period to bill from when the Quote is accepted.
sig {
returns(T.nilable(::Stripe::QuoteService::UpdateParams::SubscriptionData::BillOnAcceptance::BillFrom))
}
attr_accessor :bill_from
# The end of the period to bill until when the Quote is accepted.
sig {
returns(T.nilable(::Stripe::QuoteService::UpdateParams::SubscriptionData::BillOnAcceptance::BillUntil))
}
attr_accessor :bill_until
sig {
params(bill_from: T.nilable(::Stripe::QuoteService::UpdateParams::SubscriptionData::BillOnAcceptance::BillFrom), bill_until: T.nilable(::Stripe::QuoteService::UpdateParams::SubscriptionData::BillOnAcceptance::BillUntil)).void
}
def initialize(bill_from: nil, bill_until: nil); end
end
class Prebilling < Stripe::RequestParams
# This is used to determine the number of billing cycles to prebill.
sig { returns(Integer) }
attr_accessor :iterations
sig { params(iterations: Integer).void }
def initialize(iterations: nil); end
end
# Describes the period to bill for upon accepting the quote.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::QuoteService::UpdateParams::SubscriptionData::BillOnAcceptance))))
}
attr_accessor :bill_on_acceptance
# Configures when the subscription schedule generates prorations for phase transitions. Possible values are `prorate_on_next_phase` or `prorate_up_front` with the default being `prorate_on_next_phase`. `prorate_on_next_phase` will apply phase changes and generate prorations at transition time. `prorate_up_front` will bill for all phases within the current billing cycle up front.
sig { returns(T.nilable(String)) }
attr_accessor :billing_behavior
# When specified as `reset`, the subscription will always start a new billing period when the quote is accepted.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :billing_cycle_anchor
# The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :description
# When creating a new subscription, the date of which the subscription schedule will start after the quote is accepted. When updating a subscription, the date of which the subscription will be updated using a subscription schedule. The special value `current_period_end` can be provided to update a subscription at the end of its current period. The `effective_date` is ignored if it is in the past when the quote is accepted.
sig { returns(T.nilable(T.nilable(T.any(String, T.any(String, Integer))))) }
attr_accessor :effective_date
# Behavior of the subscription schedule and underlying subscription when it ends.
sig { returns(T.nilable(String)) }
attr_accessor :end_behavior
# Set of [key-value pairs](https://stripe.com/docs/api/metadata) that will set metadata on the subscription or subscription schedule when the quote is accepted. If a recurring price is included in `line_items`, this field will be passed to the resulting subscription's `metadata` field. If `subscription_data.effective_date` is used, this field will be passed to the resulting subscription schedule's `phases.metadata` field. Unlike object-level metadata, this field is declarative. Updates will clear prior values.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# If specified, the invoicing for the given billing cycle iterations will be processed when the quote is accepted. Cannot be used with `effective_date`.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::QuoteService::UpdateParams::SubscriptionData::Prebilling))))
}
attr_accessor :prebilling
# Determines how to handle [prorations](https://stripe.com/docs/subscriptions/billing-cycle#prorations). When creating a subscription, valid values are `create_prorations` or `none`.
#
# When updating a subscription, valid values are `create_prorations`, `none`, or `always_invoice`.
#
# Passing `create_prorations` will cause proration invoice items to be created when applicable. These proration items will only be invoiced immediately under [certain conditions](https://stripe.com/docs/subscriptions/upgrading-downgrading#immediate-payment). In order to always invoice immediately for prorations, pass `always_invoice`.
#
# Prorations can be disabled by passing `none`.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
# Integer representing the number of trial period days before the customer is charged for the first time.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :trial_period_days
sig {
params(bill_on_acceptance: T.nilable(T.nilable(T.any(String, ::Stripe::QuoteService::UpdateParams::SubscriptionData::BillOnAcceptance))), billing_behavior: T.nilable(String), billing_cycle_anchor: T.nilable(T.nilable(String)), description: T.nilable(T.nilable(String)), effective_date: T.nilable(T.nilable(T.any(String, T.any(String, Integer)))), end_behavior: T.nilable(String), metadata: T.nilable(T::Hash[String, String]), prebilling: T.nilable(T.nilable(T.any(String, ::Stripe::QuoteService::UpdateParams::SubscriptionData::Prebilling))), proration_behavior: T.nilable(String), trial_period_days: T.nilable(T.nilable(T.any(String, Integer)))).void
}
def initialize(
bill_on_acceptance: nil,
billing_behavior: nil,
billing_cycle_anchor: nil,
description: nil,
effective_date: nil,
end_behavior: nil,
metadata: nil,
prebilling: nil,
proration_behavior: nil,
trial_period_days: nil
); end
end
class SubscriptionDataOverride < Stripe::RequestParams
class AppliesTo < Stripe::RequestParams
# A custom string that identifies a new subscription schedule being created upon quote acceptance. All quote lines with the same `new_reference` field will be applied to the creation of a new subscription schedule.
sig { returns(T.nilable(String)) }
attr_accessor :new_reference
# The ID of the schedule the line applies to.
sig { returns(T.nilable(String)) }
attr_accessor :subscription_schedule
# Describes whether the quote line is affecting a new schedule or an existing schedule.
sig { returns(String) }
attr_accessor :type
sig {
params(new_reference: T.nilable(String), subscription_schedule: T.nilable(String), type: String).void
}
def initialize(new_reference: nil, subscription_schedule: nil, type: nil); end
end
class BillOnAcceptance < Stripe::RequestParams
class BillFrom < Stripe::RequestParams
class LineStartsAt < Stripe::RequestParams
# The ID of a quote line.
sig { returns(T.nilable(String)) }
attr_accessor :id
# The position of the previous quote line in the `lines` array after which this line should begin. Indexes start from 0 and must be less than the index of the current line in the array.
sig { returns(T.nilable(Integer)) }
attr_accessor :index
sig { params(id: T.nilable(String), index: T.nilable(Integer)).void }
def initialize(id: nil, index: nil); end
end
# Details of a Quote line to start the bill period from.
sig {
returns(T.nilable(::Stripe::QuoteService::UpdateParams::SubscriptionDataOverride::BillOnAcceptance::BillFrom::LineStartsAt))
}
attr_accessor :line_starts_at
# A precise Unix timestamp.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of method to specify the `bill_from` time.
sig { returns(String) }
attr_accessor :type
sig {
params(line_starts_at: T.nilable(::Stripe::QuoteService::UpdateParams::SubscriptionDataOverride::BillOnAcceptance::BillFrom::LineStartsAt), timestamp: T.nilable(Integer), type: String).void
}
def initialize(line_starts_at: nil, timestamp: nil, type: nil); end
end
class BillUntil < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
class LineEndsAt < Stripe::RequestParams
# The ID of a quote line.
sig { returns(T.nilable(String)) }
attr_accessor :id
# The position of the previous quote line in the `lines` array after which this line should begin. Indexes start from 0 and must be less than the index of the current line in the array.
sig { returns(T.nilable(Integer)) }
attr_accessor :index
sig { params(id: T.nilable(String), index: T.nilable(Integer)).void }
def initialize(id: nil, index: nil); end
end
# Details of the duration over which to bill.
sig {
returns(T.nilable(::Stripe::QuoteService::UpdateParams::SubscriptionDataOverride::BillOnAcceptance::BillUntil::Duration))
}
attr_accessor :duration
# Details of a Quote line item from which to bill until.
sig {
returns(T.nilable(::Stripe::QuoteService::UpdateParams::SubscriptionDataOverride::BillOnAcceptance::BillUntil::LineEndsAt))
}
attr_accessor :line_ends_at
# A precise Unix timestamp.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of method to specify the `bill_until` time.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::QuoteService::UpdateParams::SubscriptionDataOverride::BillOnAcceptance::BillUntil::Duration), line_ends_at: T.nilable(::Stripe::QuoteService::UpdateParams::SubscriptionDataOverride::BillOnAcceptance::BillUntil::LineEndsAt), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, line_ends_at: nil, timestamp: nil, type: nil); end
end
# The start of the period to bill from when the Quote is accepted.
sig {
returns(T.nilable(::Stripe::QuoteService::UpdateParams::SubscriptionDataOverride::BillOnAcceptance::BillFrom))
}
attr_accessor :bill_from
# The end of the period to bill until when the Quote is accepted.
sig {
returns(T.nilable(::Stripe::QuoteService::UpdateParams::SubscriptionDataOverride::BillOnAcceptance::BillUntil))
}
attr_accessor :bill_until
sig {
params(bill_from: T.nilable(::Stripe::QuoteService::UpdateParams::SubscriptionDataOverride::BillOnAcceptance::BillFrom), bill_until: T.nilable(::Stripe::QuoteService::UpdateParams::SubscriptionDataOverride::BillOnAcceptance::BillUntil)).void
}
def initialize(bill_from: nil, bill_until: nil); end
end
# Whether the override applies to an existing Subscription Schedule or a new Subscription Schedule.
sig { returns(::Stripe::QuoteService::UpdateParams::SubscriptionDataOverride::AppliesTo) }
attr_accessor :applies_to
# Describes the period to bill for upon accepting the quote.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::QuoteService::UpdateParams::SubscriptionDataOverride::BillOnAcceptance))))
}
attr_accessor :bill_on_acceptance
# Configures when the subscription schedule generates prorations for phase transitions. Possible values are `prorate_on_next_phase` or `prorate_up_front` with the default being `prorate_on_next_phase`. `prorate_on_next_phase` will apply phase changes and generate prorations at transition time. `prorate_up_front` will bill for all phases within the current billing cycle up front.
sig { returns(T.nilable(String)) }
attr_accessor :billing_behavior
# The customer the Subscription Data override applies to.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :description
# Behavior of the subscription schedule and underlying subscription when it ends.
sig { returns(T.nilable(String)) }
attr_accessor :end_behavior
# Determines how to handle [prorations](https://stripe.com/docs/subscriptions/billing-cycle#prorations). When creating a subscription, valid values are `create_prorations` or `none`.
#
# When updating a subscription, valid values are `create_prorations`, `none`, or `always_invoice`.
#
# Passing `create_prorations` will cause proration invoice items to be created when applicable. These proration items will only be invoiced immediately under [certain conditions](https://stripe.com/docs/subscriptions/upgrading-downgrading#immediate-payment). In order to always invoice immediately for prorations, pass `always_invoice`.
#
# Prorations can be disabled by passing `none`.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
sig {
params(applies_to: ::Stripe::QuoteService::UpdateParams::SubscriptionDataOverride::AppliesTo, bill_on_acceptance: T.nilable(T.nilable(T.any(String, ::Stripe::QuoteService::UpdateParams::SubscriptionDataOverride::BillOnAcceptance))), billing_behavior: T.nilable(String), customer: T.nilable(String), description: T.nilable(T.nilable(String)), end_behavior: T.nilable(String), proration_behavior: T.nilable(String)).void
}
def initialize(
applies_to: nil,
bill_on_acceptance: nil,
billing_behavior: nil,
customer: nil,
description: nil,
end_behavior: nil,
proration_behavior: nil
); end
end
class TransferData < Stripe::RequestParams
# The amount that will be transferred automatically when the invoice is paid. If no amount is set, the full amount is transferred. There cannot be any line items with recurring prices when using this field.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination. There must be at least 1 line item with a recurring price to use this field.
sig { returns(T.nilable(Float)) }
attr_accessor :amount_percent
# ID of an existing, connected Stripe account.
sig { returns(String) }
attr_accessor :destination
sig {
params(amount: T.nilable(Integer), amount_percent: T.nilable(Float), destination: String).void
}
def initialize(amount: nil, amount_percent: nil, destination: nil); end
end
# Set to true to allow quote lines to have `starts_at` in the past if collection is paused between `starts_at` and now.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :allow_backdated_lines
# The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. There cannot be any line items with recurring prices when using this field.
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :application_fee_amount
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. There must be at least 1 line item with a recurring price to use this field.
sig { returns(T.nilable(T.nilable(T.any(String, Float)))) }
attr_accessor :application_fee_percent
# Settings for automatic tax lookup for this quote and resulting invoices and subscriptions.
sig { returns(T.nilable(::Stripe::QuoteService::UpdateParams::AutomaticTax)) }
attr_accessor :automatic_tax
# Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay invoices at the end of the subscription cycle or at invoice finalization using the default payment method attached to the subscription or customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically`.
sig { returns(T.nilable(String)) }
attr_accessor :collection_method
# The customer for which this quote belongs to. A customer is required before finalizing the quote. Once specified, it cannot be changed.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# The account for which this quote belongs to. A customer or account is required before finalizing the quote. Once specified, it cannot be changed.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# The tax rates that will apply to any line item that does not have `tax_rates` set.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :default_tax_rates
# A description that will be displayed on the quote PDF.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :description
# The discounts applied to the quote.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::QuoteService::UpdateParams::Discount]))))
}
attr_accessor :discounts
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A future timestamp on which the quote will be canceled if in `open` or `draft` status. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_at
# A footer that will be displayed on the quote PDF.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :footer
# A header that will be displayed on the quote PDF.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :header
# All invoices will be billed using the specified settings.
sig { returns(T.nilable(::Stripe::QuoteService::UpdateParams::InvoiceSettings)) }
attr_accessor :invoice_settings
# A list of line items the customer is being quoted for. Each line item includes information about the product, the quantity, and the resulting cost.
sig { returns(T.nilable(T::Array[::Stripe::QuoteService::UpdateParams::LineItem])) }
attr_accessor :line_items
# A list of [quote lines](https://docs.stripe.com/api/quote_lines) on the quote. These lines describe changes, in the order provided, that will be used to create new subscription schedules or update existing subscription schedules when the quote is accepted.
sig { returns(T.nilable(T::Array[::Stripe::QuoteService::UpdateParams::Line])) }
attr_accessor :lines
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The account on behalf of which to charge.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :on_behalf_of
# When creating a subscription or subscription schedule, the specified configuration data will be used. There must be at least one line item with a recurring price for a subscription or subscription schedule to be created. A subscription schedule is created if `subscription_data[effective_date]` is present and in the future, otherwise a subscription is created.
sig { returns(T.nilable(::Stripe::QuoteService::UpdateParams::SubscriptionData)) }
attr_accessor :subscription_data
# List representing overrides for `subscription_data` configurations for specific subscription schedules.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::QuoteService::UpdateParams::SubscriptionDataOverride]))))
}
attr_accessor :subscription_data_overrides
# The data with which to automatically create a Transfer for each of the invoices.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::QuoteService::UpdateParams::TransferData))))
}
attr_accessor :transfer_data
sig {
params(allow_backdated_lines: T.nilable(T::Boolean), application_fee_amount: T.nilable(T.nilable(T.any(String, Integer))), application_fee_percent: T.nilable(T.nilable(T.any(String, Float))), automatic_tax: T.nilable(::Stripe::QuoteService::UpdateParams::AutomaticTax), collection_method: T.nilable(String), customer: T.nilable(String), customer_account: T.nilable(String), default_tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String]))), description: T.nilable(T.nilable(String)), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::QuoteService::UpdateParams::Discount]))), expand: T.nilable(T::Array[String]), expires_at: T.nilable(Integer), footer: T.nilable(T.nilable(String)), header: T.nilable(T.nilable(String)), invoice_settings: T.nilable(::Stripe::QuoteService::UpdateParams::InvoiceSettings), line_items: T.nilable(T::Array[::Stripe::QuoteService::UpdateParams::LineItem]), lines: T.nilable(T::Array[::Stripe::QuoteService::UpdateParams::Line]), metadata: T.nilable(T::Hash[String, String]), on_behalf_of: T.nilable(T.nilable(String)), subscription_data: T.nilable(::Stripe::QuoteService::UpdateParams::SubscriptionData), subscription_data_overrides: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::QuoteService::UpdateParams::SubscriptionDataOverride]))), transfer_data: T.nilable(T.nilable(T.any(String, ::Stripe::QuoteService::UpdateParams::TransferData)))).void
}
def initialize(
allow_backdated_lines: nil,
application_fee_amount: nil,
application_fee_percent: nil,
automatic_tax: nil,
collection_method: nil,
customer: nil,
customer_account: nil,
default_tax_rates: nil,
description: nil,
discounts: nil,
expand: nil,
expires_at: nil,
footer: nil,
header: nil,
invoice_settings: nil,
line_items: nil,
lines: nil,
metadata: nil,
on_behalf_of: nil,
subscription_data: nil,
subscription_data_overrides: nil,
transfer_data: nil
); end
end
class AcceptParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class CancelParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class FinalizeQuoteParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A future timestamp on which the quote will be canceled if in `open` or `draft` status. Measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_at
sig { params(expand: T.nilable(T::Array[String]), expires_at: T.nilable(Integer)).void }
def initialize(expand: nil, expires_at: nil); end
end
class MarkDraftParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class MarkStaleParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Reason the Quote is being marked stale.
sig { returns(T.nilable(String)) }
attr_accessor :reason
sig { params(expand: T.nilable(T::Array[String]), reason: T.nilable(String)).void }
def initialize(expand: nil, reason: nil); end
end
class ReestimateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class PdfParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class ListPreviewInvoiceLinesParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
# Accepts the specified quote.
sig {
params(quote: String, params: T.any(::Stripe::QuoteService::AcceptParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Quote)
}
def accept(quote, params = {}, opts = {}); end
# Cancels the quote.
sig {
params(quote: String, params: T.any(::Stripe::QuoteService::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Quote)
}
def cancel(quote, params = {}, opts = {}); end
# A quote models prices and services for a customer. Default options for header, description, footer, and expires_at can be set in the dashboard via the [quote template](https://dashboard.stripe.com/settings/billing/quote).
sig {
params(params: T.any(::Stripe::QuoteService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Quote)
}
def create(params = {}, opts = {}); end
# Finalizes the quote.
sig {
params(quote: String, params: T.any(::Stripe::QuoteService::FinalizeQuoteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Quote)
}
def finalize_quote(quote, params = {}, opts = {}); end
# Returns a list of your quotes.
sig {
params(params: T.any(::Stripe::QuoteService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Preview the invoice line items that would be generated by accepting the quote.
sig {
params(quote: String, preview_invoice: String, params: T.any(::Stripe::QuoteService::ListPreviewInvoiceLinesParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list_preview_invoice_lines(quote, preview_invoice, params = {}, opts = {}); end
# Converts a stale quote to draft.
sig {
params(quote: String, params: T.any(::Stripe::QuoteService::MarkDraftParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Quote)
}
def mark_draft(quote, params = {}, opts = {}); end
# Converts a draft or open quote to stale.
sig {
params(quote: String, params: T.any(::Stripe::QuoteService::MarkStaleParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Quote)
}
def mark_stale(quote, params = {}, opts = {}); end
# Download the PDF for a finalized quote. Explanation for special handling can be found [here](https://docs.stripe.com/quotes/overview#quote_pdf)
sig {
params(quote: String, params: T.any(::Stripe::QuoteService::PdfParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped, read_body_chunk_block: T.untyped).returns(T.untyped)
}
def pdf(quote, params = {}, opts = {}, &read_body_chunk_block); end
# Recompute the upcoming invoice estimate for the quote.
sig {
params(quote: String, params: T.any(::Stripe::QuoteService::ReestimateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Quote)
}
def reestimate(quote, params = {}, opts = {}); end
# Retrieves the quote with the given ID.
sig {
params(quote: String, params: T.any(::Stripe::QuoteService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Quote)
}
def retrieve(quote, params = {}, opts = {}); end
# A quote models prices and services for a customer.
sig {
params(quote: String, params: T.any(::Stripe::QuoteService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Quote)
}
def update(quote, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class QuotePreviewInvoiceService < StripeService
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
# Preview the invoices that would be generated by accepting the quote.
sig {
params(quote: String, params: T.any(::Stripe::QuotePreviewInvoiceService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(quote, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class QuotePreviewSubscriptionScheduleService < StripeService
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
# Preview the schedules that would be generated by accepting the quote
sig {
params(quote: String, params: T.any(::Stripe::QuotePreviewSubscriptionScheduleService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(quote, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class QuoteLineService < StripeService
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
# Retrieves a paginated list of lines for a quote. These lines describe changes that will be used to create new subscription schedules or update existing subscription schedules when the quote is accepted.
sig {
params(quote: String, params: T.any(::Stripe::QuoteLineService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(quote, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class QuoteLineItemService < StripeService
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
# When retrieving a quote, there is an includable line_items property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of line items.
sig {
params(quote: String, params: T.any(::Stripe::QuoteLineItemService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(quote, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class QuoteComputedUpfrontLineItemsService < StripeService
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
# When retrieving a quote, there is an includable [computed.upfront.line_items](https://stripe.com/docs/api/quotes/object#quote_object-computed-upfront-line_items) property containing the first handful of those items. There is also a URL where you can retrieve the full (paginated) list of upfront line items.
sig {
params(quote: String, params: T.any(::Stripe::QuoteComputedUpfrontLineItemsService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(quote, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class RadarService < StripeService
attr_reader :early_fraud_warnings
attr_reader :value_lists
attr_reader :value_list_items
end
end
# typed: true
module Stripe
module Radar
class EarlyFraudWarningService < StripeService
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return early fraud warnings for the charge specified by this charge ID.
sig { returns(T.nilable(String)) }
attr_accessor :charge
# Only return early fraud warnings that were created during the given date interval.
sig {
returns(T.nilable(T.any(::Stripe::Radar::EarlyFraudWarningService::ListParams::Created, Integer)))
}
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Only return early fraud warnings for charges that were created by the PaymentIntent specified by this PaymentIntent ID.
sig { returns(T.nilable(String)) }
attr_accessor :payment_intent
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(charge: T.nilable(String), created: T.nilable(T.any(::Stripe::Radar::EarlyFraudWarningService::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), payment_intent: T.nilable(String), starting_after: T.nilable(String)).void
}
def initialize(
charge: nil,
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
payment_intent: nil,
starting_after: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Returns a list of early fraud warnings.
sig {
params(params: T.any(::Stripe::Radar::EarlyFraudWarningService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the details of an early fraud warning that has previously been created.
#
# Please refer to the [early fraud warning](https://docs.stripe.com/api#early_fraud_warning_object) object reference for more details.
sig {
params(early_fraud_warning: String, params: T.any(::Stripe::Radar::EarlyFraudWarningService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Radar::EarlyFraudWarning)
}
def retrieve(early_fraud_warning, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Radar
class ValueListService < StripeService
class DeleteParams < Stripe::RequestParams; end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
# The name of the value list for use in rules.
sig { returns(T.nilable(String)) }
attr_accessor :alias
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The human-readable name of the value list.
sig { returns(T.nilable(String)) }
attr_accessor :name
sig {
params(alias_: T.nilable(String), expand: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), name: T.nilable(String)).void
}
def initialize(alias_: nil, expand: nil, metadata: nil, name: nil); end
end
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# The alias used to reference the value list when writing rules.
sig { returns(T.nilable(String)) }
attr_accessor :alias
# A value contained within a value list - returns all value lists containing this value.
sig { returns(T.nilable(String)) }
attr_accessor :contains
# Only return value lists that were created during the given date interval.
sig {
returns(T.nilable(T.any(::Stripe::Radar::ValueListService::ListParams::Created, Integer)))
}
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(alias_: T.nilable(String), contains: T.nilable(String), created: T.nilable(T.any(::Stripe::Radar::ValueListService::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
alias_: nil,
contains: nil,
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
# The name of the value list for use in rules.
sig { returns(String) }
attr_accessor :alias
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Type of the items in the value list. One of `card_fingerprint`, `us_bank_account_fingerprint`, `sepa_debit_fingerprint`, `card_bin`, `email`, `ip_address`, `country`, `string`, `case_sensitive_string`, or `customer_id`. Use `string` if the item type is unknown or mixed.
sig { returns(T.nilable(String)) }
attr_accessor :item_type
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The human-readable name of the value list.
sig { returns(String) }
attr_accessor :name
sig {
params(alias_: String, expand: T.nilable(T::Array[String]), item_type: T.nilable(String), metadata: T.nilable(T::Hash[String, String]), name: String).void
}
def initialize(alias_: nil, expand: nil, item_type: nil, metadata: nil, name: nil); end
end
# Creates a new ValueList object, which can then be referenced in rules.
sig {
params(params: T.any(::Stripe::Radar::ValueListService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Radar::ValueList)
}
def create(params = {}, opts = {}); end
# Deletes a ValueList object, also deleting any items contained within the value list. To be deleted, a value list must not be referenced in any rules.
sig {
params(value_list: String, params: T.any(::Stripe::Radar::ValueListService::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Radar::ValueList)
}
def delete(value_list, params = {}, opts = {}); end
# Returns a list of ValueList objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.
sig {
params(params: T.any(::Stripe::Radar::ValueListService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves a ValueList object.
sig {
params(value_list: String, params: T.any(::Stripe::Radar::ValueListService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Radar::ValueList)
}
def retrieve(value_list, params = {}, opts = {}); end
# Updates a ValueList object by setting the values of the parameters passed. Any parameters not provided will be left unchanged. Note that item_type is immutable.
sig {
params(value_list: String, params: T.any(::Stripe::Radar::ValueListService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Radar::ValueList)
}
def update(value_list, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Radar
class ValueListItemService < StripeService
class DeleteParams < Stripe::RequestParams; end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return items that were created during the given date interval.
sig {
returns(T.nilable(T.any(::Stripe::Radar::ValueListItemService::ListParams::Created, Integer)))
}
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Return items belonging to the parent list whose value matches the specified value (using an "is like" match).
sig { returns(T.nilable(String)) }
attr_accessor :value
# Identifier for the parent value list this item belongs to.
sig { returns(String) }
attr_accessor :value_list
sig {
params(created: T.nilable(T.any(::Stripe::Radar::ValueListItemService::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String), value: T.nilable(String), value_list: String).void
}
def initialize(
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil,
value: nil,
value_list: nil
); end
end
class CreateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The value of the item (whose type must match the type of the parent value list).
sig { returns(String) }
attr_accessor :value
# The identifier of the value list which the created item will be added to.
sig { returns(String) }
attr_accessor :value_list
sig { params(expand: T.nilable(T::Array[String]), value: String, value_list: String).void }
def initialize(expand: nil, value: nil, value_list: nil); end
end
# Creates a new ValueListItem object, which is added to the specified parent value list.
sig {
params(params: T.any(::Stripe::Radar::ValueListItemService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Radar::ValueListItem)
}
def create(params = {}, opts = {}); end
# Deletes a ValueListItem object, removing it from its parent value list.
sig {
params(item: String, params: T.any(::Stripe::Radar::ValueListItemService::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Radar::ValueListItem)
}
def delete(item, params = {}, opts = {}); end
# Returns a list of ValueListItem objects. The objects are sorted in descending order by creation date, with the most recently created object appearing first.
sig {
params(params: T.any(::Stripe::Radar::ValueListItemService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves a ValueListItem object.
sig {
params(item: String, params: T.any(::Stripe::Radar::ValueListItemService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Radar::ValueListItem)
}
def retrieve(item, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
class RefundService < StripeService
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return refunds for the charge specified by this charge ID.
sig { returns(T.nilable(String)) }
attr_accessor :charge
# Only return refunds that were created during the given date interval.
sig { returns(T.nilable(T.any(::Stripe::RefundService::ListParams::Created, Integer))) }
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Only return refunds for the PaymentIntent specified by this ID.
sig { returns(T.nilable(String)) }
attr_accessor :payment_intent
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(charge: T.nilable(String), created: T.nilable(T.any(::Stripe::RefundService::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), payment_intent: T.nilable(String), starting_after: T.nilable(String)).void
}
def initialize(
charge: nil,
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
payment_intent: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
# Attribute for param field amount
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# The identifier of the charge to refund.
sig { returns(T.nilable(String)) }
attr_accessor :charge
# 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).
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Customer whose customer balance to refund from.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# For payment methods without native refund support (e.g., Konbini, PromptPay), use this email from the customer to receive refund instructions.
sig { returns(T.nilable(String)) }
attr_accessor :instructions_email
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Origin of the refund
sig { returns(T.nilable(String)) }
attr_accessor :origin
# The identifier of the PaymentIntent to refund.
sig { returns(T.nilable(String)) }
attr_accessor :payment_intent
# String indicating the reason for the refund. If set, possible values are `duplicate`, `fraudulent`, and `requested_by_customer`. If you believe the charge to be fraudulent, specifying `fraudulent` as the reason will add the associated card and email to your [block lists](https://stripe.com/docs/radar/lists), and will also help us improve our fraud detection algorithms.
sig { returns(T.nilable(String)) }
attr_accessor :reason
# Boolean indicating whether the application fee should be refunded when refunding this charge. If a full charge refund is given, the full application fee will be refunded. Otherwise, the application fee will be refunded in an amount proportional to the amount of the charge refunded. An application fee can be refunded only by the application that created the charge.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :refund_application_fee
# Boolean indicating whether the transfer should be reversed when refunding this charge. The transfer will be reversed proportionally to the amount being refunded (either the entire or partial amount).
A transfer can be reversed only by the application that created the charge.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :reverse_transfer
sig {
params(amount: T.nilable(Integer), charge: T.nilable(String), currency: T.nilable(String), customer: T.nilable(String), expand: T.nilable(T::Array[String]), instructions_email: T.nilable(String), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), origin: T.nilable(String), payment_intent: T.nilable(String), reason: T.nilable(String), refund_application_fee: T.nilable(T::Boolean), reverse_transfer: T.nilable(T::Boolean)).void
}
def initialize(
amount: nil,
charge: nil,
currency: nil,
customer: nil,
expand: nil,
instructions_email: nil,
metadata: nil,
origin: nil,
payment_intent: nil,
reason: nil,
refund_application_fee: nil,
reverse_transfer: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
sig {
params(expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String])))).void
}
def initialize(expand: nil, metadata: nil); end
end
class CancelParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Cancels a refund with a status of requires_action.
#
# You can't cancel refunds in other states. Only refunds for payment methods that require customer action can enter the requires_action state.
sig {
params(refund: String, params: T.any(::Stripe::RefundService::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Refund)
}
def cancel(refund, params = {}, opts = {}); end
# When you create a new refund, you must specify a Charge or a PaymentIntent object on which to create it.
#
# Creating a new refund will refund a charge that has previously been created but not yet refunded.
# Funds will be refunded to the credit or debit card that was originally charged.
#
# You can optionally refund only part of a charge.
# You can do so multiple times, until the entire charge has been refunded.
#
# Once entirely refunded, a charge can't be refunded again.
# This method will raise an error when called on an already-refunded charge,
# or when trying to refund more money than is left on a charge.
sig {
params(params: T.any(::Stripe::RefundService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Refund)
}
def create(params = {}, opts = {}); end
# Returns a list of all refunds you created. We return the refunds in sorted order, with the most recent refunds appearing first. The 10 most recent refunds are always available by default on the Charge object.
sig {
params(params: T.any(::Stripe::RefundService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the details of an existing refund.
sig {
params(refund: String, params: T.any(::Stripe::RefundService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Refund)
}
def retrieve(refund, params = {}, opts = {}); end
# Updates the refund that you specify by setting the values of the passed parameters. Any parameters that you don't provide remain unchanged.
#
# This request only accepts metadata as an argument.
sig {
params(refund: String, params: T.any(::Stripe::RefundService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Refund)
}
def update(refund, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class ReportingService < StripeService
attr_reader :report_runs
attr_reader :report_types
end
end
# typed: true
module Stripe
module Reporting
class ReportRunService < StripeService
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return Report Runs that were created during the given date interval.
sig {
returns(T.nilable(T.any(::Stripe::Reporting::ReportRunService::ListParams::Created, Integer)))
}
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(created: T.nilable(T.any(::Stripe::Reporting::ReportRunService::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class Parameters < Stripe::RequestParams
# The set of report columns to include in the report output. If omitted, the Report Type is run with its default column set.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :columns
# Connected account ID to filter for in the report run.
sig { returns(T.nilable(String)) }
attr_accessor :connected_account
# Currency of objects to be included in the report run.
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Ending timestamp of data to be included in the report run (exclusive).
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_end
# Starting timestamp of data to be included in the report run.
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_start
# Payout ID by which to filter the report run.
sig { returns(T.nilable(String)) }
attr_accessor :payout
# Category of balance transactions to be included in the report run.
sig { returns(T.nilable(String)) }
attr_accessor :reporting_category
# Defaults to `Etc/UTC`. The output timezone for all timestamps in the report. A list of possible time zone values is maintained at the [IANA Time Zone Database](http://www.iana.org/time-zones). Has no effect on `interval_start` or `interval_end`.
sig { returns(T.nilable(String)) }
attr_accessor :timezone
sig {
params(columns: T.nilable(T::Array[String]), connected_account: T.nilable(String), currency: T.nilable(String), interval_end: T.nilable(Integer), interval_start: T.nilable(Integer), payout: T.nilable(String), reporting_category: T.nilable(String), timezone: T.nilable(String)).void
}
def initialize(
columns: nil,
connected_account: nil,
currency: nil,
interval_end: nil,
interval_start: nil,
payout: nil,
reporting_category: nil,
timezone: nil
); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Parameters specifying how the report should be run. Different Report Types have different required and optional parameters, listed in the [API Access to Reports](https://stripe.com/docs/reporting/statements/api) documentation.
sig { returns(T.nilable(::Stripe::Reporting::ReportRunService::CreateParams::Parameters)) }
attr_accessor :parameters
# The ID of the [report type](https://stripe.com/docs/reporting/statements/api#report-types) to run, such as `"balance.summary.1"`.
sig { returns(String) }
attr_accessor :report_type
sig {
params(expand: T.nilable(T::Array[String]), parameters: T.nilable(::Stripe::Reporting::ReportRunService::CreateParams::Parameters), report_type: String).void
}
def initialize(expand: nil, parameters: nil, report_type: nil); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Creates a new object and begin running the report. (Certain report types require a [live-mode API key](https://stripe.com/docs/keys#test-live-modes).)
sig {
params(params: T.any(::Stripe::Reporting::ReportRunService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Reporting::ReportRun)
}
def create(params = {}, opts = {}); end
# Returns a list of Report Runs, with the most recent appearing first.
sig {
params(params: T.any(::Stripe::Reporting::ReportRunService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the details of an existing Report Run.
sig {
params(report_run: String, params: T.any(::Stripe::Reporting::ReportRunService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Reporting::ReportRun)
}
def retrieve(report_run, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Reporting
class ReportTypeService < StripeService
class ListParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Returns a full list of Report Types.
sig {
params(params: T.any(::Stripe::Reporting::ReportTypeService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the details of a Report Type. (Certain report types require a [live-mode API key](https://stripe.com/docs/keys#test-live-modes).)
sig {
params(report_type: String, params: T.any(::Stripe::Reporting::ReportTypeService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Reporting::ReportType)
}
def retrieve(report_type, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
class ReviewService < StripeService
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return reviews that were created during the given date interval.
sig { returns(T.nilable(T.any(::Stripe::ReviewService::ListParams::Created, Integer))) }
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(created: T.nilable(T.any(::Stripe::ReviewService::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class ApproveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Approves a Review object, closing it and removing it from the list of reviews.
sig {
params(review: String, params: T.any(::Stripe::ReviewService::ApproveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Review)
}
def approve(review, params = {}, opts = {}); end
# Returns a list of Review objects that have open set to true. The objects are sorted in descending order by creation date, with the most recently created object appearing first.
sig {
params(params: T.any(::Stripe::ReviewService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves a Review object.
sig {
params(review: String, params: T.any(::Stripe::ReviewService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Review)
}
def retrieve(review, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class SigmaService < StripeService
attr_reader :scheduled_query_runs
end
end
# typed: true
module Stripe
module Sigma
class ScheduledQueryRunService < StripeService
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Returns a list of scheduled query runs.
sig {
params(params: T.any(::Stripe::Sigma::ScheduledQueryRunService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the details of an scheduled query run.
sig {
params(scheduled_query_run: String, params: T.any(::Stripe::Sigma::ScheduledQueryRunService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Sigma::ScheduledQueryRun)
}
def retrieve(scheduled_query_run, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
class SetupAttemptService < StripeService
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# A filter on the list, based on the object `created` field. The value
# can be a string with an integer Unix timestamp or a
# dictionary with a number of different query options.
sig { returns(T.nilable(T.any(::Stripe::SetupAttemptService::ListParams::Created, Integer))) }
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Only return SetupAttempts created by the SetupIntent specified by
# this ID.
sig { returns(String) }
attr_accessor :setup_intent
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(created: T.nilable(T.any(::Stripe::SetupAttemptService::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), setup_intent: String, starting_after: T.nilable(String)).void
}
def initialize(
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
setup_intent: nil,
starting_after: nil
); end
end
# Returns a list of SetupAttempts that associate with a provided SetupIntent.
sig {
params(params: T.any(::Stripe::SetupAttemptService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class SetupIntentService < StripeService
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# If present, the SetupIntent's payment method will be attached to the in-context Stripe Account.
#
# It can only be used for this Stripe Account’s own money movement flows like InboundTransfer and OutboundTransfers. It cannot be set to true when setting up a PaymentMethod for a Customer, and defaults to false when attaching a PaymentMethod to a Customer.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :attach_to_self
# A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.
sig { returns(T.nilable(T.any(::Stripe::SetupIntentService::ListParams::Created, Integer))) }
attr_accessor :created
# Only return SetupIntents for the customer specified by this customer ID.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# Only return SetupIntents for the account specified by this customer ID.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Only return SetupIntents that associate with the specified payment method.
sig { returns(T.nilable(String)) }
attr_accessor :payment_method
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(attach_to_self: T.nilable(T::Boolean), created: T.nilable(T.any(::Stripe::SetupIntentService::ListParams::Created, Integer)), customer: T.nilable(String), customer_account: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), payment_method: T.nilable(String), starting_after: T.nilable(String)).void
}
def initialize(
attach_to_self: nil,
created: nil,
customer: nil,
customer_account: nil,
ending_before: nil,
expand: nil,
limit: nil,
payment_method: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class AutomaticPaymentMethods < Stripe::RequestParams
# Controls whether this SetupIntent will accept redirect-based payment methods.
#
# Redirect-based payment methods may require your customer to be redirected to a payment method's app or site for authentication or additional steps. To [confirm](https://stripe.com/docs/api/setup_intents/confirm) this SetupIntent, you may be required to provide a `return_url` to redirect customers back to your site after they authenticate or complete the setup.
sig { returns(T.nilable(String)) }
attr_accessor :allow_redirects
# Whether this feature is enabled.
sig { returns(T::Boolean) }
attr_accessor :enabled
sig { params(allow_redirects: T.nilable(String), enabled: T::Boolean).void }
def initialize(allow_redirects: nil, enabled: nil); end
end
class MandateData < Stripe::RequestParams
class CustomerAcceptance < Stripe::RequestParams
class Offline < Stripe::RequestParams; end
class Online < Stripe::RequestParams
# The IP address from which the Mandate was accepted by the customer.
sig { returns(String) }
attr_accessor :ip_address
# The user agent of the browser from which the Mandate was accepted by the customer.
sig { returns(String) }
attr_accessor :user_agent
sig { params(ip_address: String, user_agent: String).void }
def initialize(ip_address: nil, user_agent: nil); end
end
# The time at which the customer accepted the Mandate.
sig { returns(T.nilable(Integer)) }
attr_accessor :accepted_at
# If this is a Mandate accepted offline, this hash contains details about the offline acceptance.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::MandateData::CustomerAcceptance::Offline))
}
attr_accessor :offline
# If this is a Mandate accepted online, this hash contains details about the online acceptance.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::MandateData::CustomerAcceptance::Online))
}
attr_accessor :online
# The type of customer acceptance information included with the Mandate. One of `online` or `offline`.
sig { returns(String) }
attr_accessor :type
sig {
params(accepted_at: T.nilable(Integer), offline: T.nilable(::Stripe::SetupIntentService::CreateParams::MandateData::CustomerAcceptance::Offline), online: T.nilable(::Stripe::SetupIntentService::CreateParams::MandateData::CustomerAcceptance::Online), type: String).void
}
def initialize(accepted_at: nil, offline: nil, online: nil, type: nil); end
end
# This hash contains details about the customer acceptance of the Mandate.
sig { returns(::Stripe::SetupIntentService::CreateParams::MandateData::CustomerAcceptance) }
attr_accessor :customer_acceptance
sig {
params(customer_acceptance: ::Stripe::SetupIntentService::CreateParams::MandateData::CustomerAcceptance).void
}
def initialize(customer_acceptance: nil); end
end
class PaymentMethodData < Stripe::RequestParams
class AcssDebit < Stripe::RequestParams
# Customer's bank account number.
sig { returns(String) }
attr_accessor :account_number
# Institution number of the customer's bank.
sig { returns(String) }
attr_accessor :institution_number
# Transit number of the customer's bank.
sig { returns(String) }
attr_accessor :transit_number
sig {
params(account_number: String, institution_number: String, transit_number: String).void
}
def initialize(account_number: nil, institution_number: nil, transit_number: nil); end
end
class Affirm < Stripe::RequestParams; end
class AfterpayClearpay < Stripe::RequestParams; end
class Alipay < Stripe::RequestParams; end
class Alma < Stripe::RequestParams; end
class AmazonPay < Stripe::RequestParams; end
class AuBecsDebit < Stripe::RequestParams
# The account number for the bank account.
sig { returns(String) }
attr_accessor :account_number
# Bank-State-Branch number of the bank account.
sig { returns(String) }
attr_accessor :bsb_number
sig { params(account_number: String, bsb_number: String).void }
def initialize(account_number: nil, bsb_number: nil); end
end
class BacsDebit < Stripe::RequestParams
# Account number of the bank account that the funds will be debited from.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Sort code of the bank account. (e.g., `10-20-30`)
sig { returns(T.nilable(String)) }
attr_accessor :sort_code
sig { params(account_number: T.nilable(String), sort_code: T.nilable(String)).void }
def initialize(account_number: nil, sort_code: nil); end
end
class Bancontact < Stripe::RequestParams; end
class Billie < Stripe::RequestParams; end
class BillingDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Billing address.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SetupIntentService::CreateParams::PaymentMethodData::BillingDetails::Address))))
}
attr_accessor :address
# Email address.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :email
# Full name.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :name
# Billing phone number (including extension).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :phone
# Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
sig { returns(T.nilable(String)) }
attr_accessor :tax_id
sig {
params(address: T.nilable(T.nilable(T.any(String, ::Stripe::SetupIntentService::CreateParams::PaymentMethodData::BillingDetails::Address))), email: T.nilable(T.nilable(String)), name: T.nilable(T.nilable(String)), phone: T.nilable(T.nilable(String)), tax_id: T.nilable(String)).void
}
def initialize(address: nil, email: nil, name: nil, phone: nil, tax_id: nil); end
end
class Blik < Stripe::RequestParams; end
class Boleto < Stripe::RequestParams
# The tax ID of the customer (CPF for individual consumers or CNPJ for businesses consumers)
sig { returns(String) }
attr_accessor :tax_id
sig { params(tax_id: String).void }
def initialize(tax_id: nil); end
end
class Cashapp < Stripe::RequestParams; end
class CustomerBalance < Stripe::RequestParams; end
class Eps < Stripe::RequestParams
# The customer's bank.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class Fpx < Stripe::RequestParams
# Account holder type for FPX transaction
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_type
# The customer's bank.
sig { returns(String) }
attr_accessor :bank
sig { params(account_holder_type: T.nilable(String), bank: String).void }
def initialize(account_holder_type: nil, bank: nil); end
end
class Giropay < Stripe::RequestParams; end
class Gopay < Stripe::RequestParams; end
class Grabpay < Stripe::RequestParams; end
class IdBankTransfer < Stripe::RequestParams
# Bank where the account is held.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class Ideal < Stripe::RequestParams
# The customer's bank. Only use this parameter for existing customers. Don't use it for new customers.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class InteracPresent < Stripe::RequestParams; end
class KakaoPay < Stripe::RequestParams; end
class Klarna < Stripe::RequestParams
class Dob < Stripe::RequestParams
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
# Customer's date of birth
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Klarna::Dob))
}
attr_accessor :dob
sig {
params(dob: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Klarna::Dob)).void
}
def initialize(dob: nil); end
end
class Konbini < Stripe::RequestParams; end
class KrCard < Stripe::RequestParams; end
class Link < Stripe::RequestParams; end
class MbWay < Stripe::RequestParams; end
class Mobilepay < Stripe::RequestParams; end
class Multibanco < Stripe::RequestParams; end
class NaverPay < Stripe::RequestParams
# Whether to use Naver Pay points or a card to fund this transaction. If not provided, this defaults to `card`.
sig { returns(T.nilable(String)) }
attr_accessor :funding
sig { params(funding: T.nilable(String)).void }
def initialize(funding: nil); end
end
class NzBankAccount < Stripe::RequestParams
# The name on the bank account. Only required if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod’s billing details.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_name
# The account number for the bank account.
sig { returns(String) }
attr_accessor :account_number
# The numeric code for the bank account's bank.
sig { returns(String) }
attr_accessor :bank_code
# The numeric code for the bank account's bank branch.
sig { returns(String) }
attr_accessor :branch_code
# Attribute for param field reference
sig { returns(T.nilable(String)) }
attr_accessor :reference
# The suffix of the bank account number.
sig { returns(String) }
attr_accessor :suffix
sig {
params(account_holder_name: T.nilable(String), account_number: String, bank_code: String, branch_code: String, reference: T.nilable(String), suffix: String).void
}
def initialize(
account_holder_name: nil,
account_number: nil,
bank_code: nil,
branch_code: nil,
reference: nil,
suffix: nil
); end
end
class Oxxo < Stripe::RequestParams; end
class P24 < Stripe::RequestParams
# The customer's bank.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class PayByBank < Stripe::RequestParams; end
class Payco < Stripe::RequestParams; end
class Paynow < Stripe::RequestParams; end
class Paypal < Stripe::RequestParams; end
class Payto < Stripe::RequestParams
# The account number for the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Bank-State-Branch number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :bsb_number
# The PayID alias for the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :pay_id
sig {
params(account_number: T.nilable(String), bsb_number: T.nilable(String), pay_id: T.nilable(String)).void
}
def initialize(account_number: nil, bsb_number: nil, pay_id: nil); end
end
class Pix < Stripe::RequestParams; end
class Promptpay < Stripe::RequestParams; end
class Qris < Stripe::RequestParams; end
class RadarOptions < Stripe::RequestParams
# A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
sig { returns(T.nilable(String)) }
attr_accessor :session
sig { params(session: T.nilable(String)).void }
def initialize(session: nil); end
end
class Rechnung < Stripe::RequestParams
class Dob < Stripe::RequestParams
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
# Customer's date of birth
sig {
returns(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Rechnung::Dob)
}
attr_accessor :dob
sig {
params(dob: ::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Rechnung::Dob).void
}
def initialize(dob: nil); end
end
class RevolutPay < Stripe::RequestParams; end
class SamsungPay < Stripe::RequestParams; end
class Satispay < Stripe::RequestParams; end
class SepaDebit < Stripe::RequestParams
# IBAN of the bank account.
sig { returns(String) }
attr_accessor :iban
sig { params(iban: String).void }
def initialize(iban: nil); end
end
class Shopeepay < Stripe::RequestParams; end
class Sofort < Stripe::RequestParams
# Two-letter ISO code representing the country the bank account is located in.
sig { returns(String) }
attr_accessor :country
sig { params(country: String).void }
def initialize(country: nil); end
end
class StripeBalance < Stripe::RequestParams
# The connected account ID whose Stripe balance to use as the source of payment
sig { returns(T.nilable(String)) }
attr_accessor :account
# The [source_type](https://docs.stripe.com/api/balance/balance_object#balance_object-available-source_types) of the balance
sig { returns(T.nilable(String)) }
attr_accessor :source_type
sig { params(account: T.nilable(String), source_type: T.nilable(String)).void }
def initialize(account: nil, source_type: nil); end
end
class Swish < Stripe::RequestParams; end
class Twint < Stripe::RequestParams; end
class UsBankAccount < Stripe::RequestParams
# Account holder type: individual or company.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_type
# Account number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Account type: checkings or savings. Defaults to checking if omitted.
sig { returns(T.nilable(String)) }
attr_accessor :account_type
# The ID of a Financial Connections Account to use as a payment method.
sig { returns(T.nilable(String)) }
attr_accessor :financial_connections_account
# Routing number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :routing_number
sig {
params(account_holder_type: T.nilable(String), account_number: T.nilable(String), account_type: T.nilable(String), financial_connections_account: T.nilable(String), routing_number: T.nilable(String)).void
}
def initialize(
account_holder_type: nil,
account_number: nil,
account_type: nil,
financial_connections_account: nil,
routing_number: nil
); end
end
class WechatPay < Stripe::RequestParams; end
class Zip < Stripe::RequestParams; end
# If this is an `acss_debit` PaymentMethod, this hash contains details about the ACSS Debit payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::AcssDebit))
}
attr_accessor :acss_debit
# If this is an `affirm` PaymentMethod, this hash contains details about the Affirm payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Affirm))
}
attr_accessor :affirm
# If this is an `AfterpayClearpay` PaymentMethod, this hash contains details about the AfterpayClearpay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::AfterpayClearpay))
}
attr_accessor :afterpay_clearpay
# If this is an `Alipay` PaymentMethod, this hash contains details about the Alipay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Alipay))
}
attr_accessor :alipay
# This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :allow_redisplay
# If this is a Alma PaymentMethod, this hash contains details about the Alma payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Alma))
}
attr_accessor :alma
# If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::AmazonPay))
}
attr_accessor :amazon_pay
# If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::AuBecsDebit))
}
attr_accessor :au_becs_debit
# If this is a `bacs_debit` PaymentMethod, this hash contains details about the Bacs Direct Debit bank account.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::BacsDebit))
}
attr_accessor :bacs_debit
# If this is a `bancontact` PaymentMethod, this hash contains details about the Bancontact payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Bancontact))
}
attr_accessor :bancontact
# If this is a `billie` PaymentMethod, this hash contains details about the Billie payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Billie))
}
attr_accessor :billie
# Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::BillingDetails))
}
attr_accessor :billing_details
# If this is a `blik` PaymentMethod, this hash contains details about the BLIK payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Blik))
}
attr_accessor :blik
# If this is a `boleto` PaymentMethod, this hash contains details about the Boleto payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Boleto))
}
attr_accessor :boleto
# If this is a `cashapp` PaymentMethod, this hash contains details about the Cash App Pay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Cashapp))
}
attr_accessor :cashapp
# If this is a `customer_balance` PaymentMethod, this hash contains details about the CustomerBalance payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::CustomerBalance))
}
attr_accessor :customer_balance
# If this is an `eps` PaymentMethod, this hash contains details about the EPS payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Eps))
}
attr_accessor :eps
# If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Fpx))
}
attr_accessor :fpx
# If this is a `giropay` PaymentMethod, this hash contains details about the Giropay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Giropay))
}
attr_accessor :giropay
# If this is a Gopay PaymentMethod, this hash contains details about the Gopay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Gopay))
}
attr_accessor :gopay
# If this is a `grabpay` PaymentMethod, this hash contains details about the GrabPay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Grabpay))
}
attr_accessor :grabpay
# If this is an `IdBankTransfer` PaymentMethod, this hash contains details about the IdBankTransfer payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::IdBankTransfer))
}
attr_accessor :id_bank_transfer
# If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Ideal))
}
attr_accessor :ideal
# If this is an `interac_present` PaymentMethod, this hash contains details about the Interac Present payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::InteracPresent))
}
attr_accessor :interac_present
# If this is a `kakao_pay` PaymentMethod, this hash contains details about the Kakao Pay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::KakaoPay))
}
attr_accessor :kakao_pay
# If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Klarna))
}
attr_accessor :klarna
# If this is a `konbini` PaymentMethod, this hash contains details about the Konbini payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Konbini))
}
attr_accessor :konbini
# If this is a `kr_card` PaymentMethod, this hash contains details about the Korean Card payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::KrCard))
}
attr_accessor :kr_card
# If this is an `Link` PaymentMethod, this hash contains details about the Link payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Link))
}
attr_accessor :link
# If this is a MB WAY PaymentMethod, this hash contains details about the MB WAY payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::MbWay))
}
attr_accessor :mb_way
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# If this is a `mobilepay` PaymentMethod, this hash contains details about the MobilePay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Mobilepay))
}
attr_accessor :mobilepay
# If this is a `multibanco` PaymentMethod, this hash contains details about the Multibanco payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Multibanco))
}
attr_accessor :multibanco
# If this is a `naver_pay` PaymentMethod, this hash contains details about the Naver Pay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::NaverPay))
}
attr_accessor :naver_pay
# If this is an nz_bank_account PaymentMethod, this hash contains details about the nz_bank_account payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::NzBankAccount))
}
attr_accessor :nz_bank_account
# If this is an `oxxo` PaymentMethod, this hash contains details about the OXXO payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Oxxo))
}
attr_accessor :oxxo
# If this is a `p24` PaymentMethod, this hash contains details about the P24 payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::P24))
}
attr_accessor :p24
# If this is a `pay_by_bank` PaymentMethod, this hash contains details about the PayByBank payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::PayByBank))
}
attr_accessor :pay_by_bank
# If this is a `payco` PaymentMethod, this hash contains details about the PAYCO payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Payco))
}
attr_accessor :payco
# If this is a `paynow` PaymentMethod, this hash contains details about the PayNow payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Paynow))
}
attr_accessor :paynow
# If this is a `paypal` PaymentMethod, this hash contains details about the PayPal payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Paypal))
}
attr_accessor :paypal
# If this is a `payto` PaymentMethod, this hash contains details about the PayTo payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Payto))
}
attr_accessor :payto
# If this is a `pix` PaymentMethod, this hash contains details about the Pix payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Pix))
}
attr_accessor :pix
# If this is a `promptpay` PaymentMethod, this hash contains details about the PromptPay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Promptpay))
}
attr_accessor :promptpay
# If this is a `qris` PaymentMethod, this hash contains details about the QRIS payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Qris))
}
attr_accessor :qris
# Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::RadarOptions))
}
attr_accessor :radar_options
# If this is a `rechnung` PaymentMethod, this hash contains details about the Rechnung payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Rechnung))
}
attr_accessor :rechnung
# If this is a `revolut_pay` PaymentMethod, this hash contains details about the Revolut Pay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::RevolutPay))
}
attr_accessor :revolut_pay
# If this is a `samsung_pay` PaymentMethod, this hash contains details about the SamsungPay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::SamsungPay))
}
attr_accessor :samsung_pay
# If this is a `satispay` PaymentMethod, this hash contains details about the Satispay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Satispay))
}
attr_accessor :satispay
# If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::SepaDebit))
}
attr_accessor :sepa_debit
# If this is a Shopeepay PaymentMethod, this hash contains details about the Shopeepay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Shopeepay))
}
attr_accessor :shopeepay
# If this is a `sofort` PaymentMethod, this hash contains details about the SOFORT payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Sofort))
}
attr_accessor :sofort
# This hash contains details about the Stripe balance payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::StripeBalance))
}
attr_accessor :stripe_balance
# If this is a `swish` PaymentMethod, this hash contains details about the Swish payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Swish))
}
attr_accessor :swish
# If this is a TWINT PaymentMethod, this hash contains details about the TWINT payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Twint))
}
attr_accessor :twint
# The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
sig { returns(String) }
attr_accessor :type
# If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::UsBankAccount))
}
attr_accessor :us_bank_account
# If this is an `wechat_pay` PaymentMethod, this hash contains details about the wechat_pay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::WechatPay))
}
attr_accessor :wechat_pay
# If this is a `zip` PaymentMethod, this hash contains details about the Zip payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Zip))
}
attr_accessor :zip
sig {
params(acss_debit: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::AcssDebit), affirm: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Affirm), afterpay_clearpay: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::AfterpayClearpay), alipay: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Alipay), allow_redisplay: T.nilable(String), alma: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Alma), amazon_pay: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::AmazonPay), au_becs_debit: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::AuBecsDebit), bacs_debit: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::BacsDebit), bancontact: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Bancontact), billie: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Billie), billing_details: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::BillingDetails), blik: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Blik), boleto: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Boleto), cashapp: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Cashapp), customer_balance: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::CustomerBalance), eps: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Eps), fpx: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Fpx), giropay: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Giropay), gopay: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Gopay), grabpay: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Grabpay), id_bank_transfer: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::IdBankTransfer), ideal: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Ideal), interac_present: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::InteracPresent), kakao_pay: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::KakaoPay), klarna: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Klarna), konbini: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Konbini), kr_card: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::KrCard), link: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Link), mb_way: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::MbWay), metadata: T.nilable(T::Hash[String, String]), mobilepay: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Mobilepay), multibanco: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Multibanco), naver_pay: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::NaverPay), nz_bank_account: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::NzBankAccount), oxxo: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Oxxo), p24: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::P24), pay_by_bank: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::PayByBank), payco: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Payco), paynow: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Paynow), paypal: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Paypal), payto: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Payto), pix: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Pix), promptpay: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Promptpay), qris: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Qris), radar_options: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::RadarOptions), rechnung: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Rechnung), revolut_pay: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::RevolutPay), samsung_pay: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::SamsungPay), satispay: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Satispay), sepa_debit: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::SepaDebit), shopeepay: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Shopeepay), sofort: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Sofort), stripe_balance: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::StripeBalance), swish: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Swish), twint: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Twint), type: String, us_bank_account: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::UsBankAccount), wechat_pay: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::WechatPay), zip: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData::Zip)).void
}
def initialize(
acss_debit: nil,
affirm: nil,
afterpay_clearpay: nil,
alipay: nil,
allow_redisplay: nil,
alma: nil,
amazon_pay: nil,
au_becs_debit: nil,
bacs_debit: nil,
bancontact: nil,
billie: nil,
billing_details: nil,
blik: nil,
boleto: nil,
cashapp: nil,
customer_balance: nil,
eps: nil,
fpx: nil,
giropay: nil,
gopay: nil,
grabpay: nil,
id_bank_transfer: nil,
ideal: nil,
interac_present: nil,
kakao_pay: nil,
klarna: nil,
konbini: nil,
kr_card: nil,
link: nil,
mb_way: nil,
metadata: nil,
mobilepay: nil,
multibanco: nil,
naver_pay: nil,
nz_bank_account: nil,
oxxo: nil,
p24: nil,
pay_by_bank: nil,
payco: nil,
paynow: nil,
paypal: nil,
payto: nil,
pix: nil,
promptpay: nil,
qris: nil,
radar_options: nil,
rechnung: nil,
revolut_pay: nil,
samsung_pay: nil,
satispay: nil,
sepa_debit: nil,
shopeepay: nil,
sofort: nil,
stripe_balance: nil,
swish: nil,
twint: nil,
type: nil,
us_bank_account: nil,
wechat_pay: nil,
zip: nil
); end
end
class PaymentMethodOptions < Stripe::RequestParams
class AcssDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# A URL for custom mandate text to render during confirmation step.
# The URL will be rendered with additional GET parameters `payment_intent` and `payment_intent_client_secret` when confirming a Payment Intent,
# or `setup_intent` and `setup_intent_client_secret` when confirming a Setup Intent.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :custom_mandate_url
# List of Stripe products where this mandate can be selected automatically.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :default_for
# Description of the mandate interval. Only required if 'payment_schedule' parameter is 'interval' or 'combined'.
sig { returns(T.nilable(String)) }
attr_accessor :interval_description
# Payment schedule for the mandate.
sig { returns(T.nilable(String)) }
attr_accessor :payment_schedule
# Transaction type of the mandate.
sig { returns(T.nilable(String)) }
attr_accessor :transaction_type
sig {
params(custom_mandate_url: T.nilable(T.nilable(String)), default_for: T.nilable(T::Array[String]), interval_description: T.nilable(String), payment_schedule: T.nilable(String), transaction_type: T.nilable(String)).void
}
def initialize(
custom_mandate_url: nil,
default_for: nil,
interval_description: nil,
payment_schedule: nil,
transaction_type: nil
); end
end
# 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).
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions::AcssDebit::MandateOptions))
}
attr_accessor :mandate_options
# Bank account verification method.
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(currency: T.nilable(String), mandate_options: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions::AcssDebit::MandateOptions), verification_method: T.nilable(String)).void
}
def initialize(currency: nil, mandate_options: nil, verification_method: nil); end
end
class AmazonPay < Stripe::RequestParams; end
class BacsDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'DDIC' or 'STRIPE'.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :reference_prefix
sig { params(reference_prefix: T.nilable(T.nilable(String))).void }
def initialize(reference_prefix: nil); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions::BacsDebit::MandateOptions))
}
attr_accessor :mandate_options
sig {
params(mandate_options: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions::BacsDebit::MandateOptions)).void
}
def initialize(mandate_options: nil); end
end
class Card < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Amount to be charged for future payments.
sig { returns(Integer) }
attr_accessor :amount
# One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.
sig { returns(String) }
attr_accessor :amount_type
# Currency in which future payments will be charged. 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).
sig { returns(String) }
attr_accessor :currency
# A description of the mandate or subscription that is meant to be displayed to the customer.
sig { returns(T.nilable(String)) }
attr_accessor :description
# End date of the mandate or subscription. If not provided, the mandate will be active until canceled. If provided, end date should be after start date.
sig { returns(T.nilable(Integer)) }
attr_accessor :end_date
# Specifies payment frequency. One of `day`, `week`, `month`, `year`, or `sporadic`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals between payments. For example, `interval=month` and `interval_count=3` indicates one payment every three months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks). This parameter is optional when `interval=sporadic`.
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_count
# Unique identifier for the mandate or subscription.
sig { returns(String) }
attr_accessor :reference
# Start date of the mandate or subscription. Start date should not be lesser than yesterday.
sig { returns(Integer) }
attr_accessor :start_date
# Specifies the type of mandates supported. Possible values are `india`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :supported_types
sig {
params(amount: Integer, amount_type: String, currency: String, description: T.nilable(String), end_date: T.nilable(Integer), interval: String, interval_count: T.nilable(Integer), reference: String, start_date: Integer, supported_types: T.nilable(T::Array[String])).void
}
def initialize(
amount: nil,
amount_type: nil,
currency: nil,
description: nil,
end_date: nil,
interval: nil,
interval_count: nil,
reference: nil,
start_date: nil,
supported_types: nil
); end
end
class ThreeDSecure < Stripe::RequestParams
class NetworkOptions < Stripe::RequestParams
class CartesBancaires < Stripe::RequestParams
# The cryptogram calculation algorithm used by the card Issuer's ACS
# to calculate the Authentication cryptogram. Also known as `cavvAlgorithm`.
# messageExtension: CB-AVALGO
sig { returns(String) }
attr_accessor :cb_avalgo
# The exemption indicator returned from Cartes Bancaires in the ARes.
# message extension: CB-EXEMPTION; string (4 characters)
# This is a 3 byte bitmap (low significant byte first and most significant
# bit first) that has been Base64 encoded
sig { returns(T.nilable(String)) }
attr_accessor :cb_exemption
# The risk score returned from Cartes Bancaires in the ARes.
# message extension: CB-SCORE; numeric value 0-99
sig { returns(T.nilable(Integer)) }
attr_accessor :cb_score
sig {
params(cb_avalgo: String, cb_exemption: T.nilable(String), cb_score: T.nilable(Integer)).void
}
def initialize(cb_avalgo: nil, cb_exemption: nil, cb_score: nil); end
end
# Cartes Bancaires-specific 3DS fields.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions::CartesBancaires))
}
attr_accessor :cartes_bancaires
sig {
params(cartes_bancaires: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions::CartesBancaires)).void
}
def initialize(cartes_bancaires: nil); end
end
# The `transStatus` returned from the card Issuer’s ACS in the ARes.
sig { returns(T.nilable(String)) }
attr_accessor :ares_trans_status
# The cryptogram, also known as the "authentication value" (AAV, CAVV or
# AEVV). This value is 20 bytes, base64-encoded into a 28-character string.
# (Most 3D Secure providers will return the base64-encoded version, which
# is what you should specify here.)
sig { returns(T.nilable(String)) }
attr_accessor :cryptogram
# The Electronic Commerce Indicator (ECI) is returned by your 3D Secure
# provider and indicates what degree of authentication was performed.
sig { returns(T.nilable(String)) }
attr_accessor :electronic_commerce_indicator
# Network specific 3DS fields. Network specific arguments require an
# explicit card brand choice. The parameter `payment_method_options.card.network``
# must be populated accordingly
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions))
}
attr_accessor :network_options
# The challenge indicator (`threeDSRequestorChallengeInd`) which was requested in the
# AReq sent to the card Issuer's ACS. A string containing 2 digits from 01-99.
sig { returns(T.nilable(String)) }
attr_accessor :requestor_challenge_indicator
# For 3D Secure 1, the XID. For 3D Secure 2, the Directory Server
# Transaction ID (dsTransID).
sig { returns(T.nilable(String)) }
attr_accessor :transaction_id
# The version of 3D Secure that was performed.
sig { returns(T.nilable(String)) }
attr_accessor :version
sig {
params(ares_trans_status: T.nilable(String), cryptogram: T.nilable(String), electronic_commerce_indicator: T.nilable(String), network_options: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions), requestor_challenge_indicator: T.nilable(String), transaction_id: T.nilable(String), version: T.nilable(String)).void
}
def initialize(
ares_trans_status: nil,
cryptogram: nil,
electronic_commerce_indicator: nil,
network_options: nil,
requestor_challenge_indicator: nil,
transaction_id: nil,
version: nil
); end
end
# Configuration options for setting up an eMandate for cards issued in India.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions::Card::MandateOptions))
}
attr_accessor :mandate_options
# When specified, this parameter signals that a card has been collected
# as MOTO (Mail Order Telephone Order) and thus out of scope for SCA. This
# parameter can only be provided during confirmation.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :moto
# Selected network to process this SetupIntent on. Depends on the available networks of the card attached to the SetupIntent. Can be only set confirm-time.
sig { returns(T.nilable(String)) }
attr_accessor :network
# We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. If not provided, this value defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
sig { returns(T.nilable(String)) }
attr_accessor :request_three_d_secure
# If 3D Secure authentication was performed with a third-party provider,
# the authentication details to use for this setup.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions::Card::ThreeDSecure))
}
attr_accessor :three_d_secure
sig {
params(mandate_options: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions::Card::MandateOptions), moto: T.nilable(T::Boolean), network: T.nilable(String), request_three_d_secure: T.nilable(String), three_d_secure: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions::Card::ThreeDSecure)).void
}
def initialize(
mandate_options: nil,
moto: nil,
network: nil,
request_three_d_secure: nil,
three_d_secure: nil
); end
end
class CardPresent < Stripe::RequestParams; end
class Link < Stripe::RequestParams
# [Deprecated] This is a legacy parameter that no longer has any function.
sig { returns(T.nilable(String)) }
attr_accessor :persistent_token
sig { params(persistent_token: T.nilable(String)).void }
def initialize(persistent_token: nil); end
end
class Paypal < Stripe::RequestParams
# The PayPal Billing Agreement ID (BAID). This is an ID generated by PayPal which represents the mandate between the merchant and the customer.
sig { returns(T.nilable(String)) }
attr_accessor :billing_agreement_id
# Attribute for param field currency
sig { returns(T.nilable(String)) }
attr_accessor :currency
# The Stripe connected account IDs of the sellers on the platform for this transaction (optional). Only allowed when [separate charges and transfers](https://stripe.com/docs/connect/separate-charges-and-transfers) are used.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :subsellers
sig {
params(billing_agreement_id: T.nilable(String), currency: T.nilable(String), subsellers: T.nilable(T::Array[String])).void
}
def initialize(billing_agreement_id: nil, currency: nil, subsellers: nil); end
end
class Payto < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Amount that will be collected. It is required when `amount_type` is `fixed`.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# The type of amount that will be collected. The amount charged must be exact or up to the value of `amount` param for `fixed` or `maximum` type respectively.
sig { returns(T.nilable(String)) }
attr_accessor :amount_type
# Date, in YYYY-MM-DD format, after which payments will not be collected. Defaults to no end date.
sig { returns(T.nilable(String)) }
attr_accessor :end_date
# The periodicity at which payments will be collected.
sig { returns(T.nilable(String)) }
attr_accessor :payment_schedule
# The number of payments that will be made during a payment period. Defaults to 1 except for when `payment_schedule` is `adhoc`. In that case, it defaults to no limit.
sig { returns(T.nilable(Integer)) }
attr_accessor :payments_per_period
# The purpose for which payments are made. Defaults to retail.
sig { returns(T.nilable(String)) }
attr_accessor :purpose
# Date, in YYYY-MM-DD format, from which payments will be collected. Defaults to confirmation time.
sig { returns(T.nilable(String)) }
attr_accessor :start_date
sig {
params(amount: T.nilable(Integer), amount_type: T.nilable(String), end_date: T.nilable(String), payment_schedule: T.nilable(String), payments_per_period: T.nilable(Integer), purpose: T.nilable(String), start_date: T.nilable(String)).void
}
def initialize(
amount: nil,
amount_type: nil,
end_date: nil,
payment_schedule: nil,
payments_per_period: nil,
purpose: nil,
start_date: nil
); end
end
# Additional fields for Mandate creation.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions::Payto::MandateOptions))
}
attr_accessor :mandate_options
sig {
params(mandate_options: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions::Payto::MandateOptions)).void
}
def initialize(mandate_options: nil); end
end
class SepaDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'STRIPE'.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :reference_prefix
sig { params(reference_prefix: T.nilable(T.nilable(String))).void }
def initialize(reference_prefix: nil); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions::SepaDebit::MandateOptions))
}
attr_accessor :mandate_options
sig {
params(mandate_options: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions::SepaDebit::MandateOptions)).void
}
def initialize(mandate_options: nil); end
end
class UsBankAccount < Stripe::RequestParams
class FinancialConnections < Stripe::RequestParams
class Filters < Stripe::RequestParams
# The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :account_subcategories
# ID of the institution to use to filter for selectable accounts.
sig { returns(T.nilable(String)) }
attr_accessor :institution
sig {
params(account_subcategories: T.nilable(T::Array[String]), institution: T.nilable(String)).void
}
def initialize(account_subcategories: nil, institution: nil); end
end
class ManualEntry < Stripe::RequestParams
# Settings for configuring manual entry of account details.
sig { returns(String) }
attr_accessor :mode
sig { params(mode: String).void }
def initialize(mode: nil); end
end
# Provide filters for the linked accounts that the customer can select for the payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::Filters))
}
attr_accessor :filters
# Customize manual entry behavior
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::ManualEntry))
}
attr_accessor :manual_entry
# The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :permissions
# List of data features that you would like to retrieve upon account creation.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :prefetch
# For webview integrations only. Upon completing OAuth login in the native browser, the user will be redirected to this URL to return to your app.
sig { returns(T.nilable(String)) }
attr_accessor :return_url
sig {
params(filters: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::Filters), manual_entry: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::ManualEntry), permissions: T.nilable(T::Array[String]), prefetch: T.nilable(T::Array[String]), return_url: T.nilable(String)).void
}
def initialize(
filters: nil,
manual_entry: nil,
permissions: nil,
prefetch: nil,
return_url: nil
); end
end
class MandateOptions < Stripe::RequestParams
# The method used to collect offline mandate customer acceptance.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :collection_method
sig { params(collection_method: T.nilable(T.nilable(String))).void }
def initialize(collection_method: nil); end
end
class Networks < Stripe::RequestParams
# Triggers validations to run across the selected networks
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Array[String])).void }
def initialize(requested: nil); end
end
# Additional fields for Financial Connections Session creation
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections))
}
attr_accessor :financial_connections
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions::UsBankAccount::MandateOptions))
}
attr_accessor :mandate_options
# Additional fields for network related functions
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions::UsBankAccount::Networks))
}
attr_accessor :networks
# Bank account verification method.
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(financial_connections: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections), mandate_options: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions::UsBankAccount::MandateOptions), networks: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions::UsBankAccount::Networks), verification_method: T.nilable(String)).void
}
def initialize(
financial_connections: nil,
mandate_options: nil,
networks: nil,
verification_method: nil
); end
end
# If this is a `acss_debit` SetupIntent, this sub-hash contains details about the ACSS Debit payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions::AcssDebit))
}
attr_accessor :acss_debit
# If this is a `amazon_pay` SetupIntent, this sub-hash contains details about the AmazonPay payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions::AmazonPay))
}
attr_accessor :amazon_pay
# If this is a `bacs_debit` SetupIntent, this sub-hash contains details about the Bacs Debit payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions::BacsDebit))
}
attr_accessor :bacs_debit
# Configuration for any card setup attempted on this SetupIntent.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions::Card))
}
attr_accessor :card
# If this is a `card_present` PaymentMethod, this sub-hash contains details about the card-present payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions::CardPresent))
}
attr_accessor :card_present
# If this is a `link` PaymentMethod, this sub-hash contains details about the Link payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions::Link))
}
attr_accessor :link
# If this is a `paypal` PaymentMethod, this sub-hash contains details about the PayPal payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions::Paypal))
}
attr_accessor :paypal
# If this is a `payto` SetupIntent, this sub-hash contains details about the PayTo payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions::Payto))
}
attr_accessor :payto
# If this is a `sepa_debit` SetupIntent, this sub-hash contains details about the SEPA Debit payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions::SepaDebit))
}
attr_accessor :sepa_debit
# If this is a `us_bank_account` SetupIntent, this sub-hash contains details about the US bank account payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions::UsBankAccount))
}
attr_accessor :us_bank_account
sig {
params(acss_debit: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions::AcssDebit), amazon_pay: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions::AmazonPay), bacs_debit: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions::BacsDebit), card: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions::Card), card_present: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions::CardPresent), link: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions::Link), paypal: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions::Paypal), payto: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions::Payto), sepa_debit: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions::SepaDebit), us_bank_account: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions::UsBankAccount)).void
}
def initialize(
acss_debit: nil,
amazon_pay: nil,
bacs_debit: nil,
card: nil,
card_present: nil,
link: nil,
paypal: nil,
payto: nil,
sepa_debit: nil,
us_bank_account: nil
); end
end
class SingleUse < Stripe::RequestParams
# Amount the customer is granting permission to collect later. A positive integer representing how much to charge in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is $0.50 US or [equivalent in charge currency](https://stripe.com/docs/currencies#minimum-and-maximum-charge-amounts). The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of $999,999.99).
sig { returns(Integer) }
attr_accessor :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).
sig { returns(String) }
attr_accessor :currency
sig { params(amount: Integer, currency: String).void }
def initialize(amount: nil, currency: nil); end
end
# If present, the SetupIntent's payment method will be attached to the in-context Stripe Account.
#
# It can only be used for this Stripe Account’s own money movement flows like InboundTransfer and OutboundTransfers. It cannot be set to true when setting up a PaymentMethod for a Customer, and defaults to false when attaching a PaymentMethod to a Customer.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :attach_to_self
# When you enable this parameter, this SetupIntent accepts payment methods that you enable in the Dashboard and that are compatible with its other parameters.
sig {
returns(T.nilable(::Stripe::SetupIntentService::CreateParams::AutomaticPaymentMethods))
}
attr_accessor :automatic_payment_methods
# Set to `true` to attempt to confirm this SetupIntent immediately. This parameter defaults to `false`. If a card is the attached payment method, you can provide a `return_url` in case further authentication is necessary.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :confirm
# ID of the ConfirmationToken used to confirm this SetupIntent.
#
# If the provided ConfirmationToken contains properties that are also being provided in this request, such as `payment_method`, then the values in this request will take precedence.
sig { returns(T.nilable(String)) }
attr_accessor :confirmation_token
# ID of the Customer this SetupIntent belongs to, if one exists.
#
# If present, the SetupIntent's payment method will be attached to the Customer on successful setup. Payment methods attached to other Customers cannot be used with this SetupIntent.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# ID of the Account this SetupIntent belongs to, if one exists.
#
# If present, the SetupIntent's payment method will be attached to the Account on successful setup. Payment methods attached to other Accounts cannot be used with this SetupIntent.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Indicates the directions of money movement for which this payment method is intended to be used.
#
# Include `inbound` if you intend to use the payment method as the origin to pull funds from. Include `outbound` if you intend to use the payment method as the destination to send funds to. You can include both if you intend to use the payment method for both purposes.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :flow_directions
# This hash contains details about the mandate to create. This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/setup_intents/create#create_setup_intent-confirm).
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SetupIntentService::CreateParams::MandateData))))
}
attr_accessor :mandate_data
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The Stripe account ID created for this SetupIntent.
sig { returns(T.nilable(String)) }
attr_accessor :on_behalf_of
# ID of the payment method (a PaymentMethod, Card, or saved Source object) to attach to this SetupIntent.
sig { returns(T.nilable(String)) }
attr_accessor :payment_method
# The ID of the [payment method configuration](https://stripe.com/docs/api/payment_method_configurations) to use with this SetupIntent.
sig { returns(T.nilable(String)) }
attr_accessor :payment_method_configuration
# When included, this hash creates a PaymentMethod that is set as the [`payment_method`](https://stripe.com/docs/api/setup_intents/object#setup_intent_object-payment_method)
# value in the SetupIntent.
sig { returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData)) }
attr_accessor :payment_method_data
# Payment method-specific configuration for this SetupIntent.
sig { returns(T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions)) }
attr_accessor :payment_method_options
# The list of payment method types (for example, card) that this SetupIntent can use. If you don't provide this, Stripe will dynamically show relevant payment methods from your [payment method settings](https://dashboard.stripe.com/settings/payment_methods).
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :payment_method_types
# The URL to redirect your customer back to after they authenticate or cancel their payment on the payment method's app or site. To redirect to a mobile application, you can alternatively supply an application URI scheme. This parameter can only be used with [`confirm=true`](https://stripe.com/docs/api/setup_intents/create#create_setup_intent-confirm).
sig { returns(T.nilable(String)) }
attr_accessor :return_url
# If you populate this hash, this SetupIntent generates a `single_use` mandate after successful completion.
#
# Single-use mandates are only valid for the following payment methods: `acss_debit`, `alipay`, `au_becs_debit`, `bacs_debit`, `bancontact`, `boleto`, `ideal`, `link`, `sepa_debit`, and `us_bank_account`.
sig { returns(T.nilable(::Stripe::SetupIntentService::CreateParams::SingleUse)) }
attr_accessor :single_use
# Indicates how the payment method is intended to be used in the future. If not provided, this value defaults to `off_session`.
sig { returns(T.nilable(String)) }
attr_accessor :usage
# Set to `true` when confirming server-side and using Stripe.js, iOS, or Android client-side SDKs to handle the next actions.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :use_stripe_sdk
sig {
params(attach_to_self: T.nilable(T::Boolean), automatic_payment_methods: T.nilable(::Stripe::SetupIntentService::CreateParams::AutomaticPaymentMethods), confirm: T.nilable(T::Boolean), confirmation_token: T.nilable(String), customer: T.nilable(String), customer_account: T.nilable(String), description: T.nilable(String), expand: T.nilable(T::Array[String]), flow_directions: T.nilable(T::Array[String]), mandate_data: T.nilable(T.nilable(T.any(String, ::Stripe::SetupIntentService::CreateParams::MandateData))), metadata: T.nilable(T::Hash[String, String]), on_behalf_of: T.nilable(String), payment_method: T.nilable(String), payment_method_configuration: T.nilable(String), payment_method_data: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodData), payment_method_options: T.nilable(::Stripe::SetupIntentService::CreateParams::PaymentMethodOptions), payment_method_types: T.nilable(T::Array[String]), return_url: T.nilable(String), single_use: T.nilable(::Stripe::SetupIntentService::CreateParams::SingleUse), usage: T.nilable(String), use_stripe_sdk: T.nilable(T::Boolean)).void
}
def initialize(
attach_to_self: nil,
automatic_payment_methods: nil,
confirm: nil,
confirmation_token: nil,
customer: nil,
customer_account: nil,
description: nil,
expand: nil,
flow_directions: nil,
mandate_data: nil,
metadata: nil,
on_behalf_of: nil,
payment_method: nil,
payment_method_configuration: nil,
payment_method_data: nil,
payment_method_options: nil,
payment_method_types: nil,
return_url: nil,
single_use: nil,
usage: nil,
use_stripe_sdk: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# The client secret of the SetupIntent. We require this string if you use a publishable key to retrieve the SetupIntent.
sig { returns(T.nilable(String)) }
attr_accessor :client_secret
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(client_secret: T.nilable(String), expand: T.nilable(T::Array[String])).void }
def initialize(client_secret: nil, expand: nil); end
end
class UpdateParams < Stripe::RequestParams
class PaymentMethodData < Stripe::RequestParams
class AcssDebit < Stripe::RequestParams
# Customer's bank account number.
sig { returns(String) }
attr_accessor :account_number
# Institution number of the customer's bank.
sig { returns(String) }
attr_accessor :institution_number
# Transit number of the customer's bank.
sig { returns(String) }
attr_accessor :transit_number
sig {
params(account_number: String, institution_number: String, transit_number: String).void
}
def initialize(account_number: nil, institution_number: nil, transit_number: nil); end
end
class Affirm < Stripe::RequestParams; end
class AfterpayClearpay < Stripe::RequestParams; end
class Alipay < Stripe::RequestParams; end
class Alma < Stripe::RequestParams; end
class AmazonPay < Stripe::RequestParams; end
class AuBecsDebit < Stripe::RequestParams
# The account number for the bank account.
sig { returns(String) }
attr_accessor :account_number
# Bank-State-Branch number of the bank account.
sig { returns(String) }
attr_accessor :bsb_number
sig { params(account_number: String, bsb_number: String).void }
def initialize(account_number: nil, bsb_number: nil); end
end
class BacsDebit < Stripe::RequestParams
# Account number of the bank account that the funds will be debited from.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Sort code of the bank account. (e.g., `10-20-30`)
sig { returns(T.nilable(String)) }
attr_accessor :sort_code
sig { params(account_number: T.nilable(String), sort_code: T.nilable(String)).void }
def initialize(account_number: nil, sort_code: nil); end
end
class Bancontact < Stripe::RequestParams; end
class Billie < Stripe::RequestParams; end
class BillingDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Billing address.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::BillingDetails::Address))))
}
attr_accessor :address
# Email address.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :email
# Full name.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :name
# Billing phone number (including extension).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :phone
# Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
sig { returns(T.nilable(String)) }
attr_accessor :tax_id
sig {
params(address: T.nilable(T.nilable(T.any(String, ::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::BillingDetails::Address))), email: T.nilable(T.nilable(String)), name: T.nilable(T.nilable(String)), phone: T.nilable(T.nilable(String)), tax_id: T.nilable(String)).void
}
def initialize(address: nil, email: nil, name: nil, phone: nil, tax_id: nil); end
end
class Blik < Stripe::RequestParams; end
class Boleto < Stripe::RequestParams
# The tax ID of the customer (CPF for individual consumers or CNPJ for businesses consumers)
sig { returns(String) }
attr_accessor :tax_id
sig { params(tax_id: String).void }
def initialize(tax_id: nil); end
end
class Cashapp < Stripe::RequestParams; end
class CustomerBalance < Stripe::RequestParams; end
class Eps < Stripe::RequestParams
# The customer's bank.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class Fpx < Stripe::RequestParams
# Account holder type for FPX transaction
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_type
# The customer's bank.
sig { returns(String) }
attr_accessor :bank
sig { params(account_holder_type: T.nilable(String), bank: String).void }
def initialize(account_holder_type: nil, bank: nil); end
end
class Giropay < Stripe::RequestParams; end
class Gopay < Stripe::RequestParams; end
class Grabpay < Stripe::RequestParams; end
class IdBankTransfer < Stripe::RequestParams
# Bank where the account is held.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class Ideal < Stripe::RequestParams
# The customer's bank. Only use this parameter for existing customers. Don't use it for new customers.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class InteracPresent < Stripe::RequestParams; end
class KakaoPay < Stripe::RequestParams; end
class Klarna < Stripe::RequestParams
class Dob < Stripe::RequestParams
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
# Customer's date of birth
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Klarna::Dob))
}
attr_accessor :dob
sig {
params(dob: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Klarna::Dob)).void
}
def initialize(dob: nil); end
end
class Konbini < Stripe::RequestParams; end
class KrCard < Stripe::RequestParams; end
class Link < Stripe::RequestParams; end
class MbWay < Stripe::RequestParams; end
class Mobilepay < Stripe::RequestParams; end
class Multibanco < Stripe::RequestParams; end
class NaverPay < Stripe::RequestParams
# Whether to use Naver Pay points or a card to fund this transaction. If not provided, this defaults to `card`.
sig { returns(T.nilable(String)) }
attr_accessor :funding
sig { params(funding: T.nilable(String)).void }
def initialize(funding: nil); end
end
class NzBankAccount < Stripe::RequestParams
# The name on the bank account. Only required if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod’s billing details.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_name
# The account number for the bank account.
sig { returns(String) }
attr_accessor :account_number
# The numeric code for the bank account's bank.
sig { returns(String) }
attr_accessor :bank_code
# The numeric code for the bank account's bank branch.
sig { returns(String) }
attr_accessor :branch_code
# Attribute for param field reference
sig { returns(T.nilable(String)) }
attr_accessor :reference
# The suffix of the bank account number.
sig { returns(String) }
attr_accessor :suffix
sig {
params(account_holder_name: T.nilable(String), account_number: String, bank_code: String, branch_code: String, reference: T.nilable(String), suffix: String).void
}
def initialize(
account_holder_name: nil,
account_number: nil,
bank_code: nil,
branch_code: nil,
reference: nil,
suffix: nil
); end
end
class Oxxo < Stripe::RequestParams; end
class P24 < Stripe::RequestParams
# The customer's bank.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class PayByBank < Stripe::RequestParams; end
class Payco < Stripe::RequestParams; end
class Paynow < Stripe::RequestParams; end
class Paypal < Stripe::RequestParams; end
class Payto < Stripe::RequestParams
# The account number for the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Bank-State-Branch number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :bsb_number
# The PayID alias for the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :pay_id
sig {
params(account_number: T.nilable(String), bsb_number: T.nilable(String), pay_id: T.nilable(String)).void
}
def initialize(account_number: nil, bsb_number: nil, pay_id: nil); end
end
class Pix < Stripe::RequestParams; end
class Promptpay < Stripe::RequestParams; end
class Qris < Stripe::RequestParams; end
class RadarOptions < Stripe::RequestParams
# A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
sig { returns(T.nilable(String)) }
attr_accessor :session
sig { params(session: T.nilable(String)).void }
def initialize(session: nil); end
end
class Rechnung < Stripe::RequestParams
class Dob < Stripe::RequestParams
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
# Customer's date of birth
sig {
returns(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Rechnung::Dob)
}
attr_accessor :dob
sig {
params(dob: ::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Rechnung::Dob).void
}
def initialize(dob: nil); end
end
class RevolutPay < Stripe::RequestParams; end
class SamsungPay < Stripe::RequestParams; end
class Satispay < Stripe::RequestParams; end
class SepaDebit < Stripe::RequestParams
# IBAN of the bank account.
sig { returns(String) }
attr_accessor :iban
sig { params(iban: String).void }
def initialize(iban: nil); end
end
class Shopeepay < Stripe::RequestParams; end
class Sofort < Stripe::RequestParams
# Two-letter ISO code representing the country the bank account is located in.
sig { returns(String) }
attr_accessor :country
sig { params(country: String).void }
def initialize(country: nil); end
end
class StripeBalance < Stripe::RequestParams
# The connected account ID whose Stripe balance to use as the source of payment
sig { returns(T.nilable(String)) }
attr_accessor :account
# The [source_type](https://docs.stripe.com/api/balance/balance_object#balance_object-available-source_types) of the balance
sig { returns(T.nilable(String)) }
attr_accessor :source_type
sig { params(account: T.nilable(String), source_type: T.nilable(String)).void }
def initialize(account: nil, source_type: nil); end
end
class Swish < Stripe::RequestParams; end
class Twint < Stripe::RequestParams; end
class UsBankAccount < Stripe::RequestParams
# Account holder type: individual or company.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_type
# Account number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Account type: checkings or savings. Defaults to checking if omitted.
sig { returns(T.nilable(String)) }
attr_accessor :account_type
# The ID of a Financial Connections Account to use as a payment method.
sig { returns(T.nilable(String)) }
attr_accessor :financial_connections_account
# Routing number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :routing_number
sig {
params(account_holder_type: T.nilable(String), account_number: T.nilable(String), account_type: T.nilable(String), financial_connections_account: T.nilable(String), routing_number: T.nilable(String)).void
}
def initialize(
account_holder_type: nil,
account_number: nil,
account_type: nil,
financial_connections_account: nil,
routing_number: nil
); end
end
class WechatPay < Stripe::RequestParams; end
class Zip < Stripe::RequestParams; end
# If this is an `acss_debit` PaymentMethod, this hash contains details about the ACSS Debit payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::AcssDebit))
}
attr_accessor :acss_debit
# If this is an `affirm` PaymentMethod, this hash contains details about the Affirm payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Affirm))
}
attr_accessor :affirm
# If this is an `AfterpayClearpay` PaymentMethod, this hash contains details about the AfterpayClearpay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::AfterpayClearpay))
}
attr_accessor :afterpay_clearpay
# If this is an `Alipay` PaymentMethod, this hash contains details about the Alipay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Alipay))
}
attr_accessor :alipay
# This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :allow_redisplay
# If this is a Alma PaymentMethod, this hash contains details about the Alma payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Alma))
}
attr_accessor :alma
# If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::AmazonPay))
}
attr_accessor :amazon_pay
# If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::AuBecsDebit))
}
attr_accessor :au_becs_debit
# If this is a `bacs_debit` PaymentMethod, this hash contains details about the Bacs Direct Debit bank account.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::BacsDebit))
}
attr_accessor :bacs_debit
# If this is a `bancontact` PaymentMethod, this hash contains details about the Bancontact payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Bancontact))
}
attr_accessor :bancontact
# If this is a `billie` PaymentMethod, this hash contains details about the Billie payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Billie))
}
attr_accessor :billie
# Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::BillingDetails))
}
attr_accessor :billing_details
# If this is a `blik` PaymentMethod, this hash contains details about the BLIK payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Blik))
}
attr_accessor :blik
# If this is a `boleto` PaymentMethod, this hash contains details about the Boleto payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Boleto))
}
attr_accessor :boleto
# If this is a `cashapp` PaymentMethod, this hash contains details about the Cash App Pay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Cashapp))
}
attr_accessor :cashapp
# If this is a `customer_balance` PaymentMethod, this hash contains details about the CustomerBalance payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::CustomerBalance))
}
attr_accessor :customer_balance
# If this is an `eps` PaymentMethod, this hash contains details about the EPS payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Eps))
}
attr_accessor :eps
# If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Fpx))
}
attr_accessor :fpx
# If this is a `giropay` PaymentMethod, this hash contains details about the Giropay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Giropay))
}
attr_accessor :giropay
# If this is a Gopay PaymentMethod, this hash contains details about the Gopay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Gopay))
}
attr_accessor :gopay
# If this is a `grabpay` PaymentMethod, this hash contains details about the GrabPay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Grabpay))
}
attr_accessor :grabpay
# If this is an `IdBankTransfer` PaymentMethod, this hash contains details about the IdBankTransfer payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::IdBankTransfer))
}
attr_accessor :id_bank_transfer
# If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Ideal))
}
attr_accessor :ideal
# If this is an `interac_present` PaymentMethod, this hash contains details about the Interac Present payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::InteracPresent))
}
attr_accessor :interac_present
# If this is a `kakao_pay` PaymentMethod, this hash contains details about the Kakao Pay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::KakaoPay))
}
attr_accessor :kakao_pay
# If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Klarna))
}
attr_accessor :klarna
# If this is a `konbini` PaymentMethod, this hash contains details about the Konbini payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Konbini))
}
attr_accessor :konbini
# If this is a `kr_card` PaymentMethod, this hash contains details about the Korean Card payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::KrCard))
}
attr_accessor :kr_card
# If this is an `Link` PaymentMethod, this hash contains details about the Link payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Link))
}
attr_accessor :link
# If this is a MB WAY PaymentMethod, this hash contains details about the MB WAY payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::MbWay))
}
attr_accessor :mb_way
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# If this is a `mobilepay` PaymentMethod, this hash contains details about the MobilePay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Mobilepay))
}
attr_accessor :mobilepay
# If this is a `multibanco` PaymentMethod, this hash contains details about the Multibanco payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Multibanco))
}
attr_accessor :multibanco
# If this is a `naver_pay` PaymentMethod, this hash contains details about the Naver Pay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::NaverPay))
}
attr_accessor :naver_pay
# If this is an nz_bank_account PaymentMethod, this hash contains details about the nz_bank_account payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::NzBankAccount))
}
attr_accessor :nz_bank_account
# If this is an `oxxo` PaymentMethod, this hash contains details about the OXXO payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Oxxo))
}
attr_accessor :oxxo
# If this is a `p24` PaymentMethod, this hash contains details about the P24 payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::P24))
}
attr_accessor :p24
# If this is a `pay_by_bank` PaymentMethod, this hash contains details about the PayByBank payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::PayByBank))
}
attr_accessor :pay_by_bank
# If this is a `payco` PaymentMethod, this hash contains details about the PAYCO payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Payco))
}
attr_accessor :payco
# If this is a `paynow` PaymentMethod, this hash contains details about the PayNow payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Paynow))
}
attr_accessor :paynow
# If this is a `paypal` PaymentMethod, this hash contains details about the PayPal payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Paypal))
}
attr_accessor :paypal
# If this is a `payto` PaymentMethod, this hash contains details about the PayTo payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Payto))
}
attr_accessor :payto
# If this is a `pix` PaymentMethod, this hash contains details about the Pix payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Pix))
}
attr_accessor :pix
# If this is a `promptpay` PaymentMethod, this hash contains details about the PromptPay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Promptpay))
}
attr_accessor :promptpay
# If this is a `qris` PaymentMethod, this hash contains details about the QRIS payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Qris))
}
attr_accessor :qris
# Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::RadarOptions))
}
attr_accessor :radar_options
# If this is a `rechnung` PaymentMethod, this hash contains details about the Rechnung payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Rechnung))
}
attr_accessor :rechnung
# If this is a `revolut_pay` PaymentMethod, this hash contains details about the Revolut Pay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::RevolutPay))
}
attr_accessor :revolut_pay
# If this is a `samsung_pay` PaymentMethod, this hash contains details about the SamsungPay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::SamsungPay))
}
attr_accessor :samsung_pay
# If this is a `satispay` PaymentMethod, this hash contains details about the Satispay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Satispay))
}
attr_accessor :satispay
# If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::SepaDebit))
}
attr_accessor :sepa_debit
# If this is a Shopeepay PaymentMethod, this hash contains details about the Shopeepay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Shopeepay))
}
attr_accessor :shopeepay
# If this is a `sofort` PaymentMethod, this hash contains details about the SOFORT payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Sofort))
}
attr_accessor :sofort
# This hash contains details about the Stripe balance payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::StripeBalance))
}
attr_accessor :stripe_balance
# If this is a `swish` PaymentMethod, this hash contains details about the Swish payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Swish))
}
attr_accessor :swish
# If this is a TWINT PaymentMethod, this hash contains details about the TWINT payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Twint))
}
attr_accessor :twint
# The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
sig { returns(String) }
attr_accessor :type
# If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::UsBankAccount))
}
attr_accessor :us_bank_account
# If this is an `wechat_pay` PaymentMethod, this hash contains details about the wechat_pay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::WechatPay))
}
attr_accessor :wechat_pay
# If this is a `zip` PaymentMethod, this hash contains details about the Zip payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Zip))
}
attr_accessor :zip
sig {
params(acss_debit: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::AcssDebit), affirm: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Affirm), afterpay_clearpay: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::AfterpayClearpay), alipay: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Alipay), allow_redisplay: T.nilable(String), alma: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Alma), amazon_pay: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::AmazonPay), au_becs_debit: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::AuBecsDebit), bacs_debit: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::BacsDebit), bancontact: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Bancontact), billie: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Billie), billing_details: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::BillingDetails), blik: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Blik), boleto: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Boleto), cashapp: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Cashapp), customer_balance: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::CustomerBalance), eps: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Eps), fpx: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Fpx), giropay: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Giropay), gopay: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Gopay), grabpay: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Grabpay), id_bank_transfer: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::IdBankTransfer), ideal: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Ideal), interac_present: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::InteracPresent), kakao_pay: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::KakaoPay), klarna: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Klarna), konbini: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Konbini), kr_card: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::KrCard), link: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Link), mb_way: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::MbWay), metadata: T.nilable(T::Hash[String, String]), mobilepay: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Mobilepay), multibanco: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Multibanco), naver_pay: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::NaverPay), nz_bank_account: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::NzBankAccount), oxxo: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Oxxo), p24: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::P24), pay_by_bank: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::PayByBank), payco: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Payco), paynow: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Paynow), paypal: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Paypal), payto: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Payto), pix: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Pix), promptpay: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Promptpay), qris: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Qris), radar_options: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::RadarOptions), rechnung: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Rechnung), revolut_pay: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::RevolutPay), samsung_pay: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::SamsungPay), satispay: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Satispay), sepa_debit: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::SepaDebit), shopeepay: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Shopeepay), sofort: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Sofort), stripe_balance: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::StripeBalance), swish: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Swish), twint: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Twint), type: String, us_bank_account: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::UsBankAccount), wechat_pay: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::WechatPay), zip: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData::Zip)).void
}
def initialize(
acss_debit: nil,
affirm: nil,
afterpay_clearpay: nil,
alipay: nil,
allow_redisplay: nil,
alma: nil,
amazon_pay: nil,
au_becs_debit: nil,
bacs_debit: nil,
bancontact: nil,
billie: nil,
billing_details: nil,
blik: nil,
boleto: nil,
cashapp: nil,
customer_balance: nil,
eps: nil,
fpx: nil,
giropay: nil,
gopay: nil,
grabpay: nil,
id_bank_transfer: nil,
ideal: nil,
interac_present: nil,
kakao_pay: nil,
klarna: nil,
konbini: nil,
kr_card: nil,
link: nil,
mb_way: nil,
metadata: nil,
mobilepay: nil,
multibanco: nil,
naver_pay: nil,
nz_bank_account: nil,
oxxo: nil,
p24: nil,
pay_by_bank: nil,
payco: nil,
paynow: nil,
paypal: nil,
payto: nil,
pix: nil,
promptpay: nil,
qris: nil,
radar_options: nil,
rechnung: nil,
revolut_pay: nil,
samsung_pay: nil,
satispay: nil,
sepa_debit: nil,
shopeepay: nil,
sofort: nil,
stripe_balance: nil,
swish: nil,
twint: nil,
type: nil,
us_bank_account: nil,
wechat_pay: nil,
zip: nil
); end
end
class PaymentMethodOptions < Stripe::RequestParams
class AcssDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# A URL for custom mandate text to render during confirmation step.
# The URL will be rendered with additional GET parameters `payment_intent` and `payment_intent_client_secret` when confirming a Payment Intent,
# or `setup_intent` and `setup_intent_client_secret` when confirming a Setup Intent.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :custom_mandate_url
# List of Stripe products where this mandate can be selected automatically.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :default_for
# Description of the mandate interval. Only required if 'payment_schedule' parameter is 'interval' or 'combined'.
sig { returns(T.nilable(String)) }
attr_accessor :interval_description
# Payment schedule for the mandate.
sig { returns(T.nilable(String)) }
attr_accessor :payment_schedule
# Transaction type of the mandate.
sig { returns(T.nilable(String)) }
attr_accessor :transaction_type
sig {
params(custom_mandate_url: T.nilable(T.nilable(String)), default_for: T.nilable(T::Array[String]), interval_description: T.nilable(String), payment_schedule: T.nilable(String), transaction_type: T.nilable(String)).void
}
def initialize(
custom_mandate_url: nil,
default_for: nil,
interval_description: nil,
payment_schedule: nil,
transaction_type: nil
); end
end
# 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).
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions::AcssDebit::MandateOptions))
}
attr_accessor :mandate_options
# Bank account verification method.
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(currency: T.nilable(String), mandate_options: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions::AcssDebit::MandateOptions), verification_method: T.nilable(String)).void
}
def initialize(currency: nil, mandate_options: nil, verification_method: nil); end
end
class AmazonPay < Stripe::RequestParams; end
class BacsDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'DDIC' or 'STRIPE'.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :reference_prefix
sig { params(reference_prefix: T.nilable(T.nilable(String))).void }
def initialize(reference_prefix: nil); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions::BacsDebit::MandateOptions))
}
attr_accessor :mandate_options
sig {
params(mandate_options: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions::BacsDebit::MandateOptions)).void
}
def initialize(mandate_options: nil); end
end
class Card < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Amount to be charged for future payments.
sig { returns(Integer) }
attr_accessor :amount
# One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.
sig { returns(String) }
attr_accessor :amount_type
# Currency in which future payments will be charged. 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).
sig { returns(String) }
attr_accessor :currency
# A description of the mandate or subscription that is meant to be displayed to the customer.
sig { returns(T.nilable(String)) }
attr_accessor :description
# End date of the mandate or subscription. If not provided, the mandate will be active until canceled. If provided, end date should be after start date.
sig { returns(T.nilable(Integer)) }
attr_accessor :end_date
# Specifies payment frequency. One of `day`, `week`, `month`, `year`, or `sporadic`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals between payments. For example, `interval=month` and `interval_count=3` indicates one payment every three months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks). This parameter is optional when `interval=sporadic`.
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_count
# Unique identifier for the mandate or subscription.
sig { returns(String) }
attr_accessor :reference
# Start date of the mandate or subscription. Start date should not be lesser than yesterday.
sig { returns(Integer) }
attr_accessor :start_date
# Specifies the type of mandates supported. Possible values are `india`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :supported_types
sig {
params(amount: Integer, amount_type: String, currency: String, description: T.nilable(String), end_date: T.nilable(Integer), interval: String, interval_count: T.nilable(Integer), reference: String, start_date: Integer, supported_types: T.nilable(T::Array[String])).void
}
def initialize(
amount: nil,
amount_type: nil,
currency: nil,
description: nil,
end_date: nil,
interval: nil,
interval_count: nil,
reference: nil,
start_date: nil,
supported_types: nil
); end
end
class ThreeDSecure < Stripe::RequestParams
class NetworkOptions < Stripe::RequestParams
class CartesBancaires < Stripe::RequestParams
# The cryptogram calculation algorithm used by the card Issuer's ACS
# to calculate the Authentication cryptogram. Also known as `cavvAlgorithm`.
# messageExtension: CB-AVALGO
sig { returns(String) }
attr_accessor :cb_avalgo
# The exemption indicator returned from Cartes Bancaires in the ARes.
# message extension: CB-EXEMPTION; string (4 characters)
# This is a 3 byte bitmap (low significant byte first and most significant
# bit first) that has been Base64 encoded
sig { returns(T.nilable(String)) }
attr_accessor :cb_exemption
# The risk score returned from Cartes Bancaires in the ARes.
# message extension: CB-SCORE; numeric value 0-99
sig { returns(T.nilable(Integer)) }
attr_accessor :cb_score
sig {
params(cb_avalgo: String, cb_exemption: T.nilable(String), cb_score: T.nilable(Integer)).void
}
def initialize(cb_avalgo: nil, cb_exemption: nil, cb_score: nil); end
end
# Cartes Bancaires-specific 3DS fields.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions::CartesBancaires))
}
attr_accessor :cartes_bancaires
sig {
params(cartes_bancaires: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions::CartesBancaires)).void
}
def initialize(cartes_bancaires: nil); end
end
# The `transStatus` returned from the card Issuer’s ACS in the ARes.
sig { returns(T.nilable(String)) }
attr_accessor :ares_trans_status
# The cryptogram, also known as the "authentication value" (AAV, CAVV or
# AEVV). This value is 20 bytes, base64-encoded into a 28-character string.
# (Most 3D Secure providers will return the base64-encoded version, which
# is what you should specify here.)
sig { returns(T.nilable(String)) }
attr_accessor :cryptogram
# The Electronic Commerce Indicator (ECI) is returned by your 3D Secure
# provider and indicates what degree of authentication was performed.
sig { returns(T.nilable(String)) }
attr_accessor :electronic_commerce_indicator
# Network specific 3DS fields. Network specific arguments require an
# explicit card brand choice. The parameter `payment_method_options.card.network``
# must be populated accordingly
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions))
}
attr_accessor :network_options
# The challenge indicator (`threeDSRequestorChallengeInd`) which was requested in the
# AReq sent to the card Issuer's ACS. A string containing 2 digits from 01-99.
sig { returns(T.nilable(String)) }
attr_accessor :requestor_challenge_indicator
# For 3D Secure 1, the XID. For 3D Secure 2, the Directory Server
# Transaction ID (dsTransID).
sig { returns(T.nilable(String)) }
attr_accessor :transaction_id
# The version of 3D Secure that was performed.
sig { returns(T.nilable(String)) }
attr_accessor :version
sig {
params(ares_trans_status: T.nilable(String), cryptogram: T.nilable(String), electronic_commerce_indicator: T.nilable(String), network_options: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions), requestor_challenge_indicator: T.nilable(String), transaction_id: T.nilable(String), version: T.nilable(String)).void
}
def initialize(
ares_trans_status: nil,
cryptogram: nil,
electronic_commerce_indicator: nil,
network_options: nil,
requestor_challenge_indicator: nil,
transaction_id: nil,
version: nil
); end
end
# Configuration options for setting up an eMandate for cards issued in India.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions::Card::MandateOptions))
}
attr_accessor :mandate_options
# When specified, this parameter signals that a card has been collected
# as MOTO (Mail Order Telephone Order) and thus out of scope for SCA. This
# parameter can only be provided during confirmation.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :moto
# Selected network to process this SetupIntent on. Depends on the available networks of the card attached to the SetupIntent. Can be only set confirm-time.
sig { returns(T.nilable(String)) }
attr_accessor :network
# We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. If not provided, this value defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
sig { returns(T.nilable(String)) }
attr_accessor :request_three_d_secure
# If 3D Secure authentication was performed with a third-party provider,
# the authentication details to use for this setup.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions::Card::ThreeDSecure))
}
attr_accessor :three_d_secure
sig {
params(mandate_options: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions::Card::MandateOptions), moto: T.nilable(T::Boolean), network: T.nilable(String), request_three_d_secure: T.nilable(String), three_d_secure: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions::Card::ThreeDSecure)).void
}
def initialize(
mandate_options: nil,
moto: nil,
network: nil,
request_three_d_secure: nil,
three_d_secure: nil
); end
end
class CardPresent < Stripe::RequestParams; end
class Link < Stripe::RequestParams
# [Deprecated] This is a legacy parameter that no longer has any function.
sig { returns(T.nilable(String)) }
attr_accessor :persistent_token
sig { params(persistent_token: T.nilable(String)).void }
def initialize(persistent_token: nil); end
end
class Paypal < Stripe::RequestParams
# The PayPal Billing Agreement ID (BAID). This is an ID generated by PayPal which represents the mandate between the merchant and the customer.
sig { returns(T.nilable(String)) }
attr_accessor :billing_agreement_id
# Attribute for param field currency
sig { returns(T.nilable(String)) }
attr_accessor :currency
# The Stripe connected account IDs of the sellers on the platform for this transaction (optional). Only allowed when [separate charges and transfers](https://stripe.com/docs/connect/separate-charges-and-transfers) are used.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :subsellers
sig {
params(billing_agreement_id: T.nilable(String), currency: T.nilable(String), subsellers: T.nilable(T::Array[String])).void
}
def initialize(billing_agreement_id: nil, currency: nil, subsellers: nil); end
end
class Payto < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Amount that will be collected. It is required when `amount_type` is `fixed`.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# The type of amount that will be collected. The amount charged must be exact or up to the value of `amount` param for `fixed` or `maximum` type respectively.
sig { returns(T.nilable(String)) }
attr_accessor :amount_type
# Date, in YYYY-MM-DD format, after which payments will not be collected. Defaults to no end date.
sig { returns(T.nilable(String)) }
attr_accessor :end_date
# The periodicity at which payments will be collected.
sig { returns(T.nilable(String)) }
attr_accessor :payment_schedule
# The number of payments that will be made during a payment period. Defaults to 1 except for when `payment_schedule` is `adhoc`. In that case, it defaults to no limit.
sig { returns(T.nilable(Integer)) }
attr_accessor :payments_per_period
# The purpose for which payments are made. Defaults to retail.
sig { returns(T.nilable(String)) }
attr_accessor :purpose
# Date, in YYYY-MM-DD format, from which payments will be collected. Defaults to confirmation time.
sig { returns(T.nilable(String)) }
attr_accessor :start_date
sig {
params(amount: T.nilable(Integer), amount_type: T.nilable(String), end_date: T.nilable(String), payment_schedule: T.nilable(String), payments_per_period: T.nilable(Integer), purpose: T.nilable(String), start_date: T.nilable(String)).void
}
def initialize(
amount: nil,
amount_type: nil,
end_date: nil,
payment_schedule: nil,
payments_per_period: nil,
purpose: nil,
start_date: nil
); end
end
# Additional fields for Mandate creation.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions::Payto::MandateOptions))
}
attr_accessor :mandate_options
sig {
params(mandate_options: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions::Payto::MandateOptions)).void
}
def initialize(mandate_options: nil); end
end
class SepaDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'STRIPE'.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :reference_prefix
sig { params(reference_prefix: T.nilable(T.nilable(String))).void }
def initialize(reference_prefix: nil); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions::SepaDebit::MandateOptions))
}
attr_accessor :mandate_options
sig {
params(mandate_options: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions::SepaDebit::MandateOptions)).void
}
def initialize(mandate_options: nil); end
end
class UsBankAccount < Stripe::RequestParams
class FinancialConnections < Stripe::RequestParams
class Filters < Stripe::RequestParams
# The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :account_subcategories
# ID of the institution to use to filter for selectable accounts.
sig { returns(T.nilable(String)) }
attr_accessor :institution
sig {
params(account_subcategories: T.nilable(T::Array[String]), institution: T.nilable(String)).void
}
def initialize(account_subcategories: nil, institution: nil); end
end
class ManualEntry < Stripe::RequestParams
# Settings for configuring manual entry of account details.
sig { returns(String) }
attr_accessor :mode
sig { params(mode: String).void }
def initialize(mode: nil); end
end
# Provide filters for the linked accounts that the customer can select for the payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::Filters))
}
attr_accessor :filters
# Customize manual entry behavior
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::ManualEntry))
}
attr_accessor :manual_entry
# The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :permissions
# List of data features that you would like to retrieve upon account creation.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :prefetch
# For webview integrations only. Upon completing OAuth login in the native browser, the user will be redirected to this URL to return to your app.
sig { returns(T.nilable(String)) }
attr_accessor :return_url
sig {
params(filters: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::Filters), manual_entry: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::ManualEntry), permissions: T.nilable(T::Array[String]), prefetch: T.nilable(T::Array[String]), return_url: T.nilable(String)).void
}
def initialize(
filters: nil,
manual_entry: nil,
permissions: nil,
prefetch: nil,
return_url: nil
); end
end
class MandateOptions < Stripe::RequestParams
# The method used to collect offline mandate customer acceptance.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :collection_method
sig { params(collection_method: T.nilable(T.nilable(String))).void }
def initialize(collection_method: nil); end
end
class Networks < Stripe::RequestParams
# Triggers validations to run across the selected networks
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Array[String])).void }
def initialize(requested: nil); end
end
# Additional fields for Financial Connections Session creation
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections))
}
attr_accessor :financial_connections
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions::UsBankAccount::MandateOptions))
}
attr_accessor :mandate_options
# Additional fields for network related functions
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions::UsBankAccount::Networks))
}
attr_accessor :networks
# Bank account verification method.
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(financial_connections: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions::UsBankAccount::FinancialConnections), mandate_options: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions::UsBankAccount::MandateOptions), networks: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions::UsBankAccount::Networks), verification_method: T.nilable(String)).void
}
def initialize(
financial_connections: nil,
mandate_options: nil,
networks: nil,
verification_method: nil
); end
end
# If this is a `acss_debit` SetupIntent, this sub-hash contains details about the ACSS Debit payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions::AcssDebit))
}
attr_accessor :acss_debit
# If this is a `amazon_pay` SetupIntent, this sub-hash contains details about the AmazonPay payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions::AmazonPay))
}
attr_accessor :amazon_pay
# If this is a `bacs_debit` SetupIntent, this sub-hash contains details about the Bacs Debit payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions::BacsDebit))
}
attr_accessor :bacs_debit
# Configuration for any card setup attempted on this SetupIntent.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions::Card))
}
attr_accessor :card
# If this is a `card_present` PaymentMethod, this sub-hash contains details about the card-present payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions::CardPresent))
}
attr_accessor :card_present
# If this is a `link` PaymentMethod, this sub-hash contains details about the Link payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions::Link))
}
attr_accessor :link
# If this is a `paypal` PaymentMethod, this sub-hash contains details about the PayPal payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions::Paypal))
}
attr_accessor :paypal
# If this is a `payto` SetupIntent, this sub-hash contains details about the PayTo payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions::Payto))
}
attr_accessor :payto
# If this is a `sepa_debit` SetupIntent, this sub-hash contains details about the SEPA Debit payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions::SepaDebit))
}
attr_accessor :sepa_debit
# If this is a `us_bank_account` SetupIntent, this sub-hash contains details about the US bank account payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions::UsBankAccount))
}
attr_accessor :us_bank_account
sig {
params(acss_debit: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions::AcssDebit), amazon_pay: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions::AmazonPay), bacs_debit: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions::BacsDebit), card: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions::Card), card_present: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions::CardPresent), link: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions::Link), paypal: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions::Paypal), payto: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions::Payto), sepa_debit: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions::SepaDebit), us_bank_account: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions::UsBankAccount)).void
}
def initialize(
acss_debit: nil,
amazon_pay: nil,
bacs_debit: nil,
card: nil,
card_present: nil,
link: nil,
paypal: nil,
payto: nil,
sepa_debit: nil,
us_bank_account: nil
); end
end
# If present, the SetupIntent's payment method will be attached to the in-context Stripe Account.
#
# It can only be used for this Stripe Account’s own money movement flows like InboundTransfer and OutboundTransfers. It cannot be set to true when setting up a PaymentMethod for a Customer, and defaults to false when attaching a PaymentMethod to a Customer.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :attach_to_self
# ID of the Customer this SetupIntent belongs to, if one exists.
#
# If present, the SetupIntent's payment method will be attached to the Customer on successful setup. Payment methods attached to other Customers cannot be used with this SetupIntent.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# ID of the Account this SetupIntent belongs to, if one exists.
#
# If present, the SetupIntent's payment method will be attached to the Account on successful setup. Payment methods attached to other Accounts cannot be used with this SetupIntent.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Indicates the directions of money movement for which this payment method is intended to be used.
#
# Include `inbound` if you intend to use the payment method as the origin to pull funds from. Include `outbound` if you intend to use the payment method as the destination to send funds to. You can include both if you intend to use the payment method for both purposes.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :flow_directions
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# ID of the payment method (a PaymentMethod, Card, or saved Source object) to attach to this SetupIntent. To unset this field to null, pass in an empty string.
sig { returns(T.nilable(String)) }
attr_accessor :payment_method
# The ID of the [payment method configuration](https://stripe.com/docs/api/payment_method_configurations) to use with this SetupIntent.
sig { returns(T.nilable(String)) }
attr_accessor :payment_method_configuration
# When included, this hash creates a PaymentMethod that is set as the [`payment_method`](https://stripe.com/docs/api/setup_intents/object#setup_intent_object-payment_method)
# value in the SetupIntent.
sig { returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData)) }
attr_accessor :payment_method_data
# Payment method-specific configuration for this SetupIntent.
sig { returns(T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions)) }
attr_accessor :payment_method_options
# The list of payment method types (for example, card) that this SetupIntent can set up. If you don't provide this, Stripe will dynamically show relevant payment methods from your [payment method settings](https://dashboard.stripe.com/settings/payment_methods).
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :payment_method_types
sig {
params(attach_to_self: T.nilable(T::Boolean), customer: T.nilable(String), customer_account: T.nilable(String), description: T.nilable(String), expand: T.nilable(T::Array[String]), flow_directions: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), payment_method: T.nilable(String), payment_method_configuration: T.nilable(String), payment_method_data: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodData), payment_method_options: T.nilable(::Stripe::SetupIntentService::UpdateParams::PaymentMethodOptions), payment_method_types: T.nilable(T::Array[String])).void
}
def initialize(
attach_to_self: nil,
customer: nil,
customer_account: nil,
description: nil,
expand: nil,
flow_directions: nil,
metadata: nil,
payment_method: nil,
payment_method_configuration: nil,
payment_method_data: nil,
payment_method_options: nil,
payment_method_types: nil
); end
end
class CancelParams < Stripe::RequestParams
# Reason for canceling this SetupIntent. Possible values are: `abandoned`, `requested_by_customer`, or `duplicate`
sig { returns(T.nilable(String)) }
attr_accessor :cancellation_reason
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig {
params(cancellation_reason: T.nilable(String), expand: T.nilable(T::Array[String])).void
}
def initialize(cancellation_reason: nil, expand: nil); end
end
class ConfirmParams < Stripe::RequestParams
class MandateData < Stripe::RequestParams
class CustomerAcceptance < Stripe::RequestParams
class Offline < Stripe::RequestParams; end
class Online < Stripe::RequestParams
# The IP address from which the Mandate was accepted by the customer.
sig { returns(T.nilable(String)) }
attr_accessor :ip_address
# The user agent of the browser from which the Mandate was accepted by the customer.
sig { returns(T.nilable(String)) }
attr_accessor :user_agent
sig { params(ip_address: T.nilable(String), user_agent: T.nilable(String)).void }
def initialize(ip_address: nil, user_agent: nil); end
end
# The time at which the customer accepted the Mandate.
sig { returns(T.nilable(Integer)) }
attr_accessor :accepted_at
# If this is a Mandate accepted offline, this hash contains details about the offline acceptance.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::MandateData::CustomerAcceptance::Offline))
}
attr_accessor :offline
# If this is a Mandate accepted online, this hash contains details about the online acceptance.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::MandateData::CustomerAcceptance::Online))
}
attr_accessor :online
# The type of customer acceptance information included with the Mandate. One of `online` or `offline`.
sig { returns(String) }
attr_accessor :type
sig {
params(accepted_at: T.nilable(Integer), offline: T.nilable(::Stripe::SetupIntentService::ConfirmParams::MandateData::CustomerAcceptance::Offline), online: T.nilable(::Stripe::SetupIntentService::ConfirmParams::MandateData::CustomerAcceptance::Online), type: String).void
}
def initialize(accepted_at: nil, offline: nil, online: nil, type: nil); end
end
# This hash contains details about the customer acceptance of the Mandate.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::MandateData::CustomerAcceptance))
}
attr_accessor :customer_acceptance
sig {
params(customer_acceptance: T.nilable(::Stripe::SetupIntentService::ConfirmParams::MandateData::CustomerAcceptance)).void
}
def initialize(customer_acceptance: nil); end
end
class PaymentMethodData < Stripe::RequestParams
class AcssDebit < Stripe::RequestParams
# Customer's bank account number.
sig { returns(String) }
attr_accessor :account_number
# Institution number of the customer's bank.
sig { returns(String) }
attr_accessor :institution_number
# Transit number of the customer's bank.
sig { returns(String) }
attr_accessor :transit_number
sig {
params(account_number: String, institution_number: String, transit_number: String).void
}
def initialize(account_number: nil, institution_number: nil, transit_number: nil); end
end
class Affirm < Stripe::RequestParams; end
class AfterpayClearpay < Stripe::RequestParams; end
class Alipay < Stripe::RequestParams; end
class Alma < Stripe::RequestParams; end
class AmazonPay < Stripe::RequestParams; end
class AuBecsDebit < Stripe::RequestParams
# The account number for the bank account.
sig { returns(String) }
attr_accessor :account_number
# Bank-State-Branch number of the bank account.
sig { returns(String) }
attr_accessor :bsb_number
sig { params(account_number: String, bsb_number: String).void }
def initialize(account_number: nil, bsb_number: nil); end
end
class BacsDebit < Stripe::RequestParams
# Account number of the bank account that the funds will be debited from.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Sort code of the bank account. (e.g., `10-20-30`)
sig { returns(T.nilable(String)) }
attr_accessor :sort_code
sig { params(account_number: T.nilable(String), sort_code: T.nilable(String)).void }
def initialize(account_number: nil, sort_code: nil); end
end
class Bancontact < Stripe::RequestParams; end
class Billie < Stripe::RequestParams; end
class BillingDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Billing address.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::BillingDetails::Address))))
}
attr_accessor :address
# Email address.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :email
# Full name.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :name
# Billing phone number (including extension).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :phone
# Taxpayer identification number. Used only for transactions between LATAM buyers and non-LATAM sellers.
sig { returns(T.nilable(String)) }
attr_accessor :tax_id
sig {
params(address: T.nilable(T.nilable(T.any(String, ::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::BillingDetails::Address))), email: T.nilable(T.nilable(String)), name: T.nilable(T.nilable(String)), phone: T.nilable(T.nilable(String)), tax_id: T.nilable(String)).void
}
def initialize(address: nil, email: nil, name: nil, phone: nil, tax_id: nil); end
end
class Blik < Stripe::RequestParams; end
class Boleto < Stripe::RequestParams
# The tax ID of the customer (CPF for individual consumers or CNPJ for businesses consumers)
sig { returns(String) }
attr_accessor :tax_id
sig { params(tax_id: String).void }
def initialize(tax_id: nil); end
end
class Cashapp < Stripe::RequestParams; end
class CustomerBalance < Stripe::RequestParams; end
class Eps < Stripe::RequestParams
# The customer's bank.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class Fpx < Stripe::RequestParams
# Account holder type for FPX transaction
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_type
# The customer's bank.
sig { returns(String) }
attr_accessor :bank
sig { params(account_holder_type: T.nilable(String), bank: String).void }
def initialize(account_holder_type: nil, bank: nil); end
end
class Giropay < Stripe::RequestParams; end
class Gopay < Stripe::RequestParams; end
class Grabpay < Stripe::RequestParams; end
class IdBankTransfer < Stripe::RequestParams
# Bank where the account is held.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class Ideal < Stripe::RequestParams
# The customer's bank. Only use this parameter for existing customers. Don't use it for new customers.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class InteracPresent < Stripe::RequestParams; end
class KakaoPay < Stripe::RequestParams; end
class Klarna < Stripe::RequestParams
class Dob < Stripe::RequestParams
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
# Customer's date of birth
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Klarna::Dob))
}
attr_accessor :dob
sig {
params(dob: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Klarna::Dob)).void
}
def initialize(dob: nil); end
end
class Konbini < Stripe::RequestParams; end
class KrCard < Stripe::RequestParams; end
class Link < Stripe::RequestParams; end
class MbWay < Stripe::RequestParams; end
class Mobilepay < Stripe::RequestParams; end
class Multibanco < Stripe::RequestParams; end
class NaverPay < Stripe::RequestParams
# Whether to use Naver Pay points or a card to fund this transaction. If not provided, this defaults to `card`.
sig { returns(T.nilable(String)) }
attr_accessor :funding
sig { params(funding: T.nilable(String)).void }
def initialize(funding: nil); end
end
class NzBankAccount < Stripe::RequestParams
# The name on the bank account. Only required if the account holder name is different from the name of the authorized signatory collected in the PaymentMethod’s billing details.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_name
# The account number for the bank account.
sig { returns(String) }
attr_accessor :account_number
# The numeric code for the bank account's bank.
sig { returns(String) }
attr_accessor :bank_code
# The numeric code for the bank account's bank branch.
sig { returns(String) }
attr_accessor :branch_code
# Attribute for param field reference
sig { returns(T.nilable(String)) }
attr_accessor :reference
# The suffix of the bank account number.
sig { returns(String) }
attr_accessor :suffix
sig {
params(account_holder_name: T.nilable(String), account_number: String, bank_code: String, branch_code: String, reference: T.nilable(String), suffix: String).void
}
def initialize(
account_holder_name: nil,
account_number: nil,
bank_code: nil,
branch_code: nil,
reference: nil,
suffix: nil
); end
end
class Oxxo < Stripe::RequestParams; end
class P24 < Stripe::RequestParams
# The customer's bank.
sig { returns(T.nilable(String)) }
attr_accessor :bank
sig { params(bank: T.nilable(String)).void }
def initialize(bank: nil); end
end
class PayByBank < Stripe::RequestParams; end
class Payco < Stripe::RequestParams; end
class Paynow < Stripe::RequestParams; end
class Paypal < Stripe::RequestParams; end
class Payto < Stripe::RequestParams
# The account number for the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Bank-State-Branch number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :bsb_number
# The PayID alias for the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :pay_id
sig {
params(account_number: T.nilable(String), bsb_number: T.nilable(String), pay_id: T.nilable(String)).void
}
def initialize(account_number: nil, bsb_number: nil, pay_id: nil); end
end
class Pix < Stripe::RequestParams; end
class Promptpay < Stripe::RequestParams; end
class Qris < Stripe::RequestParams; end
class RadarOptions < Stripe::RequestParams
# A [Radar Session](https://stripe.com/docs/radar/radar-session) is a snapshot of the browser metadata and device details that help Radar make more accurate predictions on your payments.
sig { returns(T.nilable(String)) }
attr_accessor :session
sig { params(session: T.nilable(String)).void }
def initialize(session: nil); end
end
class Rechnung < Stripe::RequestParams
class Dob < Stripe::RequestParams
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
# Customer's date of birth
sig {
returns(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Rechnung::Dob)
}
attr_accessor :dob
sig {
params(dob: ::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Rechnung::Dob).void
}
def initialize(dob: nil); end
end
class RevolutPay < Stripe::RequestParams; end
class SamsungPay < Stripe::RequestParams; end
class Satispay < Stripe::RequestParams; end
class SepaDebit < Stripe::RequestParams
# IBAN of the bank account.
sig { returns(String) }
attr_accessor :iban
sig { params(iban: String).void }
def initialize(iban: nil); end
end
class Shopeepay < Stripe::RequestParams; end
class Sofort < Stripe::RequestParams
# Two-letter ISO code representing the country the bank account is located in.
sig { returns(String) }
attr_accessor :country
sig { params(country: String).void }
def initialize(country: nil); end
end
class StripeBalance < Stripe::RequestParams
# The connected account ID whose Stripe balance to use as the source of payment
sig { returns(T.nilable(String)) }
attr_accessor :account
# The [source_type](https://docs.stripe.com/api/balance/balance_object#balance_object-available-source_types) of the balance
sig { returns(T.nilable(String)) }
attr_accessor :source_type
sig { params(account: T.nilable(String), source_type: T.nilable(String)).void }
def initialize(account: nil, source_type: nil); end
end
class Swish < Stripe::RequestParams; end
class Twint < Stripe::RequestParams; end
class UsBankAccount < Stripe::RequestParams
# Account holder type: individual or company.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_type
# Account number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Account type: checkings or savings. Defaults to checking if omitted.
sig { returns(T.nilable(String)) }
attr_accessor :account_type
# The ID of a Financial Connections Account to use as a payment method.
sig { returns(T.nilable(String)) }
attr_accessor :financial_connections_account
# Routing number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :routing_number
sig {
params(account_holder_type: T.nilable(String), account_number: T.nilable(String), account_type: T.nilable(String), financial_connections_account: T.nilable(String), routing_number: T.nilable(String)).void
}
def initialize(
account_holder_type: nil,
account_number: nil,
account_type: nil,
financial_connections_account: nil,
routing_number: nil
); end
end
class WechatPay < Stripe::RequestParams; end
class Zip < Stripe::RequestParams; end
# If this is an `acss_debit` PaymentMethod, this hash contains details about the ACSS Debit payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::AcssDebit))
}
attr_accessor :acss_debit
# If this is an `affirm` PaymentMethod, this hash contains details about the Affirm payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Affirm))
}
attr_accessor :affirm
# If this is an `AfterpayClearpay` PaymentMethod, this hash contains details about the AfterpayClearpay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::AfterpayClearpay))
}
attr_accessor :afterpay_clearpay
# If this is an `Alipay` PaymentMethod, this hash contains details about the Alipay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Alipay))
}
attr_accessor :alipay
# This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow. The field defaults to `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :allow_redisplay
# If this is a Alma PaymentMethod, this hash contains details about the Alma payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Alma))
}
attr_accessor :alma
# If this is a AmazonPay PaymentMethod, this hash contains details about the AmazonPay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::AmazonPay))
}
attr_accessor :amazon_pay
# If this is an `au_becs_debit` PaymentMethod, this hash contains details about the bank account.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::AuBecsDebit))
}
attr_accessor :au_becs_debit
# If this is a `bacs_debit` PaymentMethod, this hash contains details about the Bacs Direct Debit bank account.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::BacsDebit))
}
attr_accessor :bacs_debit
# If this is a `bancontact` PaymentMethod, this hash contains details about the Bancontact payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Bancontact))
}
attr_accessor :bancontact
# If this is a `billie` PaymentMethod, this hash contains details about the Billie payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Billie))
}
attr_accessor :billie
# Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::BillingDetails))
}
attr_accessor :billing_details
# If this is a `blik` PaymentMethod, this hash contains details about the BLIK payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Blik))
}
attr_accessor :blik
# If this is a `boleto` PaymentMethod, this hash contains details about the Boleto payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Boleto))
}
attr_accessor :boleto
# If this is a `cashapp` PaymentMethod, this hash contains details about the Cash App Pay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Cashapp))
}
attr_accessor :cashapp
# If this is a `customer_balance` PaymentMethod, this hash contains details about the CustomerBalance payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::CustomerBalance))
}
attr_accessor :customer_balance
# If this is an `eps` PaymentMethod, this hash contains details about the EPS payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Eps))
}
attr_accessor :eps
# If this is an `fpx` PaymentMethod, this hash contains details about the FPX payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Fpx))
}
attr_accessor :fpx
# If this is a `giropay` PaymentMethod, this hash contains details about the Giropay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Giropay))
}
attr_accessor :giropay
# If this is a Gopay PaymentMethod, this hash contains details about the Gopay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Gopay))
}
attr_accessor :gopay
# If this is a `grabpay` PaymentMethod, this hash contains details about the GrabPay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Grabpay))
}
attr_accessor :grabpay
# If this is an `IdBankTransfer` PaymentMethod, this hash contains details about the IdBankTransfer payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::IdBankTransfer))
}
attr_accessor :id_bank_transfer
# If this is an `ideal` PaymentMethod, this hash contains details about the iDEAL payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Ideal))
}
attr_accessor :ideal
# If this is an `interac_present` PaymentMethod, this hash contains details about the Interac Present payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::InteracPresent))
}
attr_accessor :interac_present
# If this is a `kakao_pay` PaymentMethod, this hash contains details about the Kakao Pay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::KakaoPay))
}
attr_accessor :kakao_pay
# If this is a `klarna` PaymentMethod, this hash contains details about the Klarna payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Klarna))
}
attr_accessor :klarna
# If this is a `konbini` PaymentMethod, this hash contains details about the Konbini payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Konbini))
}
attr_accessor :konbini
# If this is a `kr_card` PaymentMethod, this hash contains details about the Korean Card payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::KrCard))
}
attr_accessor :kr_card
# If this is an `Link` PaymentMethod, this hash contains details about the Link payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Link))
}
attr_accessor :link
# If this is a MB WAY PaymentMethod, this hash contains details about the MB WAY payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::MbWay))
}
attr_accessor :mb_way
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# If this is a `mobilepay` PaymentMethod, this hash contains details about the MobilePay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Mobilepay))
}
attr_accessor :mobilepay
# If this is a `multibanco` PaymentMethod, this hash contains details about the Multibanco payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Multibanco))
}
attr_accessor :multibanco
# If this is a `naver_pay` PaymentMethod, this hash contains details about the Naver Pay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::NaverPay))
}
attr_accessor :naver_pay
# If this is an nz_bank_account PaymentMethod, this hash contains details about the nz_bank_account payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::NzBankAccount))
}
attr_accessor :nz_bank_account
# If this is an `oxxo` PaymentMethod, this hash contains details about the OXXO payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Oxxo))
}
attr_accessor :oxxo
# If this is a `p24` PaymentMethod, this hash contains details about the P24 payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::P24))
}
attr_accessor :p24
# If this is a `pay_by_bank` PaymentMethod, this hash contains details about the PayByBank payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::PayByBank))
}
attr_accessor :pay_by_bank
# If this is a `payco` PaymentMethod, this hash contains details about the PAYCO payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Payco))
}
attr_accessor :payco
# If this is a `paynow` PaymentMethod, this hash contains details about the PayNow payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Paynow))
}
attr_accessor :paynow
# If this is a `paypal` PaymentMethod, this hash contains details about the PayPal payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Paypal))
}
attr_accessor :paypal
# If this is a `payto` PaymentMethod, this hash contains details about the PayTo payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Payto))
}
attr_accessor :payto
# If this is a `pix` PaymentMethod, this hash contains details about the Pix payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Pix))
}
attr_accessor :pix
# If this is a `promptpay` PaymentMethod, this hash contains details about the PromptPay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Promptpay))
}
attr_accessor :promptpay
# If this is a `qris` PaymentMethod, this hash contains details about the QRIS payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Qris))
}
attr_accessor :qris
# Options to configure Radar. See [Radar Session](https://stripe.com/docs/radar/radar-session) for more information.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::RadarOptions))
}
attr_accessor :radar_options
# If this is a `rechnung` PaymentMethod, this hash contains details about the Rechnung payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Rechnung))
}
attr_accessor :rechnung
# If this is a `revolut_pay` PaymentMethod, this hash contains details about the Revolut Pay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::RevolutPay))
}
attr_accessor :revolut_pay
# If this is a `samsung_pay` PaymentMethod, this hash contains details about the SamsungPay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::SamsungPay))
}
attr_accessor :samsung_pay
# If this is a `satispay` PaymentMethod, this hash contains details about the Satispay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Satispay))
}
attr_accessor :satispay
# If this is a `sepa_debit` PaymentMethod, this hash contains details about the SEPA debit bank account.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::SepaDebit))
}
attr_accessor :sepa_debit
# If this is a Shopeepay PaymentMethod, this hash contains details about the Shopeepay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Shopeepay))
}
attr_accessor :shopeepay
# If this is a `sofort` PaymentMethod, this hash contains details about the SOFORT payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Sofort))
}
attr_accessor :sofort
# This hash contains details about the Stripe balance payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::StripeBalance))
}
attr_accessor :stripe_balance
# If this is a `swish` PaymentMethod, this hash contains details about the Swish payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Swish))
}
attr_accessor :swish
# If this is a TWINT PaymentMethod, this hash contains details about the TWINT payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Twint))
}
attr_accessor :twint
# The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
sig { returns(String) }
attr_accessor :type
# If this is an `us_bank_account` PaymentMethod, this hash contains details about the US bank account payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::UsBankAccount))
}
attr_accessor :us_bank_account
# If this is an `wechat_pay` PaymentMethod, this hash contains details about the wechat_pay payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::WechatPay))
}
attr_accessor :wechat_pay
# If this is a `zip` PaymentMethod, this hash contains details about the Zip payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Zip))
}
attr_accessor :zip
sig {
params(acss_debit: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::AcssDebit), affirm: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Affirm), afterpay_clearpay: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::AfterpayClearpay), alipay: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Alipay), allow_redisplay: T.nilable(String), alma: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Alma), amazon_pay: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::AmazonPay), au_becs_debit: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::AuBecsDebit), bacs_debit: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::BacsDebit), bancontact: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Bancontact), billie: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Billie), billing_details: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::BillingDetails), blik: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Blik), boleto: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Boleto), cashapp: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Cashapp), customer_balance: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::CustomerBalance), eps: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Eps), fpx: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Fpx), giropay: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Giropay), gopay: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Gopay), grabpay: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Grabpay), id_bank_transfer: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::IdBankTransfer), ideal: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Ideal), interac_present: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::InteracPresent), kakao_pay: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::KakaoPay), klarna: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Klarna), konbini: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Konbini), kr_card: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::KrCard), link: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Link), mb_way: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::MbWay), metadata: T.nilable(T::Hash[String, String]), mobilepay: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Mobilepay), multibanco: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Multibanco), naver_pay: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::NaverPay), nz_bank_account: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::NzBankAccount), oxxo: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Oxxo), p24: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::P24), pay_by_bank: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::PayByBank), payco: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Payco), paynow: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Paynow), paypal: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Paypal), payto: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Payto), pix: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Pix), promptpay: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Promptpay), qris: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Qris), radar_options: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::RadarOptions), rechnung: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Rechnung), revolut_pay: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::RevolutPay), samsung_pay: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::SamsungPay), satispay: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Satispay), sepa_debit: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::SepaDebit), shopeepay: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Shopeepay), sofort: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Sofort), stripe_balance: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::StripeBalance), swish: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Swish), twint: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Twint), type: String, us_bank_account: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::UsBankAccount), wechat_pay: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::WechatPay), zip: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData::Zip)).void
}
def initialize(
acss_debit: nil,
affirm: nil,
afterpay_clearpay: nil,
alipay: nil,
allow_redisplay: nil,
alma: nil,
amazon_pay: nil,
au_becs_debit: nil,
bacs_debit: nil,
bancontact: nil,
billie: nil,
billing_details: nil,
blik: nil,
boleto: nil,
cashapp: nil,
customer_balance: nil,
eps: nil,
fpx: nil,
giropay: nil,
gopay: nil,
grabpay: nil,
id_bank_transfer: nil,
ideal: nil,
interac_present: nil,
kakao_pay: nil,
klarna: nil,
konbini: nil,
kr_card: nil,
link: nil,
mb_way: nil,
metadata: nil,
mobilepay: nil,
multibanco: nil,
naver_pay: nil,
nz_bank_account: nil,
oxxo: nil,
p24: nil,
pay_by_bank: nil,
payco: nil,
paynow: nil,
paypal: nil,
payto: nil,
pix: nil,
promptpay: nil,
qris: nil,
radar_options: nil,
rechnung: nil,
revolut_pay: nil,
samsung_pay: nil,
satispay: nil,
sepa_debit: nil,
shopeepay: nil,
sofort: nil,
stripe_balance: nil,
swish: nil,
twint: nil,
type: nil,
us_bank_account: nil,
wechat_pay: nil,
zip: nil
); end
end
class PaymentMethodOptions < Stripe::RequestParams
class AcssDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# A URL for custom mandate text to render during confirmation step.
# The URL will be rendered with additional GET parameters `payment_intent` and `payment_intent_client_secret` when confirming a Payment Intent,
# or `setup_intent` and `setup_intent_client_secret` when confirming a Setup Intent.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :custom_mandate_url
# List of Stripe products where this mandate can be selected automatically.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :default_for
# Description of the mandate interval. Only required if 'payment_schedule' parameter is 'interval' or 'combined'.
sig { returns(T.nilable(String)) }
attr_accessor :interval_description
# Payment schedule for the mandate.
sig { returns(T.nilable(String)) }
attr_accessor :payment_schedule
# Transaction type of the mandate.
sig { returns(T.nilable(String)) }
attr_accessor :transaction_type
sig {
params(custom_mandate_url: T.nilable(T.nilable(String)), default_for: T.nilable(T::Array[String]), interval_description: T.nilable(String), payment_schedule: T.nilable(String), transaction_type: T.nilable(String)).void
}
def initialize(
custom_mandate_url: nil,
default_for: nil,
interval_description: nil,
payment_schedule: nil,
transaction_type: nil
); end
end
# 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).
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions::AcssDebit::MandateOptions))
}
attr_accessor :mandate_options
# Bank account verification method.
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(currency: T.nilable(String), mandate_options: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions::AcssDebit::MandateOptions), verification_method: T.nilable(String)).void
}
def initialize(currency: nil, mandate_options: nil, verification_method: nil); end
end
class AmazonPay < Stripe::RequestParams; end
class BacsDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'DDIC' or 'STRIPE'.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :reference_prefix
sig { params(reference_prefix: T.nilable(T.nilable(String))).void }
def initialize(reference_prefix: nil); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions::BacsDebit::MandateOptions))
}
attr_accessor :mandate_options
sig {
params(mandate_options: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions::BacsDebit::MandateOptions)).void
}
def initialize(mandate_options: nil); end
end
class Card < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Amount to be charged for future payments.
sig { returns(Integer) }
attr_accessor :amount
# One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.
sig { returns(String) }
attr_accessor :amount_type
# Currency in which future payments will be charged. 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).
sig { returns(String) }
attr_accessor :currency
# A description of the mandate or subscription that is meant to be displayed to the customer.
sig { returns(T.nilable(String)) }
attr_accessor :description
# End date of the mandate or subscription. If not provided, the mandate will be active until canceled. If provided, end date should be after start date.
sig { returns(T.nilable(Integer)) }
attr_accessor :end_date
# Specifies payment frequency. One of `day`, `week`, `month`, `year`, or `sporadic`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals between payments. For example, `interval=month` and `interval_count=3` indicates one payment every three months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks). This parameter is optional when `interval=sporadic`.
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_count
# Unique identifier for the mandate or subscription.
sig { returns(String) }
attr_accessor :reference
# Start date of the mandate or subscription. Start date should not be lesser than yesterday.
sig { returns(Integer) }
attr_accessor :start_date
# Specifies the type of mandates supported. Possible values are `india`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :supported_types
sig {
params(amount: Integer, amount_type: String, currency: String, description: T.nilable(String), end_date: T.nilable(Integer), interval: String, interval_count: T.nilable(Integer), reference: String, start_date: Integer, supported_types: T.nilable(T::Array[String])).void
}
def initialize(
amount: nil,
amount_type: nil,
currency: nil,
description: nil,
end_date: nil,
interval: nil,
interval_count: nil,
reference: nil,
start_date: nil,
supported_types: nil
); end
end
class ThreeDSecure < Stripe::RequestParams
class NetworkOptions < Stripe::RequestParams
class CartesBancaires < Stripe::RequestParams
# The cryptogram calculation algorithm used by the card Issuer's ACS
# to calculate the Authentication cryptogram. Also known as `cavvAlgorithm`.
# messageExtension: CB-AVALGO
sig { returns(String) }
attr_accessor :cb_avalgo
# The exemption indicator returned from Cartes Bancaires in the ARes.
# message extension: CB-EXEMPTION; string (4 characters)
# This is a 3 byte bitmap (low significant byte first and most significant
# bit first) that has been Base64 encoded
sig { returns(T.nilable(String)) }
attr_accessor :cb_exemption
# The risk score returned from Cartes Bancaires in the ARes.
# message extension: CB-SCORE; numeric value 0-99
sig { returns(T.nilable(Integer)) }
attr_accessor :cb_score
sig {
params(cb_avalgo: String, cb_exemption: T.nilable(String), cb_score: T.nilable(Integer)).void
}
def initialize(cb_avalgo: nil, cb_exemption: nil, cb_score: nil); end
end
# Cartes Bancaires-specific 3DS fields.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions::CartesBancaires))
}
attr_accessor :cartes_bancaires
sig {
params(cartes_bancaires: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions::CartesBancaires)).void
}
def initialize(cartes_bancaires: nil); end
end
# The `transStatus` returned from the card Issuer’s ACS in the ARes.
sig { returns(T.nilable(String)) }
attr_accessor :ares_trans_status
# The cryptogram, also known as the "authentication value" (AAV, CAVV or
# AEVV). This value is 20 bytes, base64-encoded into a 28-character string.
# (Most 3D Secure providers will return the base64-encoded version, which
# is what you should specify here.)
sig { returns(T.nilable(String)) }
attr_accessor :cryptogram
# The Electronic Commerce Indicator (ECI) is returned by your 3D Secure
# provider and indicates what degree of authentication was performed.
sig { returns(T.nilable(String)) }
attr_accessor :electronic_commerce_indicator
# Network specific 3DS fields. Network specific arguments require an
# explicit card brand choice. The parameter `payment_method_options.card.network``
# must be populated accordingly
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions))
}
attr_accessor :network_options
# The challenge indicator (`threeDSRequestorChallengeInd`) which was requested in the
# AReq sent to the card Issuer's ACS. A string containing 2 digits from 01-99.
sig { returns(T.nilable(String)) }
attr_accessor :requestor_challenge_indicator
# For 3D Secure 1, the XID. For 3D Secure 2, the Directory Server
# Transaction ID (dsTransID).
sig { returns(T.nilable(String)) }
attr_accessor :transaction_id
# The version of 3D Secure that was performed.
sig { returns(T.nilable(String)) }
attr_accessor :version
sig {
params(ares_trans_status: T.nilable(String), cryptogram: T.nilable(String), electronic_commerce_indicator: T.nilable(String), network_options: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions::Card::ThreeDSecure::NetworkOptions), requestor_challenge_indicator: T.nilable(String), transaction_id: T.nilable(String), version: T.nilable(String)).void
}
def initialize(
ares_trans_status: nil,
cryptogram: nil,
electronic_commerce_indicator: nil,
network_options: nil,
requestor_challenge_indicator: nil,
transaction_id: nil,
version: nil
); end
end
# Configuration options for setting up an eMandate for cards issued in India.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions::Card::MandateOptions))
}
attr_accessor :mandate_options
# When specified, this parameter signals that a card has been collected
# as MOTO (Mail Order Telephone Order) and thus out of scope for SCA. This
# parameter can only be provided during confirmation.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :moto
# Selected network to process this SetupIntent on. Depends on the available networks of the card attached to the SetupIntent. Can be only set confirm-time.
sig { returns(T.nilable(String)) }
attr_accessor :network
# We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. If not provided, this value defaults to `automatic`. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
sig { returns(T.nilable(String)) }
attr_accessor :request_three_d_secure
# If 3D Secure authentication was performed with a third-party provider,
# the authentication details to use for this setup.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions::Card::ThreeDSecure))
}
attr_accessor :three_d_secure
sig {
params(mandate_options: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions::Card::MandateOptions), moto: T.nilable(T::Boolean), network: T.nilable(String), request_three_d_secure: T.nilable(String), three_d_secure: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions::Card::ThreeDSecure)).void
}
def initialize(
mandate_options: nil,
moto: nil,
network: nil,
request_three_d_secure: nil,
three_d_secure: nil
); end
end
class CardPresent < Stripe::RequestParams; end
class Link < Stripe::RequestParams
# [Deprecated] This is a legacy parameter that no longer has any function.
sig { returns(T.nilable(String)) }
attr_accessor :persistent_token
sig { params(persistent_token: T.nilable(String)).void }
def initialize(persistent_token: nil); end
end
class Paypal < Stripe::RequestParams
# The PayPal Billing Agreement ID (BAID). This is an ID generated by PayPal which represents the mandate between the merchant and the customer.
sig { returns(T.nilable(String)) }
attr_accessor :billing_agreement_id
# Attribute for param field currency
sig { returns(T.nilable(String)) }
attr_accessor :currency
# The Stripe connected account IDs of the sellers on the platform for this transaction (optional). Only allowed when [separate charges and transfers](https://stripe.com/docs/connect/separate-charges-and-transfers) are used.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :subsellers
sig {
params(billing_agreement_id: T.nilable(String), currency: T.nilable(String), subsellers: T.nilable(T::Array[String])).void
}
def initialize(billing_agreement_id: nil, currency: nil, subsellers: nil); end
end
class Payto < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Amount that will be collected. It is required when `amount_type` is `fixed`.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# The type of amount that will be collected. The amount charged must be exact or up to the value of `amount` param for `fixed` or `maximum` type respectively.
sig { returns(T.nilable(String)) }
attr_accessor :amount_type
# Date, in YYYY-MM-DD format, after which payments will not be collected. Defaults to no end date.
sig { returns(T.nilable(String)) }
attr_accessor :end_date
# The periodicity at which payments will be collected.
sig { returns(T.nilable(String)) }
attr_accessor :payment_schedule
# The number of payments that will be made during a payment period. Defaults to 1 except for when `payment_schedule` is `adhoc`. In that case, it defaults to no limit.
sig { returns(T.nilable(Integer)) }
attr_accessor :payments_per_period
# The purpose for which payments are made. Defaults to retail.
sig { returns(T.nilable(String)) }
attr_accessor :purpose
# Date, in YYYY-MM-DD format, from which payments will be collected. Defaults to confirmation time.
sig { returns(T.nilable(String)) }
attr_accessor :start_date
sig {
params(amount: T.nilable(Integer), amount_type: T.nilable(String), end_date: T.nilable(String), payment_schedule: T.nilable(String), payments_per_period: T.nilable(Integer), purpose: T.nilable(String), start_date: T.nilable(String)).void
}
def initialize(
amount: nil,
amount_type: nil,
end_date: nil,
payment_schedule: nil,
payments_per_period: nil,
purpose: nil,
start_date: nil
); end
end
# Additional fields for Mandate creation.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions::Payto::MandateOptions))
}
attr_accessor :mandate_options
sig {
params(mandate_options: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions::Payto::MandateOptions)).void
}
def initialize(mandate_options: nil); end
end
class SepaDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Prefix used to generate the Mandate reference. Must be at most 12 characters long. Must consist of only uppercase letters, numbers, spaces, or the following special characters: '/', '_', '-', '&', '.'. Cannot begin with 'STRIPE'.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :reference_prefix
sig { params(reference_prefix: T.nilable(T.nilable(String))).void }
def initialize(reference_prefix: nil); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions::SepaDebit::MandateOptions))
}
attr_accessor :mandate_options
sig {
params(mandate_options: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions::SepaDebit::MandateOptions)).void
}
def initialize(mandate_options: nil); end
end
class UsBankAccount < Stripe::RequestParams
class FinancialConnections < Stripe::RequestParams
class Filters < Stripe::RequestParams
# The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :account_subcategories
# ID of the institution to use to filter for selectable accounts.
sig { returns(T.nilable(String)) }
attr_accessor :institution
sig {
params(account_subcategories: T.nilable(T::Array[String]), institution: T.nilable(String)).void
}
def initialize(account_subcategories: nil, institution: nil); end
end
class ManualEntry < Stripe::RequestParams
# Settings for configuring manual entry of account details.
sig { returns(String) }
attr_accessor :mode
sig { params(mode: String).void }
def initialize(mode: nil); end
end
# Provide filters for the linked accounts that the customer can select for the payment method.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::Filters))
}
attr_accessor :filters
# Customize manual entry behavior
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::ManualEntry))
}
attr_accessor :manual_entry
# The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :permissions
# List of data features that you would like to retrieve upon account creation.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :prefetch
# For webview integrations only. Upon completing OAuth login in the native browser, the user will be redirected to this URL to return to your app.
sig { returns(T.nilable(String)) }
attr_accessor :return_url
sig {
params(filters: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::Filters), manual_entry: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions::UsBankAccount::FinancialConnections::ManualEntry), permissions: T.nilable(T::Array[String]), prefetch: T.nilable(T::Array[String]), return_url: T.nilable(String)).void
}
def initialize(
filters: nil,
manual_entry: nil,
permissions: nil,
prefetch: nil,
return_url: nil
); end
end
class MandateOptions < Stripe::RequestParams
# The method used to collect offline mandate customer acceptance.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :collection_method
sig { params(collection_method: T.nilable(T.nilable(String))).void }
def initialize(collection_method: nil); end
end
class Networks < Stripe::RequestParams
# Triggers validations to run across the selected networks
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Array[String])).void }
def initialize(requested: nil); end
end
# Additional fields for Financial Connections Session creation
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions::UsBankAccount::FinancialConnections))
}
attr_accessor :financial_connections
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions::UsBankAccount::MandateOptions))
}
attr_accessor :mandate_options
# Additional fields for network related functions
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions::UsBankAccount::Networks))
}
attr_accessor :networks
# Bank account verification method.
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(financial_connections: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions::UsBankAccount::FinancialConnections), mandate_options: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions::UsBankAccount::MandateOptions), networks: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions::UsBankAccount::Networks), verification_method: T.nilable(String)).void
}
def initialize(
financial_connections: nil,
mandate_options: nil,
networks: nil,
verification_method: nil
); end
end
# If this is a `acss_debit` SetupIntent, this sub-hash contains details about the ACSS Debit payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions::AcssDebit))
}
attr_accessor :acss_debit
# If this is a `amazon_pay` SetupIntent, this sub-hash contains details about the AmazonPay payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions::AmazonPay))
}
attr_accessor :amazon_pay
# If this is a `bacs_debit` SetupIntent, this sub-hash contains details about the Bacs Debit payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions::BacsDebit))
}
attr_accessor :bacs_debit
# Configuration for any card setup attempted on this SetupIntent.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions::Card))
}
attr_accessor :card
# If this is a `card_present` PaymentMethod, this sub-hash contains details about the card-present payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions::CardPresent))
}
attr_accessor :card_present
# If this is a `link` PaymentMethod, this sub-hash contains details about the Link payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions::Link))
}
attr_accessor :link
# If this is a `paypal` PaymentMethod, this sub-hash contains details about the PayPal payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions::Paypal))
}
attr_accessor :paypal
# If this is a `payto` SetupIntent, this sub-hash contains details about the PayTo payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions::Payto))
}
attr_accessor :payto
# If this is a `sepa_debit` SetupIntent, this sub-hash contains details about the SEPA Debit payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions::SepaDebit))
}
attr_accessor :sepa_debit
# If this is a `us_bank_account` SetupIntent, this sub-hash contains details about the US bank account payment method options.
sig {
returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions::UsBankAccount))
}
attr_accessor :us_bank_account
sig {
params(acss_debit: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions::AcssDebit), amazon_pay: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions::AmazonPay), bacs_debit: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions::BacsDebit), card: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions::Card), card_present: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions::CardPresent), link: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions::Link), paypal: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions::Paypal), payto: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions::Payto), sepa_debit: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions::SepaDebit), us_bank_account: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions::UsBankAccount)).void
}
def initialize(
acss_debit: nil,
amazon_pay: nil,
bacs_debit: nil,
card: nil,
card_present: nil,
link: nil,
paypal: nil,
payto: nil,
sepa_debit: nil,
us_bank_account: nil
); end
end
# ID of the ConfirmationToken used to confirm this SetupIntent.
#
# If the provided ConfirmationToken contains properties that are also being provided in this request, such as `payment_method`, then the values in this request will take precedence.
sig { returns(T.nilable(String)) }
attr_accessor :confirmation_token
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Attribute for param field mandate_data
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SetupIntentService::ConfirmParams::MandateData))))
}
attr_accessor :mandate_data
# ID of the payment method (a PaymentMethod, Card, or saved Source object) to attach to this SetupIntent.
sig { returns(T.nilable(String)) }
attr_accessor :payment_method
# When included, this hash creates a PaymentMethod that is set as the [`payment_method`](https://stripe.com/docs/api/setup_intents/object#setup_intent_object-payment_method)
# value in the SetupIntent.
sig { returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData)) }
attr_accessor :payment_method_data
# Payment method-specific configuration for this SetupIntent.
sig { returns(T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions)) }
attr_accessor :payment_method_options
# The URL to redirect your customer back to after they authenticate on the payment method's app or site.
# If you'd prefer to redirect to a mobile application, you can alternatively supply an application URI scheme.
# This parameter is only used for cards and other redirect-based payment methods.
sig { returns(T.nilable(String)) }
attr_accessor :return_url
# Set to `true` when confirming server-side and using Stripe.js, iOS, or Android client-side SDKs to handle the next actions.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :use_stripe_sdk
sig {
params(confirmation_token: T.nilable(String), expand: T.nilable(T::Array[String]), mandate_data: T.nilable(T.nilable(T.any(String, ::Stripe::SetupIntentService::ConfirmParams::MandateData))), payment_method: T.nilable(String), payment_method_data: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodData), payment_method_options: T.nilable(::Stripe::SetupIntentService::ConfirmParams::PaymentMethodOptions), return_url: T.nilable(String), use_stripe_sdk: T.nilable(T::Boolean)).void
}
def initialize(
confirmation_token: nil,
expand: nil,
mandate_data: nil,
payment_method: nil,
payment_method_data: nil,
payment_method_options: nil,
return_url: nil,
use_stripe_sdk: nil
); end
end
class VerifyMicrodepositsParams < Stripe::RequestParams
# Two positive integers, in *cents*, equal to the values of the microdeposits sent to the bank account.
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :amounts
# A six-character code starting with SM present in the microdeposit sent to the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :descriptor_code
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig {
params(amounts: T.nilable(T::Array[Integer]), descriptor_code: T.nilable(String), expand: T.nilable(T::Array[String])).void
}
def initialize(amounts: nil, descriptor_code: nil, expand: nil); end
end
# You can cancel a SetupIntent object when it's in one of these statuses: requires_payment_method, requires_confirmation, or requires_action.
#
# After you cancel it, setup is abandoned and any operations on the SetupIntent fail with an error. You can't cancel the SetupIntent for a Checkout Session. [Expire the Checkout Session](https://docs.stripe.com/docs/api/checkout/sessions/expire) instead.
sig {
params(intent: String, params: T.any(::Stripe::SetupIntentService::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SetupIntent)
}
def cancel(intent, params = {}, opts = {}); end
# Confirm that your customer intends to set up the current or
# provided payment method. For example, you would confirm a SetupIntent
# when a customer hits the “Save” button on a payment method management
# page on your website.
#
# If the selected payment method does not require any additional
# steps from the customer, the SetupIntent will transition to the
# succeeded status.
#
# Otherwise, it will transition to the requires_action status and
# suggest additional actions via next_action. If setup fails,
# the SetupIntent will transition to the
# requires_payment_method status or the canceled status if the
# confirmation limit is reached.
sig {
params(intent: String, params: T.any(::Stripe::SetupIntentService::ConfirmParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SetupIntent)
}
def confirm(intent, params = {}, opts = {}); end
# Creates a SetupIntent object.
#
# After you create the SetupIntent, attach a payment method and [confirm](https://docs.stripe.com/docs/api/setup_intents/confirm)
# it to collect any required permissions to charge the payment method later.
sig {
params(params: T.any(::Stripe::SetupIntentService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SetupIntent)
}
def create(params = {}, opts = {}); end
# Returns a list of SetupIntents.
sig {
params(params: T.any(::Stripe::SetupIntentService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the details of a SetupIntent that has previously been created.
#
# Client-side retrieval using a publishable key is allowed when the client_secret is provided in the query string.
#
# When retrieved with a publishable key, only a subset of properties will be returned. Please refer to the [SetupIntent](https://docs.stripe.com/api#setup_intent_object) object reference for more details.
sig {
params(intent: String, params: T.any(::Stripe::SetupIntentService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SetupIntent)
}
def retrieve(intent, params = {}, opts = {}); end
# Updates a SetupIntent object.
sig {
params(intent: String, params: T.any(::Stripe::SetupIntentService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SetupIntent)
}
def update(intent, params = {}, opts = {}); end
# Verifies microdeposits on a SetupIntent object.
sig {
params(intent: String, params: T.any(::Stripe::SetupIntentService::VerifyMicrodepositsParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SetupIntent)
}
def verify_microdeposits(intent, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class ShippingRateService < StripeService
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return shipping rates that are active or inactive.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.
sig { returns(T.nilable(T.any(::Stripe::ShippingRateService::ListParams::Created, Integer))) }
attr_accessor :created
# Only return shipping rates for the given currency.
sig { returns(T.nilable(String)) }
attr_accessor :currency
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(active: T.nilable(T::Boolean), created: T.nilable(T.any(::Stripe::ShippingRateService::ListParams::Created, Integer)), currency: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
active: nil,
created: nil,
currency: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class DeliveryEstimate < Stripe::RequestParams
class Maximum < Stripe::RequestParams
# A unit of time.
sig { returns(String) }
attr_accessor :unit
# Must be greater than 0.
sig { returns(Integer) }
attr_accessor :value
sig { params(unit: String, value: Integer).void }
def initialize(unit: nil, value: nil); end
end
class Minimum < Stripe::RequestParams
# A unit of time.
sig { returns(String) }
attr_accessor :unit
# Must be greater than 0.
sig { returns(Integer) }
attr_accessor :value
sig { params(unit: String, value: Integer).void }
def initialize(unit: nil, value: nil); end
end
# The upper bound of the estimated range. If empty, represents no upper bound i.e., infinite.
sig {
returns(T.nilable(::Stripe::ShippingRateService::CreateParams::DeliveryEstimate::Maximum))
}
attr_accessor :maximum
# The lower bound of the estimated range. If empty, represents no lower bound.
sig {
returns(T.nilable(::Stripe::ShippingRateService::CreateParams::DeliveryEstimate::Minimum))
}
attr_accessor :minimum
sig {
params(maximum: T.nilable(::Stripe::ShippingRateService::CreateParams::DeliveryEstimate::Maximum), minimum: T.nilable(::Stripe::ShippingRateService::CreateParams::DeliveryEstimate::Minimum)).void
}
def initialize(maximum: nil, minimum: nil); end
end
class FixedAmount < Stripe::RequestParams
class CurrencyOptions < Stripe::RequestParams
# A non-negative integer in cents representing how much to charge.
sig { returns(Integer) }
attr_accessor :amount
# Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
sig { params(amount: Integer, tax_behavior: T.nilable(String)).void }
def initialize(amount: nil, tax_behavior: nil); end
end
# A non-negative integer in cents representing how much to charge.
sig { returns(Integer) }
attr_accessor :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).
sig { returns(String) }
attr_accessor :currency
# Shipping rates defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
sig {
returns(T.nilable(T::Hash[String, ::Stripe::ShippingRateService::CreateParams::FixedAmount::CurrencyOptions]))
}
attr_accessor :currency_options
sig {
params(amount: Integer, currency: String, currency_options: T.nilable(T::Hash[String, ::Stripe::ShippingRateService::CreateParams::FixedAmount::CurrencyOptions])).void
}
def initialize(amount: nil, currency: nil, currency_options: nil); end
end
# The estimated range for how long shipping will take, meant to be displayable to the customer. This will appear on CheckoutSessions.
sig { returns(T.nilable(::Stripe::ShippingRateService::CreateParams::DeliveryEstimate)) }
attr_accessor :delivery_estimate
# The name of the shipping rate, meant to be displayable to the customer. This will appear on CheckoutSessions.
sig { returns(String) }
attr_accessor :display_name
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Describes a fixed amount to charge for shipping. Must be present if type is `fixed_amount`.
sig { returns(T.nilable(::Stripe::ShippingRateService::CreateParams::FixedAmount)) }
attr_accessor :fixed_amount
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID. The Shipping tax code is `txcd_92010001`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_code
# The type of calculation to use on the shipping rate.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(delivery_estimate: T.nilable(::Stripe::ShippingRateService::CreateParams::DeliveryEstimate), display_name: String, expand: T.nilable(T::Array[String]), fixed_amount: T.nilable(::Stripe::ShippingRateService::CreateParams::FixedAmount), metadata: T.nilable(T::Hash[String, String]), tax_behavior: T.nilable(String), tax_code: T.nilable(String), type: T.nilable(String)).void
}
def initialize(
delivery_estimate: nil,
display_name: nil,
expand: nil,
fixed_amount: nil,
metadata: nil,
tax_behavior: nil,
tax_code: nil,
type: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
class FixedAmount < Stripe::RequestParams
class CurrencyOptions < Stripe::RequestParams
# A non-negative integer in cents representing how much to charge.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
sig { params(amount: T.nilable(Integer), tax_behavior: T.nilable(String)).void }
def initialize(amount: nil, tax_behavior: nil); end
end
# Shipping rates defined in each available currency option. Each key must be a three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html) and a [supported currency](https://stripe.com/docs/currencies).
sig {
returns(T.nilable(T::Hash[String, ::Stripe::ShippingRateService::UpdateParams::FixedAmount::CurrencyOptions]))
}
attr_accessor :currency_options
sig {
params(currency_options: T.nilable(T::Hash[String, ::Stripe::ShippingRateService::UpdateParams::FixedAmount::CurrencyOptions])).void
}
def initialize(currency_options: nil); end
end
# Whether the shipping rate can be used for new purchases. Defaults to `true`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Describes a fixed amount to charge for shipping. Must be present if type is `fixed_amount`.
sig { returns(T.nilable(::Stripe::ShippingRateService::UpdateParams::FixedAmount)) }
attr_accessor :fixed_amount
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Specifies whether the rate is considered inclusive of taxes or exclusive of taxes. One of `inclusive`, `exclusive`, or `unspecified`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
sig {
params(active: T.nilable(T::Boolean), expand: T.nilable(T::Array[String]), fixed_amount: T.nilable(::Stripe::ShippingRateService::UpdateParams::FixedAmount), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), tax_behavior: T.nilable(String)).void
}
def initialize(
active: nil,
expand: nil,
fixed_amount: nil,
metadata: nil,
tax_behavior: nil
); end
end
# Creates a new shipping rate object.
sig {
params(params: T.any(::Stripe::ShippingRateService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ShippingRate)
}
def create(params = {}, opts = {}); end
# Returns a list of your shipping rates.
sig {
params(params: T.any(::Stripe::ShippingRateService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Returns the shipping rate object with the given ID.
sig {
params(shipping_rate_token: String, params: T.any(::Stripe::ShippingRateService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ShippingRate)
}
def retrieve(shipping_rate_token, params = {}, opts = {}); end
# Updates an existing shipping rate object.
sig {
params(shipping_rate_token: String, params: T.any(::Stripe::ShippingRateService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ShippingRate)
}
def update(shipping_rate_token, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class SourceService < StripeService
attr_reader :transactions
class DetachParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class RetrieveParams < Stripe::RequestParams
# The client secret of the source. Required if a publishable key is used to retrieve the source.
sig { returns(T.nilable(String)) }
attr_accessor :client_secret
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(client_secret: T.nilable(String), expand: T.nilable(T::Array[String])).void }
def initialize(client_secret: nil, expand: nil); end
end
class UpdateParams < Stripe::RequestParams
class Mandate < Stripe::RequestParams
class Acceptance < Stripe::RequestParams
class Offline < Stripe::RequestParams
# An email to contact you with if a copy of the mandate is requested, required if `type` is `offline`.
sig { returns(String) }
attr_accessor :contact_email
sig { params(contact_email: String).void }
def initialize(contact_email: nil); end
end
class Online < Stripe::RequestParams
# The Unix timestamp (in seconds) when the mandate was accepted or refused by the customer.
sig { returns(T.nilable(Integer)) }
attr_accessor :date
# The IP address from which the mandate was accepted or refused by the customer.
sig { returns(T.nilable(String)) }
attr_accessor :ip
# The user agent of the browser from which the mandate was accepted or refused by the customer.
sig { returns(T.nilable(String)) }
attr_accessor :user_agent
sig {
params(date: T.nilable(Integer), ip: T.nilable(String), user_agent: T.nilable(String)).void
}
def initialize(date: nil, ip: nil, user_agent: nil); end
end
# The Unix timestamp (in seconds) when the mandate was accepted or refused by the customer.
sig { returns(T.nilable(Integer)) }
attr_accessor :date
# The IP address from which the mandate was accepted or refused by the customer.
sig { returns(T.nilable(String)) }
attr_accessor :ip
# The parameters required to store a mandate accepted offline. Should only be set if `mandate[type]` is `offline`
sig {
returns(T.nilable(::Stripe::SourceService::UpdateParams::Mandate::Acceptance::Offline))
}
attr_accessor :offline
# The parameters required to store a mandate accepted online. Should only be set if `mandate[type]` is `online`
sig {
returns(T.nilable(::Stripe::SourceService::UpdateParams::Mandate::Acceptance::Online))
}
attr_accessor :online
# The status of the mandate acceptance. Either `accepted` (the mandate was accepted) or `refused` (the mandate was refused).
sig { returns(String) }
attr_accessor :status
# The type of acceptance information included with the mandate. Either `online` or `offline`
sig { returns(T.nilable(String)) }
attr_accessor :type
# The user agent of the browser from which the mandate was accepted or refused by the customer.
sig { returns(T.nilable(String)) }
attr_accessor :user_agent
sig {
params(date: T.nilable(Integer), ip: T.nilable(String), offline: T.nilable(::Stripe::SourceService::UpdateParams::Mandate::Acceptance::Offline), online: T.nilable(::Stripe::SourceService::UpdateParams::Mandate::Acceptance::Online), status: String, type: T.nilable(String), user_agent: T.nilable(String)).void
}
def initialize(
date: nil,
ip: nil,
offline: nil,
online: nil,
status: nil,
type: nil,
user_agent: nil
); end
end
# The parameters required to notify Stripe of a mandate acceptance or refusal by the customer.
sig { returns(T.nilable(::Stripe::SourceService::UpdateParams::Mandate::Acceptance)) }
attr_accessor :acceptance
# The amount specified by the mandate. (Leave null for a mandate covering all amounts)
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :amount
# The currency specified by the mandate. (Must match `currency` of the source)
sig { returns(T.nilable(String)) }
attr_accessor :currency
# The interval of debits permitted by the mandate. Either `one_time` (just permitting a single debit), `scheduled` (with debits on an agreed schedule or for clearly-defined events), or `variable`(for debits with any frequency)
sig { returns(T.nilable(String)) }
attr_accessor :interval
# The method Stripe should use to notify the customer of upcoming debit instructions and/or mandate confirmation as required by the underlying debit network. Either `email` (an email is sent directly to the customer), `manual` (a `source.mandate_notification` event is sent to your webhooks endpoint and you should handle the notification) or `none` (the underlying debit network does not require any notification).
sig { returns(T.nilable(String)) }
attr_accessor :notification_method
sig {
params(acceptance: T.nilable(::Stripe::SourceService::UpdateParams::Mandate::Acceptance), amount: T.nilable(T.nilable(T.any(String, Integer))), currency: T.nilable(String), interval: T.nilable(String), notification_method: T.nilable(String)).void
}
def initialize(
acceptance: nil,
amount: nil,
currency: nil,
interval: nil,
notification_method: nil
); end
end
class Owner < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Owner's address.
sig { returns(T.nilable(::Stripe::SourceService::UpdateParams::Owner::Address)) }
attr_accessor :address
# Owner's email address.
sig { returns(T.nilable(String)) }
attr_accessor :email
# Owner's full name.
sig { returns(T.nilable(String)) }
attr_accessor :name
# Owner's phone number.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(address: T.nilable(::Stripe::SourceService::UpdateParams::Owner::Address), email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(address: nil, email: nil, name: nil, phone: nil); end
end
class SourceOrder < Stripe::RequestParams
class Item < Stripe::RequestParams
# Attribute for param field amount
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# Attribute for param field currency
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Attribute for param field description
sig { returns(T.nilable(String)) }
attr_accessor :description
# The ID of the SKU being ordered.
sig { returns(T.nilable(String)) }
attr_accessor :parent
# The quantity of this order item. When type is `sku`, this is the number of instances of the SKU to be ordered.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# Attribute for param field type
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(amount: T.nilable(Integer), currency: T.nilable(String), description: T.nilable(String), parent: T.nilable(String), quantity: T.nilable(Integer), type: T.nilable(String)).void
}
def initialize(
amount: nil,
currency: nil,
description: nil,
parent: nil,
quantity: nil,
type: nil
); end
end
class Shipping < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(String) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: String, line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Shipping address.
sig { returns(::Stripe::SourceService::UpdateParams::SourceOrder::Shipping::Address) }
attr_accessor :address
# The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
sig { returns(T.nilable(String)) }
attr_accessor :carrier
# Recipient name.
sig { returns(T.nilable(String)) }
attr_accessor :name
# Recipient phone (including extension).
sig { returns(T.nilable(String)) }
attr_accessor :phone
# The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
sig { returns(T.nilable(String)) }
attr_accessor :tracking_number
sig {
params(address: ::Stripe::SourceService::UpdateParams::SourceOrder::Shipping::Address, carrier: T.nilable(String), name: T.nilable(String), phone: T.nilable(String), tracking_number: T.nilable(String)).void
}
def initialize(
address: nil,
carrier: nil,
name: nil,
phone: nil,
tracking_number: nil
); end
end
# List of items constituting the order.
sig {
returns(T.nilable(T::Array[::Stripe::SourceService::UpdateParams::SourceOrder::Item]))
}
attr_accessor :items
# Shipping address for the order. Required if any of the SKUs are for products that have `shippable` set to true.
sig { returns(T.nilable(::Stripe::SourceService::UpdateParams::SourceOrder::Shipping)) }
attr_accessor :shipping
sig {
params(items: T.nilable(T::Array[::Stripe::SourceService::UpdateParams::SourceOrder::Item]), shipping: T.nilable(::Stripe::SourceService::UpdateParams::SourceOrder::Shipping)).void
}
def initialize(items: nil, shipping: nil); end
end
# Amount associated with the source.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Information about a mandate possibility attached to a source object (generally for bank debits) as well as its acceptance status.
sig { returns(T.nilable(::Stripe::SourceService::UpdateParams::Mandate)) }
attr_accessor :mandate
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Information about the owner of the payment instrument that may be used or required by particular source types.
sig { returns(T.nilable(::Stripe::SourceService::UpdateParams::Owner)) }
attr_accessor :owner
# Information about the items and shipping associated with the source. Required for transactional credit (for example Klarna) sources before you can charge it.
sig { returns(T.nilable(::Stripe::SourceService::UpdateParams::SourceOrder)) }
attr_accessor :source_order
sig {
params(amount: T.nilable(Integer), expand: T.nilable(T::Array[String]), mandate: T.nilable(::Stripe::SourceService::UpdateParams::Mandate), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), owner: T.nilable(::Stripe::SourceService::UpdateParams::Owner), source_order: T.nilable(::Stripe::SourceService::UpdateParams::SourceOrder)).void
}
def initialize(
amount: nil,
expand: nil,
mandate: nil,
metadata: nil,
owner: nil,
source_order: nil
); end
end
class CreateParams < Stripe::RequestParams
class Mandate < Stripe::RequestParams
class Acceptance < Stripe::RequestParams
class Offline < Stripe::RequestParams
# An email to contact you with if a copy of the mandate is requested, required if `type` is `offline`.
sig { returns(String) }
attr_accessor :contact_email
sig { params(contact_email: String).void }
def initialize(contact_email: nil); end
end
class Online < Stripe::RequestParams
# The Unix timestamp (in seconds) when the mandate was accepted or refused by the customer.
sig { returns(T.nilable(Integer)) }
attr_accessor :date
# The IP address from which the mandate was accepted or refused by the customer.
sig { returns(T.nilable(String)) }
attr_accessor :ip
# The user agent of the browser from which the mandate was accepted or refused by the customer.
sig { returns(T.nilable(String)) }
attr_accessor :user_agent
sig {
params(date: T.nilable(Integer), ip: T.nilable(String), user_agent: T.nilable(String)).void
}
def initialize(date: nil, ip: nil, user_agent: nil); end
end
# The Unix timestamp (in seconds) when the mandate was accepted or refused by the customer.
sig { returns(T.nilable(Integer)) }
attr_accessor :date
# The IP address from which the mandate was accepted or refused by the customer.
sig { returns(T.nilable(String)) }
attr_accessor :ip
# The parameters required to store a mandate accepted offline. Should only be set if `mandate[type]` is `offline`
sig {
returns(T.nilable(::Stripe::SourceService::CreateParams::Mandate::Acceptance::Offline))
}
attr_accessor :offline
# The parameters required to store a mandate accepted online. Should only be set if `mandate[type]` is `online`
sig {
returns(T.nilable(::Stripe::SourceService::CreateParams::Mandate::Acceptance::Online))
}
attr_accessor :online
# The status of the mandate acceptance. Either `accepted` (the mandate was accepted) or `refused` (the mandate was refused).
sig { returns(String) }
attr_accessor :status
# The type of acceptance information included with the mandate. Either `online` or `offline`
sig { returns(T.nilable(String)) }
attr_accessor :type
# The user agent of the browser from which the mandate was accepted or refused by the customer.
sig { returns(T.nilable(String)) }
attr_accessor :user_agent
sig {
params(date: T.nilable(Integer), ip: T.nilable(String), offline: T.nilable(::Stripe::SourceService::CreateParams::Mandate::Acceptance::Offline), online: T.nilable(::Stripe::SourceService::CreateParams::Mandate::Acceptance::Online), status: String, type: T.nilable(String), user_agent: T.nilable(String)).void
}
def initialize(
date: nil,
ip: nil,
offline: nil,
online: nil,
status: nil,
type: nil,
user_agent: nil
); end
end
# The parameters required to notify Stripe of a mandate acceptance or refusal by the customer.
sig { returns(T.nilable(::Stripe::SourceService::CreateParams::Mandate::Acceptance)) }
attr_accessor :acceptance
# The amount specified by the mandate. (Leave null for a mandate covering all amounts)
sig { returns(T.nilable(T.nilable(T.any(String, Integer)))) }
attr_accessor :amount
# The currency specified by the mandate. (Must match `currency` of the source)
sig { returns(T.nilable(String)) }
attr_accessor :currency
# The interval of debits permitted by the mandate. Either `one_time` (just permitting a single debit), `scheduled` (with debits on an agreed schedule or for clearly-defined events), or `variable`(for debits with any frequency)
sig { returns(T.nilable(String)) }
attr_accessor :interval
# The method Stripe should use to notify the customer of upcoming debit instructions and/or mandate confirmation as required by the underlying debit network. Either `email` (an email is sent directly to the customer), `manual` (a `source.mandate_notification` event is sent to your webhooks endpoint and you should handle the notification) or `none` (the underlying debit network does not require any notification).
sig { returns(T.nilable(String)) }
attr_accessor :notification_method
sig {
params(acceptance: T.nilable(::Stripe::SourceService::CreateParams::Mandate::Acceptance), amount: T.nilable(T.nilable(T.any(String, Integer))), currency: T.nilable(String), interval: T.nilable(String), notification_method: T.nilable(String)).void
}
def initialize(
acceptance: nil,
amount: nil,
currency: nil,
interval: nil,
notification_method: nil
); end
end
class Owner < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Owner's address.
sig { returns(T.nilable(::Stripe::SourceService::CreateParams::Owner::Address)) }
attr_accessor :address
# Owner's email address.
sig { returns(T.nilable(String)) }
attr_accessor :email
# Owner's full name.
sig { returns(T.nilable(String)) }
attr_accessor :name
# Owner's phone number.
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(address: T.nilable(::Stripe::SourceService::CreateParams::Owner::Address), email: T.nilable(String), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(address: nil, email: nil, name: nil, phone: nil); end
end
class Receiver < Stripe::RequestParams
# The method Stripe should use to request information needed to process a refund or mispayment. Either `email` (an email is sent directly to the customer) or `manual` (a `source.refund_attributes_required` event is sent to your webhooks endpoint). Refer to each payment method's documentation to learn which refund attributes may be required.
sig { returns(T.nilable(String)) }
attr_accessor :refund_attributes_method
sig { params(refund_attributes_method: T.nilable(String)).void }
def initialize(refund_attributes_method: nil); end
end
class Redirect < Stripe::RequestParams
# The URL you provide to redirect the customer back to you after they authenticated their payment. It can use your application URI scheme in the context of a mobile application.
sig { returns(String) }
attr_accessor :return_url
sig { params(return_url: String).void }
def initialize(return_url: nil); end
end
class SourceOrder < Stripe::RequestParams
class Item < Stripe::RequestParams
# Attribute for param field amount
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# Attribute for param field currency
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Attribute for param field description
sig { returns(T.nilable(String)) }
attr_accessor :description
# The ID of the SKU being ordered.
sig { returns(T.nilable(String)) }
attr_accessor :parent
# The quantity of this order item. When type is `sku`, this is the number of instances of the SKU to be ordered.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# Attribute for param field type
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(amount: T.nilable(Integer), currency: T.nilable(String), description: T.nilable(String), parent: T.nilable(String), quantity: T.nilable(Integer), type: T.nilable(String)).void
}
def initialize(
amount: nil,
currency: nil,
description: nil,
parent: nil,
quantity: nil,
type: nil
); end
end
class Shipping < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(String) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: String, line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Shipping address.
sig { returns(::Stripe::SourceService::CreateParams::SourceOrder::Shipping::Address) }
attr_accessor :address
# The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
sig { returns(T.nilable(String)) }
attr_accessor :carrier
# Recipient name.
sig { returns(T.nilable(String)) }
attr_accessor :name
# Recipient phone (including extension).
sig { returns(T.nilable(String)) }
attr_accessor :phone
# The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
sig { returns(T.nilable(String)) }
attr_accessor :tracking_number
sig {
params(address: ::Stripe::SourceService::CreateParams::SourceOrder::Shipping::Address, carrier: T.nilable(String), name: T.nilable(String), phone: T.nilable(String), tracking_number: T.nilable(String)).void
}
def initialize(
address: nil,
carrier: nil,
name: nil,
phone: nil,
tracking_number: nil
); end
end
# List of items constituting the order.
sig {
returns(T.nilable(T::Array[::Stripe::SourceService::CreateParams::SourceOrder::Item]))
}
attr_accessor :items
# Shipping address for the order. Required if any of the SKUs are for products that have `shippable` set to true.
sig { returns(T.nilable(::Stripe::SourceService::CreateParams::SourceOrder::Shipping)) }
attr_accessor :shipping
sig {
params(items: T.nilable(T::Array[::Stripe::SourceService::CreateParams::SourceOrder::Item]), shipping: T.nilable(::Stripe::SourceService::CreateParams::SourceOrder::Shipping)).void
}
def initialize(items: nil, shipping: nil); end
end
# Amount associated with the source. This is the amount for which the source will be chargeable once ready. Required for `single_use` sources. Not supported for `receiver` type sources, where charge amount may not be specified until funds land.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# Three-letter [ISO code for the currency](https://stripe.com/docs/currencies) associated with the source. This is the currency for which the source will be chargeable once ready.
sig { returns(T.nilable(String)) }
attr_accessor :currency
# The `Customer` to whom the original source is attached to. Must be set when the original source is not a `Source` (e.g., `Card`).
sig { returns(T.nilable(String)) }
attr_accessor :customer
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The authentication `flow` of the source to create. `flow` is one of `redirect`, `receiver`, `code_verification`, `none`. It is generally inferred unless a type supports multiple flows.
sig { returns(T.nilable(String)) }
attr_accessor :flow
# Information about a mandate possibility attached to a source object (generally for bank debits) as well as its acceptance status.
sig { returns(T.nilable(::Stripe::SourceService::CreateParams::Mandate)) }
attr_accessor :mandate
# Attribute for param field metadata
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The source to share.
sig { returns(T.nilable(String)) }
attr_accessor :original_source
# Information about the owner of the payment instrument that may be used or required by particular source types.
sig { returns(T.nilable(::Stripe::SourceService::CreateParams::Owner)) }
attr_accessor :owner
# Optional parameters for the receiver flow. Can be set only if the source is a receiver (`flow` is `receiver`).
sig { returns(T.nilable(::Stripe::SourceService::CreateParams::Receiver)) }
attr_accessor :receiver
# Parameters required for the redirect flow. Required if the source is authenticated by a redirect (`flow` is `redirect`).
sig { returns(T.nilable(::Stripe::SourceService::CreateParams::Redirect)) }
attr_accessor :redirect
# Information about the items and shipping associated with the source. Required for transactional credit (for example Klarna) sources before you can charge it.
sig { returns(T.nilable(::Stripe::SourceService::CreateParams::SourceOrder)) }
attr_accessor :source_order
# An arbitrary string to be displayed on your customer's statement. As an example, if your website is `RunClub` and the item you're charging for is a race ticket, you may want to specify a `statement_descriptor` of `RunClub 5K race ticket.` While many payment types will display this information, some may not display it at all.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
# An optional token used to create the source. When passed, token properties will override source parameters.
sig { returns(T.nilable(String)) }
attr_accessor :token
# The `type` of the source to create. Required unless `customer` and `original_source` are specified (see the [Cloning card Sources](https://stripe.com/docs/sources/connect#cloning-card-sources) guide)
sig { returns(T.nilable(String)) }
attr_accessor :type
# Attribute for param field usage
sig { returns(T.nilable(String)) }
attr_accessor :usage
sig {
params(amount: T.nilable(Integer), currency: T.nilable(String), customer: T.nilable(String), expand: T.nilable(T::Array[String]), flow: T.nilable(String), mandate: T.nilable(::Stripe::SourceService::CreateParams::Mandate), metadata: T.nilable(T::Hash[String, String]), original_source: T.nilable(String), owner: T.nilable(::Stripe::SourceService::CreateParams::Owner), receiver: T.nilable(::Stripe::SourceService::CreateParams::Receiver), redirect: T.nilable(::Stripe::SourceService::CreateParams::Redirect), source_order: T.nilable(::Stripe::SourceService::CreateParams::SourceOrder), statement_descriptor: T.nilable(String), token: T.nilable(String), type: T.nilable(String), usage: T.nilable(String)).void
}
def initialize(
amount: nil,
currency: nil,
customer: nil,
expand: nil,
flow: nil,
mandate: nil,
metadata: nil,
original_source: nil,
owner: nil,
receiver: nil,
redirect: nil,
source_order: nil,
statement_descriptor: nil,
token: nil,
type: nil,
usage: nil
); end
end
class VerifyParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The values needed to verify the source.
sig { returns(T::Array[String]) }
attr_accessor :values
sig { params(expand: T.nilable(T::Array[String]), values: T::Array[String]).void }
def initialize(expand: nil, values: nil); end
end
# Creates a new source object.
sig {
params(params: T.any(::Stripe::SourceService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Source)
}
def create(params = {}, opts = {}); end
# Delete a specified source for a given customer.
sig {
params(customer: String, id: String, params: T.any(::Stripe::SourceService::DetachParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(T.any(Stripe::Account, Stripe::BankAccount, Stripe::Card, Stripe::Source))
}
def detach(customer, id, params = {}, opts = {}); end
# Retrieves an existing source object. Supply the unique source ID from a source creation request and Stripe will return the corresponding up-to-date source object information.
sig {
params(source: String, params: T.any(::Stripe::SourceService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Source)
}
def retrieve(source, params = {}, opts = {}); end
# Updates the specified source by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
#
# This request accepts the metadata and owner as arguments. It is also possible to update type specific information for selected payment methods. Please refer to our [payment method guides](https://docs.stripe.com/docs/sources) for more detail.
sig {
params(source: String, params: T.any(::Stripe::SourceService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Source)
}
def update(source, params = {}, opts = {}); end
# Verify a given source.
sig {
params(source: String, params: T.any(::Stripe::SourceService::VerifyParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Source)
}
def verify(source, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class SourceTransactionService < StripeService
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
# List source transactions for a given source.
sig {
params(source: String, params: T.any(::Stripe::SourceTransactionService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(source, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class SubscriptionService < StripeService
class CancelParams < Stripe::RequestParams
class CancellationDetails < Stripe::RequestParams
# Additional comments about why the user canceled the subscription, if the subscription was canceled explicitly by the user.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :comment
# The customer submitted reason for why they canceled, if the subscription was canceled explicitly by the user.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :feedback
sig {
params(comment: T.nilable(T.nilable(String)), feedback: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(comment: nil, feedback: nil); end
end
# Details about why this subscription was cancelled
sig { returns(T.nilable(::Stripe::SubscriptionService::CancelParams::CancellationDetails)) }
attr_accessor :cancellation_details
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Will generate a final invoice that invoices for any un-invoiced metered usage and new/pending proration invoice items. Defaults to `false`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :invoice_now
# Will generate a proration invoice item that credits remaining unused time until the subscription period end. Defaults to `false`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :prorate
sig {
params(cancellation_details: T.nilable(::Stripe::SubscriptionService::CancelParams::CancellationDetails), expand: T.nilable(T::Array[String]), invoice_now: T.nilable(T::Boolean), prorate: T.nilable(T::Boolean)).void
}
def initialize(cancellation_details: nil, expand: nil, invoice_now: nil, prorate: nil); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
class AddInvoiceItem < Stripe::RequestParams
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::SubscriptionService::UpdateParams::AddInvoiceItem::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::SubscriptionService::UpdateParams::AddInvoiceItem::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::SubscriptionService::UpdateParams::AddInvoiceItem::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::SubscriptionService::UpdateParams::AddInvoiceItem::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class PriceData < Stripe::RequestParams
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
sig { returns(String) }
attr_accessor :product
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge or a negative integer representing the amount to credit to the customer.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, product: String, tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
# The coupons to redeem into discounts for the item.
sig {
returns(T.nilable(T::Array[::Stripe::SubscriptionService::UpdateParams::AddInvoiceItem::Discount]))
}
attr_accessor :discounts
# The ID of the price object. One of `price` or `price_data` is required.
sig { returns(T.nilable(String)) }
attr_accessor :price
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
sig {
returns(T.nilable(::Stripe::SubscriptionService::UpdateParams::AddInvoiceItem::PriceData))
}
attr_accessor :price_data
# Quantity for this item. Defaults to 1.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# The tax rates which apply to the item. When set, the `default_tax_rates` do not apply to this item.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
sig {
params(discounts: T.nilable(T::Array[::Stripe::SubscriptionService::UpdateParams::AddInvoiceItem::Discount]), price: T.nilable(String), price_data: T.nilable(::Stripe::SubscriptionService::UpdateParams::AddInvoiceItem::PriceData), quantity: T.nilable(Integer), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String])))).void
}
def initialize(
discounts: nil,
price: nil,
price_data: nil,
quantity: nil,
tax_rates: nil
); end
end
class AutomaticTax < Stripe::RequestParams
class Liability < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# Enabled automatic tax calculation which will automatically compute tax rates on all invoices generated by the subscription.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
sig {
returns(T.nilable(::Stripe::SubscriptionService::UpdateParams::AutomaticTax::Liability))
}
attr_accessor :liability
sig {
params(enabled: T::Boolean, liability: T.nilable(::Stripe::SubscriptionService::UpdateParams::AutomaticTax::Liability)).void
}
def initialize(enabled: nil, liability: nil); end
end
class BillingThresholds < Stripe::RequestParams
# Monetary threshold that triggers the subscription to advance to a new billing period
sig { returns(T.nilable(Integer)) }
attr_accessor :amount_gte
# Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :reset_billing_cycle_anchor
sig {
params(amount_gte: T.nilable(Integer), reset_billing_cycle_anchor: T.nilable(T::Boolean)).void
}
def initialize(amount_gte: nil, reset_billing_cycle_anchor: nil); end
end
class CancellationDetails < Stripe::RequestParams
# Additional comments about why the user canceled the subscription, if the subscription was canceled explicitly by the user.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :comment
# The customer submitted reason for why they canceled, if the subscription was canceled explicitly by the user.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :feedback
sig {
params(comment: T.nilable(T.nilable(String)), feedback: T.nilable(T.nilable(T.any(String, String)))).void
}
def initialize(comment: nil, feedback: nil); end
end
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::SubscriptionService::UpdateParams::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::SubscriptionService::UpdateParams::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::SubscriptionService::UpdateParams::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::SubscriptionService::UpdateParams::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class InvoiceSettings < Stripe::RequestParams
class Issuer < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# The account tax IDs associated with the subscription. Will be set on invoices generated by the subscription.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :account_tax_ids
# The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
sig {
returns(T.nilable(::Stripe::SubscriptionService::UpdateParams::InvoiceSettings::Issuer))
}
attr_accessor :issuer
sig {
params(account_tax_ids: T.nilable(T.nilable(T.any(String, T::Array[String]))), issuer: T.nilable(::Stripe::SubscriptionService::UpdateParams::InvoiceSettings::Issuer)).void
}
def initialize(account_tax_ids: nil, issuer: nil); end
end
class Item < Stripe::RequestParams
class BillingThresholds < Stripe::RequestParams
# Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))
sig { returns(Integer) }
attr_accessor :usage_gte
sig { params(usage_gte: Integer).void }
def initialize(usage_gte: nil); end
end
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::SubscriptionService::UpdateParams::Item::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::SubscriptionService::UpdateParams::Item::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::SubscriptionService::UpdateParams::Item::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::SubscriptionService::UpdateParams::Item::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class PriceData < Stripe::RequestParams
class Recurring < Stripe::RequestParams
# Specifies billing frequency. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: T.nilable(Integer)).void }
def initialize(interval: nil, interval_count: nil); end
end
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
sig { returns(String) }
attr_accessor :product
# The recurring components of a price such as `interval` and `interval_count`.
sig { returns(::Stripe::SubscriptionService::UpdateParams::Item::PriceData::Recurring) }
attr_accessor :recurring
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, product: String, recurring: ::Stripe::SubscriptionService::UpdateParams::Item::PriceData::Recurring, tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
recurring: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
# Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::UpdateParams::Item::BillingThresholds))))
}
attr_accessor :billing_thresholds
# Delete all usage for a given subscription item. You must pass this when deleting a usage records subscription item. `clear_usage` has no effect if the plan has a billing meter attached.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :clear_usage
# A flag that, if set to `true`, will delete the specified item.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :deleted
# The coupons to redeem into discounts for the subscription item.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::SubscriptionService::UpdateParams::Item::Discount]))))
}
attr_accessor :discounts
# Subscription item to update.
sig { returns(T.nilable(String)) }
attr_accessor :id
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Plan ID for this item, as a string.
sig { returns(T.nilable(String)) }
attr_accessor :plan
# The ID of the price object. One of `price` or `price_data` is required. When changing a subscription item's price, `quantity` is set to 1 unless a `quantity` parameter is provided.
sig { returns(T.nilable(String)) }
attr_accessor :price
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
sig { returns(T.nilable(::Stripe::SubscriptionService::UpdateParams::Item::PriceData)) }
attr_accessor :price_data
# Quantity for this item.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
sig {
params(billing_thresholds: T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::UpdateParams::Item::BillingThresholds))), clear_usage: T.nilable(T::Boolean), deleted: T.nilable(T::Boolean), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::SubscriptionService::UpdateParams::Item::Discount]))), id: T.nilable(String), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), plan: T.nilable(String), price: T.nilable(String), price_data: T.nilable(::Stripe::SubscriptionService::UpdateParams::Item::PriceData), quantity: T.nilable(Integer), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String])))).void
}
def initialize(
billing_thresholds: nil,
clear_usage: nil,
deleted: nil,
discounts: nil,
id: nil,
metadata: nil,
plan: nil,
price: nil,
price_data: nil,
quantity: nil,
tax_rates: nil
); end
end
class PauseCollection < Stripe::RequestParams
# The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`.
sig { returns(String) }
attr_accessor :behavior
# The time after which the subscription will resume collecting payments.
sig { returns(T.nilable(Integer)) }
attr_accessor :resumes_at
sig { params(behavior: String, resumes_at: T.nilable(Integer)).void }
def initialize(behavior: nil, resumes_at: nil); end
end
class PaymentSettings < Stripe::RequestParams
class PaymentMethodOptions < Stripe::RequestParams
class AcssDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Transaction type of the mandate.
sig { returns(T.nilable(String)) }
attr_accessor :transaction_type
sig { params(transaction_type: T.nilable(String)).void }
def initialize(transaction_type: nil); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::SubscriptionService::UpdateParams::PaymentSettings::PaymentMethodOptions::AcssDebit::MandateOptions))
}
attr_accessor :mandate_options
# Verification method for the intent
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(mandate_options: T.nilable(::Stripe::SubscriptionService::UpdateParams::PaymentSettings::PaymentMethodOptions::AcssDebit::MandateOptions), verification_method: T.nilable(String)).void
}
def initialize(mandate_options: nil, verification_method: nil); end
end
class Bancontact < Stripe::RequestParams
# Preferred language of the Bancontact authorization page that the customer is redirected to.
sig { returns(T.nilable(String)) }
attr_accessor :preferred_language
sig { params(preferred_language: T.nilable(String)).void }
def initialize(preferred_language: nil); end
end
class Card < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Amount to be charged for future payments.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.
sig { returns(T.nilable(String)) }
attr_accessor :amount_type
# A description of the mandate or subscription that is meant to be displayed to the customer.
sig { returns(T.nilable(String)) }
attr_accessor :description
sig {
params(amount: T.nilable(Integer), amount_type: T.nilable(String), description: T.nilable(String)).void
}
def initialize(amount: nil, amount_type: nil, description: nil); end
end
# Configuration options for setting up an eMandate for cards issued in India.
sig {
returns(T.nilable(::Stripe::SubscriptionService::UpdateParams::PaymentSettings::PaymentMethodOptions::Card::MandateOptions))
}
attr_accessor :mandate_options
# Selected network to process this Subscription on. Depends on the available networks of the card attached to the Subscription. Can be only set confirm-time.
sig { returns(T.nilable(String)) }
attr_accessor :network
# We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
sig { returns(T.nilable(String)) }
attr_accessor :request_three_d_secure
sig {
params(mandate_options: T.nilable(::Stripe::SubscriptionService::UpdateParams::PaymentSettings::PaymentMethodOptions::Card::MandateOptions), network: T.nilable(String), request_three_d_secure: T.nilable(String)).void
}
def initialize(mandate_options: nil, network: nil, request_three_d_secure: nil); end
end
class CustomerBalance < Stripe::RequestParams
class BankTransfer < Stripe::RequestParams
class EuBankTransfer < Stripe::RequestParams
# The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
sig { returns(String) }
attr_accessor :country
sig { params(country: String).void }
def initialize(country: nil); end
end
# Configuration for eu_bank_transfer funding type.
sig {
returns(T.nilable(::Stripe::SubscriptionService::UpdateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance::BankTransfer::EuBankTransfer))
}
attr_accessor :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`, `mx_bank_transfer`, or `us_bank_transfer`.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(eu_bank_transfer: T.nilable(::Stripe::SubscriptionService::UpdateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance::BankTransfer::EuBankTransfer), type: T.nilable(String)).void
}
def initialize(eu_bank_transfer: nil, type: nil); end
end
# Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
sig {
returns(T.nilable(::Stripe::SubscriptionService::UpdateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance::BankTransfer))
}
attr_accessor :bank_transfer
# The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
sig { returns(T.nilable(String)) }
attr_accessor :funding_type
sig {
params(bank_transfer: T.nilable(::Stripe::SubscriptionService::UpdateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance::BankTransfer), funding_type: T.nilable(String)).void
}
def initialize(bank_transfer: nil, funding_type: nil); end
end
class IdBankTransfer < Stripe::RequestParams; end
class Konbini < Stripe::RequestParams; end
class SepaDebit < Stripe::RequestParams; end
class UsBankAccount < Stripe::RequestParams
class FinancialConnections < Stripe::RequestParams
class Filters < Stripe::RequestParams
# The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :account_subcategories
# ID of the institution to use to filter for selectable accounts.
sig { returns(T.nilable(String)) }
attr_accessor :institution
sig {
params(account_subcategories: T.nilable(T::Array[String]), institution: T.nilable(String)).void
}
def initialize(account_subcategories: nil, institution: nil); end
end
# Provide filters for the linked accounts that the customer can select for the payment method.
sig {
returns(T.nilable(::Stripe::SubscriptionService::UpdateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount::FinancialConnections::Filters))
}
attr_accessor :filters
# The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :permissions
# List of data features that you would like to retrieve upon account creation.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :prefetch
sig {
params(filters: T.nilable(::Stripe::SubscriptionService::UpdateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount::FinancialConnections::Filters), permissions: T.nilable(T::Array[String]), prefetch: T.nilable(T::Array[String])).void
}
def initialize(filters: nil, permissions: nil, prefetch: nil); end
end
# Additional fields for Financial Connections Session creation
sig {
returns(T.nilable(::Stripe::SubscriptionService::UpdateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount::FinancialConnections))
}
attr_accessor :financial_connections
# Verification method for the intent
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(financial_connections: T.nilable(::Stripe::SubscriptionService::UpdateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount::FinancialConnections), verification_method: T.nilable(String)).void
}
def initialize(financial_connections: nil, verification_method: nil); end
end
# This sub-hash contains details about the Canadian pre-authorized debit payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::UpdateParams::PaymentSettings::PaymentMethodOptions::AcssDebit))))
}
attr_accessor :acss_debit
# This sub-hash contains details about the Bancontact payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::UpdateParams::PaymentSettings::PaymentMethodOptions::Bancontact))))
}
attr_accessor :bancontact
# This sub-hash contains details about the Card payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::UpdateParams::PaymentSettings::PaymentMethodOptions::Card))))
}
attr_accessor :card
# This sub-hash contains details about the Bank transfer payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::UpdateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance))))
}
attr_accessor :customer_balance
# This sub-hash contains details about the Indonesia bank transfer payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::UpdateParams::PaymentSettings::PaymentMethodOptions::IdBankTransfer))))
}
attr_accessor :id_bank_transfer
# This sub-hash contains details about the Konbini payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::UpdateParams::PaymentSettings::PaymentMethodOptions::Konbini))))
}
attr_accessor :konbini
# This sub-hash contains details about the SEPA Direct Debit payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::UpdateParams::PaymentSettings::PaymentMethodOptions::SepaDebit))))
}
attr_accessor :sepa_debit
# This sub-hash contains details about the ACH direct debit payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::UpdateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount))))
}
attr_accessor :us_bank_account
sig {
params(acss_debit: T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::UpdateParams::PaymentSettings::PaymentMethodOptions::AcssDebit))), bancontact: T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::UpdateParams::PaymentSettings::PaymentMethodOptions::Bancontact))), card: T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::UpdateParams::PaymentSettings::PaymentMethodOptions::Card))), customer_balance: T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::UpdateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance))), id_bank_transfer: T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::UpdateParams::PaymentSettings::PaymentMethodOptions::IdBankTransfer))), konbini: T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::UpdateParams::PaymentSettings::PaymentMethodOptions::Konbini))), sepa_debit: T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::UpdateParams::PaymentSettings::PaymentMethodOptions::SepaDebit))), us_bank_account: T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::UpdateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount)))).void
}
def initialize(
acss_debit: nil,
bancontact: nil,
card: nil,
customer_balance: nil,
id_bank_transfer: nil,
konbini: nil,
sepa_debit: nil,
us_bank_account: nil
); end
end
# Payment-method-specific configuration to provide to invoices created by the subscription.
sig {
returns(T.nilable(::Stripe::SubscriptionService::UpdateParams::PaymentSettings::PaymentMethodOptions))
}
attr_accessor :payment_method_options
# The list of payment method types (e.g. card) to provide to the invoice’s PaymentIntent. If not set, Stripe attempts to automatically determine the types to use by looking at the invoice’s default payment method, the subscription’s default payment method, the customer’s default payment method, and your [invoice template settings](https://dashboard.stripe.com/settings/billing/invoice). Should not be specified with payment_method_configuration
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :payment_method_types
# Configure whether Stripe updates `subscription.default_payment_method` when payment succeeds. Defaults to `off` if unspecified.
sig { returns(T.nilable(String)) }
attr_accessor :save_default_payment_method
sig {
params(payment_method_options: T.nilable(::Stripe::SubscriptionService::UpdateParams::PaymentSettings::PaymentMethodOptions), payment_method_types: T.nilable(T.nilable(T.any(String, T::Array[String]))), save_default_payment_method: T.nilable(String)).void
}
def initialize(
payment_method_options: nil,
payment_method_types: nil,
save_default_payment_method: nil
); end
end
class PendingInvoiceItemInterval < Stripe::RequestParams
# Specifies invoicing frequency. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals between invoices. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks).
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: T.nilable(Integer)).void }
def initialize(interval: nil, interval_count: nil); end
end
class Prebilling < Stripe::RequestParams
# This is used to determine the number of billing cycles to prebill.
sig { returns(Integer) }
attr_accessor :iterations
# Whether to cancel or preserve `prebilling` if the subscription is updated during the prebilled period. The default value is `reset`.
sig { returns(T.nilable(String)) }
attr_accessor :update_behavior
sig { params(iterations: Integer, update_behavior: T.nilable(String)).void }
def initialize(iterations: nil, update_behavior: nil); end
end
class TransferData < Stripe::RequestParams
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
sig { returns(T.nilable(Float)) }
attr_accessor :amount_percent
# ID of an existing, connected Stripe account.
sig { returns(String) }
attr_accessor :destination
sig { params(amount_percent: T.nilable(Float), destination: String).void }
def initialize(amount_percent: nil, destination: nil); end
end
class TrialSettings < Stripe::RequestParams
class EndBehavior < Stripe::RequestParams
# Indicates how the subscription should change when the trial ends if the user did not provide a payment method.
sig { returns(String) }
attr_accessor :missing_payment_method
sig { params(missing_payment_method: String).void }
def initialize(missing_payment_method: nil); end
end
# Defines how the subscription should behave when the user's free trial ends.
sig { returns(::Stripe::SubscriptionService::UpdateParams::TrialSettings::EndBehavior) }
attr_accessor :end_behavior
sig {
params(end_behavior: ::Stripe::SubscriptionService::UpdateParams::TrialSettings::EndBehavior).void
}
def initialize(end_behavior: nil); end
end
# A list of prices and quantities that will generate invoice items appended to the next invoice for this subscription. You may pass up to 20 items.
sig {
returns(T.nilable(T::Array[::Stripe::SubscriptionService::UpdateParams::AddInvoiceItem]))
}
attr_accessor :add_invoice_items
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).
sig { returns(T.nilable(T.nilable(T.any(String, Float)))) }
attr_accessor :application_fee_percent
# Automatic tax settings for this subscription. We recommend you only include this parameter when the existing value is being changed.
sig { returns(T.nilable(::Stripe::SubscriptionService::UpdateParams::AutomaticTax)) }
attr_accessor :automatic_tax
# Either `now` or `unchanged`. Setting the value to `now` resets the subscription's billing cycle anchor to the current time (in UTC). For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).
sig { returns(T.nilable(String)) }
attr_accessor :billing_cycle_anchor
# Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. When updating, pass an empty string to remove previously-defined thresholds.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::UpdateParams::BillingThresholds))))
}
attr_accessor :billing_thresholds
# A timestamp at which the subscription should cancel. If set to a date before the current period ends, this will cause a proration if prorations have been enabled using `proration_behavior`. If set during a future period, this will always cause a proration for that period.
sig { returns(T.nilable(T.nilable(T.any(String, T.any(Integer, String))))) }
attr_accessor :cancel_at
# Indicate whether this subscription should cancel at the end of the current period (`current_period_end`). Defaults to `false`. This param will be removed in a future API version. Please use `cancel_at` instead.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :cancel_at_period_end
# Details about why this subscription was cancelled
sig { returns(T.nilable(::Stripe::SubscriptionService::UpdateParams::CancellationDetails)) }
attr_accessor :cancellation_details
# Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically`.
sig { returns(T.nilable(String)) }
attr_accessor :collection_method
# Number of days a customer has to pay invoices generated by this subscription. Valid only for subscriptions where `collection_method` is set to `send_invoice`.
sig { returns(T.nilable(Integer)) }
attr_accessor :days_until_due
# ID of the default payment method for the subscription. It must belong to the customer associated with the subscription. This takes precedence over `default_source`. If neither are set, invoices will use the customer's [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) or [default_source](https://stripe.com/docs/api/customers/object#customer_object-default_source).
sig { returns(T.nilable(String)) }
attr_accessor :default_payment_method
# ID of the default payment source for the subscription. It must belong to the customer associated with the subscription and be in a chargeable state. If `default_payment_method` is also set, `default_payment_method` will take precedence. If neither are set, invoices will use the customer's [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) or [default_source](https://stripe.com/docs/api/customers/object#customer_object-default_source).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :default_source
# The tax rates that will apply to any subscription item that does not have `tax_rates` set. Invoices created will have their `default_tax_rates` populated from the subscription. Pass an empty string to remove previously-defined tax rates.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :default_tax_rates
# The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :description
# The coupons to redeem into discounts for the subscription. If not specified or empty, inherits the discount from the subscription's customer.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::SubscriptionService::UpdateParams::Discount]))))
}
attr_accessor :discounts
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# All invoices will be billed using the specified settings.
sig { returns(T.nilable(::Stripe::SubscriptionService::UpdateParams::InvoiceSettings)) }
attr_accessor :invoice_settings
# A list of up to 20 subscription items, each with an attached price.
sig { returns(T.nilable(T::Array[::Stripe::SubscriptionService::UpdateParams::Item])) }
attr_accessor :items
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Indicates if a customer is on or off-session while an invoice payment is attempted. Defaults to `false` (on-session).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :off_session
# The account on behalf of which to charge, for each of the subscription's invoices.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :on_behalf_of
# If specified, payment collection for this subscription will be paused. Note that the subscription status will be unchanged and will not be updated to `paused`. Learn more about [pausing collection](https://stripe.com/docs/billing/subscriptions/pause-payment).
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::UpdateParams::PauseCollection))))
}
attr_accessor :pause_collection
# Use `allow_incomplete` to transition the subscription to `status=past_due` if a payment is required but cannot be paid. This allows you to manage scenarios where additional user actions are needed to pay a subscription's invoice. For example, SCA regulation may require 3DS authentication to complete payment. See the [SCA Migration Guide](https://stripe.com/docs/billing/migration/strong-customer-authentication) for Billing to learn more. This is the default behavior.
#
# Use `default_incomplete` to transition the subscription to `status=past_due` when payment is required and await explicit confirmation of the invoice's payment intent. This allows simpler management of scenarios where additional user actions are needed to pay a subscription’s invoice. Such as failed payments, [SCA regulation](https://stripe.com/docs/billing/migration/strong-customer-authentication), or collecting a mandate for a bank debit payment method.
#
# Use `pending_if_incomplete` to update the subscription using [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates). When you use `pending_if_incomplete` you can only pass the parameters [supported by pending updates](https://stripe.com/docs/billing/pending-updates-reference#supported-attributes).
#
# Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not update the subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more.
sig { returns(T.nilable(String)) }
attr_accessor :payment_behavior
# Payment settings to pass to invoices created by the subscription.
sig { returns(T.nilable(::Stripe::SubscriptionService::UpdateParams::PaymentSettings)) }
attr_accessor :payment_settings
# Specifies an interval for how often to bill for any pending invoice items. It is analogous to calling [Create an invoice](https://stripe.com/docs/api#create_invoice) for the given subscription at the specified interval.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::UpdateParams::PendingInvoiceItemInterval))))
}
attr_accessor :pending_invoice_item_interval
# If specified, the invoicing for the given billing cycle iterations will be processed now.
sig { returns(T.nilable(::Stripe::SubscriptionService::UpdateParams::Prebilling)) }
attr_accessor :prebilling
# Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/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`.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
# If set, prorations will be calculated as though the subscription was updated at the given time. This can be used to apply exactly the same prorations that were previewed with the [create preview](https://stripe.com/docs/api/invoices/create_preview) endpoint. `proration_date` can also be used to implement custom proration logic, such as prorating by day instead of by second, by providing the time that you wish to use for proration calculations.
sig { returns(T.nilable(Integer)) }
attr_accessor :proration_date
# If specified, the funds from the subscription's invoices will be transferred to the destination and the ID of the resulting transfers will be found on the resulting charges. This will be unset if you POST an empty value.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::UpdateParams::TransferData))))
}
attr_accessor :transfer_data
# Unix timestamp representing the end of the trial period the customer will get before being charged for the first time. This will always overwrite any trials that might apply via a subscribed plan. If set, `trial_end` will override the default trial period of the plan the customer is being subscribed to. The `billing_cycle_anchor` will be updated to the `trial_end` value. The special value `now` can be provided to end the customer's trial immediately. Can be at most two years from `billing_cycle_anchor`.
sig { returns(T.nilable(T.any(String, Integer))) }
attr_accessor :trial_end
# Indicates if a plan's `trial_period_days` should be applied to the subscription. Setting `trial_end` per subscription is preferred, and this defaults to `false`. Setting this flag to `true` together with `trial_end` is not allowed. See [Using trial periods on subscriptions](https://stripe.com/docs/billing/subscriptions/trials) to learn more.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :trial_from_plan
# Settings related to subscription trials.
sig { returns(T.nilable(::Stripe::SubscriptionService::UpdateParams::TrialSettings)) }
attr_accessor :trial_settings
sig {
params(add_invoice_items: T.nilable(T::Array[::Stripe::SubscriptionService::UpdateParams::AddInvoiceItem]), application_fee_percent: T.nilable(T.nilable(T.any(String, Float))), automatic_tax: T.nilable(::Stripe::SubscriptionService::UpdateParams::AutomaticTax), billing_cycle_anchor: T.nilable(String), billing_thresholds: T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::UpdateParams::BillingThresholds))), cancel_at: T.nilable(T.nilable(T.any(String, T.any(Integer, String)))), cancel_at_period_end: T.nilable(T::Boolean), cancellation_details: T.nilable(::Stripe::SubscriptionService::UpdateParams::CancellationDetails), collection_method: T.nilable(String), days_until_due: T.nilable(Integer), default_payment_method: T.nilable(String), default_source: T.nilable(T.nilable(String)), default_tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String]))), description: T.nilable(T.nilable(String)), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::SubscriptionService::UpdateParams::Discount]))), expand: T.nilable(T::Array[String]), invoice_settings: T.nilable(::Stripe::SubscriptionService::UpdateParams::InvoiceSettings), items: T.nilable(T::Array[::Stripe::SubscriptionService::UpdateParams::Item]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), off_session: T.nilable(T::Boolean), on_behalf_of: T.nilable(T.nilable(String)), pause_collection: T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::UpdateParams::PauseCollection))), payment_behavior: T.nilable(String), payment_settings: T.nilable(::Stripe::SubscriptionService::UpdateParams::PaymentSettings), pending_invoice_item_interval: T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::UpdateParams::PendingInvoiceItemInterval))), prebilling: T.nilable(::Stripe::SubscriptionService::UpdateParams::Prebilling), proration_behavior: T.nilable(String), proration_date: T.nilable(Integer), transfer_data: T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::UpdateParams::TransferData))), trial_end: T.nilable(T.any(String, Integer)), trial_from_plan: T.nilable(T::Boolean), trial_settings: T.nilable(::Stripe::SubscriptionService::UpdateParams::TrialSettings)).void
}
def initialize(
add_invoice_items: nil,
application_fee_percent: nil,
automatic_tax: nil,
billing_cycle_anchor: nil,
billing_thresholds: nil,
cancel_at: nil,
cancel_at_period_end: nil,
cancellation_details: nil,
collection_method: nil,
days_until_due: nil,
default_payment_method: nil,
default_source: nil,
default_tax_rates: nil,
description: nil,
discounts: nil,
expand: nil,
invoice_settings: nil,
items: nil,
metadata: nil,
off_session: nil,
on_behalf_of: nil,
pause_collection: nil,
payment_behavior: nil,
payment_settings: nil,
pending_invoice_item_interval: nil,
prebilling: nil,
proration_behavior: nil,
proration_date: nil,
transfer_data: nil,
trial_end: nil,
trial_from_plan: nil,
trial_settings: nil
); end
end
class DeleteDiscountParams < Stripe::RequestParams; end
class ListParams < Stripe::RequestParams
class AutomaticTax < Stripe::RequestParams
# Enabled automatic tax calculation which will automatically compute tax rates on all invoices generated by the subscription.
sig { returns(T::Boolean) }
attr_accessor :enabled
sig { params(enabled: T::Boolean).void }
def initialize(enabled: nil); end
end
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
class CurrentPeriodEnd < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
class CurrentPeriodStart < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Filter subscriptions by their automatic tax settings.
sig { returns(T.nilable(::Stripe::SubscriptionService::ListParams::AutomaticTax)) }
attr_accessor :automatic_tax
# The collection method of the subscriptions to retrieve. Either `charge_automatically` or `send_invoice`.
sig { returns(T.nilable(String)) }
attr_accessor :collection_method
# Only return subscriptions that were created during the given date interval.
sig { returns(T.nilable(T.any(::Stripe::SubscriptionService::ListParams::Created, Integer))) }
attr_accessor :created
# Only return subscriptions whose current_period_end falls within the given date interval.
sig {
returns(T.nilable(T.any(::Stripe::SubscriptionService::ListParams::CurrentPeriodEnd, Integer)))
}
attr_accessor :current_period_end
# Only return subscriptions whose current_period_start falls within the given date interval.
sig {
returns(T.nilable(T.any(::Stripe::SubscriptionService::ListParams::CurrentPeriodStart, Integer)))
}
attr_accessor :current_period_start
# The ID of the customer whose subscriptions will be retrieved.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# The ID of the account whose subscriptions will be retrieved.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# The ID of the plan whose subscriptions will be retrieved.
sig { returns(T.nilable(String)) }
attr_accessor :plan
# Filter for subscriptions that contain this recurring price ID.
sig { returns(T.nilable(String)) }
attr_accessor :price
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# The status of the subscriptions to retrieve. Passing in a value of `canceled` will return all canceled subscriptions, including those belonging to deleted customers. Pass `ended` to find subscriptions that are canceled and subscriptions that are expired due to [incomplete payment](https://stripe.com/docs/billing/subscriptions/overview#subscription-statuses). Passing in a value of `all` will return subscriptions of all statuses. If no value is supplied, all subscriptions that have not been canceled are returned.
sig { returns(T.nilable(String)) }
attr_accessor :status
# Filter for subscriptions that are associated with the specified test clock. The response will not include subscriptions with test clocks if this and the customer parameter is not set.
sig { returns(T.nilable(String)) }
attr_accessor :test_clock
sig {
params(automatic_tax: T.nilable(::Stripe::SubscriptionService::ListParams::AutomaticTax), collection_method: T.nilable(String), created: T.nilable(T.any(::Stripe::SubscriptionService::ListParams::Created, Integer)), current_period_end: T.nilable(T.any(::Stripe::SubscriptionService::ListParams::CurrentPeriodEnd, Integer)), current_period_start: T.nilable(T.any(::Stripe::SubscriptionService::ListParams::CurrentPeriodStart, Integer)), customer: T.nilable(String), customer_account: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), plan: T.nilable(String), price: T.nilable(String), starting_after: T.nilable(String), status: T.nilable(String), test_clock: T.nilable(String)).void
}
def initialize(
automatic_tax: nil,
collection_method: nil,
created: nil,
current_period_end: nil,
current_period_start: nil,
customer: nil,
customer_account: nil,
ending_before: nil,
expand: nil,
limit: nil,
plan: nil,
price: nil,
starting_after: nil,
status: nil,
test_clock: nil
); end
end
class CreateParams < Stripe::RequestParams
class AddInvoiceItem < Stripe::RequestParams
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::SubscriptionService::CreateParams::AddInvoiceItem::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::SubscriptionService::CreateParams::AddInvoiceItem::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::SubscriptionService::CreateParams::AddInvoiceItem::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::SubscriptionService::CreateParams::AddInvoiceItem::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class PriceData < Stripe::RequestParams
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
sig { returns(String) }
attr_accessor :product
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge or a negative integer representing the amount to credit to the customer.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, product: String, tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
# The coupons to redeem into discounts for the item.
sig {
returns(T.nilable(T::Array[::Stripe::SubscriptionService::CreateParams::AddInvoiceItem::Discount]))
}
attr_accessor :discounts
# The ID of the price object. One of `price` or `price_data` is required.
sig { returns(T.nilable(String)) }
attr_accessor :price
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
sig {
returns(T.nilable(::Stripe::SubscriptionService::CreateParams::AddInvoiceItem::PriceData))
}
attr_accessor :price_data
# Quantity for this item. Defaults to 1.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# The tax rates which apply to the item. When set, the `default_tax_rates` do not apply to this item.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
sig {
params(discounts: T.nilable(T::Array[::Stripe::SubscriptionService::CreateParams::AddInvoiceItem::Discount]), price: T.nilable(String), price_data: T.nilable(::Stripe::SubscriptionService::CreateParams::AddInvoiceItem::PriceData), quantity: T.nilable(Integer), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String])))).void
}
def initialize(
discounts: nil,
price: nil,
price_data: nil,
quantity: nil,
tax_rates: nil
); end
end
class AutomaticTax < Stripe::RequestParams
class Liability < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# Enabled automatic tax calculation which will automatically compute tax rates on all invoices generated by the subscription.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
sig {
returns(T.nilable(::Stripe::SubscriptionService::CreateParams::AutomaticTax::Liability))
}
attr_accessor :liability
sig {
params(enabled: T::Boolean, liability: T.nilable(::Stripe::SubscriptionService::CreateParams::AutomaticTax::Liability)).void
}
def initialize(enabled: nil, liability: nil); end
end
class BillingCycleAnchorConfig < Stripe::RequestParams
# The day of the month the billing_cycle_anchor should be. Ranges from 1 to 31.
sig { returns(Integer) }
attr_accessor :day_of_month
# The hour of the day the billing_cycle_anchor should be. Ranges from 0 to 23.
sig { returns(T.nilable(Integer)) }
attr_accessor :hour
# The minute of the hour the billing_cycle_anchor should be. Ranges from 0 to 59.
sig { returns(T.nilable(Integer)) }
attr_accessor :minute
# The month to start full cycle billing periods. Ranges from 1 to 12.
sig { returns(T.nilable(Integer)) }
attr_accessor :month
# The second of the minute the billing_cycle_anchor should be. Ranges from 0 to 59.
sig { returns(T.nilable(Integer)) }
attr_accessor :second
sig {
params(day_of_month: Integer, hour: T.nilable(Integer), minute: T.nilable(Integer), month: T.nilable(Integer), second: T.nilable(Integer)).void
}
def initialize(day_of_month: nil, hour: nil, minute: nil, month: nil, second: nil); end
end
class BillingThresholds < Stripe::RequestParams
# Monetary threshold that triggers the subscription to advance to a new billing period
sig { returns(T.nilable(Integer)) }
attr_accessor :amount_gte
# Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :reset_billing_cycle_anchor
sig {
params(amount_gte: T.nilable(Integer), reset_billing_cycle_anchor: T.nilable(T::Boolean)).void
}
def initialize(amount_gte: nil, reset_billing_cycle_anchor: nil); end
end
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::SubscriptionService::CreateParams::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::SubscriptionService::CreateParams::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::SubscriptionService::CreateParams::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::SubscriptionService::CreateParams::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class InvoiceSettings < Stripe::RequestParams
class Issuer < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# The account tax IDs associated with the subscription. Will be set on invoices generated by the subscription.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :account_tax_ids
# The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
sig {
returns(T.nilable(::Stripe::SubscriptionService::CreateParams::InvoiceSettings::Issuer))
}
attr_accessor :issuer
sig {
params(account_tax_ids: T.nilable(T.nilable(T.any(String, T::Array[String]))), issuer: T.nilable(::Stripe::SubscriptionService::CreateParams::InvoiceSettings::Issuer)).void
}
def initialize(account_tax_ids: nil, issuer: nil); end
end
class Item < Stripe::RequestParams
class BillingThresholds < Stripe::RequestParams
# Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))
sig { returns(Integer) }
attr_accessor :usage_gte
sig { params(usage_gte: Integer).void }
def initialize(usage_gte: nil); end
end
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::SubscriptionService::CreateParams::Item::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::SubscriptionService::CreateParams::Item::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::SubscriptionService::CreateParams::Item::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::SubscriptionService::CreateParams::Item::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class PriceData < Stripe::RequestParams
class Recurring < Stripe::RequestParams
# Specifies billing frequency. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: T.nilable(Integer)).void }
def initialize(interval: nil, interval_count: nil); end
end
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
sig { returns(String) }
attr_accessor :product
# The recurring components of a price such as `interval` and `interval_count`.
sig { returns(::Stripe::SubscriptionService::CreateParams::Item::PriceData::Recurring) }
attr_accessor :recurring
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, product: String, recurring: ::Stripe::SubscriptionService::CreateParams::Item::PriceData::Recurring, tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
recurring: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
class Trial < Stripe::RequestParams
# List of price IDs which, if present on the subscription following a paid trial, constitute opting-in to the paid trial. Currently only supports at most 1 price ID.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :converts_to
# Determines the type of trial for this item.
sig { returns(String) }
attr_accessor :type
sig { params(converts_to: T.nilable(T::Array[String]), type: String).void }
def initialize(converts_to: nil, type: nil); end
end
# Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::CreateParams::Item::BillingThresholds))))
}
attr_accessor :billing_thresholds
# The coupons to redeem into discounts for the subscription item.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::SubscriptionService::CreateParams::Item::Discount]))))
}
attr_accessor :discounts
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Plan ID for this item, as a string.
sig { returns(T.nilable(String)) }
attr_accessor :plan
# The ID of the price object.
sig { returns(T.nilable(String)) }
attr_accessor :price
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
sig { returns(T.nilable(::Stripe::SubscriptionService::CreateParams::Item::PriceData)) }
attr_accessor :price_data
# Quantity for this item.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
# Define options to configure the trial on the subscription item.
sig { returns(T.nilable(::Stripe::SubscriptionService::CreateParams::Item::Trial)) }
attr_accessor :trial
sig {
params(billing_thresholds: T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::CreateParams::Item::BillingThresholds))), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::SubscriptionService::CreateParams::Item::Discount]))), metadata: T.nilable(T::Hash[String, String]), plan: T.nilable(String), price: T.nilable(String), price_data: T.nilable(::Stripe::SubscriptionService::CreateParams::Item::PriceData), quantity: T.nilable(Integer), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String]))), trial: T.nilable(::Stripe::SubscriptionService::CreateParams::Item::Trial)).void
}
def initialize(
billing_thresholds: nil,
discounts: nil,
metadata: nil,
plan: nil,
price: nil,
price_data: nil,
quantity: nil,
tax_rates: nil,
trial: nil
); end
end
class PaymentSettings < Stripe::RequestParams
class PaymentMethodOptions < Stripe::RequestParams
class AcssDebit < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Transaction type of the mandate.
sig { returns(T.nilable(String)) }
attr_accessor :transaction_type
sig { params(transaction_type: T.nilable(String)).void }
def initialize(transaction_type: nil); end
end
# Additional fields for Mandate creation
sig {
returns(T.nilable(::Stripe::SubscriptionService::CreateParams::PaymentSettings::PaymentMethodOptions::AcssDebit::MandateOptions))
}
attr_accessor :mandate_options
# Verification method for the intent
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(mandate_options: T.nilable(::Stripe::SubscriptionService::CreateParams::PaymentSettings::PaymentMethodOptions::AcssDebit::MandateOptions), verification_method: T.nilable(String)).void
}
def initialize(mandate_options: nil, verification_method: nil); end
end
class Bancontact < Stripe::RequestParams
# Preferred language of the Bancontact authorization page that the customer is redirected to.
sig { returns(T.nilable(String)) }
attr_accessor :preferred_language
sig { params(preferred_language: T.nilable(String)).void }
def initialize(preferred_language: nil); end
end
class Card < Stripe::RequestParams
class MandateOptions < Stripe::RequestParams
# Amount to be charged for future payments.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# One of `fixed` or `maximum`. If `fixed`, the `amount` param refers to the exact amount to be charged in future payments. If `maximum`, the amount charged can be up to the value passed for the `amount` param.
sig { returns(T.nilable(String)) }
attr_accessor :amount_type
# A description of the mandate or subscription that is meant to be displayed to the customer.
sig { returns(T.nilable(String)) }
attr_accessor :description
sig {
params(amount: T.nilable(Integer), amount_type: T.nilable(String), description: T.nilable(String)).void
}
def initialize(amount: nil, amount_type: nil, description: nil); end
end
# Configuration options for setting up an eMandate for cards issued in India.
sig {
returns(T.nilable(::Stripe::SubscriptionService::CreateParams::PaymentSettings::PaymentMethodOptions::Card::MandateOptions))
}
attr_accessor :mandate_options
# Selected network to process this Subscription on. Depends on the available networks of the card attached to the Subscription. Can be only set confirm-time.
sig { returns(T.nilable(String)) }
attr_accessor :network
# We strongly recommend that you rely on our SCA Engine to automatically prompt your customers for authentication based on risk level and [other requirements](https://stripe.com/docs/strong-customer-authentication). However, if you wish to request 3D Secure based on logic from your own fraud engine, provide this option. Read our guide on [manually requesting 3D Secure](https://stripe.com/docs/payments/3d-secure/authentication-flow#manual-three-ds) for more information on how this configuration interacts with Radar and our SCA Engine.
sig { returns(T.nilable(String)) }
attr_accessor :request_three_d_secure
sig {
params(mandate_options: T.nilable(::Stripe::SubscriptionService::CreateParams::PaymentSettings::PaymentMethodOptions::Card::MandateOptions), network: T.nilable(String), request_three_d_secure: T.nilable(String)).void
}
def initialize(mandate_options: nil, network: nil, request_three_d_secure: nil); end
end
class CustomerBalance < Stripe::RequestParams
class BankTransfer < Stripe::RequestParams
class EuBankTransfer < Stripe::RequestParams
# The desired country code of the bank account information. Permitted values include: `BE`, `DE`, `ES`, `FR`, `IE`, or `NL`.
sig { returns(String) }
attr_accessor :country
sig { params(country: String).void }
def initialize(country: nil); end
end
# Configuration for eu_bank_transfer funding type.
sig {
returns(T.nilable(::Stripe::SubscriptionService::CreateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance::BankTransfer::EuBankTransfer))
}
attr_accessor :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`, `mx_bank_transfer`, or `us_bank_transfer`.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(eu_bank_transfer: T.nilable(::Stripe::SubscriptionService::CreateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance::BankTransfer::EuBankTransfer), type: T.nilable(String)).void
}
def initialize(eu_bank_transfer: nil, type: nil); end
end
# Configuration for the bank transfer funding type, if the `funding_type` is set to `bank_transfer`.
sig {
returns(T.nilable(::Stripe::SubscriptionService::CreateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance::BankTransfer))
}
attr_accessor :bank_transfer
# The funding method type to be used when there are not enough funds in the customer balance. Permitted values include: `bank_transfer`.
sig { returns(T.nilable(String)) }
attr_accessor :funding_type
sig {
params(bank_transfer: T.nilable(::Stripe::SubscriptionService::CreateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance::BankTransfer), funding_type: T.nilable(String)).void
}
def initialize(bank_transfer: nil, funding_type: nil); end
end
class IdBankTransfer < Stripe::RequestParams; end
class Konbini < Stripe::RequestParams; end
class SepaDebit < Stripe::RequestParams; end
class UsBankAccount < Stripe::RequestParams
class FinancialConnections < Stripe::RequestParams
class Filters < Stripe::RequestParams
# The account subcategories to use to filter for selectable accounts. Valid subcategories are `checking` and `savings`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :account_subcategories
# ID of the institution to use to filter for selectable accounts.
sig { returns(T.nilable(String)) }
attr_accessor :institution
sig {
params(account_subcategories: T.nilable(T::Array[String]), institution: T.nilable(String)).void
}
def initialize(account_subcategories: nil, institution: nil); end
end
# Provide filters for the linked accounts that the customer can select for the payment method.
sig {
returns(T.nilable(::Stripe::SubscriptionService::CreateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount::FinancialConnections::Filters))
}
attr_accessor :filters
# The list of permissions to request. If this parameter is passed, the `payment_method` permission must be included. Valid permissions include: `balances`, `ownership`, `payment_method`, and `transactions`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :permissions
# List of data features that you would like to retrieve upon account creation.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :prefetch
sig {
params(filters: T.nilable(::Stripe::SubscriptionService::CreateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount::FinancialConnections::Filters), permissions: T.nilable(T::Array[String]), prefetch: T.nilable(T::Array[String])).void
}
def initialize(filters: nil, permissions: nil, prefetch: nil); end
end
# Additional fields for Financial Connections Session creation
sig {
returns(T.nilable(::Stripe::SubscriptionService::CreateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount::FinancialConnections))
}
attr_accessor :financial_connections
# Verification method for the intent
sig { returns(T.nilable(String)) }
attr_accessor :verification_method
sig {
params(financial_connections: T.nilable(::Stripe::SubscriptionService::CreateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount::FinancialConnections), verification_method: T.nilable(String)).void
}
def initialize(financial_connections: nil, verification_method: nil); end
end
# This sub-hash contains details about the Canadian pre-authorized debit payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::CreateParams::PaymentSettings::PaymentMethodOptions::AcssDebit))))
}
attr_accessor :acss_debit
# This sub-hash contains details about the Bancontact payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::CreateParams::PaymentSettings::PaymentMethodOptions::Bancontact))))
}
attr_accessor :bancontact
# This sub-hash contains details about the Card payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::CreateParams::PaymentSettings::PaymentMethodOptions::Card))))
}
attr_accessor :card
# This sub-hash contains details about the Bank transfer payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::CreateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance))))
}
attr_accessor :customer_balance
# This sub-hash contains details about the Indonesia bank transfer payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::CreateParams::PaymentSettings::PaymentMethodOptions::IdBankTransfer))))
}
attr_accessor :id_bank_transfer
# This sub-hash contains details about the Konbini payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::CreateParams::PaymentSettings::PaymentMethodOptions::Konbini))))
}
attr_accessor :konbini
# This sub-hash contains details about the SEPA Direct Debit payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::CreateParams::PaymentSettings::PaymentMethodOptions::SepaDebit))))
}
attr_accessor :sepa_debit
# This sub-hash contains details about the ACH direct debit payment method options to pass to the invoice’s PaymentIntent.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::CreateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount))))
}
attr_accessor :us_bank_account
sig {
params(acss_debit: T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::CreateParams::PaymentSettings::PaymentMethodOptions::AcssDebit))), bancontact: T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::CreateParams::PaymentSettings::PaymentMethodOptions::Bancontact))), card: T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::CreateParams::PaymentSettings::PaymentMethodOptions::Card))), customer_balance: T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::CreateParams::PaymentSettings::PaymentMethodOptions::CustomerBalance))), id_bank_transfer: T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::CreateParams::PaymentSettings::PaymentMethodOptions::IdBankTransfer))), konbini: T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::CreateParams::PaymentSettings::PaymentMethodOptions::Konbini))), sepa_debit: T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::CreateParams::PaymentSettings::PaymentMethodOptions::SepaDebit))), us_bank_account: T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::CreateParams::PaymentSettings::PaymentMethodOptions::UsBankAccount)))).void
}
def initialize(
acss_debit: nil,
bancontact: nil,
card: nil,
customer_balance: nil,
id_bank_transfer: nil,
konbini: nil,
sepa_debit: nil,
us_bank_account: nil
); end
end
# Payment-method-specific configuration to provide to invoices created by the subscription.
sig {
returns(T.nilable(::Stripe::SubscriptionService::CreateParams::PaymentSettings::PaymentMethodOptions))
}
attr_accessor :payment_method_options
# The list of payment method types (e.g. card) to provide to the invoice’s PaymentIntent. If not set, Stripe attempts to automatically determine the types to use by looking at the invoice’s default payment method, the subscription’s default payment method, the customer’s default payment method, and your [invoice template settings](https://dashboard.stripe.com/settings/billing/invoice). Should not be specified with payment_method_configuration
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :payment_method_types
# Configure whether Stripe updates `subscription.default_payment_method` when payment succeeds. Defaults to `off` if unspecified.
sig { returns(T.nilable(String)) }
attr_accessor :save_default_payment_method
sig {
params(payment_method_options: T.nilable(::Stripe::SubscriptionService::CreateParams::PaymentSettings::PaymentMethodOptions), payment_method_types: T.nilable(T.nilable(T.any(String, T::Array[String]))), save_default_payment_method: T.nilable(String)).void
}
def initialize(
payment_method_options: nil,
payment_method_types: nil,
save_default_payment_method: nil
); end
end
class PendingInvoiceItemInterval < Stripe::RequestParams
# Specifies invoicing frequency. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals between invoices. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of one year interval allowed (1 year, 12 months, or 52 weeks).
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: T.nilable(Integer)).void }
def initialize(interval: nil, interval_count: nil); end
end
class Prebilling < Stripe::RequestParams
# This is used to determine the number of billing cycles to prebill.
sig { returns(Integer) }
attr_accessor :iterations
# Whether to cancel or preserve `prebilling` if the subscription is updated during the prebilled period. The default value is `reset`.
sig { returns(T.nilable(String)) }
attr_accessor :update_behavior
sig { params(iterations: Integer, update_behavior: T.nilable(String)).void }
def initialize(iterations: nil, update_behavior: nil); end
end
class TransferData < Stripe::RequestParams
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
sig { returns(T.nilable(Float)) }
attr_accessor :amount_percent
# ID of an existing, connected Stripe account.
sig { returns(String) }
attr_accessor :destination
sig { params(amount_percent: T.nilable(Float), destination: String).void }
def initialize(amount_percent: nil, destination: nil); end
end
class TrialSettings < Stripe::RequestParams
class EndBehavior < Stripe::RequestParams
# Indicates how the subscription should change when the trial ends if the user did not provide a payment method.
sig { returns(String) }
attr_accessor :missing_payment_method
sig { params(missing_payment_method: String).void }
def initialize(missing_payment_method: nil); end
end
# Defines how the subscription should behave when the user's free trial ends.
sig { returns(::Stripe::SubscriptionService::CreateParams::TrialSettings::EndBehavior) }
attr_accessor :end_behavior
sig {
params(end_behavior: ::Stripe::SubscriptionService::CreateParams::TrialSettings::EndBehavior).void
}
def initialize(end_behavior: nil); end
end
# A list of prices and quantities that will generate invoice items appended to the next invoice for this subscription. You may pass up to 20 items.
sig {
returns(T.nilable(T::Array[::Stripe::SubscriptionService::CreateParams::AddInvoiceItem]))
}
attr_accessor :add_invoice_items
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).
sig { returns(T.nilable(T.nilable(T.any(String, Float)))) }
attr_accessor :application_fee_percent
# Automatic tax settings for this subscription. We recommend you only include this parameter when the existing value is being changed.
sig { returns(T.nilable(::Stripe::SubscriptionService::CreateParams::AutomaticTax)) }
attr_accessor :automatic_tax
# For new subscriptions, a past timestamp to backdate the subscription's start date to. If set, the first invoice will contain a proration for the timespan between the start date and the current time. Can be combined with trials and the billing cycle anchor.
sig { returns(T.nilable(Integer)) }
attr_accessor :backdate_start_date
# A future timestamp in UTC format to anchor the subscription's [billing cycle](https://stripe.com/docs/subscriptions/billing-cycle). The anchor is the reference point that aligns future billing cycle dates. It sets the day of week for `week` intervals, the day of month for `month` and `year` intervals, and the month of year for `year` intervals.
sig { returns(T.nilable(Integer)) }
attr_accessor :billing_cycle_anchor
# Mutually exclusive with billing_cycle_anchor and only valid with monthly and yearly price intervals. When provided, the billing_cycle_anchor is set to the next occurence of the day_of_month at the hour, minute, and second UTC.
sig {
returns(T.nilable(::Stripe::SubscriptionService::CreateParams::BillingCycleAnchorConfig))
}
attr_accessor :billing_cycle_anchor_config
# Controls how prorations and invoices for subscriptions are calculated and orchestrated.
sig { returns(T.nilable(String)) }
attr_accessor :billing_mode
# Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. When updating, pass an empty string to remove previously-defined thresholds.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::CreateParams::BillingThresholds))))
}
attr_accessor :billing_thresholds
# A timestamp at which the subscription should cancel. If set to a date before the current period ends, this will cause a proration if prorations have been enabled using `proration_behavior`. If set during a future period, this will always cause a proration for that period.
sig { returns(T.nilable(T.any(Integer, String))) }
attr_accessor :cancel_at
# Indicate whether this subscription should cancel at the end of the current period (`current_period_end`). Defaults to `false`. This param will be removed in a future API version. Please use `cancel_at` instead.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :cancel_at_period_end
# Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay this subscription at the end of the cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically`.
sig { returns(T.nilable(String)) }
attr_accessor :collection_method
# 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).
sig { returns(T.nilable(String)) }
attr_accessor :currency
# The identifier of the customer to subscribe.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# The identifier of the account to subscribe.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# Number of days a customer has to pay invoices generated by this subscription. Valid only for subscriptions where `collection_method` is set to `send_invoice`.
sig { returns(T.nilable(Integer)) }
attr_accessor :days_until_due
# ID of the default payment method for the subscription. It must belong to the customer associated with the subscription. This takes precedence over `default_source`. If neither are set, invoices will use the customer's [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) or [default_source](https://stripe.com/docs/api/customers/object#customer_object-default_source).
sig { returns(T.nilable(String)) }
attr_accessor :default_payment_method
# ID of the default payment source for the subscription. It must belong to the customer associated with the subscription and be in a chargeable state. If `default_payment_method` is also set, `default_payment_method` will take precedence. If neither are set, invoices will use the customer's [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) or [default_source](https://stripe.com/docs/api/customers/object#customer_object-default_source).
sig { returns(T.nilable(String)) }
attr_accessor :default_source
# The tax rates that will apply to any subscription item that does not have `tax_rates` set. Invoices created will have their `default_tax_rates` populated from the subscription.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :default_tax_rates
# The subscription's description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
sig { returns(T.nilable(String)) }
attr_accessor :description
# The coupons to redeem into discounts for the subscription. If not specified or empty, inherits the discount from the subscription's customer.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::SubscriptionService::CreateParams::Discount]))))
}
attr_accessor :discounts
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# All invoices will be billed using the specified settings.
sig { returns(T.nilable(::Stripe::SubscriptionService::CreateParams::InvoiceSettings)) }
attr_accessor :invoice_settings
# A list of up to 20 subscription items, each with an attached price.
sig { returns(T.nilable(T::Array[::Stripe::SubscriptionService::CreateParams::Item])) }
attr_accessor :items
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Indicates if a customer is on or off-session while an invoice payment is attempted. Defaults to `false` (on-session).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :off_session
# The account on behalf of which to charge, for each of the subscription's invoices.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :on_behalf_of
# Only applies to subscriptions with `collection_method=charge_automatically`.
#
# Use `allow_incomplete` to create Subscriptions with `status=incomplete` if the first invoice can't be paid. Creating Subscriptions with this status allows you to manage scenarios where additional customer actions are needed to pay a subscription's invoice. For example, SCA regulation may require 3DS authentication to complete payment. See the [SCA Migration Guide](https://stripe.com/docs/billing/migration/strong-customer-authentication) for Billing to learn more. This is the default behavior.
#
# Use `default_incomplete` to create Subscriptions with `status=incomplete` when the first invoice requires payment, otherwise start as active. Subscriptions transition to `status=active` when successfully confirming the PaymentIntent on the first invoice. This allows simpler management of scenarios where additional customer actions are needed to pay a subscription’s invoice, such as failed payments, [SCA regulation](https://stripe.com/docs/billing/migration/strong-customer-authentication), or collecting a mandate for a bank debit payment method. If the PaymentIntent is not confirmed within 23 hours Subscriptions transition to `status=incomplete_expired`, which is a terminal state.
#
# Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's first invoice can't be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further customer action is needed, this parameter doesn't create a Subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more.
#
# `pending_if_incomplete` is only used with updates and cannot be passed when creating a Subscription.
#
# Subscriptions with `collection_method=send_invoice` are automatically activated regardless of the first Invoice status.
sig { returns(T.nilable(String)) }
attr_accessor :payment_behavior
# Payment settings to pass to invoices created by the subscription.
sig { returns(T.nilable(::Stripe::SubscriptionService::CreateParams::PaymentSettings)) }
attr_accessor :payment_settings
# Specifies an interval for how often to bill for any pending invoice items. It is analogous to calling [Create an invoice](https://stripe.com/docs/api#create_invoice) for the given subscription at the specified interval.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::CreateParams::PendingInvoiceItemInterval))))
}
attr_accessor :pending_invoice_item_interval
# If specified, the invoicing for the given billing cycle iterations will be processed now.
sig { returns(T.nilable(::Stripe::SubscriptionService::CreateParams::Prebilling)) }
attr_accessor :prebilling
# Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/prorations) resulting from the `billing_cycle_anchor`. If no value is passed, the default is `create_prorations`.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
# If specified, the funds from the subscription's invoices will be transferred to the destination and the ID of the resulting transfers will be found on the resulting charges.
sig { returns(T.nilable(::Stripe::SubscriptionService::CreateParams::TransferData)) }
attr_accessor :transfer_data
# Unix timestamp representing the end of the trial period the customer will get before being charged for the first time. If set, trial_end will override the default trial period of the plan the customer is being subscribed to. The special value `now` can be provided to end the customer's trial immediately. Can be at most two years from `billing_cycle_anchor`. See [Using trial periods on subscriptions](https://stripe.com/docs/billing/subscriptions/trials) to learn more.
sig { returns(T.nilable(T.any(String, Integer))) }
attr_accessor :trial_end
# Indicates if a plan's `trial_period_days` should be applied to the subscription. Setting `trial_end` per subscription is preferred, and this defaults to `false`. Setting this flag to `true` together with `trial_end` is not allowed. See [Using trial periods on subscriptions](https://stripe.com/docs/billing/subscriptions/trials) to learn more.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :trial_from_plan
# Integer representing the number of trial period days before the customer is charged for the first time. This will always overwrite any trials that might apply via a subscribed plan. See [Using trial periods on subscriptions](https://stripe.com/docs/billing/subscriptions/trials) to learn more.
sig { returns(T.nilable(Integer)) }
attr_accessor :trial_period_days
# Settings related to subscription trials.
sig { returns(T.nilable(::Stripe::SubscriptionService::CreateParams::TrialSettings)) }
attr_accessor :trial_settings
sig {
params(add_invoice_items: T.nilable(T::Array[::Stripe::SubscriptionService::CreateParams::AddInvoiceItem]), application_fee_percent: T.nilable(T.nilable(T.any(String, Float))), automatic_tax: T.nilable(::Stripe::SubscriptionService::CreateParams::AutomaticTax), backdate_start_date: T.nilable(Integer), billing_cycle_anchor: T.nilable(Integer), billing_cycle_anchor_config: T.nilable(::Stripe::SubscriptionService::CreateParams::BillingCycleAnchorConfig), billing_mode: T.nilable(String), billing_thresholds: T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::CreateParams::BillingThresholds))), cancel_at: T.nilable(T.any(Integer, String)), cancel_at_period_end: T.nilable(T::Boolean), collection_method: T.nilable(String), currency: T.nilable(String), customer: T.nilable(String), customer_account: T.nilable(String), days_until_due: T.nilable(Integer), default_payment_method: T.nilable(String), default_source: T.nilable(String), default_tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String]))), description: T.nilable(String), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::SubscriptionService::CreateParams::Discount]))), expand: T.nilable(T::Array[String]), invoice_settings: T.nilable(::Stripe::SubscriptionService::CreateParams::InvoiceSettings), items: T.nilable(T::Array[::Stripe::SubscriptionService::CreateParams::Item]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), off_session: T.nilable(T::Boolean), on_behalf_of: T.nilable(T.nilable(String)), payment_behavior: T.nilable(String), payment_settings: T.nilable(::Stripe::SubscriptionService::CreateParams::PaymentSettings), pending_invoice_item_interval: T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionService::CreateParams::PendingInvoiceItemInterval))), prebilling: T.nilable(::Stripe::SubscriptionService::CreateParams::Prebilling), proration_behavior: T.nilable(String), transfer_data: T.nilable(::Stripe::SubscriptionService::CreateParams::TransferData), trial_end: T.nilable(T.any(String, Integer)), trial_from_plan: T.nilable(T::Boolean), trial_period_days: T.nilable(Integer), trial_settings: T.nilable(::Stripe::SubscriptionService::CreateParams::TrialSettings)).void
}
def initialize(
add_invoice_items: nil,
application_fee_percent: nil,
automatic_tax: nil,
backdate_start_date: nil,
billing_cycle_anchor: nil,
billing_cycle_anchor_config: nil,
billing_mode: nil,
billing_thresholds: nil,
cancel_at: nil,
cancel_at_period_end: nil,
collection_method: nil,
currency: nil,
customer: nil,
customer_account: nil,
days_until_due: nil,
default_payment_method: nil,
default_source: nil,
default_tax_rates: nil,
description: nil,
discounts: nil,
expand: nil,
invoice_settings: nil,
items: nil,
metadata: nil,
off_session: nil,
on_behalf_of: nil,
payment_behavior: nil,
payment_settings: nil,
pending_invoice_item_interval: nil,
prebilling: nil,
proration_behavior: nil,
transfer_data: nil,
trial_end: nil,
trial_from_plan: nil,
trial_period_days: nil,
trial_settings: nil
); end
end
class SearchParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for pagination across multiple pages of results. Don't include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.
sig { returns(T.nilable(String)) }
attr_accessor :page
# The search query string. See [search query language](https://stripe.com/docs/search#search-query-language) and the list of supported [query fields for subscriptions](https://stripe.com/docs/search#query-fields-for-subscriptions).
sig { returns(String) }
attr_accessor :query
sig {
params(expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), page: T.nilable(String), query: String).void
}
def initialize(expand: nil, limit: nil, page: nil, query: nil); end
end
class MigrateParams < Stripe::RequestParams
# Controls how prorations and invoices for subscriptions are calculated and orchestrated.
sig { returns(String) }
attr_accessor :billing_mode
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(billing_mode: String, expand: T.nilable(T::Array[String])).void }
def initialize(billing_mode: nil, expand: nil); end
end
class ResumeParams < Stripe::RequestParams
# The billing cycle anchor that applies when the subscription is resumed. Either `now` or `unchanged`. The default is `now`. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).
sig { returns(T.nilable(String)) }
attr_accessor :billing_cycle_anchor
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/prorations) resulting from the `billing_cycle_anchor` being `unchanged`. When the `billing_cycle_anchor` is set to `now` (default value), no prorations are generated. If no value is passed, the default is `create_prorations`.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
# If set, prorations will be calculated as though the subscription was resumed at the given time. This can be used to apply exactly the same prorations that were previewed with the [create preview](https://stripe.com/docs/api/invoices/create_preview) endpoint.
sig { returns(T.nilable(Integer)) }
attr_accessor :proration_date
sig {
params(billing_cycle_anchor: T.nilable(String), expand: T.nilable(T::Array[String]), proration_behavior: T.nilable(String), proration_date: T.nilable(Integer)).void
}
def initialize(
billing_cycle_anchor: nil,
expand: nil,
proration_behavior: nil,
proration_date: nil
); end
end
# Cancels a customer's subscription immediately. The customer won't be charged again for the subscription. After it's canceled, you can no longer update the subscription or its [metadata](https://docs.stripe.com/metadata).
#
# Any pending invoice items that you've created are still charged at the end of the period, unless manually [deleted](https://docs.stripe.com/api#delete_invoiceitem). If you've set the subscription to cancel at the end of the period, any pending prorations are also left in place and collected at the end of the period. But if the subscription is set to cancel immediately, pending prorations are removed if invoice_now and prorate are both set to true.
#
# By default, upon subscription cancellation, Stripe stops automatic collection of all finalized invoices for the customer. This is intended to prevent unexpected payment attempts after the customer has canceled a subscription. However, you can resume automatic collection of the invoices manually after subscription cancellation to have us proceed. Or, you could check for unpaid invoices before allowing the customer to cancel the subscription at all.
sig {
params(subscription_exposed_id: String, params: T.any(::Stripe::SubscriptionService::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Subscription)
}
def cancel(subscription_exposed_id, params = {}, opts = {}); end
# Creates a new subscription on an existing customer. Each customer can have up to 500 active or scheduled subscriptions.
#
# When you create a subscription with collection_method=charge_automatically, the first invoice is finalized as part of the request.
# The payment_behavior parameter determines the exact behavior of the initial payment.
#
# To start subscriptions where the first invoice always begins in a draft status, use [subscription schedules](https://docs.stripe.com/docs/billing/subscriptions/subscription-schedules#managing) instead.
# Schedules provide the flexibility to model more complex billing configurations that change over time.
sig {
params(params: T.any(::Stripe::SubscriptionService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Subscription)
}
def create(params = {}, opts = {}); end
# Removes the currently applied discount on a subscription.
sig {
params(subscription_exposed_id: String, params: T.any(::Stripe::SubscriptionService::DeleteDiscountParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Discount)
}
def delete_discount(subscription_exposed_id, params = {}, opts = {}); end
# By default, returns a list of subscriptions that have not been canceled. In order to list canceled subscriptions, specify status=canceled.
sig {
params(params: T.any(::Stripe::SubscriptionService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Upgrade the billing_mode of an existing subscription.
sig {
params(subscription: String, params: T.any(::Stripe::SubscriptionService::MigrateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Subscription)
}
def migrate(subscription, params = {}, opts = {}); end
# Initiates resumption of a paused subscription, optionally resetting the billing cycle anchor and creating prorations. If a resumption invoice is generated, it must be paid or marked uncollectible before the subscription will be unpaused. If payment succeeds the subscription will become active, and if payment fails the subscription will be past_due. The resumption invoice will void automatically if not paid by the expiration date.
sig {
params(subscription: String, params: T.any(::Stripe::SubscriptionService::ResumeParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Subscription)
}
def resume(subscription, params = {}, opts = {}); end
# Retrieves the subscription with the given ID.
sig {
params(subscription_exposed_id: String, params: T.any(::Stripe::SubscriptionService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Subscription)
}
def retrieve(subscription_exposed_id, params = {}, opts = {}); end
# Search for subscriptions you've previously created using Stripe's [Search Query Language](https://docs.stripe.com/docs/search#search-query-language).
# Don't use search in read-after-write flows where strict consistency is necessary. Under normal operating
# conditions, data is searchable in less than a minute. Occasionally, propagation of new or updated data can be up
# to an hour behind during outages. Search functionality is not available to merchants in India.
sig {
params(params: T.any(::Stripe::SubscriptionService::SearchParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SearchResultObject)
}
def search(params = {}, opts = {}); end
# Updates an existing subscription to match the specified parameters.
# When changing prices or quantities, we optionally prorate the price we charge next month to make up for any price changes.
# To preview how the proration is calculated, use the [create preview](https://docs.stripe.com/docs/api/invoices/create_preview) endpoint.
#
# By default, we prorate subscription changes. For example, if a customer signs up on May 1 for a 100 price, they'll be billed 100 immediately. If on May 15 they switch to a 200 price, then on June 1 they'll be billed 250 (200 for a renewal of her subscription, plus a 50 prorating adjustment for half of the previous month's 100 difference). Similarly, a downgrade generates a credit that is applied to the next invoice. We also prorate when you make quantity changes.
#
# Switching prices does not normally change the billing date or generate an immediate charge unless:
#
#
# The billing interval is changed (for example, from monthly to yearly).
# The subscription moves from free to paid.
# A trial starts or ends.
#
#
# In these cases, we apply a credit for the unused time on the previous price, immediately charge the customer using the new price, and reset the billing date. Learn about how [Stripe immediately attempts payment for subscription changes](https://docs.stripe.com/docs/billing/subscriptions/upgrade-downgrade#immediate-payment).
#
# If you want to charge for an upgrade immediately, pass proration_behavior as always_invoice to create prorations, automatically invoice the customer for those proration adjustments, and attempt to collect payment. If you pass create_prorations, the prorations are created but not automatically invoiced. If you want to bill the customer for the prorations before the subscription's renewal date, you need to manually [invoice the customer](https://docs.stripe.com/docs/api/invoices/create).
#
# If you don't want to prorate, set the proration_behavior option to none. With this option, the customer is billed 100 on May 1 and 200 on June 1. Similarly, if you set proration_behavior to none when switching between different billing intervals (for example, from monthly to yearly), we don't generate any credits for the old subscription's unused time. We still reset the billing date and bill immediately for the new subscription.
#
# Updating the quantity on a subscription many times in an hour may result in [rate limiting. If you need to bill for a frequently changing quantity, consider integrating usage-based billing](https://docs.stripe.com/docs/rate-limits) instead.
sig {
params(subscription_exposed_id: String, params: T.any(::Stripe::SubscriptionService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Subscription)
}
def update(subscription_exposed_id, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class SubscriptionItemService < StripeService
class DeleteParams < Stripe::RequestParams
# Delete all usage for the given subscription item. Allowed only when the current plan's `usage_type` is `metered`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :clear_usage
# Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/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`.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
# If set, the proration will be calculated as though the subscription was updated at the given time. This can be used to apply the same proration that was previewed with the [upcoming invoice](https://stripe.com/docs/api#retrieve_customer_invoice) endpoint.
sig { returns(T.nilable(Integer)) }
attr_accessor :proration_date
sig {
params(clear_usage: T.nilable(T::Boolean), proration_behavior: T.nilable(String), proration_date: T.nilable(Integer)).void
}
def initialize(clear_usage: nil, proration_behavior: nil, proration_date: nil); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
class BillingThresholds < Stripe::RequestParams
# Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))
sig { returns(Integer) }
attr_accessor :usage_gte
sig { params(usage_gte: Integer).void }
def initialize(usage_gte: nil); end
end
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::SubscriptionItemService::UpdateParams::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::SubscriptionItemService::UpdateParams::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::SubscriptionItemService::UpdateParams::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::SubscriptionItemService::UpdateParams::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class PriceData < Stripe::RequestParams
class Recurring < Stripe::RequestParams
# Specifies billing frequency. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: T.nilable(Integer)).void }
def initialize(interval: nil, interval_count: nil); end
end
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
sig { returns(String) }
attr_accessor :product
# The recurring components of a price such as `interval` and `interval_count`.
sig { returns(::Stripe::SubscriptionItemService::UpdateParams::PriceData::Recurring) }
attr_accessor :recurring
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, product: String, recurring: ::Stripe::SubscriptionItemService::UpdateParams::PriceData::Recurring, tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
recurring: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
# Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionItemService::UpdateParams::BillingThresholds))))
}
attr_accessor :billing_thresholds
# The coupons to redeem into discounts for the subscription item.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::SubscriptionItemService::UpdateParams::Discount]))))
}
attr_accessor :discounts
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Indicates if a customer is on or off-session while an invoice payment is attempted. Defaults to `false` (on-session).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :off_session
# Use `allow_incomplete` to transition the subscription to `status=past_due` if a payment is required but cannot be paid. This allows you to manage scenarios where additional user actions are needed to pay a subscription's invoice. For example, SCA regulation may require 3DS authentication to complete payment. See the [SCA Migration Guide](https://stripe.com/docs/billing/migration/strong-customer-authentication) for Billing to learn more. This is the default behavior.
#
# Use `default_incomplete` to transition the subscription to `status=past_due` when payment is required and await explicit confirmation of the invoice's payment intent. This allows simpler management of scenarios where additional user actions are needed to pay a subscription’s invoice. Such as failed payments, [SCA regulation](https://stripe.com/docs/billing/migration/strong-customer-authentication), or collecting a mandate for a bank debit payment method.
#
# Use `pending_if_incomplete` to update the subscription using [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates). When you use `pending_if_incomplete` you can only pass the parameters [supported by pending updates](https://stripe.com/docs/billing/pending-updates-reference#supported-attributes).
#
# Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not update the subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more.
sig { returns(T.nilable(String)) }
attr_accessor :payment_behavior
# The identifier of the new plan for this subscription item.
sig { returns(T.nilable(String)) }
attr_accessor :plan
# The ID of the price object. One of `price` or `price_data` is required. When changing a subscription item's price, `quantity` is set to 1 unless a `quantity` parameter is provided.
sig { returns(T.nilable(String)) }
attr_accessor :price
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
sig { returns(T.nilable(::Stripe::SubscriptionItemService::UpdateParams::PriceData)) }
attr_accessor :price_data
# Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/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`.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
# If set, the proration will be calculated as though the subscription was updated at the given time. This can be used to apply the same proration that was previewed with the [upcoming invoice](https://stripe.com/docs/api#retrieve_customer_invoice) endpoint.
sig { returns(T.nilable(Integer)) }
attr_accessor :proration_date
# The quantity you'd like to apply to the subscription item you're creating.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
sig {
params(billing_thresholds: T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionItemService::UpdateParams::BillingThresholds))), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::SubscriptionItemService::UpdateParams::Discount]))), expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), off_session: T.nilable(T::Boolean), payment_behavior: T.nilable(String), plan: T.nilable(String), price: T.nilable(String), price_data: T.nilable(::Stripe::SubscriptionItemService::UpdateParams::PriceData), proration_behavior: T.nilable(String), proration_date: T.nilable(Integer), quantity: T.nilable(Integer), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String])))).void
}
def initialize(
billing_thresholds: nil,
discounts: nil,
expand: nil,
metadata: nil,
off_session: nil,
payment_behavior: nil,
plan: nil,
price: nil,
price_data: nil,
proration_behavior: nil,
proration_date: nil,
quantity: nil,
tax_rates: nil
); end
end
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# The ID of the subscription whose items will be retrieved.
sig { returns(String) }
attr_accessor :subscription
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String), subscription: String).void
}
def initialize(
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil,
subscription: nil
); end
end
class CreateParams < Stripe::RequestParams
class BillingThresholds < Stripe::RequestParams
# Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))
sig { returns(Integer) }
attr_accessor :usage_gte
sig { params(usage_gte: Integer).void }
def initialize(usage_gte: nil); end
end
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::SubscriptionItemService::CreateParams::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::SubscriptionItemService::CreateParams::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::SubscriptionItemService::CreateParams::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::SubscriptionItemService::CreateParams::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class PriceData < Stripe::RequestParams
class Recurring < Stripe::RequestParams
# Specifies billing frequency. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: T.nilable(Integer)).void }
def initialize(interval: nil, interval_count: nil); end
end
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
sig { returns(String) }
attr_accessor :product
# The recurring components of a price such as `interval` and `interval_count`.
sig { returns(::Stripe::SubscriptionItemService::CreateParams::PriceData::Recurring) }
attr_accessor :recurring
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, product: String, recurring: ::Stripe::SubscriptionItemService::CreateParams::PriceData::Recurring, tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
recurring: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
class Trial < Stripe::RequestParams
# List of price IDs which, if present on the subscription following a paid trial, constitute opting-in to the paid trial. Currently only supports at most 1 price ID.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :converts_to
# Determines the type of trial for this item.
sig { returns(String) }
attr_accessor :type
sig { params(converts_to: T.nilable(T::Array[String]), type: String).void }
def initialize(converts_to: nil, type: nil); end
end
# Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionItemService::CreateParams::BillingThresholds))))
}
attr_accessor :billing_thresholds
# The coupons to redeem into discounts for the subscription item.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::SubscriptionItemService::CreateParams::Discount]))))
}
attr_accessor :discounts
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Use `allow_incomplete` to transition the subscription to `status=past_due` if a payment is required but cannot be paid. This allows you to manage scenarios where additional user actions are needed to pay a subscription's invoice. For example, SCA regulation may require 3DS authentication to complete payment. See the [SCA Migration Guide](https://stripe.com/docs/billing/migration/strong-customer-authentication) for Billing to learn more. This is the default behavior.
#
# Use `default_incomplete` to transition the subscription to `status=past_due` when payment is required and await explicit confirmation of the invoice's payment intent. This allows simpler management of scenarios where additional user actions are needed to pay a subscription’s invoice. Such as failed payments, [SCA regulation](https://stripe.com/docs/billing/migration/strong-customer-authentication), or collecting a mandate for a bank debit payment method.
#
# Use `pending_if_incomplete` to update the subscription using [pending updates](https://stripe.com/docs/billing/subscriptions/pending-updates). When you use `pending_if_incomplete` you can only pass the parameters [supported by pending updates](https://stripe.com/docs/billing/pending-updates-reference#supported-attributes).
#
# Use `error_if_incomplete` if you want Stripe to return an HTTP 402 status code if a subscription's invoice cannot be paid. For example, if a payment method requires 3DS authentication due to SCA regulation and further user action is needed, this parameter does not update the subscription and returns an error instead. This was the default behavior for API versions prior to 2019-03-14. See the [changelog](https://stripe.com/docs/upgrades#2019-03-14) to learn more.
sig { returns(T.nilable(String)) }
attr_accessor :payment_behavior
# The identifier of the plan to add to the subscription.
sig { returns(T.nilable(String)) }
attr_accessor :plan
# The ID of the price object.
sig { returns(T.nilable(String)) }
attr_accessor :price
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
sig { returns(T.nilable(::Stripe::SubscriptionItemService::CreateParams::PriceData)) }
attr_accessor :price_data
# Determines how to handle [prorations](https://stripe.com/docs/billing/subscriptions/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`.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
# If set, the proration will be calculated as though the subscription was updated at the given time. This can be used to apply the same proration that was previewed with the [upcoming invoice](https://stripe.com/docs/api#retrieve_customer_invoice) endpoint.
sig { returns(T.nilable(Integer)) }
attr_accessor :proration_date
# The quantity you'd like to apply to the subscription item you're creating.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# The identifier of the subscription to modify.
sig { returns(String) }
attr_accessor :subscription
# A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
# Options that configure the trial on the subscription item.
sig { returns(T.nilable(::Stripe::SubscriptionItemService::CreateParams::Trial)) }
attr_accessor :trial
sig {
params(billing_thresholds: T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionItemService::CreateParams::BillingThresholds))), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::SubscriptionItemService::CreateParams::Discount]))), expand: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), payment_behavior: T.nilable(String), plan: T.nilable(String), price: T.nilable(String), price_data: T.nilable(::Stripe::SubscriptionItemService::CreateParams::PriceData), proration_behavior: T.nilable(String), proration_date: T.nilable(Integer), quantity: T.nilable(Integer), subscription: String, tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String]))), trial: T.nilable(::Stripe::SubscriptionItemService::CreateParams::Trial)).void
}
def initialize(
billing_thresholds: nil,
discounts: nil,
expand: nil,
metadata: nil,
payment_behavior: nil,
plan: nil,
price: nil,
price_data: nil,
proration_behavior: nil,
proration_date: nil,
quantity: nil,
subscription: nil,
tax_rates: nil,
trial: nil
); end
end
# Adds a new item to an existing subscription. No existing items will be changed or replaced.
sig {
params(params: T.any(::Stripe::SubscriptionItemService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SubscriptionItem)
}
def create(params = {}, opts = {}); end
# Deletes an item from the subscription. Removing a subscription item from a subscription will not cancel the subscription.
sig {
params(item: String, params: T.any(::Stripe::SubscriptionItemService::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SubscriptionItem)
}
def delete(item, params = {}, opts = {}); end
# Returns a list of your subscription items for a given subscription.
sig {
params(params: T.any(::Stripe::SubscriptionItemService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the subscription item with the given ID.
sig {
params(item: String, params: T.any(::Stripe::SubscriptionItemService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SubscriptionItem)
}
def retrieve(item, params = {}, opts = {}); end
# Updates the plan or quantity of an item on a current subscription.
sig {
params(item: String, params: T.any(::Stripe::SubscriptionItemService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SubscriptionItem)
}
def update(item, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class SubscriptionScheduleService < StripeService
class ListParams < Stripe::RequestParams
class CanceledAt < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
class CompletedAt < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
class ReleasedAt < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return subscription schedules that were created canceled the given date interval.
sig {
returns(T.nilable(T.any(::Stripe::SubscriptionScheduleService::ListParams::CanceledAt, Integer)))
}
attr_accessor :canceled_at
# Only return subscription schedules that completed during the given date interval.
sig {
returns(T.nilable(T.any(::Stripe::SubscriptionScheduleService::ListParams::CompletedAt, Integer)))
}
attr_accessor :completed_at
# Only return subscription schedules that were created during the given date interval.
sig {
returns(T.nilable(T.any(::Stripe::SubscriptionScheduleService::ListParams::Created, Integer)))
}
attr_accessor :created
# Only return subscription schedules for the given customer.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# Only return subscription schedules for the given account.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Only return subscription schedules that were released during the given date interval.
sig {
returns(T.nilable(T.any(::Stripe::SubscriptionScheduleService::ListParams::ReleasedAt, Integer)))
}
attr_accessor :released_at
# Only return subscription schedules that have not started yet.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :scheduled
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(canceled_at: T.nilable(T.any(::Stripe::SubscriptionScheduleService::ListParams::CanceledAt, Integer)), completed_at: T.nilable(T.any(::Stripe::SubscriptionScheduleService::ListParams::CompletedAt, Integer)), created: T.nilable(T.any(::Stripe::SubscriptionScheduleService::ListParams::Created, Integer)), customer: T.nilable(String), customer_account: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), released_at: T.nilable(T.any(::Stripe::SubscriptionScheduleService::ListParams::ReleasedAt, Integer)), scheduled: T.nilable(T::Boolean), starting_after: T.nilable(String)).void
}
def initialize(
canceled_at: nil,
completed_at: nil,
created: nil,
customer: nil,
customer_account: nil,
ending_before: nil,
expand: nil,
limit: nil,
released_at: nil,
scheduled: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class DefaultSettings < Stripe::RequestParams
class AutomaticTax < Stripe::RequestParams
class Liability < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# Enabled automatic tax calculation which will automatically compute tax rates on all invoices generated by the subscription.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::CreateParams::DefaultSettings::AutomaticTax::Liability))
}
attr_accessor :liability
sig {
params(enabled: T::Boolean, liability: T.nilable(::Stripe::SubscriptionScheduleService::CreateParams::DefaultSettings::AutomaticTax::Liability)).void
}
def initialize(enabled: nil, liability: nil); end
end
class BillingThresholds < Stripe::RequestParams
# Monetary threshold that triggers the subscription to advance to a new billing period
sig { returns(T.nilable(Integer)) }
attr_accessor :amount_gte
# Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :reset_billing_cycle_anchor
sig {
params(amount_gte: T.nilable(Integer), reset_billing_cycle_anchor: T.nilable(T::Boolean)).void
}
def initialize(amount_gte: nil, reset_billing_cycle_anchor: nil); end
end
class InvoiceSettings < Stripe::RequestParams
class Issuer < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# The account tax IDs associated with the subscription schedule. Will be set on invoices generated by the subscription schedule.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :account_tax_ids
# Number of days within which a customer must pay invoices generated by this subscription schedule. This value will be `null` for subscription schedules where `collection_method=charge_automatically`.
sig { returns(T.nilable(Integer)) }
attr_accessor :days_until_due
# The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::CreateParams::DefaultSettings::InvoiceSettings::Issuer))
}
attr_accessor :issuer
sig {
params(account_tax_ids: T.nilable(T.nilable(T.any(String, T::Array[String]))), days_until_due: T.nilable(Integer), issuer: T.nilable(::Stripe::SubscriptionScheduleService::CreateParams::DefaultSettings::InvoiceSettings::Issuer)).void
}
def initialize(account_tax_ids: nil, days_until_due: nil, issuer: nil); end
end
class TransferData < Stripe::RequestParams
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
sig { returns(T.nilable(Float)) }
attr_accessor :amount_percent
# ID of an existing, connected Stripe account.
sig { returns(String) }
attr_accessor :destination
sig { params(amount_percent: T.nilable(Float), destination: String).void }
def initialize(amount_percent: nil, destination: nil); end
end
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).
sig { returns(T.nilable(Float)) }
attr_accessor :application_fee_percent
# Default settings for automatic tax computation.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::CreateParams::DefaultSettings::AutomaticTax))
}
attr_accessor :automatic_tax
# Can be set to `phase_start` to set the anchor to the start of the phase or `automatic` to automatically change it if needed. Cannot be set to `phase_start` if this phase specifies a trial. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).
sig { returns(T.nilable(String)) }
attr_accessor :billing_cycle_anchor
# Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionScheduleService::CreateParams::DefaultSettings::BillingThresholds))))
}
attr_accessor :billing_thresholds
# Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically` on creation.
sig { returns(T.nilable(String)) }
attr_accessor :collection_method
# ID of the default payment method for the subscription schedule. It must belong to the customer associated with the subscription schedule. If not set, invoices will use the default payment method in the customer's invoice settings.
sig { returns(T.nilable(String)) }
attr_accessor :default_payment_method
# Subscription description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :description
# All invoices will be billed using the specified settings.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::CreateParams::DefaultSettings::InvoiceSettings))
}
attr_accessor :invoice_settings
# The account on behalf of which to charge, for each of the associated subscription's invoices.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :on_behalf_of
# The data with which to automatically create a Transfer for each of the associated subscription's invoices.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionScheduleService::CreateParams::DefaultSettings::TransferData))))
}
attr_accessor :transfer_data
sig {
params(application_fee_percent: T.nilable(Float), automatic_tax: T.nilable(::Stripe::SubscriptionScheduleService::CreateParams::DefaultSettings::AutomaticTax), billing_cycle_anchor: T.nilable(String), billing_thresholds: T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionScheduleService::CreateParams::DefaultSettings::BillingThresholds))), collection_method: T.nilable(String), default_payment_method: T.nilable(String), description: T.nilable(T.nilable(String)), invoice_settings: T.nilable(::Stripe::SubscriptionScheduleService::CreateParams::DefaultSettings::InvoiceSettings), on_behalf_of: T.nilable(T.nilable(String)), transfer_data: T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionScheduleService::CreateParams::DefaultSettings::TransferData)))).void
}
def initialize(
application_fee_percent: nil,
automatic_tax: nil,
billing_cycle_anchor: nil,
billing_thresholds: nil,
collection_method: nil,
default_payment_method: nil,
description: nil,
invoice_settings: nil,
on_behalf_of: nil,
transfer_data: nil
); end
end
class Phase < Stripe::RequestParams
class AddInvoiceItem < Stripe::RequestParams
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::CreateParams::Phase::AddInvoiceItem::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::SubscriptionScheduleService::CreateParams::Phase::AddInvoiceItem::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::CreateParams::Phase::AddInvoiceItem::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::SubscriptionScheduleService::CreateParams::Phase::AddInvoiceItem::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class PriceData < Stripe::RequestParams
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
sig { returns(String) }
attr_accessor :product
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge or a negative integer representing the amount to credit to the customer.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, product: String, tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
# The coupons to redeem into discounts for the item.
sig {
returns(T.nilable(T::Array[::Stripe::SubscriptionScheduleService::CreateParams::Phase::AddInvoiceItem::Discount]))
}
attr_accessor :discounts
# The ID of the price object. One of `price` or `price_data` is required.
sig { returns(T.nilable(String)) }
attr_accessor :price
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::CreateParams::Phase::AddInvoiceItem::PriceData))
}
attr_accessor :price_data
# Quantity for this item. Defaults to 1.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# The tax rates which apply to the item. When set, the `default_tax_rates` do not apply to this item.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
sig {
params(discounts: T.nilable(T::Array[::Stripe::SubscriptionScheduleService::CreateParams::Phase::AddInvoiceItem::Discount]), price: T.nilable(String), price_data: T.nilable(::Stripe::SubscriptionScheduleService::CreateParams::Phase::AddInvoiceItem::PriceData), quantity: T.nilable(Integer), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String])))).void
}
def initialize(
discounts: nil,
price: nil,
price_data: nil,
quantity: nil,
tax_rates: nil
); end
end
class AutomaticTax < Stripe::RequestParams
class Liability < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# Enabled automatic tax calculation which will automatically compute tax rates on all invoices generated by the subscription.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::CreateParams::Phase::AutomaticTax::Liability))
}
attr_accessor :liability
sig {
params(enabled: T::Boolean, liability: T.nilable(::Stripe::SubscriptionScheduleService::CreateParams::Phase::AutomaticTax::Liability)).void
}
def initialize(enabled: nil, liability: nil); end
end
class BillingThresholds < Stripe::RequestParams
# Monetary threshold that triggers the subscription to advance to a new billing period
sig { returns(T.nilable(Integer)) }
attr_accessor :amount_gte
# Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :reset_billing_cycle_anchor
sig {
params(amount_gte: T.nilable(Integer), reset_billing_cycle_anchor: T.nilable(T::Boolean)).void
}
def initialize(amount_gte: nil, reset_billing_cycle_anchor: nil); end
end
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::CreateParams::Phase::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::SubscriptionScheduleService::CreateParams::Phase::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::CreateParams::Phase::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::SubscriptionScheduleService::CreateParams::Phase::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class InvoiceSettings < Stripe::RequestParams
class Issuer < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# The account tax IDs associated with this phase of the subscription schedule. Will be set on invoices generated by this phase of the subscription schedule.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :account_tax_ids
# Number of days within which a customer must pay invoices generated by this subscription schedule. This value will be `null` for subscription schedules where `billing=charge_automatically`.
sig { returns(T.nilable(Integer)) }
attr_accessor :days_until_due
# The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::CreateParams::Phase::InvoiceSettings::Issuer))
}
attr_accessor :issuer
sig {
params(account_tax_ids: T.nilable(T.nilable(T.any(String, T::Array[String]))), days_until_due: T.nilable(Integer), issuer: T.nilable(::Stripe::SubscriptionScheduleService::CreateParams::Phase::InvoiceSettings::Issuer)).void
}
def initialize(account_tax_ids: nil, days_until_due: nil, issuer: nil); end
end
class Item < Stripe::RequestParams
class BillingThresholds < Stripe::RequestParams
# Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))
sig { returns(Integer) }
attr_accessor :usage_gte
sig { params(usage_gte: Integer).void }
def initialize(usage_gte: nil); end
end
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::CreateParams::Phase::Item::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::SubscriptionScheduleService::CreateParams::Phase::Item::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::CreateParams::Phase::Item::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::SubscriptionScheduleService::CreateParams::Phase::Item::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class PriceData < Stripe::RequestParams
class Recurring < Stripe::RequestParams
# Specifies billing frequency. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: T.nilable(Integer)).void }
def initialize(interval: nil, interval_count: nil); end
end
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
sig { returns(String) }
attr_accessor :product
# The recurring components of a price such as `interval` and `interval_count`.
sig {
returns(::Stripe::SubscriptionScheduleService::CreateParams::Phase::Item::PriceData::Recurring)
}
attr_accessor :recurring
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, product: String, recurring: ::Stripe::SubscriptionScheduleService::CreateParams::Phase::Item::PriceData::Recurring, tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
recurring: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
class Trial < Stripe::RequestParams
# List of price IDs which, if present on the subscription following a paid trial, constitute opting-in to the paid trial. Currently only supports at most 1 price ID.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :converts_to
# Determines the type of trial for this item.
sig { returns(String) }
attr_accessor :type
sig { params(converts_to: T.nilable(T::Array[String]), type: String).void }
def initialize(converts_to: nil, type: nil); end
end
# Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionScheduleService::CreateParams::Phase::Item::BillingThresholds))))
}
attr_accessor :billing_thresholds
# The coupons to redeem into discounts for the subscription item.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::SubscriptionScheduleService::CreateParams::Phase::Item::Discount]))))
}
attr_accessor :discounts
# Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to a configuration item. Metadata on a configuration item will update the underlying subscription item's `metadata` when the phase is entered, adding new keys and replacing existing keys. Individual keys in the subscription item's `metadata` can be unset by posting an empty value to them in the configuration item's `metadata`. To unset all keys in the subscription item's `metadata`, update the subscription item directly or unset every key individually from the configuration item's `metadata`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The plan ID to subscribe to. You may specify the same ID in `plan` and `price`.
sig { returns(T.nilable(String)) }
attr_accessor :plan
# The ID of the price object.
sig { returns(T.nilable(String)) }
attr_accessor :price
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::CreateParams::Phase::Item::PriceData))
}
attr_accessor :price_data
# Quantity for the given price. Can be set only if the price's `usage_type` is `licensed` and not `metered`.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
# Options that configure the trial on the subscription item.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::CreateParams::Phase::Item::Trial))
}
attr_accessor :trial
sig {
params(billing_thresholds: T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionScheduleService::CreateParams::Phase::Item::BillingThresholds))), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::SubscriptionScheduleService::CreateParams::Phase::Item::Discount]))), metadata: T.nilable(T::Hash[String, String]), plan: T.nilable(String), price: T.nilable(String), price_data: T.nilable(::Stripe::SubscriptionScheduleService::CreateParams::Phase::Item::PriceData), quantity: T.nilable(Integer), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String]))), trial: T.nilable(::Stripe::SubscriptionScheduleService::CreateParams::Phase::Item::Trial)).void
}
def initialize(
billing_thresholds: nil,
discounts: nil,
metadata: nil,
plan: nil,
price: nil,
price_data: nil,
quantity: nil,
tax_rates: nil,
trial: nil
); end
end
class PauseCollection < Stripe::RequestParams
# The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`.
sig { returns(String) }
attr_accessor :behavior
sig { params(behavior: String).void }
def initialize(behavior: nil); end
end
class TransferData < Stripe::RequestParams
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
sig { returns(T.nilable(Float)) }
attr_accessor :amount_percent
# ID of an existing, connected Stripe account.
sig { returns(String) }
attr_accessor :destination
sig { params(amount_percent: T.nilable(Float), destination: String).void }
def initialize(amount_percent: nil, destination: nil); end
end
class TrialSettings < Stripe::RequestParams
class EndBehavior < Stripe::RequestParams
# Configure how an opt-in following a paid trial is billed when using `billing_behavior: prorate_up_front`.
sig { returns(T.nilable(String)) }
attr_accessor :prorate_up_front
sig { params(prorate_up_front: T.nilable(String)).void }
def initialize(prorate_up_front: nil); end
end
# Defines how the subscription should behave when a trial ends.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::CreateParams::Phase::TrialSettings::EndBehavior))
}
attr_accessor :end_behavior
sig {
params(end_behavior: T.nilable(::Stripe::SubscriptionScheduleService::CreateParams::Phase::TrialSettings::EndBehavior)).void
}
def initialize(end_behavior: nil); end
end
# A list of prices and quantities that will generate invoice items appended to the next invoice for this phase. You may pass up to 20 items.
sig {
returns(T.nilable(T::Array[::Stripe::SubscriptionScheduleService::CreateParams::Phase::AddInvoiceItem]))
}
attr_accessor :add_invoice_items
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).
sig { returns(T.nilable(Float)) }
attr_accessor :application_fee_percent
# Automatic tax settings for this phase.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::CreateParams::Phase::AutomaticTax))
}
attr_accessor :automatic_tax
# Can be set to `phase_start` to set the anchor to the start of the phase or `automatic` to automatically change it if needed. Cannot be set to `phase_start` if this phase specifies a trial. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).
sig { returns(T.nilable(String)) }
attr_accessor :billing_cycle_anchor
# Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionScheduleService::CreateParams::Phase::BillingThresholds))))
}
attr_accessor :billing_thresholds
# Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically` on creation.
sig { returns(T.nilable(String)) }
attr_accessor :collection_method
# 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).
sig { returns(T.nilable(String)) }
attr_accessor :currency
# ID of the default payment method for the subscription schedule. It must belong to the customer associated with the subscription schedule. If not set, invoices will use the default payment method in the customer's invoice settings.
sig { returns(T.nilable(String)) }
attr_accessor :default_payment_method
# A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will set the Subscription's [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates), which means they will be the Invoice's [`default_tax_rates`](https://stripe.com/docs/api/invoices/create#create_invoice-default_tax_rates) for any Invoices issued by the Subscription during this Phase.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :default_tax_rates
# Subscription description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :description
# The coupons to redeem into discounts for the schedule phase. If not specified, inherits the discount from the subscription's customer. Pass an empty string to avoid inheriting any discounts.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::SubscriptionScheduleService::CreateParams::Phase::Discount]))))
}
attr_accessor :discounts
# The date at which this phase of the subscription schedule ends. If set, `iterations` must not be set.
sig { returns(T.nilable(Integer)) }
attr_accessor :end_date
# All invoices will be billed using the specified settings.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::CreateParams::Phase::InvoiceSettings))
}
attr_accessor :invoice_settings
# List of configuration items, each with an attached price, to apply during this phase of the subscription schedule.
sig { returns(T::Array[::Stripe::SubscriptionScheduleService::CreateParams::Phase::Item]) }
attr_accessor :items
# Integer representing the multiplier applied to the price interval. For example, `iterations=2` applied to a price with `interval=month` and `interval_count=3` results in a phase of duration `2 * 3 months = 6 months`. If set, `end_date` must not be set.
sig { returns(T.nilable(Integer)) }
attr_accessor :iterations
# Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to a phase. Metadata on a schedule's phase will update the underlying subscription's `metadata` when the phase is entered, adding new keys and replacing existing keys in the subscription's `metadata`. Individual keys in the subscription's `metadata` can be unset by posting an empty value to them in the phase's `metadata`. To unset all keys in the subscription's `metadata`, update the subscription directly or unset every key individually from the phase's `metadata`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The account on behalf of which to charge, for each of the associated subscription's invoices.
sig { returns(T.nilable(String)) }
attr_accessor :on_behalf_of
# If specified, payment collection for this subscription will be paused. Note that the subscription status will be unchanged and will not be updated to `paused`. Learn more about [pausing collection](https://stripe.com/docs/billing/subscriptions/pause-payment).
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::CreateParams::Phase::PauseCollection))
}
attr_accessor :pause_collection
# Controls whether the subscription schedule should create [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when transitioning to this phase if there is a difference in billing configuration. 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 (item price, quantity, etc.) of the current phase.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
# The data with which to automatically create a Transfer for each of the associated subscription's invoices.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::CreateParams::Phase::TransferData))
}
attr_accessor :transfer_data
# If set to true the entire phase is counted as a trial and the customer will not be charged for any fees.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :trial
# Specify trial behavior when crossing phase boundaries
sig { returns(T.nilable(String)) }
attr_accessor :trial_continuation
# Sets the phase to trialing from the start date to this date. Must be before the phase end date, can not be combined with `trial`
sig { returns(T.nilable(Integer)) }
attr_accessor :trial_end
# Settings related to subscription trials.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::CreateParams::Phase::TrialSettings))
}
attr_accessor :trial_settings
sig {
params(add_invoice_items: T.nilable(T::Array[::Stripe::SubscriptionScheduleService::CreateParams::Phase::AddInvoiceItem]), application_fee_percent: T.nilable(Float), automatic_tax: T.nilable(::Stripe::SubscriptionScheduleService::CreateParams::Phase::AutomaticTax), billing_cycle_anchor: T.nilable(String), billing_thresholds: T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionScheduleService::CreateParams::Phase::BillingThresholds))), collection_method: T.nilable(String), currency: T.nilable(String), default_payment_method: T.nilable(String), default_tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String]))), description: T.nilable(T.nilable(String)), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::SubscriptionScheduleService::CreateParams::Phase::Discount]))), end_date: T.nilable(Integer), invoice_settings: T.nilable(::Stripe::SubscriptionScheduleService::CreateParams::Phase::InvoiceSettings), items: T::Array[::Stripe::SubscriptionScheduleService::CreateParams::Phase::Item], iterations: T.nilable(Integer), metadata: T.nilable(T::Hash[String, String]), on_behalf_of: T.nilable(String), pause_collection: T.nilable(::Stripe::SubscriptionScheduleService::CreateParams::Phase::PauseCollection), proration_behavior: T.nilable(String), transfer_data: T.nilable(::Stripe::SubscriptionScheduleService::CreateParams::Phase::TransferData), trial: T.nilable(T::Boolean), trial_continuation: T.nilable(String), trial_end: T.nilable(Integer), trial_settings: T.nilable(::Stripe::SubscriptionScheduleService::CreateParams::Phase::TrialSettings)).void
}
def initialize(
add_invoice_items: nil,
application_fee_percent: nil,
automatic_tax: nil,
billing_cycle_anchor: nil,
billing_thresholds: nil,
collection_method: nil,
currency: nil,
default_payment_method: nil,
default_tax_rates: nil,
description: nil,
discounts: nil,
end_date: nil,
invoice_settings: nil,
items: nil,
iterations: nil,
metadata: nil,
on_behalf_of: nil,
pause_collection: nil,
proration_behavior: nil,
transfer_data: nil,
trial: nil,
trial_continuation: nil,
trial_end: nil,
trial_settings: nil
); end
end
class Prebilling < Stripe::RequestParams
# This is used to determine the number of billing cycles to prebill.
sig { returns(Integer) }
attr_accessor :iterations
# Whether to cancel or preserve `prebilling` if the subscription is updated during the prebilled period. The default value is `reset`.
sig { returns(T.nilable(String)) }
attr_accessor :update_behavior
sig { params(iterations: Integer, update_behavior: T.nilable(String)).void }
def initialize(iterations: nil, update_behavior: nil); end
end
# Configures when the subscription schedule generates prorations for phase transitions. Possible values are `prorate_on_next_phase` or `prorate_up_front` with the default being `prorate_on_next_phase`. `prorate_on_next_phase` will apply phase changes and generate prorations at transition time. `prorate_up_front` will bill for all phases within the current billing cycle up front.
sig { returns(T.nilable(String)) }
attr_accessor :billing_behavior
# Controls how prorations and invoices for subscriptions are calculated and orchestrated.
sig { returns(T.nilable(String)) }
attr_accessor :billing_mode
# The identifier of the customer to create the subscription schedule for.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# The identifier of the account to create the subscription schedule for.
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# Object representing the subscription schedule's default settings.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::CreateParams::DefaultSettings))
}
attr_accessor :default_settings
# Behavior of the subscription schedule and underlying subscription when it ends. Possible values are `release` or `cancel` with the default being `release`. `release` will end the subscription schedule and keep the underlying subscription running. `cancel` will end the subscription schedule and cancel the underlying subscription.
sig { returns(T.nilable(String)) }
attr_accessor :end_behavior
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Migrate an existing subscription to be managed by a subscription schedule. If this parameter is set, a subscription schedule will be created using the subscription's item(s), set to auto-renew using the subscription's interval. When using this parameter, other parameters (such as phase values) cannot be set. To create a subscription schedule with other modifications, we recommend making two separate API calls.
sig { returns(T.nilable(String)) }
attr_accessor :from_subscription
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# List representing phases of the subscription schedule. Each phase can be customized to have different durations, plans, and coupons. If there are multiple phases, the `end_date` of one phase will always equal the `start_date` of the next phase.
sig {
returns(T.nilable(T::Array[::Stripe::SubscriptionScheduleService::CreateParams::Phase]))
}
attr_accessor :phases
# If specified, the invoicing for the given billing cycle iterations will be processed now.
sig { returns(T.nilable(::Stripe::SubscriptionScheduleService::CreateParams::Prebilling)) }
attr_accessor :prebilling
# When the subscription schedule starts. We recommend using `now` so that it starts the subscription immediately. You can also use a Unix timestamp to backdate the subscription so that it starts on a past date, or set a future date for the subscription to start on.
sig { returns(T.nilable(T.any(Integer, String))) }
attr_accessor :start_date
sig {
params(billing_behavior: T.nilable(String), billing_mode: T.nilable(String), customer: T.nilable(String), customer_account: T.nilable(String), default_settings: T.nilable(::Stripe::SubscriptionScheduleService::CreateParams::DefaultSettings), end_behavior: T.nilable(String), expand: T.nilable(T::Array[String]), from_subscription: T.nilable(String), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), phases: T.nilable(T::Array[::Stripe::SubscriptionScheduleService::CreateParams::Phase]), prebilling: T.nilable(::Stripe::SubscriptionScheduleService::CreateParams::Prebilling), start_date: T.nilable(T.any(Integer, String))).void
}
def initialize(
billing_behavior: nil,
billing_mode: nil,
customer: nil,
customer_account: nil,
default_settings: nil,
end_behavior: nil,
expand: nil,
from_subscription: nil,
metadata: nil,
phases: nil,
prebilling: nil,
start_date: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
class DefaultSettings < Stripe::RequestParams
class AutomaticTax < Stripe::RequestParams
class Liability < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# Enabled automatic tax calculation which will automatically compute tax rates on all invoices generated by the subscription.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::UpdateParams::DefaultSettings::AutomaticTax::Liability))
}
attr_accessor :liability
sig {
params(enabled: T::Boolean, liability: T.nilable(::Stripe::SubscriptionScheduleService::UpdateParams::DefaultSettings::AutomaticTax::Liability)).void
}
def initialize(enabled: nil, liability: nil); end
end
class BillingThresholds < Stripe::RequestParams
# Monetary threshold that triggers the subscription to advance to a new billing period
sig { returns(T.nilable(Integer)) }
attr_accessor :amount_gte
# Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :reset_billing_cycle_anchor
sig {
params(amount_gte: T.nilable(Integer), reset_billing_cycle_anchor: T.nilable(T::Boolean)).void
}
def initialize(amount_gte: nil, reset_billing_cycle_anchor: nil); end
end
class InvoiceSettings < Stripe::RequestParams
class Issuer < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# The account tax IDs associated with the subscription schedule. Will be set on invoices generated by the subscription schedule.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :account_tax_ids
# Number of days within which a customer must pay invoices generated by this subscription schedule. This value will be `null` for subscription schedules where `collection_method=charge_automatically`.
sig { returns(T.nilable(Integer)) }
attr_accessor :days_until_due
# The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::UpdateParams::DefaultSettings::InvoiceSettings::Issuer))
}
attr_accessor :issuer
sig {
params(account_tax_ids: T.nilable(T.nilable(T.any(String, T::Array[String]))), days_until_due: T.nilable(Integer), issuer: T.nilable(::Stripe::SubscriptionScheduleService::UpdateParams::DefaultSettings::InvoiceSettings::Issuer)).void
}
def initialize(account_tax_ids: nil, days_until_due: nil, issuer: nil); end
end
class TransferData < Stripe::RequestParams
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
sig { returns(T.nilable(Float)) }
attr_accessor :amount_percent
# ID of an existing, connected Stripe account.
sig { returns(String) }
attr_accessor :destination
sig { params(amount_percent: T.nilable(Float), destination: String).void }
def initialize(amount_percent: nil, destination: nil); end
end
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).
sig { returns(T.nilable(Float)) }
attr_accessor :application_fee_percent
# Default settings for automatic tax computation.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::UpdateParams::DefaultSettings::AutomaticTax))
}
attr_accessor :automatic_tax
# Can be set to `phase_start` to set the anchor to the start of the phase or `automatic` to automatically change it if needed. Cannot be set to `phase_start` if this phase specifies a trial. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).
sig { returns(T.nilable(String)) }
attr_accessor :billing_cycle_anchor
# Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionScheduleService::UpdateParams::DefaultSettings::BillingThresholds))))
}
attr_accessor :billing_thresholds
# Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically` on creation.
sig { returns(T.nilable(String)) }
attr_accessor :collection_method
# ID of the default payment method for the subscription schedule. It must belong to the customer associated with the subscription schedule. If not set, invoices will use the default payment method in the customer's invoice settings.
sig { returns(T.nilable(String)) }
attr_accessor :default_payment_method
# Subscription description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :description
# All invoices will be billed using the specified settings.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::UpdateParams::DefaultSettings::InvoiceSettings))
}
attr_accessor :invoice_settings
# The account on behalf of which to charge, for each of the associated subscription's invoices.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :on_behalf_of
# The data with which to automatically create a Transfer for each of the associated subscription's invoices.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionScheduleService::UpdateParams::DefaultSettings::TransferData))))
}
attr_accessor :transfer_data
sig {
params(application_fee_percent: T.nilable(Float), automatic_tax: T.nilable(::Stripe::SubscriptionScheduleService::UpdateParams::DefaultSettings::AutomaticTax), billing_cycle_anchor: T.nilable(String), billing_thresholds: T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionScheduleService::UpdateParams::DefaultSettings::BillingThresholds))), collection_method: T.nilable(String), default_payment_method: T.nilable(String), description: T.nilable(T.nilable(String)), invoice_settings: T.nilable(::Stripe::SubscriptionScheduleService::UpdateParams::DefaultSettings::InvoiceSettings), on_behalf_of: T.nilable(T.nilable(String)), transfer_data: T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionScheduleService::UpdateParams::DefaultSettings::TransferData)))).void
}
def initialize(
application_fee_percent: nil,
automatic_tax: nil,
billing_cycle_anchor: nil,
billing_thresholds: nil,
collection_method: nil,
default_payment_method: nil,
description: nil,
invoice_settings: nil,
on_behalf_of: nil,
transfer_data: nil
); end
end
class Phase < Stripe::RequestParams
class AddInvoiceItem < Stripe::RequestParams
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::UpdateParams::Phase::AddInvoiceItem::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::SubscriptionScheduleService::UpdateParams::Phase::AddInvoiceItem::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::UpdateParams::Phase::AddInvoiceItem::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::SubscriptionScheduleService::UpdateParams::Phase::AddInvoiceItem::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class PriceData < Stripe::RequestParams
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
sig { returns(String) }
attr_accessor :product
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge or a negative integer representing the amount to credit to the customer.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, product: String, tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
# The coupons to redeem into discounts for the item.
sig {
returns(T.nilable(T::Array[::Stripe::SubscriptionScheduleService::UpdateParams::Phase::AddInvoiceItem::Discount]))
}
attr_accessor :discounts
# The ID of the price object. One of `price` or `price_data` is required.
sig { returns(T.nilable(String)) }
attr_accessor :price
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline. One of `price` or `price_data` is required.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::UpdateParams::Phase::AddInvoiceItem::PriceData))
}
attr_accessor :price_data
# Quantity for this item. Defaults to 1.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# The tax rates which apply to the item. When set, the `default_tax_rates` do not apply to this item.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
sig {
params(discounts: T.nilable(T::Array[::Stripe::SubscriptionScheduleService::UpdateParams::Phase::AddInvoiceItem::Discount]), price: T.nilable(String), price_data: T.nilable(::Stripe::SubscriptionScheduleService::UpdateParams::Phase::AddInvoiceItem::PriceData), quantity: T.nilable(Integer), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String])))).void
}
def initialize(
discounts: nil,
price: nil,
price_data: nil,
quantity: nil,
tax_rates: nil
); end
end
class AutomaticTax < Stripe::RequestParams
class Liability < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# Enabled automatic tax calculation which will automatically compute tax rates on all invoices generated by the subscription.
sig { returns(T::Boolean) }
attr_accessor :enabled
# The account that's liable for tax. If set, the business address and tax registrations required to perform the tax calculation are loaded from this account. The tax transaction is returned in the report of the connected account.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::UpdateParams::Phase::AutomaticTax::Liability))
}
attr_accessor :liability
sig {
params(enabled: T::Boolean, liability: T.nilable(::Stripe::SubscriptionScheduleService::UpdateParams::Phase::AutomaticTax::Liability)).void
}
def initialize(enabled: nil, liability: nil); end
end
class BillingThresholds < Stripe::RequestParams
# Monetary threshold that triggers the subscription to advance to a new billing period
sig { returns(T.nilable(Integer)) }
attr_accessor :amount_gte
# Indicates if the `billing_cycle_anchor` should be reset when a threshold is reached. If true, `billing_cycle_anchor` will be updated to the date/time the threshold was last reached; otherwise, the value will remain unchanged.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :reset_billing_cycle_anchor
sig {
params(amount_gte: T.nilable(Integer), reset_billing_cycle_anchor: T.nilable(T::Boolean)).void
}
def initialize(amount_gte: nil, reset_billing_cycle_anchor: nil); end
end
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::UpdateParams::Phase::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::SubscriptionScheduleService::UpdateParams::Phase::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::UpdateParams::Phase::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::SubscriptionScheduleService::UpdateParams::Phase::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class InvoiceSettings < Stripe::RequestParams
class Issuer < Stripe::RequestParams
# The connected account being referenced when `type` is `account`.
sig { returns(T.nilable(String)) }
attr_accessor :account
# Type of the account referenced in the request.
sig { returns(String) }
attr_accessor :type
sig { params(account: T.nilable(String), type: String).void }
def initialize(account: nil, type: nil); end
end
# The account tax IDs associated with this phase of the subscription schedule. Will be set on invoices generated by this phase of the subscription schedule.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :account_tax_ids
# Number of days within which a customer must pay invoices generated by this subscription schedule. This value will be `null` for subscription schedules where `billing=charge_automatically`.
sig { returns(T.nilable(Integer)) }
attr_accessor :days_until_due
# The connected account that issues the invoice. The invoice is presented with the branding and support information of the specified account.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::UpdateParams::Phase::InvoiceSettings::Issuer))
}
attr_accessor :issuer
sig {
params(account_tax_ids: T.nilable(T.nilable(T.any(String, T::Array[String]))), days_until_due: T.nilable(Integer), issuer: T.nilable(::Stripe::SubscriptionScheduleService::UpdateParams::Phase::InvoiceSettings::Issuer)).void
}
def initialize(account_tax_ids: nil, days_until_due: nil, issuer: nil); end
end
class Item < Stripe::RequestParams
class BillingThresholds < Stripe::RequestParams
# Number of units that meets the billing threshold to advance the subscription to a new billing period (e.g., it takes 10 $5 units to meet a $50 [monetary threshold](https://stripe.com/docs/api/subscriptions/update#update_subscription-billing_thresholds-amount_gte))
sig { returns(Integer) }
attr_accessor :usage_gte
sig { params(usage_gte: Integer).void }
def initialize(usage_gte: nil); end
end
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::UpdateParams::Phase::Item::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::SubscriptionScheduleService::UpdateParams::Phase::Item::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::UpdateParams::Phase::Item::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::SubscriptionScheduleService::UpdateParams::Phase::Item::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, discount_end: nil, promotion_code: nil); end
end
class PriceData < Stripe::RequestParams
class Recurring < Stripe::RequestParams
# Specifies billing frequency. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals between subscription billings. For example, `interval=month` and `interval_count=3` bills every 3 months. Maximum of three years interval allowed (3 years, 36 months, or 156 weeks).
sig { returns(T.nilable(Integer)) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: T.nilable(Integer)).void }
def initialize(interval: nil, interval_count: nil); end
end
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of the [Product](https://docs.stripe.com/api/products) that this [Price](https://docs.stripe.com/api/prices) will belong to.
sig { returns(String) }
attr_accessor :product
# The recurring components of a price such as `interval` and `interval_count`.
sig {
returns(::Stripe::SubscriptionScheduleService::UpdateParams::Phase::Item::PriceData::Recurring)
}
attr_accessor :recurring
# 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.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much to charge.
sig { returns(T.nilable(Integer)) }
attr_accessor :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.
sig { returns(T.nilable(String)) }
attr_accessor :unit_amount_decimal
sig {
params(currency: String, product: String, recurring: ::Stripe::SubscriptionScheduleService::UpdateParams::Phase::Item::PriceData::Recurring, tax_behavior: T.nilable(String), unit_amount: T.nilable(Integer), unit_amount_decimal: T.nilable(String)).void
}
def initialize(
currency: nil,
product: nil,
recurring: nil,
tax_behavior: nil,
unit_amount: nil,
unit_amount_decimal: nil
); end
end
class Trial < Stripe::RequestParams
# List of price IDs which, if present on the subscription following a paid trial, constitute opting-in to the paid trial. Currently only supports at most 1 price ID.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :converts_to
# Determines the type of trial for this item.
sig { returns(String) }
attr_accessor :type
sig { params(converts_to: T.nilable(T::Array[String]), type: String).void }
def initialize(converts_to: nil, type: nil); end
end
# Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionScheduleService::UpdateParams::Phase::Item::BillingThresholds))))
}
attr_accessor :billing_thresholds
# The coupons to redeem into discounts for the subscription item.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::SubscriptionScheduleService::UpdateParams::Phase::Item::Discount]))))
}
attr_accessor :discounts
# Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to a configuration item. Metadata on a configuration item will update the underlying subscription item's `metadata` when the phase is entered, adding new keys and replacing existing keys. Individual keys in the subscription item's `metadata` can be unset by posting an empty value to them in the configuration item's `metadata`. To unset all keys in the subscription item's `metadata`, update the subscription item directly or unset every key individually from the configuration item's `metadata`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The plan ID to subscribe to. You may specify the same ID in `plan` and `price`.
sig { returns(T.nilable(String)) }
attr_accessor :plan
# The ID of the price object.
sig { returns(T.nilable(String)) }
attr_accessor :price
# Data used to generate a new [Price](https://stripe.com/docs/api/prices) object inline.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::UpdateParams::Phase::Item::PriceData))
}
attr_accessor :price_data
# Quantity for the given price. Can be set only if the price's `usage_type` is `licensed` and not `metered`.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will override the [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates) on the Subscription. When updating, pass an empty string to remove previously-defined tax rates.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :tax_rates
# Options that configure the trial on the subscription item.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::UpdateParams::Phase::Item::Trial))
}
attr_accessor :trial
sig {
params(billing_thresholds: T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionScheduleService::UpdateParams::Phase::Item::BillingThresholds))), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::SubscriptionScheduleService::UpdateParams::Phase::Item::Discount]))), metadata: T.nilable(T::Hash[String, String]), plan: T.nilable(String), price: T.nilable(String), price_data: T.nilable(::Stripe::SubscriptionScheduleService::UpdateParams::Phase::Item::PriceData), quantity: T.nilable(Integer), tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String]))), trial: T.nilable(::Stripe::SubscriptionScheduleService::UpdateParams::Phase::Item::Trial)).void
}
def initialize(
billing_thresholds: nil,
discounts: nil,
metadata: nil,
plan: nil,
price: nil,
price_data: nil,
quantity: nil,
tax_rates: nil,
trial: nil
); end
end
class PauseCollection < Stripe::RequestParams
# The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`.
sig { returns(String) }
attr_accessor :behavior
sig { params(behavior: String).void }
def initialize(behavior: nil); end
end
class TransferData < Stripe::RequestParams
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the destination account. By default, the entire amount is transferred to the destination.
sig { returns(T.nilable(Float)) }
attr_accessor :amount_percent
# ID of an existing, connected Stripe account.
sig { returns(String) }
attr_accessor :destination
sig { params(amount_percent: T.nilable(Float), destination: String).void }
def initialize(amount_percent: nil, destination: nil); end
end
class TrialSettings < Stripe::RequestParams
class EndBehavior < Stripe::RequestParams
# Configure how an opt-in following a paid trial is billed when using `billing_behavior: prorate_up_front`.
sig { returns(T.nilable(String)) }
attr_accessor :prorate_up_front
sig { params(prorate_up_front: T.nilable(String)).void }
def initialize(prorate_up_front: nil); end
end
# Defines how the subscription should behave when a trial ends.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::UpdateParams::Phase::TrialSettings::EndBehavior))
}
attr_accessor :end_behavior
sig {
params(end_behavior: T.nilable(::Stripe::SubscriptionScheduleService::UpdateParams::Phase::TrialSettings::EndBehavior)).void
}
def initialize(end_behavior: nil); end
end
# A list of prices and quantities that will generate invoice items appended to the next invoice for this phase. You may pass up to 20 items.
sig {
returns(T.nilable(T::Array[::Stripe::SubscriptionScheduleService::UpdateParams::Phase::AddInvoiceItem]))
}
attr_accessor :add_invoice_items
# A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account. The request must be made by a platform account on a connected account in order to set an application fee percentage. For more information, see the application fees [documentation](https://stripe.com/docs/connect/subscriptions#collecting-fees-on-subscriptions).
sig { returns(T.nilable(Float)) }
attr_accessor :application_fee_percent
# Automatic tax settings for this phase.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::UpdateParams::Phase::AutomaticTax))
}
attr_accessor :automatic_tax
# Can be set to `phase_start` to set the anchor to the start of the phase or `automatic` to automatically change it if needed. Cannot be set to `phase_start` if this phase specifies a trial. For more information, see the billing cycle [documentation](https://stripe.com/docs/billing/subscriptions/billing-cycle).
sig { returns(T.nilable(String)) }
attr_accessor :billing_cycle_anchor
# Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period. Pass an empty string to remove previously-defined thresholds.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionScheduleService::UpdateParams::Phase::BillingThresholds))))
}
attr_accessor :billing_thresholds
# Either `charge_automatically`, or `send_invoice`. When charging automatically, Stripe will attempt to pay the underlying subscription at the end of each billing cycle using the default source attached to the customer. When sending an invoice, Stripe will email your customer an invoice with payment instructions and mark the subscription as `active`. Defaults to `charge_automatically` on creation.
sig { returns(T.nilable(String)) }
attr_accessor :collection_method
# 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).
sig { returns(T.nilable(String)) }
attr_accessor :currency
# ID of the default payment method for the subscription schedule. It must belong to the customer associated with the subscription schedule. If not set, invoices will use the default payment method in the customer's invoice settings.
sig { returns(T.nilable(String)) }
attr_accessor :default_payment_method
# A list of [Tax Rate](https://stripe.com/docs/api/tax_rates) ids. These Tax Rates will set the Subscription's [`default_tax_rates`](https://stripe.com/docs/api/subscriptions/create#create_subscription-default_tax_rates), which means they will be the Invoice's [`default_tax_rates`](https://stripe.com/docs/api/invoices/create#create_invoice-default_tax_rates) for any Invoices issued by the Subscription during this Phase.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :default_tax_rates
# Subscription description, meant to be displayable to the customer. Use this field to optionally store an explanation of the subscription for rendering in Stripe surfaces and certain local payment methods UIs.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :description
# The coupons to redeem into discounts for the schedule phase. If not specified, inherits the discount from the subscription's customer. Pass an empty string to avoid inheriting any discounts.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::SubscriptionScheduleService::UpdateParams::Phase::Discount]))))
}
attr_accessor :discounts
# The date at which this phase of the subscription schedule ends. If set, `iterations` must not be set.
sig { returns(T.nilable(T.any(Integer, String))) }
attr_accessor :end_date
# All invoices will be billed using the specified settings.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::UpdateParams::Phase::InvoiceSettings))
}
attr_accessor :invoice_settings
# List of configuration items, each with an attached price, to apply during this phase of the subscription schedule.
sig { returns(T::Array[::Stripe::SubscriptionScheduleService::UpdateParams::Phase::Item]) }
attr_accessor :items
# Integer representing the multiplier applied to the price interval. For example, `iterations=2` applied to a price with `interval=month` and `interval_count=3` results in a phase of duration `2 * 3 months = 6 months`. If set, `end_date` must not be set.
sig { returns(T.nilable(Integer)) }
attr_accessor :iterations
# Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to a phase. Metadata on a schedule's phase will update the underlying subscription's `metadata` when the phase is entered, adding new keys and replacing existing keys in the subscription's `metadata`. Individual keys in the subscription's `metadata` can be unset by posting an empty value to them in the phase's `metadata`. To unset all keys in the subscription's `metadata`, update the subscription directly or unset every key individually from the phase's `metadata`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The account on behalf of which to charge, for each of the associated subscription's invoices.
sig { returns(T.nilable(String)) }
attr_accessor :on_behalf_of
# If specified, payment collection for this subscription will be paused. Note that the subscription status will be unchanged and will not be updated to `paused`. Learn more about [pausing collection](https://stripe.com/docs/billing/subscriptions/pause-payment).
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::UpdateParams::Phase::PauseCollection))
}
attr_accessor :pause_collection
# Controls whether the subscription schedule should create [prorations](https://stripe.com/docs/billing/subscriptions/prorations) when transitioning to this phase if there is a difference in billing configuration. 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 (item price, quantity, etc.) of the current phase.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
# The date at which this phase of the subscription schedule starts or `now`. Must be set on the first phase.
sig { returns(T.nilable(T.any(Integer, String))) }
attr_accessor :start_date
# The data with which to automatically create a Transfer for each of the associated subscription's invoices.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::UpdateParams::Phase::TransferData))
}
attr_accessor :transfer_data
# If set to true the entire phase is counted as a trial and the customer will not be charged for any fees.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :trial
# Specify trial behavior when crossing phase boundaries
sig { returns(T.nilable(String)) }
attr_accessor :trial_continuation
# Sets the phase to trialing from the start date to this date. Must be before the phase end date, can not be combined with `trial`
sig { returns(T.nilable(T.any(Integer, String))) }
attr_accessor :trial_end
# Settings related to subscription trials.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::UpdateParams::Phase::TrialSettings))
}
attr_accessor :trial_settings
sig {
params(add_invoice_items: T.nilable(T::Array[::Stripe::SubscriptionScheduleService::UpdateParams::Phase::AddInvoiceItem]), application_fee_percent: T.nilable(Float), automatic_tax: T.nilable(::Stripe::SubscriptionScheduleService::UpdateParams::Phase::AutomaticTax), billing_cycle_anchor: T.nilable(String), billing_thresholds: T.nilable(T.nilable(T.any(String, ::Stripe::SubscriptionScheduleService::UpdateParams::Phase::BillingThresholds))), collection_method: T.nilable(String), currency: T.nilable(String), default_payment_method: T.nilable(String), default_tax_rates: T.nilable(T.nilable(T.any(String, T::Array[String]))), description: T.nilable(T.nilable(String)), discounts: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::SubscriptionScheduleService::UpdateParams::Phase::Discount]))), end_date: T.nilable(T.any(Integer, String)), invoice_settings: T.nilable(::Stripe::SubscriptionScheduleService::UpdateParams::Phase::InvoiceSettings), items: T::Array[::Stripe::SubscriptionScheduleService::UpdateParams::Phase::Item], iterations: T.nilable(Integer), metadata: T.nilable(T::Hash[String, String]), on_behalf_of: T.nilable(String), pause_collection: T.nilable(::Stripe::SubscriptionScheduleService::UpdateParams::Phase::PauseCollection), proration_behavior: T.nilable(String), start_date: T.nilable(T.any(Integer, String)), transfer_data: T.nilable(::Stripe::SubscriptionScheduleService::UpdateParams::Phase::TransferData), trial: T.nilable(T::Boolean), trial_continuation: T.nilable(String), trial_end: T.nilable(T.any(Integer, String)), trial_settings: T.nilable(::Stripe::SubscriptionScheduleService::UpdateParams::Phase::TrialSettings)).void
}
def initialize(
add_invoice_items: nil,
application_fee_percent: nil,
automatic_tax: nil,
billing_cycle_anchor: nil,
billing_thresholds: nil,
collection_method: nil,
currency: nil,
default_payment_method: nil,
default_tax_rates: nil,
description: nil,
discounts: nil,
end_date: nil,
invoice_settings: nil,
items: nil,
iterations: nil,
metadata: nil,
on_behalf_of: nil,
pause_collection: nil,
proration_behavior: nil,
start_date: nil,
transfer_data: nil,
trial: nil,
trial_continuation: nil,
trial_end: nil,
trial_settings: nil
); end
end
class Prebilling < Stripe::RequestParams
# This is used to determine the number of billing cycles to prebill.
sig { returns(Integer) }
attr_accessor :iterations
# Whether to cancel or preserve `prebilling` if the subscription is updated during the prebilled period. The default value is `reset`.
sig { returns(T.nilable(String)) }
attr_accessor :update_behavior
sig { params(iterations: Integer, update_behavior: T.nilable(String)).void }
def initialize(iterations: nil, update_behavior: nil); end
end
# Configures when the subscription schedule generates prorations for phase transitions. Possible values are `prorate_on_next_phase` or `prorate_up_front` with the default being `prorate_on_next_phase`. `prorate_on_next_phase` will apply phase changes and generate prorations at transition time. `prorate_up_front` will bill for all phases within the current billing cycle up front.
sig { returns(T.nilable(String)) }
attr_accessor :billing_behavior
# Object representing the subscription schedule's default settings.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::UpdateParams::DefaultSettings))
}
attr_accessor :default_settings
# Behavior of the subscription schedule and underlying subscription when it ends. Possible values are `release` or `cancel` with the default being `release`. `release` will end the subscription schedule and keep the underlying subscription running. `cancel` will end the subscription schedule and cancel the underlying subscription.
sig { returns(T.nilable(String)) }
attr_accessor :end_behavior
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# List representing phases of the subscription schedule. Each phase can be customized to have different durations, plans, and coupons. If there are multiple phases, the `end_date` of one phase will always equal the `start_date` of the next phase. Note that past phases can be omitted.
sig {
returns(T.nilable(T::Array[::Stripe::SubscriptionScheduleService::UpdateParams::Phase]))
}
attr_accessor :phases
# If specified, the invoicing for the given billing cycle iterations will be processed now.
sig { returns(T.nilable(::Stripe::SubscriptionScheduleService::UpdateParams::Prebilling)) }
attr_accessor :prebilling
# If the update changes the billing configuration (item price, quantity, etc.) of the current phase, indicates how prorations from this change should be handled. The default value is `create_prorations`.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
sig {
params(billing_behavior: T.nilable(String), default_settings: T.nilable(::Stripe::SubscriptionScheduleService::UpdateParams::DefaultSettings), end_behavior: T.nilable(String), expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), phases: T.nilable(T::Array[::Stripe::SubscriptionScheduleService::UpdateParams::Phase]), prebilling: T.nilable(::Stripe::SubscriptionScheduleService::UpdateParams::Prebilling), proration_behavior: T.nilable(String)).void
}
def initialize(
billing_behavior: nil,
default_settings: nil,
end_behavior: nil,
expand: nil,
metadata: nil,
phases: nil,
prebilling: nil,
proration_behavior: nil
); end
end
class AmendParams < Stripe::RequestParams
class Amendment < Stripe::RequestParams
class AmendmentEnd < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
# The ID of a specific discount.
sig { returns(String) }
attr_accessor :discount
sig { params(discount: String).void }
def initialize(discount: nil); end
end
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Use the `end` time of a given discount.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Amendment::AmendmentEnd::DiscountEnd))
}
attr_accessor :discount_end
# Time span for the amendment starting from the `amendment_start`.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Amendment::AmendmentEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the amendment to end. Must be after the `amendment_start`.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# Select one of three ways to pass the `amendment_end`.
sig { returns(String) }
attr_accessor :type
sig {
params(discount_end: T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Amendment::AmendmentEnd::DiscountEnd), duration: T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Amendment::AmendmentEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(discount_end: nil, duration: nil, timestamp: nil, type: nil); end
end
class AmendmentStart < Stripe::RequestParams
class AmendmentEnd < Stripe::RequestParams
# The position of the previous amendment in the `amendments` array after which this amendment should begin. Indexes start from 0 and must be less than the index of the current amendment in the array.
sig { returns(Integer) }
attr_accessor :index
sig { params(index: Integer).void }
def initialize(index: nil); end
end
class DiscountEnd < Stripe::RequestParams
# The ID of a specific discount.
sig { returns(String) }
attr_accessor :discount
sig { params(discount: String).void }
def initialize(discount: nil); end
end
# Details of another amendment in the same array, immediately after which this amendment should begin.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Amendment::AmendmentStart::AmendmentEnd))
}
attr_accessor :amendment_end
# Use the `end` time of a given discount.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Amendment::AmendmentStart::DiscountEnd))
}
attr_accessor :discount_end
# A precise Unix timestamp for the amendment to start.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# Select one of three ways to pass the `amendment_start`.
sig { returns(String) }
attr_accessor :type
sig {
params(amendment_end: T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Amendment::AmendmentStart::AmendmentEnd), discount_end: T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Amendment::AmendmentStart::DiscountEnd), timestamp: T.nilable(Integer), type: String).void
}
def initialize(amendment_end: nil, discount_end: nil, timestamp: nil, type: nil); end
end
class DiscountAction < Stripe::RequestParams
class Add < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
# The coupon code to redeem.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# An ID of an existing discount for a coupon that was already redeemed.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Amendment::DiscountAction::Add::DiscountEnd))
}
attr_accessor :discount_end
# The index, starting at 0, at which to position the new discount. When not supplied, Stripe defaults to appending the discount to the end of the `discounts` array.
sig { returns(T.nilable(Integer)) }
attr_accessor :index
# The promotion code to redeem.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Amendment::DiscountAction::Add::DiscountEnd), index: T.nilable(Integer), promotion_code: T.nilable(String)).void
}
def initialize(
coupon: nil,
discount: nil,
discount_end: nil,
index: nil,
promotion_code: nil
); end
end
class Remove < Stripe::RequestParams
# The coupon code to remove from the `discounts` array.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# The ID of a discount to remove from the `discounts` array.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# The ID of a promotion code to remove from the `discounts` array.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, promotion_code: nil); end
end
class Set < Stripe::RequestParams
# The coupon code to replace the `discounts` array with.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# An ID of an existing discount to replace the `discounts` array with.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# An ID of an existing promotion code to replace the `discounts` array with.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), promotion_code: T.nilable(String)).void
}
def initialize(coupon: nil, discount: nil, promotion_code: nil); end
end
# Details of the discount to add.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Amendment::DiscountAction::Add))
}
attr_accessor :add
# Details of the discount to remove.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Amendment::DiscountAction::Remove))
}
attr_accessor :remove
# Details of the discount to replace the existing discounts with.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Amendment::DiscountAction::Set))
}
attr_accessor :set
# Determines the type of discount action.
sig { returns(String) }
attr_accessor :type
sig {
params(add: T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Amendment::DiscountAction::Add), remove: T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Amendment::DiscountAction::Remove), set: T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Amendment::DiscountAction::Set), type: String).void
}
def initialize(add: nil, remove: nil, set: nil, type: nil); end
end
class ItemAction < Stripe::RequestParams
class Add < Stripe::RequestParams
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Amendment::ItemAction::Add::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Amendment::ItemAction::Add::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Amendment::ItemAction::Add::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Amendment::ItemAction::Add::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(
coupon: nil,
discount: nil,
discount_end: nil,
promotion_code: nil
); end
end
class Trial < Stripe::RequestParams
# List of price IDs which, if present on the subscription following a paid trial, constitute opting-in to the paid trial. Currently only supports at most 1 price ID.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :converts_to
# Determines the type of trial for this item.
sig { returns(String) }
attr_accessor :type
sig { params(converts_to: T.nilable(T::Array[String]), type: String).void }
def initialize(converts_to: nil, type: nil); end
end
# The discounts applied to the item. Subscription item discounts are applied before subscription discounts.
sig {
returns(T.nilable(T::Array[::Stripe::SubscriptionScheduleService::AmendParams::Amendment::ItemAction::Add::Discount]))
}
attr_accessor :discounts
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The ID of the price object.
sig { returns(String) }
attr_accessor :price
# Quantity for this item.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# The tax rates that apply to this subscription item. When set, the `default_tax_rates` on the subscription do not apply to this `subscription_item`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :tax_rates
# Options that configure the trial on the subscription item.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Amendment::ItemAction::Add::Trial))
}
attr_accessor :trial
sig {
params(discounts: T.nilable(T::Array[::Stripe::SubscriptionScheduleService::AmendParams::Amendment::ItemAction::Add::Discount]), metadata: T.nilable(T::Hash[String, String]), price: String, quantity: T.nilable(Integer), tax_rates: T.nilable(T::Array[String]), trial: T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Amendment::ItemAction::Add::Trial)).void
}
def initialize(
discounts: nil,
metadata: nil,
price: nil,
quantity: nil,
tax_rates: nil,
trial: nil
); end
end
class Remove < Stripe::RequestParams
# ID of a price to remove.
sig { returns(String) }
attr_accessor :price
sig { params(price: String).void }
def initialize(price: nil); end
end
class Set < Stripe::RequestParams
class Discount < Stripe::RequestParams
class DiscountEnd < Stripe::RequestParams
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# Time span for the redeemed discount.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Amendment::ItemAction::Set::Discount::DiscountEnd::Duration))
}
attr_accessor :duration
# A precise Unix timestamp for the discount to end. Must be in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# The type of calculation made to determine when the discount ends.
sig { returns(String) }
attr_accessor :type
sig {
params(duration: T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Amendment::ItemAction::Set::Discount::DiscountEnd::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(duration: nil, timestamp: nil, type: nil); end
end
# ID of the coupon to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :coupon
# ID of an existing discount on the object (or one of its ancestors) to reuse.
sig { returns(T.nilable(String)) }
attr_accessor :discount
# Details to determine how long the discount should be applied for.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Amendment::ItemAction::Set::Discount::DiscountEnd))
}
attr_accessor :discount_end
# ID of the promotion code to create a new discount for.
sig { returns(T.nilable(String)) }
attr_accessor :promotion_code
sig {
params(coupon: T.nilable(String), discount: T.nilable(String), discount_end: T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Amendment::ItemAction::Set::Discount::DiscountEnd), promotion_code: T.nilable(String)).void
}
def initialize(
coupon: nil,
discount: nil,
discount_end: nil,
promotion_code: nil
); end
end
class Trial < Stripe::RequestParams
# List of price IDs which, if present on the subscription following a paid trial, constitute opting-in to the paid trial. Currently only supports at most 1 price ID.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :converts_to
# Determines the type of trial for this item.
sig { returns(String) }
attr_accessor :type
sig { params(converts_to: T.nilable(T::Array[String]), type: String).void }
def initialize(converts_to: nil, type: nil); end
end
# If an item with the `price` already exists, passing this will override the `discounts` array on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `discounts`.
sig {
returns(T.nilable(T::Array[::Stripe::SubscriptionScheduleService::AmendParams::Amendment::ItemAction::Set::Discount]))
}
attr_accessor :discounts
# If an item with the `price` already exists, passing this will override the `metadata` on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `metadata`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The ID of the price object.
sig { returns(String) }
attr_accessor :price
# If an item with the `price` already exists, passing this will override the quantity on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `quantity`.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# If an item with the `price` already exists, passing this will override the `tax_rates` array on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `tax_rates`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :tax_rates
# If an item with the `price` already exists, passing this will override the `trial` configuration on the subscription item that matches that price. Otherwise, the `items` array is cleared and a single new item is added with the supplied `trial`.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Amendment::ItemAction::Set::Trial))
}
attr_accessor :trial
sig {
params(discounts: T.nilable(T::Array[::Stripe::SubscriptionScheduleService::AmendParams::Amendment::ItemAction::Set::Discount]), metadata: T.nilable(T::Hash[String, String]), price: String, quantity: T.nilable(Integer), tax_rates: T.nilable(T::Array[String]), trial: T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Amendment::ItemAction::Set::Trial)).void
}
def initialize(
discounts: nil,
metadata: nil,
price: nil,
quantity: nil,
tax_rates: nil,
trial: nil
); end
end
# Details of the subscription item to add. If an item with the same `price` exists, it will be replaced by this new item. Otherwise, it adds the new item.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Amendment::ItemAction::Add))
}
attr_accessor :add
# Details of the subscription item to remove.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Amendment::ItemAction::Remove))
}
attr_accessor :remove
# Details of the subscription item to replace the existing items with. If an item with the `set[price]` already exists, the `items` array is not cleared. Instead, all of the other `set` properties that are passed in this request will replace the existing values for the configuration item.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Amendment::ItemAction::Set))
}
attr_accessor :set
# Determines the type of item action.
sig { returns(String) }
attr_accessor :type
sig {
params(add: T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Amendment::ItemAction::Add), remove: T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Amendment::ItemAction::Remove), set: T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Amendment::ItemAction::Set), type: String).void
}
def initialize(add: nil, remove: nil, set: nil, type: nil); end
end
class MetadataAction < Stripe::RequestParams
# Key-value pairs to add to schedule phase metadata. These values will merge with existing schedule phase metadata.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :add
# Keys to remove from schedule phase metadata.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :remove
# Key-value pairs to set as schedule phase metadata. Existing schedule phase metadata will be overwritten.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :set
# Select one of three ways to update phase-level `metadata` on subscription schedules.
sig { returns(String) }
attr_accessor :type
sig {
params(add: T.nilable(T::Hash[String, String]), remove: T.nilable(T::Array[String]), set: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), type: String).void
}
def initialize(add: nil, remove: nil, set: nil, type: nil); end
end
class SetPauseCollection < Stripe::RequestParams
class Set < Stripe::RequestParams
# The payment collection behavior for this subscription while paused. One of `keep_as_draft`, `mark_uncollectible`, or `void`.
sig { returns(String) }
attr_accessor :behavior
sig { params(behavior: String).void }
def initialize(behavior: nil); end
end
# Details of the pause_collection behavior to apply to the amendment.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Amendment::SetPauseCollection::Set))
}
attr_accessor :set
# Determines the type of the pause_collection amendment.
sig { returns(String) }
attr_accessor :type
sig {
params(set: T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Amendment::SetPauseCollection::Set), type: String).void
}
def initialize(set: nil, type: nil); end
end
class TrialSettings < Stripe::RequestParams
class EndBehavior < Stripe::RequestParams
# Configure how an opt-in following a paid trial is billed when using `billing_behavior: prorate_up_front`.
sig { returns(T.nilable(String)) }
attr_accessor :prorate_up_front
sig { params(prorate_up_front: T.nilable(String)).void }
def initialize(prorate_up_front: nil); end
end
# Defines how the subscription should behave when a trial ends.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Amendment::TrialSettings::EndBehavior))
}
attr_accessor :end_behavior
sig {
params(end_behavior: T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Amendment::TrialSettings::EndBehavior)).void
}
def initialize(end_behavior: nil); end
end
# Details to identify the end of the time range modified by the proposed change. If not supplied, the amendment is considered a point-in-time operation that only affects the exact timestamp at `amendment_start`, and a restricted set of attributes is supported on the amendment.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Amendment::AmendmentEnd))
}
attr_accessor :amendment_end
# Details to identify the earliest timestamp where the proposed change should take effect.
sig {
returns(::Stripe::SubscriptionScheduleService::AmendParams::Amendment::AmendmentStart)
}
attr_accessor :amendment_start
# For point-in-time amendments (having no `amendment_end`), this attribute lets you set or remove whether the subscription's billing cycle anchor is reset at the `amendment_start` timestamp.For time-span based amendments (having both `amendment_start` and `amendment_end`), the only value valid is `automatic`, which removes any previously configured billing cycle anchor resets scheduled to occur during the window of time spanned by the amendment.
sig { returns(T.nilable(String)) }
attr_accessor :billing_cycle_anchor
# Changes to the coupons being redeemed or discounts being applied during the amendment time span.
sig {
returns(T.nilable(T::Array[::Stripe::SubscriptionScheduleService::AmendParams::Amendment::DiscountAction]))
}
attr_accessor :discount_actions
# Changes to the subscription items during the amendment time span.
sig {
returns(T.nilable(T::Array[::Stripe::SubscriptionScheduleService::AmendParams::Amendment::ItemAction]))
}
attr_accessor :item_actions
# Instructions for how to modify phase metadata
sig {
returns(T.nilable(T::Array[::Stripe::SubscriptionScheduleService::AmendParams::Amendment::MetadataAction]))
}
attr_accessor :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`.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
# Defines how to pause collection for the underlying subscription throughout the duration of the amendment.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Amendment::SetPauseCollection))
}
attr_accessor :set_pause_collection
# Ends the subscription schedule early as dictated by either the accompanying amendment's start or end.
sig { returns(T.nilable(String)) }
attr_accessor :set_schedule_end
# Settings related to subscription trials.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Amendment::TrialSettings))
}
attr_accessor :trial_settings
sig {
params(amendment_end: T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Amendment::AmendmentEnd), amendment_start: ::Stripe::SubscriptionScheduleService::AmendParams::Amendment::AmendmentStart, billing_cycle_anchor: T.nilable(String), discount_actions: T.nilable(T::Array[::Stripe::SubscriptionScheduleService::AmendParams::Amendment::DiscountAction]), item_actions: T.nilable(T::Array[::Stripe::SubscriptionScheduleService::AmendParams::Amendment::ItemAction]), metadata_actions: T.nilable(T::Array[::Stripe::SubscriptionScheduleService::AmendParams::Amendment::MetadataAction]), proration_behavior: T.nilable(String), set_pause_collection: T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Amendment::SetPauseCollection), set_schedule_end: T.nilable(String), trial_settings: T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Amendment::TrialSettings)).void
}
def initialize(
amendment_end: nil,
amendment_start: nil,
billing_cycle_anchor: nil,
discount_actions: nil,
item_actions: nil,
metadata_actions: nil,
proration_behavior: nil,
set_pause_collection: nil,
set_schedule_end: nil,
trial_settings: nil
); end
end
class Prebilling < Stripe::RequestParams
class BillFrom < Stripe::RequestParams
class AmendmentStart < Stripe::RequestParams
# The position of the amendment in the `amendments` array with which prebilling should begin. Indexes start from 0 and must be less than the total number of supplied amendments.
sig { returns(Integer) }
attr_accessor :index
sig { params(index: Integer).void }
def initialize(index: nil); end
end
# Start the prebilled period when a specified amendment begins.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Prebilling::BillFrom::AmendmentStart))
}
attr_accessor :amendment_start
# Start the prebilled period at a precise integer timestamp, starting from the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# Select one of several ways to pass the `bill_from` value.
sig { returns(String) }
attr_accessor :type
sig {
params(amendment_start: T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Prebilling::BillFrom::AmendmentStart), timestamp: T.nilable(Integer), type: String).void
}
def initialize(amendment_start: nil, timestamp: nil, type: nil); end
end
class BillUntil < Stripe::RequestParams
class AmendmentEnd < Stripe::RequestParams
# The position of the amendment in the `amendments` array at which prebilling should end. Indexes start from 0 and must be less than the total number of supplied amendments.
sig { returns(Integer) }
attr_accessor :index
sig { params(index: Integer).void }
def initialize(index: nil); end
end
class Duration < Stripe::RequestParams
# Specifies a type of interval unit. Either `day`, `week`, `month` or `year`.
sig { returns(String) }
attr_accessor :interval
# The number of intervals, as an whole number greater than 0. Stripe multiplies this by the interval type to get the overall duration.
sig { returns(Integer) }
attr_accessor :interval_count
sig { params(interval: String, interval_count: Integer).void }
def initialize(interval: nil, interval_count: nil); end
end
# End the prebilled period when a specified amendment ends.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Prebilling::BillUntil::AmendmentEnd))
}
attr_accessor :amendment_end
# Time span for prebilling, starting from `bill_from`.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Prebilling::BillUntil::Duration))
}
attr_accessor :duration
# End the prebilled period at a precise integer timestamp, starting from the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :timestamp
# Select one of several ways to pass the `bill_until` value.
sig { returns(String) }
attr_accessor :type
sig {
params(amendment_end: T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Prebilling::BillUntil::AmendmentEnd), duration: T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Prebilling::BillUntil::Duration), timestamp: T.nilable(Integer), type: String).void
}
def initialize(amendment_end: nil, duration: nil, timestamp: nil, type: nil); end
end
# The beginning of the prebilled time period. The default value is `now`.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Prebilling::BillFrom))
}
attr_accessor :bill_from
# The end of the prebilled time period.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Prebilling::BillUntil))
}
attr_accessor :bill_until
# When the prebilling invoice should be created. The default value is `now`.
sig { returns(T.nilable(String)) }
attr_accessor :invoice_at
# Whether to cancel or preserve `prebilling` if the subscription is updated during the prebilled period. The default value is `reset`.
sig { returns(T.nilable(String)) }
attr_accessor :update_behavior
sig {
params(bill_from: T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Prebilling::BillFrom), bill_until: T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::Prebilling::BillUntil), invoice_at: T.nilable(String), update_behavior: T.nilable(String)).void
}
def initialize(bill_from: nil, bill_until: nil, invoice_at: nil, update_behavior: nil); end
end
class ScheduleSettings < Stripe::RequestParams
# Behavior of the subscription schedule and underlying subscription when it ends.
sig { returns(T.nilable(String)) }
attr_accessor :end_behavior
sig { params(end_behavior: T.nilable(String)).void }
def initialize(end_behavior: nil); end
end
# Changes to apply to the phases of the subscription schedule, in the order provided.
sig {
returns(T.nilable(T::Array[::Stripe::SubscriptionScheduleService::AmendParams::Amendment]))
}
attr_accessor :amendments
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Provide any time periods to bill in advance.
sig {
returns(T.nilable(T.nilable(T.any(String, T::Array[::Stripe::SubscriptionScheduleService::AmendParams::Prebilling]))))
}
attr_accessor :prebilling
# In cases where the amendment changes the currently active phase,
# specifies if and how to prorate at the time of the request.
sig { returns(T.nilable(String)) }
attr_accessor :proration_behavior
# Changes to apply to the subscription schedule.
sig {
returns(T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::ScheduleSettings))
}
attr_accessor :schedule_settings
sig {
params(amendments: T.nilable(T::Array[::Stripe::SubscriptionScheduleService::AmendParams::Amendment]), expand: T.nilable(T::Array[String]), prebilling: T.nilable(T.nilable(T.any(String, T::Array[::Stripe::SubscriptionScheduleService::AmendParams::Prebilling]))), proration_behavior: T.nilable(String), schedule_settings: T.nilable(::Stripe::SubscriptionScheduleService::AmendParams::ScheduleSettings)).void
}
def initialize(
amendments: nil,
expand: nil,
prebilling: nil,
proration_behavior: nil,
schedule_settings: nil
); end
end
class CancelParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# If the subscription schedule is `active`, indicates if a final invoice will be generated that contains any un-invoiced metered usage and new/pending proration invoice items. Defaults to `true`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :invoice_now
# If the subscription schedule is `active`, indicates if the cancellation should be prorated. Defaults to `true`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :prorate
sig {
params(expand: T.nilable(T::Array[String]), invoice_now: T.nilable(T::Boolean), prorate: T.nilable(T::Boolean)).void
}
def initialize(expand: nil, invoice_now: nil, prorate: nil); end
end
class ReleaseParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Keep any cancellation on the subscription that the schedule has set
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :preserve_cancel_date
sig {
params(expand: T.nilable(T::Array[String]), preserve_cancel_date: T.nilable(T::Boolean)).void
}
def initialize(expand: nil, preserve_cancel_date: nil); end
end
# Amends an existing subscription schedule.
sig {
params(schedule: String, params: T.any(::Stripe::SubscriptionScheduleService::AmendParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SubscriptionSchedule)
}
def amend(schedule, params = {}, opts = {}); end
# Cancels a subscription schedule and its associated subscription immediately (if the subscription schedule has an active subscription). A subscription schedule can only be canceled if its status is not_started or active.
sig {
params(schedule: String, params: T.any(::Stripe::SubscriptionScheduleService::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SubscriptionSchedule)
}
def cancel(schedule, params = {}, opts = {}); end
# Creates a new subscription schedule object. Each customer can have up to 500 active or scheduled subscriptions.
sig {
params(params: T.any(::Stripe::SubscriptionScheduleService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SubscriptionSchedule)
}
def create(params = {}, opts = {}); end
# Retrieves the list of your subscription schedules.
sig {
params(params: T.any(::Stripe::SubscriptionScheduleService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Releases the subscription schedule immediately, which will stop scheduling of its phases, but leave any existing subscription in place. A schedule can only be released if its status is not_started or active. If the subscription schedule is currently associated with a subscription, releasing it will remove its subscription property and set the subscription's ID to the released_subscription property.
sig {
params(schedule: String, params: T.any(::Stripe::SubscriptionScheduleService::ReleaseParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SubscriptionSchedule)
}
def release(schedule, params = {}, opts = {}); end
# Retrieves the details of an existing subscription schedule. You only need to supply the unique subscription schedule identifier that was returned upon subscription schedule creation.
sig {
params(schedule: String, params: T.any(::Stripe::SubscriptionScheduleService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SubscriptionSchedule)
}
def retrieve(schedule, params = {}, opts = {}); end
# Updates an existing subscription schedule.
sig {
params(schedule: String, params: T.any(::Stripe::SubscriptionScheduleService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::SubscriptionSchedule)
}
def update(schedule, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class TaxService < StripeService
attr_reader :associations
attr_reader :calculations
attr_reader :forms
attr_reader :registrations
attr_reader :settings
attr_reader :transactions
end
end
# typed: true
module Stripe
module Tax
class AssociationService < StripeService
class FindParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Valid [PaymentIntent](https://stripe.com/docs/api/payment_intents/object) id
sig { returns(String) }
attr_accessor :payment_intent
sig { params(expand: T.nilable(T::Array[String]), payment_intent: String).void }
def initialize(expand: nil, payment_intent: nil); end
end
# Finds a tax association object by PaymentIntent id.
sig {
params(params: T.any(::Stripe::Tax::AssociationService::FindParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Tax::Association)
}
def find(params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Tax
class CalculationService < StripeService
attr_reader :line_items
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class CreateParams < Stripe::RequestParams
class CustomerDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(String) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :postal_code
# State, county, province, or region. We recommend sending [ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2) subdivision code value when possible.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :state
sig {
params(city: T.nilable(T.nilable(String)), country: String, line1: T.nilable(T.nilable(String)), line2: T.nilable(T.nilable(String)), postal_code: T.nilable(T.nilable(String)), state: T.nilable(T.nilable(String))).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class TaxId < Stripe::RequestParams
# Type of the tax ID, one of `ad_nrt`, `ae_trn`, `al_tin`, `am_tin`, `ao_tin`, `ar_cuit`, `au_abn`, `au_arn`, `aw_tin`, `az_tin`, `ba_tin`, `bb_tin`, `bd_bin`, `bf_ifu`, `bg_uic`, `bh_vat`, `bj_ifu`, `bo_tin`, `br_cnpj`, `br_cpf`, `bs_tin`, `by_tin`, `ca_bn`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `ca_qst`, `cd_nif`, `ch_uid`, `ch_vat`, `cl_tin`, `cm_niu`, `cn_tin`, `co_nit`, `cr_tin`, `cv_nif`, `de_stn`, `do_rcn`, `ec_ruc`, `eg_tin`, `es_cif`, `et_tin`, `eu_oss_vat`, `eu_vat`, `gb_vat`, `ge_vat`, `gn_nif`, `hk_br`, `hr_oib`, `hu_tin`, `id_npwp`, `il_vat`, `in_gst`, `is_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `ke_pin`, `kg_tin`, `kh_tin`, `kr_brn`, `kz_bin`, `la_tin`, `li_uid`, `li_vat`, `ma_vat`, `md_vat`, `me_pib`, `mk_vat`, `mr_nif`, `mx_rfc`, `my_frp`, `my_itn`, `my_sst`, `ng_tin`, `no_vat`, `no_voec`, `np_pan`, `nz_gst`, `om_vat`, `pe_ruc`, `ph_tin`, `ro_tin`, `rs_pib`, `ru_inn`, `ru_kpp`, `sa_vat`, `sg_gst`, `sg_uen`, `si_tin`, `sn_ninea`, `sr_fin`, `sv_nit`, `th_vat`, `tj_tin`, `tr_tin`, `tw_vat`, `tz_vat`, `ua_vat`, `ug_tin`, `us_ein`, `uy_ruc`, `uz_tin`, `uz_vat`, `ve_rif`, `vn_tin`, `za_vat`, `zm_tin`, or `zw_tin`
sig { returns(String) }
attr_accessor :type
# Value of the tax ID.
sig { returns(String) }
attr_accessor :value
sig { params(type: String, value: String).void }
def initialize(type: nil, value: nil); end
end
# The customer's postal address (for example, home or business location).
sig {
returns(T.nilable(::Stripe::Tax::CalculationService::CreateParams::CustomerDetails::Address))
}
attr_accessor :address
# The type of customer address provided.
sig { returns(T.nilable(String)) }
attr_accessor :address_source
# The customer's IP address (IPv4 or IPv6).
sig { returns(T.nilable(String)) }
attr_accessor :ip_address
# The customer's tax IDs. Stripe Tax might consider a transaction with applicable tax IDs to be B2B, which might affect the tax calculation result. Stripe Tax doesn't validate tax IDs for correctness.
sig {
returns(T.nilable(T::Array[::Stripe::Tax::CalculationService::CreateParams::CustomerDetails::TaxId]))
}
attr_accessor :tax_ids
# Overrides the tax calculation result to allow you to not collect tax from your customer. Use this if you've manually checked your customer's tax exemptions. Prefer providing the customer's `tax_ids` where possible, which automatically determines whether `reverse_charge` applies.
sig { returns(T.nilable(String)) }
attr_accessor :taxability_override
sig {
params(address: T.nilable(::Stripe::Tax::CalculationService::CreateParams::CustomerDetails::Address), address_source: T.nilable(String), ip_address: T.nilable(String), tax_ids: T.nilable(T::Array[::Stripe::Tax::CalculationService::CreateParams::CustomerDetails::TaxId]), taxability_override: T.nilable(String)).void
}
def initialize(
address: nil,
address_source: nil,
ip_address: nil,
tax_ids: nil,
taxability_override: nil
); end
end
class LineItem < Stripe::RequestParams
# A positive integer representing the line item's total price in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal).
# If `tax_behavior=inclusive`, then this amount includes taxes. Otherwise, taxes are calculated on top of this amount.
sig { returns(Integer) }
attr_accessor :amount
# 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.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# If provided, the product's `tax_code` will be used as the line item's `tax_code`.
sig { returns(T.nilable(String)) }
attr_accessor :product
# The number of units of the item being purchased. Used to calculate the per-unit price from the total `amount` for the line. For example, if `amount=100` and `quantity=4`, the calculated unit price is 25.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# A custom identifier for this line item, which must be unique across the line items in the calculation. The reference helps identify each line item in exported [tax reports](https://stripe.com/docs/tax/reports).
sig { returns(T.nilable(String)) }
attr_accessor :reference
# Specifies whether the `amount` includes taxes. Defaults to `exclusive`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID to use for this line item. If not provided, we will use the tax code from the provided `product` param. If neither `tax_code` nor `product` is provided, we will use the default tax code from your Tax Settings.
sig { returns(T.nilable(String)) }
attr_accessor :tax_code
sig {
params(amount: Integer, metadata: T.nilable(T::Hash[String, String]), product: T.nilable(String), quantity: T.nilable(Integer), reference: T.nilable(String), tax_behavior: T.nilable(String), tax_code: T.nilable(String)).void
}
def initialize(
amount: nil,
metadata: nil,
product: nil,
quantity: nil,
reference: nil,
tax_behavior: nil,
tax_code: nil
); end
end
class ShipFromDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(String) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :postal_code
# State/province as an [ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2) subdivision code, without country prefix. Example: "NY" or "TX".
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :state
sig {
params(city: T.nilable(T.nilable(String)), country: String, line1: T.nilable(T.nilable(String)), line2: T.nilable(T.nilable(String)), postal_code: T.nilable(T.nilable(String)), state: T.nilable(T.nilable(String))).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# The address from which the goods are being shipped from.
sig { returns(::Stripe::Tax::CalculationService::CreateParams::ShipFromDetails::Address) }
attr_accessor :address
sig {
params(address: ::Stripe::Tax::CalculationService::CreateParams::ShipFromDetails::Address).void
}
def initialize(address: nil); end
end
class ShippingCost < Stripe::RequestParams
# A positive integer in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) representing the shipping charge. If `tax_behavior=inclusive`, then this amount includes taxes. Otherwise, taxes are calculated on top of this amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# If provided, the [shipping rate](https://stripe.com/docs/api/shipping_rates/object)'s `amount`, `tax_code` and `tax_behavior` are used. If you provide a shipping rate, then you cannot pass the `amount`, `tax_code`, or `tax_behavior` parameters.
sig { returns(T.nilable(String)) }
attr_accessor :shipping_rate
# Specifies whether the `amount` includes taxes. If `tax_behavior=inclusive`, then the amount includes taxes. Defaults to `exclusive`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# The [tax code](https://stripe.com/docs/tax/tax-categories) used to calculate tax on shipping. If not provided, the default shipping tax code from your [Tax Settings](https://dashboard.stripe.com/settings/tax) is used.
sig { returns(T.nilable(String)) }
attr_accessor :tax_code
sig {
params(amount: T.nilable(Integer), shipping_rate: T.nilable(String), tax_behavior: T.nilable(String), tax_code: T.nilable(String)).void
}
def initialize(amount: nil, shipping_rate: nil, tax_behavior: nil, tax_code: nil); end
end
# 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).
sig { returns(String) }
attr_accessor :currency
# The ID of an existing customer to use for this calculation. If provided, the customer's address and tax IDs are copied to `customer_details`.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# Details about the customer, including address and tax IDs.
sig { returns(T.nilable(::Stripe::Tax::CalculationService::CreateParams::CustomerDetails)) }
attr_accessor :customer_details
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A list of items the customer is purchasing.
sig { returns(T::Array[::Stripe::Tax::CalculationService::CreateParams::LineItem]) }
attr_accessor :line_items
# Details about the address from which the goods are being shipped.
sig { returns(T.nilable(::Stripe::Tax::CalculationService::CreateParams::ShipFromDetails)) }
attr_accessor :ship_from_details
# Shipping cost details to be used for the calculation.
sig { returns(T.nilable(::Stripe::Tax::CalculationService::CreateParams::ShippingCost)) }
attr_accessor :shipping_cost
# Timestamp of date at which the tax rules and rates in effect applies for the calculation. Measured in seconds since the Unix epoch. Can be up to 48 hours in the past, and up to 48 hours in the future.
sig { returns(T.nilable(Integer)) }
attr_accessor :tax_date
sig {
params(currency: String, customer: T.nilable(String), customer_details: T.nilable(::Stripe::Tax::CalculationService::CreateParams::CustomerDetails), expand: T.nilable(T::Array[String]), line_items: T::Array[::Stripe::Tax::CalculationService::CreateParams::LineItem], ship_from_details: T.nilable(::Stripe::Tax::CalculationService::CreateParams::ShipFromDetails), shipping_cost: T.nilable(::Stripe::Tax::CalculationService::CreateParams::ShippingCost), tax_date: T.nilable(Integer)).void
}
def initialize(
currency: nil,
customer: nil,
customer_details: nil,
expand: nil,
line_items: nil,
ship_from_details: nil,
shipping_cost: nil,
tax_date: nil
); end
end
# Calculates tax based on the input and returns a Tax Calculation object.
sig {
params(params: T.any(::Stripe::Tax::CalculationService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Tax::Calculation)
}
def create(params = {}, opts = {}); end
# Retrieves a Tax Calculation object, if the calculation hasn't expired.
sig {
params(calculation: String, params: T.any(::Stripe::Tax::CalculationService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Tax::Calculation)
}
def retrieve(calculation, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Tax
class CalculationLineItemService < StripeService
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
# Retrieves the line items of a tax calculation as a collection, if the calculation hasn't expired.
sig {
params(calculation: String, params: T.any(::Stripe::Tax::CalculationLineItemService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(calculation, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Tax
class FormService < StripeService
class ListParams < Stripe::RequestParams
class Payee < Stripe::RequestParams
# The ID of the Stripe account whose forms will be retrieved.
sig { returns(T.nilable(String)) }
attr_accessor :account
# The external reference to the payee whose forms will be retrieved.
sig { returns(T.nilable(String)) }
attr_accessor :external_reference
# Specifies the payee type. Either `account` or `external_reference`.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(account: T.nilable(String), external_reference: T.nilable(String), type: T.nilable(String)).void
}
def initialize(account: nil, external_reference: nil, type: nil); end
end
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# The payee whose volume is represented on the tax form.
sig { returns(::Stripe::Tax::FormService::ListParams::Payee) }
attr_accessor :payee
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# An optional filter on the list, based on the object `type` field. Without the filter, the list includes all current and future tax form types. If your integration expects only one type of tax form in the response, make sure to provide a type value in the request.
sig { returns(T.nilable(String)) }
attr_accessor :type
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), payee: ::Stripe::Tax::FormService::ListParams::Payee, starting_after: T.nilable(String), type: T.nilable(String)).void
}
def initialize(
ending_before: nil,
expand: nil,
limit: nil,
payee: nil,
starting_after: nil,
type: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class PdfParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Returns a list of tax forms which were previously created. The tax forms are returned in sorted order, with the oldest tax forms appearing first.
sig {
params(params: T.any(::Stripe::Tax::FormService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Download the PDF for a tax form.
sig {
params(id: String, params: T.any(::Stripe::Tax::FormService::PdfParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped, read_body_chunk_block: T.untyped).returns(T.untyped)
}
def pdf(id, params = {}, opts = {}, &read_body_chunk_block); end
# Retrieves the details of a tax form that has previously been created. Supply the unique tax form ID that was returned from your previous request, and Stripe will return the corresponding tax form information.
sig {
params(id: String, params: T.any(::Stripe::Tax::FormService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Tax::Form)
}
def retrieve(id, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Tax
class RegistrationService < StripeService
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# The status of the Tax Registration.
sig { returns(T.nilable(String)) }
attr_accessor :status
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String), status: T.nilable(String)).void
}
def initialize(
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil,
status: nil
); end
end
class CreateParams < Stripe::RequestParams
class CountryOptions < Stripe::RequestParams
class Ae < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Al < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Am < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Ao < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class At < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::At::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::At::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Au < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Aw < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Az < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Ba < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Bb < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Bd < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Be < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Be::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Be::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Bf < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Bg < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Bg::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Bg::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Bh < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Bj < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Bs < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class By < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Ca < Stripe::RequestParams
class ProvinceStandard < Stripe::RequestParams
# Two-letter CA province code ([ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2)).
sig { returns(String) }
attr_accessor :province
sig { params(province: String).void }
def initialize(province: nil); end
end
# Options for the provincial tax registration.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Ca::ProvinceStandard))
}
attr_accessor :province_standard
# Type of registration to be created in Canada.
sig { returns(String) }
attr_accessor :type
sig {
params(province_standard: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Ca::ProvinceStandard), type: String).void
}
def initialize(province_standard: nil, type: nil); end
end
class Cd < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Ch < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Cl < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Cm < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Co < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Cr < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Cv < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Cy < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Cy::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Cy::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Cz < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Cz::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Cz::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class De < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::De::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::De::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Dk < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Dk::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Dk::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Ec < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Ee < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Ee::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Ee::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Eg < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Es < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Es::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Es::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Et < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Fi < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Fi::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Fi::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Fr < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Fr::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Fr::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Gb < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Ge < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Gn < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Gr < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Gr::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Gr::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Hr < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Hr::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Hr::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Hu < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Hu::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Hu::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Id < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Ie < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Ie::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Ie::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class In < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Is < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class It < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::It::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::It::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Jp < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Ke < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Kg < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Kh < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Kr < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Kz < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class La < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Lt < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Lt::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Lt::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Lu < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Lu::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Lu::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Lv < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Lv::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Lv::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Ma < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Md < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Me < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Mk < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Mr < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Mt < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Mt::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Mt::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Mx < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class My < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Ng < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Nl < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Nl::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Nl::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class No < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Np < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Nz < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Om < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Pe < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Ph < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Pl < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Pl::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Pl::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Pt < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Pt::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Pt::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Ro < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Ro::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Ro::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Rs < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Ru < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Sa < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Se < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Se::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Se::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Sg < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Si < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Si::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Si::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Sk < Stripe::RequestParams
class Standard < Stripe::RequestParams
# Place of supply scheme used in an EU standard registration.
sig { returns(String) }
attr_accessor :place_of_supply_scheme
sig { params(place_of_supply_scheme: String).void }
def initialize(place_of_supply_scheme: nil); end
end
# Options for the standard registration.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Sk::Standard))
}
attr_accessor :standard
# Type of registration to be created in an EU country.
sig { returns(String) }
attr_accessor :type
sig {
params(standard: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Sk::Standard), type: String).void
}
def initialize(standard: nil, type: nil); end
end
class Sn < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Sr < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Th < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Tj < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Tr < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Tz < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Ug < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Us < Stripe::RequestParams
class LocalAmusementTax < Stripe::RequestParams
# A [FIPS code](https://www.census.gov/library/reference/code-lists/ansi.html) representing the local jurisdiction. Supported FIPS codes are: `14000` (Chicago), `06613` (Bloomington), `21696` (East Dundee), `24582` (Evanston), `45421` (Lynwood), `48892` (Midlothian), `64343` (River Grove), and `68081` (Schiller Park).
sig { returns(String) }
attr_accessor :jurisdiction
sig { params(jurisdiction: String).void }
def initialize(jurisdiction: nil); end
end
class LocalLeaseTax < Stripe::RequestParams
# A [FIPS code](https://www.census.gov/library/reference/code-lists/ansi.html) representing the local jurisdiction. Supported FIPS codes are: `14000` (Chicago).
sig { returns(String) }
attr_accessor :jurisdiction
sig { params(jurisdiction: String).void }
def initialize(jurisdiction: nil); end
end
class StateSalesTax < Stripe::RequestParams
class Election < Stripe::RequestParams
# A [FIPS code](https://www.census.gov/library/reference/code-lists/ansi.html) representing the local jurisdiction. Supported FIPS codes are: `003` (Allegheny County) and `60000` (Philadelphia City).
sig { returns(T.nilable(String)) }
attr_accessor :jurisdiction
# The type of the election for the state sales tax registration.
sig { returns(String) }
attr_accessor :type
sig { params(jurisdiction: T.nilable(String), type: String).void }
def initialize(jurisdiction: nil, type: nil); end
end
# Elections for the state sales tax registration.
sig {
returns(T::Array[::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Us::StateSalesTax::Election])
}
attr_accessor :elections
sig {
params(elections: T::Array[::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Us::StateSalesTax::Election]).void
}
def initialize(elections: nil); end
end
# Options for the local amusement tax registration.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Us::LocalAmusementTax))
}
attr_accessor :local_amusement_tax
# Options for the local lease tax registration.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Us::LocalLeaseTax))
}
attr_accessor :local_lease_tax
# Two-letter US state code ([ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2)).
sig { returns(String) }
attr_accessor :state
# Options for the state sales tax registration.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Us::StateSalesTax))
}
attr_accessor :state_sales_tax
# Type of registration to be created in the US.
sig { returns(String) }
attr_accessor :type
sig {
params(local_amusement_tax: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Us::LocalAmusementTax), local_lease_tax: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Us::LocalLeaseTax), state: String, state_sales_tax: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Us::StateSalesTax), type: String).void
}
def initialize(
local_amusement_tax: nil,
local_lease_tax: nil,
state: nil,
state_sales_tax: nil,
type: nil
); end
end
class Uy < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Uz < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Vn < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Za < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Zm < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
class Zw < Stripe::RequestParams
# Type of registration to be created in `country`.
sig { returns(String) }
attr_accessor :type
sig { params(type: String).void }
def initialize(type: nil); end
end
# Options for the registration in AE.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Ae))
}
attr_accessor :ae
# Options for the registration in AL.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Al))
}
attr_accessor :al
# Options for the registration in AM.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Am))
}
attr_accessor :am
# Options for the registration in AO.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Ao))
}
attr_accessor :ao
# Options for the registration in AT.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::At))
}
attr_accessor :at
# Options for the registration in AU.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Au))
}
attr_accessor :au
# Options for the registration in AW.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Aw))
}
attr_accessor :aw
# Options for the registration in AZ.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Az))
}
attr_accessor :az
# Options for the registration in BA.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Ba))
}
attr_accessor :ba
# Options for the registration in BB.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Bb))
}
attr_accessor :bb
# Options for the registration in BD.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Bd))
}
attr_accessor :bd
# Options for the registration in BE.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Be))
}
attr_accessor :be
# Options for the registration in BF.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Bf))
}
attr_accessor :bf
# Options for the registration in BG.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Bg))
}
attr_accessor :bg
# Options for the registration in BH.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Bh))
}
attr_accessor :bh
# Options for the registration in BJ.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Bj))
}
attr_accessor :bj
# Options for the registration in BS.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Bs))
}
attr_accessor :bs
# Options for the registration in BY.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::By))
}
attr_accessor :by
# Options for the registration in CA.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Ca))
}
attr_accessor :ca
# Options for the registration in CD.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Cd))
}
attr_accessor :cd
# Options for the registration in CH.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Ch))
}
attr_accessor :ch
# Options for the registration in CL.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Cl))
}
attr_accessor :cl
# Options for the registration in CM.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Cm))
}
attr_accessor :cm
# Options for the registration in CO.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Co))
}
attr_accessor :co
# Options for the registration in CR.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Cr))
}
attr_accessor :cr
# Options for the registration in CV.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Cv))
}
attr_accessor :cv
# Options for the registration in CY.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Cy))
}
attr_accessor :cy
# Options for the registration in CZ.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Cz))
}
attr_accessor :cz
# Options for the registration in DE.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::De))
}
attr_accessor :de
# Options for the registration in DK.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Dk))
}
attr_accessor :dk
# Options for the registration in EC.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Ec))
}
attr_accessor :ec
# Options for the registration in EE.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Ee))
}
attr_accessor :ee
# Options for the registration in EG.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Eg))
}
attr_accessor :eg
# Options for the registration in ES.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Es))
}
attr_accessor :es
# Options for the registration in ET.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Et))
}
attr_accessor :et
# Options for the registration in FI.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Fi))
}
attr_accessor :fi
# Options for the registration in FR.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Fr))
}
attr_accessor :fr
# Options for the registration in GB.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Gb))
}
attr_accessor :gb
# Options for the registration in GE.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Ge))
}
attr_accessor :ge
# Options for the registration in GN.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Gn))
}
attr_accessor :gn
# Options for the registration in GR.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Gr))
}
attr_accessor :gr
# Options for the registration in HR.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Hr))
}
attr_accessor :hr
# Options for the registration in HU.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Hu))
}
attr_accessor :hu
# Options for the registration in ID.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Id))
}
attr_accessor :id
# Options for the registration in IE.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Ie))
}
attr_accessor :ie
# Options for the registration in IN.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::In))
}
attr_accessor :in
# Options for the registration in IS.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Is))
}
attr_accessor :is
# Options for the registration in IT.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::It))
}
attr_accessor :it
# Options for the registration in JP.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Jp))
}
attr_accessor :jp
# Options for the registration in KE.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Ke))
}
attr_accessor :ke
# Options for the registration in KG.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Kg))
}
attr_accessor :kg
# Options for the registration in KH.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Kh))
}
attr_accessor :kh
# Options for the registration in KR.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Kr))
}
attr_accessor :kr
# Options for the registration in KZ.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Kz))
}
attr_accessor :kz
# Options for the registration in LA.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::La))
}
attr_accessor :la
# Options for the registration in LT.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Lt))
}
attr_accessor :lt
# Options for the registration in LU.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Lu))
}
attr_accessor :lu
# Options for the registration in LV.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Lv))
}
attr_accessor :lv
# Options for the registration in MA.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Ma))
}
attr_accessor :ma
# Options for the registration in MD.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Md))
}
attr_accessor :md
# Options for the registration in ME.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Me))
}
attr_accessor :me
# Options for the registration in MK.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Mk))
}
attr_accessor :mk
# Options for the registration in MR.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Mr))
}
attr_accessor :mr
# Options for the registration in MT.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Mt))
}
attr_accessor :mt
# Options for the registration in MX.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Mx))
}
attr_accessor :mx
# Options for the registration in MY.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::My))
}
attr_accessor :my
# Options for the registration in NG.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Ng))
}
attr_accessor :ng
# Options for the registration in NL.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Nl))
}
attr_accessor :nl
# Options for the registration in NO.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::No))
}
attr_accessor :no
# Options for the registration in NP.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Np))
}
attr_accessor :np
# Options for the registration in NZ.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Nz))
}
attr_accessor :nz
# Options for the registration in OM.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Om))
}
attr_accessor :om
# Options for the registration in PE.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Pe))
}
attr_accessor :pe
# Options for the registration in PH.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Ph))
}
attr_accessor :ph
# Options for the registration in PL.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Pl))
}
attr_accessor :pl
# Options for the registration in PT.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Pt))
}
attr_accessor :pt
# Options for the registration in RO.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Ro))
}
attr_accessor :ro
# Options for the registration in RS.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Rs))
}
attr_accessor :rs
# Options for the registration in RU.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Ru))
}
attr_accessor :ru
# Options for the registration in SA.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Sa))
}
attr_accessor :sa
# Options for the registration in SE.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Se))
}
attr_accessor :se
# Options for the registration in SG.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Sg))
}
attr_accessor :sg
# Options for the registration in SI.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Si))
}
attr_accessor :si
# Options for the registration in SK.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Sk))
}
attr_accessor :sk
# Options for the registration in SN.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Sn))
}
attr_accessor :sn
# Options for the registration in SR.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Sr))
}
attr_accessor :sr
# Options for the registration in TH.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Th))
}
attr_accessor :th
# Options for the registration in TJ.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Tj))
}
attr_accessor :tj
# Options for the registration in TR.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Tr))
}
attr_accessor :tr
# Options for the registration in TZ.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Tz))
}
attr_accessor :tz
# Options for the registration in UG.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Ug))
}
attr_accessor :ug
# Options for the registration in US.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Us))
}
attr_accessor :us
# Options for the registration in UY.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Uy))
}
attr_accessor :uy
# Options for the registration in UZ.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Uz))
}
attr_accessor :uz
# Options for the registration in VN.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Vn))
}
attr_accessor :vn
# Options for the registration in ZA.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Za))
}
attr_accessor :za
# Options for the registration in ZM.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Zm))
}
attr_accessor :zm
# Options for the registration in ZW.
sig {
returns(T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Zw))
}
attr_accessor :zw
sig {
params(ae: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Ae), al: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Al), am: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Am), ao: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Ao), at: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::At), au: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Au), aw: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Aw), az: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Az), ba: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Ba), bb: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Bb), bd: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Bd), be: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Be), bf: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Bf), bg: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Bg), bh: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Bh), bj: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Bj), bs: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Bs), by: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::By), ca: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Ca), cd: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Cd), ch: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Ch), cl: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Cl), cm: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Cm), co: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Co), cr: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Cr), cv: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Cv), cy: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Cy), cz: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Cz), de: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::De), dk: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Dk), ec: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Ec), ee: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Ee), eg: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Eg), es: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Es), et: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Et), fi: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Fi), fr: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Fr), gb: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Gb), ge: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Ge), gn: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Gn), gr: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Gr), hr: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Hr), hu: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Hu), id: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Id), ie: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Ie), in_: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::In), is: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Is), it: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::It), jp: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Jp), ke: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Ke), kg: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Kg), kh: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Kh), kr: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Kr), kz: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Kz), la: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::La), lt: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Lt), lu: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Lu), lv: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Lv), ma: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Ma), md: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Md), me: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Me), mk: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Mk), mr: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Mr), mt: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Mt), mx: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Mx), my: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::My), ng: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Ng), nl: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Nl), no: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::No), np: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Np), nz: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Nz), om: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Om), pe: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Pe), ph: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Ph), pl: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Pl), pt: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Pt), ro: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Ro), rs: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Rs), ru: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Ru), sa: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Sa), se: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Se), sg: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Sg), si: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Si), sk: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Sk), sn: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Sn), sr: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Sr), th: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Th), tj: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Tj), tr: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Tr), tz: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Tz), ug: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Ug), us: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Us), uy: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Uy), uz: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Uz), vn: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Vn), za: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Za), zm: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Zm), zw: T.nilable(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions::Zw)).void
}
def initialize(
ae: nil,
al: nil,
am: nil,
ao: nil,
at: nil,
au: nil,
aw: nil,
az: nil,
ba: nil,
bb: nil,
bd: nil,
be: nil,
bf: nil,
bg: nil,
bh: nil,
bj: nil,
bs: nil,
by: nil,
ca: nil,
cd: nil,
ch: nil,
cl: nil,
cm: nil,
co: nil,
cr: nil,
cv: nil,
cy: nil,
cz: nil,
de: nil,
dk: nil,
ec: nil,
ee: nil,
eg: nil,
es: nil,
et: nil,
fi: nil,
fr: nil,
gb: nil,
ge: nil,
gn: nil,
gr: nil,
hr: nil,
hu: nil,
id: nil,
ie: nil,
in_: nil,
is: nil,
it: nil,
jp: nil,
ke: nil,
kg: nil,
kh: nil,
kr: nil,
kz: nil,
la: nil,
lt: nil,
lu: nil,
lv: nil,
ma: nil,
md: nil,
me: nil,
mk: nil,
mr: nil,
mt: nil,
mx: nil,
my: nil,
ng: nil,
nl: nil,
no: nil,
np: nil,
nz: nil,
om: nil,
pe: nil,
ph: nil,
pl: nil,
pt: nil,
ro: nil,
rs: nil,
ru: nil,
sa: nil,
se: nil,
sg: nil,
si: nil,
sk: nil,
sn: nil,
sr: nil,
th: nil,
tj: nil,
tr: nil,
tz: nil,
ug: nil,
us: nil,
uy: nil,
uz: nil,
vn: nil,
za: nil,
zm: nil,
zw: nil
); end
end
# Time at which the Tax Registration becomes active. It can be either `now` to indicate the current time, or a future timestamp measured in seconds since the Unix epoch.
sig { returns(T.any(String, Integer)) }
attr_accessor :active_from
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(String) }
attr_accessor :country
# Specific options for a registration in the specified `country`.
sig { returns(::Stripe::Tax::RegistrationService::CreateParams::CountryOptions) }
attr_accessor :country_options
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# If set, the Tax Registration stops being active at this time. If not set, the Tax Registration will be active indefinitely. Timestamp measured in seconds since the Unix epoch.
sig { returns(T.nilable(Integer)) }
attr_accessor :expires_at
sig {
params(active_from: T.any(String, Integer), country: String, country_options: ::Stripe::Tax::RegistrationService::CreateParams::CountryOptions, expand: T.nilable(T::Array[String]), expires_at: T.nilable(Integer)).void
}
def initialize(
active_from: nil,
country: nil,
country_options: nil,
expand: nil,
expires_at: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
# Time at which the registration becomes active. It can be either `now` to indicate the current time, or a timestamp measured in seconds since the Unix epoch.
sig { returns(T.nilable(T.any(String, Integer))) }
attr_accessor :active_from
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# If set, the registration stops being active at this time. If not set, the registration will be active indefinitely. It can be either `now` to indicate the current time, or a timestamp measured in seconds since the Unix epoch.
sig { returns(T.nilable(T.nilable(T.any(String, T.any(String, Integer))))) }
attr_accessor :expires_at
sig {
params(active_from: T.nilable(T.any(String, Integer)), expand: T.nilable(T::Array[String]), expires_at: T.nilable(T.nilable(T.any(String, T.any(String, Integer))))).void
}
def initialize(active_from: nil, expand: nil, expires_at: nil); end
end
# Creates a new Tax Registration object.
sig {
params(params: T.any(::Stripe::Tax::RegistrationService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Tax::Registration)
}
def create(params = {}, opts = {}); end
# Returns a list of Tax Registration objects.
sig {
params(params: T.any(::Stripe::Tax::RegistrationService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Returns a Tax Registration object.
sig {
params(id: String, params: T.any(::Stripe::Tax::RegistrationService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Tax::Registration)
}
def retrieve(id, params = {}, opts = {}); end
# Updates an existing Tax Registration object.
#
# A registration cannot be deleted after it has been created. If you wish to end a registration you may do so by setting expires_at.
sig {
params(id: String, params: T.any(::Stripe::Tax::RegistrationService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Tax::Registration)
}
def update(id, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Tax
class SettingsService < StripeService
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
class Defaults < Stripe::RequestParams
# Specifies the default [tax behavior](https://stripe.com/docs/tax/products-prices-tax-categories-tax-behavior#tax-behavior) to be used when the item's price has unspecified tax behavior. One of inclusive, exclusive, or inferred_by_currency. Once specified, it cannot be changed back to null.
sig { returns(T.nilable(String)) }
attr_accessor :tax_behavior
# A [tax code](https://stripe.com/docs/tax/tax-categories) ID.
sig { returns(T.nilable(String)) }
attr_accessor :tax_code
sig { params(tax_behavior: T.nilable(String), tax_code: T.nilable(String)).void }
def initialize(tax_behavior: nil, tax_code: nil); end
end
class HeadOffice < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State/province as an [ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2) subdivision code, without country prefix. Example: "NY" or "TX".
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# The location of the business for tax purposes.
sig { returns(::Stripe::Tax::SettingsService::UpdateParams::HeadOffice::Address) }
attr_accessor :address
sig {
params(address: ::Stripe::Tax::SettingsService::UpdateParams::HeadOffice::Address).void
}
def initialize(address: nil); end
end
# Default configuration to be used on Stripe Tax calculations.
sig { returns(T.nilable(::Stripe::Tax::SettingsService::UpdateParams::Defaults)) }
attr_accessor :defaults
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The place where your business is located.
sig { returns(T.nilable(::Stripe::Tax::SettingsService::UpdateParams::HeadOffice)) }
attr_accessor :head_office
sig {
params(defaults: T.nilable(::Stripe::Tax::SettingsService::UpdateParams::Defaults), expand: T.nilable(T::Array[String]), head_office: T.nilable(::Stripe::Tax::SettingsService::UpdateParams::HeadOffice)).void
}
def initialize(defaults: nil, expand: nil, head_office: nil); end
end
# Retrieves Tax Settings for a merchant.
sig {
params(params: T.any(::Stripe::Tax::SettingsService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Tax::Settings)
}
def retrieve(params = {}, opts = {}); end
# Updates Tax Settings parameters used in tax calculations. All parameters are editable but none can be removed once set.
sig {
params(params: T.any(::Stripe::Tax::SettingsService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Tax::Settings)
}
def update(params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Tax
class TransactionService < StripeService
attr_reader :line_items
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class CreateFromCalculationParams < Stripe::RequestParams
# Tax Calculation ID to be used as input when creating the transaction.
sig { returns(String) }
attr_accessor :calculation
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The Unix timestamp representing when the tax liability is assumed or reduced, which determines the liability posting period and handling in tax liability reports. The timestamp must fall within the `tax_date` and the current time, unless the `tax_date` is scheduled in advance. Defaults to the current time.
sig { returns(T.nilable(Integer)) }
attr_accessor :posted_at
# A custom order or sale identifier, such as 'myOrder_123'. Must be unique across all transactions, including reversals.
sig { returns(String) }
attr_accessor :reference
sig {
params(calculation: String, expand: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), posted_at: T.nilable(Integer), reference: String).void
}
def initialize(
calculation: nil,
expand: nil,
metadata: nil,
posted_at: nil,
reference: nil
); end
end
class CreateReversalParams < Stripe::RequestParams
class LineItem < Stripe::RequestParams
# The amount to reverse, in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) in negative.
sig { returns(Integer) }
attr_accessor :amount
# The amount of tax to reverse, in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) in negative.
sig { returns(Integer) }
attr_accessor :amount_tax
# 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.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The `id` of the line item to reverse in the original transaction.
sig { returns(String) }
attr_accessor :original_line_item
# The quantity reversed. Appears in [tax exports](https://stripe.com/docs/tax/reports), but does not affect the amount of tax reversed.
sig { returns(T.nilable(Integer)) }
attr_accessor :quantity
# A custom identifier for this line item in the reversal transaction, such as 'L1-refund'.
sig { returns(String) }
attr_accessor :reference
sig {
params(amount: Integer, amount_tax: Integer, metadata: T.nilable(T::Hash[String, String]), original_line_item: String, quantity: T.nilable(Integer), reference: String).void
}
def initialize(
amount: nil,
amount_tax: nil,
metadata: nil,
original_line_item: nil,
quantity: nil,
reference: nil
); end
end
class ShippingCost < Stripe::RequestParams
# The amount to reverse, in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) in negative.
sig { returns(Integer) }
attr_accessor :amount
# The amount of tax to reverse, in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) in negative.
sig { returns(Integer) }
attr_accessor :amount_tax
sig { params(amount: Integer, amount_tax: Integer).void }
def initialize(amount: nil, amount_tax: nil); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A flat amount to reverse across the entire transaction, in the [smallest currency unit](https://stripe.com/docs/currencies#zero-decimal) in negative. This value represents the total amount to refund from the transaction, including taxes.
sig { returns(T.nilable(Integer)) }
attr_accessor :flat_amount
# The line item amounts to reverse.
sig {
returns(T.nilable(T::Array[::Stripe::Tax::TransactionService::CreateReversalParams::LineItem]))
}
attr_accessor :line_items
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# If `partial`, the provided line item or shipping cost amounts are reversed. If `full`, the original transaction is fully reversed.
sig { returns(String) }
attr_accessor :mode
# The ID of the Transaction to partially or fully reverse.
sig { returns(String) }
attr_accessor :original_transaction
# A custom identifier for this reversal, such as `myOrder_123-refund_1`, which must be unique across all transactions. The reference helps identify this reversal transaction in exported [tax reports](https://stripe.com/docs/tax/reports).
sig { returns(String) }
attr_accessor :reference
# The shipping cost to reverse.
sig {
returns(T.nilable(::Stripe::Tax::TransactionService::CreateReversalParams::ShippingCost))
}
attr_accessor :shipping_cost
sig {
params(expand: T.nilable(T::Array[String]), flat_amount: T.nilable(Integer), line_items: T.nilable(T::Array[::Stripe::Tax::TransactionService::CreateReversalParams::LineItem]), metadata: T.nilable(T::Hash[String, String]), mode: String, original_transaction: String, reference: String, shipping_cost: T.nilable(::Stripe::Tax::TransactionService::CreateReversalParams::ShippingCost)).void
}
def initialize(
expand: nil,
flat_amount: nil,
line_items: nil,
metadata: nil,
mode: nil,
original_transaction: nil,
reference: nil,
shipping_cost: nil
); end
end
# Creates a Tax Transaction from a calculation, if that calculation hasn't expired. Calculations expire after 90 days.
sig {
params(params: T.any(::Stripe::Tax::TransactionService::CreateFromCalculationParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Tax::Transaction)
}
def create_from_calculation(params = {}, opts = {}); end
# Partially or fully reverses a previously created Transaction.
sig {
params(params: T.any(::Stripe::Tax::TransactionService::CreateReversalParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Tax::Transaction)
}
def create_reversal(params = {}, opts = {}); end
# Retrieves a Tax Transaction object.
sig {
params(transaction: String, params: T.any(::Stripe::Tax::TransactionService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Tax::Transaction)
}
def retrieve(transaction, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Tax
class TransactionLineItemService < StripeService
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
# Retrieves the line items of a committed standalone transaction as a collection.
sig {
params(transaction: String, params: T.any(::Stripe::Tax::TransactionLineItemService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(transaction, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
class TaxCodeService < StripeService
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# A list of [all tax codes available](https://stripe.com/docs/tax/tax-categories) to add to Products in order to allow specific tax calculations.
sig {
params(params: T.any(::Stripe::TaxCodeService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the details of an existing tax code. Supply the unique tax code ID and Stripe will return the corresponding tax code information.
sig {
params(id: String, params: T.any(::Stripe::TaxCodeService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::TaxCode)
}
def retrieve(id, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class TaxIdService < StripeService
class DeleteParams < Stripe::RequestParams; end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class ListParams < Stripe::RequestParams
class Owner < Stripe::RequestParams
# Account the tax ID belongs to. Required when `type=account`
sig { returns(T.nilable(String)) }
attr_accessor :account
# Customer the tax ID belongs to. Required when `type=customer`
sig { returns(T.nilable(String)) }
attr_accessor :customer
# v2 Account the tax ID belongs to. Can be used in place of `customer` when `type=customer`
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# Type of owner referenced.
sig { returns(String) }
attr_accessor :type
sig {
params(account: T.nilable(String), customer: T.nilable(String), customer_account: T.nilable(String), type: String).void
}
def initialize(account: nil, customer: nil, customer_account: nil, type: nil); end
end
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# The account or customer the tax ID belongs to. Defaults to `owner[type]=self`.
sig { returns(T.nilable(::Stripe::TaxIdService::ListParams::Owner)) }
attr_accessor :owner
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), owner: T.nilable(::Stripe::TaxIdService::ListParams::Owner), starting_after: T.nilable(String)).void
}
def initialize(
ending_before: nil,
expand: nil,
limit: nil,
owner: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class Owner < Stripe::RequestParams
# Account the tax ID belongs to. Required when `type=account`
sig { returns(T.nilable(String)) }
attr_accessor :account
# Customer the tax ID belongs to. Required when `type=customer`
sig { returns(T.nilable(String)) }
attr_accessor :customer
# v2 Account the tax ID belongs to. Can be used in place of `customer` when `type=customer`
sig { returns(T.nilable(String)) }
attr_accessor :customer_account
# Type of owner referenced.
sig { returns(String) }
attr_accessor :type
sig {
params(account: T.nilable(String), customer: T.nilable(String), customer_account: T.nilable(String), type: String).void
}
def initialize(account: nil, customer: nil, customer_account: nil, type: nil); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The account or customer the tax ID belongs to. Defaults to `owner[type]=self`.
sig { returns(T.nilable(::Stripe::TaxIdService::CreateParams::Owner)) }
attr_accessor :owner
# Type of the tax ID, one of `ad_nrt`, `ae_trn`, `al_tin`, `am_tin`, `ao_tin`, `ar_cuit`, `au_abn`, `au_arn`, `aw_tin`, `az_tin`, `ba_tin`, `bb_tin`, `bd_bin`, `bf_ifu`, `bg_uic`, `bh_vat`, `bj_ifu`, `bo_tin`, `br_cnpj`, `br_cpf`, `bs_tin`, `by_tin`, `ca_bn`, `ca_gst_hst`, `ca_pst_bc`, `ca_pst_mb`, `ca_pst_sk`, `ca_qst`, `cd_nif`, `ch_uid`, `ch_vat`, `cl_tin`, `cm_niu`, `cn_tin`, `co_nit`, `cr_tin`, `cv_nif`, `de_stn`, `do_rcn`, `ec_ruc`, `eg_tin`, `es_cif`, `et_tin`, `eu_oss_vat`, `eu_vat`, `gb_vat`, `ge_vat`, `gn_nif`, `hk_br`, `hr_oib`, `hu_tin`, `id_npwp`, `il_vat`, `in_gst`, `is_vat`, `jp_cn`, `jp_rn`, `jp_trn`, `ke_pin`, `kg_tin`, `kh_tin`, `kr_brn`, `kz_bin`, `la_tin`, `li_uid`, `li_vat`, `ma_vat`, `md_vat`, `me_pib`, `mk_vat`, `mr_nif`, `mx_rfc`, `my_frp`, `my_itn`, `my_sst`, `ng_tin`, `no_vat`, `no_voec`, `np_pan`, `nz_gst`, `om_vat`, `pe_ruc`, `ph_tin`, `ro_tin`, `rs_pib`, `ru_inn`, `ru_kpp`, `sa_vat`, `sg_gst`, `sg_uen`, `si_tin`, `sn_ninea`, `sr_fin`, `sv_nit`, `th_vat`, `tj_tin`, `tr_tin`, `tw_vat`, `tz_vat`, `ua_vat`, `ug_tin`, `us_ein`, `uy_ruc`, `uz_tin`, `uz_vat`, `ve_rif`, `vn_tin`, `za_vat`, `zm_tin`, or `zw_tin`
sig { returns(String) }
attr_accessor :type
# Value of the tax ID.
sig { returns(String) }
attr_accessor :value
sig {
params(expand: T.nilable(T::Array[String]), owner: T.nilable(::Stripe::TaxIdService::CreateParams::Owner), type: String, value: String).void
}
def initialize(expand: nil, owner: nil, type: nil, value: nil); end
end
# Creates a new account or customer tax_id object.
sig {
params(params: T.any(::Stripe::TaxIdService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::TaxId)
}
def create(params = {}, opts = {}); end
# Deletes an existing account or customer tax_id object.
sig {
params(id: String, params: T.any(::Stripe::TaxIdService::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::TaxId)
}
def delete(id, params = {}, opts = {}); end
# Returns a list of tax IDs.
sig {
params(params: T.any(::Stripe::TaxIdService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves an account or customer tax_id object.
sig {
params(id: String, params: T.any(::Stripe::TaxIdService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::TaxId)
}
def retrieve(id, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class TaxRateService < StripeService
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Optional flag to filter by tax rates that are either active or inactive (archived).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# Optional range for filtering created date.
sig { returns(T.nilable(T.any(::Stripe::TaxRateService::ListParams::Created, Integer))) }
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Optional flag to filter by tax rates that are inclusive (or those that are not inclusive).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :inclusive
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(active: T.nilable(T::Boolean), created: T.nilable(T.any(::Stripe::TaxRateService::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), inclusive: T.nilable(T::Boolean), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
active: nil,
created: nil,
ending_before: nil,
expand: nil,
inclusive: nil,
limit: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
# Flag determining whether the tax rate is active or inactive (archived). Inactive tax rates cannot be used with new applications or Checkout Sessions, but will still work for subscriptions and invoices that already have it set.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# An arbitrary string attached to the tax rate for your internal use only. It will not be visible to your customers.
sig { returns(T.nilable(String)) }
attr_accessor :description
# The display name of the tax rate, which will be shown to users.
sig { returns(String) }
attr_accessor :display_name
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# This specifies if the tax rate is inclusive or exclusive.
sig { returns(T::Boolean) }
attr_accessor :inclusive
# The jurisdiction for the tax rate. You can use this label field for tax reporting purposes. It also appears on your customer’s invoice.
sig { returns(T.nilable(String)) }
attr_accessor :jurisdiction
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# This represents the tax rate percent out of 100.
sig { returns(Float) }
attr_accessor :percentage
# [ISO 3166-2 subdivision code](https://en.wikipedia.org/wiki/ISO_3166-2), without country prefix. For example, "NY" for New York, United States.
sig { returns(T.nilable(String)) }
attr_accessor :state
# The high-level tax type, such as `vat` or `sales_tax`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_type
sig {
params(active: T.nilable(T::Boolean), country: T.nilable(String), description: T.nilable(String), display_name: String, expand: T.nilable(T::Array[String]), inclusive: T::Boolean, jurisdiction: T.nilable(String), metadata: T.nilable(T::Hash[String, String]), percentage: Float, state: T.nilable(String), tax_type: T.nilable(String)).void
}
def initialize(
active: nil,
country: nil,
description: nil,
display_name: nil,
expand: nil,
inclusive: nil,
jurisdiction: nil,
metadata: nil,
percentage: nil,
state: nil,
tax_type: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
# Flag determining whether the tax rate is active or inactive (archived). Inactive tax rates cannot be used with new applications or Checkout Sessions, but will still work for subscriptions and invoices that already have it set.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :active
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# An arbitrary string attached to the tax rate for your internal use only. It will not be visible to your customers.
sig { returns(T.nilable(String)) }
attr_accessor :description
# The display name of the tax rate, which will be shown to users.
sig { returns(T.nilable(String)) }
attr_accessor :display_name
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The jurisdiction for the tax rate. You can use this label field for tax reporting purposes. It also appears on your customer’s invoice.
sig { returns(T.nilable(String)) }
attr_accessor :jurisdiction
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# [ISO 3166-2 subdivision code](https://en.wikipedia.org/wiki/ISO_3166-2), without country prefix. For example, "NY" for New York, United States.
sig { returns(T.nilable(String)) }
attr_accessor :state
# The high-level tax type, such as `vat` or `sales_tax`.
sig { returns(T.nilable(String)) }
attr_accessor :tax_type
sig {
params(active: T.nilable(T::Boolean), country: T.nilable(String), description: T.nilable(String), display_name: T.nilable(String), expand: T.nilable(T::Array[String]), jurisdiction: T.nilable(String), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), state: T.nilable(String), tax_type: T.nilable(String)).void
}
def initialize(
active: nil,
country: nil,
description: nil,
display_name: nil,
expand: nil,
jurisdiction: nil,
metadata: nil,
state: nil,
tax_type: nil
); end
end
# Creates a new tax rate.
sig {
params(params: T.any(::Stripe::TaxRateService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::TaxRate)
}
def create(params = {}, opts = {}); end
# Returns a list of your tax rates. Tax rates are returned sorted by creation date, with the most recently created tax rates appearing first.
sig {
params(params: T.any(::Stripe::TaxRateService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves a tax rate with the given ID
sig {
params(tax_rate: String, params: T.any(::Stripe::TaxRateService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::TaxRate)
}
def retrieve(tax_rate, params = {}, opts = {}); end
# Updates an existing tax rate.
sig {
params(tax_rate: String, params: T.any(::Stripe::TaxRateService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::TaxRate)
}
def update(tax_rate, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class TerminalService < StripeService
attr_reader :configurations
attr_reader :connection_tokens
attr_reader :locations
attr_reader :readers
attr_reader :reader_collected_data
end
end
# typed: true
module Stripe
module Terminal
class ConfigurationService < StripeService
class DeleteParams < Stripe::RequestParams; end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
class BbposWiseposE < Stripe::RequestParams
# A File ID representing an image to display on the reader
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :splashscreen
sig { params(splashscreen: T.nilable(T.nilable(String))).void }
def initialize(splashscreen: nil); end
end
class Offline < Stripe::RequestParams
# Determines whether to allow transactions to be collected while reader is offline. Defaults to false.
sig { returns(T::Boolean) }
attr_accessor :enabled
sig { params(enabled: T::Boolean).void }
def initialize(enabled: nil); end
end
class RebootWindow < Stripe::RequestParams
# Integer between 0 to 23 that represents the end hour of the reboot time window. The value must be different than the start_hour.
sig { returns(Integer) }
attr_accessor :end_hour
# Integer between 0 to 23 that represents the start hour of the reboot time window.
sig { returns(Integer) }
attr_accessor :start_hour
sig { params(end_hour: Integer, start_hour: Integer).void }
def initialize(end_hour: nil, start_hour: nil); end
end
class StripeS700 < Stripe::RequestParams
# A File ID representing an image you would like displayed on the reader.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :splashscreen
sig { params(splashscreen: T.nilable(T.nilable(String))).void }
def initialize(splashscreen: nil); end
end
class Tipping < Stripe::RequestParams
class Aud < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Cad < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Chf < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Czk < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Dkk < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Eur < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Gbp < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Hkd < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Jpy < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Myr < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Nok < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Nzd < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Pln < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Sek < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Sgd < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Usd < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
# Tipping configuration for AUD
sig {
returns(T.nilable(::Stripe::Terminal::ConfigurationService::UpdateParams::Tipping::Aud))
}
attr_accessor :aud
# Tipping configuration for CAD
sig {
returns(T.nilable(::Stripe::Terminal::ConfigurationService::UpdateParams::Tipping::Cad))
}
attr_accessor :cad
# Tipping configuration for CHF
sig {
returns(T.nilable(::Stripe::Terminal::ConfigurationService::UpdateParams::Tipping::Chf))
}
attr_accessor :chf
# Tipping configuration for CZK
sig {
returns(T.nilable(::Stripe::Terminal::ConfigurationService::UpdateParams::Tipping::Czk))
}
attr_accessor :czk
# Tipping configuration for DKK
sig {
returns(T.nilable(::Stripe::Terminal::ConfigurationService::UpdateParams::Tipping::Dkk))
}
attr_accessor :dkk
# Tipping configuration for EUR
sig {
returns(T.nilable(::Stripe::Terminal::ConfigurationService::UpdateParams::Tipping::Eur))
}
attr_accessor :eur
# Tipping configuration for GBP
sig {
returns(T.nilable(::Stripe::Terminal::ConfigurationService::UpdateParams::Tipping::Gbp))
}
attr_accessor :gbp
# Tipping configuration for HKD
sig {
returns(T.nilable(::Stripe::Terminal::ConfigurationService::UpdateParams::Tipping::Hkd))
}
attr_accessor :hkd
# Tipping configuration for JPY
sig {
returns(T.nilable(::Stripe::Terminal::ConfigurationService::UpdateParams::Tipping::Jpy))
}
attr_accessor :jpy
# Tipping configuration for MYR
sig {
returns(T.nilable(::Stripe::Terminal::ConfigurationService::UpdateParams::Tipping::Myr))
}
attr_accessor :myr
# Tipping configuration for NOK
sig {
returns(T.nilable(::Stripe::Terminal::ConfigurationService::UpdateParams::Tipping::Nok))
}
attr_accessor :nok
# Tipping configuration for NZD
sig {
returns(T.nilable(::Stripe::Terminal::ConfigurationService::UpdateParams::Tipping::Nzd))
}
attr_accessor :nzd
# Tipping configuration for PLN
sig {
returns(T.nilable(::Stripe::Terminal::ConfigurationService::UpdateParams::Tipping::Pln))
}
attr_accessor :pln
# Tipping configuration for SEK
sig {
returns(T.nilable(::Stripe::Terminal::ConfigurationService::UpdateParams::Tipping::Sek))
}
attr_accessor :sek
# Tipping configuration for SGD
sig {
returns(T.nilable(::Stripe::Terminal::ConfigurationService::UpdateParams::Tipping::Sgd))
}
attr_accessor :sgd
# Tipping configuration for USD
sig {
returns(T.nilable(::Stripe::Terminal::ConfigurationService::UpdateParams::Tipping::Usd))
}
attr_accessor :usd
sig {
params(aud: T.nilable(::Stripe::Terminal::ConfigurationService::UpdateParams::Tipping::Aud), cad: T.nilable(::Stripe::Terminal::ConfigurationService::UpdateParams::Tipping::Cad), chf: T.nilable(::Stripe::Terminal::ConfigurationService::UpdateParams::Tipping::Chf), czk: T.nilable(::Stripe::Terminal::ConfigurationService::UpdateParams::Tipping::Czk), dkk: T.nilable(::Stripe::Terminal::ConfigurationService::UpdateParams::Tipping::Dkk), eur: T.nilable(::Stripe::Terminal::ConfigurationService::UpdateParams::Tipping::Eur), gbp: T.nilable(::Stripe::Terminal::ConfigurationService::UpdateParams::Tipping::Gbp), hkd: T.nilable(::Stripe::Terminal::ConfigurationService::UpdateParams::Tipping::Hkd), jpy: T.nilable(::Stripe::Terminal::ConfigurationService::UpdateParams::Tipping::Jpy), myr: T.nilable(::Stripe::Terminal::ConfigurationService::UpdateParams::Tipping::Myr), nok: T.nilable(::Stripe::Terminal::ConfigurationService::UpdateParams::Tipping::Nok), nzd: T.nilable(::Stripe::Terminal::ConfigurationService::UpdateParams::Tipping::Nzd), pln: T.nilable(::Stripe::Terminal::ConfigurationService::UpdateParams::Tipping::Pln), sek: T.nilable(::Stripe::Terminal::ConfigurationService::UpdateParams::Tipping::Sek), sgd: T.nilable(::Stripe::Terminal::ConfigurationService::UpdateParams::Tipping::Sgd), usd: T.nilable(::Stripe::Terminal::ConfigurationService::UpdateParams::Tipping::Usd)).void
}
def initialize(
aud: nil,
cad: nil,
chf: nil,
czk: nil,
dkk: nil,
eur: nil,
gbp: nil,
hkd: nil,
jpy: nil,
myr: nil,
nok: nil,
nzd: nil,
pln: nil,
sek: nil,
sgd: nil,
usd: nil
); end
end
class VerifoneP400 < Stripe::RequestParams
# A File ID representing an image you would like displayed on the reader.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :splashscreen
sig { params(splashscreen: T.nilable(T.nilable(String))).void }
def initialize(splashscreen: nil); end
end
class Wifi < Stripe::RequestParams
class EnterpriseEapPeap < Stripe::RequestParams
# A File ID representing a PEM file containing the server certificate
sig { returns(T.nilable(String)) }
attr_accessor :ca_certificate_file
# Password for connecting to the WiFi network
sig { returns(String) }
attr_accessor :password
# Name of the WiFi network
sig { returns(String) }
attr_accessor :ssid
# Username for connecting to the WiFi network
sig { returns(String) }
attr_accessor :username
sig {
params(ca_certificate_file: T.nilable(String), password: String, ssid: String, username: String).void
}
def initialize(ca_certificate_file: nil, password: nil, ssid: nil, username: nil); end
end
class EnterpriseEapTls < Stripe::RequestParams
# A File ID representing a PEM file containing the server certificate
sig { returns(T.nilable(String)) }
attr_accessor :ca_certificate_file
# A File ID representing a PEM file containing the client certificate
sig { returns(String) }
attr_accessor :client_certificate_file
# A File ID representing a PEM file containing the client RSA private key
sig { returns(String) }
attr_accessor :private_key_file
# Password for the private key file
sig { returns(T.nilable(String)) }
attr_accessor :private_key_file_password
# Name of the WiFi network
sig { returns(String) }
attr_accessor :ssid
sig {
params(ca_certificate_file: T.nilable(String), client_certificate_file: String, private_key_file: String, private_key_file_password: T.nilable(String), ssid: String).void
}
def initialize(
ca_certificate_file: nil,
client_certificate_file: nil,
private_key_file: nil,
private_key_file_password: nil,
ssid: nil
); end
end
class PersonalPsk < Stripe::RequestParams
# Password for connecting to the WiFi network
sig { returns(String) }
attr_accessor :password
# Name of the WiFi network
sig { returns(String) }
attr_accessor :ssid
sig { params(password: String, ssid: String).void }
def initialize(password: nil, ssid: nil); end
end
# Credentials for a WPA-Enterprise WiFi network using the EAP-PEAP authentication method.
sig {
returns(T.nilable(::Stripe::Terminal::ConfigurationService::UpdateParams::Wifi::EnterpriseEapPeap))
}
attr_accessor :enterprise_eap_peap
# Credentials for a WPA-Enterprise WiFi network using the EAP-TLS authentication method.
sig {
returns(T.nilable(::Stripe::Terminal::ConfigurationService::UpdateParams::Wifi::EnterpriseEapTls))
}
attr_accessor :enterprise_eap_tls
# Credentials for a WPA-Personal WiFi network.
sig {
returns(T.nilable(::Stripe::Terminal::ConfigurationService::UpdateParams::Wifi::PersonalPsk))
}
attr_accessor :personal_psk
# Security type of the WiFi network. Fill out the hash with the corresponding name to provide the set of credentials for this security type.
sig { returns(String) }
attr_accessor :type
sig {
params(enterprise_eap_peap: T.nilable(::Stripe::Terminal::ConfigurationService::UpdateParams::Wifi::EnterpriseEapPeap), enterprise_eap_tls: T.nilable(::Stripe::Terminal::ConfigurationService::UpdateParams::Wifi::EnterpriseEapTls), personal_psk: T.nilable(::Stripe::Terminal::ConfigurationService::UpdateParams::Wifi::PersonalPsk), type: String).void
}
def initialize(
enterprise_eap_peap: nil,
enterprise_eap_tls: nil,
personal_psk: nil,
type: nil
); end
end
# An object containing device type specific settings for BBPOS WisePOS E readers
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Terminal::ConfigurationService::UpdateParams::BbposWiseposE))))
}
attr_accessor :bbpos_wisepos_e
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Name of the configuration
sig { returns(T.nilable(String)) }
attr_accessor :name
# Configurations for collecting transactions offline.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Terminal::ConfigurationService::UpdateParams::Offline))))
}
attr_accessor :offline
# Reboot time settings for readers that support customized reboot time configuration.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Terminal::ConfigurationService::UpdateParams::RebootWindow))))
}
attr_accessor :reboot_window
# An object containing device type specific settings for Stripe S700 readers
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Terminal::ConfigurationService::UpdateParams::StripeS700))))
}
attr_accessor :stripe_s700
# Tipping configurations for readers supporting on-reader tips
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Terminal::ConfigurationService::UpdateParams::Tipping))))
}
attr_accessor :tipping
# An object containing device type specific settings for Verifone P400 readers
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Terminal::ConfigurationService::UpdateParams::VerifoneP400))))
}
attr_accessor :verifone_p400
# Configurations for connecting to a WiFi network.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Terminal::ConfigurationService::UpdateParams::Wifi))))
}
attr_accessor :wifi
sig {
params(bbpos_wisepos_e: T.nilable(T.nilable(T.any(String, ::Stripe::Terminal::ConfigurationService::UpdateParams::BbposWiseposE))), expand: T.nilable(T::Array[String]), name: T.nilable(String), offline: T.nilable(T.nilable(T.any(String, ::Stripe::Terminal::ConfigurationService::UpdateParams::Offline))), reboot_window: T.nilable(T.nilable(T.any(String, ::Stripe::Terminal::ConfigurationService::UpdateParams::RebootWindow))), stripe_s700: T.nilable(T.nilable(T.any(String, ::Stripe::Terminal::ConfigurationService::UpdateParams::StripeS700))), tipping: T.nilable(T.nilable(T.any(String, ::Stripe::Terminal::ConfigurationService::UpdateParams::Tipping))), verifone_p400: T.nilable(T.nilable(T.any(String, ::Stripe::Terminal::ConfigurationService::UpdateParams::VerifoneP400))), wifi: T.nilable(T.nilable(T.any(String, ::Stripe::Terminal::ConfigurationService::UpdateParams::Wifi)))).void
}
def initialize(
bbpos_wisepos_e: nil,
expand: nil,
name: nil,
offline: nil,
reboot_window: nil,
stripe_s700: nil,
tipping: nil,
verifone_p400: nil,
wifi: nil
); end
end
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# if present, only return the account default or non-default configurations.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :is_account_default
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), is_account_default: T.nilable(T::Boolean), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
ending_before: nil,
expand: nil,
is_account_default: nil,
limit: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class BbposWiseposE < Stripe::RequestParams
# A File ID representing an image to display on the reader
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :splashscreen
sig { params(splashscreen: T.nilable(T.nilable(String))).void }
def initialize(splashscreen: nil); end
end
class Offline < Stripe::RequestParams
# Determines whether to allow transactions to be collected while reader is offline. Defaults to false.
sig { returns(T::Boolean) }
attr_accessor :enabled
sig { params(enabled: T::Boolean).void }
def initialize(enabled: nil); end
end
class RebootWindow < Stripe::RequestParams
# Integer between 0 to 23 that represents the end hour of the reboot time window. The value must be different than the start_hour.
sig { returns(Integer) }
attr_accessor :end_hour
# Integer between 0 to 23 that represents the start hour of the reboot time window.
sig { returns(Integer) }
attr_accessor :start_hour
sig { params(end_hour: Integer, start_hour: Integer).void }
def initialize(end_hour: nil, start_hour: nil); end
end
class StripeS700 < Stripe::RequestParams
# A File ID representing an image you would like displayed on the reader.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :splashscreen
sig { params(splashscreen: T.nilable(T.nilable(String))).void }
def initialize(splashscreen: nil); end
end
class Tipping < Stripe::RequestParams
class Aud < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Cad < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Chf < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Czk < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Dkk < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Eur < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Gbp < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Hkd < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Jpy < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Myr < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Nok < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Nzd < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Pln < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Sek < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Sgd < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
class Usd < Stripe::RequestParams
# Fixed amounts displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :fixed_amounts
# Percentages displayed when collecting a tip
sig { returns(T.nilable(T::Array[Integer])) }
attr_accessor :percentages
# Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
sig { returns(T.nilable(Integer)) }
attr_accessor :smart_tip_threshold
sig {
params(fixed_amounts: T.nilable(T::Array[Integer]), percentages: T.nilable(T::Array[Integer]), smart_tip_threshold: T.nilable(Integer)).void
}
def initialize(fixed_amounts: nil, percentages: nil, smart_tip_threshold: nil); end
end
# Tipping configuration for AUD
sig {
returns(T.nilable(::Stripe::Terminal::ConfigurationService::CreateParams::Tipping::Aud))
}
attr_accessor :aud
# Tipping configuration for CAD
sig {
returns(T.nilable(::Stripe::Terminal::ConfigurationService::CreateParams::Tipping::Cad))
}
attr_accessor :cad
# Tipping configuration for CHF
sig {
returns(T.nilable(::Stripe::Terminal::ConfigurationService::CreateParams::Tipping::Chf))
}
attr_accessor :chf
# Tipping configuration for CZK
sig {
returns(T.nilable(::Stripe::Terminal::ConfigurationService::CreateParams::Tipping::Czk))
}
attr_accessor :czk
# Tipping configuration for DKK
sig {
returns(T.nilable(::Stripe::Terminal::ConfigurationService::CreateParams::Tipping::Dkk))
}
attr_accessor :dkk
# Tipping configuration for EUR
sig {
returns(T.nilable(::Stripe::Terminal::ConfigurationService::CreateParams::Tipping::Eur))
}
attr_accessor :eur
# Tipping configuration for GBP
sig {
returns(T.nilable(::Stripe::Terminal::ConfigurationService::CreateParams::Tipping::Gbp))
}
attr_accessor :gbp
# Tipping configuration for HKD
sig {
returns(T.nilable(::Stripe::Terminal::ConfigurationService::CreateParams::Tipping::Hkd))
}
attr_accessor :hkd
# Tipping configuration for JPY
sig {
returns(T.nilable(::Stripe::Terminal::ConfigurationService::CreateParams::Tipping::Jpy))
}
attr_accessor :jpy
# Tipping configuration for MYR
sig {
returns(T.nilable(::Stripe::Terminal::ConfigurationService::CreateParams::Tipping::Myr))
}
attr_accessor :myr
# Tipping configuration for NOK
sig {
returns(T.nilable(::Stripe::Terminal::ConfigurationService::CreateParams::Tipping::Nok))
}
attr_accessor :nok
# Tipping configuration for NZD
sig {
returns(T.nilable(::Stripe::Terminal::ConfigurationService::CreateParams::Tipping::Nzd))
}
attr_accessor :nzd
# Tipping configuration for PLN
sig {
returns(T.nilable(::Stripe::Terminal::ConfigurationService::CreateParams::Tipping::Pln))
}
attr_accessor :pln
# Tipping configuration for SEK
sig {
returns(T.nilable(::Stripe::Terminal::ConfigurationService::CreateParams::Tipping::Sek))
}
attr_accessor :sek
# Tipping configuration for SGD
sig {
returns(T.nilable(::Stripe::Terminal::ConfigurationService::CreateParams::Tipping::Sgd))
}
attr_accessor :sgd
# Tipping configuration for USD
sig {
returns(T.nilable(::Stripe::Terminal::ConfigurationService::CreateParams::Tipping::Usd))
}
attr_accessor :usd
sig {
params(aud: T.nilable(::Stripe::Terminal::ConfigurationService::CreateParams::Tipping::Aud), cad: T.nilable(::Stripe::Terminal::ConfigurationService::CreateParams::Tipping::Cad), chf: T.nilable(::Stripe::Terminal::ConfigurationService::CreateParams::Tipping::Chf), czk: T.nilable(::Stripe::Terminal::ConfigurationService::CreateParams::Tipping::Czk), dkk: T.nilable(::Stripe::Terminal::ConfigurationService::CreateParams::Tipping::Dkk), eur: T.nilable(::Stripe::Terminal::ConfigurationService::CreateParams::Tipping::Eur), gbp: T.nilable(::Stripe::Terminal::ConfigurationService::CreateParams::Tipping::Gbp), hkd: T.nilable(::Stripe::Terminal::ConfigurationService::CreateParams::Tipping::Hkd), jpy: T.nilable(::Stripe::Terminal::ConfigurationService::CreateParams::Tipping::Jpy), myr: T.nilable(::Stripe::Terminal::ConfigurationService::CreateParams::Tipping::Myr), nok: T.nilable(::Stripe::Terminal::ConfigurationService::CreateParams::Tipping::Nok), nzd: T.nilable(::Stripe::Terminal::ConfigurationService::CreateParams::Tipping::Nzd), pln: T.nilable(::Stripe::Terminal::ConfigurationService::CreateParams::Tipping::Pln), sek: T.nilable(::Stripe::Terminal::ConfigurationService::CreateParams::Tipping::Sek), sgd: T.nilable(::Stripe::Terminal::ConfigurationService::CreateParams::Tipping::Sgd), usd: T.nilable(::Stripe::Terminal::ConfigurationService::CreateParams::Tipping::Usd)).void
}
def initialize(
aud: nil,
cad: nil,
chf: nil,
czk: nil,
dkk: nil,
eur: nil,
gbp: nil,
hkd: nil,
jpy: nil,
myr: nil,
nok: nil,
nzd: nil,
pln: nil,
sek: nil,
sgd: nil,
usd: nil
); end
end
class VerifoneP400 < Stripe::RequestParams
# A File ID representing an image you would like displayed on the reader.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :splashscreen
sig { params(splashscreen: T.nilable(T.nilable(String))).void }
def initialize(splashscreen: nil); end
end
class Wifi < Stripe::RequestParams
class EnterpriseEapPeap < Stripe::RequestParams
# A File ID representing a PEM file containing the server certificate
sig { returns(T.nilable(String)) }
attr_accessor :ca_certificate_file
# Password for connecting to the WiFi network
sig { returns(String) }
attr_accessor :password
# Name of the WiFi network
sig { returns(String) }
attr_accessor :ssid
# Username for connecting to the WiFi network
sig { returns(String) }
attr_accessor :username
sig {
params(ca_certificate_file: T.nilable(String), password: String, ssid: String, username: String).void
}
def initialize(ca_certificate_file: nil, password: nil, ssid: nil, username: nil); end
end
class EnterpriseEapTls < Stripe::RequestParams
# A File ID representing a PEM file containing the server certificate
sig { returns(T.nilable(String)) }
attr_accessor :ca_certificate_file
# A File ID representing a PEM file containing the client certificate
sig { returns(String) }
attr_accessor :client_certificate_file
# A File ID representing a PEM file containing the client RSA private key
sig { returns(String) }
attr_accessor :private_key_file
# Password for the private key file
sig { returns(T.nilable(String)) }
attr_accessor :private_key_file_password
# Name of the WiFi network
sig { returns(String) }
attr_accessor :ssid
sig {
params(ca_certificate_file: T.nilable(String), client_certificate_file: String, private_key_file: String, private_key_file_password: T.nilable(String), ssid: String).void
}
def initialize(
ca_certificate_file: nil,
client_certificate_file: nil,
private_key_file: nil,
private_key_file_password: nil,
ssid: nil
); end
end
class PersonalPsk < Stripe::RequestParams
# Password for connecting to the WiFi network
sig { returns(String) }
attr_accessor :password
# Name of the WiFi network
sig { returns(String) }
attr_accessor :ssid
sig { params(password: String, ssid: String).void }
def initialize(password: nil, ssid: nil); end
end
# Credentials for a WPA-Enterprise WiFi network using the EAP-PEAP authentication method.
sig {
returns(T.nilable(::Stripe::Terminal::ConfigurationService::CreateParams::Wifi::EnterpriseEapPeap))
}
attr_accessor :enterprise_eap_peap
# Credentials for a WPA-Enterprise WiFi network using the EAP-TLS authentication method.
sig {
returns(T.nilable(::Stripe::Terminal::ConfigurationService::CreateParams::Wifi::EnterpriseEapTls))
}
attr_accessor :enterprise_eap_tls
# Credentials for a WPA-Personal WiFi network.
sig {
returns(T.nilable(::Stripe::Terminal::ConfigurationService::CreateParams::Wifi::PersonalPsk))
}
attr_accessor :personal_psk
# Security type of the WiFi network. Fill out the hash with the corresponding name to provide the set of credentials for this security type.
sig { returns(String) }
attr_accessor :type
sig {
params(enterprise_eap_peap: T.nilable(::Stripe::Terminal::ConfigurationService::CreateParams::Wifi::EnterpriseEapPeap), enterprise_eap_tls: T.nilable(::Stripe::Terminal::ConfigurationService::CreateParams::Wifi::EnterpriseEapTls), personal_psk: T.nilable(::Stripe::Terminal::ConfigurationService::CreateParams::Wifi::PersonalPsk), type: String).void
}
def initialize(
enterprise_eap_peap: nil,
enterprise_eap_tls: nil,
personal_psk: nil,
type: nil
); end
end
# An object containing device type specific settings for BBPOS WisePOS E readers
sig {
returns(T.nilable(::Stripe::Terminal::ConfigurationService::CreateParams::BbposWiseposE))
}
attr_accessor :bbpos_wisepos_e
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Name of the configuration
sig { returns(T.nilable(String)) }
attr_accessor :name
# Configurations for collecting transactions offline.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Terminal::ConfigurationService::CreateParams::Offline))))
}
attr_accessor :offline
# Reboot time settings for readers that support customized reboot time configuration.
sig {
returns(T.nilable(::Stripe::Terminal::ConfigurationService::CreateParams::RebootWindow))
}
attr_accessor :reboot_window
# An object containing device type specific settings for Stripe S700 readers
sig {
returns(T.nilable(::Stripe::Terminal::ConfigurationService::CreateParams::StripeS700))
}
attr_accessor :stripe_s700
# Tipping configurations for readers supporting on-reader tips
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Terminal::ConfigurationService::CreateParams::Tipping))))
}
attr_accessor :tipping
# An object containing device type specific settings for Verifone P400 readers
sig {
returns(T.nilable(::Stripe::Terminal::ConfigurationService::CreateParams::VerifoneP400))
}
attr_accessor :verifone_p400
# Configurations for connecting to a WiFi network.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Terminal::ConfigurationService::CreateParams::Wifi))))
}
attr_accessor :wifi
sig {
params(bbpos_wisepos_e: T.nilable(::Stripe::Terminal::ConfigurationService::CreateParams::BbposWiseposE), expand: T.nilable(T::Array[String]), name: T.nilable(String), offline: T.nilable(T.nilable(T.any(String, ::Stripe::Terminal::ConfigurationService::CreateParams::Offline))), reboot_window: T.nilable(::Stripe::Terminal::ConfigurationService::CreateParams::RebootWindow), stripe_s700: T.nilable(::Stripe::Terminal::ConfigurationService::CreateParams::StripeS700), tipping: T.nilable(T.nilable(T.any(String, ::Stripe::Terminal::ConfigurationService::CreateParams::Tipping))), verifone_p400: T.nilable(::Stripe::Terminal::ConfigurationService::CreateParams::VerifoneP400), wifi: T.nilable(T.nilable(T.any(String, ::Stripe::Terminal::ConfigurationService::CreateParams::Wifi)))).void
}
def initialize(
bbpos_wisepos_e: nil,
expand: nil,
name: nil,
offline: nil,
reboot_window: nil,
stripe_s700: nil,
tipping: nil,
verifone_p400: nil,
wifi: nil
); end
end
# Creates a new Configuration object.
sig {
params(params: T.any(::Stripe::Terminal::ConfigurationService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Configuration)
}
def create(params = {}, opts = {}); end
# Deletes a Configuration object.
sig {
params(configuration: String, params: T.any(::Stripe::Terminal::ConfigurationService::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Configuration)
}
def delete(configuration, params = {}, opts = {}); end
# Returns a list of Configuration objects.
sig {
params(params: T.any(::Stripe::Terminal::ConfigurationService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves a Configuration object.
sig {
params(configuration: String, params: T.any(::Stripe::Terminal::ConfigurationService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Configuration)
}
def retrieve(configuration, params = {}, opts = {}); end
# Updates a new Configuration object.
sig {
params(configuration: String, params: T.any(::Stripe::Terminal::ConfigurationService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Configuration)
}
def update(configuration, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Terminal
class ConnectionTokenService < StripeService
class CreateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The id of the location that this connection token is scoped to. If specified the connection token will only be usable with readers assigned to that location, otherwise the connection token will be usable with all readers. Note that location scoping only applies to internet-connected readers. For more details, see [the docs on scoping connection tokens](https://docs.stripe.com/terminal/fleet/locations-and-zones?dashboard-or-api=api#connection-tokens).
sig { returns(T.nilable(String)) }
attr_accessor :location
sig { params(expand: T.nilable(T::Array[String]), location: T.nilable(String)).void }
def initialize(expand: nil, location: nil); end
end
# To connect to a reader the Stripe Terminal SDK needs to retrieve a short-lived connection token from Stripe, proxied through your server. On your backend, add an endpoint that creates and returns a connection token.
sig {
params(params: T.any(::Stripe::Terminal::ConnectionTokenService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::ConnectionToken)
}
def create(params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Terminal
class LocationService < StripeService
class DeleteParams < Stripe::RequestParams; end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# The full address of the location. You can't change the location's `country`. If you need to modify the `country` field, create a new `Location` object and re-register any existing readers to that location.
sig { returns(T.nilable(::Stripe::Terminal::LocationService::UpdateParams::Address)) }
attr_accessor :address
# The ID of a configuration that will be used to customize all readers in this location.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :configuration_overrides
# A name for the location.
sig { returns(T.nilable(String)) }
attr_accessor :display_name
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
sig {
params(address: T.nilable(::Stripe::Terminal::LocationService::UpdateParams::Address), configuration_overrides: T.nilable(T.nilable(String)), display_name: T.nilable(String), expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String])))).void
}
def initialize(
address: nil,
configuration_overrides: nil,
display_name: nil,
expand: nil,
metadata: nil
); end
end
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
class CreateParams < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(String) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: String, line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# The full address of the location.
sig { returns(::Stripe::Terminal::LocationService::CreateParams::Address) }
attr_accessor :address
# The ID of a configuration that will be used to customize all readers in this location.
sig { returns(T.nilable(String)) }
attr_accessor :configuration_overrides
# A name for the location. Maximum length is 1000 characters.
sig { returns(String) }
attr_accessor :display_name
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
sig {
params(address: ::Stripe::Terminal::LocationService::CreateParams::Address, configuration_overrides: T.nilable(String), display_name: String, expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String])))).void
}
def initialize(
address: nil,
configuration_overrides: nil,
display_name: nil,
expand: nil,
metadata: nil
); end
end
# Creates a new Location object.
# For further details, including which address fields are required in each country, see the [Manage locations](https://docs.stripe.com/docs/terminal/fleet/locations) guide.
sig {
params(params: T.any(::Stripe::Terminal::LocationService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Location)
}
def create(params = {}, opts = {}); end
# Deletes a Location object.
sig {
params(location: String, params: T.any(::Stripe::Terminal::LocationService::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Location)
}
def delete(location, params = {}, opts = {}); end
# Returns a list of Location objects.
sig {
params(params: T.any(::Stripe::Terminal::LocationService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves a Location object.
sig {
params(location: String, params: T.any(::Stripe::Terminal::LocationService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Location)
}
def retrieve(location, params = {}, opts = {}); end
# Updates a Location object by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
sig {
params(location: String, params: T.any(::Stripe::Terminal::LocationService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Location)
}
def update(location, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Terminal
class ReaderService < StripeService
class DeleteParams < Stripe::RequestParams; end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The new label of the reader.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :label
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
sig {
params(expand: T.nilable(T::Array[String]), label: T.nilable(T.nilable(String)), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String])))).void
}
def initialize(expand: nil, label: nil, metadata: nil); end
end
class ListParams < Stripe::RequestParams
# Filters readers by device type
sig { returns(T.nilable(String)) }
attr_accessor :device_type
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A location ID to filter the response list to only readers at the specific location
sig { returns(T.nilable(String)) }
attr_accessor :location
# Filters readers by serial number
sig { returns(T.nilable(String)) }
attr_accessor :serial_number
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# A status filter to filter readers to only offline or online readers
sig { returns(T.nilable(String)) }
attr_accessor :status
sig {
params(device_type: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), location: T.nilable(String), serial_number: T.nilable(String), starting_after: T.nilable(String), status: T.nilable(String)).void
}
def initialize(
device_type: nil,
ending_before: nil,
expand: nil,
limit: nil,
location: nil,
serial_number: nil,
starting_after: nil,
status: nil
); end
end
class CreateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Custom label given to the reader for easier identification. If no label is specified, the registration code will be used.
sig { returns(T.nilable(String)) }
attr_accessor :label
# The location to assign the reader to.
sig { returns(T.nilable(String)) }
attr_accessor :location
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# A code generated by the reader used for registering to an account.
sig { returns(String) }
attr_accessor :registration_code
sig {
params(expand: T.nilable(T::Array[String]), label: T.nilable(String), location: T.nilable(String), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), registration_code: String).void
}
def initialize(
expand: nil,
label: nil,
location: nil,
metadata: nil,
registration_code: nil
); end
end
class CancelActionParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class CollectInputsParams < Stripe::RequestParams
class Input < Stripe::RequestParams
class CustomText < Stripe::RequestParams
# The description which will be displayed when collecting this input
sig { returns(T.nilable(String)) }
attr_accessor :description
# The skip button text
sig { returns(T.nilable(String)) }
attr_accessor :skip_button
# The submit button text
sig { returns(T.nilable(String)) }
attr_accessor :submit_button
# The title which will be displayed when collecting this input
sig { returns(String) }
attr_accessor :title
sig {
params(description: T.nilable(String), skip_button: T.nilable(String), submit_button: T.nilable(String), title: String).void
}
def initialize(description: nil, skip_button: nil, submit_button: nil, title: nil); end
end
class Selection < Stripe::RequestParams
class Choice < Stripe::RequestParams
# The unique identifier for this choice
sig { returns(String) }
attr_accessor :id
# The style of the button which will be shown for this choice
sig { returns(T.nilable(String)) }
attr_accessor :style
# The text which will be shown on the button for this choice
sig { returns(String) }
attr_accessor :text
sig { params(id: String, style: T.nilable(String), text: String).void }
def initialize(id: nil, style: nil, text: nil); end
end
# List of choices for the `selection` input
sig {
returns(T::Array[::Stripe::Terminal::ReaderService::CollectInputsParams::Input::Selection::Choice])
}
attr_accessor :choices
sig {
params(choices: T::Array[::Stripe::Terminal::ReaderService::CollectInputsParams::Input::Selection::Choice]).void
}
def initialize(choices: nil); end
end
class Toggle < Stripe::RequestParams
# The default value of the toggle
sig { returns(T.nilable(String)) }
attr_accessor :default_value
# The description which will be displayed for the toggle
sig { returns(T.nilable(String)) }
attr_accessor :description
# The title which will be displayed for the toggle
sig { returns(T.nilable(String)) }
attr_accessor :title
sig {
params(default_value: T.nilable(String), description: T.nilable(String), title: T.nilable(String)).void
}
def initialize(default_value: nil, description: nil, title: nil); end
end
# Customize the text which will be displayed while collecting this input
sig { returns(::Stripe::Terminal::ReaderService::CollectInputsParams::Input::CustomText) }
attr_accessor :custom_text
# Indicate that this input is required, disabling the skip button
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :required
# Options for the `selection` input
sig {
returns(T.nilable(::Stripe::Terminal::ReaderService::CollectInputsParams::Input::Selection))
}
attr_accessor :selection
# List of toggles to be displayed and customization for the toggles
sig {
returns(T.nilable(T::Array[::Stripe::Terminal::ReaderService::CollectInputsParams::Input::Toggle]))
}
attr_accessor :toggles
# The type of input to collect
sig { returns(String) }
attr_accessor :type
sig {
params(custom_text: ::Stripe::Terminal::ReaderService::CollectInputsParams::Input::CustomText, required: T.nilable(T::Boolean), selection: T.nilable(::Stripe::Terminal::ReaderService::CollectInputsParams::Input::Selection), toggles: T.nilable(T::Array[::Stripe::Terminal::ReaderService::CollectInputsParams::Input::Toggle]), type: String).void
}
def initialize(
custom_text: nil,
required: nil,
selection: nil,
toggles: nil,
type: nil
); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# List of inputs to be collected using the Reader
sig { returns(T::Array[::Stripe::Terminal::ReaderService::CollectInputsParams::Input]) }
attr_accessor :inputs
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
sig {
params(expand: T.nilable(T::Array[String]), inputs: T::Array[::Stripe::Terminal::ReaderService::CollectInputsParams::Input], metadata: T.nilable(T::Hash[String, String])).void
}
def initialize(expand: nil, inputs: nil, metadata: nil); end
end
class CollectPaymentMethodParams < Stripe::RequestParams
class CollectConfig < Stripe::RequestParams
class Tipping < Stripe::RequestParams
# Amount used to calculate tip suggestions on tipping selection screen for this transaction. Must be a positive integer in the smallest currency unit (e.g., 100 cents to represent $1.00 or 100 to represent ¥100, a zero-decimal currency).
sig { returns(T.nilable(Integer)) }
attr_accessor :amount_eligible
sig { params(amount_eligible: T.nilable(Integer)).void }
def initialize(amount_eligible: nil); end
end
# This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow.
sig { returns(T.nilable(String)) }
attr_accessor :allow_redisplay
# Enables cancel button on transaction screens.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :enable_customer_cancellation
# Override showing a tipping selection screen on this transaction.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :skip_tipping
# Tipping configuration for this transaction.
sig {
returns(T.nilable(::Stripe::Terminal::ReaderService::CollectPaymentMethodParams::CollectConfig::Tipping))
}
attr_accessor :tipping
sig {
params(allow_redisplay: T.nilable(String), enable_customer_cancellation: T.nilable(T::Boolean), skip_tipping: T.nilable(T::Boolean), tipping: T.nilable(::Stripe::Terminal::ReaderService::CollectPaymentMethodParams::CollectConfig::Tipping)).void
}
def initialize(
allow_redisplay: nil,
enable_customer_cancellation: nil,
skip_tipping: nil,
tipping: nil
); end
end
# Configuration overrides
sig {
returns(T.nilable(::Stripe::Terminal::ReaderService::CollectPaymentMethodParams::CollectConfig))
}
attr_accessor :collect_config
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# PaymentIntent ID
sig { returns(String) }
attr_accessor :payment_intent
sig {
params(collect_config: T.nilable(::Stripe::Terminal::ReaderService::CollectPaymentMethodParams::CollectConfig), expand: T.nilable(T::Array[String]), payment_intent: String).void
}
def initialize(collect_config: nil, expand: nil, payment_intent: nil); end
end
class ConfirmPaymentIntentParams < Stripe::RequestParams
class ConfirmConfig < Stripe::RequestParams
# The URL to redirect your customer back to after they authenticate or cancel their payment on the payment method's app or site. If you'd prefer to redirect to a mobile application, you can alternatively supply an application URI scheme.
sig { returns(T.nilable(String)) }
attr_accessor :return_url
sig { params(return_url: T.nilable(String)).void }
def initialize(return_url: nil); end
end
# Configuration overrides
sig {
returns(T.nilable(::Stripe::Terminal::ReaderService::ConfirmPaymentIntentParams::ConfirmConfig))
}
attr_accessor :confirm_config
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# PaymentIntent ID
sig { returns(String) }
attr_accessor :payment_intent
sig {
params(confirm_config: T.nilable(::Stripe::Terminal::ReaderService::ConfirmPaymentIntentParams::ConfirmConfig), expand: T.nilable(T::Array[String]), payment_intent: String).void
}
def initialize(confirm_config: nil, expand: nil, payment_intent: nil); end
end
class ProcessPaymentIntentParams < Stripe::RequestParams
class ProcessConfig < Stripe::RequestParams
class Tipping < Stripe::RequestParams
# Amount used to calculate tip suggestions on tipping selection screen for this transaction. Must be a positive integer in the smallest currency unit (e.g., 100 cents to represent $1.00 or 100 to represent ¥100, a zero-decimal currency).
sig { returns(T.nilable(Integer)) }
attr_accessor :amount_eligible
sig { params(amount_eligible: T.nilable(Integer)).void }
def initialize(amount_eligible: nil); end
end
# This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow.
sig { returns(T.nilable(String)) }
attr_accessor :allow_redisplay
# Enables cancel button on transaction screens.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :enable_customer_cancellation
# The URL to redirect your customer back to after they authenticate or cancel their payment on the payment method's app or site. If you'd prefer to redirect to a mobile application, you can alternatively supply an application URI scheme.
sig { returns(T.nilable(String)) }
attr_accessor :return_url
# Override showing a tipping selection screen on this transaction.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :skip_tipping
# Tipping configuration for this transaction.
sig {
returns(T.nilable(::Stripe::Terminal::ReaderService::ProcessPaymentIntentParams::ProcessConfig::Tipping))
}
attr_accessor :tipping
sig {
params(allow_redisplay: T.nilable(String), enable_customer_cancellation: T.nilable(T::Boolean), return_url: T.nilable(String), skip_tipping: T.nilable(T::Boolean), tipping: T.nilable(::Stripe::Terminal::ReaderService::ProcessPaymentIntentParams::ProcessConfig::Tipping)).void
}
def initialize(
allow_redisplay: nil,
enable_customer_cancellation: nil,
return_url: nil,
skip_tipping: nil,
tipping: nil
); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# PaymentIntent ID
sig { returns(String) }
attr_accessor :payment_intent
# Configuration overrides
sig {
returns(T.nilable(::Stripe::Terminal::ReaderService::ProcessPaymentIntentParams::ProcessConfig))
}
attr_accessor :process_config
sig {
params(expand: T.nilable(T::Array[String]), payment_intent: String, process_config: T.nilable(::Stripe::Terminal::ReaderService::ProcessPaymentIntentParams::ProcessConfig)).void
}
def initialize(expand: nil, payment_intent: nil, process_config: nil); end
end
class ProcessSetupIntentParams < Stripe::RequestParams
class ProcessConfig < Stripe::RequestParams
# Enables cancel button on transaction screens.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :enable_customer_cancellation
sig { params(enable_customer_cancellation: T.nilable(T::Boolean)).void }
def initialize(enable_customer_cancellation: nil); end
end
# This field indicates whether this payment method can be shown again to its customer in a checkout flow. Stripe products such as Checkout and Elements use this field to determine whether a payment method can be shown as a saved payment method in a checkout flow.
sig { returns(String) }
attr_accessor :allow_redisplay
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Configuration overrides
sig {
returns(T.nilable(::Stripe::Terminal::ReaderService::ProcessSetupIntentParams::ProcessConfig))
}
attr_accessor :process_config
# SetupIntent ID
sig { returns(String) }
attr_accessor :setup_intent
sig {
params(allow_redisplay: String, expand: T.nilable(T::Array[String]), process_config: T.nilable(::Stripe::Terminal::ReaderService::ProcessSetupIntentParams::ProcessConfig), setup_intent: String).void
}
def initialize(
allow_redisplay: nil,
expand: nil,
process_config: nil,
setup_intent: nil
); end
end
class RefundPaymentParams < Stripe::RequestParams
class RefundPaymentConfig < Stripe::RequestParams
# Enables cancel button on transaction screens.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :enable_customer_cancellation
sig { params(enable_customer_cancellation: T.nilable(T::Boolean)).void }
def initialize(enable_customer_cancellation: nil); end
end
# A positive integer in __cents__ representing how much of this charge to refund.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# ID of the Charge to refund.
sig { returns(T.nilable(String)) }
attr_accessor :charge
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# ID of the PaymentIntent to refund.
sig { returns(T.nilable(String)) }
attr_accessor :payment_intent
# Boolean indicating whether the application fee should be refunded when refunding this charge. If a full charge refund is given, the full application fee will be refunded. Otherwise, the application fee will be refunded in an amount proportional to the amount of the charge refunded. An application fee can be refunded only by the application that created the charge.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :refund_application_fee
# Configuration overrides
sig {
returns(T.nilable(::Stripe::Terminal::ReaderService::RefundPaymentParams::RefundPaymentConfig))
}
attr_accessor :refund_payment_config
# Boolean indicating whether the transfer should be reversed when refunding this charge. The transfer will be reversed proportionally to the amount being refunded (either the entire or partial amount). A transfer can be reversed only by the application that created the charge.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :reverse_transfer
sig {
params(amount: T.nilable(Integer), charge: T.nilable(String), expand: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), payment_intent: T.nilable(String), refund_application_fee: T.nilable(T::Boolean), refund_payment_config: T.nilable(::Stripe::Terminal::ReaderService::RefundPaymentParams::RefundPaymentConfig), reverse_transfer: T.nilable(T::Boolean)).void
}
def initialize(
amount: nil,
charge: nil,
expand: nil,
metadata: nil,
payment_intent: nil,
refund_application_fee: nil,
refund_payment_config: nil,
reverse_transfer: nil
); end
end
class SetReaderDisplayParams < Stripe::RequestParams
class Cart < Stripe::RequestParams
class LineItem < Stripe::RequestParams
# The price of the item in cents.
sig { returns(Integer) }
attr_accessor :amount
# The description or name of the item.
sig { returns(String) }
attr_accessor :description
# The quantity of the line item being purchased.
sig { returns(Integer) }
attr_accessor :quantity
sig { params(amount: Integer, description: String, quantity: Integer).void }
def initialize(amount: nil, description: nil, quantity: nil); end
end
# 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).
sig { returns(String) }
attr_accessor :currency
# Array of line items that were purchased.
sig {
returns(T::Array[::Stripe::Terminal::ReaderService::SetReaderDisplayParams::Cart::LineItem])
}
attr_accessor :line_items
# The amount of tax in cents.
sig { returns(T.nilable(Integer)) }
attr_accessor :tax
# Total balance of cart due in cents.
sig { returns(Integer) }
attr_accessor :total
sig {
params(currency: String, line_items: T::Array[::Stripe::Terminal::ReaderService::SetReaderDisplayParams::Cart::LineItem], tax: T.nilable(Integer), total: Integer).void
}
def initialize(currency: nil, line_items: nil, tax: nil, total: nil); end
end
# Cart
sig { returns(T.nilable(::Stripe::Terminal::ReaderService::SetReaderDisplayParams::Cart)) }
attr_accessor :cart
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Type
sig { returns(String) }
attr_accessor :type
sig {
params(cart: T.nilable(::Stripe::Terminal::ReaderService::SetReaderDisplayParams::Cart), expand: T.nilable(T::Array[String]), type: String).void
}
def initialize(cart: nil, expand: nil, type: nil); end
end
# Cancels the current reader action.
sig {
params(reader: String, params: T.any(::Stripe::Terminal::ReaderService::CancelActionParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Reader)
}
def cancel_action(reader, params = {}, opts = {}); end
# Initiates an input collection flow on a Reader.
sig {
params(reader: String, params: T.any(::Stripe::Terminal::ReaderService::CollectInputsParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Reader)
}
def collect_inputs(reader, params = {}, opts = {}); end
# Initiates a payment flow on a Reader and updates the PaymentIntent with card details before manual confirmation.
sig {
params(reader: String, params: T.any(::Stripe::Terminal::ReaderService::CollectPaymentMethodParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Reader)
}
def collect_payment_method(reader, params = {}, opts = {}); end
# Finalizes a payment on a Reader.
sig {
params(reader: String, params: T.any(::Stripe::Terminal::ReaderService::ConfirmPaymentIntentParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Reader)
}
def confirm_payment_intent(reader, params = {}, opts = {}); end
# Creates a new Reader object.
sig {
params(params: T.any(::Stripe::Terminal::ReaderService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Reader)
}
def create(params = {}, opts = {}); end
# Deletes a Reader object.
sig {
params(reader: String, params: T.any(::Stripe::Terminal::ReaderService::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Reader)
}
def delete(reader, params = {}, opts = {}); end
# Returns a list of Reader objects.
sig {
params(params: T.any(::Stripe::Terminal::ReaderService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Initiates a payment flow on a Reader.
sig {
params(reader: String, params: T.any(::Stripe::Terminal::ReaderService::ProcessPaymentIntentParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Reader)
}
def process_payment_intent(reader, params = {}, opts = {}); end
# Initiates a setup intent flow on a Reader.
sig {
params(reader: String, params: T.any(::Stripe::Terminal::ReaderService::ProcessSetupIntentParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Reader)
}
def process_setup_intent(reader, params = {}, opts = {}); end
# Initiates a refund on a Reader
sig {
params(reader: String, params: T.any(::Stripe::Terminal::ReaderService::RefundPaymentParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Reader)
}
def refund_payment(reader, params = {}, opts = {}); end
# Retrieves a Reader object.
sig {
params(reader: String, params: T.any(::Stripe::Terminal::ReaderService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Reader)
}
def retrieve(reader, params = {}, opts = {}); end
# Sets reader display to show cart details.
sig {
params(reader: String, params: T.any(::Stripe::Terminal::ReaderService::SetReaderDisplayParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Reader)
}
def set_reader_display(reader, params = {}, opts = {}); end
# Updates a Reader object by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
sig {
params(reader: String, params: T.any(::Stripe::Terminal::ReaderService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::Reader)
}
def update(reader, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Terminal
class ReaderCollectedDataService < StripeService
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Retrieve data collected using Reader hardware.
sig {
params(reader_collected_data: String, params: T.any(::Stripe::Terminal::ReaderCollectedDataService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Terminal::ReaderCollectedData)
}
def retrieve(reader_collected_data, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
class TokenService < StripeService
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class CreateParams < Stripe::RequestParams
class Account < Stripe::RequestParams
class Company < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class AddressKana < Stripe::RequestParams
# City or ward.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Block or building number.
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Building details.
sig { returns(T.nilable(String)) }
attr_accessor :line2
# Postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# Prefecture.
sig { returns(T.nilable(String)) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_accessor :town
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), town: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
class AddressKanji < Stripe::RequestParams
# City or ward.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Block or building number.
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Building details.
sig { returns(T.nilable(String)) }
attr_accessor :line2
# Postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# Prefecture.
sig { returns(T.nilable(String)) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_accessor :town
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), town: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
class DirectorshipDeclaration < Stripe::RequestParams
# The Unix timestamp marking when the directorship declaration attestation was made.
sig { returns(T.nilable(Integer)) }
attr_accessor :date
# The IP address from which the directorship declaration attestation was made.
sig { returns(T.nilable(String)) }
attr_accessor :ip
# The user agent of the browser from which the directorship declaration attestation was made.
sig { returns(T.nilable(String)) }
attr_accessor :user_agent
sig {
params(date: T.nilable(Integer), ip: T.nilable(String), user_agent: T.nilable(String)).void
}
def initialize(date: nil, ip: nil, user_agent: nil); end
end
class OwnershipDeclaration < Stripe::RequestParams
# The Unix timestamp marking when the beneficial owner attestation was made.
sig { returns(T.nilable(Integer)) }
attr_accessor :date
# The IP address from which the beneficial owner attestation was made.
sig { returns(T.nilable(String)) }
attr_accessor :ip
# The user agent of the browser from which the beneficial owner attestation was made.
sig { returns(T.nilable(String)) }
attr_accessor :user_agent
sig {
params(date: T.nilable(Integer), ip: T.nilable(String), user_agent: T.nilable(String)).void
}
def initialize(date: nil, ip: nil, user_agent: nil); end
end
class RegistrationDate < Stripe::RequestParams
# The day of registration, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of registration, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of registration.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
class Verification < Stripe::RequestParams
class Document < Stripe::RequestParams
# The back of a document returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `additional_verification`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :back
# The front of a document returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `additional_verification`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :front
sig { params(back: T.nilable(String), front: T.nilable(String)).void }
def initialize(back: nil, front: nil); end
end
# A document verifying the business.
sig {
returns(T.nilable(::Stripe::TokenService::CreateParams::Account::Company::Verification::Document))
}
attr_accessor :document
sig {
params(document: T.nilable(::Stripe::TokenService::CreateParams::Account::Company::Verification::Document)).void
}
def initialize(document: nil); end
end
# The company's primary address.
sig {
returns(T.nilable(::Stripe::TokenService::CreateParams::Account::Company::Address))
}
attr_accessor :address
# The Kana variation of the company's primary address (Japan only).
sig {
returns(T.nilable(::Stripe::TokenService::CreateParams::Account::Company::AddressKana))
}
attr_accessor :address_kana
# The Kanji variation of the company's primary address (Japan only).
sig {
returns(T.nilable(::Stripe::TokenService::CreateParams::Account::Company::AddressKanji))
}
attr_accessor :address_kanji
# Whether the company's directors have been provided. Set this Boolean to `true` after creating all the company's directors with [the Persons API](/api/persons) for accounts with a `relationship.director` requirement. This value is not automatically set to `true` after creating directors, so it needs to be updated to indicate all directors have been provided.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :directors_provided
# This hash is used to attest that the directors information provided to Stripe is both current and correct.
sig {
returns(T.nilable(::Stripe::TokenService::CreateParams::Account::Company::DirectorshipDeclaration))
}
attr_accessor :directorship_declaration
# Whether the company's executives have been provided. Set this Boolean to `true` after creating all the company's executives with [the Persons API](/api/persons) for accounts with a `relationship.executive` requirement.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :executives_provided
# The export license ID number of the company, also referred as Import Export Code (India only).
sig { returns(T.nilable(String)) }
attr_accessor :export_license_id
# The purpose code to use for export transactions (India only).
sig { returns(T.nilable(String)) }
attr_accessor :export_purpose_code
# The company's legal name.
sig { returns(T.nilable(String)) }
attr_accessor :name
# The Kana variation of the company's legal name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :name_kana
# The Kanji variation of the company's legal name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :name_kanji
# Whether the company's owners have been provided. Set this Boolean to `true` after creating all the company's owners with [the Persons API](/api/persons) for accounts with a `relationship.owner` requirement.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :owners_provided
# This hash is used to attest that the beneficial owner information provided to Stripe is both current and correct.
sig {
returns(T.nilable(::Stripe::TokenService::CreateParams::Account::Company::OwnershipDeclaration))
}
attr_accessor :ownership_declaration
# Whether the user described by the data in the token has been shown the Ownership Declaration and indicated that it is correct.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :ownership_declaration_shown_and_signed
# This value is used to determine if a business is exempt from providing ultimate beneficial owners. See [this support article](https://support.stripe.com/questions/exemption-from-providing-ownership-details) and [changelog](https://docs.stripe.com/changelog/acacia/2025-01-27/ownership-exemption-reason-accounts-api) for more details.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :ownership_exemption_reason
# The company's phone number (used for verification).
sig { returns(T.nilable(String)) }
attr_accessor :phone
# Attribute for param field registration_date
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::TokenService::CreateParams::Account::Company::RegistrationDate))))
}
attr_accessor :registration_date
# The identification number given to a company when it is registered or incorporated, if distinct from the identification number used for filing taxes. (Examples are the CIN for companies and LLP IN for partnerships in India, and the Company Registration Number in Hong Kong).
sig { returns(T.nilable(String)) }
attr_accessor :registration_number
# The category identifying the legal structure of the company or legal entity. See [Business structure](/connect/identity-verification#business-structure) for more details. Pass an empty string to unset this value.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :structure
# The business ID number of the company, as appropriate for the company’s country. (Examples are an Employer ID Number in the U.S., a Business Number in Canada, or a Company Number in the UK.)
sig { returns(T.nilable(String)) }
attr_accessor :tax_id
# The jurisdiction in which the `tax_id` is registered (Germany-based companies only).
sig { returns(T.nilable(String)) }
attr_accessor :tax_id_registrar
# The VAT number of the company.
sig { returns(T.nilable(String)) }
attr_accessor :vat_id
# Information on the verification state of the company.
sig {
returns(T.nilable(::Stripe::TokenService::CreateParams::Account::Company::Verification))
}
attr_accessor :verification
sig {
params(address: T.nilable(::Stripe::TokenService::CreateParams::Account::Company::Address), address_kana: T.nilable(::Stripe::TokenService::CreateParams::Account::Company::AddressKana), address_kanji: T.nilable(::Stripe::TokenService::CreateParams::Account::Company::AddressKanji), directors_provided: T.nilable(T::Boolean), directorship_declaration: T.nilable(::Stripe::TokenService::CreateParams::Account::Company::DirectorshipDeclaration), executives_provided: T.nilable(T::Boolean), export_license_id: T.nilable(String), export_purpose_code: T.nilable(String), name: T.nilable(String), name_kana: T.nilable(String), name_kanji: T.nilable(String), owners_provided: T.nilable(T::Boolean), ownership_declaration: T.nilable(::Stripe::TokenService::CreateParams::Account::Company::OwnershipDeclaration), ownership_declaration_shown_and_signed: T.nilable(T::Boolean), ownership_exemption_reason: T.nilable(T.nilable(T.any(String, String))), phone: T.nilable(String), registration_date: T.nilable(T.nilable(T.any(String, ::Stripe::TokenService::CreateParams::Account::Company::RegistrationDate))), registration_number: T.nilable(String), structure: T.nilable(T.nilable(T.any(String, String))), tax_id: T.nilable(String), tax_id_registrar: T.nilable(String), vat_id: T.nilable(String), verification: T.nilable(::Stripe::TokenService::CreateParams::Account::Company::Verification)).void
}
def initialize(
address: nil,
address_kana: nil,
address_kanji: nil,
directors_provided: nil,
directorship_declaration: nil,
executives_provided: nil,
export_license_id: nil,
export_purpose_code: nil,
name: nil,
name_kana: nil,
name_kanji: nil,
owners_provided: nil,
ownership_declaration: nil,
ownership_declaration_shown_and_signed: nil,
ownership_exemption_reason: nil,
phone: nil,
registration_date: nil,
registration_number: nil,
structure: nil,
tax_id: nil,
tax_id_registrar: nil,
vat_id: nil,
verification: nil
); end
end
class Individual < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class AddressKana < Stripe::RequestParams
# City or ward.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Block or building number.
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Building details.
sig { returns(T.nilable(String)) }
attr_accessor :line2
# Postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# Prefecture.
sig { returns(T.nilable(String)) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_accessor :town
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), town: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
class AddressKanji < Stripe::RequestParams
# City or ward.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Block or building number.
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Building details.
sig { returns(T.nilable(String)) }
attr_accessor :line2
# Postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# Prefecture.
sig { returns(T.nilable(String)) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_accessor :town
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), town: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
class Dob < Stripe::RequestParams
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
class RegisteredAddress < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class Relationship < Stripe::RequestParams
# Whether the person is a director of the account's legal entity. Directors are typically members of the governing board of the company, or responsible for ensuring the company meets its regulatory obligations.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :director
# Whether the person has significant responsibility to control, manage, or direct the organization.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :executive
# Whether the person is an owner of the account’s legal entity.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :owner
# The percent owned by the person of the account's legal entity.
sig { returns(T.nilable(T.nilable(T.any(String, Float)))) }
attr_accessor :percent_ownership
# The person's title (e.g., CEO, Support Engineer).
sig { returns(T.nilable(String)) }
attr_accessor :title
sig {
params(director: T.nilable(T::Boolean), executive: T.nilable(T::Boolean), owner: T.nilable(T::Boolean), percent_ownership: T.nilable(T.nilable(T.any(String, Float))), title: T.nilable(String)).void
}
def initialize(
director: nil,
executive: nil,
owner: nil,
percent_ownership: nil,
title: nil
); end
end
class Verification < Stripe::RequestParams
class AdditionalDocument < Stripe::RequestParams
# The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :back
# The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :front
sig { params(back: T.nilable(String), front: T.nilable(String)).void }
def initialize(back: nil, front: nil); end
end
class Document < Stripe::RequestParams
# The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :back
# The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :front
sig { params(back: T.nilable(String), front: T.nilable(String)).void }
def initialize(back: nil, front: nil); end
end
# A document showing address, either a passport, local ID card, or utility bill from a well-known utility company.
sig {
returns(T.nilable(::Stripe::TokenService::CreateParams::Account::Individual::Verification::AdditionalDocument))
}
attr_accessor :additional_document
# An identifying document, either a passport or local ID card.
sig {
returns(T.nilable(::Stripe::TokenService::CreateParams::Account::Individual::Verification::Document))
}
attr_accessor :document
sig {
params(additional_document: T.nilable(::Stripe::TokenService::CreateParams::Account::Individual::Verification::AdditionalDocument), document: T.nilable(::Stripe::TokenService::CreateParams::Account::Individual::Verification::Document)).void
}
def initialize(additional_document: nil, document: nil); end
end
# The individual's primary address.
sig {
returns(T.nilable(::Stripe::TokenService::CreateParams::Account::Individual::Address))
}
attr_accessor :address
# The Kana variation of the individual's primary address (Japan only).
sig {
returns(T.nilable(::Stripe::TokenService::CreateParams::Account::Individual::AddressKana))
}
attr_accessor :address_kana
# The Kanji variation of the individual's primary address (Japan only).
sig {
returns(T.nilable(::Stripe::TokenService::CreateParams::Account::Individual::AddressKanji))
}
attr_accessor :address_kanji
# The individual's date of birth.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::TokenService::CreateParams::Account::Individual::Dob))))
}
attr_accessor :dob
# The individual's email address.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The individual's first name.
sig { returns(T.nilable(String)) }
attr_accessor :first_name
# The Kana variation of the individual's first name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :first_name_kana
# The Kanji variation of the individual's first name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :first_name_kanji
# A list of alternate names or aliases that the individual is known by.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :full_name_aliases
# The individual's gender
sig { returns(T.nilable(String)) }
attr_accessor :gender
# The government-issued ID number of the individual, as appropriate for the representative's country. (Examples are a Social Security Number in the U.S., or a Social Insurance Number in Canada). Instead of the number itself, you can also provide a [PII token created with Stripe.js](/js/tokens/create_token?type=pii).
sig { returns(T.nilable(String)) }
attr_accessor :id_number
# The government-issued secondary ID number of the individual, as appropriate for the representative's country, will be used for enhanced verification checks. In Thailand, this would be the laser code found on the back of an ID card. Instead of the number itself, you can also provide a [PII token created with Stripe.js](/js/tokens/create_token?type=pii).
sig { returns(T.nilable(String)) }
attr_accessor :id_number_secondary
# The individual's last name.
sig { returns(T.nilable(String)) }
attr_accessor :last_name
# The Kana variation of the individual's last name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :last_name_kana
# The Kanji variation of the individual's last name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :last_name_kanji
# The individual's maiden name.
sig { returns(T.nilable(String)) }
attr_accessor :maiden_name
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# The individual's phone number.
sig { returns(T.nilable(String)) }
attr_accessor :phone
# Indicates if the person or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction.
sig { returns(T.nilable(String)) }
attr_accessor :political_exposure
# The individual's registered address.
sig {
returns(T.nilable(::Stripe::TokenService::CreateParams::Account::Individual::RegisteredAddress))
}
attr_accessor :registered_address
# Describes the person’s relationship to the account.
sig {
returns(T.nilable(::Stripe::TokenService::CreateParams::Account::Individual::Relationship))
}
attr_accessor :relationship
# The last four digits of the individual's Social Security Number (U.S. only).
sig { returns(T.nilable(String)) }
attr_accessor :ssn_last_4
# The individual's verification document information.
sig {
returns(T.nilable(::Stripe::TokenService::CreateParams::Account::Individual::Verification))
}
attr_accessor :verification
sig {
params(address: T.nilable(::Stripe::TokenService::CreateParams::Account::Individual::Address), address_kana: T.nilable(::Stripe::TokenService::CreateParams::Account::Individual::AddressKana), address_kanji: T.nilable(::Stripe::TokenService::CreateParams::Account::Individual::AddressKanji), dob: T.nilable(T.nilable(T.any(String, ::Stripe::TokenService::CreateParams::Account::Individual::Dob))), email: T.nilable(String), first_name: T.nilable(String), first_name_kana: T.nilable(String), first_name_kanji: T.nilable(String), full_name_aliases: T.nilable(T.nilable(T.any(String, T::Array[String]))), gender: T.nilable(String), id_number: T.nilable(String), id_number_secondary: T.nilable(String), last_name: T.nilable(String), last_name_kana: T.nilable(String), last_name_kanji: T.nilable(String), maiden_name: T.nilable(String), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), phone: T.nilable(String), political_exposure: T.nilable(String), registered_address: T.nilable(::Stripe::TokenService::CreateParams::Account::Individual::RegisteredAddress), relationship: T.nilable(::Stripe::TokenService::CreateParams::Account::Individual::Relationship), ssn_last_4: T.nilable(String), verification: T.nilable(::Stripe::TokenService::CreateParams::Account::Individual::Verification)).void
}
def initialize(
address: nil,
address_kana: nil,
address_kanji: nil,
dob: nil,
email: nil,
first_name: nil,
first_name_kana: nil,
first_name_kanji: nil,
full_name_aliases: nil,
gender: nil,
id_number: nil,
id_number_secondary: nil,
last_name: nil,
last_name_kana: nil,
last_name_kanji: nil,
maiden_name: nil,
metadata: nil,
phone: nil,
political_exposure: nil,
registered_address: nil,
relationship: nil,
ssn_last_4: nil,
verification: nil
); end
end
# The business type.
sig { returns(T.nilable(String)) }
attr_accessor :business_type
# Information about the company or business.
sig { returns(T.nilable(::Stripe::TokenService::CreateParams::Account::Company)) }
attr_accessor :company
# Information about the person represented by the account.
sig { returns(T.nilable(::Stripe::TokenService::CreateParams::Account::Individual)) }
attr_accessor :individual
# Whether the user described by the data in the token has been shown [the Stripe Connected Account Agreement](/connect/account-tokens#stripe-connected-account-agreement). When creating an account token to create a new Connect account, this value must be `true`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :tos_shown_and_accepted
sig {
params(business_type: T.nilable(String), company: T.nilable(::Stripe::TokenService::CreateParams::Account::Company), individual: T.nilable(::Stripe::TokenService::CreateParams::Account::Individual), tos_shown_and_accepted: T.nilable(T::Boolean)).void
}
def initialize(
business_type: nil,
company: nil,
individual: nil,
tos_shown_and_accepted: nil
); end
end
class BankAccount < Stripe::RequestParams
# The name of the person or business that owns the bank account. This field is required when attaching the bank account to a `Customer` object.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_name
# The type of entity that holds the account. It can be `company` or `individual`. This field is required when attaching the bank account to a `Customer` object.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_type
# The account number for the bank account, in string form. Must be a checking account.
sig { returns(String) }
attr_accessor :account_number
# The bank account type. This can only be `checking` or `savings` in most countries. In Japan, this can only be `futsu` or `toza`.
sig { returns(T.nilable(String)) }
attr_accessor :account_type
# The country in which the bank account is located.
sig { returns(String) }
attr_accessor :country
# The currency the bank account is in. This must be a country/currency pairing that [Stripe supports.](https://stripe.com/docs/payouts)
sig { returns(T.nilable(String)) }
attr_accessor :currency
# The ID of a Payment Method with a `type` of `us_bank_account`. The Payment Method's bank account information will be copied and returned as a Bank Account Token. This parameter is exclusive with respect to all other parameters in the `bank_account` hash. You must include the top-level `customer` parameter if the Payment Method is attached to a `Customer` object. If the Payment Method is not attached to a `Customer` object, it will be consumed and cannot be used again. You may not use Payment Methods which were created by a Setup Intent with `attach_to_self=true`.
sig { returns(T.nilable(String)) }
attr_accessor :payment_method
# The routing number, sort code, or other country-appropriate institution number for the bank account. For US bank accounts, this is required and should be the ACH routing number, not the wire routing number. If you are providing an IBAN for `account_number`, this field is not required.
sig { returns(T.nilable(String)) }
attr_accessor :routing_number
sig {
params(account_holder_name: T.nilable(String), account_holder_type: T.nilable(String), account_number: String, account_type: T.nilable(String), country: String, currency: T.nilable(String), payment_method: T.nilable(String), routing_number: T.nilable(String)).void
}
def initialize(
account_holder_name: nil,
account_holder_type: nil,
account_number: nil,
account_type: nil,
country: nil,
currency: nil,
payment_method: nil,
routing_number: nil
); end
end
class Card < Stripe::RequestParams
class Networks < Stripe::RequestParams
# The customer's preferred card network for co-branded cards. Supports `cartes_bancaires`, `mastercard`, or `visa`. Selection of a network that does not apply to the card will be stored as `invalid_preference` on the card.
sig { returns(T.nilable(String)) }
attr_accessor :preferred
sig { params(preferred: T.nilable(String)).void }
def initialize(preferred: nil); end
end
# City / District / Suburb / Town / Village.
sig { returns(T.nilable(String)) }
attr_accessor :address_city
# Billing address country, if provided.
sig { returns(T.nilable(String)) }
attr_accessor :address_country
# Address line 1 (Street address / PO Box / Company name).
sig { returns(T.nilable(String)) }
attr_accessor :address_line1
# Address line 2 (Apartment / Suite / Unit / Building).
sig { returns(T.nilable(String)) }
attr_accessor :address_line2
# State / County / Province / Region.
sig { returns(T.nilable(String)) }
attr_accessor :address_state
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :address_zip
# Required in order to add the card to an account; in all other cases, this parameter is not used. When added to an account, the card (which must be a debit card) can be used as a transfer destination for funds in this currency.
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Card security code. Highly recommended to always include this value.
sig { returns(T.nilable(String)) }
attr_accessor :cvc
# Two-digit number representing the card's expiration month.
sig { returns(String) }
attr_accessor :exp_month
# Two- or four-digit number representing the card's expiration year.
sig { returns(String) }
attr_accessor :exp_year
# Cardholder's full name.
sig { returns(T.nilable(String)) }
attr_accessor :name
# Contains information about card networks used to process the payment.
sig { returns(T.nilable(::Stripe::TokenService::CreateParams::Card::Networks)) }
attr_accessor :networks
# The card number, as a string without any separators.
sig { returns(String) }
attr_accessor :number
sig {
params(address_city: T.nilable(String), address_country: T.nilable(String), address_line1: T.nilable(String), address_line2: T.nilable(String), address_state: T.nilable(String), address_zip: T.nilable(String), currency: T.nilable(String), cvc: T.nilable(String), exp_month: String, exp_year: String, name: T.nilable(String), networks: T.nilable(::Stripe::TokenService::CreateParams::Card::Networks), number: String).void
}
def initialize(
address_city: nil,
address_country: nil,
address_line1: nil,
address_line2: nil,
address_state: nil,
address_zip: nil,
currency: nil,
cvc: nil,
exp_month: nil,
exp_year: nil,
name: nil,
networks: nil,
number: nil
); end
end
class CvcUpdate < Stripe::RequestParams
# The CVC value, in string form.
sig { returns(String) }
attr_accessor :cvc
sig { params(cvc: String).void }
def initialize(cvc: nil); end
end
class Person < Stripe::RequestParams
class AdditionalTosAcceptances < Stripe::RequestParams
class Account < Stripe::RequestParams
# The Unix timestamp marking when the account representative accepted the service agreement.
sig { returns(T.nilable(Integer)) }
attr_accessor :date
# The IP address from which the account representative accepted the service agreement.
sig { returns(T.nilable(String)) }
attr_accessor :ip
# The user agent of the browser from which the account representative accepted the service agreement.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :user_agent
sig {
params(date: T.nilable(Integer), ip: T.nilable(String), user_agent: T.nilable(T.nilable(String))).void
}
def initialize(date: nil, ip: nil, user_agent: nil); end
end
# Details on the legal guardian's acceptance of the main Stripe service agreement.
sig {
returns(T.nilable(::Stripe::TokenService::CreateParams::Person::AdditionalTosAcceptances::Account))
}
attr_accessor :account
sig {
params(account: T.nilable(::Stripe::TokenService::CreateParams::Person::AdditionalTosAcceptances::Account)).void
}
def initialize(account: nil); end
end
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class AddressKana < Stripe::RequestParams
# City or ward.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Block or building number.
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Building details.
sig { returns(T.nilable(String)) }
attr_accessor :line2
# Postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# Prefecture.
sig { returns(T.nilable(String)) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_accessor :town
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), town: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
class AddressKanji < Stripe::RequestParams
# City or ward.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Block or building number.
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Building details.
sig { returns(T.nilable(String)) }
attr_accessor :line2
# Postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# Prefecture.
sig { returns(T.nilable(String)) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_accessor :town
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), town: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
class Dob < Stripe::RequestParams
# The day of birth, between 1 and 31.
sig { returns(Integer) }
attr_accessor :day
# The month of birth, between 1 and 12.
sig { returns(Integer) }
attr_accessor :month
# The four-digit year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
class Documents < Stripe::RequestParams
class CompanyAuthorization < Stripe::RequestParams
# One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :files
sig { params(files: T.nilable(T::Array[String])).void }
def initialize(files: nil); end
end
class Passport < Stripe::RequestParams
# One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :files
sig { params(files: T.nilable(T::Array[String])).void }
def initialize(files: nil); end
end
class Visa < Stripe::RequestParams
# One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :files
sig { params(files: T.nilable(T::Array[String])).void }
def initialize(files: nil); end
end
# One or more documents that demonstrate proof that this person is authorized to represent the company.
sig {
returns(T.nilable(::Stripe::TokenService::CreateParams::Person::Documents::CompanyAuthorization))
}
attr_accessor :company_authorization
# One or more documents showing the person's passport page with photo and personal data.
sig {
returns(T.nilable(::Stripe::TokenService::CreateParams::Person::Documents::Passport))
}
attr_accessor :passport
# One or more documents showing the person's visa required for living in the country where they are residing.
sig { returns(T.nilable(::Stripe::TokenService::CreateParams::Person::Documents::Visa)) }
attr_accessor :visa
sig {
params(company_authorization: T.nilable(::Stripe::TokenService::CreateParams::Person::Documents::CompanyAuthorization), passport: T.nilable(::Stripe::TokenService::CreateParams::Person::Documents::Passport), visa: T.nilable(::Stripe::TokenService::CreateParams::Person::Documents::Visa)).void
}
def initialize(company_authorization: nil, passport: nil, visa: nil); end
end
class RegisteredAddress < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
class Relationship < Stripe::RequestParams
# Whether the person is the authorizer of the account's representative.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :authorizer
# Whether the person is a director of the account's legal entity. Directors are typically members of the governing board of the company, or responsible for ensuring the company meets its regulatory obligations.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :director
# Whether the person has significant responsibility to control, manage, or direct the organization.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :executive
# Whether the person is the legal guardian of the account's representative.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :legal_guardian
# Whether the person is an owner of the account’s legal entity.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :owner
# The percent owned by the person of the account's legal entity.
sig { returns(T.nilable(T.nilable(T.any(String, Float)))) }
attr_accessor :percent_ownership
# Whether the person is authorized as the primary representative of the account. This is the person nominated by the business to provide information about themselves, and general information about the account. There can only be one representative at any given time. At the time the account is created, this person should be set to the person responsible for opening the account.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :representative
# The person's title (e.g., CEO, Support Engineer).
sig { returns(T.nilable(String)) }
attr_accessor :title
sig {
params(authorizer: T.nilable(T::Boolean), director: T.nilable(T::Boolean), executive: T.nilable(T::Boolean), legal_guardian: T.nilable(T::Boolean), owner: T.nilable(T::Boolean), percent_ownership: T.nilable(T.nilable(T.any(String, Float))), representative: T.nilable(T::Boolean), title: T.nilable(String)).void
}
def initialize(
authorizer: nil,
director: nil,
executive: nil,
legal_guardian: nil,
owner: nil,
percent_ownership: nil,
representative: nil,
title: nil
); end
end
class UsCfpbData < Stripe::RequestParams
class EthnicityDetails < Stripe::RequestParams
# The persons ethnicity
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :ethnicity
# Please specify your origin, when other is selected.
sig { returns(T.nilable(String)) }
attr_accessor :ethnicity_other
sig {
params(ethnicity: T.nilable(T::Array[String]), ethnicity_other: T.nilable(String)).void
}
def initialize(ethnicity: nil, ethnicity_other: nil); end
end
class RaceDetails < Stripe::RequestParams
# The persons race.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :race
# Please specify your race, when other is selected.
sig { returns(T.nilable(String)) }
attr_accessor :race_other
sig { params(race: T.nilable(T::Array[String]), race_other: T.nilable(String)).void }
def initialize(race: nil, race_other: nil); end
end
# The persons ethnicity details
sig {
returns(T.nilable(::Stripe::TokenService::CreateParams::Person::UsCfpbData::EthnicityDetails))
}
attr_accessor :ethnicity_details
# The persons race details
sig {
returns(T.nilable(::Stripe::TokenService::CreateParams::Person::UsCfpbData::RaceDetails))
}
attr_accessor :race_details
# The persons self-identified gender
sig { returns(T.nilable(String)) }
attr_accessor :self_identified_gender
sig {
params(ethnicity_details: T.nilable(::Stripe::TokenService::CreateParams::Person::UsCfpbData::EthnicityDetails), race_details: T.nilable(::Stripe::TokenService::CreateParams::Person::UsCfpbData::RaceDetails), self_identified_gender: T.nilable(String)).void
}
def initialize(
ethnicity_details: nil,
race_details: nil,
self_identified_gender: nil
); end
end
class Verification < Stripe::RequestParams
class AdditionalDocument < Stripe::RequestParams
# The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :back
# The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :front
sig { params(back: T.nilable(String), front: T.nilable(String)).void }
def initialize(back: nil, front: nil); end
end
class Document < Stripe::RequestParams
# The back of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :back
# The front of an ID returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `identity_document`. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :front
sig { params(back: T.nilable(String), front: T.nilable(String)).void }
def initialize(back: nil, front: nil); end
end
# A document showing address, either a passport, local ID card, or utility bill from a well-known utility company.
sig {
returns(T.nilable(::Stripe::TokenService::CreateParams::Person::Verification::AdditionalDocument))
}
attr_accessor :additional_document
# An identifying document, either a passport or local ID card.
sig {
returns(T.nilable(::Stripe::TokenService::CreateParams::Person::Verification::Document))
}
attr_accessor :document
sig {
params(additional_document: T.nilable(::Stripe::TokenService::CreateParams::Person::Verification::AdditionalDocument), document: T.nilable(::Stripe::TokenService::CreateParams::Person::Verification::Document)).void
}
def initialize(additional_document: nil, document: nil); end
end
# Details on the legal guardian's or authorizer's acceptance of the required Stripe agreements.
sig {
returns(T.nilable(::Stripe::TokenService::CreateParams::Person::AdditionalTosAcceptances))
}
attr_accessor :additional_tos_acceptances
# The person's address.
sig { returns(T.nilable(::Stripe::TokenService::CreateParams::Person::Address)) }
attr_accessor :address
# The Kana variation of the person's address (Japan only).
sig { returns(T.nilable(::Stripe::TokenService::CreateParams::Person::AddressKana)) }
attr_accessor :address_kana
# The Kanji variation of the person's address (Japan only).
sig { returns(T.nilable(::Stripe::TokenService::CreateParams::Person::AddressKanji)) }
attr_accessor :address_kanji
# The person's date of birth.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::TokenService::CreateParams::Person::Dob))))
}
attr_accessor :dob
# Documents that may be submitted to satisfy various informational requests.
sig { returns(T.nilable(::Stripe::TokenService::CreateParams::Person::Documents)) }
attr_accessor :documents
# The person's email address.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The person's first name.
sig { returns(T.nilable(String)) }
attr_accessor :first_name
# The Kana variation of the person's first name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :first_name_kana
# The Kanji variation of the person's first name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :first_name_kanji
# A list of alternate names or aliases that the person is known by.
sig { returns(T.nilable(T.nilable(T.any(String, T::Array[String])))) }
attr_accessor :full_name_aliases
# The person's gender (International regulations require either "male" or "female").
sig { returns(T.nilable(String)) }
attr_accessor :gender
# The person's ID number, as appropriate for their country. For example, a social security number in the U.S., social insurance number in Canada, etc. Instead of the number itself, you can also provide a [PII token provided by Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).
sig { returns(T.nilable(String)) }
attr_accessor :id_number
# The person's secondary ID number, as appropriate for their country, will be used for enhanced verification checks. In Thailand, this would be the laser code found on the back of an ID card. Instead of the number itself, you can also provide a [PII token provided by Stripe.js](https://docs.stripe.com/js/tokens/create_token?type=pii).
sig { returns(T.nilable(String)) }
attr_accessor :id_number_secondary
# The person's last name.
sig { returns(T.nilable(String)) }
attr_accessor :last_name
# The Kana variation of the person's last name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :last_name_kana
# The Kanji variation of the person's last name (Japan only).
sig { returns(T.nilable(String)) }
attr_accessor :last_name_kanji
# The person's maiden name.
sig { returns(T.nilable(String)) }
attr_accessor :maiden_name
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# The country where the person is a national. Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)), or "XX" if unavailable.
sig { returns(T.nilable(String)) }
attr_accessor :nationality
# The person's phone number.
sig { returns(T.nilable(String)) }
attr_accessor :phone
# Indicates if the person or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction.
sig { returns(T.nilable(String)) }
attr_accessor :political_exposure
# The person's registered address.
sig { returns(T.nilable(::Stripe::TokenService::CreateParams::Person::RegisteredAddress)) }
attr_accessor :registered_address
# The relationship that this person has with the account's legal entity.
sig { returns(T.nilable(::Stripe::TokenService::CreateParams::Person::Relationship)) }
attr_accessor :relationship
# The last four digits of the person's Social Security number (U.S. only).
sig { returns(T.nilable(String)) }
attr_accessor :ssn_last_4
# Demographic data related to the person.
sig { returns(T.nilable(::Stripe::TokenService::CreateParams::Person::UsCfpbData)) }
attr_accessor :us_cfpb_data
# The person's verification status.
sig { returns(T.nilable(::Stripe::TokenService::CreateParams::Person::Verification)) }
attr_accessor :verification
sig {
params(additional_tos_acceptances: T.nilable(::Stripe::TokenService::CreateParams::Person::AdditionalTosAcceptances), address: T.nilable(::Stripe::TokenService::CreateParams::Person::Address), address_kana: T.nilable(::Stripe::TokenService::CreateParams::Person::AddressKana), address_kanji: T.nilable(::Stripe::TokenService::CreateParams::Person::AddressKanji), dob: T.nilable(T.nilable(T.any(String, ::Stripe::TokenService::CreateParams::Person::Dob))), documents: T.nilable(::Stripe::TokenService::CreateParams::Person::Documents), email: T.nilable(String), first_name: T.nilable(String), first_name_kana: T.nilable(String), first_name_kanji: T.nilable(String), full_name_aliases: T.nilable(T.nilable(T.any(String, T::Array[String]))), gender: T.nilable(String), id_number: T.nilable(String), id_number_secondary: T.nilable(String), last_name: T.nilable(String), last_name_kana: T.nilable(String), last_name_kanji: T.nilable(String), maiden_name: T.nilable(String), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), nationality: T.nilable(String), phone: T.nilable(String), political_exposure: T.nilable(String), registered_address: T.nilable(::Stripe::TokenService::CreateParams::Person::RegisteredAddress), relationship: T.nilable(::Stripe::TokenService::CreateParams::Person::Relationship), ssn_last_4: T.nilable(String), us_cfpb_data: T.nilable(::Stripe::TokenService::CreateParams::Person::UsCfpbData), verification: T.nilable(::Stripe::TokenService::CreateParams::Person::Verification)).void
}
def initialize(
additional_tos_acceptances: nil,
address: nil,
address_kana: nil,
address_kanji: nil,
dob: nil,
documents: nil,
email: nil,
first_name: nil,
first_name_kana: nil,
first_name_kanji: nil,
full_name_aliases: nil,
gender: nil,
id_number: nil,
id_number_secondary: nil,
last_name: nil,
last_name_kana: nil,
last_name_kanji: nil,
maiden_name: nil,
metadata: nil,
nationality: nil,
phone: nil,
political_exposure: nil,
registered_address: nil,
relationship: nil,
ssn_last_4: nil,
us_cfpb_data: nil,
verification: nil
); end
end
class Pii < Stripe::RequestParams
# The `id_number` for the PII, in string form.
sig { returns(T.nilable(String)) }
attr_accessor :id_number
sig { params(id_number: T.nilable(String)).void }
def initialize(id_number: nil); end
end
# Information for the account this token represents.
sig { returns(T.nilable(::Stripe::TokenService::CreateParams::Account)) }
attr_accessor :account
# The bank account this token will represent.
sig { returns(T.nilable(::Stripe::TokenService::CreateParams::BankAccount)) }
attr_accessor :bank_account
# The card this token will represent. If you also pass in a customer, the card must be the ID of a card belonging to the customer. Otherwise, if you do not pass in a customer, this is a dictionary containing a user's credit card details, with the options described below.
sig { returns(T.nilable(T.any(::Stripe::TokenService::CreateParams::Card, String))) }
attr_accessor :card
# Create a token for the customer, which is owned by the application's account. You can only use this with an [OAuth access token](https://stripe.com/docs/connect/standard-accounts) or [Stripe-Account header](https://stripe.com/docs/connect/authentication). Learn more about [cloning saved payment methods](https://stripe.com/docs/connect/cloning-saved-payment-methods).
sig { returns(T.nilable(String)) }
attr_accessor :customer
# The updated CVC value this token represents.
sig { returns(T.nilable(::Stripe::TokenService::CreateParams::CvcUpdate)) }
attr_accessor :cvc_update
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Information for the person this token represents.
sig { returns(T.nilable(::Stripe::TokenService::CreateParams::Person)) }
attr_accessor :person
# The PII this token represents.
sig { returns(T.nilable(::Stripe::TokenService::CreateParams::Pii)) }
attr_accessor :pii
sig {
params(account: T.nilable(::Stripe::TokenService::CreateParams::Account), bank_account: T.nilable(::Stripe::TokenService::CreateParams::BankAccount), card: T.nilable(T.any(::Stripe::TokenService::CreateParams::Card, String)), customer: T.nilable(String), cvc_update: T.nilable(::Stripe::TokenService::CreateParams::CvcUpdate), expand: T.nilable(T::Array[String]), person: T.nilable(::Stripe::TokenService::CreateParams::Person), pii: T.nilable(::Stripe::TokenService::CreateParams::Pii)).void
}
def initialize(
account: nil,
bank_account: nil,
card: nil,
customer: nil,
cvc_update: nil,
expand: nil,
person: nil,
pii: nil
); end
end
# Creates a single-use token that represents a bank account's details.
# You can use this token with any v1 API method in place of a bank account dictionary. You can only use this token once. To do so, attach it to a [connected account](https://docs.stripe.com/api#accounts) where [controller.requirement_collection](https://docs.stripe.com/api/accounts/object#account_object-controller-requirement_collection) is application, which includes Custom accounts.
sig {
params(params: T.any(::Stripe::TokenService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Token)
}
def create(params = {}, opts = {}); end
# Retrieves the token with the given ID.
sig {
params(token: String, params: T.any(::Stripe::TokenService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Token)
}
def retrieve(token, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class TopupService < StripeService
class ListParams < Stripe::RequestParams
class Amount < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# A positive integer representing how much to transfer.
sig { returns(T.nilable(T.any(::Stripe::TopupService::ListParams::Amount, Integer))) }
attr_accessor :amount
# A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options.
sig { returns(T.nilable(T.any(::Stripe::TopupService::ListParams::Created, Integer))) }
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return top-ups that have the given status. One of `canceled`, `failed`, `pending` or `succeeded`.
sig { returns(T.nilable(String)) }
attr_accessor :status
sig {
params(amount: T.nilable(T.any(::Stripe::TopupService::ListParams::Amount, Integer)), created: T.nilable(T.any(::Stripe::TopupService::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String), status: T.nilable(String)).void
}
def initialize(
amount: nil,
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil,
status: nil
); end
end
class CreateParams < Stripe::RequestParams
# A positive integer representing how much to transfer.
sig { returns(Integer) }
attr_accessor :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).
sig { returns(String) }
attr_accessor :currency
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# The ID of a source to transfer funds from. For most users, this should be left unspecified which will use the bank account that was set up in the dashboard for the specified currency. In test mode, this can be a test bank token (see [Testing Top-ups](https://stripe.com/docs/connect/testing#testing-top-ups)).
sig { returns(T.nilable(String)) }
attr_accessor :source
# Extra information about a top-up for the source's bank statement. Limited to 15 ASCII characters.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
# A string that identifies this top-up as part of a group.
sig { returns(T.nilable(String)) }
attr_accessor :transfer_group
sig {
params(amount: Integer, currency: String, description: T.nilable(String), expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), source: T.nilable(String), statement_descriptor: T.nilable(String), transfer_group: T.nilable(String)).void
}
def initialize(
amount: nil,
currency: nil,
description: nil,
expand: nil,
metadata: nil,
source: nil,
statement_descriptor: nil,
transfer_group: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
sig {
params(description: T.nilable(String), expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String])))).void
}
def initialize(description: nil, expand: nil, metadata: nil); end
end
class CancelParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Cancels a top-up. Only pending top-ups can be canceled.
sig {
params(topup: String, params: T.any(::Stripe::TopupService::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Topup)
}
def cancel(topup, params = {}, opts = {}); end
# Top up the balance of an account
sig {
params(params: T.any(::Stripe::TopupService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Topup)
}
def create(params = {}, opts = {}); end
# Returns a list of top-ups.
sig {
params(params: T.any(::Stripe::TopupService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the details of a top-up that has previously been created. Supply the unique top-up ID that was returned from your previous request, and Stripe will return the corresponding top-up information.
sig {
params(topup: String, params: T.any(::Stripe::TopupService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Topup)
}
def retrieve(topup, params = {}, opts = {}); end
# Updates the metadata of a top-up. Other top-up details are not editable by design.
sig {
params(topup: String, params: T.any(::Stripe::TopupService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Topup)
}
def update(topup, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class TransferService < StripeService
attr_reader :reversals
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return transfers that were created during the given date interval.
sig { returns(T.nilable(T.any(::Stripe::TransferService::ListParams::Created, Integer))) }
attr_accessor :created
# Only return transfers for the destination specified by this account ID.
sig { returns(T.nilable(String)) }
attr_accessor :destination
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return transfers with the specified transfer group.
sig { returns(T.nilable(String)) }
attr_accessor :transfer_group
sig {
params(created: T.nilable(T.any(::Stripe::TransferService::ListParams::Created, Integer)), destination: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String), transfer_group: T.nilable(String)).void
}
def initialize(
created: nil,
destination: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil,
transfer_group: nil
); end
end
class CreateParams < Stripe::RequestParams
# A positive integer in cents (or local equivalent) representing how much to transfer.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# Three-letter [ISO code for currency](https://www.iso.org/iso-4217-currency-codes.html) in lowercase. Must be a [supported currency](https://docs.stripe.com/currencies).
sig { returns(String) }
attr_accessor :currency
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# The ID of a connected Stripe account. See the Connect documentation for details.
sig { returns(String) }
attr_accessor :destination
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The FX rate in the quote is validated and used to convert the transfer amount to the destination currency.
sig { returns(T.nilable(String)) }
attr_accessor :fx_quote
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# You can use this parameter to transfer funds from a charge before they are added to your available balance. A pending balance will transfer immediately but the funds will not become available until the original charge becomes available. [See the Connect documentation](https://stripe.com/docs/connect/separate-charges-and-transfers#transfer-availability) for details.
sig { returns(T.nilable(String)) }
attr_accessor :source_transaction
# The source balance to use for this transfer. One of `bank_account`, `card`, or `fpx`. For most users, this will default to `card`.
sig { returns(T.nilable(String)) }
attr_accessor :source_type
# A string that identifies this transaction as part of a group. See the [Connect documentation](https://stripe.com/docs/connect/separate-charges-and-transfers#transfer-options) for details.
sig { returns(T.nilable(String)) }
attr_accessor :transfer_group
sig {
params(amount: T.nilable(Integer), currency: String, description: T.nilable(String), destination: String, expand: T.nilable(T::Array[String]), fx_quote: T.nilable(String), metadata: T.nilable(T::Hash[String, String]), source_transaction: T.nilable(String), source_type: T.nilable(String), transfer_group: T.nilable(String)).void
}
def initialize(
amount: nil,
currency: nil,
description: nil,
destination: nil,
expand: nil,
fx_quote: nil,
metadata: nil,
source_transaction: nil,
source_type: nil,
transfer_group: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
sig {
params(description: T.nilable(String), expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String])))).void
}
def initialize(description: nil, expand: nil, metadata: nil); end
end
# To send funds from your Stripe account to a connected account, you create a new transfer object. Your [Stripe balance](https://docs.stripe.com/api#balance) must be able to cover the transfer amount, or you'll receive an “Insufficient Funds” error.
sig {
params(params: T.any(::Stripe::TransferService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Transfer)
}
def create(params = {}, opts = {}); end
# Returns a list of existing transfers sent to connected accounts. The transfers are returned in sorted order, with the most recently created transfers appearing first.
sig {
params(params: T.any(::Stripe::TransferService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the details of an existing transfer. Supply the unique transfer ID from either a transfer creation request or the transfer list, and Stripe will return the corresponding transfer information.
sig {
params(transfer: String, params: T.any(::Stripe::TransferService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Transfer)
}
def retrieve(transfer, params = {}, opts = {}); end
# Updates the specified transfer by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
#
# This request accepts only metadata as an argument.
sig {
params(transfer: String, params: T.any(::Stripe::TransferService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Transfer)
}
def update(transfer, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class TransferReversalService < StripeService
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
class CreateParams < Stripe::RequestParams
# A positive integer in cents (or local equivalent) representing how much of this transfer to reverse. Can only reverse up to the unreversed amount remaining of the transfer. Partial transfer reversals are only allowed for transfers to Stripe Accounts. Defaults to the entire transfer amount.
sig { returns(T.nilable(Integer)) }
attr_accessor :amount
# An arbitrary string which you can attach to a reversal object. This will be unset if you POST an empty value.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Boolean indicating whether the application fee should be refunded when reversing this transfer. If a full transfer reversal is given, the full application fee will be refunded. Otherwise, the application fee will be refunded with an amount proportional to the amount of the transfer reversed.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :refund_application_fee
sig {
params(amount: T.nilable(Integer), description: T.nilable(String), expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), refund_application_fee: T.nilable(T::Boolean)).void
}
def initialize(
amount: nil,
description: nil,
expand: nil,
metadata: nil,
refund_application_fee: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
sig {
params(expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String])))).void
}
def initialize(expand: nil, metadata: nil); end
end
# When you create a new reversal, you must specify a transfer to create it on.
#
# When reversing transfers, you can optionally reverse part of the transfer. You can do so as many times as you wish until the entire transfer has been reversed.
#
# Once entirely reversed, a transfer can't be reversed again. This method will return an error when called on an already-reversed transfer, or when trying to reverse more money than is left on a transfer.
sig {
params(id: String, params: T.any(::Stripe::TransferReversalService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Reversal)
}
def create(id, params = {}, opts = {}); end
# You can see a list of the reversals belonging to a specific transfer. Note that the 10 most recent reversals are always available by default on the transfer object. If you need more than those 10, you can use this API method and the limit and starting_after parameters to page through additional reversals.
sig {
params(id: String, params: T.any(::Stripe::TransferReversalService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(id, params = {}, opts = {}); end
# By default, you can see the 10 most recent reversals stored directly on the transfer object, but you can also retrieve details about a specific reversal stored on the transfer.
sig {
params(transfer: String, id: String, params: T.any(::Stripe::TransferReversalService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Reversal)
}
def retrieve(transfer, id, params = {}, opts = {}); end
# Updates the specified reversal by setting the values of the parameters passed. Any parameters not provided will be left unchanged.
#
# This request only accepts metadata and description as arguments.
sig {
params(transfer: String, id: String, params: T.any(::Stripe::TransferReversalService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Reversal)
}
def update(transfer, id, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class TreasuryService < StripeService
attr_reader :credit_reversals
attr_reader :debit_reversals
attr_reader :financial_accounts
attr_reader :inbound_transfers
attr_reader :outbound_payments
attr_reader :outbound_transfers
attr_reader :received_credits
attr_reader :received_debits
attr_reader :transactions
attr_reader :transaction_entries
end
end
# typed: true
module Stripe
module Treasury
class CreditReversalService < StripeService
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Returns objects associated with this FinancialAccount.
sig { returns(String) }
attr_accessor :financial_account
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Only return CreditReversals for the ReceivedCredit ID.
sig { returns(T.nilable(String)) }
attr_accessor :received_credit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return CreditReversals for a given status.
sig { returns(T.nilable(String)) }
attr_accessor :status
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), financial_account: String, limit: T.nilable(Integer), received_credit: T.nilable(String), starting_after: T.nilable(String), status: T.nilable(String)).void
}
def initialize(
ending_before: nil,
expand: nil,
financial_account: nil,
limit: nil,
received_credit: nil,
starting_after: nil,
status: nil
); end
end
class CreateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The ReceivedCredit to reverse.
sig { returns(String) }
attr_accessor :received_credit
sig {
params(expand: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), received_credit: String).void
}
def initialize(expand: nil, metadata: nil, received_credit: nil); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Reverses a ReceivedCredit and creates a CreditReversal object.
sig {
params(params: T.any(::Stripe::Treasury::CreditReversalService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::CreditReversal)
}
def create(params = {}, opts = {}); end
# Returns a list of CreditReversals.
sig {
params(params: T.any(::Stripe::Treasury::CreditReversalService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the details of an existing CreditReversal by passing the unique CreditReversal ID from either the CreditReversal creation request or CreditReversal list
sig {
params(credit_reversal: String, params: T.any(::Stripe::Treasury::CreditReversalService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::CreditReversal)
}
def retrieve(credit_reversal, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Treasury
class DebitReversalService < StripeService
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Returns objects associated with this FinancialAccount.
sig { returns(String) }
attr_accessor :financial_account
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Only return DebitReversals for the ReceivedDebit ID.
sig { returns(T.nilable(String)) }
attr_accessor :received_debit
# Only return DebitReversals for a given resolution.
sig { returns(T.nilable(String)) }
attr_accessor :resolution
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return DebitReversals for a given status.
sig { returns(T.nilable(String)) }
attr_accessor :status
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), financial_account: String, limit: T.nilable(Integer), received_debit: T.nilable(String), resolution: T.nilable(String), starting_after: T.nilable(String), status: T.nilable(String)).void
}
def initialize(
ending_before: nil,
expand: nil,
financial_account: nil,
limit: nil,
received_debit: nil,
resolution: nil,
starting_after: nil,
status: nil
); end
end
class CreateParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The ReceivedDebit to reverse.
sig { returns(String) }
attr_accessor :received_debit
sig {
params(expand: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), received_debit: String).void
}
def initialize(expand: nil, metadata: nil, received_debit: nil); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Reverses a ReceivedDebit and creates a DebitReversal object.
sig {
params(params: T.any(::Stripe::Treasury::DebitReversalService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::DebitReversal)
}
def create(params = {}, opts = {}); end
# Returns a list of DebitReversals.
sig {
params(params: T.any(::Stripe::Treasury::DebitReversalService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves a DebitReversal object.
sig {
params(debit_reversal: String, params: T.any(::Stripe::Treasury::DebitReversalService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::DebitReversal)
}
def retrieve(debit_reversal, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Treasury
class FinancialAccountService < StripeService
attr_reader :features
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return FinancialAccounts that were created during the given date interval.
sig {
returns(T.nilable(T.any(::Stripe::Treasury::FinancialAccountService::ListParams::Created, Integer)))
}
attr_accessor :created
# An object ID cursor for use in pagination.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit ranging from 1 to 100 (defaults to 10).
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# An object ID cursor for use in pagination.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(created: T.nilable(T.any(::Stripe::Treasury::FinancialAccountService::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(
created: nil,
ending_before: nil,
expand: nil,
limit: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class Features < Stripe::RequestParams
class CardIssuing < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class DepositInsurance < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class FinancialAddresses < Stripe::RequestParams
class Aba < Stripe::RequestParams
# Requested bank partner
sig { returns(T.nilable(String)) }
attr_accessor :bank
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(bank: T.nilable(String), requested: T::Boolean).void }
def initialize(bank: nil, requested: nil); end
end
# Adds an ABA FinancialAddress to the FinancialAccount.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccountService::CreateParams::Features::FinancialAddresses::Aba))
}
attr_accessor :aba
sig {
params(aba: T.nilable(::Stripe::Treasury::FinancialAccountService::CreateParams::Features::FinancialAddresses::Aba)).void
}
def initialize(aba: nil); end
end
class InboundTransfers < Stripe::RequestParams
class Ach < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
# Enables ACH Debits via the InboundTransfers API.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccountService::CreateParams::Features::InboundTransfers::Ach))
}
attr_accessor :ach
sig {
params(ach: T.nilable(::Stripe::Treasury::FinancialAccountService::CreateParams::Features::InboundTransfers::Ach)).void
}
def initialize(ach: nil); end
end
class IntraStripeFlows < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class OutboundPayments < Stripe::RequestParams
class Ach < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class UsDomesticWire < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
# Enables ACH transfers via the OutboundPayments API.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccountService::CreateParams::Features::OutboundPayments::Ach))
}
attr_accessor :ach
# Enables US domestic wire transfers via the OutboundPayments API.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccountService::CreateParams::Features::OutboundPayments::UsDomesticWire))
}
attr_accessor :us_domestic_wire
sig {
params(ach: T.nilable(::Stripe::Treasury::FinancialAccountService::CreateParams::Features::OutboundPayments::Ach), us_domestic_wire: T.nilable(::Stripe::Treasury::FinancialAccountService::CreateParams::Features::OutboundPayments::UsDomesticWire)).void
}
def initialize(ach: nil, us_domestic_wire: nil); end
end
class OutboundTransfers < Stripe::RequestParams
class Ach < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class UsDomesticWire < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
# Enables ACH transfers via the OutboundTransfers API.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccountService::CreateParams::Features::OutboundTransfers::Ach))
}
attr_accessor :ach
# Enables US domestic wire transfers via the OutboundTransfers API.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccountService::CreateParams::Features::OutboundTransfers::UsDomesticWire))
}
attr_accessor :us_domestic_wire
sig {
params(ach: T.nilable(::Stripe::Treasury::FinancialAccountService::CreateParams::Features::OutboundTransfers::Ach), us_domestic_wire: T.nilable(::Stripe::Treasury::FinancialAccountService::CreateParams::Features::OutboundTransfers::UsDomesticWire)).void
}
def initialize(ach: nil, us_domestic_wire: nil); end
end
# Encodes the FinancialAccount's ability to be used with the Issuing product, including attaching cards to and drawing funds from the FinancialAccount.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccountService::CreateParams::Features::CardIssuing))
}
attr_accessor :card_issuing
# Represents whether this FinancialAccount is eligible for deposit insurance. Various factors determine the insurance amount.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccountService::CreateParams::Features::DepositInsurance))
}
attr_accessor :deposit_insurance
# Contains Features that add FinancialAddresses to the FinancialAccount.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccountService::CreateParams::Features::FinancialAddresses))
}
attr_accessor :financial_addresses
# Contains settings related to adding funds to a FinancialAccount from another Account with the same owner.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccountService::CreateParams::Features::InboundTransfers))
}
attr_accessor :inbound_transfers
# Represents the ability for the FinancialAccount to send money to, or receive money from other FinancialAccounts (for example, via OutboundPayment).
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccountService::CreateParams::Features::IntraStripeFlows))
}
attr_accessor :intra_stripe_flows
# Includes Features related to initiating money movement out of the FinancialAccount to someone else's bucket of money.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccountService::CreateParams::Features::OutboundPayments))
}
attr_accessor :outbound_payments
# Contains a Feature and settings related to moving money out of the FinancialAccount into another Account with the same owner.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccountService::CreateParams::Features::OutboundTransfers))
}
attr_accessor :outbound_transfers
sig {
params(card_issuing: T.nilable(::Stripe::Treasury::FinancialAccountService::CreateParams::Features::CardIssuing), deposit_insurance: T.nilable(::Stripe::Treasury::FinancialAccountService::CreateParams::Features::DepositInsurance), financial_addresses: T.nilable(::Stripe::Treasury::FinancialAccountService::CreateParams::Features::FinancialAddresses), inbound_transfers: T.nilable(::Stripe::Treasury::FinancialAccountService::CreateParams::Features::InboundTransfers), intra_stripe_flows: T.nilable(::Stripe::Treasury::FinancialAccountService::CreateParams::Features::IntraStripeFlows), outbound_payments: T.nilable(::Stripe::Treasury::FinancialAccountService::CreateParams::Features::OutboundPayments), outbound_transfers: T.nilable(::Stripe::Treasury::FinancialAccountService::CreateParams::Features::OutboundTransfers)).void
}
def initialize(
card_issuing: nil,
deposit_insurance: nil,
financial_addresses: nil,
inbound_transfers: nil,
intra_stripe_flows: nil,
outbound_payments: nil,
outbound_transfers: nil
); end
end
class PlatformRestrictions < Stripe::RequestParams
# Restricts all inbound money movement.
sig { returns(T.nilable(String)) }
attr_accessor :inbound_flows
# Restricts all outbound money movement.
sig { returns(T.nilable(String)) }
attr_accessor :outbound_flows
sig { params(inbound_flows: T.nilable(String), outbound_flows: T.nilable(String)).void }
def initialize(inbound_flows: nil, outbound_flows: nil); end
end
# The display name for the FinancialAccount. Use this field to customize the names of the FinancialAccounts for your connected accounts. Unlike the `nickname` field, `display_name` is not internal metadata and will be exposed to connected accounts.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :display_name
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Encodes whether a FinancialAccount has access to a particular feature. Stripe or the platform can control features via the requested field.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccountService::CreateParams::Features))
}
attr_accessor :features
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The nickname for the FinancialAccount.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :nickname
# The set of functionalities that the platform can restrict on the FinancialAccount.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccountService::CreateParams::PlatformRestrictions))
}
attr_accessor :platform_restrictions
# The currencies the FinancialAccount can hold a balance in.
sig { returns(T::Array[String]) }
attr_accessor :supported_currencies
sig {
params(display_name: T.nilable(T.nilable(String)), expand: T.nilable(T::Array[String]), features: T.nilable(::Stripe::Treasury::FinancialAccountService::CreateParams::Features), metadata: T.nilable(T::Hash[String, String]), nickname: T.nilable(T.nilable(String)), platform_restrictions: T.nilable(::Stripe::Treasury::FinancialAccountService::CreateParams::PlatformRestrictions), supported_currencies: T::Array[String]).void
}
def initialize(
display_name: nil,
expand: nil,
features: nil,
metadata: nil,
nickname: nil,
platform_restrictions: nil,
supported_currencies: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
class Features < Stripe::RequestParams
class CardIssuing < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class DepositInsurance < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class FinancialAddresses < Stripe::RequestParams
class Aba < Stripe::RequestParams
# Requested bank partner
sig { returns(T.nilable(String)) }
attr_accessor :bank
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(bank: T.nilable(String), requested: T::Boolean).void }
def initialize(bank: nil, requested: nil); end
end
# Adds an ABA FinancialAddress to the FinancialAccount.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccountService::UpdateParams::Features::FinancialAddresses::Aba))
}
attr_accessor :aba
sig {
params(aba: T.nilable(::Stripe::Treasury::FinancialAccountService::UpdateParams::Features::FinancialAddresses::Aba)).void
}
def initialize(aba: nil); end
end
class InboundTransfers < Stripe::RequestParams
class Ach < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
# Enables ACH Debits via the InboundTransfers API.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccountService::UpdateParams::Features::InboundTransfers::Ach))
}
attr_accessor :ach
sig {
params(ach: T.nilable(::Stripe::Treasury::FinancialAccountService::UpdateParams::Features::InboundTransfers::Ach)).void
}
def initialize(ach: nil); end
end
class IntraStripeFlows < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class OutboundPayments < Stripe::RequestParams
class Ach < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class UsDomesticWire < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
# Enables ACH transfers via the OutboundPayments API.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccountService::UpdateParams::Features::OutboundPayments::Ach))
}
attr_accessor :ach
# Enables US domestic wire transfers via the OutboundPayments API.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccountService::UpdateParams::Features::OutboundPayments::UsDomesticWire))
}
attr_accessor :us_domestic_wire
sig {
params(ach: T.nilable(::Stripe::Treasury::FinancialAccountService::UpdateParams::Features::OutboundPayments::Ach), us_domestic_wire: T.nilable(::Stripe::Treasury::FinancialAccountService::UpdateParams::Features::OutboundPayments::UsDomesticWire)).void
}
def initialize(ach: nil, us_domestic_wire: nil); end
end
class OutboundTransfers < Stripe::RequestParams
class Ach < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class UsDomesticWire < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
# Enables ACH transfers via the OutboundTransfers API.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccountService::UpdateParams::Features::OutboundTransfers::Ach))
}
attr_accessor :ach
# Enables US domestic wire transfers via the OutboundTransfers API.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccountService::UpdateParams::Features::OutboundTransfers::UsDomesticWire))
}
attr_accessor :us_domestic_wire
sig {
params(ach: T.nilable(::Stripe::Treasury::FinancialAccountService::UpdateParams::Features::OutboundTransfers::Ach), us_domestic_wire: T.nilable(::Stripe::Treasury::FinancialAccountService::UpdateParams::Features::OutboundTransfers::UsDomesticWire)).void
}
def initialize(ach: nil, us_domestic_wire: nil); end
end
# Encodes the FinancialAccount's ability to be used with the Issuing product, including attaching cards to and drawing funds from the FinancialAccount.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccountService::UpdateParams::Features::CardIssuing))
}
attr_accessor :card_issuing
# Represents whether this FinancialAccount is eligible for deposit insurance. Various factors determine the insurance amount.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccountService::UpdateParams::Features::DepositInsurance))
}
attr_accessor :deposit_insurance
# Contains Features that add FinancialAddresses to the FinancialAccount.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccountService::UpdateParams::Features::FinancialAddresses))
}
attr_accessor :financial_addresses
# Contains settings related to adding funds to a FinancialAccount from another Account with the same owner.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccountService::UpdateParams::Features::InboundTransfers))
}
attr_accessor :inbound_transfers
# Represents the ability for the FinancialAccount to send money to, or receive money from other FinancialAccounts (for example, via OutboundPayment).
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccountService::UpdateParams::Features::IntraStripeFlows))
}
attr_accessor :intra_stripe_flows
# Includes Features related to initiating money movement out of the FinancialAccount to someone else's bucket of money.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccountService::UpdateParams::Features::OutboundPayments))
}
attr_accessor :outbound_payments
# Contains a Feature and settings related to moving money out of the FinancialAccount into another Account with the same owner.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccountService::UpdateParams::Features::OutboundTransfers))
}
attr_accessor :outbound_transfers
sig {
params(card_issuing: T.nilable(::Stripe::Treasury::FinancialAccountService::UpdateParams::Features::CardIssuing), deposit_insurance: T.nilable(::Stripe::Treasury::FinancialAccountService::UpdateParams::Features::DepositInsurance), financial_addresses: T.nilable(::Stripe::Treasury::FinancialAccountService::UpdateParams::Features::FinancialAddresses), inbound_transfers: T.nilable(::Stripe::Treasury::FinancialAccountService::UpdateParams::Features::InboundTransfers), intra_stripe_flows: T.nilable(::Stripe::Treasury::FinancialAccountService::UpdateParams::Features::IntraStripeFlows), outbound_payments: T.nilable(::Stripe::Treasury::FinancialAccountService::UpdateParams::Features::OutboundPayments), outbound_transfers: T.nilable(::Stripe::Treasury::FinancialAccountService::UpdateParams::Features::OutboundTransfers)).void
}
def initialize(
card_issuing: nil,
deposit_insurance: nil,
financial_addresses: nil,
inbound_transfers: nil,
intra_stripe_flows: nil,
outbound_payments: nil,
outbound_transfers: nil
); end
end
class ForwardingSettings < Stripe::RequestParams
# The financial_account id
sig { returns(T.nilable(String)) }
attr_accessor :financial_account
# The payment_method or bank account id. This needs to be a verified bank account.
sig { returns(T.nilable(String)) }
attr_accessor :payment_method
# The type of the bank account provided. This can be either "financial_account" or "payment_method"
sig { returns(String) }
attr_accessor :type
sig {
params(financial_account: T.nilable(String), payment_method: T.nilable(String), type: String).void
}
def initialize(financial_account: nil, payment_method: nil, type: nil); end
end
class PlatformRestrictions < Stripe::RequestParams
# Restricts all inbound money movement.
sig { returns(T.nilable(String)) }
attr_accessor :inbound_flows
# Restricts all outbound money movement.
sig { returns(T.nilable(String)) }
attr_accessor :outbound_flows
sig { params(inbound_flows: T.nilable(String), outbound_flows: T.nilable(String)).void }
def initialize(inbound_flows: nil, outbound_flows: nil); end
end
# The display name for the FinancialAccount. Use this field to customize the names of the FinancialAccounts for your connected accounts. Unlike the `nickname` field, `display_name` is not internal metadata and will be exposed to connected accounts.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :display_name
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Encodes whether a FinancialAccount has access to a particular feature, with a status enum and associated `status_details`. Stripe or the platform may control features via the requested field.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccountService::UpdateParams::Features))
}
attr_accessor :features
# A different bank account where funds can be deposited/debited in order to get the closing FA's balance to $0
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccountService::UpdateParams::ForwardingSettings))
}
attr_accessor :forwarding_settings
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The nickname for the FinancialAccount.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :nickname
# The set of functionalities that the platform can restrict on the FinancialAccount.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccountService::UpdateParams::PlatformRestrictions))
}
attr_accessor :platform_restrictions
sig {
params(display_name: T.nilable(T.nilable(String)), expand: T.nilable(T::Array[String]), features: T.nilable(::Stripe::Treasury::FinancialAccountService::UpdateParams::Features), forwarding_settings: T.nilable(::Stripe::Treasury::FinancialAccountService::UpdateParams::ForwardingSettings), metadata: T.nilable(T::Hash[String, String]), nickname: T.nilable(T.nilable(String)), platform_restrictions: T.nilable(::Stripe::Treasury::FinancialAccountService::UpdateParams::PlatformRestrictions)).void
}
def initialize(
display_name: nil,
expand: nil,
features: nil,
forwarding_settings: nil,
metadata: nil,
nickname: nil,
platform_restrictions: nil
); end
end
class CloseParams < Stripe::RequestParams
class ForwardingSettings < Stripe::RequestParams
# The financial_account id
sig { returns(T.nilable(String)) }
attr_accessor :financial_account
# The payment_method or bank account id. This needs to be a verified bank account.
sig { returns(T.nilable(String)) }
attr_accessor :payment_method
# The type of the bank account provided. This can be either "financial_account" or "payment_method"
sig { returns(String) }
attr_accessor :type
sig {
params(financial_account: T.nilable(String), payment_method: T.nilable(String), type: String).void
}
def initialize(financial_account: nil, payment_method: nil, type: nil); end
end
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A different bank account where funds can be deposited/debited in order to get the closing FA's balance to $0
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccountService::CloseParams::ForwardingSettings))
}
attr_accessor :forwarding_settings
sig {
params(expand: T.nilable(T::Array[String]), forwarding_settings: T.nilable(::Stripe::Treasury::FinancialAccountService::CloseParams::ForwardingSettings)).void
}
def initialize(expand: nil, forwarding_settings: nil); end
end
# Closes a FinancialAccount. A FinancialAccount can only be closed if it has a zero balance, has no pending InboundTransfers, and has canceled all attached Issuing cards.
sig {
params(financial_account: String, params: T.any(::Stripe::Treasury::FinancialAccountService::CloseParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::FinancialAccount)
}
def close(financial_account, params = {}, opts = {}); end
# Creates a new FinancialAccount. Each connected account can have up to three FinancialAccounts by default.
sig {
params(params: T.any(::Stripe::Treasury::FinancialAccountService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::FinancialAccount)
}
def create(params = {}, opts = {}); end
# Returns a list of FinancialAccounts.
sig {
params(params: T.any(::Stripe::Treasury::FinancialAccountService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the details of a FinancialAccount.
sig {
params(financial_account: String, params: T.any(::Stripe::Treasury::FinancialAccountService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::FinancialAccount)
}
def retrieve(financial_account, params = {}, opts = {}); end
# Updates the details of a FinancialAccount.
sig {
params(financial_account: String, params: T.any(::Stripe::Treasury::FinancialAccountService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::FinancialAccount)
}
def update(financial_account, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Treasury
class FinancialAccountFeaturesService < StripeService
class UpdateParams < Stripe::RequestParams
class CardIssuing < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class DepositInsurance < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class FinancialAddresses < Stripe::RequestParams
class Aba < Stripe::RequestParams
# Requested bank partner
sig { returns(T.nilable(String)) }
attr_accessor :bank
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(bank: T.nilable(String), requested: T::Boolean).void }
def initialize(bank: nil, requested: nil); end
end
# Adds an ABA FinancialAddress to the FinancialAccount.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccountFeaturesService::UpdateParams::FinancialAddresses::Aba))
}
attr_accessor :aba
sig {
params(aba: T.nilable(::Stripe::Treasury::FinancialAccountFeaturesService::UpdateParams::FinancialAddresses::Aba)).void
}
def initialize(aba: nil); end
end
class InboundTransfers < Stripe::RequestParams
class Ach < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
# Enables ACH Debits via the InboundTransfers API.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccountFeaturesService::UpdateParams::InboundTransfers::Ach))
}
attr_accessor :ach
sig {
params(ach: T.nilable(::Stripe::Treasury::FinancialAccountFeaturesService::UpdateParams::InboundTransfers::Ach)).void
}
def initialize(ach: nil); end
end
class IntraStripeFlows < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class OutboundPayments < Stripe::RequestParams
class Ach < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class UsDomesticWire < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
# Enables ACH transfers via the OutboundPayments API.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccountFeaturesService::UpdateParams::OutboundPayments::Ach))
}
attr_accessor :ach
# Enables US domestic wire transfers via the OutboundPayments API.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccountFeaturesService::UpdateParams::OutboundPayments::UsDomesticWire))
}
attr_accessor :us_domestic_wire
sig {
params(ach: T.nilable(::Stripe::Treasury::FinancialAccountFeaturesService::UpdateParams::OutboundPayments::Ach), us_domestic_wire: T.nilable(::Stripe::Treasury::FinancialAccountFeaturesService::UpdateParams::OutboundPayments::UsDomesticWire)).void
}
def initialize(ach: nil, us_domestic_wire: nil); end
end
class OutboundTransfers < Stripe::RequestParams
class Ach < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class UsDomesticWire < Stripe::RequestParams
# Whether the FinancialAccount should have the Feature.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
# Enables ACH transfers via the OutboundTransfers API.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccountFeaturesService::UpdateParams::OutboundTransfers::Ach))
}
attr_accessor :ach
# Enables US domestic wire transfers via the OutboundTransfers API.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccountFeaturesService::UpdateParams::OutboundTransfers::UsDomesticWire))
}
attr_accessor :us_domestic_wire
sig {
params(ach: T.nilable(::Stripe::Treasury::FinancialAccountFeaturesService::UpdateParams::OutboundTransfers::Ach), us_domestic_wire: T.nilable(::Stripe::Treasury::FinancialAccountFeaturesService::UpdateParams::OutboundTransfers::UsDomesticWire)).void
}
def initialize(ach: nil, us_domestic_wire: nil); end
end
# Encodes the FinancialAccount's ability to be used with the Issuing product, including attaching cards to and drawing funds from the FinancialAccount.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccountFeaturesService::UpdateParams::CardIssuing))
}
attr_accessor :card_issuing
# Represents whether this FinancialAccount is eligible for deposit insurance. Various factors determine the insurance amount.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccountFeaturesService::UpdateParams::DepositInsurance))
}
attr_accessor :deposit_insurance
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Contains Features that add FinancialAddresses to the FinancialAccount.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccountFeaturesService::UpdateParams::FinancialAddresses))
}
attr_accessor :financial_addresses
# Contains settings related to adding funds to a FinancialAccount from another Account with the same owner.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccountFeaturesService::UpdateParams::InboundTransfers))
}
attr_accessor :inbound_transfers
# Represents the ability for the FinancialAccount to send money to, or receive money from other FinancialAccounts (for example, via OutboundPayment).
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccountFeaturesService::UpdateParams::IntraStripeFlows))
}
attr_accessor :intra_stripe_flows
# Includes Features related to initiating money movement out of the FinancialAccount to someone else's bucket of money.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccountFeaturesService::UpdateParams::OutboundPayments))
}
attr_accessor :outbound_payments
# Contains a Feature and settings related to moving money out of the FinancialAccount into another Account with the same owner.
sig {
returns(T.nilable(::Stripe::Treasury::FinancialAccountFeaturesService::UpdateParams::OutboundTransfers))
}
attr_accessor :outbound_transfers
sig {
params(card_issuing: T.nilable(::Stripe::Treasury::FinancialAccountFeaturesService::UpdateParams::CardIssuing), deposit_insurance: T.nilable(::Stripe::Treasury::FinancialAccountFeaturesService::UpdateParams::DepositInsurance), expand: T.nilable(T::Array[String]), financial_addresses: T.nilable(::Stripe::Treasury::FinancialAccountFeaturesService::UpdateParams::FinancialAddresses), inbound_transfers: T.nilable(::Stripe::Treasury::FinancialAccountFeaturesService::UpdateParams::InboundTransfers), intra_stripe_flows: T.nilable(::Stripe::Treasury::FinancialAccountFeaturesService::UpdateParams::IntraStripeFlows), outbound_payments: T.nilable(::Stripe::Treasury::FinancialAccountFeaturesService::UpdateParams::OutboundPayments), outbound_transfers: T.nilable(::Stripe::Treasury::FinancialAccountFeaturesService::UpdateParams::OutboundTransfers)).void
}
def initialize(
card_issuing: nil,
deposit_insurance: nil,
expand: nil,
financial_addresses: nil,
inbound_transfers: nil,
intra_stripe_flows: nil,
outbound_payments: nil,
outbound_transfers: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Retrieves Features information associated with the FinancialAccount.
sig {
params(financial_account: String, params: T.any(::Stripe::Treasury::FinancialAccountFeaturesService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::FinancialAccountFeatures)
}
def retrieve(financial_account, params = {}, opts = {}); end
# Updates the Features associated with a FinancialAccount.
sig {
params(financial_account: String, params: T.any(::Stripe::Treasury::FinancialAccountFeaturesService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::FinancialAccountFeatures)
}
def update(financial_account, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Treasury
class InboundTransferService < StripeService
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Returns objects associated with this FinancialAccount.
sig { returns(String) }
attr_accessor :financial_account
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return InboundTransfers that have the given status: `processing`, `succeeded`, `failed` or `canceled`.
sig { returns(T.nilable(String)) }
attr_accessor :status
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), financial_account: String, limit: T.nilable(Integer), starting_after: T.nilable(String), status: T.nilable(String)).void
}
def initialize(
ending_before: nil,
expand: nil,
financial_account: nil,
limit: nil,
starting_after: nil,
status: nil
); end
end
class CreateParams < Stripe::RequestParams
# Amount (in cents) to be transferred.
sig { returns(Integer) }
attr_accessor :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).
sig { returns(String) }
attr_accessor :currency
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The FinancialAccount to send funds to.
sig { returns(String) }
attr_accessor :financial_account
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The origin payment method to be debited for the InboundTransfer.
sig { returns(String) }
attr_accessor :origin_payment_method
# The complete description that appears on your customers' statements. Maximum 10 characters.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
sig {
params(amount: Integer, currency: String, description: T.nilable(String), expand: T.nilable(T::Array[String]), financial_account: String, metadata: T.nilable(T::Hash[String, String]), origin_payment_method: String, statement_descriptor: T.nilable(String)).void
}
def initialize(
amount: nil,
currency: nil,
description: nil,
expand: nil,
financial_account: nil,
metadata: nil,
origin_payment_method: nil,
statement_descriptor: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class CancelParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Cancels an InboundTransfer.
sig {
params(inbound_transfer: String, params: T.any(::Stripe::Treasury::InboundTransferService::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::InboundTransfer)
}
def cancel(inbound_transfer, params = {}, opts = {}); end
# Creates an InboundTransfer.
sig {
params(params: T.any(::Stripe::Treasury::InboundTransferService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::InboundTransfer)
}
def create(params = {}, opts = {}); end
# Returns a list of InboundTransfers sent from the specified FinancialAccount.
sig {
params(params: T.any(::Stripe::Treasury::InboundTransferService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the details of an existing InboundTransfer.
sig {
params(id: String, params: T.any(::Stripe::Treasury::InboundTransferService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::InboundTransfer)
}
def retrieve(id, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Treasury
class OutboundPaymentService < StripeService
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return OutboundPayments that were created during the given date interval.
sig {
returns(T.nilable(T.any(::Stripe::Treasury::OutboundPaymentService::ListParams::Created, Integer)))
}
attr_accessor :created
# Only return OutboundPayments sent to this customer.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Returns objects associated with this FinancialAccount.
sig { returns(String) }
attr_accessor :financial_account
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return OutboundPayments that have the given status: `processing`, `failed`, `posted`, `returned`, or `canceled`.
sig { returns(T.nilable(String)) }
attr_accessor :status
sig {
params(created: T.nilable(T.any(::Stripe::Treasury::OutboundPaymentService::ListParams::Created, Integer)), customer: T.nilable(String), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), financial_account: String, limit: T.nilable(Integer), starting_after: T.nilable(String), status: T.nilable(String)).void
}
def initialize(
created: nil,
customer: nil,
ending_before: nil,
expand: nil,
financial_account: nil,
limit: nil,
starting_after: nil,
status: nil
); end
end
class CreateParams < Stripe::RequestParams
class DestinationPaymentMethodData < Stripe::RequestParams
class BillingDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Billing address.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Treasury::OutboundPaymentService::CreateParams::DestinationPaymentMethodData::BillingDetails::Address))))
}
attr_accessor :address
# Email address.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :email
# Full name.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :name
# Billing phone number (including extension).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :phone
sig {
params(address: T.nilable(T.nilable(T.any(String, ::Stripe::Treasury::OutboundPaymentService::CreateParams::DestinationPaymentMethodData::BillingDetails::Address))), email: T.nilable(T.nilable(String)), name: T.nilable(T.nilable(String)), phone: T.nilable(T.nilable(String))).void
}
def initialize(address: nil, email: nil, name: nil, phone: nil); end
end
class UsBankAccount < Stripe::RequestParams
# Account holder type: individual or company.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_type
# Account number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :account_number
# Account type: checkings or savings. Defaults to checking if omitted.
sig { returns(T.nilable(String)) }
attr_accessor :account_type
# The ID of a Financial Connections Account to use as a payment method.
sig { returns(T.nilable(String)) }
attr_accessor :financial_connections_account
# Routing number of the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :routing_number
sig {
params(account_holder_type: T.nilable(String), account_number: T.nilable(String), account_type: T.nilable(String), financial_connections_account: T.nilable(String), routing_number: T.nilable(String)).void
}
def initialize(
account_holder_type: nil,
account_number: nil,
account_type: nil,
financial_connections_account: nil,
routing_number: nil
); end
end
# Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
sig {
returns(T.nilable(::Stripe::Treasury::OutboundPaymentService::CreateParams::DestinationPaymentMethodData::BillingDetails))
}
attr_accessor :billing_details
# Required if type is set to `financial_account`. The FinancialAccount ID to send funds to.
sig { returns(T.nilable(String)) }
attr_accessor :financial_account
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a name matching this value. It contains additional information specific to the PaymentMethod type.
sig { returns(String) }
attr_accessor :type
# Required hash if type is set to `us_bank_account`.
sig {
returns(T.nilable(::Stripe::Treasury::OutboundPaymentService::CreateParams::DestinationPaymentMethodData::UsBankAccount))
}
attr_accessor :us_bank_account
sig {
params(billing_details: T.nilable(::Stripe::Treasury::OutboundPaymentService::CreateParams::DestinationPaymentMethodData::BillingDetails), financial_account: T.nilable(String), metadata: T.nilable(T::Hash[String, String]), type: String, us_bank_account: T.nilable(::Stripe::Treasury::OutboundPaymentService::CreateParams::DestinationPaymentMethodData::UsBankAccount)).void
}
def initialize(
billing_details: nil,
financial_account: nil,
metadata: nil,
type: nil,
us_bank_account: nil
); end
end
class DestinationPaymentMethodOptions < Stripe::RequestParams
class UsBankAccount < Stripe::RequestParams
# Specifies the network rails to be used. If not set, will default to the PaymentMethod's preferred network. See the [docs](https://stripe.com/docs/treasury/money-movement/timelines) to learn more about money movement timelines for each network type.
sig { returns(T.nilable(String)) }
attr_accessor :network
sig { params(network: T.nilable(String)).void }
def initialize(network: nil); end
end
# Optional fields for `us_bank_account`.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Treasury::OutboundPaymentService::CreateParams::DestinationPaymentMethodOptions::UsBankAccount))))
}
attr_accessor :us_bank_account
sig {
params(us_bank_account: T.nilable(T.nilable(T.any(String, ::Stripe::Treasury::OutboundPaymentService::CreateParams::DestinationPaymentMethodOptions::UsBankAccount)))).void
}
def initialize(us_bank_account: nil); end
end
class EndUserDetails < Stripe::RequestParams
# IP address of the user initiating the OutboundPayment. Must be supplied if `present` is set to `true`.
sig { returns(T.nilable(String)) }
attr_accessor :ip_address
# `True` if the OutboundPayment creation request is being made on behalf of an end user by a platform. Otherwise, `false`.
sig { returns(T::Boolean) }
attr_accessor :present
sig { params(ip_address: T.nilable(String), present: T::Boolean).void }
def initialize(ip_address: nil, present: nil); end
end
# Amount (in cents) to be transferred.
sig { returns(Integer) }
attr_accessor :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).
sig { returns(String) }
attr_accessor :currency
# ID of the customer to whom the OutboundPayment is sent. Must match the Customer attached to the `destination_payment_method` passed in.
sig { returns(T.nilable(String)) }
attr_accessor :customer
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# The PaymentMethod to use as the payment instrument for the OutboundPayment. Exclusive with `destination_payment_method_data`.
sig { returns(T.nilable(String)) }
attr_accessor :destination_payment_method
# Hash used to generate the PaymentMethod to be used for this OutboundPayment. Exclusive with `destination_payment_method`.
sig {
returns(T.nilable(::Stripe::Treasury::OutboundPaymentService::CreateParams::DestinationPaymentMethodData))
}
attr_accessor :destination_payment_method_data
# Payment method-specific configuration for this OutboundPayment.
sig {
returns(T.nilable(::Stripe::Treasury::OutboundPaymentService::CreateParams::DestinationPaymentMethodOptions))
}
attr_accessor :destination_payment_method_options
# End user details.
sig {
returns(T.nilable(::Stripe::Treasury::OutboundPaymentService::CreateParams::EndUserDetails))
}
attr_accessor :end_user_details
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The FinancialAccount to pull funds from.
sig { returns(String) }
attr_accessor :financial_account
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The description that appears on the receiving end for this OutboundPayment (for example, bank statement for external bank transfer). Maximum 10 characters for `ach` payments, 140 characters for `us_domestic_wire` payments, or 500 characters for `stripe` network transfers. The default value is "payment".
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
sig {
params(amount: Integer, currency: String, customer: T.nilable(String), description: T.nilable(String), destination_payment_method: T.nilable(String), destination_payment_method_data: T.nilable(::Stripe::Treasury::OutboundPaymentService::CreateParams::DestinationPaymentMethodData), destination_payment_method_options: T.nilable(::Stripe::Treasury::OutboundPaymentService::CreateParams::DestinationPaymentMethodOptions), end_user_details: T.nilable(::Stripe::Treasury::OutboundPaymentService::CreateParams::EndUserDetails), expand: T.nilable(T::Array[String]), financial_account: String, metadata: T.nilable(T::Hash[String, String]), statement_descriptor: T.nilable(String)).void
}
def initialize(
amount: nil,
currency: nil,
customer: nil,
description: nil,
destination_payment_method: nil,
destination_payment_method_data: nil,
destination_payment_method_options: nil,
end_user_details: nil,
expand: nil,
financial_account: nil,
metadata: nil,
statement_descriptor: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class CancelParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Cancel an OutboundPayment.
sig {
params(id: String, params: T.any(::Stripe::Treasury::OutboundPaymentService::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::OutboundPayment)
}
def cancel(id, params = {}, opts = {}); end
# Creates an OutboundPayment.
sig {
params(params: T.any(::Stripe::Treasury::OutboundPaymentService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::OutboundPayment)
}
def create(params = {}, opts = {}); end
# Returns a list of OutboundPayments sent from the specified FinancialAccount.
sig {
params(params: T.any(::Stripe::Treasury::OutboundPaymentService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the details of an existing OutboundPayment by passing the unique OutboundPayment ID from either the OutboundPayment creation request or OutboundPayment list.
sig {
params(id: String, params: T.any(::Stripe::Treasury::OutboundPaymentService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::OutboundPayment)
}
def retrieve(id, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Treasury
class OutboundTransferService < StripeService
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Returns objects associated with this FinancialAccount.
sig { returns(String) }
attr_accessor :financial_account
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return OutboundTransfers that have the given status: `processing`, `canceled`, `failed`, `posted`, or `returned`.
sig { returns(T.nilable(String)) }
attr_accessor :status
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), financial_account: String, limit: T.nilable(Integer), starting_after: T.nilable(String), status: T.nilable(String)).void
}
def initialize(
ending_before: nil,
expand: nil,
financial_account: nil,
limit: nil,
starting_after: nil,
status: nil
); end
end
class CreateParams < Stripe::RequestParams
class DestinationPaymentMethodData < Stripe::RequestParams
# Required if type is set to `financial_account`. The FinancialAccount ID to send funds to.
sig { returns(T.nilable(String)) }
attr_accessor :financial_account
# The type of the destination.
sig { returns(String) }
attr_accessor :type
sig { params(financial_account: T.nilable(String), type: String).void }
def initialize(financial_account: nil, type: nil); end
end
class DestinationPaymentMethodOptions < Stripe::RequestParams
class UsBankAccount < Stripe::RequestParams
# Specifies the network rails to be used. If not set, will default to the PaymentMethod's preferred network. See the [docs](https://stripe.com/docs/treasury/money-movement/timelines) to learn more about money movement timelines for each network type.
sig { returns(T.nilable(String)) }
attr_accessor :network
sig { params(network: T.nilable(String)).void }
def initialize(network: nil); end
end
# Optional fields for `us_bank_account`.
sig {
returns(T.nilable(T.nilable(T.any(String, ::Stripe::Treasury::OutboundTransferService::CreateParams::DestinationPaymentMethodOptions::UsBankAccount))))
}
attr_accessor :us_bank_account
sig {
params(us_bank_account: T.nilable(T.nilable(T.any(String, ::Stripe::Treasury::OutboundTransferService::CreateParams::DestinationPaymentMethodOptions::UsBankAccount)))).void
}
def initialize(us_bank_account: nil); end
end
class NetworkDetails < Stripe::RequestParams
class Ach < Stripe::RequestParams
# Addenda record data associated with this OutboundTransfer.
sig { returns(T.nilable(String)) }
attr_accessor :addenda
sig { params(addenda: T.nilable(String)).void }
def initialize(addenda: nil); end
end
# Optional fields for `ach`.
sig {
returns(T.nilable(::Stripe::Treasury::OutboundTransferService::CreateParams::NetworkDetails::Ach))
}
attr_accessor :ach
# The type of flow that originated the OutboundTransfer.
sig { returns(String) }
attr_accessor :type
sig {
params(ach: T.nilable(::Stripe::Treasury::OutboundTransferService::CreateParams::NetworkDetails::Ach), type: String).void
}
def initialize(ach: nil, type: nil); end
end
# Amount (in cents) to be transferred.
sig { returns(Integer) }
attr_accessor :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).
sig { returns(String) }
attr_accessor :currency
# An arbitrary string attached to the object. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# The PaymentMethod to use as the payment instrument for the OutboundTransfer.
sig { returns(T.nilable(String)) }
attr_accessor :destination_payment_method
# Hash used to generate the PaymentMethod to be used for this OutboundTransfer. Exclusive with `destination_payment_method`.
sig {
returns(T.nilable(::Stripe::Treasury::OutboundTransferService::CreateParams::DestinationPaymentMethodData))
}
attr_accessor :destination_payment_method_data
# Hash describing payment method configuration details.
sig {
returns(T.nilable(::Stripe::Treasury::OutboundTransferService::CreateParams::DestinationPaymentMethodOptions))
}
attr_accessor :destination_payment_method_options
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The FinancialAccount to pull funds from.
sig { returns(String) }
attr_accessor :financial_account
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Details about the network used for the OutboundTransfer.
sig {
returns(T.nilable(::Stripe::Treasury::OutboundTransferService::CreateParams::NetworkDetails))
}
attr_accessor :network_details
# Statement descriptor to be shown on the receiving end of an OutboundTransfer. Maximum 10 characters for `ach` transfers or 140 characters for `us_domestic_wire` transfers. The default value is "transfer".
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
sig {
params(amount: Integer, currency: String, description: T.nilable(String), destination_payment_method: T.nilable(String), destination_payment_method_data: T.nilable(::Stripe::Treasury::OutboundTransferService::CreateParams::DestinationPaymentMethodData), destination_payment_method_options: T.nilable(::Stripe::Treasury::OutboundTransferService::CreateParams::DestinationPaymentMethodOptions), expand: T.nilable(T::Array[String]), financial_account: String, metadata: T.nilable(T::Hash[String, String]), network_details: T.nilable(::Stripe::Treasury::OutboundTransferService::CreateParams::NetworkDetails), statement_descriptor: T.nilable(String)).void
}
def initialize(
amount: nil,
currency: nil,
description: nil,
destination_payment_method: nil,
destination_payment_method_data: nil,
destination_payment_method_options: nil,
expand: nil,
financial_account: nil,
metadata: nil,
network_details: nil,
statement_descriptor: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class CancelParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# An OutboundTransfer can be canceled if the funds have not yet been paid out.
sig {
params(outbound_transfer: String, params: T.any(::Stripe::Treasury::OutboundTransferService::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::OutboundTransfer)
}
def cancel(outbound_transfer, params = {}, opts = {}); end
# Creates an OutboundTransfer.
sig {
params(params: T.any(::Stripe::Treasury::OutboundTransferService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::OutboundTransfer)
}
def create(params = {}, opts = {}); end
# Returns a list of OutboundTransfers sent from the specified FinancialAccount.
sig {
params(params: T.any(::Stripe::Treasury::OutboundTransferService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the details of an existing OutboundTransfer by passing the unique OutboundTransfer ID from either the OutboundTransfer creation request or OutboundTransfer list.
sig {
params(outbound_transfer: String, params: T.any(::Stripe::Treasury::OutboundTransferService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::OutboundTransfer)
}
def retrieve(outbound_transfer, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Treasury
class ReceivedCreditService < StripeService
class ListParams < Stripe::RequestParams
class LinkedFlows < Stripe::RequestParams
# The source flow type.
sig { returns(String) }
attr_accessor :source_flow_type
sig { params(source_flow_type: String).void }
def initialize(source_flow_type: nil); end
end
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The FinancialAccount that received the funds.
sig { returns(String) }
attr_accessor :financial_account
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Only return ReceivedCredits described by the flow.
sig {
returns(T.nilable(::Stripe::Treasury::ReceivedCreditService::ListParams::LinkedFlows))
}
attr_accessor :linked_flows
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return ReceivedCredits that have the given status: `succeeded` or `failed`.
sig { returns(T.nilable(String)) }
attr_accessor :status
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), financial_account: String, limit: T.nilable(Integer), linked_flows: T.nilable(::Stripe::Treasury::ReceivedCreditService::ListParams::LinkedFlows), starting_after: T.nilable(String), status: T.nilable(String)).void
}
def initialize(
ending_before: nil,
expand: nil,
financial_account: nil,
limit: nil,
linked_flows: nil,
starting_after: nil,
status: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Returns a list of ReceivedCredits.
sig {
params(params: T.any(::Stripe::Treasury::ReceivedCreditService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the details of an existing ReceivedCredit by passing the unique ReceivedCredit ID from the ReceivedCredit list.
sig {
params(id: String, params: T.any(::Stripe::Treasury::ReceivedCreditService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::ReceivedCredit)
}
def retrieve(id, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Treasury
class ReceivedDebitService < StripeService
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# The FinancialAccount that funds were pulled from.
sig { returns(String) }
attr_accessor :financial_account
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return ReceivedDebits that have the given status: `succeeded` or `failed`.
sig { returns(T.nilable(String)) }
attr_accessor :status
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), financial_account: String, limit: T.nilable(Integer), starting_after: T.nilable(String), status: T.nilable(String)).void
}
def initialize(
ending_before: nil,
expand: nil,
financial_account: nil,
limit: nil,
starting_after: nil,
status: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Returns a list of ReceivedDebits.
sig {
params(params: T.any(::Stripe::Treasury::ReceivedDebitService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the details of an existing ReceivedDebit by passing the unique ReceivedDebit ID from the ReceivedDebit list
sig {
params(id: String, params: T.any(::Stripe::Treasury::ReceivedDebitService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::ReceivedDebit)
}
def retrieve(id, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Treasury
class TransactionService < StripeService
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
class StatusTransitions < Stripe::RequestParams
class PostedAt < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Returns Transactions with `posted_at` within the specified range.
sig {
returns(T.nilable(T.any(::Stripe::Treasury::TransactionService::ListParams::StatusTransitions::PostedAt, Integer)))
}
attr_accessor :posted_at
sig {
params(posted_at: T.nilable(T.any(::Stripe::Treasury::TransactionService::ListParams::StatusTransitions::PostedAt, Integer))).void
}
def initialize(posted_at: nil); end
end
# Only return Transactions that were created during the given date interval.
sig {
returns(T.nilable(T.any(::Stripe::Treasury::TransactionService::ListParams::Created, Integer)))
}
attr_accessor :created
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Returns objects associated with this FinancialAccount.
sig { returns(String) }
attr_accessor :financial_account
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# The results are in reverse chronological order by `created` or `posted_at`. The default is `created`.
sig { returns(T.nilable(String)) }
attr_accessor :order_by
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return Transactions that have the given status: `open`, `posted`, or `void`.
sig { returns(T.nilable(String)) }
attr_accessor :status
# A filter for the `status_transitions.posted_at` timestamp. When using this filter, `status=posted` and `order_by=posted_at` must also be specified.
sig {
returns(T.nilable(::Stripe::Treasury::TransactionService::ListParams::StatusTransitions))
}
attr_accessor :status_transitions
sig {
params(created: T.nilable(T.any(::Stripe::Treasury::TransactionService::ListParams::Created, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), financial_account: String, limit: T.nilable(Integer), order_by: T.nilable(String), starting_after: T.nilable(String), status: T.nilable(String), status_transitions: T.nilable(::Stripe::Treasury::TransactionService::ListParams::StatusTransitions)).void
}
def initialize(
created: nil,
ending_before: nil,
expand: nil,
financial_account: nil,
limit: nil,
order_by: nil,
starting_after: nil,
status: nil,
status_transitions: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Retrieves a list of Transaction objects.
sig {
params(params: T.any(::Stripe::Treasury::TransactionService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the details of an existing Transaction.
sig {
params(id: String, params: T.any(::Stripe::Treasury::TransactionService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::Transaction)
}
def retrieve(id, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
module Treasury
class TransactionEntryService < StripeService
class ListParams < Stripe::RequestParams
class Created < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
class EffectiveAt < Stripe::RequestParams
# Minimum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gt
# Minimum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :gte
# Maximum value to filter by (exclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lt
# Maximum value to filter by (inclusive)
sig { returns(T.nilable(Integer)) }
attr_accessor :lte
sig {
params(gt: T.nilable(Integer), gte: T.nilable(Integer), lt: T.nilable(Integer), lte: T.nilable(Integer)).void
}
def initialize(gt: nil, gte: nil, lt: nil, lte: nil); end
end
# Only return TransactionEntries that were created during the given date interval.
sig {
returns(T.nilable(T.any(::Stripe::Treasury::TransactionEntryService::ListParams::Created, Integer)))
}
attr_accessor :created
# Attribute for param field effective_at
sig {
returns(T.nilable(T.any(::Stripe::Treasury::TransactionEntryService::ListParams::EffectiveAt, Integer)))
}
attr_accessor :effective_at
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Returns objects associated with this FinancialAccount.
sig { returns(String) }
attr_accessor :financial_account
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# The results are in reverse chronological order by `created` or `effective_at`. The default is `created`.
sig { returns(T.nilable(String)) }
attr_accessor :order_by
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
# Only return TransactionEntries associated with this Transaction.
sig { returns(T.nilable(String)) }
attr_accessor :transaction
sig {
params(created: T.nilable(T.any(::Stripe::Treasury::TransactionEntryService::ListParams::Created, Integer)), effective_at: T.nilable(T.any(::Stripe::Treasury::TransactionEntryService::ListParams::EffectiveAt, Integer)), ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), financial_account: String, limit: T.nilable(Integer), order_by: T.nilable(String), starting_after: T.nilable(String), transaction: T.nilable(String)).void
}
def initialize(
created: nil,
effective_at: nil,
ending_before: nil,
expand: nil,
financial_account: nil,
limit: nil,
order_by: nil,
starting_after: nil,
transaction: nil
); end
end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
# Retrieves a list of TransactionEntry objects.
sig {
params(params: T.any(::Stripe::Treasury::TransactionEntryService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves a TransactionEntry object.
sig {
params(id: String, params: T.any(::Stripe::Treasury::TransactionEntryService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::Treasury::TransactionEntry)
}
def retrieve(id, params = {}, opts = {}); end
end
end
end
# typed: true
module Stripe
class WebhookEndpointService < StripeService
class DeleteParams < Stripe::RequestParams; end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
# An optional description of what the webhook is used for.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :description
# Disable the webhook endpoint if set to true.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :disabled
# The list of events to enable for this endpoint. You may specify `['*']` to enable all events, except those that require explicit selection.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :enabled_events
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# The URL of the webhook endpoint.
sig { returns(T.nilable(String)) }
attr_accessor :url
sig {
params(description: T.nilable(T.nilable(String)), disabled: T.nilable(T::Boolean), enabled_events: T.nilable(T::Array[String]), expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), url: T.nilable(String)).void
}
def initialize(
description: nil,
disabled: nil,
enabled_events: nil,
expand: nil,
metadata: nil,
url: nil
); end
end
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), starting_after: T.nilable(String)).void
}
def initialize(ending_before: nil, expand: nil, limit: nil, starting_after: nil); end
end
class CreateParams < Stripe::RequestParams
# Events sent to this endpoint will be generated with this Stripe Version instead of your account's default Stripe Version.
sig { returns(T.nilable(String)) }
attr_accessor :api_version
# Whether this endpoint should receive events from connected accounts (`true`), or from your account (`false`). Defaults to `false`.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :connect
# An optional description of what the webhook is used for.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :description
# The list of events to enable for this endpoint. You may specify `['*']` to enable all events, except those that require explicit selection.
sig { returns(T::Array[String]) }
attr_accessor :enabled_events
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# The URL of the webhook endpoint.
sig { returns(String) }
attr_accessor :url
sig {
params(api_version: T.nilable(String), connect: T.nilable(T::Boolean), description: T.nilable(T.nilable(String)), enabled_events: T::Array[String], expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), url: String).void
}
def initialize(
api_version: nil,
connect: nil,
description: nil,
enabled_events: nil,
expand: nil,
metadata: nil,
url: nil
); end
end
# A webhook endpoint must have a url and a list of enabled_events. You may optionally specify the Boolean connect parameter. If set to true, then a Connect webhook endpoint that notifies the specified url about events from all connected accounts is created; otherwise an account webhook endpoint that notifies the specified url only about events from your account is created. You can also create webhook endpoints in the [webhooks settings](https://dashboard.stripe.com/account/webhooks) section of the Dashboard.
sig {
params(params: T.any(::Stripe::WebhookEndpointService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::WebhookEndpoint)
}
def create(params = {}, opts = {}); end
# You can also delete webhook endpoints via the [webhook endpoint management](https://dashboard.stripe.com/account/webhooks) page of the Stripe dashboard.
sig {
params(webhook_endpoint: String, params: T.any(::Stripe::WebhookEndpointService::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::WebhookEndpoint)
}
def delete(webhook_endpoint, params = {}, opts = {}); end
# Returns a list of your webhook endpoints.
sig {
params(params: T.any(::Stripe::WebhookEndpointService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the webhook endpoint with the given ID.
sig {
params(webhook_endpoint: String, params: T.any(::Stripe::WebhookEndpointService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::WebhookEndpoint)
}
def retrieve(webhook_endpoint, params = {}, opts = {}); end
# Updates the webhook endpoint. You may edit the url, the list of enabled_events, and the status of your endpoint.
sig {
params(webhook_endpoint: String, params: T.any(::Stripe::WebhookEndpointService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::WebhookEndpoint)
}
def update(webhook_endpoint, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class ExternalAccountService < StripeService
class DeleteParams < Stripe::RequestParams; end
class RetrieveParams < Stripe::RequestParams
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
sig { params(expand: T.nilable(T::Array[String])).void }
def initialize(expand: nil); end
end
class UpdateParams < Stripe::RequestParams
class Documents < Stripe::RequestParams
class BankAccountOwnershipVerification < Stripe::RequestParams
# One or more document ids returned by a [file upload](https://stripe.com/docs/api#create_file) with a `purpose` value of `account_requirement`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :files
sig { params(files: T.nilable(T::Array[String])).void }
def initialize(files: nil); end
end
# One or more documents that support the [Bank account ownership verification](https://support.stripe.com/questions/bank-account-ownership-verification) requirement. Must be a document associated with the bank account that displays the last 4 digits of the account number, either a statement or a check.
sig {
returns(T.nilable(::Stripe::ExternalAccountService::UpdateParams::Documents::BankAccountOwnershipVerification))
}
attr_accessor :bank_account_ownership_verification
sig {
params(bank_account_ownership_verification: T.nilable(::Stripe::ExternalAccountService::UpdateParams::Documents::BankAccountOwnershipVerification)).void
}
def initialize(bank_account_ownership_verification: nil); end
end
# The name of the person or business that owns the bank account.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_name
# The type of entity that holds the account. This can be either `individual` or `company`.
sig { returns(T.nilable(T.nilable(T.any(String, String)))) }
attr_accessor :account_holder_type
# The bank account type. This can only be `checking` or `savings` in most countries. In Japan, this can only be `futsu` or `toza`.
sig { returns(T.nilable(String)) }
attr_accessor :account_type
# City/District/Suburb/Town/Village.
sig { returns(T.nilable(String)) }
attr_accessor :address_city
# Billing address country, if provided when creating card.
sig { returns(T.nilable(String)) }
attr_accessor :address_country
# Address line 1 (Street address/PO Box/Company name).
sig { returns(T.nilable(String)) }
attr_accessor :address_line1
# Address line 2 (Apartment/Suite/Unit/Building).
sig { returns(T.nilable(String)) }
attr_accessor :address_line2
# State/County/Province/Region.
sig { returns(T.nilable(String)) }
attr_accessor :address_state
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :address_zip
# When set to true, this becomes the default external account for its currency.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :default_for_currency
# Documents that may be submitted to satisfy various informational requests.
sig { returns(T.nilable(::Stripe::ExternalAccountService::UpdateParams::Documents)) }
attr_accessor :documents
# Two digit number representing the card’s expiration month.
sig { returns(T.nilable(String)) }
attr_accessor :exp_month
# Four digit number representing the card’s expiration year.
sig { returns(T.nilable(String)) }
attr_accessor :exp_year
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# 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`.
sig { returns(T.nilable(T.nilable(T.any(String, T::Hash[String, String])))) }
attr_accessor :metadata
# Cardholder name.
sig { returns(T.nilable(String)) }
attr_accessor :name
sig {
params(account_holder_name: T.nilable(String), account_holder_type: T.nilable(T.nilable(T.any(String, String))), account_type: T.nilable(String), address_city: T.nilable(String), address_country: T.nilable(String), address_line1: T.nilable(String), address_line2: T.nilable(String), address_state: T.nilable(String), address_zip: T.nilable(String), default_for_currency: T.nilable(T::Boolean), documents: T.nilable(::Stripe::ExternalAccountService::UpdateParams::Documents), exp_month: T.nilable(String), exp_year: T.nilable(String), expand: T.nilable(T::Array[String]), metadata: T.nilable(T.nilable(T.any(String, T::Hash[String, String]))), name: T.nilable(String)).void
}
def initialize(
account_holder_name: nil,
account_holder_type: nil,
account_type: nil,
address_city: nil,
address_country: nil,
address_line1: nil,
address_line2: nil,
address_state: nil,
address_zip: nil,
default_for_currency: nil,
documents: nil,
exp_month: nil,
exp_year: nil,
expand: nil,
metadata: nil,
name: nil
); end
end
class ListParams < Stripe::RequestParams
# A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :ending_before
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Filter external accounts according to a particular object type.
sig { returns(T.nilable(String)) }
attr_accessor :object
# A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list.
sig { returns(T.nilable(String)) }
attr_accessor :starting_after
sig {
params(ending_before: T.nilable(String), expand: T.nilable(T::Array[String]), limit: T.nilable(Integer), object: T.nilable(String), starting_after: T.nilable(String)).void
}
def initialize(
ending_before: nil,
expand: nil,
limit: nil,
object: nil,
starting_after: nil
); end
end
class CreateParams < Stripe::RequestParams
class BankAccount < Stripe::RequestParams
# Attribute for param field object
sig { returns(String) }
attr_accessor :object
# The name of the person or business that owns the bank account.This field is required when attaching the bank account to a `Customer` object.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_name
# The type of entity that holds the account. It can be `company` or `individual`. This field is required when attaching the bank account to a `Customer` object.
sig { returns(T.nilable(String)) }
attr_accessor :account_holder_type
# The account number for the bank account, in string form. Must be a checking account.
sig { returns(String) }
attr_accessor :account_number
# The country in which the bank account is located.
sig { returns(String) }
attr_accessor :country
# The currency the bank account is in. This must be a country/currency pairing that [Stripe supports.](docs/payouts)
sig { returns(T.nilable(String)) }
attr_accessor :currency
# The routing number, sort code, or other country-appropriate institution number for the bank account. For US bank accounts, this is required and should be the ACH routing number, not the wire routing number. If you are providing an IBAN for `account_number`, this field is not required.
sig { returns(T.nilable(String)) }
attr_accessor :routing_number
sig {
params(object: String, account_holder_name: T.nilable(String), account_holder_type: T.nilable(String), account_number: String, country: String, currency: T.nilable(String), routing_number: T.nilable(String)).void
}
def initialize(
object: nil,
account_holder_name: nil,
account_holder_type: nil,
account_number: nil,
country: nil,
currency: nil,
routing_number: nil
); end
end
class Card < Stripe::RequestParams
# Attribute for param field object
sig { returns(String) }
attr_accessor :object
# Attribute for param field address_city
sig { returns(T.nilable(String)) }
attr_accessor :address_city
# Attribute for param field address_country
sig { returns(T.nilable(String)) }
attr_accessor :address_country
# Attribute for param field address_line1
sig { returns(T.nilable(String)) }
attr_accessor :address_line1
# Attribute for param field address_line2
sig { returns(T.nilable(String)) }
attr_accessor :address_line2
# Attribute for param field address_state
sig { returns(T.nilable(String)) }
attr_accessor :address_state
# Attribute for param field address_zip
sig { returns(T.nilable(String)) }
attr_accessor :address_zip
# Attribute for param field currency
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Attribute for param field cvc
sig { returns(T.nilable(String)) }
attr_accessor :cvc
# Attribute for param field exp_month
sig { returns(Integer) }
attr_accessor :exp_month
# Attribute for param field exp_year
sig { returns(Integer) }
attr_accessor :exp_year
# Attribute for param field name
sig { returns(T.nilable(String)) }
attr_accessor :name
# Attribute for param field number
sig { returns(String) }
attr_accessor :number
# 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.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
sig {
params(object: String, address_city: T.nilable(String), address_country: T.nilable(String), address_line1: T.nilable(String), address_line2: T.nilable(String), address_state: T.nilable(String), address_zip: T.nilable(String), currency: T.nilable(String), cvc: T.nilable(String), exp_month: Integer, exp_year: Integer, name: T.nilable(String), number: String, metadata: T.nilable(T::Hash[String, String])).void
}
def initialize(
object: nil,
address_city: nil,
address_country: nil,
address_line1: nil,
address_line2: nil,
address_state: nil,
address_zip: nil,
currency: nil,
cvc: nil,
exp_month: nil,
exp_year: nil,
name: nil,
number: nil,
metadata: nil
); end
end
class CardToken < Stripe::RequestParams
# Attribute for param field object
sig { returns(String) }
attr_accessor :object
# Attribute for param field currency
sig { returns(T.nilable(String)) }
attr_accessor :currency
# Attribute for param field token
sig { returns(String) }
attr_accessor :token
sig { params(object: String, currency: T.nilable(String), token: String).void }
def initialize(object: nil, currency: nil, token: nil); end
end
# When set to true, or if this is the first external account added in this currency, this account becomes the default external account for its currency.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :default_for_currency
# Specifies which fields in the response should be expanded.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :expand
# Either a token, like the ones returned by [Stripe.js](https://stripe.com/docs/js), or a dictionary containing a user’s external account details (with the options shown below).
sig {
returns(T.any(String, ::Stripe::ExternalAccountService::CreateParams::Card, ::Stripe::ExternalAccountService::CreateParams::BankAccount, ::Stripe::ExternalAccountService::CreateParams::CardToken))
}
attr_accessor :external_account
# 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`.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
sig {
params(default_for_currency: T.nilable(T::Boolean), expand: T.nilable(T::Array[String]), external_account: T.any(String, ::Stripe::ExternalAccountService::CreateParams::Card, ::Stripe::ExternalAccountService::CreateParams::BankAccount, ::Stripe::ExternalAccountService::CreateParams::CardToken), metadata: T.nilable(T::Hash[String, String])).void
}
def initialize(
default_for_currency: nil,
expand: nil,
external_account: nil,
metadata: nil
); end
end
# Create an external account for a given connected account.
sig {
params(params: T.any(::Stripe::ExternalAccountService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(T.any(Stripe::BankAccount, Stripe::Card))
}
def create(params = {}, opts = {}); end
# Delete a specified external account for a given account.
sig {
params(id: String, params: T.any(::Stripe::ExternalAccountService::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(T.any(Stripe::BankAccount, Stripe::Card))
}
def delete(id, params = {}, opts = {}); end
# List external accounts for an account.
sig {
params(params: T.any(::Stripe::ExternalAccountService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieve a specified external account for a given account.
sig {
params(id: String, params: T.any(::Stripe::ExternalAccountService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(T.any(Stripe::BankAccount, Stripe::Card))
}
def retrieve(id, params = {}, opts = {}); end
# Updates the metadata, account holder name, account holder type of a bank account belonging to
# a connected account and optionally sets it as the default for its currency. Other bank account
# details are not editable by design.
#
# You can only update bank accounts when [account.controller.requirement_collection is application, which includes Custom accounts](https://docs.stripe.com/api/accounts/object#account_object-controller-requirement_collection).
#
# You can re-enable a disabled bank account by performing an update call without providing any
# arguments or changes.
sig {
params(id: String, params: T.any(::Stripe::ExternalAccountService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(T.any(Stripe::BankAccount, Stripe::Card))
}
def update(id, params = {}, opts = {}); end
end
end
# typed: true
module Stripe
class V2Services < StripeService
attr_reader :core
attr_reader :money_management
attr_reader :billing
attr_reader :test_helpers
attr_reader :payments
end
end
# typed: true
module Stripe
module V2
class CoreService < StripeService
attr_reader :accounts
attr_reader :account_links
attr_reader :event_destinations
attr_reader :events
attr_reader :vault
end
end
end
# typed: true
module Stripe
module V2
module Core
class AccountService < StripeService
attr_reader :persons
class CloseParams < Stripe::RequestParams
# Configurations on the Account to be closed. All configurations on the Account must be passed in for this request to succeed.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :applied_configurations
sig { params(applied_configurations: T.nilable(T::Array[String])).void }
def initialize(applied_configurations: nil); end
end
class CreateParams < Stripe::RequestParams
class Configuration < Stripe::RequestParams
class Customer < Stripe::RequestParams
class AutomaticIndirectTax < Stripe::RequestParams
# Describes the customer's tax exemption status, which is `none`, `exempt`, or `reverse`. When set to reverse, invoice and receipt PDFs include the following text: “Reverse charge”.
sig { returns(T.nilable(String)) }
attr_accessor :exempt
# A recent IP address of the customer used for tax reporting and tax location inference.
sig { returns(T.nilable(String)) }
attr_accessor :ip_address
# The data source used to identify the customer's tax location - defaults to 'identity_address'. Will only be used for automatic tax calculation on the customer's Invoices and Subscriptions.
sig { returns(T.nilable(String)) }
attr_accessor :location_source
sig {
params(exempt: T.nilable(String), ip_address: T.nilable(String), location_source: T.nilable(String)).void
}
def initialize(exempt: nil, ip_address: nil, location_source: nil); end
end
class Billing < Stripe::RequestParams
class Invoice < Stripe::RequestParams
class CustomField < Stripe::RequestParams
# The name of the custom field. This may be up to 40 characters.
sig { returns(String) }
attr_accessor :name
# The value of the custom field. This may be up to 140 characters. When updating, pass an empty string to remove previously-defined values.
sig { returns(String) }
attr_accessor :value
sig { params(name: String, value: String).void }
def initialize(name: nil, value: nil); end
end
class Rendering < Stripe::RequestParams
# How line-item prices and amounts will be displayed with respect to tax on invoice PDFs. One of exclude_tax or include_inclusive_tax. include_inclusive_tax will include inclusive tax (and exclude exclusive tax) in invoice PDF amounts. exclude_tax will exclude all tax (inclusive and exclusive alike) from invoice PDF amounts.
sig { returns(T.nilable(String)) }
attr_accessor :amount_tax_display
# ID of the invoice rendering template to use for future invoices.
sig { returns(T.nilable(String)) }
attr_accessor :template
sig {
params(amount_tax_display: T.nilable(String), template: T.nilable(String)).void
}
def initialize(amount_tax_display: nil, template: nil); end
end
# The list of up to 4 default custom fields to be displayed on invoices for this customer.
sig {
returns(T.nilable(T::Array[::Stripe::V2::Core::AccountService::CreateParams::Configuration::Customer::Billing::Invoice::CustomField]))
}
attr_accessor :custom_fields
# Default footer to be displayed on invoices for this customer.
sig { returns(T.nilable(String)) }
attr_accessor :footer
# The sequence to be used on the customer's next invoice. Defaults to 1.
sig { returns(T.nilable(Integer)) }
attr_accessor :next_sequence
# The prefix for the customer used to generate unique invoice numbers. Must be 3–12 uppercase letters or numbers.
sig { returns(T.nilable(String)) }
attr_accessor :prefix
# Default options for invoice PDF rendering for this customer.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Customer::Billing::Invoice::Rendering))
}
attr_accessor :rendering
sig {
params(custom_fields: T.nilable(T::Array[::Stripe::V2::Core::AccountService::CreateParams::Configuration::Customer::Billing::Invoice::CustomField]), footer: T.nilable(String), next_sequence: T.nilable(Integer), prefix: T.nilable(String), rendering: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Customer::Billing::Invoice::Rendering)).void
}
def initialize(
custom_fields: nil,
footer: nil,
next_sequence: nil,
prefix: nil,
rendering: nil
); end
end
# Default settings used on invoices for this customer.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Customer::Billing::Invoice))
}
attr_accessor :invoice
sig {
params(invoice: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Customer::Billing::Invoice)).void
}
def initialize(invoice: nil); end
end
class Capabilities < Stripe::RequestParams
class AutomaticIndirectTax < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
# Generates requirements for enabling automatic indirect tax calculation on this customer's invoices or subscriptions. Recommended to request this capability if planning to enable automatic tax calculation on this customer's invoices or subscriptions. Uses the `location_source` field.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Customer::Capabilities::AutomaticIndirectTax))
}
attr_accessor :automatic_indirect_tax
sig {
params(automatic_indirect_tax: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Customer::Capabilities::AutomaticIndirectTax)).void
}
def initialize(automatic_indirect_tax: nil); end
end
class Shipping < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Customer shipping address.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Customer::Shipping::Address))
}
attr_accessor :address
# Customer name.
sig { returns(T.nilable(String)) }
attr_accessor :name
# Customer phone (including extension).
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(address: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Customer::Shipping::Address), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(address: nil, name: nil, phone: nil); end
end
# Automatic indirect tax settings to be used when automatic tax calculation is enabled on the customer's invoices, subscriptions, checkout sessions, or payment links. Surfaces if automatic tax calculation is possible given the current customer location information.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Customer::AutomaticIndirectTax))
}
attr_accessor :automatic_indirect_tax
# Billing settings - default settings used for this customer in Billing flows such as Invoices and Subscriptions.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Customer::Billing))
}
attr_accessor :billing
# Capabilities that have been requested on the Customer Configuration.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Customer::Capabilities))
}
attr_accessor :capabilities
# The customer's shipping information. Appears on invoices emailed to this customer.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Customer::Shipping))
}
attr_accessor :shipping
# ID of the test clock to attach to the customer. Can only be set on testmode Accounts, and when the Customer Configuration is first set on an Account.
sig { returns(T.nilable(String)) }
attr_accessor :test_clock
sig {
params(automatic_indirect_tax: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Customer::AutomaticIndirectTax), billing: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Customer::Billing), capabilities: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Customer::Capabilities), shipping: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Customer::Shipping), test_clock: T.nilable(String)).void
}
def initialize(
automatic_indirect_tax: nil,
billing: nil,
capabilities: nil,
shipping: nil,
test_clock: nil
); end
end
class Merchant < Stripe::RequestParams
class BacsDebitPayments < Stripe::RequestParams
# Display name for Bacs debit payments.
sig { returns(T.nilable(String)) }
attr_accessor :display_name
sig { params(display_name: T.nilable(String)).void }
def initialize(display_name: nil); end
end
class Branding < Stripe::RequestParams
# ID of a [file upload](https://docs.stripe.com/api/persons/update#create_file): An icon for the merchant. Must be square and at least 128px x 128px.
sig { returns(T.nilable(String)) }
attr_accessor :icon
# ID of a [file upload](https://docs.stripe.com/api/persons/update#create_file): A logo for the merchant that will be used in Checkout instead of the icon and without the merchant's name next to it if provided. Must be at least 128px x 128px.
sig { returns(T.nilable(String)) }
attr_accessor :logo
# A CSS hex color value representing the primary branding color for the merchant.
sig { returns(T.nilable(String)) }
attr_accessor :primary_color
# A CSS hex color value representing the secondary branding color for the merchant.
sig { returns(T.nilable(String)) }
attr_accessor :secondary_color
sig {
params(icon: T.nilable(String), logo: T.nilable(String), primary_color: T.nilable(String), secondary_color: T.nilable(String)).void
}
def initialize(icon: nil, logo: nil, primary_color: nil, secondary_color: nil); end
end
class Capabilities < Stripe::RequestParams
class AchDebitPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class AcssDebitPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class AffirmPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class AfterpayClearpayPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class AlmaPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class AmazonPayPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class AuBecsDebitPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class BacsDebitPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class BancontactPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class BlikPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class BoletoPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class CardPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class CartesBancairesPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class CashappPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class EpsPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class FpxPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class GbBankTransferPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class GrabpayPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class IdealPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class JcbPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class JpBankTransferPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class KakaoPayPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class KlarnaPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class KonbiniPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class KrCardPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class LinkPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class MobilepayPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class MultibancoPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class MxBankTransferPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class NaverPayPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class OxxoPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class P24Payments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class PayByBankPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class PaycoPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class PaynowPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class PromptpayPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class RevolutPayPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class SamsungPayPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class SepaBankTransferPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class SepaDebitPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class SwishPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class TwintPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class UsBankTransferPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class ZipPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
# Allow the merchant to process ACH debit payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::AchDebitPayments))
}
attr_accessor :ach_debit_payments
# Allow the merchant to process ACSS debit payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::AcssDebitPayments))
}
attr_accessor :acss_debit_payments
# Allow the merchant to process Affirm payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::AffirmPayments))
}
attr_accessor :affirm_payments
# Allow the merchant to process Afterpay/Clearpay payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::AfterpayClearpayPayments))
}
attr_accessor :afterpay_clearpay_payments
# Allow the merchant to process Alma payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::AlmaPayments))
}
attr_accessor :alma_payments
# Allow the merchant to process Amazon Pay payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::AmazonPayPayments))
}
attr_accessor :amazon_pay_payments
# Allow the merchant to process Australian BECS Direct Debit payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::AuBecsDebitPayments))
}
attr_accessor :au_becs_debit_payments
# Allow the merchant to process BACS Direct Debit payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::BacsDebitPayments))
}
attr_accessor :bacs_debit_payments
# Allow the merchant to process Bancontact payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::BancontactPayments))
}
attr_accessor :bancontact_payments
# Allow the merchant to process BLIK payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::BlikPayments))
}
attr_accessor :blik_payments
# Allow the merchant to process Boleto payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::BoletoPayments))
}
attr_accessor :boleto_payments
# Allow the merchant to collect card payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::CardPayments))
}
attr_accessor :card_payments
# Allow the merchant to process Cartes Bancaires payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::CartesBancairesPayments))
}
attr_accessor :cartes_bancaires_payments
# Allow the merchant to process Cash App payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::CashappPayments))
}
attr_accessor :cashapp_payments
# Allow the merchant to process EPS payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::EpsPayments))
}
attr_accessor :eps_payments
# Allow the merchant to process FPX payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::FpxPayments))
}
attr_accessor :fpx_payments
# Allow the merchant to process UK bank transfer payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::GbBankTransferPayments))
}
attr_accessor :gb_bank_transfer_payments
# Allow the merchant to process GrabPay payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::GrabpayPayments))
}
attr_accessor :grabpay_payments
# Allow the merchant to process iDEAL payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::IdealPayments))
}
attr_accessor :ideal_payments
# Allow the merchant to process JCB card payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::JcbPayments))
}
attr_accessor :jcb_payments
# Allow the merchant to process Japanese bank transfer payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::JpBankTransferPayments))
}
attr_accessor :jp_bank_transfer_payments
# Allow the merchant to process Kakao Pay payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::KakaoPayPayments))
}
attr_accessor :kakao_pay_payments
# Allow the merchant to process Klarna payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::KlarnaPayments))
}
attr_accessor :klarna_payments
# Allow the merchant to process Konbini convenience store payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::KonbiniPayments))
}
attr_accessor :konbini_payments
# Allow the merchant to process Korean card payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::KrCardPayments))
}
attr_accessor :kr_card_payments
# Allow the merchant to process Link payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::LinkPayments))
}
attr_accessor :link_payments
# Allow the merchant to process MobilePay payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::MobilepayPayments))
}
attr_accessor :mobilepay_payments
# Allow the merchant to process Multibanco payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::MultibancoPayments))
}
attr_accessor :multibanco_payments
# Allow the merchant to process Mexican bank transfer payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::MxBankTransferPayments))
}
attr_accessor :mx_bank_transfer_payments
# Allow the merchant to process Naver Pay payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::NaverPayPayments))
}
attr_accessor :naver_pay_payments
# Allow the merchant to process OXXO payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::OxxoPayments))
}
attr_accessor :oxxo_payments
# Allow the merchant to process Przelewy24 (P24) payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::P24Payments))
}
attr_accessor :p24_payments
# Allow the merchant to process Pay by Bank payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::PayByBankPayments))
}
attr_accessor :pay_by_bank_payments
# Allow the merchant to process PAYCO payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::PaycoPayments))
}
attr_accessor :payco_payments
# Allow the merchant to process PayNow payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::PaynowPayments))
}
attr_accessor :paynow_payments
# Allow the merchant to process PromptPay payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::PromptpayPayments))
}
attr_accessor :promptpay_payments
# Allow the merchant to process Revolut Pay payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::RevolutPayPayments))
}
attr_accessor :revolut_pay_payments
# Allow the merchant to process Samsung Pay payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::SamsungPayPayments))
}
attr_accessor :samsung_pay_payments
# Allow the merchant to process SEPA bank transfer payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::SepaBankTransferPayments))
}
attr_accessor :sepa_bank_transfer_payments
# Allow the merchant to process SEPA Direct Debit payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::SepaDebitPayments))
}
attr_accessor :sepa_debit_payments
# Allow the merchant to process Swish payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::SwishPayments))
}
attr_accessor :swish_payments
# Allow the merchant to process TWINT payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::TwintPayments))
}
attr_accessor :twint_payments
# Allow the merchant to process US bank transfer payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::UsBankTransferPayments))
}
attr_accessor :us_bank_transfer_payments
# Allow the merchant to process Zip payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::ZipPayments))
}
attr_accessor :zip_payments
sig {
params(ach_debit_payments: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::AchDebitPayments), acss_debit_payments: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::AcssDebitPayments), affirm_payments: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::AffirmPayments), afterpay_clearpay_payments: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::AfterpayClearpayPayments), alma_payments: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::AlmaPayments), amazon_pay_payments: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::AmazonPayPayments), au_becs_debit_payments: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::AuBecsDebitPayments), bacs_debit_payments: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::BacsDebitPayments), bancontact_payments: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::BancontactPayments), blik_payments: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::BlikPayments), boleto_payments: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::BoletoPayments), card_payments: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::CardPayments), cartes_bancaires_payments: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::CartesBancairesPayments), cashapp_payments: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::CashappPayments), eps_payments: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::EpsPayments), fpx_payments: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::FpxPayments), gb_bank_transfer_payments: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::GbBankTransferPayments), grabpay_payments: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::GrabpayPayments), ideal_payments: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::IdealPayments), jcb_payments: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::JcbPayments), jp_bank_transfer_payments: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::JpBankTransferPayments), kakao_pay_payments: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::KakaoPayPayments), klarna_payments: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::KlarnaPayments), konbini_payments: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::KonbiniPayments), kr_card_payments: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::KrCardPayments), link_payments: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::LinkPayments), mobilepay_payments: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::MobilepayPayments), multibanco_payments: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::MultibancoPayments), mx_bank_transfer_payments: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::MxBankTransferPayments), naver_pay_payments: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::NaverPayPayments), oxxo_payments: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::OxxoPayments), p24_payments: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::P24Payments), pay_by_bank_payments: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::PayByBankPayments), payco_payments: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::PaycoPayments), paynow_payments: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::PaynowPayments), promptpay_payments: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::PromptpayPayments), revolut_pay_payments: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::RevolutPayPayments), samsung_pay_payments: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::SamsungPayPayments), sepa_bank_transfer_payments: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::SepaBankTransferPayments), sepa_debit_payments: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::SepaDebitPayments), swish_payments: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::SwishPayments), twint_payments: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::TwintPayments), us_bank_transfer_payments: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::UsBankTransferPayments), zip_payments: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities::ZipPayments)).void
}
def initialize(
ach_debit_payments: nil,
acss_debit_payments: nil,
affirm_payments: nil,
afterpay_clearpay_payments: nil,
alma_payments: nil,
amazon_pay_payments: nil,
au_becs_debit_payments: nil,
bacs_debit_payments: nil,
bancontact_payments: nil,
blik_payments: nil,
boleto_payments: nil,
card_payments: nil,
cartes_bancaires_payments: nil,
cashapp_payments: nil,
eps_payments: nil,
fpx_payments: nil,
gb_bank_transfer_payments: nil,
grabpay_payments: nil,
ideal_payments: nil,
jcb_payments: nil,
jp_bank_transfer_payments: nil,
kakao_pay_payments: nil,
klarna_payments: nil,
konbini_payments: nil,
kr_card_payments: nil,
link_payments: nil,
mobilepay_payments: nil,
multibanco_payments: nil,
mx_bank_transfer_payments: nil,
naver_pay_payments: nil,
oxxo_payments: nil,
p24_payments: nil,
pay_by_bank_payments: nil,
payco_payments: nil,
paynow_payments: nil,
promptpay_payments: nil,
revolut_pay_payments: nil,
samsung_pay_payments: nil,
sepa_bank_transfer_payments: nil,
sepa_debit_payments: nil,
swish_payments: nil,
twint_payments: nil,
us_bank_transfer_payments: nil,
zip_payments: nil
); end
end
class CardPayments < Stripe::RequestParams
class DeclineOn < Stripe::RequestParams
# Whether Stripe automatically declines charges with an incorrect ZIP or postal code. This setting only applies when a ZIP or postal code is provided and they fail bank verification.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :avs_failure
# Whether Stripe automatically declines charges with an incorrect CVC. This setting only applies when a CVC is provided and it fails bank verification.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :cvc_failure
sig {
params(avs_failure: T.nilable(T::Boolean), cvc_failure: T.nilable(T::Boolean)).void
}
def initialize(avs_failure: nil, cvc_failure: nil); end
end
# Automatically declines certain charge types regardless of whether the card issuer accepted or declined the charge.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::CardPayments::DeclineOn))
}
attr_accessor :decline_on
sig {
params(decline_on: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::CardPayments::DeclineOn)).void
}
def initialize(decline_on: nil); end
end
class StatementDescriptor < Stripe::RequestParams
# The default text that appears on statements for non-card charges outside of Japan. For card charges, if you don’t set a statement_descriptor_prefix, this text is also used as the statement descriptor prefix. In that case, if concatenating the statement descriptor suffix causes the combined statement descriptor to exceed 22 characters, we truncate the statement_descriptor text to limit the full descriptor to 22 characters. For more information about statement descriptors and their requirements, see the Merchant Configuration settings documentation.
sig { returns(T.nilable(String)) }
attr_accessor :descriptor
# Default text that appears on statements for card charges outside of Japan, prefixing any dynamic statement_descriptor_suffix specified on the charge. To maximize space for the dynamic part of the descriptor, keep this text short. If you don’t specify this value, statement_descriptor is used as the prefix. For more information about statement descriptors and their requirements, see the Merchant Configuration settings documentation.
sig { returns(T.nilable(String)) }
attr_accessor :prefix
sig { params(descriptor: T.nilable(String), prefix: T.nilable(String)).void }
def initialize(descriptor: nil, prefix: nil); end
end
class Support < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(String) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_accessor :town
sig {
params(city: T.nilable(String), country: String, line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), town: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
# A publicly available mailing address for sending support issues to.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Support::Address))
}
attr_accessor :address
# A publicly available email address for sending support issues to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# A publicly available phone number to call with support issues.
sig { returns(T.nilable(String)) }
attr_accessor :phone
# A publicly available website for handling support issues.
sig { returns(T.nilable(String)) }
attr_accessor :url
sig {
params(address: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Support::Address), email: T.nilable(String), phone: T.nilable(String), url: T.nilable(String)).void
}
def initialize(address: nil, email: nil, phone: nil, url: nil); end
end
# Settings used for Bacs debit payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::BacsDebitPayments))
}
attr_accessor :bacs_debit_payments
# Settings used to apply the merchant's branding to email receipts, invoices, Checkout, and other products.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Branding))
}
attr_accessor :branding
# Capabilities to request on the Merchant Configuration.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities))
}
attr_accessor :capabilities
# Card payments settings.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::CardPayments))
}
attr_accessor :card_payments
# The merchant category code for the Merchant Configuration. MCCs are used to classify businesses based on the goods or services they provide.
sig { returns(T.nilable(String)) }
attr_accessor :mcc
# Statement descriptor.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::StatementDescriptor))
}
attr_accessor :statement_descriptor
# Publicly available contact information for sending support issues to.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Support))
}
attr_accessor :support
sig {
params(bacs_debit_payments: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::BacsDebitPayments), branding: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Branding), capabilities: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Capabilities), card_payments: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::CardPayments), mcc: T.nilable(String), statement_descriptor: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::StatementDescriptor), support: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant::Support)).void
}
def initialize(
bacs_debit_payments: nil,
branding: nil,
capabilities: nil,
card_payments: nil,
mcc: nil,
statement_descriptor: nil,
support: nil
); end
end
class Recipient < Stripe::RequestParams
class Capabilities < Stripe::RequestParams
class BankAccounts < Stripe::RequestParams
class Local < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class Wire < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
# Enables this Account to receive OutboundPayments to linked bank accounts over local networks.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Recipient::Capabilities::BankAccounts::Local))
}
attr_accessor :local
# Enables this Account to receive OutboundPayments to linked bank accounts over wire.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Recipient::Capabilities::BankAccounts::Wire))
}
attr_accessor :wire
sig {
params(local: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Recipient::Capabilities::BankAccounts::Local), wire: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Recipient::Capabilities::BankAccounts::Wire)).void
}
def initialize(local: nil, wire: nil); end
end
class Cards < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
class StripeBalance < Stripe::RequestParams
class StripeTransfers < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T::Boolean) }
attr_accessor :requested
sig { params(requested: T::Boolean).void }
def initialize(requested: nil); end
end
# Allows the account to receive /v1/transfers into their Stripe Balance (/v1/balance).
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Recipient::Capabilities::StripeBalance::StripeTransfers))
}
attr_accessor :stripe_transfers
sig {
params(stripe_transfers: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Recipient::Capabilities::StripeBalance::StripeTransfers)).void
}
def initialize(stripe_transfers: nil); end
end
# Capabilities that enable OutboundPayments to a bank account linked to this Account.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Recipient::Capabilities::BankAccounts))
}
attr_accessor :bank_accounts
# Capabilities that enable OutboundPayments to a card linked to this Account.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Recipient::Capabilities::Cards))
}
attr_accessor :cards
# Capabilities that enable the recipient to manage their Stripe Balance (/v1/balance).
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Recipient::Capabilities::StripeBalance))
}
attr_accessor :stripe_balance
sig {
params(bank_accounts: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Recipient::Capabilities::BankAccounts), cards: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Recipient::Capabilities::Cards), stripe_balance: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Recipient::Capabilities::StripeBalance)).void
}
def initialize(bank_accounts: nil, cards: nil, stripe_balance: nil); end
end
# Capabilities to be requested on the Recipient Configuration.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Recipient::Capabilities))
}
attr_accessor :capabilities
sig {
params(capabilities: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Recipient::Capabilities)).void
}
def initialize(capabilities: nil); end
end
# The Customer Configuration allows the Account to be used in inbound payment flows.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Customer))
}
attr_accessor :customer
# The Merchant configuration allows the Account to act as a connected account and collect payments facilitated by a Connect platform. You can add this configuration to your connected accounts only if you’ve completed onboarding as a Connect platform.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant))
}
attr_accessor :merchant
# The Recipient Configuration allows the Account to receive funds.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Recipient))
}
attr_accessor :recipient
sig {
params(customer: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Customer), merchant: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Merchant), recipient: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration::Recipient)).void
}
def initialize(customer: nil, merchant: nil, recipient: nil); end
end
class Defaults < Stripe::RequestParams
class Responsibilities < Stripe::RequestParams
# A value indicating the party responsible for collecting fees from this account.
sig { returns(String) }
attr_accessor :fees_collector
# A value indicating who is responsible for losses when this Account can’t pay back negative balances from payments.
sig { returns(String) }
attr_accessor :losses_collector
sig { params(fees_collector: String, losses_collector: String).void }
def initialize(fees_collector: nil, losses_collector: nil); end
end
# 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).
sig { returns(T.nilable(String)) }
attr_accessor :currency
# The Account's preferred locales (languages), ordered by preference.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :locales
# Default responsibilities held by either Stripe or the platform.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Defaults::Responsibilities))
}
attr_accessor :responsibilities
sig {
params(currency: T.nilable(String), locales: T.nilable(T::Array[String]), responsibilities: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Defaults::Responsibilities)).void
}
def initialize(currency: nil, locales: nil, responsibilities: nil); end
end
class Identity < Stripe::RequestParams
class Attestations < Stripe::RequestParams
class DirectorshipDeclaration < Stripe::RequestParams
# The time marking when the director attestation was made. Represented as a RFC 3339 date & time UTC value in millisecond precision, for example: 2022-09-18T13:22:18.123Z.
sig { returns(T.nilable(String)) }
attr_accessor :date
# The IP address from which the director attestation was made.
sig { returns(T.nilable(String)) }
attr_accessor :ip
# The user agent of the browser from which the director attestation was made.
sig { returns(T.nilable(String)) }
attr_accessor :user_agent
sig {
params(date: T.nilable(String), ip: T.nilable(String), user_agent: T.nilable(String)).void
}
def initialize(date: nil, ip: nil, user_agent: nil); end
end
class OwnershipDeclaration < Stripe::RequestParams
# The time marking when the beneficial owner attestation was made. Represented as a RFC 3339 date & time UTC value in millisecond precision, for example: 2022-09-18T13:22:18.123Z.
sig { returns(T.nilable(String)) }
attr_accessor :date
# The IP address from which the beneficial owner attestation was made.
sig { returns(T.nilable(String)) }
attr_accessor :ip
# The user agent of the browser from which the beneficial owner attestation was made.
sig { returns(T.nilable(String)) }
attr_accessor :user_agent
sig {
params(date: T.nilable(String), ip: T.nilable(String), user_agent: T.nilable(String)).void
}
def initialize(date: nil, ip: nil, user_agent: nil); end
end
class PersonsProvided < Stripe::RequestParams
# Whether the company’s directors have been provided. Set this Boolean to true after creating all the company’s directors with the [Persons API](https://docs.stripe.com/api/v2/core/accounts/createperson).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :directors
# Whether the company’s executives have been provided. Set this Boolean to true after creating all the company’s executives with the [Persons API](https://docs.stripe.com/api/v2/core/accounts/createperson).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :executives
# Whether the company’s owners have been provided. Set this Boolean to true after creating all the company’s owners with the [Persons API](https://docs.stripe.com/api/v2/core/accounts/createperson).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :owners
# Reason for why the company is exempt from providing ownership information.
sig { returns(T.nilable(String)) }
attr_accessor :ownership_exemption_reason
sig {
params(directors: T.nilable(T::Boolean), executives: T.nilable(T::Boolean), owners: T.nilable(T::Boolean), ownership_exemption_reason: T.nilable(String)).void
}
def initialize(
directors: nil,
executives: nil,
owners: nil,
ownership_exemption_reason: nil
); end
end
class TermsOfService < Stripe::RequestParams
class Account < Stripe::RequestParams
# The time when the Account's representative accepted the terms of service. Represented as a RFC 3339 date & time UTC value in millisecond precision, for example: 2022-09-18T13:22:18.123Z.
sig { returns(String) }
attr_accessor :date
# The IP address from which the Account's representative accepted the terms of service.
sig { returns(String) }
attr_accessor :ip
# The user agent of the browser from which the Account's representative accepted the terms of service.
sig { returns(T.nilable(String)) }
attr_accessor :user_agent
sig { params(date: String, ip: String, user_agent: T.nilable(String)).void }
def initialize(date: nil, ip: nil, user_agent: nil); end
end
# Details on the Account's acceptance of the [Stripe Services Agreement](https://docs.stripe.com/connect/updating-accounts#tos-acceptance).
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::Attestations::TermsOfService::Account))
}
attr_accessor :account
sig {
params(account: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::Attestations::TermsOfService::Account)).void
}
def initialize(account: nil); end
end
# This hash is used to attest that the directors information provided to Stripe is both current and correct.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::Attestations::DirectorshipDeclaration))
}
attr_accessor :directorship_declaration
# This hash is used to attest that the beneficial owner information provided to Stripe is both current and correct.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::Attestations::OwnershipDeclaration))
}
attr_accessor :ownership_declaration
# Attestation that all Persons with a specific Relationship value have been provided.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::Attestations::PersonsProvided))
}
attr_accessor :persons_provided
# Attestations of accepted terms of service agreements.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::Attestations::TermsOfService))
}
attr_accessor :terms_of_service
sig {
params(directorship_declaration: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::Attestations::DirectorshipDeclaration), ownership_declaration: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::Attestations::OwnershipDeclaration), persons_provided: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::Attestations::PersonsProvided), terms_of_service: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::Attestations::TermsOfService)).void
}
def initialize(
directorship_declaration: nil,
ownership_declaration: nil,
persons_provided: nil,
terms_of_service: nil
); end
end
class BusinessDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(String) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_accessor :town
sig {
params(city: T.nilable(String), country: String, line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), town: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
class AnnualRevenue < Stripe::RequestParams
# A non-negative integer representing the amount in the smallest currency unit.
sig { returns(T.nilable(Stripe::V2::Amount)) }
attr_accessor :amount
# The close-out date of the preceding fiscal year in ISO 8601 format. E.g. 2023-12-31 for the 31st of December, 2023.
sig { returns(T.nilable(String)) }
attr_accessor :fiscal_year_end
sig {
params(amount: T.nilable(Stripe::V2::Amount), fiscal_year_end: T.nilable(String)).void
}
def initialize(amount: nil, fiscal_year_end: nil); end
end
class Documents < Stripe::RequestParams
class BankAccountOwnershipVerification < Stripe::RequestParams
# One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`.
sig { returns(T::Array[String]) }
attr_accessor :files
# The format of the document. Currently supports `files` only.
sig { returns(String) }
attr_accessor :type
sig { params(files: T::Array[String], type: String).void }
def initialize(files: nil, type: nil); end
end
class CompanyLicense < Stripe::RequestParams
# One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`.
sig { returns(T::Array[String]) }
attr_accessor :files
# The format of the document. Currently supports `files` only.
sig { returns(String) }
attr_accessor :type
sig { params(files: T::Array[String], type: String).void }
def initialize(files: nil, type: nil); end
end
class CompanyMemorandumOfAssociation < Stripe::RequestParams
# One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`.
sig { returns(T::Array[String]) }
attr_accessor :files
# The format of the document. Currently supports `files` only.
sig { returns(String) }
attr_accessor :type
sig { params(files: T::Array[String], type: String).void }
def initialize(files: nil, type: nil); end
end
class CompanyMinisterialDecree < Stripe::RequestParams
# One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`.
sig { returns(T::Array[String]) }
attr_accessor :files
# The format of the document. Currently supports `files` only.
sig { returns(String) }
attr_accessor :type
sig { params(files: T::Array[String], type: String).void }
def initialize(files: nil, type: nil); end
end
class CompanyRegistrationVerification < Stripe::RequestParams
# One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`.
sig { returns(T::Array[String]) }
attr_accessor :files
# The format of the document. Currently supports `files` only.
sig { returns(String) }
attr_accessor :type
sig { params(files: T::Array[String], type: String).void }
def initialize(files: nil, type: nil); end
end
class CompanyTaxIdVerification < Stripe::RequestParams
# One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`.
sig { returns(T::Array[String]) }
attr_accessor :files
# The format of the document. Currently supports `files` only.
sig { returns(String) }
attr_accessor :type
sig { params(files: T::Array[String], type: String).void }
def initialize(files: nil, type: nil); end
end
class PrimaryVerification < Stripe::RequestParams
class FrontBack < Stripe::RequestParams
# A [file upload](https://docs.stripe.com/api/persons/update#create_file) token representing the back of the verification document. The purpose of the uploaded file should be 'identity_document'. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :back
# A [file upload](https://docs.stripe.com/api/persons/update#create_file) token representing the front of the verification document. The purpose of the uploaded file should be 'identity_document'. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(String) }
attr_accessor :front
sig { params(back: T.nilable(String), front: String).void }
def initialize(back: nil, front: nil); end
end
# The [file upload](https://docs.stripe.com/api/persons/update#create_file) tokens referring to each side of the document.
sig {
returns(::Stripe::V2::Core::AccountService::CreateParams::Identity::BusinessDetails::Documents::PrimaryVerification::FrontBack)
}
attr_accessor :front_back
# The format of the verification document. Currently supports `front_back` only.
sig { returns(String) }
attr_accessor :type
sig {
params(front_back: ::Stripe::V2::Core::AccountService::CreateParams::Identity::BusinessDetails::Documents::PrimaryVerification::FrontBack, type: String).void
}
def initialize(front_back: nil, type: nil); end
end
class ProofOfRegistration < Stripe::RequestParams
# One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`.
sig { returns(T::Array[String]) }
attr_accessor :files
# The format of the document. Currently supports `files` only.
sig { returns(String) }
attr_accessor :type
sig { params(files: T::Array[String], type: String).void }
def initialize(files: nil, type: nil); end
end
class ProofOfUltimateBeneficialOwnership < Stripe::RequestParams
# One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`.
sig { returns(T::Array[String]) }
attr_accessor :files
# The format of the document. Currently supports `files` only.
sig { returns(String) }
attr_accessor :type
sig { params(files: T::Array[String], type: String).void }
def initialize(files: nil, type: nil); end
end
# One or more documents that support the bank account ownership verification requirement. Must be a document associated with the account’s primary active bank account that displays the last 4 digits of the account number, either a statement or a check.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::BusinessDetails::Documents::BankAccountOwnershipVerification))
}
attr_accessor :bank_account_ownership_verification
# One or more documents that demonstrate proof of a company’s license to operate.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::BusinessDetails::Documents::CompanyLicense))
}
attr_accessor :company_license
# One or more documents showing the company’s Memorandum of Association.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::BusinessDetails::Documents::CompanyMemorandumOfAssociation))
}
attr_accessor :company_memorandum_of_association
# Certain countries only: One or more documents showing the ministerial decree legalizing the company’s establishment.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::BusinessDetails::Documents::CompanyMinisterialDecree))
}
attr_accessor :company_ministerial_decree
# One or more documents that demonstrate proof of a company’s registration with the appropriate local authorities.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::BusinessDetails::Documents::CompanyRegistrationVerification))
}
attr_accessor :company_registration_verification
# One or more documents that demonstrate proof of a company’s tax ID.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::BusinessDetails::Documents::CompanyTaxIdVerification))
}
attr_accessor :company_tax_id_verification
# A document verifying the business.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::BusinessDetails::Documents::PrimaryVerification))
}
attr_accessor :primary_verification
# One or more documents showing the company’s proof of registration with the national business registry.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::BusinessDetails::Documents::ProofOfRegistration))
}
attr_accessor :proof_of_registration
# One or more documents that demonstrate proof of ultimate beneficial ownership.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::BusinessDetails::Documents::ProofOfUltimateBeneficialOwnership))
}
attr_accessor :proof_of_ultimate_beneficial_ownership
sig {
params(bank_account_ownership_verification: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::BusinessDetails::Documents::BankAccountOwnershipVerification), company_license: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::BusinessDetails::Documents::CompanyLicense), company_memorandum_of_association: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::BusinessDetails::Documents::CompanyMemorandumOfAssociation), company_ministerial_decree: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::BusinessDetails::Documents::CompanyMinisterialDecree), company_registration_verification: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::BusinessDetails::Documents::CompanyRegistrationVerification), company_tax_id_verification: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::BusinessDetails::Documents::CompanyTaxIdVerification), primary_verification: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::BusinessDetails::Documents::PrimaryVerification), proof_of_registration: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::BusinessDetails::Documents::ProofOfRegistration), proof_of_ultimate_beneficial_ownership: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::BusinessDetails::Documents::ProofOfUltimateBeneficialOwnership)).void
}
def initialize(
bank_account_ownership_verification: nil,
company_license: nil,
company_memorandum_of_association: nil,
company_ministerial_decree: nil,
company_registration_verification: nil,
company_tax_id_verification: nil,
primary_verification: nil,
proof_of_registration: nil,
proof_of_ultimate_beneficial_ownership: nil
); end
end
class IdNumber < Stripe::RequestParams
# The registrar of the ID number (Only valid for DE ID number types).
sig { returns(T.nilable(String)) }
attr_accessor :registrar
# Open Enum. The ID number type of a business entity.
sig { returns(String) }
attr_accessor :type
# The value of the ID number.
sig { returns(String) }
attr_accessor :value
sig { params(registrar: T.nilable(String), type: String, value: String).void }
def initialize(registrar: nil, type: nil, value: nil); end
end
class MonthlyEstimatedRevenue < Stripe::RequestParams
# A non-negative integer representing the amount in the smallest currency unit.
sig { returns(T.nilable(Stripe::V2::Amount)) }
attr_accessor :amount
sig { params(amount: T.nilable(Stripe::V2::Amount)).void }
def initialize(amount: nil); end
end
class ScriptAddresses < Stripe::RequestParams
class Kana < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(String) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_accessor :town
sig {
params(city: T.nilable(String), country: String, line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), town: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
class Kanji < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(String) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_accessor :town
sig {
params(city: T.nilable(String), country: String, line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), town: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
# Kana Address.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::BusinessDetails::ScriptAddresses::Kana))
}
attr_accessor :kana
# Kanji Address.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::BusinessDetails::ScriptAddresses::Kanji))
}
attr_accessor :kanji
sig {
params(kana: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::BusinessDetails::ScriptAddresses::Kana), kanji: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::BusinessDetails::ScriptAddresses::Kanji)).void
}
def initialize(kana: nil, kanji: nil); end
end
class ScriptNames < Stripe::RequestParams
class Kana < Stripe::RequestParams
# Registered name of the business.
sig { returns(T.nilable(String)) }
attr_accessor :registered_name
sig { params(registered_name: T.nilable(String)).void }
def initialize(registered_name: nil); end
end
class Kanji < Stripe::RequestParams
# Registered name of the business.
sig { returns(T.nilable(String)) }
attr_accessor :registered_name
sig { params(registered_name: T.nilable(String)).void }
def initialize(registered_name: nil); end
end
# Kana name.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::BusinessDetails::ScriptNames::Kana))
}
attr_accessor :kana
# Kanji name.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::BusinessDetails::ScriptNames::Kanji))
}
attr_accessor :kanji
sig {
params(kana: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::BusinessDetails::ScriptNames::Kana), kanji: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::BusinessDetails::ScriptNames::Kanji)).void
}
def initialize(kana: nil, kanji: nil); end
end
# The business registration address of the business entity.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::BusinessDetails::Address))
}
attr_accessor :address
# The business gross annual revenue for its preceding fiscal year.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::BusinessDetails::AnnualRevenue))
}
attr_accessor :annual_revenue
# A document verifying the business.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::BusinessDetails::Documents))
}
attr_accessor :documents
# The name which is used by the business.
sig { returns(T.nilable(String)) }
attr_accessor :doing_business_as
# An estimated upper bound of employees, contractors, vendors, etc. currently working for the business.
sig { returns(T.nilable(Integer)) }
attr_accessor :estimated_worker_count
# The ID numbers of a business entity.
sig {
returns(T.nilable(T::Array[::Stripe::V2::Core::AccountService::CreateParams::Identity::BusinessDetails::IdNumber]))
}
attr_accessor :id_numbers
# An estimate of the monthly revenue of the business.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::BusinessDetails::MonthlyEstimatedRevenue))
}
attr_accessor :monthly_estimated_revenue
# The phone number of the Business Entity.
sig { returns(T.nilable(String)) }
attr_accessor :phone
# Internal-only description of the product sold or service provided by the business. It's used by Stripe for risk and underwriting purposes.
sig { returns(T.nilable(String)) }
attr_accessor :product_description
# The business legal name.
sig { returns(T.nilable(String)) }
attr_accessor :registered_name
# The business registration address of the business entity in non latin script.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::BusinessDetails::ScriptAddresses))
}
attr_accessor :script_addresses
# The business legal name in non latin script.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::BusinessDetails::ScriptNames))
}
attr_accessor :script_names
# The category identifying the legal structure of the business.
sig { returns(T.nilable(String)) }
attr_accessor :structure
# The business's publicly available website.
sig { returns(T.nilable(String)) }
attr_accessor :url
sig {
params(address: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::BusinessDetails::Address), annual_revenue: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::BusinessDetails::AnnualRevenue), documents: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::BusinessDetails::Documents), doing_business_as: T.nilable(String), estimated_worker_count: T.nilable(Integer), id_numbers: T.nilable(T::Array[::Stripe::V2::Core::AccountService::CreateParams::Identity::BusinessDetails::IdNumber]), monthly_estimated_revenue: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::BusinessDetails::MonthlyEstimatedRevenue), phone: T.nilable(String), product_description: T.nilable(String), registered_name: T.nilable(String), script_addresses: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::BusinessDetails::ScriptAddresses), script_names: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::BusinessDetails::ScriptNames), structure: T.nilable(String), url: T.nilable(String)).void
}
def initialize(
address: nil,
annual_revenue: nil,
documents: nil,
doing_business_as: nil,
estimated_worker_count: nil,
id_numbers: nil,
monthly_estimated_revenue: nil,
phone: nil,
product_description: nil,
registered_name: nil,
script_addresses: nil,
script_names: nil,
structure: nil,
url: nil
); end
end
class Individual < Stripe::RequestParams
class AdditionalAddress < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(String) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# Purpose of additional address.
sig { returns(String) }
attr_accessor :purpose
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_accessor :town
sig {
params(city: T.nilable(String), country: String, line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), purpose: String, state: T.nilable(String), town: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
purpose: nil,
state: nil,
town: nil
); end
end
class AdditionalName < Stripe::RequestParams
# The person's full name.
sig { returns(T.nilable(String)) }
attr_accessor :full_name
# The person's first or given name.
sig { returns(T.nilable(String)) }
attr_accessor :given_name
# The purpose or type of the additional name.
sig { returns(String) }
attr_accessor :purpose
# The person's last or family name.
sig { returns(T.nilable(String)) }
attr_accessor :surname
sig {
params(full_name: T.nilable(String), given_name: T.nilable(String), purpose: String, surname: T.nilable(String)).void
}
def initialize(full_name: nil, given_name: nil, purpose: nil, surname: nil); end
end
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(String) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_accessor :town
sig {
params(city: T.nilable(String), country: String, line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), town: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
class DateOfBirth < Stripe::RequestParams
# The day of birth.
sig { returns(Integer) }
attr_accessor :day
# The month of birth.
sig { returns(Integer) }
attr_accessor :month
# The year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
class Documents < Stripe::RequestParams
class CompanyAuthorization < Stripe::RequestParams
# One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`.
sig { returns(T::Array[String]) }
attr_accessor :files
# The format of the document. Currently supports `files` only.
sig { returns(String) }
attr_accessor :type
sig { params(files: T::Array[String], type: String).void }
def initialize(files: nil, type: nil); end
end
class Passport < Stripe::RequestParams
# One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`.
sig { returns(T::Array[String]) }
attr_accessor :files
# The format of the document. Currently supports `files` only.
sig { returns(String) }
attr_accessor :type
sig { params(files: T::Array[String], type: String).void }
def initialize(files: nil, type: nil); end
end
class PrimaryVerification < Stripe::RequestParams
class FrontBack < Stripe::RequestParams
# A [file upload](https://docs.stripe.com/api/persons/update#create_file) token representing the back of the verification document. The purpose of the uploaded file should be 'identity_document'. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :back
# A [file upload](https://docs.stripe.com/api/persons/update#create_file) token representing the front of the verification document. The purpose of the uploaded file should be 'identity_document'. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(String) }
attr_accessor :front
sig { params(back: T.nilable(String), front: String).void }
def initialize(back: nil, front: nil); end
end
# The [file upload](https://docs.stripe.com/api/persons/update#create_file) tokens referring to each side of the document.
sig {
returns(::Stripe::V2::Core::AccountService::CreateParams::Identity::Individual::Documents::PrimaryVerification::FrontBack)
}
attr_accessor :front_back
# The format of the verification document. Currently supports `front_back` only.
sig { returns(String) }
attr_accessor :type
sig {
params(front_back: ::Stripe::V2::Core::AccountService::CreateParams::Identity::Individual::Documents::PrimaryVerification::FrontBack, type: String).void
}
def initialize(front_back: nil, type: nil); end
end
class SecondaryVerification < Stripe::RequestParams
class FrontBack < Stripe::RequestParams
# A [file upload](https://docs.stripe.com/api/persons/update#create_file) token representing the back of the verification document. The purpose of the uploaded file should be 'identity_document'. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :back
# A [file upload](https://docs.stripe.com/api/persons/update#create_file) token representing the front of the verification document. The purpose of the uploaded file should be 'identity_document'. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(String) }
attr_accessor :front
sig { params(back: T.nilable(String), front: String).void }
def initialize(back: nil, front: nil); end
end
# The [file upload](https://docs.stripe.com/api/persons/update#create_file) tokens referring to each side of the document.
sig {
returns(::Stripe::V2::Core::AccountService::CreateParams::Identity::Individual::Documents::SecondaryVerification::FrontBack)
}
attr_accessor :front_back
# The format of the verification document. Currently supports `front_back` only.
sig { returns(String) }
attr_accessor :type
sig {
params(front_back: ::Stripe::V2::Core::AccountService::CreateParams::Identity::Individual::Documents::SecondaryVerification::FrontBack, type: String).void
}
def initialize(front_back: nil, type: nil); end
end
class Visa < Stripe::RequestParams
# One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`.
sig { returns(T::Array[String]) }
attr_accessor :files
# The format of the document. Currently supports `files` only.
sig { returns(String) }
attr_accessor :type
sig { params(files: T::Array[String], type: String).void }
def initialize(files: nil, type: nil); end
end
# One or more documents that demonstrate proof that this person is authorized to represent the company.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::Individual::Documents::CompanyAuthorization))
}
attr_accessor :company_authorization
# One or more documents showing the person’s passport page with photo and personal data.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::Individual::Documents::Passport))
}
attr_accessor :passport
# An identifying document showing the person's name, either a passport or local ID card.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::Individual::Documents::PrimaryVerification))
}
attr_accessor :primary_verification
# A document showing address, either a passport, local ID card, or utility bill from a well-known utility company.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::Individual::Documents::SecondaryVerification))
}
attr_accessor :secondary_verification
# One or more documents showing the person’s visa required for living in the country where they are residing.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::Individual::Documents::Visa))
}
attr_accessor :visa
sig {
params(company_authorization: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::Individual::Documents::CompanyAuthorization), passport: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::Individual::Documents::Passport), primary_verification: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::Individual::Documents::PrimaryVerification), secondary_verification: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::Individual::Documents::SecondaryVerification), visa: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::Individual::Documents::Visa)).void
}
def initialize(
company_authorization: nil,
passport: nil,
primary_verification: nil,
secondary_verification: nil,
visa: nil
); end
end
class IdNumber < Stripe::RequestParams
# The ID number type of an individual.
sig { returns(String) }
attr_accessor :type
# The value of the ID number.
sig { returns(String) }
attr_accessor :value
sig { params(type: String, value: String).void }
def initialize(type: nil, value: nil); end
end
class Relationship < Stripe::RequestParams
# Whether the person is a director of the account's identity. Directors are typically members of the governing board of the company, or responsible for ensuring the company meets its regulatory obligations.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :director
# Whether the person has significant responsibility to control, manage, or direct the organization.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :executive
# Whether the person is an owner of the account’s identity.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :owner
# The percent owned by the person of the account's legal entity.
sig { returns(T.nilable(String)) }
attr_accessor :percent_ownership
# The person's title (e.g., CEO, Support Engineer).
sig { returns(T.nilable(String)) }
attr_accessor :title
sig {
params(director: T.nilable(T::Boolean), executive: T.nilable(T::Boolean), owner: T.nilable(T::Boolean), percent_ownership: T.nilable(String), title: T.nilable(String)).void
}
def initialize(
director: nil,
executive: nil,
owner: nil,
percent_ownership: nil,
title: nil
); end
end
class ScriptAddresses < Stripe::RequestParams
class Kana < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(String) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_accessor :town
sig {
params(city: T.nilable(String), country: String, line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), town: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
class Kanji < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(String) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_accessor :town
sig {
params(city: T.nilable(String), country: String, line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), town: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
# Kana Address.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::Individual::ScriptAddresses::Kana))
}
attr_accessor :kana
# Kanji Address.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::Individual::ScriptAddresses::Kanji))
}
attr_accessor :kanji
sig {
params(kana: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::Individual::ScriptAddresses::Kana), kanji: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::Individual::ScriptAddresses::Kanji)).void
}
def initialize(kana: nil, kanji: nil); end
end
class ScriptNames < Stripe::RequestParams
class Kana < Stripe::RequestParams
# The person's first or given name.
sig { returns(T.nilable(String)) }
attr_accessor :given_name
# The person's last or family name.
sig { returns(T.nilable(String)) }
attr_accessor :surname
sig { params(given_name: T.nilable(String), surname: T.nilable(String)).void }
def initialize(given_name: nil, surname: nil); end
end
class Kanji < Stripe::RequestParams
# The person's first or given name.
sig { returns(T.nilable(String)) }
attr_accessor :given_name
# The person's last or family name.
sig { returns(T.nilable(String)) }
attr_accessor :surname
sig { params(given_name: T.nilable(String), surname: T.nilable(String)).void }
def initialize(given_name: nil, surname: nil); end
end
# Persons name in kana script.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::Individual::ScriptNames::Kana))
}
attr_accessor :kana
# Persons name in kanji script.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::Individual::ScriptNames::Kanji))
}
attr_accessor :kanji
sig {
params(kana: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::Individual::ScriptNames::Kana), kanji: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::Individual::ScriptNames::Kanji)).void
}
def initialize(kana: nil, kanji: nil); end
end
# Additional addresses associated with the individual.
sig {
returns(T.nilable(T::Array[::Stripe::V2::Core::AccountService::CreateParams::Identity::Individual::AdditionalAddress]))
}
attr_accessor :additional_addresses
# Additional names (e.g. aliases) associated with the individual.
sig {
returns(T.nilable(T::Array[::Stripe::V2::Core::AccountService::CreateParams::Identity::Individual::AdditionalName]))
}
attr_accessor :additional_names
# The individual's residential address.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::Individual::Address))
}
attr_accessor :address
# The individual's date of birth.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::Individual::DateOfBirth))
}
attr_accessor :date_of_birth
# Documents that may be submitted to satisfy various informational requests.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::Individual::Documents))
}
attr_accessor :documents
# The individual's email address.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The individual's first name.
sig { returns(T.nilable(String)) }
attr_accessor :given_name
# The identification numbers (e.g., SSN) associated with the individual.
sig {
returns(T.nilable(T::Array[::Stripe::V2::Core::AccountService::CreateParams::Identity::Individual::IdNumber]))
}
attr_accessor :id_numbers
# The individual's gender (International regulations require either "male" or "female").
sig { returns(T.nilable(String)) }
attr_accessor :legal_gender
# Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The countries where the individual is a national. Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :nationalities
# The individual's phone number.
sig { returns(T.nilable(String)) }
attr_accessor :phone
# The individual's political exposure.
sig { returns(T.nilable(String)) }
attr_accessor :political_exposure
# The relationship that this individual has with the account's identity.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::Individual::Relationship))
}
attr_accessor :relationship
# The script addresses (e.g., non-Latin characters) associated with the individual.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::Individual::ScriptAddresses))
}
attr_accessor :script_addresses
# The individuals primary name in non latin script.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::Individual::ScriptNames))
}
attr_accessor :script_names
# The individual's last name.
sig { returns(T.nilable(String)) }
attr_accessor :surname
sig {
params(additional_addresses: T.nilable(T::Array[::Stripe::V2::Core::AccountService::CreateParams::Identity::Individual::AdditionalAddress]), additional_names: T.nilable(T::Array[::Stripe::V2::Core::AccountService::CreateParams::Identity::Individual::AdditionalName]), address: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::Individual::Address), date_of_birth: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::Individual::DateOfBirth), documents: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::Individual::Documents), email: T.nilable(String), given_name: T.nilable(String), id_numbers: T.nilable(T::Array[::Stripe::V2::Core::AccountService::CreateParams::Identity::Individual::IdNumber]), legal_gender: T.nilable(String), metadata: T.nilable(T::Hash[String, String]), nationalities: T.nilable(T::Array[String]), phone: T.nilable(String), political_exposure: T.nilable(String), relationship: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::Individual::Relationship), script_addresses: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::Individual::ScriptAddresses), script_names: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::Individual::ScriptNames), surname: T.nilable(String)).void
}
def initialize(
additional_addresses: nil,
additional_names: nil,
address: nil,
date_of_birth: nil,
documents: nil,
email: nil,
given_name: nil,
id_numbers: nil,
legal_gender: nil,
metadata: nil,
nationalities: nil,
phone: nil,
political_exposure: nil,
relationship: nil,
script_addresses: nil,
script_names: nil,
surname: nil
); end
end
# Attestations from the identity's key people, e.g. owners, executives, directors.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::Attestations))
}
attr_accessor :attestations
# Information about the company or business.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::BusinessDetails))
}
attr_accessor :business_details
# The country in which the account holder resides, or in which the business is legally established. This should be an [ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2) country code.
sig { returns(T.nilable(String)) }
attr_accessor :country
# The entity type.
sig { returns(T.nilable(String)) }
attr_accessor :entity_type
# Information about the person represented by the account.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::Individual))
}
attr_accessor :individual
sig {
params(attestations: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::Attestations), business_details: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::BusinessDetails), country: T.nilable(String), entity_type: T.nilable(String), individual: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity::Individual)).void
}
def initialize(
attestations: nil,
business_details: nil,
country: nil,
entity_type: nil,
individual: nil
); end
end
# An Account Configuration which allows the Account to take on a key persona across Stripe products.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration))
}
attr_accessor :configuration
# The default contact email address for the Account. Required when configuring the account as a merchant or recipient.
sig { returns(T.nilable(String)) }
attr_accessor :contact_email
# A value indicating the Stripe dashboard this Account has access to. This will depend on which configurations are enabled for this account.
sig { returns(T.nilable(String)) }
attr_accessor :dashboard
# Default values to be used on Account Configurations.
sig { returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Defaults)) }
attr_accessor :defaults
# A descriptive name for the Account. This name will be surfaced in the Stripe Dashboard and on any invoices sent to the Account.
sig { returns(T.nilable(String)) }
attr_accessor :display_name
# Information about the company, individual, and business represented by the Account.
sig { returns(T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity)) }
attr_accessor :identity
# Additional fields to include in the response.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :include
# Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
sig {
params(configuration: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Configuration), contact_email: T.nilable(String), dashboard: T.nilable(String), defaults: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Defaults), display_name: T.nilable(String), identity: T.nilable(::Stripe::V2::Core::AccountService::CreateParams::Identity), include: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String])).void
}
def initialize(
configuration: nil,
contact_email: nil,
dashboard: nil,
defaults: nil,
display_name: nil,
identity: nil,
include: nil,
metadata: nil
); end
end
class ListParams < Stripe::RequestParams
# Filter only accounts that have all of the configurations specified. If omitted, returns all accounts regardless of which configurations they have.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :applied_configurations
# The upper limit on the number of accounts returned by the List Account request.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
sig {
params(applied_configurations: T.nilable(T::Array[String]), limit: T.nilable(Integer)).void
}
def initialize(applied_configurations: nil, limit: nil); end
end
class RetrieveParams < Stripe::RequestParams
# Additional fields to include in the response.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :include
sig { params(include: T.nilable(T::Array[String])).void }
def initialize(include: nil); end
end
class UpdateParams < Stripe::RequestParams
class Configuration < Stripe::RequestParams
class Customer < Stripe::RequestParams
class AutomaticIndirectTax < Stripe::RequestParams
# Describes the customer's tax exemption status, which is `none`, `exempt`, or `reverse`. When set to reverse, invoice and receipt PDFs include the following text: “Reverse charge”.
sig { returns(T.nilable(String)) }
attr_accessor :exempt
# A recent IP address of the customer used for tax reporting and tax location inference.
sig { returns(T.nilable(String)) }
attr_accessor :ip_address
# The data source used to identify the customer's tax location - defaults to 'identity_address'. Will only be used for automatic tax calculation on the customer's Invoices and Subscriptions.
sig { returns(T.nilable(String)) }
attr_accessor :location_source
# A per-request flag that indicates when Stripe should validate the customer tax location - defaults to 'auto'.
sig { returns(T.nilable(String)) }
attr_accessor :validate_location
sig {
params(exempt: T.nilable(String), ip_address: T.nilable(String), location_source: T.nilable(String), validate_location: T.nilable(String)).void
}
def initialize(
exempt: nil,
ip_address: nil,
location_source: nil,
validate_location: nil
); end
end
class Billing < Stripe::RequestParams
class Invoice < Stripe::RequestParams
class CustomField < Stripe::RequestParams
# The name of the custom field. This may be up to 40 characters.
sig { returns(String) }
attr_accessor :name
# The value of the custom field. This may be up to 140 characters. When updating, pass an empty string to remove previously-defined values.
sig { returns(String) }
attr_accessor :value
sig { params(name: String, value: String).void }
def initialize(name: nil, value: nil); end
end
class Rendering < Stripe::RequestParams
# How line-item prices and amounts will be displayed with respect to tax on invoice PDFs. One of exclude_tax or include_inclusive_tax. include_inclusive_tax will include inclusive tax (and exclude exclusive tax) in invoice PDF amounts. exclude_tax will exclude all tax (inclusive and exclusive alike) from invoice PDF amounts.
sig { returns(T.nilable(String)) }
attr_accessor :amount_tax_display
# ID of the invoice rendering template to use for future invoices.
sig { returns(T.nilable(String)) }
attr_accessor :template
sig {
params(amount_tax_display: T.nilable(String), template: T.nilable(String)).void
}
def initialize(amount_tax_display: nil, template: nil); end
end
# The list of up to 4 default custom fields to be displayed on invoices for this customer.
sig {
returns(T.nilable(T::Array[::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Customer::Billing::Invoice::CustomField]))
}
attr_accessor :custom_fields
# Default footer to be displayed on invoices for this customer.
sig { returns(T.nilable(String)) }
attr_accessor :footer
# The sequence to be used on the customer's next invoice. Defaults to 1.
sig { returns(T.nilable(Integer)) }
attr_accessor :next_sequence
# The prefix for the customer used to generate unique invoice numbers. Must be 3–12 uppercase letters or numbers.
sig { returns(T.nilable(String)) }
attr_accessor :prefix
# Default options for invoice PDF rendering for this customer.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Customer::Billing::Invoice::Rendering))
}
attr_accessor :rendering
sig {
params(custom_fields: T.nilable(T::Array[::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Customer::Billing::Invoice::CustomField]), footer: T.nilable(String), next_sequence: T.nilable(Integer), prefix: T.nilable(String), rendering: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Customer::Billing::Invoice::Rendering)).void
}
def initialize(
custom_fields: nil,
footer: nil,
next_sequence: nil,
prefix: nil,
rendering: nil
); end
end
# ID of a payment method that’s attached to the customer, to be used as the customer’s default payment method for invoices and subscriptions.
sig { returns(T.nilable(String)) }
attr_accessor :default_payment_method
# Default settings used on invoices for this customer.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Customer::Billing::Invoice))
}
attr_accessor :invoice
sig {
params(default_payment_method: T.nilable(String), invoice: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Customer::Billing::Invoice)).void
}
def initialize(default_payment_method: nil, invoice: nil); end
end
class Capabilities < Stripe::RequestParams
class AutomaticIndirectTax < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
# Generates requirements for enabling automatic indirect tax calculation on this customer's invoices or subscriptions. Recommended to request this capability if planning to enable automatic tax calculation on this customer's invoices or subscriptions. Uses the `location_source` field.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Customer::Capabilities::AutomaticIndirectTax))
}
attr_accessor :automatic_indirect_tax
sig {
params(automatic_indirect_tax: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Customer::Capabilities::AutomaticIndirectTax)).void
}
def initialize(automatic_indirect_tax: nil); end
end
class Shipping < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(String)) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
sig {
params(city: T.nilable(String), country: T.nilable(String), line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil
); end
end
# Customer shipping address.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Customer::Shipping::Address))
}
attr_accessor :address
# Customer name.
sig { returns(T.nilable(String)) }
attr_accessor :name
# Customer phone (including extension).
sig { returns(T.nilable(String)) }
attr_accessor :phone
sig {
params(address: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Customer::Shipping::Address), name: T.nilable(String), phone: T.nilable(String)).void
}
def initialize(address: nil, name: nil, phone: nil); end
end
# Automatic indirect tax settings to be used when automatic tax calculation is enabled on the customer's invoices, subscriptions, checkout sessions, or payment links. Surfaces if automatic tax calculation is possible given the current customer location information.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Customer::AutomaticIndirectTax))
}
attr_accessor :automatic_indirect_tax
# Billing settings - default settings used for this customer in Billing flows such as Invoices and Subscriptions.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Customer::Billing))
}
attr_accessor :billing
# Capabilities that have been requested on the Customer Configuration.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Customer::Capabilities))
}
attr_accessor :capabilities
# The customer's shipping information. Appears on invoices emailed to this customer.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Customer::Shipping))
}
attr_accessor :shipping
# ID of the test clock to attach to the customer. Can only be set on testmode Accounts, and when the Customer Configuration is first set on an Account.
sig { returns(T.nilable(String)) }
attr_accessor :test_clock
sig {
params(automatic_indirect_tax: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Customer::AutomaticIndirectTax), billing: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Customer::Billing), capabilities: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Customer::Capabilities), shipping: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Customer::Shipping), test_clock: T.nilable(String)).void
}
def initialize(
automatic_indirect_tax: nil,
billing: nil,
capabilities: nil,
shipping: nil,
test_clock: nil
); end
end
class Merchant < Stripe::RequestParams
class BacsDebitPayments < Stripe::RequestParams
# Display name for Bacs debit payments.
sig { returns(T.nilable(String)) }
attr_accessor :display_name
sig { params(display_name: T.nilable(String)).void }
def initialize(display_name: nil); end
end
class Branding < Stripe::RequestParams
# ID of a [file upload](https://docs.stripe.com/api/persons/update#create_file): An icon for the merchant. Must be square and at least 128px x 128px.
sig { returns(T.nilable(String)) }
attr_accessor :icon
# ID of a [file upload](https://docs.stripe.com/api/persons/update#create_file): A logo for the merchant that will be used in Checkout instead of the icon and without the merchant's name next to it if provided. Must be at least 128px x 128px.
sig { returns(T.nilable(String)) }
attr_accessor :logo
# A CSS hex color value representing the primary branding color for the merchant.
sig { returns(T.nilable(String)) }
attr_accessor :primary_color
# A CSS hex color value representing the secondary branding color for the merchant.
sig { returns(T.nilable(String)) }
attr_accessor :secondary_color
sig {
params(icon: T.nilable(String), logo: T.nilable(String), primary_color: T.nilable(String), secondary_color: T.nilable(String)).void
}
def initialize(icon: nil, logo: nil, primary_color: nil, secondary_color: nil); end
end
class Capabilities < Stripe::RequestParams
class AchDebitPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class AcssDebitPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class AffirmPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class AfterpayClearpayPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class AlmaPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class AmazonPayPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class AuBecsDebitPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class BacsDebitPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class BancontactPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class BlikPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class BoletoPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class CardPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class CartesBancairesPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class CashappPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class EpsPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class FpxPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class GbBankTransferPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class GrabpayPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class IdealPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class JcbPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class JpBankTransferPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class KakaoPayPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class KlarnaPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class KonbiniPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class KrCardPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class LinkPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class MobilepayPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class MultibancoPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class MxBankTransferPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class NaverPayPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class OxxoPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class P24Payments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class PayByBankPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class PaycoPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class PaynowPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class PromptpayPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class RevolutPayPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class SamsungPayPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class SepaBankTransferPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class SepaDebitPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class SwishPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class TwintPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class UsBankTransferPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class ZipPayments < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
# Allow the merchant to process ACH debit payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::AchDebitPayments))
}
attr_accessor :ach_debit_payments
# Allow the merchant to process ACSS debit payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::AcssDebitPayments))
}
attr_accessor :acss_debit_payments
# Allow the merchant to process Affirm payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::AffirmPayments))
}
attr_accessor :affirm_payments
# Allow the merchant to process Afterpay/Clearpay payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::AfterpayClearpayPayments))
}
attr_accessor :afterpay_clearpay_payments
# Allow the merchant to process Alma payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::AlmaPayments))
}
attr_accessor :alma_payments
# Allow the merchant to process Amazon Pay payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::AmazonPayPayments))
}
attr_accessor :amazon_pay_payments
# Allow the merchant to process Australian BECS Direct Debit payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::AuBecsDebitPayments))
}
attr_accessor :au_becs_debit_payments
# Allow the merchant to process BACS Direct Debit payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::BacsDebitPayments))
}
attr_accessor :bacs_debit_payments
# Allow the merchant to process Bancontact payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::BancontactPayments))
}
attr_accessor :bancontact_payments
# Allow the merchant to process BLIK payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::BlikPayments))
}
attr_accessor :blik_payments
# Allow the merchant to process Boleto payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::BoletoPayments))
}
attr_accessor :boleto_payments
# Allow the merchant to collect card payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::CardPayments))
}
attr_accessor :card_payments
# Allow the merchant to process Cartes Bancaires payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::CartesBancairesPayments))
}
attr_accessor :cartes_bancaires_payments
# Allow the merchant to process Cash App payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::CashappPayments))
}
attr_accessor :cashapp_payments
# Allow the merchant to process EPS payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::EpsPayments))
}
attr_accessor :eps_payments
# Allow the merchant to process FPX payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::FpxPayments))
}
attr_accessor :fpx_payments
# Allow the merchant to process UK bank transfer payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::GbBankTransferPayments))
}
attr_accessor :gb_bank_transfer_payments
# Allow the merchant to process GrabPay payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::GrabpayPayments))
}
attr_accessor :grabpay_payments
# Allow the merchant to process iDEAL payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::IdealPayments))
}
attr_accessor :ideal_payments
# Allow the merchant to process JCB card payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::JcbPayments))
}
attr_accessor :jcb_payments
# Allow the merchant to process Japanese bank transfer payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::JpBankTransferPayments))
}
attr_accessor :jp_bank_transfer_payments
# Allow the merchant to process Kakao Pay payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::KakaoPayPayments))
}
attr_accessor :kakao_pay_payments
# Allow the merchant to process Klarna payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::KlarnaPayments))
}
attr_accessor :klarna_payments
# Allow the merchant to process Konbini convenience store payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::KonbiniPayments))
}
attr_accessor :konbini_payments
# Allow the merchant to process Korean card payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::KrCardPayments))
}
attr_accessor :kr_card_payments
# Allow the merchant to process Link payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::LinkPayments))
}
attr_accessor :link_payments
# Allow the merchant to process MobilePay payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::MobilepayPayments))
}
attr_accessor :mobilepay_payments
# Allow the merchant to process Multibanco payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::MultibancoPayments))
}
attr_accessor :multibanco_payments
# Allow the merchant to process Mexican bank transfer payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::MxBankTransferPayments))
}
attr_accessor :mx_bank_transfer_payments
# Allow the merchant to process Naver Pay payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::NaverPayPayments))
}
attr_accessor :naver_pay_payments
# Allow the merchant to process OXXO payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::OxxoPayments))
}
attr_accessor :oxxo_payments
# Allow the merchant to process Przelewy24 (P24) payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::P24Payments))
}
attr_accessor :p24_payments
# Allow the merchant to process Pay by Bank payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::PayByBankPayments))
}
attr_accessor :pay_by_bank_payments
# Allow the merchant to process PAYCO payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::PaycoPayments))
}
attr_accessor :payco_payments
# Allow the merchant to process PayNow payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::PaynowPayments))
}
attr_accessor :paynow_payments
# Allow the merchant to process PromptPay payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::PromptpayPayments))
}
attr_accessor :promptpay_payments
# Allow the merchant to process Revolut Pay payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::RevolutPayPayments))
}
attr_accessor :revolut_pay_payments
# Allow the merchant to process Samsung Pay payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::SamsungPayPayments))
}
attr_accessor :samsung_pay_payments
# Allow the merchant to process SEPA bank transfer payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::SepaBankTransferPayments))
}
attr_accessor :sepa_bank_transfer_payments
# Allow the merchant to process SEPA Direct Debit payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::SepaDebitPayments))
}
attr_accessor :sepa_debit_payments
# Allow the merchant to process Swish payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::SwishPayments))
}
attr_accessor :swish_payments
# Allow the merchant to process TWINT payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::TwintPayments))
}
attr_accessor :twint_payments
# Allow the merchant to process US bank transfer payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::UsBankTransferPayments))
}
attr_accessor :us_bank_transfer_payments
# Allow the merchant to process Zip payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::ZipPayments))
}
attr_accessor :zip_payments
sig {
params(ach_debit_payments: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::AchDebitPayments), acss_debit_payments: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::AcssDebitPayments), affirm_payments: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::AffirmPayments), afterpay_clearpay_payments: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::AfterpayClearpayPayments), alma_payments: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::AlmaPayments), amazon_pay_payments: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::AmazonPayPayments), au_becs_debit_payments: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::AuBecsDebitPayments), bacs_debit_payments: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::BacsDebitPayments), bancontact_payments: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::BancontactPayments), blik_payments: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::BlikPayments), boleto_payments: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::BoletoPayments), card_payments: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::CardPayments), cartes_bancaires_payments: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::CartesBancairesPayments), cashapp_payments: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::CashappPayments), eps_payments: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::EpsPayments), fpx_payments: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::FpxPayments), gb_bank_transfer_payments: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::GbBankTransferPayments), grabpay_payments: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::GrabpayPayments), ideal_payments: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::IdealPayments), jcb_payments: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::JcbPayments), jp_bank_transfer_payments: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::JpBankTransferPayments), kakao_pay_payments: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::KakaoPayPayments), klarna_payments: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::KlarnaPayments), konbini_payments: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::KonbiniPayments), kr_card_payments: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::KrCardPayments), link_payments: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::LinkPayments), mobilepay_payments: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::MobilepayPayments), multibanco_payments: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::MultibancoPayments), mx_bank_transfer_payments: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::MxBankTransferPayments), naver_pay_payments: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::NaverPayPayments), oxxo_payments: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::OxxoPayments), p24_payments: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::P24Payments), pay_by_bank_payments: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::PayByBankPayments), payco_payments: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::PaycoPayments), paynow_payments: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::PaynowPayments), promptpay_payments: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::PromptpayPayments), revolut_pay_payments: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::RevolutPayPayments), samsung_pay_payments: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::SamsungPayPayments), sepa_bank_transfer_payments: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::SepaBankTransferPayments), sepa_debit_payments: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::SepaDebitPayments), swish_payments: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::SwishPayments), twint_payments: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::TwintPayments), us_bank_transfer_payments: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::UsBankTransferPayments), zip_payments: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities::ZipPayments)).void
}
def initialize(
ach_debit_payments: nil,
acss_debit_payments: nil,
affirm_payments: nil,
afterpay_clearpay_payments: nil,
alma_payments: nil,
amazon_pay_payments: nil,
au_becs_debit_payments: nil,
bacs_debit_payments: nil,
bancontact_payments: nil,
blik_payments: nil,
boleto_payments: nil,
card_payments: nil,
cartes_bancaires_payments: nil,
cashapp_payments: nil,
eps_payments: nil,
fpx_payments: nil,
gb_bank_transfer_payments: nil,
grabpay_payments: nil,
ideal_payments: nil,
jcb_payments: nil,
jp_bank_transfer_payments: nil,
kakao_pay_payments: nil,
klarna_payments: nil,
konbini_payments: nil,
kr_card_payments: nil,
link_payments: nil,
mobilepay_payments: nil,
multibanco_payments: nil,
mx_bank_transfer_payments: nil,
naver_pay_payments: nil,
oxxo_payments: nil,
p24_payments: nil,
pay_by_bank_payments: nil,
payco_payments: nil,
paynow_payments: nil,
promptpay_payments: nil,
revolut_pay_payments: nil,
samsung_pay_payments: nil,
sepa_bank_transfer_payments: nil,
sepa_debit_payments: nil,
swish_payments: nil,
twint_payments: nil,
us_bank_transfer_payments: nil,
zip_payments: nil
); end
end
class CardPayments < Stripe::RequestParams
class DeclineOn < Stripe::RequestParams
# Whether Stripe automatically declines charges with an incorrect ZIP or postal code. This setting only applies when a ZIP or postal code is provided and they fail bank verification.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :avs_failure
# Whether Stripe automatically declines charges with an incorrect CVC. This setting only applies when a CVC is provided and it fails bank verification.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :cvc_failure
sig {
params(avs_failure: T.nilable(T::Boolean), cvc_failure: T.nilable(T::Boolean)).void
}
def initialize(avs_failure: nil, cvc_failure: nil); end
end
# Automatically declines certain charge types regardless of whether the card issuer accepted or declined the charge.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::CardPayments::DeclineOn))
}
attr_accessor :decline_on
sig {
params(decline_on: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::CardPayments::DeclineOn)).void
}
def initialize(decline_on: nil); end
end
class StatementDescriptor < Stripe::RequestParams
# The default text that appears on statements for non-card charges outside of Japan. For card charges, if you don’t set a statement_descriptor_prefix, this text is also used as the statement descriptor prefix. In that case, if concatenating the statement descriptor suffix causes the combined statement descriptor to exceed 22 characters, we truncate the statement_descriptor text to limit the full descriptor to 22 characters. For more information about statement descriptors and their requirements, see the Merchant Configuration settings documentation.
sig { returns(T.nilable(String)) }
attr_accessor :descriptor
# Default text that appears on statements for card charges outside of Japan, prefixing any dynamic statement_descriptor_suffix specified on the charge. To maximize space for the dynamic part of the descriptor, keep this text short. If you don’t specify this value, statement_descriptor is used as the prefix. For more information about statement descriptors and their requirements, see the Merchant Configuration settings documentation.
sig { returns(T.nilable(String)) }
attr_accessor :prefix
sig { params(descriptor: T.nilable(String), prefix: T.nilable(String)).void }
def initialize(descriptor: nil, prefix: nil); end
end
class Support < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :town
sig {
params(city: T.nilable(T.nilable(String)), country: T.nilable(T.nilable(String)), line1: T.nilable(T.nilable(String)), line2: T.nilable(T.nilable(String)), postal_code: T.nilable(T.nilable(String)), state: T.nilable(T.nilable(String)), town: T.nilable(T.nilable(String))).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
# A publicly available mailing address for sending support issues to.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Support::Address))
}
attr_accessor :address
# A publicly available email address for sending support issues to.
sig { returns(T.nilable(String)) }
attr_accessor :email
# A publicly available phone number to call with support issues.
sig { returns(T.nilable(String)) }
attr_accessor :phone
# A publicly available website for handling support issues.
sig { returns(T.nilable(String)) }
attr_accessor :url
sig {
params(address: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Support::Address), email: T.nilable(String), phone: T.nilable(String), url: T.nilable(String)).void
}
def initialize(address: nil, email: nil, phone: nil, url: nil); end
end
# Settings used for Bacs debit payments.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::BacsDebitPayments))
}
attr_accessor :bacs_debit_payments
# Settings used to apply the merchant's branding to email receipts, invoices, Checkout, and other products.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Branding))
}
attr_accessor :branding
# Capabilities to request on the Merchant Configuration.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities))
}
attr_accessor :capabilities
# Card payments settings.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::CardPayments))
}
attr_accessor :card_payments
# The merchant category code for the merchant. MCCs are used to classify businesses based on the goods or services they provide.
sig { returns(T.nilable(String)) }
attr_accessor :mcc
# Statement descriptor.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::StatementDescriptor))
}
attr_accessor :statement_descriptor
# Publicly available contact information for sending support issues to.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Support))
}
attr_accessor :support
sig {
params(bacs_debit_payments: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::BacsDebitPayments), branding: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Branding), capabilities: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Capabilities), card_payments: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::CardPayments), mcc: T.nilable(String), statement_descriptor: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::StatementDescriptor), support: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant::Support)).void
}
def initialize(
bacs_debit_payments: nil,
branding: nil,
capabilities: nil,
card_payments: nil,
mcc: nil,
statement_descriptor: nil,
support: nil
); end
end
class Recipient < Stripe::RequestParams
class Capabilities < Stripe::RequestParams
class BankAccounts < Stripe::RequestParams
class Local < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class Wire < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
# Enables this Account to receive OutboundPayments to linked bank accounts over local networks.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Recipient::Capabilities::BankAccounts::Local))
}
attr_accessor :local
# Enables this Account to receive OutboundPayments to linked bank accounts over wire.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Recipient::Capabilities::BankAccounts::Wire))
}
attr_accessor :wire
sig {
params(local: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Recipient::Capabilities::BankAccounts::Local), wire: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Recipient::Capabilities::BankAccounts::Wire)).void
}
def initialize(local: nil, wire: nil); end
end
class Cards < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
class StripeBalance < Stripe::RequestParams
class StripeTransfers < Stripe::RequestParams
# To request a new Capability for an account, pass true. There can be a delay before the requested Capability becomes active.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :requested
sig { params(requested: T.nilable(T::Boolean)).void }
def initialize(requested: nil); end
end
# Allows the account to receive /v1/transfers into their Stripe Balance (/v1/balance).
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Recipient::Capabilities::StripeBalance::StripeTransfers))
}
attr_accessor :stripe_transfers
sig {
params(stripe_transfers: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Recipient::Capabilities::StripeBalance::StripeTransfers)).void
}
def initialize(stripe_transfers: nil); end
end
# Capabilities that enable OutboundPayments to a bank account linked to this Account.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Recipient::Capabilities::BankAccounts))
}
attr_accessor :bank_accounts
# Capability that enable OutboundPayments to a debit card linked to this Account.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Recipient::Capabilities::Cards))
}
attr_accessor :cards
# Capabilities that enable the recipient to manage their Stripe Balance (/v1/balance).
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Recipient::Capabilities::StripeBalance))
}
attr_accessor :stripe_balance
sig {
params(bank_accounts: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Recipient::Capabilities::BankAccounts), cards: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Recipient::Capabilities::Cards), stripe_balance: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Recipient::Capabilities::StripeBalance)).void
}
def initialize(bank_accounts: nil, cards: nil, stripe_balance: nil); end
end
# Capabilities to request on the Recipient Configuration.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Recipient::Capabilities))
}
attr_accessor :capabilities
# The payout method id to be used as a default outbound destination. This will allow the PayoutMethod to be omitted on OutboundPayments made through API or sending payouts via dashboard. Can also be explicitly set to `null` to clear the existing default outbound destination.
sig { returns(T.nilable(String)) }
attr_accessor :default_outbound_destination
sig {
params(capabilities: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Recipient::Capabilities), default_outbound_destination: T.nilable(String)).void
}
def initialize(capabilities: nil, default_outbound_destination: nil); end
end
# The Customer Configuration allows the Account to be charged.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Customer))
}
attr_accessor :customer
# The Merchant configuration allows the Account to act as a connected account and collect payments facilitated by a Connect platform. You can add this configuration to your connected accounts only if you’ve completed onboarding as a Connect platform.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant))
}
attr_accessor :merchant
# The Recipient Configuration allows the Account to receive funds.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Recipient))
}
attr_accessor :recipient
sig {
params(customer: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Customer), merchant: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Merchant), recipient: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration::Recipient)).void
}
def initialize(customer: nil, merchant: nil, recipient: nil); end
end
class Defaults < Stripe::RequestParams
class Responsibilities < Stripe::RequestParams
# A value indicating the party responsible for collecting fees from this account.
sig { returns(String) }
attr_accessor :fees_collector
# A value indicating who is responsible for losses when this Account can’t pay back negative balances from payments.
sig { returns(String) }
attr_accessor :losses_collector
sig { params(fees_collector: String, losses_collector: String).void }
def initialize(fees_collector: nil, losses_collector: nil); end
end
# 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).
sig { returns(T.nilable(String)) }
attr_accessor :currency
# The Account's preferred locales (languages), ordered by preference.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :locales
# Default responsibilities held by either Stripe or the platform.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Defaults::Responsibilities))
}
attr_accessor :responsibilities
sig {
params(currency: T.nilable(String), locales: T.nilable(T::Array[String]), responsibilities: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Defaults::Responsibilities)).void
}
def initialize(currency: nil, locales: nil, responsibilities: nil); end
end
class Identity < Stripe::RequestParams
class Attestations < Stripe::RequestParams
class DirectorshipDeclaration < Stripe::RequestParams
# The time marking when the director attestation was made. Represented as a RFC 3339 date & time UTC value in millisecond precision, for example: 2022-09-18T13:22:18.123Z.
sig { returns(T.nilable(String)) }
attr_accessor :date
# The IP address from which the director attestation was made.
sig { returns(T.nilable(String)) }
attr_accessor :ip
# The user agent of the browser from which the director attestation was made.
sig { returns(T.nilable(String)) }
attr_accessor :user_agent
sig {
params(date: T.nilable(String), ip: T.nilable(String), user_agent: T.nilable(String)).void
}
def initialize(date: nil, ip: nil, user_agent: nil); end
end
class OwnershipDeclaration < Stripe::RequestParams
# The time marking when the beneficial owner attestation was made. Represented as a RFC 3339 date & time UTC value in millisecond precision, for example: 2022-09-18T13:22:18.123Z.
sig { returns(T.nilable(String)) }
attr_accessor :date
# The IP address from which the beneficial owner attestation was made.
sig { returns(T.nilable(String)) }
attr_accessor :ip
# The user agent of the browser from which the beneficial owner attestation was made.
sig { returns(T.nilable(String)) }
attr_accessor :user_agent
sig {
params(date: T.nilable(String), ip: T.nilable(String), user_agent: T.nilable(String)).void
}
def initialize(date: nil, ip: nil, user_agent: nil); end
end
class PersonsProvided < Stripe::RequestParams
# Whether the company’s directors have been provided. Set this Boolean to true after creating all the company’s directors with the [Persons API](https://docs.stripe.com/api/v2/core/accounts/createperson).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :directors
# Whether the company’s executives have been provided. Set this Boolean to true after creating all the company’s executives with the [Persons API](https://docs.stripe.com/api/v2/core/accounts/createperson).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :executives
# Whether the company’s owners have been provided. Set this Boolean to true after creating all the company’s owners with the [Persons API](https://docs.stripe.com/api/v2/core/accounts/createperson).
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :owners
# Reason for why the company is exempt from providing ownership information.
sig { returns(T.nilable(String)) }
attr_accessor :ownership_exemption_reason
sig {
params(directors: T.nilable(T::Boolean), executives: T.nilable(T::Boolean), owners: T.nilable(T::Boolean), ownership_exemption_reason: T.nilable(String)).void
}
def initialize(
directors: nil,
executives: nil,
owners: nil,
ownership_exemption_reason: nil
); end
end
class TermsOfService < Stripe::RequestParams
class Account < Stripe::RequestParams
# The time when the Account's representative accepted the terms of service. Represented as a RFC 3339 date & time UTC value in millisecond precision, for example: 2022-09-18T13:22:18.123Z.
sig { returns(T.nilable(String)) }
attr_accessor :date
# The IP address from which the Account's representative accepted the terms of service.
sig { returns(T.nilable(String)) }
attr_accessor :ip
# The user agent of the browser from which the Account's representative accepted the terms of service.
sig { returns(T.nilable(String)) }
attr_accessor :user_agent
sig {
params(date: T.nilable(String), ip: T.nilable(String), user_agent: T.nilable(String)).void
}
def initialize(date: nil, ip: nil, user_agent: nil); end
end
# Details on the Account's acceptance of the [Stripe Services Agreement](https://docs.stripe.com/connect/updating-accounts#tos-acceptance).
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::Attestations::TermsOfService::Account))
}
attr_accessor :account
sig {
params(account: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::Attestations::TermsOfService::Account)).void
}
def initialize(account: nil); end
end
# This hash is used to attest that the directors information provided to Stripe is both current and correct.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::Attestations::DirectorshipDeclaration))
}
attr_accessor :directorship_declaration
# This hash is used to attest that the beneficial owner information provided to Stripe is both current and correct.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::Attestations::OwnershipDeclaration))
}
attr_accessor :ownership_declaration
# Attestation that all Persons with a specific Relationship value have been provided.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::Attestations::PersonsProvided))
}
attr_accessor :persons_provided
# Attestations of accepted terms of service agreements.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::Attestations::TermsOfService))
}
attr_accessor :terms_of_service
sig {
params(directorship_declaration: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::Attestations::DirectorshipDeclaration), ownership_declaration: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::Attestations::OwnershipDeclaration), persons_provided: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::Attestations::PersonsProvided), terms_of_service: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::Attestations::TermsOfService)).void
}
def initialize(
directorship_declaration: nil,
ownership_declaration: nil,
persons_provided: nil,
terms_of_service: nil
); end
end
class BusinessDetails < Stripe::RequestParams
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :town
sig {
params(city: T.nilable(T.nilable(String)), country: T.nilable(T.nilable(String)), line1: T.nilable(T.nilable(String)), line2: T.nilable(T.nilable(String)), postal_code: T.nilable(T.nilable(String)), state: T.nilable(T.nilable(String)), town: T.nilable(T.nilable(String))).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
class AnnualRevenue < Stripe::RequestParams
# A non-negative integer representing the amount in the smallest currency unit.
sig { returns(T.nilable(Stripe::V2::Amount)) }
attr_accessor :amount
# The close-out date of the preceding fiscal year in ISO 8601 format. E.g. 2023-12-31 for the 31st of December, 2023.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :fiscal_year_end
sig {
params(amount: T.nilable(Stripe::V2::Amount), fiscal_year_end: T.nilable(T.nilable(String))).void
}
def initialize(amount: nil, fiscal_year_end: nil); end
end
class Documents < Stripe::RequestParams
class BankAccountOwnershipVerification < Stripe::RequestParams
# One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`.
sig { returns(T::Array[String]) }
attr_accessor :files
# The format of the document. Currently supports `files` only.
sig { returns(String) }
attr_accessor :type
sig { params(files: T::Array[String], type: String).void }
def initialize(files: nil, type: nil); end
end
class CompanyLicense < Stripe::RequestParams
# One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`.
sig { returns(T::Array[String]) }
attr_accessor :files
# The format of the document. Currently supports `files` only.
sig { returns(String) }
attr_accessor :type
sig { params(files: T::Array[String], type: String).void }
def initialize(files: nil, type: nil); end
end
class CompanyMemorandumOfAssociation < Stripe::RequestParams
# One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`.
sig { returns(T::Array[String]) }
attr_accessor :files
# The format of the document. Currently supports `files` only.
sig { returns(String) }
attr_accessor :type
sig { params(files: T::Array[String], type: String).void }
def initialize(files: nil, type: nil); end
end
class CompanyMinisterialDecree < Stripe::RequestParams
# One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`.
sig { returns(T::Array[String]) }
attr_accessor :files
# The format of the document. Currently supports `files` only.
sig { returns(String) }
attr_accessor :type
sig { params(files: T::Array[String], type: String).void }
def initialize(files: nil, type: nil); end
end
class CompanyRegistrationVerification < Stripe::RequestParams
# One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`.
sig { returns(T::Array[String]) }
attr_accessor :files
# The format of the document. Currently supports `files` only.
sig { returns(String) }
attr_accessor :type
sig { params(files: T::Array[String], type: String).void }
def initialize(files: nil, type: nil); end
end
class CompanyTaxIdVerification < Stripe::RequestParams
# One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`.
sig { returns(T::Array[String]) }
attr_accessor :files
# The format of the document. Currently supports `files` only.
sig { returns(String) }
attr_accessor :type
sig { params(files: T::Array[String], type: String).void }
def initialize(files: nil, type: nil); end
end
class PrimaryVerification < Stripe::RequestParams
class FrontBack < Stripe::RequestParams
# A [file upload](https://docs.stripe.com/api/persons/update#create_file) token representing the back of the verification document. The purpose of the uploaded file should be 'identity_document'. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :back
# A [file upload](https://docs.stripe.com/api/persons/update#create_file) token representing the front of the verification document. The purpose of the uploaded file should be 'identity_document'. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :front
sig {
params(back: T.nilable(T.nilable(String)), front: T.nilable(String)).void
}
def initialize(back: nil, front: nil); end
end
# The [file upload](https://docs.stripe.com/api/persons/update#create_file) tokens referring to each side of the document.
sig {
returns(::Stripe::V2::Core::AccountService::UpdateParams::Identity::BusinessDetails::Documents::PrimaryVerification::FrontBack)
}
attr_accessor :front_back
# The format of the verification document. Currently supports `front_back` only.
sig { returns(String) }
attr_accessor :type
sig {
params(front_back: ::Stripe::V2::Core::AccountService::UpdateParams::Identity::BusinessDetails::Documents::PrimaryVerification::FrontBack, type: String).void
}
def initialize(front_back: nil, type: nil); end
end
class ProofOfRegistration < Stripe::RequestParams
# One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`.
sig { returns(T::Array[String]) }
attr_accessor :files
# The format of the document. Currently supports `files` only.
sig { returns(String) }
attr_accessor :type
sig { params(files: T::Array[String], type: String).void }
def initialize(files: nil, type: nil); end
end
class ProofOfUltimateBeneficialOwnership < Stripe::RequestParams
# One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`.
sig { returns(T::Array[String]) }
attr_accessor :files
# The format of the document. Currently supports `files` only.
sig { returns(String) }
attr_accessor :type
sig { params(files: T::Array[String], type: String).void }
def initialize(files: nil, type: nil); end
end
# One or more documents that support the bank account ownership verification requirement. Must be a document associated with the account’s primary active bank account that displays the last 4 digits of the account number, either a statement or a check.
sig {
returns(T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::BusinessDetails::Documents::BankAccountOwnershipVerification)))
}
attr_accessor :bank_account_ownership_verification
# One or more documents that demonstrate proof of a company’s license to operate.
sig {
returns(T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::BusinessDetails::Documents::CompanyLicense)))
}
attr_accessor :company_license
# One or more documents showing the company’s Memorandum of Association.
sig {
returns(T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::BusinessDetails::Documents::CompanyMemorandumOfAssociation)))
}
attr_accessor :company_memorandum_of_association
# Certain countries only: One or more documents showing the ministerial decree legalizing the company’s establishment.
sig {
returns(T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::BusinessDetails::Documents::CompanyMinisterialDecree)))
}
attr_accessor :company_ministerial_decree
# One or more documents that demonstrate proof of a company’s registration with the appropriate local authorities.
sig {
returns(T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::BusinessDetails::Documents::CompanyRegistrationVerification)))
}
attr_accessor :company_registration_verification
# One or more documents that demonstrate proof of a company’s tax ID.
sig {
returns(T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::BusinessDetails::Documents::CompanyTaxIdVerification)))
}
attr_accessor :company_tax_id_verification
# A document verifying the business.
sig {
returns(T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::BusinessDetails::Documents::PrimaryVerification)))
}
attr_accessor :primary_verification
# One or more documents showing the company’s proof of registration with the national business registry.
sig {
returns(T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::BusinessDetails::Documents::ProofOfRegistration)))
}
attr_accessor :proof_of_registration
# One or more documents that demonstrate proof of ultimate beneficial ownership.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::BusinessDetails::Documents::ProofOfUltimateBeneficialOwnership))
}
attr_accessor :proof_of_ultimate_beneficial_ownership
sig {
params(bank_account_ownership_verification: T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::BusinessDetails::Documents::BankAccountOwnershipVerification)), company_license: T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::BusinessDetails::Documents::CompanyLicense)), company_memorandum_of_association: T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::BusinessDetails::Documents::CompanyMemorandumOfAssociation)), company_ministerial_decree: T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::BusinessDetails::Documents::CompanyMinisterialDecree)), company_registration_verification: T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::BusinessDetails::Documents::CompanyRegistrationVerification)), company_tax_id_verification: T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::BusinessDetails::Documents::CompanyTaxIdVerification)), primary_verification: T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::BusinessDetails::Documents::PrimaryVerification)), proof_of_registration: T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::BusinessDetails::Documents::ProofOfRegistration)), proof_of_ultimate_beneficial_ownership: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::BusinessDetails::Documents::ProofOfUltimateBeneficialOwnership)).void
}
def initialize(
bank_account_ownership_verification: nil,
company_license: nil,
company_memorandum_of_association: nil,
company_ministerial_decree: nil,
company_registration_verification: nil,
company_tax_id_verification: nil,
primary_verification: nil,
proof_of_registration: nil,
proof_of_ultimate_beneficial_ownership: nil
); end
end
class IdNumber < Stripe::RequestParams
# The registrar of the ID number (Only valid for DE ID number types).
sig { returns(T.nilable(String)) }
attr_accessor :registrar
# Open Enum. The ID number type of a business entity.
sig { returns(String) }
attr_accessor :type
# The value of the ID number.
sig { returns(String) }
attr_accessor :value
sig { params(registrar: T.nilable(String), type: String, value: String).void }
def initialize(registrar: nil, type: nil, value: nil); end
end
class MonthlyEstimatedRevenue < Stripe::RequestParams
# A non-negative integer representing the amount in the smallest currency unit.
sig { returns(T.nilable(Stripe::V2::Amount)) }
attr_accessor :amount
sig { params(amount: T.nilable(Stripe::V2::Amount)).void }
def initialize(amount: nil); end
end
class ScriptAddresses < Stripe::RequestParams
class Kana < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :town
sig {
params(city: T.nilable(T.nilable(String)), country: T.nilable(T.nilable(String)), line1: T.nilable(T.nilable(String)), line2: T.nilable(T.nilable(String)), postal_code: T.nilable(T.nilable(String)), state: T.nilable(T.nilable(String)), town: T.nilable(T.nilable(String))).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
class Kanji < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :town
sig {
params(city: T.nilable(T.nilable(String)), country: T.nilable(T.nilable(String)), line1: T.nilable(T.nilable(String)), line2: T.nilable(T.nilable(String)), postal_code: T.nilable(T.nilable(String)), state: T.nilable(T.nilable(String)), town: T.nilable(T.nilable(String))).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
# Kana Address.
sig {
returns(T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::BusinessDetails::ScriptAddresses::Kana)))
}
attr_accessor :kana
# Kanji Address.
sig {
returns(T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::BusinessDetails::ScriptAddresses::Kanji)))
}
attr_accessor :kanji
sig {
params(kana: T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::BusinessDetails::ScriptAddresses::Kana)), kanji: T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::BusinessDetails::ScriptAddresses::Kanji))).void
}
def initialize(kana: nil, kanji: nil); end
end
class ScriptNames < Stripe::RequestParams
class Kana < Stripe::RequestParams
# Registered name of the business.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :registered_name
sig { params(registered_name: T.nilable(T.nilable(String))).void }
def initialize(registered_name: nil); end
end
class Kanji < Stripe::RequestParams
# Registered name of the business.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :registered_name
sig { params(registered_name: T.nilable(T.nilable(String))).void }
def initialize(registered_name: nil); end
end
# Kana name.
sig {
returns(T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::BusinessDetails::ScriptNames::Kana)))
}
attr_accessor :kana
# Kanji name.
sig {
returns(T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::BusinessDetails::ScriptNames::Kanji)))
}
attr_accessor :kanji
sig {
params(kana: T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::BusinessDetails::ScriptNames::Kana)), kanji: T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::BusinessDetails::ScriptNames::Kanji))).void
}
def initialize(kana: nil, kanji: nil); end
end
# The business registration address of the business entity.
sig {
returns(T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::BusinessDetails::Address)))
}
attr_accessor :address
# The business gross annual revenue for its preceding fiscal year.
sig {
returns(T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::BusinessDetails::AnnualRevenue)))
}
attr_accessor :annual_revenue
# A document verifying the business.
sig {
returns(T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::BusinessDetails::Documents)))
}
attr_accessor :documents
# The name which is used by the business.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :doing_business_as
# An estimated upper bound of employees, contractors, vendors, etc. currently working for the business.
sig { returns(T.nilable(T.nilable(Integer))) }
attr_accessor :estimated_worker_count
# The ID numbers of a business entity.
sig {
returns(T.nilable(T.nilable(T::Array[::Stripe::V2::Core::AccountService::UpdateParams::Identity::BusinessDetails::IdNumber])))
}
attr_accessor :id_numbers
# An estimate of the monthly revenue of the business.
sig {
returns(T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::BusinessDetails::MonthlyEstimatedRevenue)))
}
attr_accessor :monthly_estimated_revenue
# The phone number of the Business Entity.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :phone
# Internal-only description of the product sold or service provided by the business. It’s used by Stripe for risk and underwriting purposes.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :product_description
# The business legal name.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :registered_name
# The business registration address of the business entity in non latin script.
sig {
returns(T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::BusinessDetails::ScriptAddresses)))
}
attr_accessor :script_addresses
# The business legal name in non latin script.
sig {
returns(T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::BusinessDetails::ScriptNames)))
}
attr_accessor :script_names
# The category identifying the legal structure of the business.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :structure
# The business's publicly available website.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :url
sig {
params(address: T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::BusinessDetails::Address)), annual_revenue: T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::BusinessDetails::AnnualRevenue)), documents: T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::BusinessDetails::Documents)), doing_business_as: T.nilable(T.nilable(String)), estimated_worker_count: T.nilable(T.nilable(Integer)), id_numbers: T.nilable(T.nilable(T::Array[::Stripe::V2::Core::AccountService::UpdateParams::Identity::BusinessDetails::IdNumber])), monthly_estimated_revenue: T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::BusinessDetails::MonthlyEstimatedRevenue)), phone: T.nilable(T.nilable(String)), product_description: T.nilable(T.nilable(String)), registered_name: T.nilable(T.nilable(String)), script_addresses: T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::BusinessDetails::ScriptAddresses)), script_names: T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::BusinessDetails::ScriptNames)), structure: T.nilable(T.nilable(String)), url: T.nilable(T.nilable(String))).void
}
def initialize(
address: nil,
annual_revenue: nil,
documents: nil,
doing_business_as: nil,
estimated_worker_count: nil,
id_numbers: nil,
monthly_estimated_revenue: nil,
phone: nil,
product_description: nil,
registered_name: nil,
script_addresses: nil,
script_names: nil,
structure: nil,
url: nil
); end
end
class Individual < Stripe::RequestParams
class AdditionalAddress < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :postal_code
# Purpose of additional address.
sig { returns(String) }
attr_accessor :purpose
# State, county, province, or region.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :town
sig {
params(city: T.nilable(T.nilable(String)), country: T.nilable(T.nilable(String)), line1: T.nilable(T.nilable(String)), line2: T.nilable(T.nilable(String)), postal_code: T.nilable(T.nilable(String)), purpose: String, state: T.nilable(T.nilable(String)), town: T.nilable(T.nilable(String))).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
purpose: nil,
state: nil,
town: nil
); end
end
class AdditionalName < Stripe::RequestParams
# The person's full name.
sig { returns(T.nilable(String)) }
attr_accessor :full_name
# The person's first or given name.
sig { returns(T.nilable(String)) }
attr_accessor :given_name
# The purpose or type of the additional name.
sig { returns(String) }
attr_accessor :purpose
# The person's last or family name.
sig { returns(T.nilable(String)) }
attr_accessor :surname
sig {
params(full_name: T.nilable(String), given_name: T.nilable(String), purpose: String, surname: T.nilable(String)).void
}
def initialize(full_name: nil, given_name: nil, purpose: nil, surname: nil); end
end
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :town
sig {
params(city: T.nilable(T.nilable(String)), country: T.nilable(T.nilable(String)), line1: T.nilable(T.nilable(String)), line2: T.nilable(T.nilable(String)), postal_code: T.nilable(T.nilable(String)), state: T.nilable(T.nilable(String)), town: T.nilable(T.nilable(String))).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
class DateOfBirth < Stripe::RequestParams
# The day of the birth.
sig { returns(Integer) }
attr_accessor :day
# The month of birth.
sig { returns(Integer) }
attr_accessor :month
# The year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
class Documents < Stripe::RequestParams
class CompanyAuthorization < Stripe::RequestParams
# One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`.
sig { returns(T::Array[String]) }
attr_accessor :files
# The format of the document. Currently supports `files` only.
sig { returns(String) }
attr_accessor :type
sig { params(files: T::Array[String], type: String).void }
def initialize(files: nil, type: nil); end
end
class Passport < Stripe::RequestParams
# One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`.
sig { returns(T::Array[String]) }
attr_accessor :files
# The format of the document. Currently supports `files` only.
sig { returns(String) }
attr_accessor :type
sig { params(files: T::Array[String], type: String).void }
def initialize(files: nil, type: nil); end
end
class PrimaryVerification < Stripe::RequestParams
class FrontBack < Stripe::RequestParams
# A [file upload](https://docs.stripe.com/api/persons/update#create_file) token representing the back of the verification document. The purpose of the uploaded file should be 'identity_document'. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :back
# A [file upload](https://docs.stripe.com/api/persons/update#create_file) token representing the front of the verification document. The purpose of the uploaded file should be 'identity_document'. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :front
sig {
params(back: T.nilable(T.nilable(String)), front: T.nilable(String)).void
}
def initialize(back: nil, front: nil); end
end
# The [file upload](https://docs.stripe.com/api/persons/update#create_file) tokens referring to each side of the document.
sig {
returns(::Stripe::V2::Core::AccountService::UpdateParams::Identity::Individual::Documents::PrimaryVerification::FrontBack)
}
attr_accessor :front_back
# The format of the verification document. Currently supports `front_back` only.
sig { returns(String) }
attr_accessor :type
sig {
params(front_back: ::Stripe::V2::Core::AccountService::UpdateParams::Identity::Individual::Documents::PrimaryVerification::FrontBack, type: String).void
}
def initialize(front_back: nil, type: nil); end
end
class SecondaryVerification < Stripe::RequestParams
class FrontBack < Stripe::RequestParams
# A [file upload](https://docs.stripe.com/api/persons/update#create_file) token representing the back of the verification document. The purpose of the uploaded file should be 'identity_document'. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :back
# A [file upload](https://docs.stripe.com/api/persons/update#create_file) token representing the front of the verification document. The purpose of the uploaded file should be 'identity_document'. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :front
sig {
params(back: T.nilable(T.nilable(String)), front: T.nilable(String)).void
}
def initialize(back: nil, front: nil); end
end
# The [file upload](https://docs.stripe.com/api/persons/update#create_file) tokens referring to each side of the document.
sig {
returns(::Stripe::V2::Core::AccountService::UpdateParams::Identity::Individual::Documents::SecondaryVerification::FrontBack)
}
attr_accessor :front_back
# The format of the verification document. Currently supports `front_back` only.
sig { returns(String) }
attr_accessor :type
sig {
params(front_back: ::Stripe::V2::Core::AccountService::UpdateParams::Identity::Individual::Documents::SecondaryVerification::FrontBack, type: String).void
}
def initialize(front_back: nil, type: nil); end
end
class Visa < Stripe::RequestParams
# One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`.
sig { returns(T::Array[String]) }
attr_accessor :files
# The format of the document. Currently supports `files` only.
sig { returns(String) }
attr_accessor :type
sig { params(files: T::Array[String], type: String).void }
def initialize(files: nil, type: nil); end
end
# One or more documents that demonstrate proof that this person is authorized to represent the company.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::Individual::Documents::CompanyAuthorization))
}
attr_accessor :company_authorization
# One or more documents showing the person’s passport page with photo and personal data.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::Individual::Documents::Passport))
}
attr_accessor :passport
# An identifying document showing the person's name, either a passport or local ID card.
sig {
returns(T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::Individual::Documents::PrimaryVerification)))
}
attr_accessor :primary_verification
# A document showing address, either a passport, local ID card, or utility bill from a well-known utility company.
sig {
returns(T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::Individual::Documents::SecondaryVerification)))
}
attr_accessor :secondary_verification
# One or more documents showing the person’s visa required for living in the country where they are residing.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::Individual::Documents::Visa))
}
attr_accessor :visa
sig {
params(company_authorization: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::Individual::Documents::CompanyAuthorization), passport: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::Individual::Documents::Passport), primary_verification: T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::Individual::Documents::PrimaryVerification)), secondary_verification: T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::Individual::Documents::SecondaryVerification)), visa: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::Individual::Documents::Visa)).void
}
def initialize(
company_authorization: nil,
passport: nil,
primary_verification: nil,
secondary_verification: nil,
visa: nil
); end
end
class IdNumber < Stripe::RequestParams
# The ID number type of an individual.
sig { returns(String) }
attr_accessor :type
# The value of the ID number.
sig { returns(String) }
attr_accessor :value
sig { params(type: String, value: String).void }
def initialize(type: nil, value: nil); end
end
class Relationship < Stripe::RequestParams
# Whether the person is a director of the account's identity. Directors are typically members of the governing board of the company, or responsible for ensuring the company meets its regulatory obligations.
sig { returns(T.nilable(T.nilable(T::Boolean))) }
attr_accessor :director
# Whether the person has significant responsibility to control, manage, or direct the organization.
sig { returns(T.nilable(T.nilable(T::Boolean))) }
attr_accessor :executive
# Whether the person is an owner of the account’s identity.
sig { returns(T.nilable(T.nilable(T::Boolean))) }
attr_accessor :owner
# The percent owned by the person of the account's legal entity.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :percent_ownership
# The person's title (e.g., CEO, Support Engineer).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :title
sig {
params(director: T.nilable(T.nilable(T::Boolean)), executive: T.nilable(T.nilable(T::Boolean)), owner: T.nilable(T.nilable(T::Boolean)), percent_ownership: T.nilable(T.nilable(String)), title: T.nilable(T.nilable(String))).void
}
def initialize(
director: nil,
executive: nil,
owner: nil,
percent_ownership: nil,
title: nil
); end
end
class ScriptAddresses < Stripe::RequestParams
class Kana < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :town
sig {
params(city: T.nilable(T.nilable(String)), country: T.nilable(T.nilable(String)), line1: T.nilable(T.nilable(String)), line2: T.nilable(T.nilable(String)), postal_code: T.nilable(T.nilable(String)), state: T.nilable(T.nilable(String)), town: T.nilable(T.nilable(String))).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
class Kanji < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :town
sig {
params(city: T.nilable(T.nilable(String)), country: T.nilable(T.nilable(String)), line1: T.nilable(T.nilable(String)), line2: T.nilable(T.nilable(String)), postal_code: T.nilable(T.nilable(String)), state: T.nilable(T.nilable(String)), town: T.nilable(T.nilable(String))).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
# Kana Address.
sig {
returns(T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::Individual::ScriptAddresses::Kana)))
}
attr_accessor :kana
# Kanji Address.
sig {
returns(T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::Individual::ScriptAddresses::Kanji)))
}
attr_accessor :kanji
sig {
params(kana: T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::Individual::ScriptAddresses::Kana)), kanji: T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::Individual::ScriptAddresses::Kanji))).void
}
def initialize(kana: nil, kanji: nil); end
end
class ScriptNames < Stripe::RequestParams
class Kana < Stripe::RequestParams
# The person's first or given name.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :given_name
# The person's last or family name.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :surname
sig {
params(given_name: T.nilable(T.nilable(String)), surname: T.nilable(T.nilable(String))).void
}
def initialize(given_name: nil, surname: nil); end
end
class Kanji < Stripe::RequestParams
# The person's first or given name.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :given_name
# The person's last or family name.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :surname
sig {
params(given_name: T.nilable(T.nilable(String)), surname: T.nilable(T.nilable(String))).void
}
def initialize(given_name: nil, surname: nil); end
end
# Persons name in kana script.
sig {
returns(T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::Individual::ScriptNames::Kana)))
}
attr_accessor :kana
# Persons name in kanji script.
sig {
returns(T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::Individual::ScriptNames::Kanji)))
}
attr_accessor :kanji
sig {
params(kana: T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::Individual::ScriptNames::Kana)), kanji: T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::Individual::ScriptNames::Kanji))).void
}
def initialize(kana: nil, kanji: nil); end
end
# Additional addresses associated with the individual.
sig {
returns(T.nilable(T.nilable(T::Array[::Stripe::V2::Core::AccountService::UpdateParams::Identity::Individual::AdditionalAddress])))
}
attr_accessor :additional_addresses
# Additional names (e.g. aliases) associated with the individual.
sig {
returns(T.nilable(T.nilable(T::Array[::Stripe::V2::Core::AccountService::UpdateParams::Identity::Individual::AdditionalName])))
}
attr_accessor :additional_names
# The individual's residential address.
sig {
returns(T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::Individual::Address)))
}
attr_accessor :address
# The individual's date of birth.
sig {
returns(T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::Individual::DateOfBirth)))
}
attr_accessor :date_of_birth
# Documents that may be submitted to satisfy various informational requests.
sig {
returns(T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::Individual::Documents)))
}
attr_accessor :documents
# The individual's email address.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :email
# The individual's first name.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :given_name
# The identification numbers (e.g., SSN) associated with the individual.
sig {
returns(T.nilable(T.nilable(T::Array[::Stripe::V2::Core::AccountService::UpdateParams::Identity::Individual::IdNumber])))
}
attr_accessor :id_numbers
# The individual's gender (International regulations require either "male" or "female").
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :legal_gender
# Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
sig { returns(T.nilable(T::Hash[String, T.nilable(String)])) }
attr_accessor :metadata
# The countries where the individual is a national. Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :nationalities
# The individual's phone number.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :phone
# The individual's political exposure.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :political_exposure
# The relationship that this individual has with the account's identity.
sig {
returns(T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::Individual::Relationship)))
}
attr_accessor :relationship
# The script addresses (e.g., non-Latin characters) associated with the individual.
sig {
returns(T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::Individual::ScriptAddresses)))
}
attr_accessor :script_addresses
# The individuals primary name in non latin script.
sig {
returns(T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::Individual::ScriptNames)))
}
attr_accessor :script_names
# The individual's last name.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :surname
sig {
params(additional_addresses: T.nilable(T.nilable(T::Array[::Stripe::V2::Core::AccountService::UpdateParams::Identity::Individual::AdditionalAddress])), additional_names: T.nilable(T.nilable(T::Array[::Stripe::V2::Core::AccountService::UpdateParams::Identity::Individual::AdditionalName])), address: T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::Individual::Address)), date_of_birth: T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::Individual::DateOfBirth)), documents: T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::Individual::Documents)), email: T.nilable(T.nilable(String)), given_name: T.nilable(T.nilable(String)), id_numbers: T.nilable(T.nilable(T::Array[::Stripe::V2::Core::AccountService::UpdateParams::Identity::Individual::IdNumber])), legal_gender: T.nilable(T.nilable(String)), metadata: T.nilable(T::Hash[String, T.nilable(String)]), nationalities: T.nilable(T::Array[String]), phone: T.nilable(T.nilable(String)), political_exposure: T.nilable(T.nilable(String)), relationship: T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::Individual::Relationship)), script_addresses: T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::Individual::ScriptAddresses)), script_names: T.nilable(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::Individual::ScriptNames)), surname: T.nilable(T.nilable(String))).void
}
def initialize(
additional_addresses: nil,
additional_names: nil,
address: nil,
date_of_birth: nil,
documents: nil,
email: nil,
given_name: nil,
id_numbers: nil,
legal_gender: nil,
metadata: nil,
nationalities: nil,
phone: nil,
political_exposure: nil,
relationship: nil,
script_addresses: nil,
script_names: nil,
surname: nil
); end
end
# Attestations from the identity's key people, e.g. owners, executives, directors.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::Attestations))
}
attr_accessor :attestations
# Information about the company or business.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::BusinessDetails))
}
attr_accessor :business_details
# The country in which the account holder resides, or in which the business is legally established. This should be an [ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2) country code.
sig { returns(T.nilable(String)) }
attr_accessor :country
# The entity type.
sig { returns(T.nilable(String)) }
attr_accessor :entity_type
# Information about the individual represented by the Account. This property is `null` unless `entity_type` is set to `individual`.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::Individual))
}
attr_accessor :individual
sig {
params(attestations: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::Attestations), business_details: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::BusinessDetails), country: T.nilable(String), entity_type: T.nilable(String), individual: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity::Individual)).void
}
def initialize(
attestations: nil,
business_details: nil,
country: nil,
entity_type: nil,
individual: nil
); end
end
# An Account Configuration which allows the Account to take on a key persona across Stripe products.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration))
}
attr_accessor :configuration
# The default contact email address for the Account. Required when configuring the account as a merchant or recipient.
sig { returns(T.nilable(String)) }
attr_accessor :contact_email
# A value indicating the Stripe dashboard this Account has access to. This will depend on which configurations are enabled for this account.
sig { returns(T.nilable(String)) }
attr_accessor :dashboard
# Default values to be used on Account Configurations.
sig { returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Defaults)) }
attr_accessor :defaults
# A descriptive name for the Account. This name will be surfaced in the Stripe Dashboard and on any invoices sent to the Account.
sig { returns(T.nilable(String)) }
attr_accessor :display_name
# Information about the company, individual, and business represented by the Account.
sig { returns(T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity)) }
attr_accessor :identity
# Additional fields to include in the response.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :include
# Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
sig { returns(T.nilable(T::Hash[String, T.nilable(String)])) }
attr_accessor :metadata
sig {
params(configuration: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Configuration), contact_email: T.nilable(String), dashboard: T.nilable(String), defaults: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Defaults), display_name: T.nilable(String), identity: T.nilable(::Stripe::V2::Core::AccountService::UpdateParams::Identity), include: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, T.nilable(String)])).void
}
def initialize(
configuration: nil,
contact_email: nil,
dashboard: nil,
defaults: nil,
display_name: nil,
identity: nil,
include: nil,
metadata: nil
); end
end
# Removes access to the Account and its associated resources.
sig {
params(id: String, params: T.any(::Stripe::V2::Core::AccountService::CloseParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::Core::Account)
}
def close(id, params = {}, opts = {}); end
# An Account is a representation of a company, individual or other entity that a user interacts with. Accounts contain identifying information about the entity, and configurations that store the features an account has access to. An account can be configured as any or all of the following configurations: Customer, Merchant and/or Recipient.
sig {
params(params: T.any(::Stripe::V2::Core::AccountService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::Core::Account)
}
def create(params = {}, opts = {}); end
# Returns a list of Accounts.
sig {
params(params: T.any(::Stripe::V2::Core::AccountService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the details of an Account.
sig {
params(id: String, params: T.any(::Stripe::V2::Core::AccountService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::Core::Account)
}
def retrieve(id, params = {}, opts = {}); end
# Updates the details of an Account.
sig {
params(id: String, params: T.any(::Stripe::V2::Core::AccountService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::Core::Account)
}
def update(id, params = {}, opts = {}); end
end
end
end
end
# typed: true
module Stripe
module V2
module Core
module Accounts
class PersonService < StripeService
class CreateParams < Stripe::RequestParams
class AdditionalAddress < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(String) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# Purpose of additional address.
sig { returns(String) }
attr_accessor :purpose
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_accessor :town
sig {
params(city: T.nilable(String), country: String, line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), purpose: String, state: T.nilable(String), town: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
purpose: nil,
state: nil,
town: nil
); end
end
class AdditionalName < Stripe::RequestParams
# The person's full name.
sig { returns(T.nilable(String)) }
attr_accessor :full_name
# The person's first or given name.
sig { returns(T.nilable(String)) }
attr_accessor :given_name
# The purpose or type of the additional name.
sig { returns(String) }
attr_accessor :purpose
# The person's last or family name.
sig { returns(T.nilable(String)) }
attr_accessor :surname
sig {
params(full_name: T.nilable(String), given_name: T.nilable(String), purpose: String, surname: T.nilable(String)).void
}
def initialize(full_name: nil, given_name: nil, purpose: nil, surname: nil); end
end
class AdditionalTermsOfService < Stripe::RequestParams
class Account < Stripe::RequestParams
# The time when the Account's representative accepted the terms of service. Represented as a RFC 3339 date & time UTC value in millisecond precision, for example: 2022-09-18T13:22:18.123Z.
sig { returns(String) }
attr_accessor :date
# The IP address from which the Account's representative accepted the terms of service.
sig { returns(String) }
attr_accessor :ip
# The user agent of the browser from which the Account's representative accepted the terms of service.
sig { returns(T.nilable(String)) }
attr_accessor :user_agent
sig { params(date: String, ip: String, user_agent: T.nilable(String)).void }
def initialize(date: nil, ip: nil, user_agent: nil); end
end
# Stripe terms of service agreement.
sig {
returns(T.nilable(::Stripe::V2::Core::Accounts::PersonService::CreateParams::AdditionalTermsOfService::Account))
}
attr_accessor :account
sig {
params(account: T.nilable(::Stripe::V2::Core::Accounts::PersonService::CreateParams::AdditionalTermsOfService::Account)).void
}
def initialize(account: nil); end
end
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(String) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_accessor :town
sig {
params(city: T.nilable(String), country: String, line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), town: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
class DateOfBirth < Stripe::RequestParams
# The day of birth.
sig { returns(Integer) }
attr_accessor :day
# The month of birth.
sig { returns(Integer) }
attr_accessor :month
# The year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
class Documents < Stripe::RequestParams
class CompanyAuthorization < Stripe::RequestParams
# One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`.
sig { returns(T::Array[String]) }
attr_accessor :files
# The format of the document. Currently supports `files` only.
sig { returns(String) }
attr_accessor :type
sig { params(files: T::Array[String], type: String).void }
def initialize(files: nil, type: nil); end
end
class Passport < Stripe::RequestParams
# One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`.
sig { returns(T::Array[String]) }
attr_accessor :files
# The format of the document. Currently supports `files` only.
sig { returns(String) }
attr_accessor :type
sig { params(files: T::Array[String], type: String).void }
def initialize(files: nil, type: nil); end
end
class PrimaryVerification < Stripe::RequestParams
class FrontBack < Stripe::RequestParams
# A [file upload](https://docs.stripe.com/api/persons/update#create_file) token representing the back of the verification document. The purpose of the uploaded file should be 'identity_document'. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :back
# A [file upload](https://docs.stripe.com/api/persons/update#create_file) token representing the front of the verification document. The purpose of the uploaded file should be 'identity_document'. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(String) }
attr_accessor :front
sig { params(back: T.nilable(String), front: String).void }
def initialize(back: nil, front: nil); end
end
# The [file upload](https://docs.stripe.com/api/persons/update#create_file) tokens referring to each side of the document.
sig {
returns(::Stripe::V2::Core::Accounts::PersonService::CreateParams::Documents::PrimaryVerification::FrontBack)
}
attr_accessor :front_back
# The format of the verification document. Currently supports `front_back` only.
sig { returns(String) }
attr_accessor :type
sig {
params(front_back: ::Stripe::V2::Core::Accounts::PersonService::CreateParams::Documents::PrimaryVerification::FrontBack, type: String).void
}
def initialize(front_back: nil, type: nil); end
end
class SecondaryVerification < Stripe::RequestParams
class FrontBack < Stripe::RequestParams
# A [file upload](https://docs.stripe.com/api/persons/update#create_file) token representing the back of the verification document. The purpose of the uploaded file should be 'identity_document'. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :back
# A [file upload](https://docs.stripe.com/api/persons/update#create_file) token representing the front of the verification document. The purpose of the uploaded file should be 'identity_document'. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(String) }
attr_accessor :front
sig { params(back: T.nilable(String), front: String).void }
def initialize(back: nil, front: nil); end
end
# The [file upload](https://docs.stripe.com/api/persons/update#create_file) tokens referring to each side of the document.
sig {
returns(::Stripe::V2::Core::Accounts::PersonService::CreateParams::Documents::SecondaryVerification::FrontBack)
}
attr_accessor :front_back
# The format of the verification document. Currently supports `front_back` only.
sig { returns(String) }
attr_accessor :type
sig {
params(front_back: ::Stripe::V2::Core::Accounts::PersonService::CreateParams::Documents::SecondaryVerification::FrontBack, type: String).void
}
def initialize(front_back: nil, type: nil); end
end
class Visa < Stripe::RequestParams
# One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`.
sig { returns(T::Array[String]) }
attr_accessor :files
# The format of the document. Currently supports `files` only.
sig { returns(String) }
attr_accessor :type
sig { params(files: T::Array[String], type: String).void }
def initialize(files: nil, type: nil); end
end
# One or more documents that demonstrate proof that this person is authorized to represent the company.
sig {
returns(T.nilable(::Stripe::V2::Core::Accounts::PersonService::CreateParams::Documents::CompanyAuthorization))
}
attr_accessor :company_authorization
# One or more documents showing the person’s passport page with photo and personal data.
sig {
returns(T.nilable(::Stripe::V2::Core::Accounts::PersonService::CreateParams::Documents::Passport))
}
attr_accessor :passport
# An identifying document showing the person's name, either a passport or local ID card.
sig {
returns(T.nilable(::Stripe::V2::Core::Accounts::PersonService::CreateParams::Documents::PrimaryVerification))
}
attr_accessor :primary_verification
# A document showing address, either a passport, local ID card, or utility bill from a well-known utility company.
sig {
returns(T.nilable(::Stripe::V2::Core::Accounts::PersonService::CreateParams::Documents::SecondaryVerification))
}
attr_accessor :secondary_verification
# One or more documents showing the person’s visa required for living in the country where they are residing.
sig {
returns(T.nilable(::Stripe::V2::Core::Accounts::PersonService::CreateParams::Documents::Visa))
}
attr_accessor :visa
sig {
params(company_authorization: T.nilable(::Stripe::V2::Core::Accounts::PersonService::CreateParams::Documents::CompanyAuthorization), passport: T.nilable(::Stripe::V2::Core::Accounts::PersonService::CreateParams::Documents::Passport), primary_verification: T.nilable(::Stripe::V2::Core::Accounts::PersonService::CreateParams::Documents::PrimaryVerification), secondary_verification: T.nilable(::Stripe::V2::Core::Accounts::PersonService::CreateParams::Documents::SecondaryVerification), visa: T.nilable(::Stripe::V2::Core::Accounts::PersonService::CreateParams::Documents::Visa)).void
}
def initialize(
company_authorization: nil,
passport: nil,
primary_verification: nil,
secondary_verification: nil,
visa: nil
); end
end
class IdNumber < Stripe::RequestParams
# The ID number type of an individual.
sig { returns(String) }
attr_accessor :type
# The value of the ID number.
sig { returns(String) }
attr_accessor :value
sig { params(type: String, value: String).void }
def initialize(type: nil, value: nil); end
end
class Relationship < Stripe::RequestParams
# Whether the individual is an authorizer of the Account’s legal entity.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :authorizer
# Indicates whether the person is a director of the associated legal entity.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :director
# Indicates whether the person is an executive of the associated legal entity.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :executive
# Indicates whether the person is a legal guardian of the associated legal entity.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :legal_guardian
# Indicates whether the person is an owner of the associated legal entity.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :owner
# The percentage of ownership the person has in the associated legal entity.
sig { returns(T.nilable(String)) }
attr_accessor :percent_ownership
# Indicates whether the person is a representative of the associated legal entity.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :representative
# The title or position the person holds in the associated legal entity.
sig { returns(T.nilable(String)) }
attr_accessor :title
sig {
params(authorizer: T.nilable(T::Boolean), director: T.nilable(T::Boolean), executive: T.nilable(T::Boolean), legal_guardian: T.nilable(T::Boolean), owner: T.nilable(T::Boolean), percent_ownership: T.nilable(String), representative: T.nilable(T::Boolean), title: T.nilable(String)).void
}
def initialize(
authorizer: nil,
director: nil,
executive: nil,
legal_guardian: nil,
owner: nil,
percent_ownership: nil,
representative: nil,
title: nil
); end
end
class ScriptAddresses < Stripe::RequestParams
class Kana < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(String) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_accessor :town
sig {
params(city: T.nilable(String), country: String, line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), town: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
class Kanji < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(String)) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(String) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(String)) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(String)) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(String)) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(String)) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(String)) }
attr_accessor :town
sig {
params(city: T.nilable(String), country: String, line1: T.nilable(String), line2: T.nilable(String), postal_code: T.nilable(String), state: T.nilable(String), town: T.nilable(String)).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
# Kana Address.
sig {
returns(T.nilable(::Stripe::V2::Core::Accounts::PersonService::CreateParams::ScriptAddresses::Kana))
}
attr_accessor :kana
# Kanji Address.
sig {
returns(T.nilable(::Stripe::V2::Core::Accounts::PersonService::CreateParams::ScriptAddresses::Kanji))
}
attr_accessor :kanji
sig {
params(kana: T.nilable(::Stripe::V2::Core::Accounts::PersonService::CreateParams::ScriptAddresses::Kana), kanji: T.nilable(::Stripe::V2::Core::Accounts::PersonService::CreateParams::ScriptAddresses::Kanji)).void
}
def initialize(kana: nil, kanji: nil); end
end
class ScriptNames < Stripe::RequestParams
class Kana < Stripe::RequestParams
# The person's first or given name.
sig { returns(T.nilable(String)) }
attr_accessor :given_name
# The person's last or family name.
sig { returns(T.nilable(String)) }
attr_accessor :surname
sig { params(given_name: T.nilable(String), surname: T.nilable(String)).void }
def initialize(given_name: nil, surname: nil); end
end
class Kanji < Stripe::RequestParams
# The person's first or given name.
sig { returns(T.nilable(String)) }
attr_accessor :given_name
# The person's last or family name.
sig { returns(T.nilable(String)) }
attr_accessor :surname
sig { params(given_name: T.nilable(String), surname: T.nilable(String)).void }
def initialize(given_name: nil, surname: nil); end
end
# Persons name in kana script.
sig {
returns(T.nilable(::Stripe::V2::Core::Accounts::PersonService::CreateParams::ScriptNames::Kana))
}
attr_accessor :kana
# Persons name in kanji script.
sig {
returns(T.nilable(::Stripe::V2::Core::Accounts::PersonService::CreateParams::ScriptNames::Kanji))
}
attr_accessor :kanji
sig {
params(kana: T.nilable(::Stripe::V2::Core::Accounts::PersonService::CreateParams::ScriptNames::Kana), kanji: T.nilable(::Stripe::V2::Core::Accounts::PersonService::CreateParams::ScriptNames::Kanji)).void
}
def initialize(kana: nil, kanji: nil); end
end
# Additional addresses associated with the person.
sig {
returns(T.nilable(T::Array[::Stripe::V2::Core::Accounts::PersonService::CreateParams::AdditionalAddress]))
}
attr_accessor :additional_addresses
# Additional names (e.g. aliases) associated with the person.
sig {
returns(T.nilable(T::Array[::Stripe::V2::Core::Accounts::PersonService::CreateParams::AdditionalName]))
}
attr_accessor :additional_names
# Attestations of accepted terms of service agreements.
sig {
returns(T.nilable(::Stripe::V2::Core::Accounts::PersonService::CreateParams::AdditionalTermsOfService))
}
attr_accessor :additional_terms_of_service
# The person's residential address.
sig {
returns(T.nilable(::Stripe::V2::Core::Accounts::PersonService::CreateParams::Address))
}
attr_accessor :address
# The person's date of birth.
sig {
returns(T.nilable(::Stripe::V2::Core::Accounts::PersonService::CreateParams::DateOfBirth))
}
attr_accessor :date_of_birth
# Documents that may be submitted to satisfy various informational requests.
sig {
returns(T.nilable(::Stripe::V2::Core::Accounts::PersonService::CreateParams::Documents))
}
attr_accessor :documents
# Email.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The person's first name.
sig { returns(T.nilable(String)) }
attr_accessor :given_name
# The identification numbers (e.g., SSN) associated with the person.
sig {
returns(T.nilable(T::Array[::Stripe::V2::Core::Accounts::PersonService::CreateParams::IdNumber]))
}
attr_accessor :id_numbers
# The person's gender (International regulations require either "male" or "female").
sig { returns(T.nilable(String)) }
attr_accessor :legal_gender
# Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The nationalities (countries) this person is associated with.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :nationalities
# The phone number for this person.
sig { returns(T.nilable(String)) }
attr_accessor :phone
# The person's political exposure.
sig { returns(T.nilable(String)) }
attr_accessor :political_exposure
# The relationship that this person has with the Account's business or legal entity.
sig {
returns(T.nilable(::Stripe::V2::Core::Accounts::PersonService::CreateParams::Relationship))
}
attr_accessor :relationship
# The script addresses (e.g., non-Latin characters) associated with the person.
sig {
returns(T.nilable(::Stripe::V2::Core::Accounts::PersonService::CreateParams::ScriptAddresses))
}
attr_accessor :script_addresses
# The script names (e.g. non-Latin characters) associated with the person.
sig {
returns(T.nilable(::Stripe::V2::Core::Accounts::PersonService::CreateParams::ScriptNames))
}
attr_accessor :script_names
# The person's last name.
sig { returns(T.nilable(String)) }
attr_accessor :surname
sig {
params(additional_addresses: T.nilable(T::Array[::Stripe::V2::Core::Accounts::PersonService::CreateParams::AdditionalAddress]), additional_names: T.nilable(T::Array[::Stripe::V2::Core::Accounts::PersonService::CreateParams::AdditionalName]), additional_terms_of_service: T.nilable(::Stripe::V2::Core::Accounts::PersonService::CreateParams::AdditionalTermsOfService), address: T.nilable(::Stripe::V2::Core::Accounts::PersonService::CreateParams::Address), date_of_birth: T.nilable(::Stripe::V2::Core::Accounts::PersonService::CreateParams::DateOfBirth), documents: T.nilable(::Stripe::V2::Core::Accounts::PersonService::CreateParams::Documents), email: T.nilable(String), given_name: T.nilable(String), id_numbers: T.nilable(T::Array[::Stripe::V2::Core::Accounts::PersonService::CreateParams::IdNumber]), legal_gender: T.nilable(String), metadata: T.nilable(T::Hash[String, String]), nationalities: T.nilable(T::Array[String]), phone: T.nilable(String), political_exposure: T.nilable(String), relationship: T.nilable(::Stripe::V2::Core::Accounts::PersonService::CreateParams::Relationship), script_addresses: T.nilable(::Stripe::V2::Core::Accounts::PersonService::CreateParams::ScriptAddresses), script_names: T.nilable(::Stripe::V2::Core::Accounts::PersonService::CreateParams::ScriptNames), surname: T.nilable(String)).void
}
def initialize(
additional_addresses: nil,
additional_names: nil,
additional_terms_of_service: nil,
address: nil,
date_of_birth: nil,
documents: nil,
email: nil,
given_name: nil,
id_numbers: nil,
legal_gender: nil,
metadata: nil,
nationalities: nil,
phone: nil,
political_exposure: nil,
relationship: nil,
script_addresses: nil,
script_names: nil,
surname: nil
); end
end
class DeleteParams < Stripe::RequestParams; end
class ListParams < Stripe::RequestParams
# The upper limit on the number of accounts returned by the List Account request.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
sig { params(limit: T.nilable(Integer)).void }
def initialize(limit: nil); end
end
class RetrieveParams < Stripe::RequestParams; end
class UpdateParams < Stripe::RequestParams
class AdditionalAddress < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :postal_code
# Purpose of additional address.
sig { returns(String) }
attr_accessor :purpose
# State, county, province, or region.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :town
sig {
params(city: T.nilable(T.nilable(String)), country: T.nilable(T.nilable(String)), line1: T.nilable(T.nilable(String)), line2: T.nilable(T.nilable(String)), postal_code: T.nilable(T.nilable(String)), purpose: String, state: T.nilable(T.nilable(String)), town: T.nilable(T.nilable(String))).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
purpose: nil,
state: nil,
town: nil
); end
end
class AdditionalName < Stripe::RequestParams
# The person's full name.
sig { returns(T.nilable(String)) }
attr_accessor :full_name
# The person's first or given name.
sig { returns(T.nilable(String)) }
attr_accessor :given_name
# The purpose or type of the additional name.
sig { returns(String) }
attr_accessor :purpose
# The person's last or family name.
sig { returns(T.nilable(String)) }
attr_accessor :surname
sig {
params(full_name: T.nilable(String), given_name: T.nilable(String), purpose: String, surname: T.nilable(String)).void
}
def initialize(full_name: nil, given_name: nil, purpose: nil, surname: nil); end
end
class AdditionalTermsOfService < Stripe::RequestParams
class Account < Stripe::RequestParams
# The time when the Account's representative accepted the terms of service. Represented as a RFC 3339 date & time UTC value in millisecond precision, for example: 2022-09-18T13:22:18.123Z.
sig { returns(T.nilable(String)) }
attr_accessor :date
# The IP address from which the Account's representative accepted the terms of service.
sig { returns(T.nilable(String)) }
attr_accessor :ip
# The user agent of the browser from which the Account's representative accepted the terms of service.
sig { returns(T.nilable(String)) }
attr_accessor :user_agent
sig {
params(date: T.nilable(String), ip: T.nilable(String), user_agent: T.nilable(String)).void
}
def initialize(date: nil, ip: nil, user_agent: nil); end
end
# Stripe terms of service agreement.
sig {
returns(T.nilable(::Stripe::V2::Core::Accounts::PersonService::UpdateParams::AdditionalTermsOfService::Account))
}
attr_accessor :account
sig {
params(account: T.nilable(::Stripe::V2::Core::Accounts::PersonService::UpdateParams::AdditionalTermsOfService::Account)).void
}
def initialize(account: nil); end
end
class Address < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :town
sig {
params(city: T.nilable(T.nilable(String)), country: T.nilable(T.nilable(String)), line1: T.nilable(T.nilable(String)), line2: T.nilable(T.nilable(String)), postal_code: T.nilable(T.nilable(String)), state: T.nilable(T.nilable(String)), town: T.nilable(T.nilable(String))).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
class DateOfBirth < Stripe::RequestParams
# The day of the birth.
sig { returns(Integer) }
attr_accessor :day
# The month of birth.
sig { returns(Integer) }
attr_accessor :month
# The year of birth.
sig { returns(Integer) }
attr_accessor :year
sig { params(day: Integer, month: Integer, year: Integer).void }
def initialize(day: nil, month: nil, year: nil); end
end
class Documents < Stripe::RequestParams
class CompanyAuthorization < Stripe::RequestParams
# One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`.
sig { returns(T::Array[String]) }
attr_accessor :files
# The format of the document. Currently supports `files` only.
sig { returns(String) }
attr_accessor :type
sig { params(files: T::Array[String], type: String).void }
def initialize(files: nil, type: nil); end
end
class Passport < Stripe::RequestParams
# One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`.
sig { returns(T::Array[String]) }
attr_accessor :files
# The format of the document. Currently supports `files` only.
sig { returns(String) }
attr_accessor :type
sig { params(files: T::Array[String], type: String).void }
def initialize(files: nil, type: nil); end
end
class PrimaryVerification < Stripe::RequestParams
class FrontBack < Stripe::RequestParams
# A [file upload](https://docs.stripe.com/api/persons/update#create_file) token representing the back of the verification document. The purpose of the uploaded file should be 'identity_document'. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :back
# A [file upload](https://docs.stripe.com/api/persons/update#create_file) token representing the front of the verification document. The purpose of the uploaded file should be 'identity_document'. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :front
sig { params(back: T.nilable(T.nilable(String)), front: T.nilable(String)).void }
def initialize(back: nil, front: nil); end
end
# The [file upload](https://docs.stripe.com/api/persons/update#create_file) tokens referring to each side of the document.
sig {
returns(::Stripe::V2::Core::Accounts::PersonService::UpdateParams::Documents::PrimaryVerification::FrontBack)
}
attr_accessor :front_back
# The format of the verification document. Currently supports `front_back` only.
sig { returns(String) }
attr_accessor :type
sig {
params(front_back: ::Stripe::V2::Core::Accounts::PersonService::UpdateParams::Documents::PrimaryVerification::FrontBack, type: String).void
}
def initialize(front_back: nil, type: nil); end
end
class SecondaryVerification < Stripe::RequestParams
class FrontBack < Stripe::RequestParams
# A [file upload](https://docs.stripe.com/api/persons/update#create_file) token representing the back of the verification document. The purpose of the uploaded file should be 'identity_document'. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :back
# A [file upload](https://docs.stripe.com/api/persons/update#create_file) token representing the front of the verification document. The purpose of the uploaded file should be 'identity_document'. The uploaded file needs to be a color image (smaller than 8,000px by 8,000px), in JPG, PNG, or PDF format, and less than 10 MB in size.
sig { returns(T.nilable(String)) }
attr_accessor :front
sig { params(back: T.nilable(T.nilable(String)), front: T.nilable(String)).void }
def initialize(back: nil, front: nil); end
end
# The [file upload](https://docs.stripe.com/api/persons/update#create_file) tokens referring to each side of the document.
sig {
returns(::Stripe::V2::Core::Accounts::PersonService::UpdateParams::Documents::SecondaryVerification::FrontBack)
}
attr_accessor :front_back
# The format of the verification document. Currently supports `front_back` only.
sig { returns(String) }
attr_accessor :type
sig {
params(front_back: ::Stripe::V2::Core::Accounts::PersonService::UpdateParams::Documents::SecondaryVerification::FrontBack, type: String).void
}
def initialize(front_back: nil, type: nil); end
end
class Visa < Stripe::RequestParams
# One or more document IDs returned by a [file upload](https://docs.stripe.com/api/persons/update#create_file) with a purpose value of `account_requirement`.
sig { returns(T::Array[String]) }
attr_accessor :files
# The format of the document. Currently supports `files` only.
sig { returns(String) }
attr_accessor :type
sig { params(files: T::Array[String], type: String).void }
def initialize(files: nil, type: nil); end
end
# One or more documents that demonstrate proof that this person is authorized to represent the company.
sig {
returns(T.nilable(::Stripe::V2::Core::Accounts::PersonService::UpdateParams::Documents::CompanyAuthorization))
}
attr_accessor :company_authorization
# One or more documents showing the person’s passport page with photo and personal data.
sig {
returns(T.nilable(::Stripe::V2::Core::Accounts::PersonService::UpdateParams::Documents::Passport))
}
attr_accessor :passport
# An identifying document showing the person's name, either a passport or local ID card.
sig {
returns(T.nilable(T.nilable(::Stripe::V2::Core::Accounts::PersonService::UpdateParams::Documents::PrimaryVerification)))
}
attr_accessor :primary_verification
# A document showing address, either a passport, local ID card, or utility bill from a well-known utility company.
sig {
returns(T.nilable(T.nilable(::Stripe::V2::Core::Accounts::PersonService::UpdateParams::Documents::SecondaryVerification)))
}
attr_accessor :secondary_verification
# One or more documents showing the person’s visa required for living in the country where they are residing.
sig {
returns(T.nilable(::Stripe::V2::Core::Accounts::PersonService::UpdateParams::Documents::Visa))
}
attr_accessor :visa
sig {
params(company_authorization: T.nilable(::Stripe::V2::Core::Accounts::PersonService::UpdateParams::Documents::CompanyAuthorization), passport: T.nilable(::Stripe::V2::Core::Accounts::PersonService::UpdateParams::Documents::Passport), primary_verification: T.nilable(T.nilable(::Stripe::V2::Core::Accounts::PersonService::UpdateParams::Documents::PrimaryVerification)), secondary_verification: T.nilable(T.nilable(::Stripe::V2::Core::Accounts::PersonService::UpdateParams::Documents::SecondaryVerification)), visa: T.nilable(::Stripe::V2::Core::Accounts::PersonService::UpdateParams::Documents::Visa)).void
}
def initialize(
company_authorization: nil,
passport: nil,
primary_verification: nil,
secondary_verification: nil,
visa: nil
); end
end
class IdNumber < Stripe::RequestParams
# The ID number type of an individual.
sig { returns(String) }
attr_accessor :type
# The value of the ID number.
sig { returns(String) }
attr_accessor :value
sig { params(type: String, value: String).void }
def initialize(type: nil, value: nil); end
end
class Relationship < Stripe::RequestParams
# Whether the individual is an authorizer of the Account’s legal entity.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :authorizer
# Indicates whether the person is a director of the associated legal entity.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :director
# Indicates whether the person is an executive of the associated legal entity.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :executive
# Indicates whether the person is a legal guardian of the associated legal entity.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :legal_guardian
# Indicates whether the person is an owner of the associated legal entity.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :owner
# The percentage of ownership the person has in the associated legal entity.
sig { returns(T.nilable(String)) }
attr_accessor :percent_ownership
# Indicates whether the person is a representative of the associated legal entity.
sig { returns(T.nilable(T::Boolean)) }
attr_accessor :representative
# The title or position the person holds in the associated legal entity.
sig { returns(T.nilable(String)) }
attr_accessor :title
sig {
params(authorizer: T.nilable(T::Boolean), director: T.nilable(T::Boolean), executive: T.nilable(T::Boolean), legal_guardian: T.nilable(T::Boolean), owner: T.nilable(T::Boolean), percent_ownership: T.nilable(String), representative: T.nilable(T::Boolean), title: T.nilable(String)).void
}
def initialize(
authorizer: nil,
director: nil,
executive: nil,
legal_guardian: nil,
owner: nil,
percent_ownership: nil,
representative: nil,
title: nil
); end
end
class ScriptAddresses < Stripe::RequestParams
class Kana < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :town
sig {
params(city: T.nilable(T.nilable(String)), country: T.nilable(T.nilable(String)), line1: T.nilable(T.nilable(String)), line2: T.nilable(T.nilable(String)), postal_code: T.nilable(T.nilable(String)), state: T.nilable(T.nilable(String)), town: T.nilable(T.nilable(String))).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
class Kanji < Stripe::RequestParams
# City, district, suburb, town, or village.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :city
# Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :country
# Address line 1 (e.g., street, PO Box, or company name).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :line1
# Address line 2 (e.g., apartment, suite, unit, or building).
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :line2
# ZIP or postal code.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :postal_code
# State, county, province, or region.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :state
# Town or cho-me.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :town
sig {
params(city: T.nilable(T.nilable(String)), country: T.nilable(T.nilable(String)), line1: T.nilable(T.nilable(String)), line2: T.nilable(T.nilable(String)), postal_code: T.nilable(T.nilable(String)), state: T.nilable(T.nilable(String)), town: T.nilable(T.nilable(String))).void
}
def initialize(
city: nil,
country: nil,
line1: nil,
line2: nil,
postal_code: nil,
state: nil,
town: nil
); end
end
# Kana Address.
sig {
returns(T.nilable(T.nilable(::Stripe::V2::Core::Accounts::PersonService::UpdateParams::ScriptAddresses::Kana)))
}
attr_accessor :kana
# Kanji Address.
sig {
returns(T.nilable(T.nilable(::Stripe::V2::Core::Accounts::PersonService::UpdateParams::ScriptAddresses::Kanji)))
}
attr_accessor :kanji
sig {
params(kana: T.nilable(T.nilable(::Stripe::V2::Core::Accounts::PersonService::UpdateParams::ScriptAddresses::Kana)), kanji: T.nilable(T.nilable(::Stripe::V2::Core::Accounts::PersonService::UpdateParams::ScriptAddresses::Kanji))).void
}
def initialize(kana: nil, kanji: nil); end
end
class ScriptNames < Stripe::RequestParams
class Kana < Stripe::RequestParams
# The person's first or given name.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :given_name
# The person's last or family name.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :surname
sig {
params(given_name: T.nilable(T.nilable(String)), surname: T.nilable(T.nilable(String))).void
}
def initialize(given_name: nil, surname: nil); end
end
class Kanji < Stripe::RequestParams
# The person's first or given name.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :given_name
# The person's last or family name.
sig { returns(T.nilable(T.nilable(String))) }
attr_accessor :surname
sig {
params(given_name: T.nilable(T.nilable(String)), surname: T.nilable(T.nilable(String))).void
}
def initialize(given_name: nil, surname: nil); end
end
# Persons name in kana script.
sig {
returns(T.nilable(T.nilable(::Stripe::V2::Core::Accounts::PersonService::UpdateParams::ScriptNames::Kana)))
}
attr_accessor :kana
# Persons name in kanji script.
sig {
returns(T.nilable(T.nilable(::Stripe::V2::Core::Accounts::PersonService::UpdateParams::ScriptNames::Kanji)))
}
attr_accessor :kanji
sig {
params(kana: T.nilable(T.nilable(::Stripe::V2::Core::Accounts::PersonService::UpdateParams::ScriptNames::Kana)), kanji: T.nilable(T.nilable(::Stripe::V2::Core::Accounts::PersonService::UpdateParams::ScriptNames::Kanji))).void
}
def initialize(kana: nil, kanji: nil); end
end
# Additional addresses associated with the person.
sig {
returns(T.nilable(T::Array[::Stripe::V2::Core::Accounts::PersonService::UpdateParams::AdditionalAddress]))
}
attr_accessor :additional_addresses
# Additional names (e.g. aliases) associated with the person.
sig {
returns(T.nilable(T::Array[::Stripe::V2::Core::Accounts::PersonService::UpdateParams::AdditionalName]))
}
attr_accessor :additional_names
# Attestations of accepted terms of service agreements.
sig {
returns(T.nilable(::Stripe::V2::Core::Accounts::PersonService::UpdateParams::AdditionalTermsOfService))
}
attr_accessor :additional_terms_of_service
# The primary address associated with the person.
sig {
returns(T.nilable(::Stripe::V2::Core::Accounts::PersonService::UpdateParams::Address))
}
attr_accessor :address
# The person's date of birth.
sig {
returns(T.nilable(::Stripe::V2::Core::Accounts::PersonService::UpdateParams::DateOfBirth))
}
attr_accessor :date_of_birth
# Documents that may be submitted to satisfy various informational requests.
sig {
returns(T.nilable(::Stripe::V2::Core::Accounts::PersonService::UpdateParams::Documents))
}
attr_accessor :documents
# Email.
sig { returns(T.nilable(String)) }
attr_accessor :email
# The person's first name.
sig { returns(T.nilable(String)) }
attr_accessor :given_name
# The identification numbers (e.g., SSN) associated with the person.
sig {
returns(T.nilable(T::Array[::Stripe::V2::Core::Accounts::PersonService::UpdateParams::IdNumber]))
}
attr_accessor :id_numbers
# The person's gender (International regulations require either "male" or "female").
sig { returns(T.nilable(String)) }
attr_accessor :legal_gender
# Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
sig { returns(T.nilable(T::Hash[String, T.nilable(String)])) }
attr_accessor :metadata
# The nationalities (countries) this person is associated with.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :nationalities
# The phone number for this person.
sig { returns(T.nilable(String)) }
attr_accessor :phone
# The person's political exposure.
sig { returns(T.nilable(String)) }
attr_accessor :political_exposure
# The relationship that this person has with the Account's business or legal entity.
sig {
returns(T.nilable(::Stripe::V2::Core::Accounts::PersonService::UpdateParams::Relationship))
}
attr_accessor :relationship
# The script addresses (e.g., non-Latin characters) associated with the person.
sig {
returns(T.nilable(T.nilable(::Stripe::V2::Core::Accounts::PersonService::UpdateParams::ScriptAddresses)))
}
attr_accessor :script_addresses
# The script names (e.g. non-Latin characters) associated with the person.
sig {
returns(T.nilable(T.nilable(::Stripe::V2::Core::Accounts::PersonService::UpdateParams::ScriptNames)))
}
attr_accessor :script_names
# The person's last name.
sig { returns(T.nilable(String)) }
attr_accessor :surname
sig {
params(additional_addresses: T.nilable(T::Array[::Stripe::V2::Core::Accounts::PersonService::UpdateParams::AdditionalAddress]), additional_names: T.nilable(T::Array[::Stripe::V2::Core::Accounts::PersonService::UpdateParams::AdditionalName]), additional_terms_of_service: T.nilable(::Stripe::V2::Core::Accounts::PersonService::UpdateParams::AdditionalTermsOfService), address: T.nilable(::Stripe::V2::Core::Accounts::PersonService::UpdateParams::Address), date_of_birth: T.nilable(::Stripe::V2::Core::Accounts::PersonService::UpdateParams::DateOfBirth), documents: T.nilable(::Stripe::V2::Core::Accounts::PersonService::UpdateParams::Documents), email: T.nilable(String), given_name: T.nilable(String), id_numbers: T.nilable(T::Array[::Stripe::V2::Core::Accounts::PersonService::UpdateParams::IdNumber]), legal_gender: T.nilable(String), metadata: T.nilable(T::Hash[String, T.nilable(String)]), nationalities: T.nilable(T::Array[String]), phone: T.nilable(String), political_exposure: T.nilable(String), relationship: T.nilable(::Stripe::V2::Core::Accounts::PersonService::UpdateParams::Relationship), script_addresses: T.nilable(T.nilable(::Stripe::V2::Core::Accounts::PersonService::UpdateParams::ScriptAddresses)), script_names: T.nilable(T.nilable(::Stripe::V2::Core::Accounts::PersonService::UpdateParams::ScriptNames)), surname: T.nilable(String)).void
}
def initialize(
additional_addresses: nil,
additional_names: nil,
additional_terms_of_service: nil,
address: nil,
date_of_birth: nil,
documents: nil,
email: nil,
given_name: nil,
id_numbers: nil,
legal_gender: nil,
metadata: nil,
nationalities: nil,
phone: nil,
political_exposure: nil,
relationship: nil,
script_addresses: nil,
script_names: nil,
surname: nil
); end
end
# Create a Person associated with an Account.
sig {
params(account_id: String, params: T.any(::Stripe::V2::Core::Accounts::PersonService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::Core::Person)
}
def create(account_id, params = {}, opts = {}); end
# Delete a Person associated with an Account.
sig {
params(account_id: String, id: String, params: T.any(::Stripe::V2::Core::Accounts::PersonService::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::Core::Person)
}
def delete(account_id, id, params = {}, opts = {}); end
# Returns a list of Persons associated with an Account.
sig {
params(account_id: String, params: T.any(::Stripe::V2::Core::Accounts::PersonService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::ListObject)
}
def list(account_id, params = {}, opts = {}); end
# Retrieves a Person associated with an Account.
sig {
params(account_id: String, id: String, params: T.any(::Stripe::V2::Core::Accounts::PersonService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::Core::Person)
}
def retrieve(account_id, id, params = {}, opts = {}); end
# Updates a Person associated with an Account.
sig {
params(account_id: String, id: String, params: T.any(::Stripe::V2::Core::Accounts::PersonService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::Core::Person)
}
def update(account_id, id, params = {}, opts = {}); end
end
end
end
end
end
# typed: true
module Stripe
module V2
module Core
class AccountLinkService < StripeService
class CreateParams < Stripe::RequestParams
class UseCase < Stripe::RequestParams
class AccountOnboarding < Stripe::RequestParams
# Open Enum. A v2/account can be configured to enable certain functionality. The configuration param targets the v2/account_link to collect information for the specified v2/account configuration/s.
sig { returns(T::Array[String]) }
attr_accessor :configurations
# The URL the user will be redirected to if the AccountLink is expired, has been used, or is otherwise invalid. The URL you specify should attempt to generate a new AccountLink with the same parameters used to create the original AccountLink, then redirect the user to the new AccountLink’s URL so they can continue the flow. If a new AccountLink cannot be generated or the redirect fails you should display a useful error to the user. Please make sure to implement authentication before redirecting the user in case this URL is leaked to a third party.
sig { returns(String) }
attr_accessor :refresh_url
# The URL that the user will be redirected to upon completing the linked flow.
sig { returns(T.nilable(String)) }
attr_accessor :return_url
sig {
params(configurations: T::Array[String], refresh_url: String, return_url: T.nilable(String)).void
}
def initialize(configurations: nil, refresh_url: nil, return_url: nil); end
end
class AccountUpdate < Stripe::RequestParams
# Open Enum. A v2/account can be configured to enable certain functionality. The configuration param targets the v2/account_link to collect information for the specified v2/account configuration/s.
sig { returns(T::Array[String]) }
attr_accessor :configurations
# The URL the user will be redirected to if the AccountLink is expired, has been used, or is otherwise invalid. The URL you specify should attempt to generate a new AccountLink with the same parameters used to create the original AccountLink, then redirect the user to the new AccountLink’s URL so they can continue the flow. If a new AccountLink cannot be generated or the redirect fails you should display a useful error to the user. Please make sure to implement authentication before redirecting the user in case this URL is leaked to a third party.
sig { returns(String) }
attr_accessor :refresh_url
# The URL that the user will be redirected to upon completing the linked flow.
sig { returns(T.nilable(String)) }
attr_accessor :return_url
sig {
params(configurations: T::Array[String], refresh_url: String, return_url: T.nilable(String)).void
}
def initialize(configurations: nil, refresh_url: nil, return_url: nil); end
end
# Open Enum. The type of AccountLink the user is requesting.
sig { returns(String) }
attr_accessor :type
# Indicates that the AccountLink provided should onboard an account.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountLinkService::CreateParams::UseCase::AccountOnboarding))
}
attr_accessor :account_onboarding
# Indicates that the AccountLink provided should update a previously onboarded account.
sig {
returns(T.nilable(::Stripe::V2::Core::AccountLinkService::CreateParams::UseCase::AccountUpdate))
}
attr_accessor :account_update
sig {
params(type: String, account_onboarding: T.nilable(::Stripe::V2::Core::AccountLinkService::CreateParams::UseCase::AccountOnboarding), account_update: T.nilable(::Stripe::V2::Core::AccountLinkService::CreateParams::UseCase::AccountUpdate)).void
}
def initialize(type: nil, account_onboarding: nil, account_update: nil); end
end
# The ID of the Account to create link for.
sig { returns(String) }
attr_accessor :account
# The use case of the AccountLink.
sig { returns(::Stripe::V2::Core::AccountLinkService::CreateParams::UseCase) }
attr_accessor :use_case
sig {
params(account: String, use_case: ::Stripe::V2::Core::AccountLinkService::CreateParams::UseCase).void
}
def initialize(account: nil, use_case: nil); end
end
# Creates an AccountLink object that includes a single-use Stripe URL that the merchant can redirect their user to in order to take them to a Stripe-hosted application such as Recipient Onboarding.
sig {
params(params: T.any(::Stripe::V2::Core::AccountLinkService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::Core::AccountLink)
}
def create(params = {}, opts = {}); end
end
end
end
end
# typed: true
module Stripe
module V2
module Core
class EventDestinationService < StripeService
class CreateParams < Stripe::RequestParams
class AmazonEventbridge < Stripe::RequestParams
# The AWS account ID.
sig { returns(String) }
attr_accessor :aws_account_id
# The region of the AWS event source.
sig { returns(String) }
attr_accessor :aws_region
sig { params(aws_account_id: String, aws_region: String).void }
def initialize(aws_account_id: nil, aws_region: nil); end
end
class WebhookEndpoint < Stripe::RequestParams
# The URL of the webhook endpoint.
sig { returns(String) }
attr_accessor :url
sig { params(url: String).void }
def initialize(url: nil); end
end
# An optional description of what the event destination is used for.
sig { returns(T.nilable(String)) }
attr_accessor :description
# The list of events to enable for this endpoint.
sig { returns(T::Array[String]) }
attr_accessor :enabled_events
# Payload type of events being subscribed to.
sig { returns(String) }
attr_accessor :event_payload
# Where events should be routed from.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :events_from
# Additional fields to include in the response.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :include
# Metadata.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# Event destination name.
sig { returns(String) }
attr_accessor :name
# If using the snapshot event payload, the API version events are rendered as.
sig { returns(T.nilable(String)) }
attr_accessor :snapshot_api_version
# Event destination type.
sig { returns(String) }
attr_accessor :type
# Amazon EventBridge configuration.
sig {
returns(T.nilable(::Stripe::V2::Core::EventDestinationService::CreateParams::AmazonEventbridge))
}
attr_accessor :amazon_eventbridge
# Webhook endpoint configuration.
sig {
returns(T.nilable(::Stripe::V2::Core::EventDestinationService::CreateParams::WebhookEndpoint))
}
attr_accessor :webhook_endpoint
sig {
params(description: T.nilable(String), enabled_events: T::Array[String], event_payload: String, events_from: T.nilable(T::Array[String]), include: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, String]), name: String, snapshot_api_version: T.nilable(String), type: String, amazon_eventbridge: T.nilable(::Stripe::V2::Core::EventDestinationService::CreateParams::AmazonEventbridge), webhook_endpoint: T.nilable(::Stripe::V2::Core::EventDestinationService::CreateParams::WebhookEndpoint)).void
}
def initialize(
description: nil,
enabled_events: nil,
event_payload: nil,
events_from: nil,
include: nil,
metadata: nil,
name: nil,
snapshot_api_version: nil,
type: nil,
amazon_eventbridge: nil,
webhook_endpoint: nil
); end
end
class DeleteParams < Stripe::RequestParams; end
class DisableParams < Stripe::RequestParams; end
class EnableParams < Stripe::RequestParams; end
class ListParams < Stripe::RequestParams
# Additional fields to include in the response. Currently supports `webhook_endpoint.url`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :include
# The page size.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
sig { params(include: T.nilable(T::Array[String]), limit: T.nilable(Integer)).void }
def initialize(include: nil, limit: nil); end
end
class PingParams < Stripe::RequestParams; end
class RetrieveParams < Stripe::RequestParams
# Additional fields to include in the response.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :include
sig { params(include: T.nilable(T::Array[String])).void }
def initialize(include: nil); end
end
class UpdateParams < Stripe::RequestParams
class WebhookEndpoint < Stripe::RequestParams
# The URL of the webhook endpoint.
sig { returns(String) }
attr_accessor :url
sig { params(url: String).void }
def initialize(url: nil); end
end
# An optional description of what the event destination is used for.
sig { returns(T.nilable(String)) }
attr_accessor :description
# The list of events to enable for this endpoint.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :enabled_events
# Additional fields to include in the response. Currently supports `webhook_endpoint.url`.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :include
# Metadata.
sig { returns(T.nilable(T::Hash[String, T.nilable(String)])) }
attr_accessor :metadata
# Event destination name.
sig { returns(T.nilable(String)) }
attr_accessor :name
# Webhook endpoint configuration.
sig {
returns(T.nilable(::Stripe::V2::Core::EventDestinationService::UpdateParams::WebhookEndpoint))
}
attr_accessor :webhook_endpoint
sig {
params(description: T.nilable(String), enabled_events: T.nilable(T::Array[String]), include: T.nilable(T::Array[String]), metadata: T.nilable(T::Hash[String, T.nilable(String)]), name: T.nilable(String), webhook_endpoint: T.nilable(::Stripe::V2::Core::EventDestinationService::UpdateParams::WebhookEndpoint)).void
}
def initialize(
description: nil,
enabled_events: nil,
include: nil,
metadata: nil,
name: nil,
webhook_endpoint: nil
); end
end
# Create a new event destination.
sig {
params(params: T.any(::Stripe::V2::Core::EventDestinationService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::EventDestination)
}
def create(params = {}, opts = {}); end
# Delete an event destination.
sig {
params(id: String, params: T.any(::Stripe::V2::Core::EventDestinationService::DeleteParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::EventDestination)
}
def delete(id, params = {}, opts = {}); end
# Disable an event destination.
sig {
params(id: String, params: T.any(::Stripe::V2::Core::EventDestinationService::DisableParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::EventDestination)
}
def disable(id, params = {}, opts = {}); end
# Enable an event destination.
sig {
params(id: String, params: T.any(::Stripe::V2::Core::EventDestinationService::EnableParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::EventDestination)
}
def enable(id, params = {}, opts = {}); end
# Lists all event destinations.
sig {
params(params: T.any(::Stripe::V2::Core::EventDestinationService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::ListObject)
}
def list(params = {}, opts = {}); end
# Send a `ping` event to an event destination.
sig {
params(id: String, params: T.any(::Stripe::V2::Core::EventDestinationService::PingParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::Event)
}
def ping(id, params = {}, opts = {}); end
# Retrieves the details of an event destination.
sig {
params(id: String, params: T.any(::Stripe::V2::Core::EventDestinationService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::EventDestination)
}
def retrieve(id, params = {}, opts = {}); end
# Update the details of an event destination.
sig {
params(id: String, params: T.any(::Stripe::V2::Core::EventDestinationService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::EventDestination)
}
def update(id, params = {}, opts = {}); end
end
end
end
end
# typed: true
module Stripe
module V2
module Core
class EventService < StripeService
class ListParams < Stripe::RequestParams
# The page size.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Primary object ID used to retrieve related events.
#
# To avoid conflict with Ruby's ':object_id', this attribute has been renamed. If using a hash parameter map instead, please use the original name ':object_id' with NO trailing underscore as the provided param key.
sig { returns(String) }
attr_accessor :object_id_
sig { params(limit: T.nilable(Integer), object_id_: String).void }
def initialize(limit: nil, object_id_: nil); end
end
class RetrieveParams < Stripe::RequestParams; end
# List events, going back up to 30 days.
sig {
params(params: T.any(::Stripe::V2::Core::EventService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the details of an event.
sig {
params(id: String, params: T.any(::Stripe::V2::Core::EventService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::Event)
}
def retrieve(id, params = {}, opts = {}); end
end
end
end
end
# typed: true
module Stripe
module V2
module Core
class VaultService < StripeService
attr_reader :gb_bank_accounts
attr_reader :us_bank_accounts
end
end
end
end
# typed: true
module Stripe
module V2
module Core
module Vault
class GbBankAccountService < StripeService
class AcknowledgeConfirmationOfPayeeParams < Stripe::RequestParams; end
class ArchiveParams < Stripe::RequestParams; end
class CreateParams < Stripe::RequestParams
class ConfirmationOfPayee < Stripe::RequestParams
# The business type to be checked against. Legal entity information will be used if unspecified.
# Closed enum.
sig { returns(T.nilable(String)) }
attr_accessor :business_type
# User specifies whether Confirmation of Payee is automatically initiated when creating the bank account.
sig { returns(T::Boolean) }
attr_accessor :initiate
# The name to be checked against. Legal entity information will be used if unspecified.
sig { returns(T.nilable(String)) }
attr_accessor :name
sig {
params(business_type: T.nilable(String), initiate: T::Boolean, name: T.nilable(String)).void
}
def initialize(business_type: nil, initiate: nil, name: nil); end
end
# The Account Number of the bank account.
sig { returns(String) }
attr_accessor :account_number
# Closed Enum. The type of the bank account (checking or savings).
sig { returns(T.nilable(String)) }
attr_accessor :bank_account_type
# Whether or not to automatically perform Confirmation of Payee to verify the users information
# against what was provided by the bank. Doing so is required for all bank accounts not owned
# by you before making domestic UK OutboundPayments.
sig {
returns(T.nilable(::Stripe::V2::Core::Vault::GbBankAccountService::CreateParams::ConfirmationOfPayee))
}
attr_accessor :confirmation_of_payee
# The Sort Code of the bank account.
sig { returns(String) }
attr_accessor :sort_code
sig {
params(account_number: String, bank_account_type: T.nilable(String), confirmation_of_payee: T.nilable(::Stripe::V2::Core::Vault::GbBankAccountService::CreateParams::ConfirmationOfPayee), sort_code: String).void
}
def initialize(
account_number: nil,
bank_account_type: nil,
confirmation_of_payee: nil,
sort_code: nil
); end
end
class InitiateConfirmationOfPayeeParams < Stripe::RequestParams
# The business type to be checked against. Legal entity information will be used if unspecified.
sig { returns(T.nilable(String)) }
attr_accessor :business_type
# The name of the user to be checked against. Legal entity information will be used if unspecified.
sig { returns(T.nilable(String)) }
attr_accessor :name
sig { params(business_type: T.nilable(String), name: T.nilable(String)).void }
def initialize(business_type: nil, name: nil); end
end
class RetrieveParams < Stripe::RequestParams; end
# Confirm that you have received the result of the Confirmation of Payee request, and that you are okay with
# proceeding to pay out to this bank account despite the account not matching, partially matching, or the service
# being unavailable. Once you confirm this, you will be able to send OutboundPayments, but this may lead to
# funds being sent to the wrong account, which we might not be able to recover.
sig {
params(id: String, params: T.any(::Stripe::V2::Core::Vault::GbBankAccountService::AcknowledgeConfirmationOfPayeeParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::Core::Vault::GbBankAccount)
}
def acknowledge_confirmation_of_payee(id, params = {}, opts = {}); end
# Archive a GBBankAccount object. Archived GBBankAccount objects cannot be used as outbound destinations
# and will not appear in the outbound destination list.
sig {
params(id: String, params: T.any(::Stripe::V2::Core::Vault::GbBankAccountService::ArchiveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::Core::Vault::GbBankAccount)
}
def archive(id, params = {}, opts = {}); end
# Create a GB bank account.
sig {
params(params: T.any(::Stripe::V2::Core::Vault::GbBankAccountService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::Core::Vault::GbBankAccount)
}
def create(params = {}, opts = {}); end
# Initiate Confirmation of Payee (CoP) in order to verify that the owner of a UK bank account matches
# who you expect. This must be done on all UK bank accounts before sending domestic OutboundPayments. If
# the result is a partial match or a non match, explicit acknowledgement using AcknowledgeConfirmationOfPayee
# is required before sending funds.
sig {
params(id: String, params: T.any(::Stripe::V2::Core::Vault::GbBankAccountService::InitiateConfirmationOfPayeeParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::Core::Vault::GbBankAccount)
}
def initiate_confirmation_of_payee(id, params = {}, opts = {}); end
# Retrieve a GB bank account.
sig {
params(id: String, params: T.any(::Stripe::V2::Core::Vault::GbBankAccountService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::Core::Vault::GbBankAccount)
}
def retrieve(id, params = {}, opts = {}); end
end
end
end
end
end
# typed: true
module Stripe
module V2
module Core
module Vault
class UsBankAccountService < StripeService
class ArchiveParams < Stripe::RequestParams; end
class CreateParams < Stripe::RequestParams
# The account number of the bank account.
sig { returns(String) }
attr_accessor :account_number
# Closed Enum. The type of the bank account (checking or savings).
sig { returns(T.nilable(String)) }
attr_accessor :bank_account_type
# The fedwire routing number of the bank account. Note that certain banks have the same ACH and wire routing number.
sig { returns(T.nilable(String)) }
attr_accessor :fedwire_routing_number
# The ACH routing number of the bank account. Note that certain banks have the same ACH and wire routing number.
sig { returns(T.nilable(String)) }
attr_accessor :routing_number
sig {
params(account_number: String, bank_account_type: T.nilable(String), fedwire_routing_number: T.nilable(String), routing_number: T.nilable(String)).void
}
def initialize(
account_number: nil,
bank_account_type: nil,
fedwire_routing_number: nil,
routing_number: nil
); end
end
class RetrieveParams < Stripe::RequestParams; end
class UpdateParams < Stripe::RequestParams
# The bank account's fedwire routing number can be provided for update it was were empty previously.
sig { returns(T.nilable(String)) }
attr_accessor :fedwire_routing_number
# The bank account's ACH routing number can be provided for update if it was empty previously.
sig { returns(T.nilable(String)) }
attr_accessor :routing_number
sig {
params(fedwire_routing_number: T.nilable(String), routing_number: T.nilable(String)).void
}
def initialize(fedwire_routing_number: nil, routing_number: nil); end
end
# Archive a USBankAccount object. USBankAccount objects will not be automatically archived by Stripe.
# Archived USBankAccount objects cannot be used as outbound destinations
# and will not appear in the outbound destination list.
#
# ** raises ControlledByDashboardError
sig {
params(id: String, params: T.any(::Stripe::V2::Core::Vault::UsBankAccountService::ArchiveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::Core::Vault::UsBankAccount)
}
def archive(id, params = {}, opts = {}); end
# Create a USBankAccount object.
#
# ** raises BlockedByStripeError
# ** raises InvalidPaymentMethodError
# ** raises QuotaExceededError
sig {
params(params: T.any(::Stripe::V2::Core::Vault::UsBankAccountService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::Core::Vault::UsBankAccount)
}
def create(params = {}, opts = {}); end
# Retrieve a USBankAccount object.
sig {
params(id: String, params: T.any(::Stripe::V2::Core::Vault::UsBankAccountService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::Core::Vault::UsBankAccount)
}
def retrieve(id, params = {}, opts = {}); end
# Update a USBankAccount object. This is limited to supplying a previously empty routing_number field.
#
# ** raises BlockedByStripeError
# ** raises InvalidPaymentMethodError
# ** raises QuotaExceededError
sig {
params(id: String, params: T.any(::Stripe::V2::Core::Vault::UsBankAccountService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::Core::Vault::UsBankAccount)
}
def update(id, params = {}, opts = {}); end
end
end
end
end
end
# typed: true
module Stripe
module V2
class MoneyManagementService < StripeService
attr_reader :adjustments
attr_reader :financial_accounts
attr_reader :financial_addresses
attr_reader :inbound_transfers
attr_reader :outbound_payments
attr_reader :outbound_payment_quotes
attr_reader :outbound_transfers
attr_reader :outbound_setup_intents
attr_reader :payout_methods
attr_reader :payout_methods_bank_account_spec
attr_reader :received_credits
attr_reader :received_debits
attr_reader :transactions
attr_reader :transaction_entries
end
end
end
# typed: true
module Stripe
module V2
module MoneyManagement
class AdjustmentService < StripeService
class ListParams < Stripe::RequestParams
# Filter for Adjustments linked to a Flow.
sig { returns(T.nilable(String)) }
attr_accessor :adjusted_flow
# Filter for objects created at the specified timestamp.
# Must be an RFC 3339 date & time value, for example: 2022-09-18T13:22:00Z.
sig { returns(T.nilable(String)) }
attr_accessor :created
# Filter for objects created after the specified timestamp.
# Must be an RFC 3339 date & time value, for example: 2022-09-18T13:22:00Z.
sig { returns(T.nilable(String)) }
attr_accessor :created_gt
# Filter for objects created on or after the specified timestamp.
# Must be an RFC 3339 date & time value, for example: 2022-09-18T13:22:00Z.
sig { returns(T.nilable(String)) }
attr_accessor :created_gte
# Filter for objects created before the specified timestamp.
# Must be an RFC 3339 date & time value, for example: 2022-09-18T13:22:00Z.
sig { returns(T.nilable(String)) }
attr_accessor :created_lt
# Filter for objects created on or before the specified timestamp.
# Must be an RFC 3339 date & time value, for example: 2022-09-18T13:22:00Z.
sig { returns(T.nilable(String)) }
attr_accessor :created_lte
# The page limit.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
sig {
params(adjusted_flow: T.nilable(String), created: T.nilable(String), created_gt: T.nilable(String), created_gte: T.nilable(String), created_lt: T.nilable(String), created_lte: T.nilable(String), limit: T.nilable(Integer)).void
}
def initialize(
adjusted_flow: nil,
created: nil,
created_gt: nil,
created_gte: nil,
created_lt: nil,
created_lte: nil,
limit: nil
); end
end
class RetrieveParams < Stripe::RequestParams; end
# Returns a list of Adjustments that match the provided filters.
sig {
params(params: T.any(::Stripe::V2::MoneyManagement::AdjustmentService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the details of an Adjustment by ID.
sig {
params(id: String, params: T.any(::Stripe::V2::MoneyManagement::AdjustmentService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::MoneyManagement::Adjustment)
}
def retrieve(id, params = {}, opts = {}); end
end
end
end
end
# typed: true
module Stripe
module V2
module MoneyManagement
class FinancialAccountService < StripeService
class ListParams < Stripe::RequestParams
# The page limit.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
sig { params(limit: T.nilable(Integer)).void }
def initialize(limit: nil); end
end
class RetrieveParams < Stripe::RequestParams; end
# Lists FinancialAccounts in this compartment.
sig {
params(params: T.any(::Stripe::V2::MoneyManagement::FinancialAccountService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the details of an existing FinancialAccount.
sig {
params(id: String, params: T.any(::Stripe::V2::MoneyManagement::FinancialAccountService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::MoneyManagement::FinancialAccount)
}
def retrieve(id, params = {}, opts = {}); end
end
end
end
end
# typed: true
module Stripe
module V2
module MoneyManagement
class FinancialAddressService < StripeService
class CreateParams < Stripe::RequestParams
# Open Enum. The currency the FinancialAddress should support. Currently, only the `usd` and `gbp` values are supported.
sig { returns(String) }
attr_accessor :currency
# The ID of the FinancialAccount the new FinancialAddress should be associated with.
sig { returns(String) }
attr_accessor :financial_account
sig { params(currency: String, financial_account: String).void }
def initialize(currency: nil, financial_account: nil); end
end
class ListParams < Stripe::RequestParams
# The ID of the FinancialAccount for which FinancialAddresses are to be returned.
sig { returns(T.nilable(String)) }
attr_accessor :financial_account
# Open Enum. A list of fields to reveal in the FinancialAddresses returned.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :include
# The page limit.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
sig {
params(financial_account: T.nilable(String), include: T.nilable(T::Array[String]), limit: T.nilable(Integer)).void
}
def initialize(financial_account: nil, include: nil, limit: nil); end
end
class RetrieveParams < Stripe::RequestParams
# Open Enum. A list of fields to reveal in the FinancialAddresses returned.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :include
sig { params(include: T.nilable(T::Array[String])).void }
def initialize(include: nil); end
end
# Create a new FinancialAddress for a FinancialAccount.
#
# ** raises FinancialAccountNotOpenError
sig {
params(params: T.any(::Stripe::V2::MoneyManagement::FinancialAddressService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::MoneyManagement::FinancialAddress)
}
def create(params = {}, opts = {}); end
# List all FinancialAddresses for a FinancialAccount.
sig {
params(params: T.any(::Stripe::V2::MoneyManagement::FinancialAddressService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieve a FinancialAddress. By default, the FinancialAddress will be returned in its unexpanded state, revealing only the last 4 digits of the account number.
sig {
params(id: String, params: T.any(::Stripe::V2::MoneyManagement::FinancialAddressService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::MoneyManagement::FinancialAddress)
}
def retrieve(id, params = {}, opts = {}); end
end
end
end
end
# typed: true
module Stripe
module V2
module MoneyManagement
class InboundTransferService < StripeService
class CreateParams < Stripe::RequestParams
class From < Stripe::RequestParams
# An optional currency field used to specify which currency is debited from the Payment Method.
# Since many Payment Methods support only one currency, this field is optional.
sig { returns(T.nilable(String)) }
attr_accessor :currency
# ID of the Payment Method using which IBT will be made.
sig { returns(String) }
attr_accessor :payment_method
sig { params(currency: T.nilable(String), payment_method: String).void }
def initialize(currency: nil, payment_method: nil); end
end
class To < Stripe::RequestParams
# The currency in which funds will land in.
sig { returns(String) }
attr_accessor :currency
# The FinancialAccount that funds will land in.
sig { returns(String) }
attr_accessor :financial_account
sig { params(currency: String, financial_account: String).void }
def initialize(currency: nil, financial_account: nil); end
end
# The amount, in specified currency, by which the FinancialAccount balance will increase due to the InboundTransfer.
sig { returns(Stripe::V2::Amount) }
attr_accessor :amount
# An optional, freeform description field intended to store metadata.
sig { returns(T.nilable(String)) }
attr_accessor :description
# Object containing details about where the funds will originate from.
sig { returns(::Stripe::V2::MoneyManagement::InboundTransferService::CreateParams::From) }
attr_accessor :from
# Object containing details about where the funds will land.
sig { returns(::Stripe::V2::MoneyManagement::InboundTransferService::CreateParams::To) }
attr_accessor :to
sig {
params(amount: Stripe::V2::Amount, description: T.nilable(String), from: ::Stripe::V2::MoneyManagement::InboundTransferService::CreateParams::From, to: ::Stripe::V2::MoneyManagement::InboundTransferService::CreateParams::To).void
}
def initialize(amount: nil, description: nil, from: nil, to: nil); end
end
class ListParams < Stripe::RequestParams
# Filter for objects created at the specified timestamp.
# Must be an RFC 3339 date & time value, for example: 2022-09-18T13:22:00Z.
sig { returns(T.nilable(String)) }
attr_accessor :created
# Filter for objects created after the specified timestamp.
# Must be an RFC 3339 date & time value, for example: 2022-09-18T13:22:00Z.
sig { returns(T.nilable(String)) }
attr_accessor :created_gt
# Filter for objects created on or after the specified timestamp.
# Must be an RFC 3339 date & time value, for example: 2022-09-18T13:22:00Z.
sig { returns(T.nilable(String)) }
attr_accessor :created_gte
# Filter for objects created before the specified timestamp.
# Must be an RFC 3339 date & time value, for example: 2022-09-18T13:22:00Z.
sig { returns(T.nilable(String)) }
attr_accessor :created_lt
# Filter for objects created on or before the specified timestamp.
# Must be an RFC 3339 date & time value, for example: 2022-09-18T13:22:00Z.
sig { returns(T.nilable(String)) }
attr_accessor :created_lte
# The page limit.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
sig {
params(created: T.nilable(String), created_gt: T.nilable(String), created_gte: T.nilable(String), created_lt: T.nilable(String), created_lte: T.nilable(String), limit: T.nilable(Integer)).void
}
def initialize(
created: nil,
created_gt: nil,
created_gte: nil,
created_lt: nil,
created_lte: nil,
limit: nil
); end
end
class RetrieveParams < Stripe::RequestParams; end
# InboundTransfers APIs are used to create, retrieve or list InboundTransfers.
#
# ** raises BlockedByStripeError
sig {
params(params: T.any(::Stripe::V2::MoneyManagement::InboundTransferService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::MoneyManagement::InboundTransfer)
}
def create(params = {}, opts = {}); end
# Retrieves a list of InboundTransfers.
sig {
params(params: T.any(::Stripe::V2::MoneyManagement::InboundTransferService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieve an InboundTransfer by ID.
sig {
params(id: String, params: T.any(::Stripe::V2::MoneyManagement::InboundTransferService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::MoneyManagement::InboundTransfer)
}
def retrieve(id, params = {}, opts = {}); end
end
end
end
end
# typed: true
module Stripe
module V2
module MoneyManagement
class OutboundPaymentService < StripeService
class CancelParams < Stripe::RequestParams; end
class CreateParams < Stripe::RequestParams
class DeliveryOptions < Stripe::RequestParams
# Open Enum. Method for bank account.
sig { returns(T.nilable(String)) }
attr_accessor :bank_account
sig { params(bank_account: T.nilable(String)).void }
def initialize(bank_account: nil); end
end
class From < Stripe::RequestParams
# Describes the FinancialAmount's currency drawn from.
sig { returns(String) }
attr_accessor :currency
# The FinancialAccount that funds were pulled from.
sig { returns(String) }
attr_accessor :financial_account
sig { params(currency: String, financial_account: String).void }
def initialize(currency: nil, financial_account: nil); end
end
class RecipientNotification < Stripe::RequestParams
# Closed Enum. Configuration option to enable or disable notifications to recipients.
# Do not send notifications when setting is NONE. Default to account setting when setting is CONFIGURED or not set.
sig { returns(String) }
attr_accessor :setting
sig { params(setting: String).void }
def initialize(setting: nil); end
end
class To < Stripe::RequestParams
# Describes the currency to send to the recipient.
# If included, this currency must match a currency supported by the destination.
# Can be omitted in the following cases:
# - destination only supports one currency
# - destination supports multiple currencies and one of the currencies matches the FA currency
# - destination supports multiple currencies and one of the currencies matches the presentment currency
# Note - when both FA currency and presentment currency are supported, we pick the FA currency to minimize FX.
sig { returns(T.nilable(String)) }
attr_accessor :currency
# The payout method which the OutboundPayment uses to send payout.
sig { returns(T.nilable(String)) }
attr_accessor :payout_method
# To which account the OutboundPayment is sent.
sig { returns(String) }
attr_accessor :recipient
sig {
params(currency: T.nilable(String), payout_method: T.nilable(String), recipient: String).void
}
def initialize(currency: nil, payout_method: nil, recipient: nil); end
end
# The "presentment amount" to be sent to the recipient.
sig { returns(Stripe::V2::Amount) }
attr_accessor :amount
# Delivery options to be used to send the OutboundPayment.
sig {
returns(T.nilable(::Stripe::V2::MoneyManagement::OutboundPaymentService::CreateParams::DeliveryOptions))
}
attr_accessor :delivery_options
# An arbitrary string attached to the OutboundPayment. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# From which FinancialAccount and BalanceType to pull funds from.
sig { returns(::Stripe::V2::MoneyManagement::OutboundPaymentService::CreateParams::From) }
attr_accessor :from
# Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# The quote for this OutboundPayment. Only required for countries with regulatory mandates to display fee estimates before OutboundPayment creation.
sig { returns(T.nilable(String)) }
attr_accessor :outbound_payment_quote
# Details about the notification settings for the OutboundPayment recipient.
sig {
returns(T.nilable(::Stripe::V2::MoneyManagement::OutboundPaymentService::CreateParams::RecipientNotification))
}
attr_accessor :recipient_notification
# To which payout method to send the OutboundPayment.
sig { returns(::Stripe::V2::MoneyManagement::OutboundPaymentService::CreateParams::To) }
attr_accessor :to
sig {
params(amount: Stripe::V2::Amount, delivery_options: T.nilable(::Stripe::V2::MoneyManagement::OutboundPaymentService::CreateParams::DeliveryOptions), description: T.nilable(String), from: ::Stripe::V2::MoneyManagement::OutboundPaymentService::CreateParams::From, metadata: T.nilable(T::Hash[String, String]), outbound_payment_quote: T.nilable(String), recipient_notification: T.nilable(::Stripe::V2::MoneyManagement::OutboundPaymentService::CreateParams::RecipientNotification), to: ::Stripe::V2::MoneyManagement::OutboundPaymentService::CreateParams::To).void
}
def initialize(
amount: nil,
delivery_options: nil,
description: nil,
from: nil,
metadata: nil,
outbound_payment_quote: nil,
recipient_notification: nil,
to: nil
); end
end
class ListParams < Stripe::RequestParams
# Filter for objects created at the specified timestamp.
# Must be an RFC 3339 date & time value, for example: 2022-09-18T13:22:00Z.
sig { returns(T.nilable(String)) }
attr_accessor :created
# Filter for objects created after the specified timestamp.
# Must be an RFC 3339 date & time value, for example: 2022-09-18T13:22:00Z.
sig { returns(T.nilable(String)) }
attr_accessor :created_gt
# Filter for objects created on or after the specified timestamp.
# Must be an RFC 3339 date & time value, for example: 2022-09-18T13:22:00Z.
sig { returns(T.nilable(String)) }
attr_accessor :created_gte
# Filter for objects created before the specified timestamp.
# Must be an RFC 3339 date & time value, for example: 2022-09-18T13:22:00Z.
sig { returns(T.nilable(String)) }
attr_accessor :created_lt
# Filter for objects created on or before the specified timestamp.
# Must be an RFC 3339 date & time value, for example: 2022-09-18T13:22:00Z.
sig { returns(T.nilable(String)) }
attr_accessor :created_lte
# The maximum number of results to return.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Only return OutboundPayments sent to this recipient.
sig { returns(T.nilable(String)) }
attr_accessor :recipient
# Closed Enum. Only return OutboundPayments with this status.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :status
sig {
params(created: T.nilable(String), created_gt: T.nilable(String), created_gte: T.nilable(String), created_lt: T.nilable(String), created_lte: T.nilable(String), limit: T.nilable(Integer), recipient: T.nilable(String), status: T.nilable(T::Array[String])).void
}
def initialize(
created: nil,
created_gt: nil,
created_gte: nil,
created_lt: nil,
created_lte: nil,
limit: nil,
recipient: nil,
status: nil
); end
end
class RetrieveParams < Stripe::RequestParams; end
# Cancels an OutboundPayment. Only processing OutboundPayments can be canceled.
#
# ** raises AlreadyCanceledError
# ** raises NotCancelableError
sig {
params(id: String, params: T.any(::Stripe::V2::MoneyManagement::OutboundPaymentService::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::MoneyManagement::OutboundPayment)
}
def cancel(id, params = {}, opts = {}); end
# Creates an OutboundPayment.
#
# ** raises InsufficientFundsError
# ** raises QuotaExceededError
# ** raises RecipientNotNotifiableError
# ** raises FeatureNotEnabledError
sig {
params(params: T.any(::Stripe::V2::MoneyManagement::OutboundPaymentService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::MoneyManagement::OutboundPayment)
}
def create(params = {}, opts = {}); end
# Returns a list of OutboundPayments that match the provided filters.
sig {
params(params: T.any(::Stripe::V2::MoneyManagement::OutboundPaymentService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the details of an existing OutboundPayment by passing the unique OutboundPayment ID from either the OutboundPayment create or list response.
sig {
params(id: String, params: T.any(::Stripe::V2::MoneyManagement::OutboundPaymentService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::MoneyManagement::OutboundPayment)
}
def retrieve(id, params = {}, opts = {}); end
end
end
end
end
# typed: true
module Stripe
module V2
module MoneyManagement
class OutboundPaymentQuoteService < StripeService
class CreateParams < Stripe::RequestParams
class DeliveryOptions < Stripe::RequestParams
# Open Enum. Method for bank account.
sig { returns(T.nilable(String)) }
attr_accessor :bank_account
sig { params(bank_account: T.nilable(String)).void }
def initialize(bank_account: nil); end
end
class From < Stripe::RequestParams
# Describes the FinancialAccount's currency drawn from.
sig { returns(String) }
attr_accessor :currency
# The FinancialAccount that funds were pulled from.
sig { returns(String) }
attr_accessor :financial_account
sig { params(currency: String, financial_account: String).void }
def initialize(currency: nil, financial_account: nil); end
end
class To < Stripe::RequestParams
# Describes the currency to send to the recipient.
# If included, this currency must match a currency supported by the destination.
# Can be omitted in the following cases:
# - destination only supports one currency
# - destination supports multiple currencies and one of the currencies matches the FA currency
# - destination supports multiple currencies and one of the currencies matches the presentment currency
# Note - when both FA currency and presentment currency are supported, we pick the FA currency to minimize FX.
sig { returns(T.nilable(String)) }
attr_accessor :currency
# The payout method which the OutboundPayment uses to send payout.
sig { returns(T.nilable(String)) }
attr_accessor :payout_method
# To which account the OutboundPayment is sent.
sig { returns(String) }
attr_accessor :recipient
sig {
params(currency: T.nilable(String), payout_method: T.nilable(String), recipient: String).void
}
def initialize(currency: nil, payout_method: nil, recipient: nil); end
end
# The "presentment amount" to be sent to the recipient.
sig { returns(Stripe::V2::Amount) }
attr_accessor :amount
# Method to be used to send the OutboundPayment.
sig {
returns(T.nilable(::Stripe::V2::MoneyManagement::OutboundPaymentQuoteService::CreateParams::DeliveryOptions))
}
attr_accessor :delivery_options
# Request details about the sender of an OutboundPaymentQuote.
sig {
returns(::Stripe::V2::MoneyManagement::OutboundPaymentQuoteService::CreateParams::From)
}
attr_accessor :from
# Request details about the recipient of an OutboundPaymentQuote.
sig {
returns(::Stripe::V2::MoneyManagement::OutboundPaymentQuoteService::CreateParams::To)
}
attr_accessor :to
sig {
params(amount: Stripe::V2::Amount, delivery_options: T.nilable(::Stripe::V2::MoneyManagement::OutboundPaymentQuoteService::CreateParams::DeliveryOptions), from: ::Stripe::V2::MoneyManagement::OutboundPaymentQuoteService::CreateParams::From, to: ::Stripe::V2::MoneyManagement::OutboundPaymentQuoteService::CreateParams::To).void
}
def initialize(amount: nil, delivery_options: nil, from: nil, to: nil); end
end
class RetrieveParams < Stripe::RequestParams; end
# Creates an OutboundPaymentQuote usable in an OutboundPayment.
#
# ** raises FeatureNotEnabledError
sig {
params(params: T.any(::Stripe::V2::MoneyManagement::OutboundPaymentQuoteService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::MoneyManagement::OutboundPaymentQuote)
}
def create(params = {}, opts = {}); end
# Retrieves the details of an existing OutboundPaymentQuote by passing the unique OutboundPaymentQuote ID.
sig {
params(id: String, params: T.any(::Stripe::V2::MoneyManagement::OutboundPaymentQuoteService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::MoneyManagement::OutboundPaymentQuote)
}
def retrieve(id, params = {}, opts = {}); end
end
end
end
end
# typed: true
module Stripe
module V2
module MoneyManagement
class OutboundTransferService < StripeService
class CancelParams < Stripe::RequestParams; end
class CreateParams < Stripe::RequestParams
class DeliveryOptions < Stripe::RequestParams
# Open Enum. Method for bank account.
sig { returns(T.nilable(String)) }
attr_accessor :bank_account
sig { params(bank_account: T.nilable(String)).void }
def initialize(bank_account: nil); end
end
class From < Stripe::RequestParams
# Describes the FinancialAmount's currency drawn from.
sig { returns(String) }
attr_accessor :currency
# The FinancialAccount that funds were pulled from.
sig { returns(String) }
attr_accessor :financial_account
sig { params(currency: String, financial_account: String).void }
def initialize(currency: nil, financial_account: nil); end
end
class To < Stripe::RequestParams
# Describes the currency to send to the recipient.
# If included, this currency must match a currency supported by the destination.
# Can be omitted in the following cases:
# - destination only supports one currency
# - destination supports multiple currencies and one of the currencies matches the FA currency
# - destination supports multiple currencies and one of the currencies matches the presentment currency
# Note - when both FA currency and presentment currency are supported, we pick the FA currency to minimize FX.
sig { returns(T.nilable(String)) }
attr_accessor :currency
# The payout method which the OutboundTransfer uses to send payout.
sig { returns(String) }
attr_accessor :payout_method
sig { params(currency: T.nilable(String), payout_method: String).void }
def initialize(currency: nil, payout_method: nil); end
end
# The "presentment amount" for the OutboundPayment.
sig { returns(Stripe::V2::Amount) }
attr_accessor :amount
# Delivery options to be used to send the OutboundTransfer.
sig {
returns(T.nilable(::Stripe::V2::MoneyManagement::OutboundTransferService::CreateParams::DeliveryOptions))
}
attr_accessor :delivery_options
# An arbitrary string attached to the OutboundTransfer. Often useful for displaying to users.
sig { returns(T.nilable(String)) }
attr_accessor :description
# The FinancialAccount to pull funds from.
sig {
returns(::Stripe::V2::MoneyManagement::OutboundTransferService::CreateParams::From)
}
attr_accessor :from
# Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
sig { returns(T.nilable(T::Hash[String, String])) }
attr_accessor :metadata
# To which payout method to send the OutboundTransfer.
sig { returns(::Stripe::V2::MoneyManagement::OutboundTransferService::CreateParams::To) }
attr_accessor :to
sig {
params(amount: Stripe::V2::Amount, delivery_options: T.nilable(::Stripe::V2::MoneyManagement::OutboundTransferService::CreateParams::DeliveryOptions), description: T.nilable(String), from: ::Stripe::V2::MoneyManagement::OutboundTransferService::CreateParams::From, metadata: T.nilable(T::Hash[String, String]), to: ::Stripe::V2::MoneyManagement::OutboundTransferService::CreateParams::To).void
}
def initialize(
amount: nil,
delivery_options: nil,
description: nil,
from: nil,
metadata: nil,
to: nil
); end
end
class ListParams < Stripe::RequestParams
# Filter for objects created at the specified timestamp.
# Must be an RFC 3339 date & time value, for example: 2022-09-18T13:22:00Z.
sig { returns(T.nilable(String)) }
attr_accessor :created
# Filter for objects created after the specified timestamp.
# Must be an RFC 3339 date & time value, for example: 2022-09-18T13:22:00Z.
sig { returns(T.nilable(String)) }
attr_accessor :created_gt
# Filter for objects created on or after the specified timestamp.
# Must be an RFC 3339 date & time value, for example: 2022-09-18T13:22:00Z.
sig { returns(T.nilable(String)) }
attr_accessor :created_gte
# Filter for objects created before the specified timestamp.
# Must be an RFC 3339 date & time value, for example: 2022-09-18T13:22:00Z.
sig { returns(T.nilable(String)) }
attr_accessor :created_lt
# Filter for objects created on or before the specified timestamp.
# Must be an RFC 3339 date & time value, for example: 2022-09-18T13:22:00Z.
sig { returns(T.nilable(String)) }
attr_accessor :created_lte
# The maximum number of results to return.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Closed Enum. Only return OutboundTransfers with this status.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :status
sig {
params(created: T.nilable(String), created_gt: T.nilable(String), created_gte: T.nilable(String), created_lt: T.nilable(String), created_lte: T.nilable(String), limit: T.nilable(Integer), status: T.nilable(T::Array[String])).void
}
def initialize(
created: nil,
created_gt: nil,
created_gte: nil,
created_lt: nil,
created_lte: nil,
limit: nil,
status: nil
); end
end
class RetrieveParams < Stripe::RequestParams; end
# Cancels an OutboundTransfer. Only processing OutboundTransfers can be canceled.
#
# ** raises AlreadyCanceledError
# ** raises NotCancelableError
sig {
params(id: String, params: T.any(::Stripe::V2::MoneyManagement::OutboundTransferService::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::MoneyManagement::OutboundTransfer)
}
def cancel(id, params = {}, opts = {}); end
# Creates an OutboundTransfer.
#
# ** raises InsufficientFundsError
sig {
params(params: T.any(::Stripe::V2::MoneyManagement::OutboundTransferService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::MoneyManagement::OutboundTransfer)
}
def create(params = {}, opts = {}); end
# Returns a list of OutboundTransfers that match the provided filters.
sig {
params(params: T.any(::Stripe::V2::MoneyManagement::OutboundTransferService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the details of an existing OutboundTransfer by passing the unique OutboundTransfer ID from either the OutboundPayment create or list response.
sig {
params(id: String, params: T.any(::Stripe::V2::MoneyManagement::OutboundTransferService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::MoneyManagement::OutboundTransfer)
}
def retrieve(id, params = {}, opts = {}); end
end
end
end
end
# typed: true
module Stripe
module V2
module MoneyManagement
class OutboundSetupIntentService < StripeService
class CancelParams < Stripe::RequestParams; end
class CreateParams < Stripe::RequestParams
class PayoutMethodData < Stripe::RequestParams
class BankAccount < Stripe::RequestParams
# The account number or IBAN of the bank account.
sig { returns(String) }
attr_accessor :account_number
# Closed Enum. The type of the bank account (checking or savings).
sig { returns(T.nilable(String)) }
attr_accessor :bank_account_type
# The branch number of the bank account, if present.
sig { returns(T.nilable(String)) }
attr_accessor :branch_number
# The country code of the bank account.
sig { returns(String) }
attr_accessor :country
# The routing number of the bank account, if present.
sig { returns(T.nilable(String)) }
attr_accessor :routing_number
# The swift code of the bank account, if present.
sig { returns(T.nilable(String)) }
attr_accessor :swift_code
sig {
params(account_number: String, bank_account_type: T.nilable(String), branch_number: T.nilable(String), country: String, routing_number: T.nilable(String), swift_code: T.nilable(String)).void
}
def initialize(
account_number: nil,
bank_account_type: nil,
branch_number: nil,
country: nil,
routing_number: nil,
swift_code: nil
); end
end
class Card < Stripe::RequestParams
# The expiration month of the card.
sig { returns(String) }
attr_accessor :exp_month
# The expiration year of the card.
sig { returns(String) }
attr_accessor :exp_year
# The card number.
sig { returns(String) }
attr_accessor :number
sig { params(exp_month: String, exp_year: String, number: String).void }
def initialize(exp_month: nil, exp_year: nil, number: nil); end
end
# Closed Enum. The type of payout method to be created.
sig { returns(String) }
attr_accessor :type
# The type specific details of the bank account payout method.
sig {
returns(T.nilable(::Stripe::V2::MoneyManagement::OutboundSetupIntentService::CreateParams::PayoutMethodData::BankAccount))
}
attr_accessor :bank_account
# The type specific details of the card payout method.
sig {
returns(T.nilable(::Stripe::V2::MoneyManagement::OutboundSetupIntentService::CreateParams::PayoutMethodData::Card))
}
attr_accessor :card
sig {
params(type: String, bank_account: T.nilable(::Stripe::V2::MoneyManagement::OutboundSetupIntentService::CreateParams::PayoutMethodData::BankAccount), card: T.nilable(::Stripe::V2::MoneyManagement::OutboundSetupIntentService::CreateParams::PayoutMethodData::Card)).void
}
def initialize(type: nil, bank_account: nil, card: nil); end
end
# If provided, the existing payout method resource to link to this setup intent.
# Any payout_method_data provided is used to update information on this linked payout method resource.
sig { returns(T.nilable(String)) }
attr_accessor :payout_method
# If no payout_method provided, used to create the underlying credential that is set up for outbound money movement.
# If a payout_method provided, used to update data on the credential linked to this setup intent.
sig {
returns(T.nilable(::Stripe::V2::MoneyManagement::OutboundSetupIntentService::CreateParams::PayoutMethodData))
}
attr_accessor :payout_method_data
# Specify which type of outbound money movement this credential should be set up for (payment | transfer).
# If not provided, defaults to payment.
sig { returns(T.nilable(String)) }
attr_accessor :usage_intent
sig {
params(payout_method: T.nilable(String), payout_method_data: T.nilable(::Stripe::V2::MoneyManagement::OutboundSetupIntentService::CreateParams::PayoutMethodData), usage_intent: T.nilable(String)).void
}
def initialize(payout_method: nil, payout_method_data: nil, usage_intent: nil); end
end
class ListParams < Stripe::RequestParams
# The page size.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
sig { params(limit: T.nilable(Integer)).void }
def initialize(limit: nil); end
end
class RetrieveParams < Stripe::RequestParams; end
class UpdateParams < Stripe::RequestParams
class PayoutMethodData < Stripe::RequestParams
class BankAccount < Stripe::RequestParams
# The account number or IBAN of the bank account.
sig { returns(String) }
attr_accessor :account_number
# Closed Enum. The type of the bank account (checking or savings).
sig { returns(T.nilable(String)) }
attr_accessor :bank_account_type
# The branch number of the bank account, if present.
sig { returns(T.nilable(String)) }
attr_accessor :branch_number
# The country code of the bank account.
sig { returns(String) }
attr_accessor :country
# The routing number of the bank account, if present.
sig { returns(T.nilable(String)) }
attr_accessor :routing_number
# The swift code of the bank account, if present.
sig { returns(T.nilable(String)) }
attr_accessor :swift_code
sig {
params(account_number: String, bank_account_type: T.nilable(String), branch_number: T.nilable(String), country: String, routing_number: T.nilable(String), swift_code: T.nilable(String)).void
}
def initialize(
account_number: nil,
bank_account_type: nil,
branch_number: nil,
country: nil,
routing_number: nil,
swift_code: nil
); end
end
class Card < Stripe::RequestParams
# The expiration month of the card.
sig { returns(T.nilable(String)) }
attr_accessor :exp_month
# The expiration year of the card.
sig { returns(T.nilable(String)) }
attr_accessor :exp_year
# The card number. This can only be passed when creating a new credential on an outbound setup intent in the requires_payout_method state.
sig { returns(T.nilable(String)) }
attr_accessor :number
sig {
params(exp_month: T.nilable(String), exp_year: T.nilable(String), number: T.nilable(String)).void
}
def initialize(exp_month: nil, exp_year: nil, number: nil); end
end
# Closed Enum. The type of payout method to be created/updated.
sig { returns(String) }
attr_accessor :type
# The type specific details of the bank account payout method.
sig {
returns(T.nilable(::Stripe::V2::MoneyManagement::OutboundSetupIntentService::UpdateParams::PayoutMethodData::BankAccount))
}
attr_accessor :bank_account
# The type specific details of the card payout method.
sig {
returns(T.nilable(::Stripe::V2::MoneyManagement::OutboundSetupIntentService::UpdateParams::PayoutMethodData::Card))
}
attr_accessor :card
sig {
params(type: String, bank_account: T.nilable(::Stripe::V2::MoneyManagement::OutboundSetupIntentService::UpdateParams::PayoutMethodData::BankAccount), card: T.nilable(::Stripe::V2::MoneyManagement::OutboundSetupIntentService::UpdateParams::PayoutMethodData::Card)).void
}
def initialize(type: nil, bank_account: nil, card: nil); end
end
# If provided, the existing payout method resource to link to this outbound setup intent.
sig { returns(T.nilable(String)) }
attr_accessor :payout_method
# If no payout_method provided, used to create the underlying credential that is set up for outbound money movement.
# If a payout_method provided, used to update data on the credential linked to this setup intent.
sig {
returns(T.nilable(::Stripe::V2::MoneyManagement::OutboundSetupIntentService::UpdateParams::PayoutMethodData))
}
attr_accessor :payout_method_data
sig {
params(payout_method: T.nilable(String), payout_method_data: T.nilable(::Stripe::V2::MoneyManagement::OutboundSetupIntentService::UpdateParams::PayoutMethodData)).void
}
def initialize(payout_method: nil, payout_method_data: nil); end
end
# Cancel an OutboundSetupIntent object.
sig {
params(id: String, params: T.any(::Stripe::V2::MoneyManagement::OutboundSetupIntentService::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::MoneyManagement::OutboundSetupIntent)
}
def cancel(id, params = {}, opts = {}); end
# Create an OutboundSetupIntent object.
#
# ** raises BlockedByStripeError
# ** raises InvalidPayoutMethodError
# ** raises QuotaExceededError
sig {
params(params: T.any(::Stripe::V2::MoneyManagement::OutboundSetupIntentService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::MoneyManagement::OutboundSetupIntent)
}
def create(params = {}, opts = {}); end
# List the OutboundSetupIntent objects.
sig {
params(params: T.any(::Stripe::V2::MoneyManagement::OutboundSetupIntentService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieve an OutboundSetupIntent object.
sig {
params(id: String, params: T.any(::Stripe::V2::MoneyManagement::OutboundSetupIntentService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::MoneyManagement::OutboundSetupIntent)
}
def retrieve(id, params = {}, opts = {}); end
# Update an OutboundSetupIntent object.
#
# ** raises QuotaExceededError
# ** raises BlockedByStripeError
# ** raises InvalidPayoutMethodError
sig {
params(id: String, params: T.any(::Stripe::V2::MoneyManagement::OutboundSetupIntentService::UpdateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::MoneyManagement::OutboundSetupIntent)
}
def update(id, params = {}, opts = {}); end
end
end
end
end
# typed: true
module Stripe
module V2
module MoneyManagement
class PayoutMethodService < StripeService
class ArchiveParams < Stripe::RequestParams; end
class ListParams < Stripe::RequestParams
class UsageStatus < Stripe::RequestParams
# List of payments status to filter by.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :payments
# List of transfers status to filter by.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :transfers
sig {
params(payments: T.nilable(T::Array[String]), transfers: T.nilable(T::Array[String])).void
}
def initialize(payments: nil, transfers: nil); end
end
# The page size.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Usage status filter.
sig {
returns(T.nilable(::Stripe::V2::MoneyManagement::PayoutMethodService::ListParams::UsageStatus))
}
attr_accessor :usage_status
sig {
params(limit: T.nilable(Integer), usage_status: T.nilable(::Stripe::V2::MoneyManagement::PayoutMethodService::ListParams::UsageStatus)).void
}
def initialize(limit: nil, usage_status: nil); end
end
class RetrieveParams < Stripe::RequestParams; end
class UnarchiveParams < Stripe::RequestParams; end
# Archive a PayoutMethod object. Archived objects cannot be used as payout methods
# and will not appear in the payout method list.
#
# ** raises ControlledByDashboardError
# ** raises InvalidPayoutMethodError
sig {
params(id: String, params: T.any(::Stripe::V2::MoneyManagement::PayoutMethodService::ArchiveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::MoneyManagement::PayoutMethod)
}
def archive(id, params = {}, opts = {}); end
# List objects that adhere to the PayoutMethod interface.
sig {
params(params: T.any(::Stripe::V2::MoneyManagement::PayoutMethodService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieve a PayoutMethod object.
#
# ** raises InvalidPayoutMethodError
sig {
params(id: String, params: T.any(::Stripe::V2::MoneyManagement::PayoutMethodService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::MoneyManagement::PayoutMethod)
}
def retrieve(id, params = {}, opts = {}); end
# Unarchive an PayoutMethod object.
#
# ** raises ControlledByDashboardError
# ** raises InvalidPayoutMethodError
sig {
params(id: String, params: T.any(::Stripe::V2::MoneyManagement::PayoutMethodService::UnarchiveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::MoneyManagement::PayoutMethod)
}
def unarchive(id, params = {}, opts = {}); end
end
end
end
end
# typed: true
module Stripe
module V2
module MoneyManagement
class PayoutMethodsBankAccountSpecService < StripeService
class RetrieveParams < Stripe::RequestParams
# The countries to fetch the bank account spec for.
sig { returns(T.nilable(T::Array[String])) }
attr_accessor :countries
sig { params(countries: T.nilable(T::Array[String])).void }
def initialize(countries: nil); end
end
# Fetch the specifications for a set of countries to know which
# credential fields are required, the validations for each fields, and how to translate these
# country-specific fields to the generic fields in the PayoutMethodBankAccount type.
sig {
params(params: T.any(::Stripe::V2::MoneyManagement::PayoutMethodsBankAccountSpecService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::MoneyManagement::PayoutMethodsBankAccountSpec)
}
def retrieve(params = {}, opts = {}); end
end
end
end
end
# typed: true
module Stripe
module V2
module MoneyManagement
class ReceivedCreditService < StripeService
class ListParams < Stripe::RequestParams
# Filter for objects created at the specified timestamp.
# Must be an RFC 3339 date & time value, for example: 2022-09-18T13:22:00Z.
sig { returns(T.nilable(String)) }
attr_accessor :created
# Filter for objects created after the specified timestamp.
# Must be an RFC 3339 date & time value, for example: 2022-09-18T13:22:00Z.
sig { returns(T.nilable(String)) }
attr_accessor :created_gt
# Filter for objects created on or after the specified timestamp.
# Must be an RFC 3339 date & time value, for example: 2022-09-18T13:22:00Z.
sig { returns(T.nilable(String)) }
attr_accessor :created_gte
# Filter for objects created before the specified timestamp.
# Must be an RFC 3339 date & time value, for example: 2022-09-18T13:22:00Z.
sig { returns(T.nilable(String)) }
attr_accessor :created_lt
# Filter for objects created on or before the specified timestamp.
# Must be an RFC 3339 date & time value, for example: 2022-09-18T13:22:00Z.
sig { returns(T.nilable(String)) }
attr_accessor :created_lte
# The page limit.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
sig {
params(created: T.nilable(String), created_gt: T.nilable(String), created_gte: T.nilable(String), created_lt: T.nilable(String), created_lte: T.nilable(String), limit: T.nilable(Integer)).void
}
def initialize(
created: nil,
created_gt: nil,
created_gte: nil,
created_lt: nil,
created_lte: nil,
limit: nil
); end
end
class RetrieveParams < Stripe::RequestParams; end
# Retrieves a list of ReceivedCredits.
sig {
params(params: T.any(::Stripe::V2::MoneyManagement::ReceivedCreditService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieve a ReceivedCredit by ID.
sig {
params(id: String, params: T.any(::Stripe::V2::MoneyManagement::ReceivedCreditService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::MoneyManagement::ReceivedCredit)
}
def retrieve(id, params = {}, opts = {}); end
end
end
end
end
# typed: true
module Stripe
module V2
module MoneyManagement
class ReceivedDebitService < StripeService
class ListParams < Stripe::RequestParams
# The page limit.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
sig { params(limit: T.nilable(Integer)).void }
def initialize(limit: nil); end
end
class RetrieveParams < Stripe::RequestParams; end
# Retrieves a list of ReceivedDebits, given the selected filters.
sig {
params(params: T.any(::Stripe::V2::MoneyManagement::ReceivedDebitService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves a single ReceivedDebit by ID.
sig {
params(id: String, params: T.any(::Stripe::V2::MoneyManagement::ReceivedDebitService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::MoneyManagement::ReceivedDebit)
}
def retrieve(id, params = {}, opts = {}); end
end
end
end
end
# typed: true
module Stripe
module V2
module MoneyManagement
class TransactionService < StripeService
class ListParams < Stripe::RequestParams
# Filter for Transactions created at an exact time.
sig { returns(T.nilable(String)) }
attr_accessor :created
# Filter for Transactions created after the specified timestamp.
sig { returns(T.nilable(String)) }
attr_accessor :created_gt
# Filter for Transactions created at or after the specified timestamp.
sig { returns(T.nilable(String)) }
attr_accessor :created_gte
# Filter for Transactions created before the specified timestamp.
sig { returns(T.nilable(String)) }
attr_accessor :created_lt
# Filter for Transactions created at or before the specified timestamp.
sig { returns(T.nilable(String)) }
attr_accessor :created_lte
# Filter for Transactions belonging to a FinancialAccount.
sig { returns(T.nilable(String)) }
attr_accessor :financial_account
# Filter for Transactions corresponding to a Flow.
sig { returns(T.nilable(String)) }
attr_accessor :flow
# The page limit.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
sig {
params(created: T.nilable(String), created_gt: T.nilable(String), created_gte: T.nilable(String), created_lt: T.nilable(String), created_lte: T.nilable(String), financial_account: T.nilable(String), flow: T.nilable(String), limit: T.nilable(Integer)).void
}
def initialize(
created: nil,
created_gt: nil,
created_gte: nil,
created_lt: nil,
created_lte: nil,
financial_account: nil,
flow: nil,
limit: nil
); end
end
class RetrieveParams < Stripe::RequestParams; end
# Returns a list of Transactions that match the provided filters.
sig {
params(params: T.any(::Stripe::V2::MoneyManagement::TransactionService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the details of a Transaction by ID.
sig {
params(id: String, params: T.any(::Stripe::V2::MoneyManagement::TransactionService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::MoneyManagement::Transaction)
}
def retrieve(id, params = {}, opts = {}); end
end
end
end
end
# typed: true
module Stripe
module V2
module MoneyManagement
class TransactionEntryService < StripeService
class ListParams < Stripe::RequestParams
# Filter for Transactions created at an exact time.
sig { returns(T.nilable(String)) }
attr_accessor :created
# Filter for Transactions created after the specified timestamp.
sig { returns(T.nilable(String)) }
attr_accessor :created_gt
# Filter for Transactions created at or after the specified timestamp.
sig { returns(T.nilable(String)) }
attr_accessor :created_gte
# Filter for Transactions created before the specified timestamp.
sig { returns(T.nilable(String)) }
attr_accessor :created_lt
# Filter for Transactions created at or before the specified timestamp.
sig { returns(T.nilable(String)) }
attr_accessor :created_lte
# The page limit.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
# Filter for TransactionEntries belonging to a Transaction.
sig { returns(T.nilable(String)) }
attr_accessor :transaction
sig {
params(created: T.nilable(String), created_gt: T.nilable(String), created_gte: T.nilable(String), created_lt: T.nilable(String), created_lte: T.nilable(String), limit: T.nilable(Integer), transaction: T.nilable(String)).void
}
def initialize(
created: nil,
created_gt: nil,
created_gte: nil,
created_lt: nil,
created_lte: nil,
limit: nil,
transaction: nil
); end
end
class RetrieveParams < Stripe::RequestParams; end
# Returns a list of TransactionEntries that match the provided filters.
sig {
params(params: T.any(::Stripe::V2::MoneyManagement::TransactionEntryService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieves the details of a TransactionEntry by ID.
sig {
params(id: String, params: T.any(::Stripe::V2::MoneyManagement::TransactionEntryService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::MoneyManagement::TransactionEntry)
}
def retrieve(id, params = {}, opts = {}); end
end
end
end
end
# typed: true
module Stripe
module V2
class BillingService < StripeService
attr_reader :meter_event_session
attr_reader :meter_event_adjustments
attr_reader :meter_event_stream
attr_reader :meter_events
end
end
end
# typed: true
module Stripe
module V2
module Billing
class MeterEventSessionService < StripeService
class CreateParams < Stripe::RequestParams; end
# Creates a meter event session to send usage on the high-throughput meter event stream. Authentication tokens are only valid for 15 minutes, so you will need to create a new meter event session when your token expires.
sig {
params(params: T.any(::Stripe::V2::Billing::MeterEventSessionService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::Billing::MeterEventSession)
}
def create(params = {}, opts = {}); end
end
end
end
end
# typed: true
module Stripe
module V2
module Billing
class MeterEventAdjustmentService < StripeService
class CreateParams < Stripe::RequestParams
class Cancel < Stripe::RequestParams
# Unique identifier for the event. You can only cancel events within 24 hours of Stripe receiving them.
sig { returns(String) }
attr_accessor :identifier
sig { params(identifier: String).void }
def initialize(identifier: nil); end
end
# Specifies which event to cancel.
sig { returns(::Stripe::V2::Billing::MeterEventAdjustmentService::CreateParams::Cancel) }
attr_accessor :cancel
# The name of the meter event. Corresponds with the `event_name` field on a meter.
sig { returns(String) }
attr_accessor :event_name
# Specifies whether to cancel a single event or a range of events for a time period. Time period cancellation is not supported yet.
sig { returns(String) }
attr_accessor :type
sig {
params(cancel: ::Stripe::V2::Billing::MeterEventAdjustmentService::CreateParams::Cancel, event_name: String, type: String).void
}
def initialize(cancel: nil, event_name: nil, type: nil); end
end
# Creates a meter event adjustment to cancel a previously sent meter event.
sig {
params(params: T.any(::Stripe::V2::Billing::MeterEventAdjustmentService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::Billing::MeterEventAdjustment)
}
def create(params = {}, opts = {}); end
end
end
end
end
# typed: true
module Stripe
module V2
module Billing
class MeterEventStreamService < StripeService
class CreateParams < Stripe::RequestParams
class Event < Stripe::RequestParams
# The name of the meter event. Corresponds with the `event_name` field on a meter.
sig { returns(String) }
attr_accessor :event_name
# A unique identifier for the event. If not provided, one will be generated.
# We recommend using a globally unique identifier for this. We’ll enforce
# uniqueness within a rolling 24 hour period.
sig { returns(T.nilable(String)) }
attr_accessor :identifier
# The payload of the event. This must contain the fields corresponding to a meter’s
# `customer_mapping.event_payload_key` (default is `stripe_customer_id`) and
# `value_settings.event_payload_key` (default is `value`). Read more about
# the
# [payload](https://docs.stripe.com/billing/subscriptions/usage-based/recording-usage#payload-key-overrides).
sig { returns(T::Hash[String, String]) }
attr_accessor :payload
# The time of the event. Must be within the past 35 calendar days or up to
# 5 minutes in the future. Defaults to current timestamp if not specified.
sig { returns(T.nilable(String)) }
attr_accessor :timestamp
sig {
params(event_name: String, identifier: T.nilable(String), payload: T::Hash[String, String], timestamp: T.nilable(String)).void
}
def initialize(event_name: nil, identifier: nil, payload: nil, timestamp: nil); end
end
# List of meter events to include in the request.
sig {
returns(T::Array[::Stripe::V2::Billing::MeterEventStreamService::CreateParams::Event])
}
attr_accessor :events
sig {
params(events: T::Array[::Stripe::V2::Billing::MeterEventStreamService::CreateParams::Event]).void
}
def initialize(events: nil); end
end
# Creates meter events. Events are processed asynchronously, including validation. Requires a meter event session for authentication. Supports up to 10,000 requests per second in livemode. For even higher rate-limits, contact sales.
#
# ** raises TemporarySessionExpiredError
sig {
params(params: T.any(::Stripe::V2::Billing::MeterEventStreamService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).void
}
def create(params = {}, opts = {}); end
end
end
end
end
# typed: true
module Stripe
module V2
module Billing
class MeterEventService < StripeService
class CreateParams < Stripe::RequestParams
# The name of the meter event. Corresponds with the `event_name` field on a meter.
sig { returns(String) }
attr_accessor :event_name
# A unique identifier for the event. If not provided, one will be generated.
# We recommend using a globally unique identifier for this. We’ll enforce
# uniqueness within a rolling 24 hour period.
sig { returns(T.nilable(String)) }
attr_accessor :identifier
# The payload of the event. This must contain the fields corresponding to a meter’s
# `customer_mapping.event_payload_key` (default is `stripe_customer_id`) and
# `value_settings.event_payload_key` (default is `value`). Read more about
# the
# [payload](https://docs.stripe.com/billing/subscriptions/usage-based/recording-usage#payload-key-overrides).
sig { returns(T::Hash[String, String]) }
attr_accessor :payload
# The time of the event. Must be within the past 35 calendar days or up to
# 5 minutes in the future. Defaults to current timestamp if not specified.
sig { returns(T.nilable(String)) }
attr_accessor :timestamp
sig {
params(event_name: String, identifier: T.nilable(String), payload: T::Hash[String, String], timestamp: T.nilable(String)).void
}
def initialize(event_name: nil, identifier: nil, payload: nil, timestamp: nil); end
end
# Creates a meter event. Events are validated synchronously, but are processed asynchronously. Supports up to 1,000 events per second in livemode. For higher rate-limits, please use meter event streams instead.
sig {
params(params: T.any(::Stripe::V2::Billing::MeterEventService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::Billing::MeterEvent)
}
def create(params = {}, opts = {}); end
end
end
end
end
# typed: true
module Stripe
module V2
class TestHelperService < StripeService
attr_reader :financial_addresses
end
end
end
# typed: true
module Stripe
module V2
module TestHelpers
class FinancialAddressService < StripeService
class CreditParams < Stripe::RequestParams
# Object containing the amount value and currency to credit.
sig { returns(Stripe::V2::Amount) }
attr_accessor :amount
# Open Enum. The network to use in simulating the funds flow. This will be the reflected in the resulting ReceivedCredit.
sig { returns(String) }
attr_accessor :network
# String explaining funds flow. Use this field to populate the statement descriptor of the ReceivedCredit created as an eventual result of this simulation.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
sig {
params(amount: Stripe::V2::Amount, network: String, statement_descriptor: T.nilable(String)).void
}
def initialize(amount: nil, network: nil, statement_descriptor: nil); end
end
class GenerateMicrodepositsParams < Stripe::RequestParams; end
# Simulate crediting a FinancialAddress in a Sandbox environment. This can be used to add virtual funds and increase your balance for testing.
sig {
params(id: String, params: T.any(::Stripe::V2::TestHelpers::FinancialAddressService::CreditParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::FinancialAddressCreditSimulation)
}
def credit(id, params = {}, opts = {}); end
# Generates microdeposits for a FinancialAddress in a Sandbox environment.
sig {
params(id: String, params: T.any(::Stripe::V2::TestHelpers::FinancialAddressService::GenerateMicrodepositsParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::FinancialAddressGeneratedMicrodeposits)
}
def generate_microdeposits(id, params = {}, opts = {}); end
end
end
end
end
# typed: true
module Stripe
module V2
class PaymentService < StripeService
attr_reader :off_session_payments
end
end
end
# typed: true
module Stripe
module V2
module Payments
class OffSessionPaymentService < StripeService
class CancelParams < Stripe::RequestParams; end
class CreateParams < Stripe::RequestParams
class RetryDetails < Stripe::RequestParams
# How you want Stripe to retry the payment.
sig { returns(String) }
attr_accessor :retry_strategy
sig { params(retry_strategy: String).void }
def initialize(retry_strategy: nil); end
end
class TransferData < Stripe::RequestParams
# Amount in minor units that you want to transfer.
sig { returns(Integer) }
attr_accessor :amount
# ID of the connected account where you want money to go.
sig { returns(String) }
attr_accessor :destination
sig { params(amount: Integer, destination: String).void }
def initialize(amount: nil, destination: nil); end
end
# Amount you want to collect.
sig { returns(Stripe::V2::Amount) }
attr_accessor :amount
# The frequency of the OSP.
sig { returns(String) }
attr_accessor :cadence
# Customer that owns the provided payment method.
sig { returns(String) }
attr_accessor :customer
# Any of your internal data you want to track here.
sig { returns(T::Hash[String, String]) }
attr_accessor :metadata
# The OBO merchant you want to use.
sig { returns(T.nilable(String)) }
attr_accessor :on_behalf_of
# Payment method you want to debit. Must be attached to a customer and set up for off-session usage.
sig { returns(String) }
attr_accessor :payment_method
# How you want stripe to retry the OSP.
sig {
returns(T.nilable(::Stripe::V2::Payments::OffSessionPaymentService::CreateParams::RetryDetails))
}
attr_accessor :retry_details
# String you want to appear on your customer's statement.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor
# Suffix appended to your account level descriptor.
sig { returns(T.nilable(String)) }
attr_accessor :statement_descriptor_suffix
# Test clock to be used for testing your retry handling. Only usable in a sandbox.
sig { returns(T.nilable(String)) }
attr_accessor :test_clock
# How you want to transfer the funds to your connected accounts.
sig {
returns(T.nilable(::Stripe::V2::Payments::OffSessionPaymentService::CreateParams::TransferData))
}
attr_accessor :transfer_data
sig {
params(amount: Stripe::V2::Amount, cadence: String, customer: String, metadata: T::Hash[String, String], on_behalf_of: T.nilable(String), payment_method: String, retry_details: T.nilable(::Stripe::V2::Payments::OffSessionPaymentService::CreateParams::RetryDetails), statement_descriptor: T.nilable(String), statement_descriptor_suffix: T.nilable(String), test_clock: T.nilable(String), transfer_data: T.nilable(::Stripe::V2::Payments::OffSessionPaymentService::CreateParams::TransferData)).void
}
def initialize(
amount: nil,
cadence: nil,
customer: nil,
metadata: nil,
on_behalf_of: nil,
payment_method: nil,
retry_details: nil,
statement_descriptor: nil,
statement_descriptor_suffix: nil,
test_clock: nil,
transfer_data: nil
); end
end
class ListParams < Stripe::RequestParams
# The page size limit, if not provided the default is 20.
sig { returns(T.nilable(Integer)) }
attr_accessor :limit
sig { params(limit: T.nilable(Integer)).void }
def initialize(limit: nil); end
end
class RetrieveParams < Stripe::RequestParams; end
# Cancel OSP.
sig {
params(id: String, params: T.any(::Stripe::V2::Payments::OffSessionPaymentService::CancelParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::Payments::OffSessionPayment)
}
def cancel(id, params = {}, opts = {}); end
# Create OSP.
sig {
params(params: T.any(::Stripe::V2::Payments::OffSessionPaymentService::CreateParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::Payments::OffSessionPayment)
}
def create(params = {}, opts = {}); end
# List OSPs matching filter.
sig {
params(params: T.any(::Stripe::V2::Payments::OffSessionPaymentService::ListParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::ListObject)
}
def list(params = {}, opts = {}); end
# Retrieve OSP by ID.
sig {
params(id: String, params: T.any(::Stripe::V2::Payments::OffSessionPaymentService::RetrieveParams, T::Hash[T.untyped, T.untyped]), opts: T.untyped).returns(Stripe::V2::Payments::OffSessionPayment)
}
def retrieve(id, params = {}, opts = {}); end
end
end
end
end